[whatwg] Notifications: usage feedback

Anne van Kesteren annevk at annevk.nl
Tue Nov 19 05:37:06 PST 2013


On Tue, Oct 29, 2013 at 3:51 PM, Jonas Sicking <jonas at sicking.cc> wrote:
> On Tue, Oct 29, 2013 at 8:26 AM, Anne van Kesteren <annevk at annevk.nl> wrote:
>> That seems like an implementation detail. Activation could mean
>> dismissal, but e.g. on Mac OS X activation does not mean dismissal.
>> It's up to the site/app to dismiss after activation and sometimes they
>> decide to keep the notification around for a bit.
>
> That sounds unlikely to work in practice. I.e. I would expect pages to
> break if some implementations fire onclose and others do not. Is there
> a reason not to forbid firing onclose if onclick has been fired. Keep
> in mind that the implementation can always hide the notification or
> not independently of if it has fired onclose or not.

Unless we force all notification platforms to be identical, I don't
think we can require any particular behavior here. It's like double
click, some platforms have it, others don't. Some notification
platforms will remove the notification once clicked (and be required
to fire close in addition to click) and in others it'll remain open
(and only click will be fired).


>>> This may be part of just further defining the steps for the "click"
>>> pathway in the spec, but at least in FirefoxOS right now, the
>>> notification onclick pathway does not bring the app to the visible
>>> front in all cases. The email app has to do some extra document.hidden
>>> checking and try to bring itself to the front.
>>
>> That seems like a UI detail we cannot really say anything about in the
>> specification.
>
> Again, this seems unlikely to work in practice. I.e. I would expect
> that authors would expect one behavior (likely the behavior of
> whatever platform they are developing on) and that things would break
> when the website is used on platforms that has the other behavior.
>
> I suspect allowing the author to choose behavior here is going to work
> more reliably.

What are you thinking of? We define some kind of UI hints a developer
can register for when initiating a new notification? Might work I
suppose.


-- 
http://annevankesteren.nl/



More information about the whatwg mailing list