W3C home > Mailing lists > Public > www-style@w3.org > January 2016

RE: [css-snappoints][css-scrollsnap] Mandatory snap-points, and voluntarily unreachable content

From: François REMY <francois.remy.dev@outlook.com>
Date: Wed, 20 Jan 2016 18:56:20 -0800
Message-ID: <DUB408-EAS3897CC95694BBD494399143A5C30@phx.gbl>
To: "'Tab Atkins Jr.'" <jackalmage@gmail.com>
CC: "'www-style list'" <www-style@w3.org>
> > The intent is that the user can see the cross-fade background section when
> > scrolling, but should only snap to the beginning of a page when moving using
> > arrow keys or just when the scroll ends, as the margin are not meant to be
> > readable.
> >
> > Is that kind of experience possible to achieve under any of the currently-
> > proposed options?
> 
> Yes.  I presume that each of the panes will overlap each other (with negative
> margins?) and use transparency in their background to achieve the fade
> effect?  If so, then you just use scroll-snap-margin with negative values to
> shrink the snapping bounds of the element back to the desired rectangle,
> and align them however you wish - probably 'center'.  This doesn't actually
> invoke the "unreachable snap position" stuff, except maybe accidentally if
> there are rounding errors and the first element's snap position ends up
> technically slightly outside the scrollable area.  (This kind of possible accident
> is one of the reasons snapping to out-of-viewport positions is
> desirable.)

This looks like a good way to achieve this, though I was even willing to accept something simpler like using a local background on the scroller that would fit its dimension perfectly and have the cross-fade built-in into that background. In that case, I would have achieved this layout using a grid with gutters for the crossfade sections. 

The problem I have with both solutions and I'm not sure you addressed or not is that I'm afraid the spec may require browsers to allow to scroll this way, to make the gutter reachable (via keyboard navigation for instance):

    <see attachment>

I had the impression part of the discussion today was about allowing scrollers with mandatory snapping to stay at positions where there is no snap point if that was required to view some content. I'm fine with this as long as there is a way of making sure this does not happen in cases like this, where the gutters are only meant to be seen during a scroll-transition, not during a steady state. In summary, have "keyboard" unreachable content by design.



temp.png
(image/png attachment: temp.png)

Received on Thursday, 21 January 2016 02:56:54 UTC

This archive was generated by hypermail 2.4.0 : Friday, 17 January 2020 22:52:33 UTC