Charles Pritchard | 1 Sep 01:46 2011

Re: add html-attribute for "responsive images"

On 8/31/2011 2:32 PM, Karl Dubost wrote:
> Anselm,
> (setting reply-to on www-style)
>
> Seen this today, to remind people that it is not just
> something up in the air. People need it.
> http://www.webmonkey.com/2011/08/speed-up-your-responsive-designs-with-adaptive-images/
>
> I wonder if it could be handled by CSS in fact.
> I guess Anselm, you could ask there.
> On the www-style mailing-list, Charles proposed [1]
>
> 	content: url(img.jpg) replaced;

Oh, that's not my proposal, that syntax was brought up by Tab Atkins.

It's already available. I was looking into how to handle <img [no 
source] style="background: url(..)" />
It may work with the following, now, or at some point in the future:
<img style="content: replaced; background-color: ...;" />

I'd proposed visibility: content-hidden; to be used with background and 
border.

> I'm not sure I fully understand the proposal
> but we can imagine something that could fit nicely
> with the CSS Generated Content Module Level 3 [2]
>
> <img class="responsive" src="http://example.org/foo" alt="wiizz"/>
>
(Continue reading)

Picon

Re: add html-attribute for "responsive images"

Am 31.08.2011 um 23:32 schrieb Karl Dubost:

> Anselm,
> (setting reply-to on www-style)
> 
> Seen this today, to remind people that it is not just 
> something up in the air. People need it.
> http://www.webmonkey.com/2011/08/speed-up-your-responsive-designs-with-adaptive-images/
> 
> I wonder if it could be handled by CSS in fact. 
> I guess Anselm, you could ask there.
> On the www-style mailing-list, Charles proposed [1]
> 
> 	content: url(img.jpg) replaced;
> 
> I'm not sure I fully understand the proposal 
> but we can imagine something that could fit nicely 
> with the CSS Generated Content Module Level 3 [2]
> 
> <img class="responsive" src="http://example.org/foo" alt="wiizz"/>
> 
> and then the CSS
> 
> 
>  <at> media  screen and (min-width:550px) and (max-width:960px) {
>   img.responsive {
> 	url(http://example.org/foobis) replaced;}
>   }
>  <at> media  screen and (min-width:240px) and (max-width:549px) {
>   img.responsive {
(Continue reading)

Picon

Re: add html-attribute for "responsive images"

Am 01.09.2011 um 01:46 schrieb Charles Pritchard:

> On 8/31/2011 2:32 PM, Karl Dubost wrote:

> Oh, that's not my proposal, that syntax was brought up by Tab Atkins.
> 
> It's already available. I was looking into how to handle <img [no source] style="background: url(..)" />
> It may work with the following, now, or at some point in the future:
> <img style="content: replaced; background-color: ...;" />
> 
> I'd proposed visibility: content-hidden; to be used with background and border.

Why should we use inline-styles once again? Why should we load content images with CSS? What about
accessibility? Where to add alt-attribute / title / ARIA etc.?
-Anselm
Anne van Kesteren | 1 Sep 10:39 2011
Picon

Re: Node inDocument

On Thu, 01 Sep 2011 00:18:26 +0200, Erik Arvidsson <arv@...>  
wrote:
> After thinking more about this we believe that moving contains to Node
> is a better alternative. The problem with Node inDocument is that it
> does not say which document it is in so code would need to also check
> ownerDocument to be robust in the presence of frames and multiple
> windows.

You got it. Now everyone please implement :-)

http://dvcs.w3.org/hg/domcore/raw-file/tip/Overview.html#dom-node-contains

--

-- 
Anne van Kesteren
http://annevankesteren.nl/

Anne van Kesteren | 1 Sep 11:10 2011
Picon

Re: Should Paths be First Class Citizens?

On Wed, 31 Aug 2011 19:48:36 +0200, David Geary  
<david.mark.geary@...> wrote:
> [...]

A native Path object is on the list of features to be added to <canvas> in  
due course.

--

-- 
Anne van Kesteren
http://annevankesteren.nl/

Alex Vincent | 1 Sep 15:26 2011
Picon

Re: Fixing undo on the Web - UndoManager and Transaction

There's too much good stuff going on, both in the specs, and in my own
project.  :-)  I noticed Ehsan's blog post about editing on the Web,
http://ehsanakhgari.org/blog/2011-08-31/future-editing-web .  I'm groaning
because I haven't been involved! :-p

A few thoughts on my mind:

   1. I think we should start writing a test suite, for two reasons.  First,
   to get some idea how this works in practice, with a reference implementation
   in JavaScript.  That will help us iron out some of the API debates we've
   been having (reapply, specifically).  Second, a test suite can help all the
   implementers implement the same thing.
   2. I think I'm not going to fully understand this spec until I at least
   try my hand at a test suite implementation, in Jasmine.  :-)
   3. I just spotted a flaw in our API's.  Imagine the following:
      -

      myEditor.undoManager.transact({apply: function () {
insert(document.createTextNode('o')) }, label: 'First transaction'});
      myEditor.undoManager.transact({apply: function () {
insert(document.createTextNode('k')) }, label: 'Merging transaction'},
true);

      - User calls myEditor.undoManager.item(0).label.  Which label does he
      get back?  For that matter, which transaction does he get back, and which
      transaction is forever hidden from him?
      - Perhaps for this reason, .item() should return a readonly
      Transaction[], representing the transaction group.
      4. Did we talk about a maxlength for the UndoManager?  If we allow an
   infinite number of transactions in an UndoManager, a lot of memory could get
(Continue reading)

Charles Pritchard | 1 Sep 17:48 2011

Re: add html-attribute for "responsive images"

On 9/1/2011 1:30 AM, Anselm Hannemann - Novolo Designagentur wrote:
> Am 01.09.2011 um 01:46 schrieb Charles Pritchard:
>
>> On 8/31/2011 2:32 PM, Karl Dubost wrote:
>
>> Oh, that's not my proposal, that syntax was brought up by Tab Atkins.
>>
>> It's already available. I was looking into how to handle <img [no 
>> source] style="background: url(..)" />
>> It may work with the following, now, or at some point in the future:
>> <img style="content: replaced; background-color: ...;" />
>>
>> I'd proposed visibility: content-hidden; to be used with background 
>> and border.
>
> Why should we use inline-styles once again? Why should we load content 
> images with CSS? What about accessibility? Where to add alt-attribute 
> / title / ARIA etc.?
>

They're CSS styles, I'm using inline for demonstrative purposes.
I'd load images because the CSS <image> spec is more powerful than the 
HTML image spec,
offering things like -webkit-canvas (soon -element), various background 
sizing and fitting routines.

Accessibility is maintained exactly as it was, you'd put the alt 
attribute in the image tag.

(Continue reading)

Chris | 1 Sep 20:09 2011
Picon

remove

--

-- 
*Christopher Regan*
christo26@...* *(best)
(949) 600-0364 (cell)
(949) 484-9667 *Google Voice*
http://gplus.to/chrisregan *(Google+)* * *
http://wiki.webfoundation.org/Christopher_Regan *(Web Foundation)* *
*
http://www.indeed.com/r/ec81cfd49730a2fb *(Resume 03.11)*
http://www.facebook.com/chregan - *Facebook*
http://www.linkedin.com/in/christophermregan - *Linkedin*

Jonas Sicking | 1 Sep 20:13 2011

Re: Fixing undo on the Web - UndoManager and Transaction

On Thu, Sep 1, 2011 at 6:26 AM, Alex Vincent <ajvincent@...> wrote:
>   3. I just spotted a flaw in our API's.  Imagine the following:
>      -
>
>      myEditor.undoManager.transact({apply: function () {
> insert(document.createTextNode('o')) }, label: 'First transaction'});
>      myEditor.undoManager.transact({apply: function () {
> insert(document.createTextNode('k')) }, label: 'Merging transaction'},
> true);
>
>      - User calls myEditor.undoManager.item(0).label.  Which label does he
>      get back?  For that matter, which transaction does he get back, and which
>      transaction is forever hidden from him?
>      - Perhaps for this reason, .item() should return a readonly
>      Transaction[], representing the transaction group.

That's what we've been thinking for the Firefox implementation. It's
not a great solution though, but I can't think of a better one.

/ Jonas

Ryosuke Niwa | 1 Sep 20:36 2011

Re: Fixing undo on the Web - UndoManager and Transaction

On Thu, Sep 1, 2011 at 6:26 AM, Alex Vincent <ajvincent@...> wrote:
>
>   1. I think we should start writing a test suite, for two reasons.  First,
>   to get some idea how this works in practice, with a reference
> implementation
>   in JavaScript.  That will help us iron out some of the API debates we've
>   been having (reapply, specifically).  Second, a test suite can help all
> the
>   implementers implement the same thing.
>

Implementing it in JavaScript will be somewhat challenging because
managed/automatic transactions need to keep track of all changes made by a
function it's calling.  It'll require a heavy use of mutation events (and
they're going away!)

     myEditor.undoManager.transact({apply: function () {
> insert(document.createTextNode('o')) }, label: 'First transaction'});
>      myEditor.undoManager.transact({apply: function () {
> insert(document.createTextNode('k')) }, label: 'Merging transaction'},
> true);
>
>      - User calls myEditor.undoManager.item(0).label.  Which label does he
>      get back?  For that matter, which transaction does he get back, and
> which
>      transaction is forever hidden from him?
>

You get an array (should make it immutable) that contains both transactions.
So you get undefined.  But this behavior is stated in my working draft:
(Continue reading)