On Aug 11, 2014 8:38 AM, "Peter Beverloo" <beverloo@google.com> wrote:
> On Mon, Aug 11, 2014 at 9:27 AM, Andrew Wilson <atwilson@google.com> wrote:
> You raise an interesting question. Given the following notification:
>
> var notification = new Notification('Title', {
> body: 'Hello, world!',
> icon: '/my-icon.png',
> items: [
> { title: 'Message 1', body: 'Contents of message 1' },
> { title: 'Message 2', body: 'Contents of message 2' },
> { title: 'Message 3', body: 'Contents of message 3' }
> ],
> buttons: [
> 'Reply',
> 'Reply to all',
> 'Forward'
> ],
> date: new Date('2014-08-11T16:35:00'),
> progress: 40
> });
>
> What do we expect to be displayed?
I agree, this is a very interesting question. My thinking had been
that this should be supported. But I hadn't thought of that not all
platforms that can render a progress bar can render one at the same
time as a bullet list, or a set of buttons.
And then there's of course the question how the above would be
rendered, I.e. does the progress bar go above or below the list? Or is
that UA defined.
Suggestions for how to deal with this is definitely welcome.
I think we can expect that the "date" is simply displayed next to the
notification. Just like the icon is. That's how every notification
system I can find do it. Dates really are more about adjusting UI
which is already there, rather than adding new UI. So I would expect
that to mix fine with all other types of data.
Buttons, progressbar and lists are indeed a problem though. Does
anyone know what limitations we have as far as platforms go?
At a first glance, it seems like we might be able to get away with
defining that buttons are always at the bottom, and progress bars are
just above buttons but below everything else. But quite possibly
things aren't that simple.
Lists are trickier. They even seem tricky on their own. Do they go
before or after the text body? It seems like you might even want to
have a list in with text both before and after. Or should we say that
you can't have lists at the same time as a text body?
/ Jonas