Gutenberg: Add Block: Quote

Created on 23 Mar 2017  路  7Comments  路  Source: WordPress/gutenberg

Attributes

  • Alignment: None, Left, Right, Center, Full Bleed.
  • Alternative style of quote.
  • Cite (fixed field).

Markup

<!-- wp:quote -->
<blockquote>
    <p>The quick brown fox jumps over the lazy dog.</p>
    <cite>Author</cite>
</blockquote>
<!-- /wp -->

States (see all)

image

image

Framework [Type] Task

Most helpful comment

Closing this. All quote features are there I think. And we can open specific issues anyway.

All 7 comments

Going to try to do a PR for this.

Can blockquotes have things like headings and lists? If so, how can they be added and changed?

Can blockquotes have things like headings and lists?

Yes, HTML is fairly liberal about nesting. Since a blockquote is an extended quotation, it can have lots of different HTML elements that are flow content.

And did you know that there is a cite attribute for the blockquote element? It is distinct from a separate cite element.

@joyously I know it's possible in HTML and the current editor. Asking about this particular block. I think that some blocks might need to act as "container blocks". Blockquote is a good example, and there are plenty of sites that have stuff like an aside/explainer.

I was talking about this particular block also. It's similar to what I commented on the Text block: "do you parse it as they edit and make it into other blocks or let them put whatever they want?".
As stated, the markup for this _block_ can contain other HTML elements. But the <p> tags cannot. I think those should be removed.

In my research, markup for quotes is not trivial. Some use <footer> instead of cite, for instance.

Also keep in mind the second style of block is similar to the purpose of the quote post-format. Interestingly, shortcake shows a very similar example where the need for a separate source attribute is clearer.

Closing this. All quote features are there I think. And we can open specific issues anyway.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

maddisondesigns picture maddisondesigns  路  3Comments

mhenrylucero picture mhenrylucero  路  3Comments

ellatrix picture ellatrix  路  3Comments

davidsword picture davidsword  路  3Comments

jasmussen picture jasmussen  路  3Comments