W3C home > Mailing lists > Public > public-css-archive@w3.org > June 2018

Re: [csswg-drafts] [css-scroll-snap] scroll-snap-align values assigned backwards

From: Majid Valipour via GitHub <sysbot+gh@w3.org>
Date: Mon, 25 Jun 2018 13:59:25 +0000
To: public-css-archive@w3.org
Message-ID: <issue_comment.created-399961633-1529935164-sysbot+gh@w3.org>
_Originally posted [here](https://bugs.chromium.org/p/chromium/issues/detail?id=854379#c4)._

I ran a query against httparchive database to better understand the compat risk. My exact query is below if anyone wants to replicate [1].

Only 4 were using the scroll-snap-align with two arguments. This is out of 450k pages so usage and breakage is very low AFAICT. This gives me more confidence to make the switch. We should ensure Safari is willing to make the switch to avoid interop issues.

Here is the result:

|bodies_page |match | bodies_url|		
|----------------- |---------|---------------|
|http://www.scrimba.com/	     | scroll-snap-align:center none;	| https://scrimba.com/assets/cached-client-fab8900c04b0f8f240d73f6c6a561770.css|		
|http://www.participate.com/  | scroll-snap-align: 0 50px;	| https://www.participate.com/webpack/style-fe837b4781471be76fc4b0b20871f197.css|		
|http://www.zikinf.com/	     | scroll-snap-align:center none;	| https://www.zikinf.com//_css/default/wk/annonces.1513606238.css|		
|http://www.chuzefitness.com/ | scroll-snap-align: none start;	| https://chuzefitness.com/wp-content/themes/chuze-reflex/css/theme.css?ver=1.5.5|		


Note that one of the cases is actually using it incorrectly.


[1] BigQuery query:

SELECT bodies.page, REGEXP_EXTRACT(bodies.body, r'(scroll-snap-align:\s*\w+?\s+\w+?\s*;)') as match, bodies.url, 
  FROM [httparchive:har.2018_02_01_chrome_requests_bodies]
  AS bodies
JOIN (
  SELECT 
    page, url,
    JSON_EXTRACT(payload, '$._contentType') AS contentType
  FROM [httparchive:har.2018_02_01_chrome_requests]
) AS requests ON requests.url=bodies.url AND requests.page=bodies.page
WHERE (requests.contentType CONTAINS 'html' OR requests.contentType CONTAINS 'css')
AND REGEXP_MATCH(body, r'(scroll-snap-align:\s*\w+?\s+\w+?\s*;)')
LIMIT 10000



-- 
GitHub Notification of comment by majido
Please view or discuss this issue at https://github.com/w3c/csswg-drafts/issues/2232#issuecomment-399961633 using your GitHub account
Received on Monday, 25 June 2018 13:59:28 UTC

This archive was generated by hypermail 2.3.1 : Monday, 25 June 2018 13:59:32 UTC