imathis / octopress

Octopress is an obsessively designed framework for Jekyll blogging. It’s easy to configure and easy to deploy. Sweet huh?
http://github.com/imathis/octopress
9.31k stars 2.62k forks source link

Update blockquote to use HTML5 figure for author grouping #994

Open imathis opened 11 years ago

imathis commented 11 years ago

What's wrong

The current blockquote plugin outputs the following HTML:

<blockquote>
  <p>Some quoted text</p>
  <footer>
    <strong>Author's Name</strong>
    <cite>
      <a href="…">Website</a>
    </cite>
  </footer>
</blockquote>

At the time I was following the recomendation at html5doctor.com which was later corrected (jump down to the 2011-07-11 update).

How to fix.

The current spec recommends wraping the blockquote with a figure and nesting its attribution inside of a figcaption, like so:

<figure>
  <blockquote>Never pet a burning dog.</blockquote>
  <figcaption>
    <span class='quote-author'>Some NPC</span>
    <cite>Warcraft II</cite>
  </figcaption>
</figure>

An aside: It occurs to me that this is one of the nice things about relying on plugins to write HTML. When the spec changes or clarifies things, fixing content is as easy as updating the plugin.

parkr commented 11 years ago

That's literally exactly what I meant to send you this morning. Crazy.

imathis commented 11 years ago

Hah!