You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: css-snappoints/Overview.bs
+30-30Lines changed: 30 additions & 30 deletions
Original file line number
Diff line number
Diff line change
@@ -259,9 +259,37 @@ Issue: <b>This spec is currently undergoing major changes in line with the resol
259
259
260
260
This property is a shorthand property that sets all of the 'scroll-snap-padding-*' longhands in one declaration.
261
261
262
-
<h3 id="scroll-snap-align">Scroll Snap Align: the 'scroll-snap-align' property</h3>
262
+
<h2 id="properties-on-the-elements">Properties on the elements</h2>
263
+
264
+
<h3 id="scroll-snap-margin">Scroll Snap Margin: the 'scroll-snap-margin' property</h3>
265
+
266
+
The 'scroll-snap-margin' property defines the <a>scroll snap margin</a> on elements within a <a>scroll container</a>, used in calculating <a>snap positions</a> for that scroll container.
267
+
268
+
<pre class="propdef">
269
+
Name: scroll-snap-margin
270
+
Value: <<length>>{1,4}
271
+
Initial: 0
272
+
Applies to: all elements
273
+
Inherited: no
274
+
Percentages: n/a
275
+
Media: interactive
276
+
Computed value: as specified, with lengths made absolute
277
+
Animatable: yes
278
+
</pre>
279
+
280
+
<dl dfn-type=value dfn-for="scroll-snap-margin">
281
+
<dt><dfn><<length>>{1,4}</dfn>
282
+
<dd>
283
+
Specifies the outset of the element's snap margin from the axis-aligned bounding box of the transformed border box, in the <a>scroll container's</a> coordinate space. Outsets are applied to this bounding box, not the border box.
284
+
285
+
Note: This ensures that the <a>scroll snap margin</a> is always rectangular and axis-aligned to the <a>scroll container's</a> coordinate space.
286
+
</dl>
287
+
288
+
This property is a shorthand property that sets all of the 'scroll-snap-margin-*' longhands in one declaration.
289
+
290
+
<h3 id="scroll-snap-align">Scroll Snap Alignment: the 'scroll-snap-align' property</h3>
263
291
264
-
The 'scroll-snap-align' property specifies how a scroll container's region specified by 'scroll-snap-padding'should align with descendent elements' scroll snap margin. The two values specify the snapping behavior in the x and y axes, respectively. If only one value is specified, the second value defaults to the same value.
292
+
The 'scroll-snap-align' property specifies how an element's scrollsnap margin should align with its ancestor scroll container's snap alignment container. The two values specify the snapping behavior in the x and y axes, respectively. If only one value is specified, the second value defaults to the same value.
265
293
266
294
Issue: Should this be x/y axes, or inline/block? Starting with x/y axes for consistency with padding/area, otherwise a writing mode change would result in a axis mismatch (since padding is physical by default).
267
295
@@ -295,34 +323,6 @@ Issue: <b>This spec is currently undergoing major changes in line with the resol
295
323
The scroll offset which aligns the center of this box's scroll snap margin with the center of its ancestor scroll container's region defined by 'scroll-snap-padding' in the specified axis is a <a>snap position</a> in that axis.
296
324
</dl>
297
325
298
-
<h2 id="properties-on-the-elements">Properties on the elements</h2>
299
-
300
-
<h3 id="scroll-snap-margin">Scroll Snap Margin: the 'scroll-snap-margin' property</h3>
301
-
302
-
The 'scroll-snap-margin' property defines the <a>scroll snap margin</a> on elements within a <a>scroll container</a>, used in calculating <a>snap positions</a> for that scroll container.
303
-
304
-
<pre class="propdef">
305
-
Name: scroll-snap-margin
306
-
Value: <<length>>{1,4}
307
-
Initial: 0
308
-
Applies to: all elements
309
-
Inherited: no
310
-
Percentages: n/a
311
-
Media: interactive
312
-
Computed value: as specified, with lengths made absolute
313
-
Animatable: yes
314
-
</pre>
315
-
316
-
<dl dfn-type=value dfn-for="scroll-snap-margin">
317
-
<dt><dfn><<length>>{1,4}</dfn>
318
-
<dd>
319
-
Specifies the outset of the element's snap margin from the axis-aligned bounding box of the transformed border box, in the <a>scroll container's</a> coordinate space. Outsets are applied to this bounding box, not the border box.
320
-
321
-
Note: This ensures that the <a>scroll snap margin</a> is always rectangular and axis-aligned to the <a>scroll container's</a> coordinate space.
322
-
</dl>
323
-
324
-
This property is a shorthand property that sets all of the 'scroll-snap-margin-*' longhands in one declaration.
0 commit comments