W3C home > Mailing lists > Public > www-style@w3.org > December 2015

Re: [css-snappoints] What if snapped element is much taller/wider than viewport?

From: Tab Atkins Jr. <jackalmage@gmail.com>
Date: Wed, 2 Dec 2015 17:28:42 -0800
Message-ID: <CAAWBYDBXoQeS1au04TNc7Xgofb7rEdUbfFbk0Gfrm7tn+H57=g@mail.gmail.com>
To: "Belov, Charles" <Charles.Belov@sfmta.com>
Cc: "www-style@w3.org" <www-style@w3.org>, fantasai <fantasai.lists@inkedblade.net>
On Wed, Dec 2, 2015 at 5:21 PM, Belov, Charles <Charles.Belov@sfmta.com> wrote:
> Tab Atkins Jr. wrote on Wednesday, December 02, 2015 10:07 AM
>>On Tue, Nov 24, 2015 at 4:22 PM, Belov, Charles <Charles.Belov@sfmta.com> wrote:
>>It might also be helpful to expand that to include the expected behavior for keyboard navigation.
>>> Perhaps something like:
>>[snip stuff about "don't return to the previous snap point if using arrow keys]
>>That's also already in the draft. ^_^
>><https://drafts.csswg.org/css-scroll-snap/#choosing>, 5th bullet point, starting with "User agents must ensure that a user can "escape"
>>a snap position, regardless of the scroll method.".
> Thank you, Tab. I would suggest removing
> "Instead, a smarter algorithm that only returned to the starting snap position if the end-point was a fairly small distance from it, and otherwise ignored the starting snap position, would give better behavior."
> as contrary to
> "User agents must ensure that a user can "escape" a snap position, regardless of the scroll method."
> for a single press of an up-arrow or down-arrow key.

Those are intended to be slightly contradicatory; there are multiple
conflicting desires in a good snapping implementation, which a UA has
to balance.

That said, if a keypress doesn't guarantee an escape, then it violates
the MUST-level requirement.  Keypresses are non-inertial, so if a
single keypress can't escape, multiple keypresses can't either.

> I sometimes press the up- or down-arrow only once or twice to reveal text that has been skipped by a Scroll Down or Scroll Up on a page that has part of the page covered by a stationary top or bottom navigation div.
> If I'm trying to only escape by a line or two, I don't want the browser second-guessing me that I didn't really mean to escape.

Ideally, future pages will use Flexbox or Grid so their top/bottom
navs actually take up space, rather than overlaying the content. ^_^

Received on Thursday, 3 December 2015 01:29:31 UTC

This archive was generated by hypermail 2.4.0 : Friday, 25 March 2022 10:08:58 UTC