Skip to content

Commit

Permalink
Added the img's width as the initial default size
Browse files Browse the repository at this point in the history
  • Loading branch information
yoavweiss committed Jan 3, 2014
1 parent 580ad04 commit d0fda08
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 14 deletions.
18 changes: 10 additions & 8 deletions index.html
Original file line number Diff line number Diff line change
Expand Up @@ -546,14 +546,14 @@
</p>
<h1 class="p-name no-ref" id=title>The picture Element</h1>
<h2 class="no-num no-toc no-ref heading settled heading" id=subtitle><span class=content>Editor’s Draft,
<span class=dt-updated><span class=value-title title=20140102>2 January 2014</span></span></span></h2>
<span class=dt-updated><span class=value-title title=20140103>3 January 2014</span></span></span></h2>
<div data-fill-with=spec-metadata><dl><dt>This version:<dd><a class=u-url href=http://picture.responsiveimages.org>http://picture.responsiveimages.org</a><dt>Editor’s Draft:<dd><a href=http://picture.responsiveimages.org>http://picture.responsiveimages.org</a><dt>Test Suite:<dd>None Yet<dt>Editors:
<dd class="p-author h-card vcard"><a class="p-name fn u-url url" href=http://xanthir.com/contact/>Tab Atkins</a> (<span class="p-org org">Google</span>)<dd class="p-author h-card vcard"><a class="p-name fn u-email email" href=mailto:>Marcos Cáceres</a> (<span class="p-org org">Mozilla</span>)<dd class="p-author h-card vcard"><a class="p-name fn u-url url" href=http://matmarquis.com/>Mat Marquis</a><dd class="p-author h-card vcard"><a class="p-name fn u-url url" href=http://blog.yoav.ws/>Yoav Weiss</a><dt>Version History:<dd><a href=https://github.com/ResponsiveImagesCG/picture-element/commits/gh-pages>Commit History</a><dd><a href=https://twitter.com/respimg_commits>Github commits on Twitter</a><dt>Participate:<dd><a href=http://w3c.responsiveimages.org>Join the Responsive Images Community Group</a><dd><a href=http://list.responsiveimages.org>Public Mailing List</a><dd><a href=irc://irc.w3.org:6665/#respimg>IRC: #respimg on W3C’s IRC</a><dd><a href=https://twitter.com/respimg>Twitter</a><dd><a href=https://github.com/ResponsiveImagesCG/picture-element>Github</a></dl></div>
<div data-fill-with=warning></div>
<p class=copyright data-fill-with=copyright><a href=http://creativecommons.org/publicdomain/zero/1.0/ rel=license><img alt=CC0 src=http://i.creativecommons.org/p/zero/1.0/80x15.png></a>
To the extent possible under law, the editors have waived all copyright
and related or neighboring rights to this work.
In addition, as of 2 January 2014,
In addition, as of 3 January 2014,
the editors have made this specification available under the
<a href=http://www.openwebfoundation.org/legal/the-owf-1-0-agreements/owfa-1-0 rel=license>Open Web Foundation Agreement Version 1.0</a>,
which is available at http://www.openwebfoundation.org/legal/the-owf-1-0-agreements/owfa-1-0.
Expand Down Expand Up @@ -908,9 +908,9 @@ <h4 class="heading settled heading" data-level=3.1.1 id=select-image-source><spa
Let this be <var>selected source</var>.

<li>
The intrinsic width of <var>parent</var> is the result of <a data-link-type=dfn href=#find-the-effective-size title="find the effective size">finding the effective size</a>
The intrinsic width of <var>child</var> is the result of <a data-link-type=dfn href=#find-the-effective-size title="find the effective size">finding the effective size</a>
from <var>source list</var>.
The intrinsic resolution of <var>parent</var> is the density associated with <var>selected source</var>.
The intrinsic resolution of <var>child</var> is the density associated with <var>selected source</var>.

<li>
<p class=issue id=issue-6edd4c75><a class=self-link href=#issue-6edd4c75></a>
Expand Down Expand Up @@ -1055,12 +1055,13 @@ <h4 class="heading settled heading" data-level=3.1.4 id=parse-sizes-attr><span c
</pre>
<p> The above grammar must be interpreted per the grammar definition in <a data-biblio-type=normative data-link-type=biblio href=#css3val title=css3val>[CSS3VAL]</a>.

<p> let <var>source size list</var> initially be an empty <a data-link-type=dfn href=#source-size-list title="source size list">source size list</a>.
Set <var>source size list</var>’s default size to the <var>child</var> <a data-link-type=element href=http://www.w3.org/html/wg/drafts/html/CR/embedded-content-0.html#the-img-element title=img>img</a>’s <dfn data-dfn-for=img data-dfn-type=element-attr data-export="" id=element-attrdef-width>width<a class=self-link href=#element-attrdef-width></a></dfn> attribute.

<p> If the value does not parse successfully according to the above grammar,
return an empty <a data-link-type=dfn href=#source-size-list title="source size list">source size list</a>.
return <a data-link-type=dfn href=#source-size-list title="source size list">source size list</a>.

<p> Otherwise,
let <var>source size list</var> initially be an emtpy <a data-link-type=dfn href=#source-size-list title="source size list">source size list</a>.
For each <a class="production css-code" data-link-type=type href=#typedef-source-size title="<source-size>">&lt;source-size&gt;</a> parsed,
<p> Otherwise, for each <a class="production css-code" data-link-type=type href=#typedef-source-size title="<source-size>">&lt;source-size&gt;</a> parsed,
do the following:

<ol>
Expand Down Expand Up @@ -1280,6 +1281,7 @@ <h2 class="no-num no-ref heading settled heading" id=index><span class=content>
</ul><li>update the list of source sets, <a href=#update-the-list-of-source-sets title="section 3.1.2">3.1.2</a>
<li>&lt;url&gt;, <a href=#typedef-url title="section 3.1.3">3.1.3</a>
<li>valid media query, <a href=#dfn-valid-media-query title="section 2">2</a>
<li>width, <a href=#element-attrdef-width title="section 3.1.4">3.1.4</a>
</ul></div>

<h2 class="no-num no-ref heading settled heading" id=property-index><span class=content>
Expand Down
13 changes: 7 additions & 6 deletions index.src.html
Original file line number Diff line number Diff line change
Expand Up @@ -363,9 +363,9 @@ <h4 id='select-image-source'>
Let this be <var>selected source</var>.

<li>
The intrinsic width of <var>parent</var> is the result of <a title="find the effective size">finding the effective size</a>
The intrinsic width of <var>child</var> is the result of <a title="find the effective size">finding the effective size</a>
from <var>source list</var>.
The intrinsic resolution of <var>parent</var> is the density associated with <var>selected source</var>.
The intrinsic resolution of <var>child</var> is the density associated with <var>selected source</var>.

<li>
<p class='issue'>
Expand Down Expand Up @@ -514,12 +514,13 @@ <h4 id='parse-sizes-attr'>

The above grammar must be interpreted per the grammar definition in [[!CSS3VAL]].

let <var>source size list</var> initially be an empty <a>source size list</a>.
Set <var>source size list</var>’s default size to the <var>child</var> <a element>img</a>'s <dfn element-attr for="img">width</dfn> attribute.

If the value does not parse successfully according to the above grammar,
return an empty <a>source size list</a>.
return <a>source size list</a>.

Otherwise,
let <var>source size list</var> initially be an emtpy <a>source size list</a>.
For each <<source-size>> parsed,
Otherwise, for each <<source-size>> parsed,
do the following:

<ol>
Expand Down

0 comments on commit d0fda08

Please sign in to comment.