Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
[e] (0) Clarify that HTML doesn't override CSS. (credit: db)
git-svn-id: http://svn.whatwg.org/webapps@2555 340c8d12-0b0e-0410-8428-c7bf67bfef74
  • Loading branch information
Hixie committed Dec 24, 2008
1 parent 0efa473 commit e6cafa9
Show file tree
Hide file tree
Showing 2 changed files with 48 additions and 11 deletions.
28 changes: 23 additions & 5 deletions index
Expand Up @@ -8441,6 +8441,11 @@ Consider: data:text/xml,<script xmlns="http://www.w3.org/1999/xhtml"><![CDATA[ d
attribute. User agents must process the links on a per-link basis,
not a per-element basis.</p>

<p class=note>Each link is handled separately. For instance, if
there are two <code><a href=#the-link-element>link</a></code> elements with <code title="">rel="stylesheet"</code>, they each count as a separate
external resource, and each is affected by its own attributes
independently.</p>

<p>The exact behavior for links to external resources depends on the
exact relationship, as defined for the relevant link type. Some of
the attributes control whether or not the external resource is to be
Expand Down Expand Up @@ -8498,9 +8503,15 @@ Consider: data:text/xml,<script xmlns="http://www.w3.org/1999/xhtml"><![CDATA[ d
<p>However, if the link is an <a href=#external-resource-link>external resource link</a>,
then the <code title=attr-link-media><a href=#attr-link-media>media</a></code> attribute is
prescriptive. The user agent must apply the external resource to
<span>views</span><!-- XXX xref --> while their state match the
listed media and the other relevant conditions apply, and must not
apply them otherwise.</p>
<a href=#view title=view>views</a> while their state match the listed
media and the other relevant conditions apply, and must not apply
them otherwise.</p><!-- note similar text in <style> section -->

<p class=note>The external resource might have further
restrictions defined within that limit its applicability. For
example, a CSS style sheet might have some <code title="">@media</code> blocks. This specification does not override
such further restrictions or requirements.</p><!-- note similar text
in <style> section -->

<p id=default-media>The default, if the <code title=attr-link-media><a href=#attr-link-media>media</a></code> attribute is omitted, is
<code>all</code>, meaning that by default links apply to all
Expand Down Expand Up @@ -9267,8 +9278,15 @@ people expect to have work and what is necessary.
<p>The <dfn id=attr-style-media title=attr-style-media><code>media</code></dfn>
attribute says which media the styles apply to. The value must be a
valid <a href=#mq>media query</a>. <a href=#refsMQ>[MQ]</a> User
agents must apply the styles to <span>views</span> while their state
match the listed media, and must not apply them otherwise. <a href=#refsDOM3VIEWS>[DOM3VIEWS]</a></p>
agents must apply the styles to <a href=#view title=view>views</a>
while their state match the listed media, and must not apply them
otherwise.</p><!-- note similar text in <link> section -->

<p class=note>The styles might be further limited in scope,
e.g. in CSS with the use of <code title="">@media</code>
blocks. This specification does not override such further
restrictions or requirements.</p><!-- note similar text in <link>
section -->

<p id=style-default-media>The default, if the <code title=attr-style-media><a href=#attr-style-media>media</a></code> attribute is omitted, is
<code>all</code>, meaning that by default styles apply to all
Expand Down
31 changes: 25 additions & 6 deletions source
Expand Up @@ -8752,6 +8752,12 @@ Consider: data:text/xml,<script xmlns="http://www.w3.org/1999/xhtml"><![CDATA[ d
attribute. User agents must process the links on a per-link basis,
not a per-element basis.</p>

<p class="note">Each link is handled separately. For instance, if
there are two <code>link</code> elements with <code
title="">rel="stylesheet"</code>, they each count as a separate
external resource, and each is affected by its own attributes
independently.</p>

<p>The exact behavior for links to external resources depends on the
exact relationship, as defined for the relevant link type. Some of
the attributes control whether or not the external resource is to be
Expand Down Expand Up @@ -8821,9 +8827,16 @@ Consider: data:text/xml,<script xmlns="http://www.w3.org/1999/xhtml"><![CDATA[ d
<p>However, if the link is an <span>external resource link</span>,
then the <code title="attr-link-media">media</code> attribute is
prescriptive. The user agent must apply the external resource to
<span>views</span><!-- XXX xref --> while their state match the
listed media and the other relevant conditions apply, and must not
apply them otherwise.</p>
<span title="view">views</span> while their state match the listed
media and the other relevant conditions apply, and must not apply
them otherwise.</p><!-- note similar text in <style> section -->

<p class="note">The external resource might have further
restrictions defined within that limit its applicability. For
example, a CSS style sheet might have some <code
title="">@media</code> blocks. This specification does not override
such further restrictions or requirements.</p><!-- note similar text
in <style> section -->

<p id="default-media">The default, if the <code
title="attr-link-media">media</code> attribute is omitted, is
Expand Down Expand Up @@ -9721,9 +9734,15 @@ people expect to have work and what is necessary.
<p>The <dfn title="attr-style-media"><code>media</code></dfn>
attribute says which media the styles apply to. The value must be a
valid <a href="#mq">media query</a>. <a href="#refsMQ">[MQ]</a> User
agents must apply the styles to <span>views</span> while their state
match the listed media, and must not apply them otherwise. <a
href="#refsDOM3VIEWS">[DOM3VIEWS]</a></p>
agents must apply the styles to <span title="view">views</span>
while their state match the listed media, and must not apply them
otherwise.</p><!-- note similar text in <link> section -->

<p class="note">The styles might be further limited in scope,
e.g. in CSS with the use of <code title="">@media</code>
blocks. This specification does not override such further
restrictions or requirements.</p><!-- note similar text in <link>
section -->

<p id="style-default-media">The default, if the <code
title="attr-style-media">media</code> attribute is omitted, is
Expand Down

0 comments on commit e6cafa9

Please sign in to comment.