forked from w3c/csswg-drafts
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathOverview.html
More file actions
726 lines (601 loc) · 49.1 KB
/
Overview.html
File metadata and controls
726 lines (601 loc) · 49.1 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
<!DOCTYPE html><html lang=en><head>
<meta content="text/html; charset=utf-8" http-equiv=Content-Type>
<title>CSS Scroll Snap Points Module Level 1</title>
<link href=../default.css rel=stylesheet type=text/css>
<link href=../csslogo.ico rel="shortcut icon" type=image/x-icon>
<style>
body {
background: url("https://www.w3.org/StyleSheets/TR/logo-ED") top left no-repeat white;
background-attachment: fixed;
color: black;
font-family: sans-serif;
margin: 0 auto;
max-width: 50em;
padding: 2em 1em 2em 70px;
}
:link { color: #00C; background: transparent }
:visited { color: #609; background: transparent }
a[href]:active { color: #C00; background: transparent }
a[href]:hover { background: #ffa }
a[href] img { border-style: none }
h1, h2, h3, h4, h5, h6 { text-align: left }
h1, h2, h3 { color: #005A9C; }
h1 { font: 170% sans-serif }
h2 { font: 140% sans-serif }
h3 { font: 120% sans-serif }
h4 { font: bold 100% sans-serif }
h5 { font: italic 100% sans-serif }
h6 { font: small-caps 100% sans-serif }
.hide { display: none }
div.head { margin-bottom: 1em }
div.head h1 { margin-top: 2em; clear: both }
div.head table { margin-left: 2em; margin-top: 2em }
p.copyright { font-size: small }
p.copyright small { font-size: small }
pre { margin-left: 2em }
dt { font-weight: bold }
ul.toc, ol.toc {
list-style: none;
}
</style>
</head>
<body class=h-entry>
<div class=head>
<p data-fill-with=logo><a class=logo href=http://www.w3.org/>
<img alt=W3C height=48 src=http://www.w3.org/Icons/w3c_home width=72>
</a>
</p>
<h1 class="p-name no-ref" id=title>CSS Scroll Snap Points Module Level 1</h1>
<h2 class="no-num no-toc no-ref heading settled heading" id=subtitle><span class=content>Editor’s Draft,
<span class=dt-updated><span class=value-title title=20140305>5 March 2014</span></span></span></h2>
<div data-fill-with=spec-metadata><dl><dt>This version:<dd><a class=u-url href=http://dev.w3.org/csswg/css-snappoints/>http://dev.w3.org/csswg/css-snappoints/</a><dt>Editor’s Draft:<dd><a href=http://dev.w3.org/csswg/css-snappoints/>http://dev.w3.org/csswg/css-snappoints/</a>
<dt>Feedback:</dt>
<dd><a href="mailto:www-style@w3.org?subject=%5Bcss-snappoints%5D%20feedback">www-style@w3.org</a>
with subject line
“<kbd>[css-snappoints] <var>… message topic …</var></kbd>”(<a href=http://lists.w3.org/Archives/Public/www-style/ rel=discussion>archives</a>)<dt>Test Suite:<dd>None Yet<dt>Editors:
<dd class="p-author h-card vcard"><span class="p-name fn">Matt Rakow</span> (<span class="p-org org">Microsoft</span>)<dd class="p-author h-card vcard"><span class="p-name fn">Jacob Rossi</span> (<span class="p-org org">Microsoft</span>)<dt>Issue Tracking:<dd><a href=http://wiki.csswg.org/spec/css-snappoints>http://wiki.csswg.org/spec/css-snappoints</a></dl></div>
<div data-fill-with=warning></div>
<p class=copyright data-fill-with=copyright><a href=http://www.w3.org/Consortium/Legal/ipr-notice#Copyright>Copyright</a> © 2014 <a href=http://www.w3.org/><abbr title="World Wide Web Consortium">W3C</abbr></a><sup>®</sup> (<a href=http://www.csail.mit.edu/><abbr title="Massachusetts Institute of Technology">MIT</abbr></a>, <a href=http://www.ercim.eu/><abbr title="European Research Consortium for Informatics and Mathematics">ERCIM</abbr></a>, <a href=http://www.keio.ac.jp/>Keio</a>, <a href=http://ev.buaa.edu.cn/>Beihang</a>), All Rights Reserved. W3C <a href=http://www.w3.org/Consortium/Legal/ipr-notice#Legal_Disclaimer>liability</a>, <a href=http://www.w3.org/Consortium/Legal/ipr-notice#W3C_Trademarks>trademark</a> and <a href=http://www.w3.org/Consortium/Legal/copyright-documents>document use</a> rules apply.
</p>
<hr title="Separator for header">
</div>
<h2 class="no-num no-toc no-ref heading settled heading" id=abstract><span class=content>Abstract</span></h2>
<p class=p-summary data-fill-with=abstract>This module contains features to control panning and scrolling behavior with "snap points".
<a href=http://www.w3.org/TR/CSS/>CSS</a> is a language for describing the rendering of structured documents
(such as HTML and XML)
on screen, on paper, in speech, etc.</p>
<h2 class="no-num no-toc no-ref heading settled heading" id=status><span class=content>Status of this document</span></h2>
<div data-fill-with=status><p>
This is a public copy of the editors’ draft.
It is provided for discussion only and may change at any moment.
Its publication here does not imply endorsement of its contents by W3C.
Don’t cite this document other than as work in progress.
<p>
The (<a href=http://lists.w3.org/Archives/Public/www-style/>archived</a>) public mailing list
<a href="mailto:www-style@w3.org?Subject=%5Bcss-snappoints%5D%20PUT%20SUBJECT%20HERE">www-style@w3.org</a>
(see <a href=http://www.w3.org/Mail/Request>instructions</a>)
is preferred for discussion of this specification.
When sending e-mail,
please put the text “css-snappoints” in the subject,
preferably like this:
“[css-snappoints] <em>…summary of comment…</em>”
<p>
This document was produced by the <a href=http://www.w3.org/Style/CSS/members>CSS Working Group</a>
(part of the <a href=http://www.w3.org/Style/>Style Activity</a>).
<p>
This document was produced by a group operating under
the <a href=http://www.w3.org/Consortium/Patent-Policy-20040205/>5 February 2004 W3C Patent Policy</a>.
W3C maintains a <a href=http://www.w3.org/2004/01/pp-impl/32061/status rel=disclosure>public list of any patent disclosures</a>
made in connection with the deliverables of the group;
that page also includes instructions for disclosing a patent.
An individual who has actual knowledge of a patent which the individual believes contains <a href=http://www.w3.org/Consortium/Patent-Policy-20040205/#def-essential>Essential Claim(s)</a>
must disclose the information in accordance with <a href=http://www.w3.org/Consortium/Patent-Policy-20040205/#sec-Disclosure>section 6 of the W3C Patent Policy</a>.</div>
<div data-fill-with=at-risk></div>
<h2 class="no-num no-toc no-ref heading settled heading" id=contents><span class=content>Table of Contents</span></h2>
<div data-fill-with=table-of-contents><ul class=toc>
<li><a href=#intro><span class=secno>1</span>Introduction</a>
<ul class=toc>
<li><a href=#placement><span class=secno>1.1</span>Module interactions</a>
<li><a href=#values><span class=secno>1.2</span>Values</a></ul>
<li><a href=#examples><span class=secno>2</span>Motivating Examples</a>
<li><a href=#definitions><span class=secno>3</span>Definitions</a>
<li><a href=#scroll-snap-type><span class=secno>4</span>Scroll Snap Types: the <span class=property data-link-type=propdesc title=scroll-snap-type>scroll-snap-type</span> property</a>
<li><a href=#scroll-snap-points><span class=secno>5</span>Scroll Snap Points: the <span class=property data-link-type=propdesc title=scroll-snap-points-x>scroll-snap-points-x</span> and <span class=property data-link-type=propdesc title=scroll-snap-points-y>scroll-snap-points-y</span> properties</a>
<li><a href=#scroll-snap-destination><span class=secno>6</span>Scroll Snap Destination: the <span class=property data-link-type=propdesc title=scroll-snap-destination>scroll-snap-destination</span> property</a>
<li><a href=#scroll-snap-coordinate><span class=secno>7</span>Scroll Snap Coordinate: the <span class=property data-link-type=propdesc title=scroll-snap-coordinate>scroll-snap-coordinate</span> property</a>
<li><a href=#CSSOM><span class=secno>8</span>CSSOM</a>
<li><a href=#acknowledgments><span class=secno></span>Acknowledgments</a>
<li><a href=#conformance><span class=secno></span> Conformance</a>
<ul class=toc>
<li><a href=#conventions><span class=secno></span> Document conventions</a>
<li><a href=#conformance-classes><span class=secno></span> Conformance classes</a>
<li><a href=#partial><span class=secno></span> Partial implementations</a>
<li><a href=#experimental><span class=secno></span> Experimental implementations</a>
<li><a href=#testing><span class=secno></span> Non-experimental implementations</a></ul>
<li><a href=#references><span class=secno></span> References</a>
<ul class=toc>
<li><a href=#normative><span class=secno></span> Normative References</a>
<li><a href=#informative><span class=secno></span> Informative References</a></ul>
<li><a href=#index><span class=secno></span> Index</a>
<li><a href=#property-index><span class=secno></span> Property index</a>
<li><a href=#issues-index><span class=secno></span>Issues Index</a></ul></div>
<h2 class="heading settled heading" data-level=1 id=intro><span class=secno>1 </span><span class=content>Introduction</span><a class=self-link href=#intro></a></h2>
<em>This section is not normative.</em>
Popular UX paradigms for scrollable content frequently employ paging through content,
or sectioning into logical divisions.
This is especially true for touch interactions
where it is quicker and easier for users to quickly pan through a flatly-arranged breadth of content
rather than delving into a heirarchical structure through tap navigation.
For example, it is easier for a user to view many photos in a photo album
by panning through a photo slideshow view
rather than tapping on individual photos in an album.
However, given the imprecise nature of scrolling inputs
like touch panning and mousewheel scrolling,
it is difficult for web developers to guarantee a well-controlled scrolling experience,
in particular creating the effect of paging through content.
For instance, it is easy for a user to land at an awkward scroll offset
which leaves a page partially on-screen when panning.
To this end, we introduce scroll snap points
which enforce the scroll offsets that a scroll container may end at
after a scrolling operation has completed.
<h3 class="heading settled heading" data-level=1.1 id=placement><span class=secno>1.1 </span><span class=content>Module interactions</span><a class=self-link href=#placement></a></h3>
This module extends the scrolling user interface features defined in <a data-biblio-type=normative data-link-type=biblio href=#css21 title=css21>[CSS21]</a> section 11.1.
None of the properties in this module apply to the <span class=css data-link-type=maybe title=::first-line>::first-line</span> and <span class=css data-link-type=maybe title=::first-letter>::first-letter</span> pseudo-elements.
<h3 class="heading settled heading" data-level=1.2 id=values><span class=secno>1.2 </span><span class=content>Values</span><a class=self-link href=#values></a></h3>
This specification follows the
<a href=http://www.w3.org/TR/CSS21/about.html#property-defs>CSS property
definition conventions</a> from <a data-biblio-type=normative data-link-type=biblio href=#css21 title=css21>[CSS21]</a>. Value types not defined in
this specification are defined in CSS Level 2 Revision 1 <a data-biblio-type=normative data-link-type=biblio href=#css21 title=css21>[CSS21]</a>.
Other CSS modules may expand the definitions of these value types: for
example <a data-biblio-type=informative data-link-type=biblio href=#css3val title=css3val>[CSS3VAL]</a>, when combined with this module, expands the
definition of the <a class="production css-code" data-link-type=type href=http://dev.w3.org/csswg/css-values-3/#length-value title="<length>"><length></a> value type as used in this specification.
<h2 class="heading settled heading" data-level=2 id=examples><span class=secno>2 </span><span class=content>Motivating Examples</span><a class=self-link href=#examples></a></h2>
<div class=example>
In this example, a series of images arranged in a <a data-link-type=dfn href=#scroll-container title="scroll container">scroll container</a>
are used to build a photo gallery.
The <a data-link-type=dfn href=#scroll-container title="scroll container">scroll container</a> is sized to the same size of the images contained therein.
Using mandatory snap points,
scrolling will always complete with a snap point aligned to the edge of the <a data-link-type=dfn href=#scroll-container title="scroll container">scroll container</a>.
By aligning a snap point at the edge of each image,
this creates a photo viewer were users can scroll through the images one at a time.
<pre>img {
width:500px;
}
.photoGallery {
width: 500px;
overflow-x: auto;
overflow-y: hidden;
white-space: nowrap;
/* Sets up points to which scrolling
will snap along x-axis */
scroll-snap-points-x: repeat(100%);
/* Requires that scrolling always end at a snap point when
the operation completes (hard snap) */
scroll-snap-type: mandatory;
}
</pre>
<pre> <div class="photoGallery">
<img src="img1.jpg">
<img src="img2.jpg">
<img src="img3.jpg">
<img src="img4.jpg">
<img src="img5.jpg">
</div>
</pre>
<figure>
<img alt="" src=interval_snap_points.png>
<figcaption>
The layout of the scroll container’s contents in the example.
Snap points are set along the x-axis,
starting at 0px and repeating at intervals of 100% of the scroll container’s width.
</figcaption>
</figure>
</div>
<div class=example>
This example also builds a photo gallery as in example 1. However, in this example the <a data-link-type=dfn href=#scroll-container title="scroll container">scroll container</a>
is larger than the photos contained within (such that multiple images may be seen simultaneously), and the image
sizes vary (such that a repeating snap interval would not be effective). Using mandatory element-based snap
points, scrolling will always complete with an image centered in the <a data-link-type=dfn href=#scroll-container title="scroll container">scroll container</a>.
<pre> img {
/* Defines the center of each photo as the
coordinate that should be used for snapping */
scroll-snap-coordinate: 50% 50%;
}
.photoGallery {
width: 500px;
overflow-x: auto;
overflow-y: hidden;
white-space: nowrap;
/* Denotes that snap points will be defined
by the elements contained within. */
scroll-snap-points-x: elements;
/* Specifies that each element’s snap coordinate should
align with the center of the scroll container */
scroll-snap-destination: 50% 50%;
/* Requires that scrolling always end at a snap point
when the operation completes (hard snap). */
scroll-snap-type: mandatory;
}
</pre>
<pre> <div class="photoGallery">
<img src="img1.jpg">
<img src="img2.jpg">
<img src="img3.jpg">
<img src="img4.jpg">
<img src="img5.jpg">
</div>
</pre>
<figure>
<img alt="" src=element_snap_points.png>
<figcaption>
The layout of the scroll container’s contents in the example.
The snap-destination is horizontally and vertically centered within the scroll container
(represented by a red X),
and each element has its snap coordinate horizontally and vertically centered within the element
(represented by yellow plus signs).
</figcaption>
</figure>
</div>
<div class=example>
This example builds a paginated document that aligns each page near to (but not exactly on) the edge of the <a data-link-type=dfn href=#scroll-container title="scroll container">scroll container</a>.
This allows the previous page to "peek" in from above in order to make the user aware that they are not yet at the top of the document.
Using proximity snap points instead of mandatory snap points allows the user to stop halfway through a page (rather than forcing them
to snap one page at a time). However, if a scrolling operation would finish near a snap point, then the scroll will be adjusted to
align the page as specified.
<pre> .page {
/* Defines the top center of each page as the
coordinate that should be used for snapping */
scroll-snap-coordinate: 50% 0;
}
.docScroller {
width: 500px;
overflow-x: hidden;
overflow-y: auto;
/* Denotes that snap points will be defined
by the elements contained within. */
scroll-snap-points-y: elements;
/* Specifies that each element’s snap coordinate should
align with the center of the scroll container, offset
a short distance from the top edge. */
scroll-snap-destination: 50% 100px;
/* Encourages scrolling to end at a snap point when the
operation completes, if it is near a snap point */
scroll-snap-type: proximity;
}
</pre>
<pre> <div class="docScroller">
<div class="page">Page 1</div>
<div class="page">Page 2</div>
<div class="page">Page 3</div>
<div class="page">Page 4</div>
</div>
</pre>
<figure>
<img alt="" src=element_snap_points_offset.png>
<figcaption>
The layout of the scroll container’s contents in the example.
The snap-destination is horizontally centered and offset 100px from the top edge with respect to the scroll container
(represented by a red X),
and each element has its snap coordinate horizontally centered and top-aligned with respect to the element
(represented by yellow plus signs).
</figcaption>
</figure>
</div>
<h2 class="heading settled heading" data-level=3 id=definitions><span class=secno>3 </span><span class=content>Definitions</span><a class=self-link href=#definitions></a></h2>
<dl>
<dt><dfn data-dfn-type=dfn data-export="" id=scroll-container>scroll container<a class=self-link href=#scroll-container></a></dfn>
<dd>
An element which provides a scrolling user interface as described in <a data-biblio-type=normative data-link-type=biblio href=#css21 title=css21>[CSS21]</a>, particularly in the section on overflow.
</dl>
<h2 class="heading settled heading" data-level=4 id=scroll-snap-type><span class=secno>4 </span><span class=content>Scroll Snap Types: the <a class=property data-link-type=propdesc href=#propdef-scroll-snap-type title=scroll-snap-type>scroll-snap-type</a> property</span><a class=self-link href=#scroll-snap-type></a></h2>
The <span class=css data-link-type=maybe title=scroll-snap-type>scroll-snap-type</span> property is used to define the physics characteristics of panning and scrolling, if any. It defines how and when snap points are enforced on the scroll container it is applied to.
<table class="definition propdef"><tr><th>Name:<td><dfn class=css-code data-dfn-type=property data-export="" id=propdef-scroll-snap-type>scroll-snap-type<a class=self-link href=#propdef-scroll-snap-type></a></dfn><tr><th>Value:<td class=prod>none | mandatory | proximity<tr><th>Initial:<td>none<tr><th>Applies to:<td><a data-link-type=dfn href=#scroll-container title="scroll containers">scroll containers</a><tr><th>Inherited:<td>no<tr><th>Media:<td>interactive<tr><th>Computed value:<td>specified value<tr><th>Percentages:<td>n/a<tr><th>Animatable:<td>no</table>
<dl data-dfn-for=scroll-snap-type data-dfn-type=value>
<dt><dfn class=css-code data-dfn-for=scroll-snap-type data-dfn-type=value data-export="" id=valuedef-none0>none<a class=self-link href=#valuedef-none0></a></dfn>
<dd>
This <a data-link-type=dfn href=#scroll-container title="scroll container">scroll container</a> must ignore snap points, if any, when scrolled.
<dt><dfn class=css-code data-dfn-for=scroll-snap-type data-dfn-type=value data-export="" id=valuedef-mandatory>mandatory<a class=self-link href=#valuedef-mandatory></a></dfn>
<dd>
This <a data-link-type=dfn href=#scroll-container title="scroll container">scroll container</a> must come to rest on a snap point at the termination of a scroll, if possible.
<dt><dfn class=css-code data-dfn-for=scroll-snap-type data-dfn-type=value data-export="" id=valuedef-proximity>proximity<a class=self-link href=#valuedef-proximity></a></dfn>
<dd>
This <a data-link-type=dfn href=#scroll-container title="scroll container">scroll container</a> may come to rest on a snap point at the termination of a scroll at the discretion of the UA given the parameters of the scroll.
</dl>
<p class=issue id=issue-c41d98db><a class=self-link href=#issue-c41d98db></a>
Could this be defined on a per-snap-point basis? What does it mean to mix types of snap points within a single scroller? Alternatively, should this be definable separately for each axis?
</p>
<p class=issue id=issue-79024523><a class=self-link href=#issue-79024523></a>
Need to consider the "snap-area" behavior described by fantasai. Maybe define this as repelling snap...lines? guardrails? bumpers? boundaries? limits? at the boundary?
</p>
<p class=issue id=issue-bc37a0a2><a class=self-link href=#issue-bc37a0a2></a>
If we do some behavior like snap-area, what happens when near an edge -- try to align with the edge or not?
</p>
<p class=issue id=issue-fa211d04><a class=self-link href=#issue-fa211d04></a>
What happens in zooming scenarios, e.g. if the images become larger than the viewport? Snapping makes less sense in this case. Is this addressable with a snap-area type of effect?
</p>
<p class=issue id=issue-b3745db4><a class=self-link href=#issue-b3745db4></a>
Consider naming conventions like in Grid Layout for grouping properties on the container vs. items.
</p>
<p class=issue id=issue-002270e1><a class=self-link href=#issue-002270e1></a>
Specify behavior of mandatory in a broader range of scenarios that induce scrolling or change content -- e.g. element is removed or moved. Does the scroller scroll to the nearest valid snap point?
</p>
<h2 class="heading settled heading" data-level=5 id=scroll-snap-points><span class=secno>5 </span><span class=content>Scroll Snap Points: the <a class=property data-link-type=propdesc href=#propdef-scroll-snap-points-x title=scroll-snap-points-x>scroll-snap-points-x</a> and <a class=property data-link-type=propdesc href=#propdef-scroll-snap-points-y title=scroll-snap-points-y>scroll-snap-points-y</a> properties</span><a class=self-link href=#scroll-snap-points></a></h2>
The <a class=property data-link-type=propdesc href=#propdef-scroll-snap-points-x title=scroll-snap-points-x>scroll-snap-points-x</a> and <a class=property data-link-type=propdesc href=#propdef-scroll-snap-points-y title=scroll-snap-points-y>scroll-snap-points-y</a> properties
are used to define the positioning of snap points
within the content of the <a data-link-type=dfn href=#scroll-container title="scroll container">scroll container</a> they are applied to,
or to declare the scroll container as snapping to elements.
<table class="definition propdef"><tr><th>Name:<td><dfn class=css-code data-dfn-type=property data-export="" id=propdef-scroll-snap-points-x>scroll-snap-points-x<a class=self-link href=#propdef-scroll-snap-points-x></a></dfn>, <dfn class=css-code data-dfn-type=property data-export="" id=propdef-scroll-snap-points-y>scroll-snap-points-y<a class=self-link href=#propdef-scroll-snap-points-y></a></dfn><tr><th>Value:<td class=prod>[ <a class="production css-code" data-link-type=type href=http://dev.w3.org/csswg/css-values-3/#length-value title="<length>"><length></a># ,]? repeat(<a class="production css-code" data-link-type=type href=http://dev.w3.org/csswg/css-values-3/#length-value title="<length>"><length></a>) | <a class="production css-code" data-link-type=type href=http://dev.w3.org/csswg/css-values-3/#length-value title="<length>"><length></a># | elements<tr><th>Initial:<td>repeat(100%)<tr><th>Applies to:<td><a data-link-type=dfn href=#scroll-container title="scroll containers">scroll containers</a><tr><th>Inherited:<td>no<tr><th>Media:<td>interactive<tr><th>Computed value:<td>specified value, with lengths made absolute<tr><th>Percentages:<td>relative to same axis of the padding-box of the <a data-link-type=dfn href=#scroll-container title="scroll container">scroll container</a><tr><th>Animatable:<td>no</table>
<dl data-dfn-for="snap-points-x, snap-points-y" data-dfn-type=value>
<dt><dfn class=css-code data-dfn-for="snap-points-x, snap-points-y" data-dfn-type=value data-export="" id=valuedef--length--repeatlength>[ <a class="production css-code" data-link-type=type href=http://dev.w3.org/csswg/css-values-3/#length-value title="<length>"><length></a># ,]? repeat(<a class="production css-code" data-link-type=type href=http://dev.w3.org/csswg/css-values-3/#length-value title="<length>"><length></a>)<a class=self-link href=#valuedef--length--repeatlength></a></dfn>
<dd>
Defines a list of starting snap points and an interval at which additional snap points are defined, starting from the final snap point of the list.
The first <a class="production css-code" data-link-type=type href=http://dev.w3.org/csswg/css-values-3/#length-value title="<length>"><length></a># list is the set of explicitly defined snap points, and the repeat(<a class="production css-code" data-link-type=type href=http://dev.w3.org/csswg/css-values-3/#length-value title="<length>"><length></a>) function defines the interval to repeat thereafter.
<dt><dfn class=css-code data-dfn-for="snap-points-x, snap-points-y" data-dfn-type=value data-export="" id=valuedef-length><a class="production css-code" data-link-type=type href=http://dev.w3.org/csswg/css-values-3/#length-value title="<length>"><length></a>+<a class=self-link href=#valuedef-length></a></dfn>
<dd>
Defines one or more discrete snap points for the <a data-link-type=dfn href=#scroll-container title="scroll container">scroll container</a>,
measured as lengths from the container’s relevant <a data-link-type=dfn href=http://dev.w3.org/csswg/css-writing-modes-3/#start title=start>start</a> edge.
<dt><dfn class=css-code data-dfn-for="snap-points-x, snap-points-y" data-dfn-type=value data-export="" id=valuedef-elements>elements<a class=self-link href=#valuedef-elements></a></dfn>
<dd>
Declares that the snap points for this scroll container
will be determined by the elements contained within.
In particular, by the combination of the element boxes' positions in layout
and their corresponding scroll-snap-coordinate properties,
in conjunction with this element’s scroll-snap-destination property.
</dl>
<p class=issue id=issue-7d8efa30><a class=self-link href=#issue-7d8efa30></a>
With the split-axis approach, the list and interval can result in unexpected behavior in 2d scrollers. For example, if you only want two diagonally-positioned snap points at (x1, y1) and (x2, y2), you will instead get (x1, y1), (x1, y2), (x2, y1), and (x2, y2).
</p>
<p class=issue id=issue-3fbc0017><a class=self-link href=#issue-3fbc0017></a>
Is the "elements" value needed? Is it important to avoid mixing list/interval with element snap points?
</p>
<p class=issue id=issue-c7020c45><a class=self-link href=#issue-c7020c45></a>
If we do stick with a value like "elements", is there a better name for it (e.g. if we can snap to non-elements like fragments).
</p>
<p class=issue id=issue-9038d543><a class=self-link href=#issue-9038d543></a>
Express as position instead of length unit?
</p>
<p class=issue id=issue-6e6e685f><a class=self-link href=#issue-6e6e685f></a>
Is the list format required, if we have element snapping? If yes, need a scenario justification. If no, remove.
</p>
<h2 class="heading settled heading" data-level=6 id=scroll-snap-destination><span class=secno>6 </span><span class=content>Scroll Snap Destination: the <a class=property data-link-type=propdesc href=#propdef-scroll-snap-destination title=scroll-snap-destination>scroll-snap-destination</a> property</span><a class=self-link href=#scroll-snap-destination></a></h2>
The <a class=property data-link-type=propdesc href=#propdef-scroll-snap-destination title=scroll-snap-destination>scroll-snap-destination</a> property is used to define the x and y coordinate within the <a data-link-type=dfn href=#scroll-container title="scroll container">scroll container</a>
which element snap points will align with
when the <a class=css data-link-type=maybe href=#valuedef-elements title=elements>elements</a> value is used for the <a class=property data-link-type=propdesc title=scroll-snap-points-*>scroll-snap-points-*</a> property.
<table class="definition propdef"><tr><th>Name:<td><dfn class=css-code data-dfn-type=property data-export="" id=propdef-scroll-snap-destination>scroll-snap-destination<a class=self-link href=#propdef-scroll-snap-destination></a></dfn><tr><th>Value:<td class=prod><a class="production css-code" data-link-type=type href=http://dev.w3.org/csswg/css-values-3/#length-value title="<length>"><length></a>{2}<tr><th>Initial:<td>0px<tr><th>Applies to:<td><a data-link-type=dfn href=#scroll-container title="scroll containers">scroll containers</a><tr><th>Inherited:<td>no<tr><th>Media:<td>interactive<tr><th>Computed value:<td>specified value, with lengths made absolute<tr><th>Percentages:<td>relative to width and height of the padding-box of the <a data-link-type=dfn href=#scroll-container title="scroll container">scroll container</a><tr><th>Animatable:<td>yes</table>
<dl data-dfn-for=scroll-snap-destination data-dfn-type=value>
<dt><dfn class=css-code data-dfn-for=scroll-snap-destination data-dfn-type=value data-export="" id=valuedef-length20><a class="production css-code" data-link-type=type href=http://dev.w3.org/csswg/css-values-3/#length-value title="<length>"><length></a>{2}<a class=self-link href=#valuedef-length20></a></dfn>
<dd>
Specifies the offset of the snap destination from the leading edge of the scroll container. The first value gives the x coordinate of the snap destination, the second value its y coordinate.
</dl>
<p class=issue id=issue-07abf187><a class=self-link href=#issue-07abf187></a>
Clarify "leading edge" -- want this to respond appropriately to writing modes
</p>
<h2 class="heading settled heading" data-level=7 id=scroll-snap-coordinate><span class=secno>7 </span><span class=content>Scroll Snap Coordinate: the <a class=property data-link-type=propdesc href=#propdef-scroll-snap-coordinate title=scroll-snap-coordinate>scroll-snap-coordinate</a> property</span><a class=self-link href=#scroll-snap-coordinate></a></h2>
The <a class=property data-link-type=propdesc href=#propdef-scroll-snap-coordinate title=scroll-snap-coordinate>scroll-snap-coordinate</a> property is used to define the x and y coordinate within the element
which will align with the nearest ancestor <a data-link-type=dfn href=#scroll-container title="scroll container’s">scroll container’s</a> snap-destination
when the <a class=css data-link-type=maybe href=#valuedef-elements title=elements>elements</a> value is used for the <a class=property data-link-type=propdesc title=scroll-snap-points-*>scroll-snap-points-*</a> property
of the nearest ancestor <a data-link-type=dfn href=#scroll-container title="scroll container’s">scroll container’s</a> respective axis.
<p class=issue id=issue-02f28956><a class=self-link href=#issue-02f28956></a>
How does this work with fragmentation?
</p>
<p class=issue id=issue-384369b3><a class=self-link href=#issue-384369b3></a>
Consider alternative naming besides "coordinate".
</p>
<table class="definition propdef"><tr><th>Name:<td><dfn class=css-code data-dfn-type=property data-export="" id=propdef-scroll-snap-coordinate>scroll-snap-coordinate<a class=self-link href=#propdef-scroll-snap-coordinate></a></dfn><tr><th>Value:<td class=prod>none | <a class="production css-code" data-link-type=type href=http://dev.w3.org/csswg/css-values-3/#length-value title="<length>"><length></a>{2}#<tr><th>Initial:<td>none<tr><th>Applies to:<td>all elements<tr><th>Inherited:<td>no<tr><th>Media:<td>interactive<tr><th>Computed value:<td>specified value, with lengths made absolute<tr><th>Percentages:<td>refer to the element box used by the box-sizing property<tr><th>Animatable:<td>yes</table>
<dl data-dfn-for=scroll-snap-coordinate data-dfn-type=value>
<dt><dfn class=css-code data-dfn-for=scroll-snap-coordinate data-dfn-type=value data-export="" id=valuedef-none>none<a class=self-link href=#valuedef-none></a></dfn>
<dd>
Specifies that this element does not contribute a snap point.
<dt><dfn class=css-code data-dfn-for=scroll-snap-coordinate data-dfn-type=value data-export="" id=valuedef-length2><a class="production css-code" data-link-type=type href=http://dev.w3.org/csswg/css-values-3/#length-value title="<length>"><length></a>{2}#<a class=self-link href=#valuedef-length2></a></dfn>
<dd>
Specifies the offset of the snap coordinates from the leading edge of the element box used by the box-sizing property. For each pairing, the first value gives the x coordinate of the snap coordinate, the second value its y coordinate.
</dl>
<p class=issue id=issue-7ebe3634><a class=self-link href=#issue-7ebe3634></a>
Don’t tie this to box-sizing.
</p>
<p class=issue id=issue-eac9b288><a class=self-link href=#issue-eac9b288></a>
Specify interaction with transforms.
</p>
<h2 class="heading settled heading" data-level=8 id=CSSOM><span class=secno>8 </span><span class=content>CSSOM</span><a class=self-link href=#CSSOM></a></h2>
<p class=issue id=issue-ee2d269c><a class=self-link href=#issue-ee2d269c></a>
Need to define how to read back points.
</p>
<p class=issue id=issue-4bbc5f72><a class=self-link href=#issue-4bbc5f72></a>
How to navigate directly to a snap point (e.g. with a hash or similar) -- e.g. enable direct linking to a specific page in a document
</p>
<p class=issue id=issue-49224241><a class=self-link href=#issue-49224241></a>
Supplementary APIs (e.g. snap-to-next, snap-to-previous, jump-to-N)
</p>
<h2 class="no-num heading settled heading" id=acknowledgments><span class=content>Acknowledgments</span><a class=self-link href=#acknowledgments></a></h2>
Many thanks to lots of people for their proposals and recommendations, some of which are incorporated into this document.
<h2 class="no-ref no-num heading settled heading" id=conformance><span class=content>
Conformance</span><a class=self-link href=#conformance></a></h2>
<h3 class="no-ref heading settled heading" id=conventions><span class=content>
Document conventions</span><a class=self-link href=#conventions></a></h3>
<p>Conformance requirements are expressed with a combination of
descriptive assertions and RFC 2119 terminology. The key words "MUST",
"MUST NOT", "REQUIRED", "SHALL", "SHALL NOT", "SHOULD", "SHOULD NOT",
"RECOMMENDED", "MAY", and "OPTIONAL" in the normative parts of this
document are to be interpreted as described in RFC 2119.
However, for readability, these words do not appear in all uppercase
letters in this specification.
<p>All of the text of this specification is normative except sections
explicitly marked as non-normative, examples, and notes. <a data-biblio-type=normative data-link-type=biblio href=#rfc2119 title=rfc2119>[RFC2119]</a></p>
<p>Examples in this specification are introduced with the words "for example"
or are set apart from the normative text with <code>class="example"</code>,
like this:
<div class=example>
<p>This is an example of an informative example.</p>
</div>
<p>Informative notes begin with the word "Note" and are set apart from the
normative text with <code>class="note"</code>, like this:
<p class=note>Note, this is an informative note.</p>
<h3 class="no-ref heading settled heading" id=conformance-classes><span class=content>
Conformance classes</span><a class=self-link href=#conformance-classes></a></h3>
<p>Conformance to this specification
is defined for three conformance classes:
<dl>
<dt>style sheet
<dd>A <a href=http://www.w3.org/TR/CSS21/conform.html#style-sheet>CSS
style sheet</a>.
<dt>renderer
<dd>A <a href=http://www.w3.org/TR/CSS21/conform.html#user-agent>UA</a>
that interprets the semantics of a style sheet and renders
documents that use them.
<dt>authoring tool
<dd>A <a href=http://www.w3.org/TR/CSS21/conform.html#user-agent>UA</a>
that writes a style sheet.
</dl>
<p>A style sheet is conformant to this specification
if all of its statements that use syntax defined in this module are valid
according to the generic CSS grammar and the individual grammars of each
feature defined in this module.
<p>A renderer is conformant to this specification
if, in addition to interpreting the style sheet as defined by the
appropriate specifications, it supports all the features defined
by this specification by parsing them correctly
and rendering the document accordingly. However, the inability of a
UA to correctly render a document due to limitations of the device
does not make the UA non-conformant. (For example, a UA is not
required to render color on a monochrome monitor.)
<p>An authoring tool is conformant to this specification
if it writes style sheets that are syntactically correct according to the
generic CSS grammar and the individual grammars of each feature in
this module, and meet all other conformance requirements of style sheets
as described in this module.
<h3 class="no-ref heading settled heading" id=partial><span class=content>
Partial implementations</span><a class=self-link href=#partial></a></h3>
<p>So that authors can exploit the forward-compatible parsing rules to
assign fallback values, CSS renderers <strong>must</strong>
treat as invalid (and <a href=http://www.w3.org/TR/CSS21/conform.html#ignore>ignore
as appropriate</a>) any at-rules, properties, property values, keywords,
and other syntactic constructs for which they have no usable level of
support. In particular, user agents <strong>must not</strong> selectively
ignore unsupported component values and honor supported values in a single
multi-value property declaration: if any value is considered invalid
(as unsupported values must be), CSS requires that the entire declaration
be ignored.</p>
<h3 class="no-ref heading settled heading" id=experimental><span class=content>
Experimental implementations</span><a class=self-link href=#experimental></a></h3>
<p>To avoid clashes with future CSS features, the CSS2.1 specification
reserves a <a href=http://www.w3.org/TR/CSS21/syndata.html#vendor-keywords>prefixed
syntax</a> for proprietary and experimental extensions to CSS.
<p>Prior to a specification reaching the Candidate Recommendation stage
in the W3C process, all implementations of a CSS feature are considered
experimental. The CSS Working Group recommends that implementations
use a vendor-prefixed syntax for such features, including those in
W3C Working Drafts. This avoids incompatibilities with future changes
in the draft.
</p>
<h3 class="no-ref heading settled heading" id=testing><span class=content>
Non-experimental implementations</span><a class=self-link href=#testing></a></h3>
<p>Once a specification reaches the Candidate Recommendation stage,
non-experimental implementations are possible, and implementors should
release an unprefixed implementation of any CR-level feature they
can demonstrate to be correctly implemented according to spec.
<p>To establish and maintain the interoperability of CSS across
implementations, the CSS Working Group requests that non-experimental
CSS renderers submit an implementation report (and, if necessary, the
testcases used for that implementation report) to the W3C before
releasing an unprefixed implementation of any CSS features. Testcases
submitted to W3C are subject to review and correction by the CSS
Working Group.
<p>Further information on submitting testcases and implementation reports
can be found from on the CSS Working Group’s website at
<a href=http://www.w3.org/Style/CSS/Test/>http://www.w3.org/Style/CSS/Test/</a>.
Questions should be directed to the
<a href=http://lists.w3.org/Archives/Public/public-css-testsuite>public-css-testsuite@w3.org</a>
mailing list.
<h2 class="no-num no-ref heading settled heading" id=references><span class=content>
References</span><a class=self-link href=#references></a></h2>
<h3 class="no-num no-ref heading settled heading" id=normative><span class=content>
Normative References</span><a class=self-link href=#normative></a></h3>
<div data-fill-with=normative-references><dl><dt id=css21 title=CSS21><a class=self-link href=#css21></a>[CSS21]<dd>Bert Bos; et al. <a href=http://www.w3.org/TR/2011/REC-CSS2-20110607>Cascading Style Sheets Level 2 Revision 1 (CSS 2.1) Specification</a>. 7 June 2011. W3C Recommendation. URL: <a href=http://www.w3.org/TR/2011/REC-CSS2-20110607>http://www.w3.org/TR/2011/REC-CSS2-20110607</a><dt id=rfc2119 title=RFC2119><a class=self-link href=#rfc2119></a>[RFC2119]<dd>S. Bradner. <a href=http://www.ietf.org/rfc/rfc2119.txt>Key words for use in RFCs to Indicate Requirement Levels</a>. URL: <a href=http://www.ietf.org/rfc/rfc2119.txt>http://www.ietf.org/rfc/rfc2119.txt</a></dl></div>
<h3 class="no-num no-ref heading settled heading" id=informative><span class=content>
Informative References</span><a class=self-link href=#informative></a></h3>
<div data-fill-with=informative-references><dl><dt id=css3val title=CSS3VAL><a class=self-link href=#css3val></a>[CSS3VAL]<dd>Håkon Wium Lie; Tab Atkins; Elika J. Etemad. <a href=http://www.w3.org/TR/2013/CR-css3-values-20130730/>CSS Values and Units Module Level 3</a>. 30 July 2013. W3C Candidate Recommendation. (Work in progress.) URL: <a href=http://www.w3.org/TR/2013/CR-css3-values-20130730/>http://www.w3.org/TR/2013/CR-css3-values-20130730/</a></dl></div>
<h2 class="no-num no-ref heading settled heading" id=index><span class=content>
Index</span><a class=self-link href=#index></a></h2>
<div data-fill-with=index><ul class=indexlist>
<li>elements, <a href=#valuedef-elements title="section 5">5</a>
<li><length>+, <a href=#valuedef-length title="section 5">5</a>
<li><length>{2}, <a href=#valuedef-length20 title="section 6">6</a>
<li><length>{2}#, <a href=#valuedef-length2 title="section 7">7</a>
<li>[ <length># ,]? repeat(<length>), <a href=#valuedef--length--repeatlength title="section 5">5</a>
<li>mandatory, <a href=#valuedef-mandatory title="section 4">4</a>
<li>none<ul><li>value for scroll-snap-type, <a href=#valuedef-none0 title="section 4">4</a>
<li>value for scroll-snap-coordinate, <a href=#valuedef-none title="section 7">7</a>
</ul><li>proximity, <a href=#valuedef-proximity title="section 4">4</a>
<li>scroll container, <a href=#scroll-container title="section 3">3</a>
<li>scroll-snap-coordinate, <a href=#propdef-scroll-snap-coordinate title="section 7">7</a>
<li>scroll-snap-destination, <a href=#propdef-scroll-snap-destination title="section 6">6</a>
<li>scroll-snap-points-x, <a href=#propdef-scroll-snap-points-x title="section 5">5</a>
<li>scroll-snap-points-y, <a href=#propdef-scroll-snap-points-y title="section 5">5</a>
<li>scroll-snap-type, <a href=#propdef-scroll-snap-type title="section 4">4</a>
</ul></div>
<h2 class="no-num no-ref heading settled heading" id=property-index><span class=content>
Property index</span><a class=self-link href=#property-index></a></h2>
<div data-fill-with=property-index><table class="proptable data"><thead><tr><th scope=col>Name<th scope=col>Value<th scope=col>Initial<th scope=col>Applies to<th scope=col>Inh.<th scope=col>%ages<th scope=col>Media<th scope=col>Animatable<th scope=col>Computed value<tbody>
<tr><th scope=row><a data-property="">scroll-snap-type</a><td>none | mandatory | proximity<td>none<td>scroll containers<td>no<td>n/a<td>interactive<td>no<td>specified value
<tr><th scope=row><a data-property="">scroll-snap-points-x</a><td>[ <length># ,]? repeat(<length>) | <length># | elements<td>repeat(100%)<td>scroll containers<td>no<td>relative to same axis of the padding-box of the scroll container<td>interactive<td>no<td>specified value, with lengths made absolute
<tr><th scope=row><a data-property="">scroll-snap-points-y</a><td>[ <length># ,]? repeat(<length>) | <length># | elements<td>repeat(100%)<td>scroll containers<td>no<td>relative to same axis of the padding-box of the scroll container<td>interactive<td>no<td>specified value, with lengths made absolute
<tr><th scope=row><a data-property="">scroll-snap-destination</a><td><length>{2}<td>0px<td>scroll containers<td>no<td>relative to width and height of the padding-box of the scroll container<td>interactive<td>yes<td>specified value, with lengths made absolute
<tr><th scope=row><a data-property="">scroll-snap-coordinate</a><td>none | <length>{2}#<td>none<td>all elements<td>no<td>refer to the element box used by the box-sizing property<td>interactive<td>yes<td>specified value, with lengths made absolute</table></div>
<h2 class="no-num heading settled" id=issues-index><span class=content>Issues Index</span><a class=self-link href=#issues-index></a></h2><div style="counter-reset: issue"><div class=issue>
Could this be defined on a per-snap-point basis? What does it mean to mix types of snap points within a single scroller? Alternatively, should this be definable separately for each axis?
<a href=#issue-c41d98db> ↵ </a></div>
<div class=issue>
Need to consider the "snap-area" behavior described by fantasai. Maybe define this as repelling snap...lines? guardrails? bumpers? boundaries? limits? at the boundary?
<a href=#issue-79024523> ↵ </a></div>
<div class=issue>
If we do some behavior like snap-area, what happens when near an edge -- try to align with the edge or not?
<a href=#issue-bc37a0a2> ↵ </a></div>
<div class=issue>
What happens in zooming scenarios, e.g. if the images become larger than the viewport? Snapping makes less sense in this case. Is this addressable with a snap-area type of effect?
<a href=#issue-fa211d04> ↵ </a></div>
<div class=issue>
Consider naming conventions like in Grid Layout for grouping properties on the container vs. items.
<a href=#issue-b3745db4> ↵ </a></div>
<div class=issue>
Specify behavior of mandatory in a broader range of scenarios that induce scrolling or change content -- e.g. element is removed or moved. Does the scroller scroll to the nearest valid snap point?
<a href=#issue-002270e1> ↵ </a></div>
<div class=issue>
With the split-axis approach, the list and interval can result in unexpected behavior in 2d scrollers. For example, if you only want two diagonally-positioned snap points at (x1, y1) and (x2, y2), you will instead get (x1, y1), (x1, y2), (x2, y1), and (x2, y2).
<a href=#issue-7d8efa30> ↵ </a></div>
<div class=issue>
Is the "elements" value needed? Is it important to avoid mixing list/interval with element snap points?
<a href=#issue-3fbc0017> ↵ </a></div>
<div class=issue>
If we do stick with a value like "elements", is there a better name for it (e.g. if we can snap to non-elements like fragments).
<a href=#issue-c7020c45> ↵ </a></div>
<div class=issue>
Express as position instead of length unit?
<a href=#issue-9038d543> ↵ </a></div>
<div class=issue>
Is the list format required, if we have element snapping? If yes, need a scenario justification. If no, remove.
<a href=#issue-6e6e685f> ↵ </a></div>
<div class=issue>
Clarify "leading edge" -- want this to respond appropriately to writing modes
<a href=#issue-07abf187> ↵ </a></div>
<div class=issue>
How does this work with fragmentation?
<a href=#issue-02f28956> ↵ </a></div>
<div class=issue>
Consider alternative naming besides "coordinate".
<a href=#issue-384369b3> ↵ </a></div>
<div class=issue>
Don’t tie this to box-sizing.
<a href=#issue-7ebe3634> ↵ </a></div>
<div class=issue>
Specify interaction with transforms.
<a href=#issue-eac9b288> ↵ </a></div>
<div class=issue>
Need to define how to read back points.
<a href=#issue-ee2d269c> ↵ </a></div>
<div class=issue>
How to navigate directly to a snap point (e.g. with a hash or similar) -- e.g. enable direct linking to a specific page in a document
<a href=#issue-4bbc5f72> ↵ </a></div>
<div class=issue>
Supplementary APIs (e.g. snap-to-next, snap-to-previous, jump-to-N)
<a href=#issue-49224241> ↵ </a></div>
</div>