Changeset 272742 in webkit


Ignore:
Timestamp:
Feb 11, 2021, 11:33:25 AM (5 years ago)
Author:
commit-queue@webkit.org
Message:

scroll-snap demo should use new spec
https://bugs.webkit.org/show_bug.cgi?id=184046

Patch by Martin Robinson <mrobinson@igalia.com> on 2021-02-11
Reviewed by Wenson Hsieh.

Update the scroll-snap demo to reflect the modern specification. This
demo isn't currently linked from the site, but if it's every linked again
it will now reflect the current specification.

This maintains the old CSS so that the demo continues to work with
old versions of Safari.

  • demos/scroll-snap/index.html: Update the descriptions in the demo to reflect

the newest version of the specification.

Location:
trunk/Websites/webkit.org
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/Websites/webkit.org/ChangeLog

    r272089 r272742  
     12021-02-11  Martin Robinson  <mrobinson@igalia.com>
     2
     3        scroll-snap demo should use new spec
     4        https://bugs.webkit.org/show_bug.cgi?id=184046
     5
     6        Reviewed by Wenson Hsieh.
     7
     8        Update the scroll-snap demo to reflect the modern specification. This
     9        demo isn't currently linked from the site, but if it's every linked again
     10        it will now reflect the current specification.
     11
     12        This maintains the old CSS so that the demo continues to work with
     13        old versions of Safari.
     14
     15        * demos/scroll-snap/index.html: Update the descriptions in the demo to reflect
     16        the newest version of the specification.
     17
    1182021-01-29  Beth Dakin  <bdakin@apple.com>
    219
  • trunk/Websites/webkit.org/demos/scroll-snap/index.html

    r211282 r272742  
    292292        </div>
    293293        <p>The CSS for the above container is:</p>
    294         <pre>-webkit-scroll-snap-type: mandatory;<br>-webkit-scroll-snap-points-x: repeat(100%);</pre>
     294        <pre>scroll-snap-type: x mandatory;</pre>
     295        <p>The CSS for each of the container&rsquo;s children is:</p>
     296        <pre>scroll-snap-align: start;</pre>
    295297
    296298        <!-- Scroll snapping container using coordinates -->
     
    350352        </div>
    351353        <p>The CSS for the above container is:</p>
    352         <pre>-webkit-scroll-snap-type: mandatory;</pre>
     354        <pre>scroll-snap-type: x mandatory;</pre>
    353355        <p>The CSS for each of the container&rsquo;s children is:</p>
    354         <pre>-webkit-scroll-snap-coordinate: 0% 0%;</pre>
     356        <pre>scroll-snap-align: start;</pre>
    355357
    356358        <!-- Centered scroll snapping container using coordinates -->
     
    410412        </div>
    411413        <p>The CSS for the above container is:</p>
    412         <pre>-webkit-scroll-snap-type: mandatory;<br>-webkit-scroll-snap-destination: 50% 50%;</pre>
     414        <pre>scroll-snap-type: x mandatory;</pre>
    413415        <p>The CSS for each of the container&rsquo;s children is:</p>
    414         <pre>-webkit-scroll-snap-coordinate: 50% 50%;</pre>
     416        <pre>scroll-snap-align: center;</pre>
    415417
    416418        <!-- Centered scroll snapping container in 2D -->
     
    424426        </div>
    425427        <p>The CSS for the above container is:</p>
    426         <pre>-webkit-scroll-snap-type: mandatory;<br>-webkit-scroll-snap-destination: 50% 50%;</pre>
     428        <pre>scroll-snap-type: both mandatory;</pre>
    427429        <p>The CSS for each of the container&rsquo;s children is:</p>
    428         <pre>-webkit-scroll-snap-coordinate: 50% 50%;</pre>
     430        <pre>scroll-snap-align: center;</pre>
    429431
    430432        <!-- Centered scroll snapping container in 2D, rotated -->
     
    438440        </div>
    439441        <p>The CSS for the above container is:</p>
    440         <pre>-webkit-scroll-snap-type: mandatory;<br>-webkit-scroll-snap-destination: 50% 50%;<br>-webkit-transform: rotate(30deg);</pre>
     442        <pre>scroll-snap-type: both mandatory;<br>transform: rotate(30deg);</pre>
    441443        <p>The CSS for each of the container&rsquo;s children is:</p>
    442         <pre>-webkit-scroll-snap-coordinate: 50% 50%;</pre>
     444        <pre>scroll-snap-align: center;</pre>
    443445
    444446        <p id="nasa">Images from <a target="_blank" href="https://www.nasa.gov/multimedia/imagegallery/iotd.html">NASA&rsquo;s image of the day gallery</a>.</p>
Note: See TracChangeset for help on using the changeset viewer.