mhulse / rex

On, Wildfire, on!
http://mhulse.github.io/rex/demo/
Apache License 2.0
4 stars 0 forks source link

Re-think address? #136

Closed mhulse closed 10 years ago

mhulse commented 10 years ago

Check this table:

https://developer.mozilla.org/en-US/docs/Web/Guide/HTML/HTML5/HTML5_element_list#Sections

What the hell, in HTML5, is an <address> element a block or inline element (in an HTML4 sense)?

If it's block, then it should be left how I have it. If it's used mostly as inline to other blocks, then I should remove my margins and line-height. Let the parent handle that stuff.

mhulse commented 10 years ago

Based on:

http://www.w3.org/html/wg/drafts/html/master/sections.html#the-address-element

<footer>
 <address>
  For more details, contact
  <a href="mailto:js@example.com">John Smith</a>.
 </address>
 <p><small>© copyright 2038 Example Corp.</small></p>
</footer>

Looks like it's used primarily as "block".

Here's the deets:

Categories:
Flow content.
Palpable content.
Contexts in which this element can be used:
Where flow content is expected.
Content model:
Flow content, but with no heading content descendants, no sectioning content descendants, and no header, footer, or address element descendants.
Content attributes:
Global attributes
DOM interface:
Uses HTMLElement.

So, it's kinda like a blockquote, in that it may contain <p> or <ul> or other.

I should probably do something similar to blockquote styling, like:

> :first-child { margin-top: 0 !important; }
> :last-child { margin-bottom: 0 !important; }

See blockquote:

https://github.com/mhulse/rex/blob/gh-pages/rex/scss/partials/_master.scss#L397-L404

mhulse commented 10 years ago

It's been thunk. Just dropped styles altogether. f564dd8395b130c3927324e6d5115f4465fec82a