Re: Shadow DOM and Fallback contents for images

2013-10-30 Thread Boris Zbarsky
On 10/30/13 5:56 PM, Ryosuke Niwa wrote: Interesting. Could you point me to the part of the spec. that mandates this behavior? http://www.whatwg.org/specs/web-apps/current-work/multipage/rendering.html#images-0 says: When an img element represents some text and the user agent does not

Re: Shadow DOM and Fallback contents for images

2013-10-30 Thread Ryosuke Niwa
On Oct 29, 2013, at 6:04 PM, Boris Zbarsky wrote: > On 10/14/13 12:11 AM, Ryosuke Niwa wrote: >> If I'm not mistaken, how alternative text is presented is up to UA vendors. > > You're mistaken. The HTML spec actually defines the behavior here, in > standards mode: it's presented as text inside

Re: Shadow DOM and Fallback contents for images

2013-10-29 Thread Boris Zbarsky
On 10/14/13 12:11 AM, Ryosuke Niwa wrote: If I'm not mistaken, how alternative text is presented is up to UA vendors. You're mistaken. The HTML spec actually defines the behavior here, in standards mode: it's presented as text inside a non-replaced inline (effectively as if content: attr(alt)

Re: Shadow DOM and Fallback contents for images

2013-10-18 Thread Ryosuke Niwa
On Oct 17, 2013, at 10:57 PM, Hayato Ito wrote: > I am aware that there are issues related to selections regarding Shadow DOM > both in the spec and the implementation. > But I don't have a clear answer to resolve that and couldn't satisfy users. > This is one of the toughest issues, I think.

Re: Shadow DOM and Fallback contents for images

2013-10-17 Thread Hayato Ito
I am aware that there are issues related to selections regarding Shadow DOM both in the spec and the implementation. But I don't have a clear answer to resolve that and couldn't satisfy users. This is one of the toughest issues, I think. Some of us have already started to tackle this issue. We had

Re: Shadow DOM and Fallback contents for images

2013-10-17 Thread Hajime Morrita
B looks fine. We don't have to rush into the API addition though. The API is just a shortcut of a tree traversal and easy to polyfill. It won't too late to design this after hearing some concrete usecases. Also, we need to extend this rough idea to take reprojection ( and ) into account. I hope pr

Re: Shadow DOM and Fallback contents for images

2013-10-17 Thread Jonas Sicking
On Oct 17, 2013 6:48 PM, "Hajime Morrita" wrote: > > > > > On Fri, Oct 18, 2013 at 3:56 AM, Jonas Sicking wrote: >> >> On Thu, Oct 17, 2013 at 1:55 AM, Hajime Morrita wrote: >> > >> > >> > >> > On Thu, Oct 17, 2013 at 5:01 PM, Ryosuke Niwa wrote: >> >> >> >> On Oct 16, 2013, at 9:47 PM, Hajime

Re: Shadow DOM and Fallback contents for images

2013-10-17 Thread Hajime Morrita
On Fri, Oct 18, 2013 at 3:56 AM, Jonas Sicking wrote: > On Thu, Oct 17, 2013 at 1:55 AM, Hajime Morrita > wrote: > > > > > > > > On Thu, Oct 17, 2013 at 5:01 PM, Ryosuke Niwa wrote: > >> > >> On Oct 16, 2013, at 9:47 PM, Hajime Morrita wrote: > >> > >> D. "H[ello Shado]w World" - selection spa

Re: Shadow DOM and Fallback contents for images

2013-10-17 Thread Jonas Sicking
On Thu, Oct 17, 2013 at 12:24 PM, Travis Leithead wrote: > From: Jonas Sicking [mailto:jo...@sicking.cc] > >> Though I'd also be interested to hear how other implementations feel about >> the Gecko solution of allowing selection to be comprised of multiple DOM >> Ranges. > > Seems totally reason

RE: Shadow DOM and Fallback contents for images

2013-10-17 Thread Travis Leithead
From: Jonas Sicking [mailto:jo...@sicking.cc] > Though I'd also be interested to hear how other implementations feel about > the Gecko solution of allowing selection to be comprised of multiple DOM > Ranges. Seems totally reasonable; only problem is that pretty much all content on the web ass

Re: Shadow DOM and Fallback contents for images

2013-10-17 Thread Jonas Sicking
On Thu, Oct 17, 2013 at 1:55 AM, Hajime Morrita wrote: > > > > On Thu, Oct 17, 2013 at 5:01 PM, Ryosuke Niwa wrote: >> >> On Oct 16, 2013, at 9:47 PM, Hajime Morrita wrote: >> >> D. "H[ello Shado]w World" - selection spans outside to inside. >> >> >> Suppose we allowed this selection. Then how d

Re: Shadow DOM and Fallback contents for images

2013-10-17 Thread Jonas Sicking
On Wed, Oct 16, 2013 at 9:47 PM, Hajime Morrita wrote: > This is not allowed: > > D. "H[ello Shado]w World" - selection spans outside to inside. This is not acceptable to me. Users should not be affected by the fact that a piece of UI is implemented using shadow DOM rather than using just "normal

Re: Shadow DOM and Fallback contents for images

2013-10-17 Thread Hajime Morrita
On Thu, Oct 17, 2013 at 5:01 PM, Ryosuke Niwa wrote: > On Oct 16, 2013, at 9:47 PM, Hajime Morrita wrote: > > D. "H[ello Shado]w World" - selection spans outside to inside. > > > Suppose we allowed this selection. Then how does one go about pasting this > content elsewhere? > > Most likely, what

Re: Shadow DOM and Fallback contents for images

2013-10-17 Thread Ryosuke Niwa
On Oct 16, 2013, at 9:47 PM, Hajime Morrita wrote: > D. "H[ello Shado]w World" - selection spans outside to inside. Suppose we allowed this selection. Then how does one go about pasting this content elsewhere? Most likely, whatever other content editable area, mail client, or some random app (

Re: Shadow DOM and Fallback contents for images

2013-10-16 Thread Hajime Morrita
Talking over an example might help... "Hello " #shadowroot "Shadow" " World" This renders text "Hello Shadow World". In my understanding, following patterns of selections are allowed: A. "H[ell]o Shadow World" - selection stays outside shadow B.

Re: Shadow DOM and Fallback contents for images

2013-10-16 Thread Jonas Sicking
On Oct 16, 2013 8:04 PM, "Ryosuke Niwa" wrote: > > On Oct 16, 2013, at 5:14 PM, Jonas Sicking wrote: > > > On Tue, Oct 15, 2013 at 12:04 PM, Ryosuke Niwa wrote: > >> On Oct 13, 2013, at 9:19 PM, Jonas Sicking wrote: > >> > >>> On Sun, Oct 13, 2013 at 9:11 PM, Ryosuke Niwa wrote: > On Oct

Re: Shadow DOM and Fallback contents for images

2013-10-16 Thread Ryosuke Niwa
On Oct 16, 2013, at 5:14 PM, Jonas Sicking wrote: > On Tue, Oct 15, 2013 at 12:04 PM, Ryosuke Niwa wrote: >> On Oct 13, 2013, at 9:19 PM, Jonas Sicking wrote: >> >>> On Sun, Oct 13, 2013 at 9:11 PM, Ryosuke Niwa wrote: On Oct 11, 2013, at 10:52 PM, Jonas Sicking wrote: > On Fr

Re: Shadow DOM and Fallback contents for images

2013-10-16 Thread Jonas Sicking
On Tue, Oct 15, 2013 at 2:39 AM, Hajime Morrita wrote: > The text in shadows are select-able, and it behaves kind of like iframes as > Ryosuke mentioned. > > I'm not sure if these are clear from the current draft, but points are: > > - Users can select a part of the shadow tree. > > - If selected

Re: Shadow DOM and Fallback contents for images

2013-10-16 Thread Jonas Sicking
On Tue, Oct 15, 2013 at 12:04 PM, Ryosuke Niwa wrote: > On Oct 13, 2013, at 9:19 PM, Jonas Sicking wrote: > >> On Sun, Oct 13, 2013 at 9:11 PM, Ryosuke Niwa wrote: >>> On Oct 11, 2013, at 10:52 PM, Jonas Sicking wrote: >>> On Fri, Oct 11, 2013 at 10:23 PM, Ryosuke Niwa wrote: > On Oct

Re: Shadow DOM and Fallback contents for images

2013-10-15 Thread Ryosuke Niwa
On Oct 13, 2013, at 9:19 PM, Jonas Sicking wrote: > On Sun, Oct 13, 2013 at 9:11 PM, Ryosuke Niwa wrote: >> On Oct 11, 2013, at 10:52 PM, Jonas Sicking wrote: >> >>> On Fri, Oct 11, 2013 at 10:23 PM, Ryosuke Niwa wrote: On Oct 7, 2013, at 1:38 PM, Jonas Sicking wrote: On Oct

Re: Shadow DOM and Fallback contents for images

2013-10-15 Thread Hajime Morrita
The text in shadows are select-able, and it behaves kind of like iframes as Ryosuke mentioned. I'm not sure if these are clear from the current draft, but points are: - Users can select a part of the shadow tree. - If selected range is in a shadow tree, it isn't accessible (in API sense) outside

Re: Shadow DOM and Fallback contents for images

2013-10-13 Thread Jonas Sicking
On Sun, Oct 13, 2013 at 9:11 PM, Ryosuke Niwa wrote: > On Oct 11, 2013, at 10:52 PM, Jonas Sicking wrote: > >> On Fri, Oct 11, 2013 at 10:23 PM, Ryosuke Niwa wrote: >>> On Oct 7, 2013, at 1:38 PM, Jonas Sicking wrote: >>> >>> On Oct 7, 2013 6:56 AM, "Hajime Morrita" wrote: Hi, >

Re: Shadow DOM and Fallback contents for images

2013-10-13 Thread Ryosuke Niwa
On Oct 11, 2013, at 10:52 PM, Jonas Sicking wrote: > On Fri, Oct 11, 2013 at 10:23 PM, Ryosuke Niwa wrote: >> On Oct 7, 2013, at 1:38 PM, Jonas Sicking wrote: >> >> On Oct 7, 2013 6:56 AM, "Hajime Morrita" wrote: >>> >>> Hi, >>> >>> I'm sorry that I didn't notice that you were talking about

Re: Shadow DOM and Fallback contents for images

2013-10-11 Thread Jonas Sicking
On Fri, Oct 11, 2013 at 10:23 PM, Ryosuke Niwa wrote: > On Oct 7, 2013, at 1:38 PM, Jonas Sicking wrote: > > On Oct 7, 2013 6:56 AM, "Hajime Morrita" wrote: >> >> Hi, >> >> I'm sorry that I didn't notice that you were talking about UA shadow DOM. >> It's an implementation detail and the standard

Re: Shadow DOM and Fallback contents for images

2013-10-11 Thread Ryosuke Niwa
On Oct 7, 2013, at 1:38 PM, Jonas Sicking wrote: > On Oct 7, 2013 6:56 AM, "Hajime Morrita" wrote: > > > > Hi, > > > > I'm sorry that I didn't notice that you were talking about UA shadow DOM. > > It's an implementation detail and the standard won't care about that. > > > > That being said, it m

Re: Shadow DOM and Fallback contents for images

2013-10-07 Thread Jonas Sicking
On Oct 7, 2013 6:56 AM, "Hajime Morrita" wrote: > > Hi, > > I'm sorry that I didn't notice that you were talking about UA shadow DOM. It's an implementation detail and the standard won't care about that. > > That being said, it might be a good exercise to think about feasibility to implement -like

Re: Shadow DOM and Fallback contents for images

2013-10-07 Thread Hajime Morrita
Hi, I'm sorry that I didn't notice that you were talking about UA shadow DOM. It's an implementation detail and the standard won't care about that. That being said, it might be a good exercise to think about feasibility to implement -like custom element which supports alternate text. 1. Selectio