prop-for-that 0.7.5 → 0.7.6
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +10 -0
- package/dist/head.cjs +1 -1
- package/dist/head.global.js +1 -1
- package/dist/head.js +1 -1
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -8,6 +8,16 @@ backwards-compatible change (semver's `1.0.0`+ rules kick in at v1).
|
|
|
8
8
|
Only the published library (`dist/`) is versioned here; the demo and docs site
|
|
9
9
|
are repo-only and not part of the npm package.
|
|
10
10
|
|
|
11
|
+
## [0.7.6]
|
|
12
|
+
|
|
13
|
+
### Fixed
|
|
14
|
+
- **`head` scrollbar probe** — `--const-scrollbar-w` and `--const-scrollbar-thin-w`
|
|
15
|
+
could report the *same* value on classic (non-overlay) scrollbar systems when a
|
|
16
|
+
page styled non-root scrollers thinner (e.g. `:where(:not(:root)){scrollbar-width:thin}`).
|
|
17
|
+
The probe never pinned `scrollbar-width` for the classic read, so that page rule
|
|
18
|
+
bled in and made the "classic" measurement actually thin. The probe now sets
|
|
19
|
+
`scrollbar-width:auto` inline, isolating the classic read from page CSS.
|
|
20
|
+
|
|
11
21
|
## [0.7.5]
|
|
12
22
|
|
|
13
23
|
### Added
|
package/dist/head.cjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
'use strict';var chunk7L35N3N3_cjs=require('./chunk-7L35N3N3.cjs');function c(){let
|
|
1
|
+
'use strict';var chunk7L35N3N3_cjs=require('./chunk-7L35N3N3.cjs');function c(){let r=chunk7L35N3N3_cjs.a.root,o=(n,s)=>r.style.setProperty(chunk7L35N3N3_cjs.a.constPrefix+n,String(s)),t=document.createElement("div");t.style.cssText="position:absolute;top:-9999px;width:100px;height:100px;overflow:scroll;visibility:hidden;scrollbar-width:auto",(document.body??r).appendChild(t);let i=t.offsetWidth-t.clientWidth;o("scrollbar-w",i),o("scrollbar-overlay",i===0?1:0),t.style.scrollbarWidth="thin",o("scrollbar-thin-w",t.offsetWidth-t.clientWidth),t.remove(),o("dpr",window.devicePixelRatio||1),o("cores",navigator.hardwareConcurrency||0),o("mem",navigator.deviceMemory||0);}typeof document<"u"&&c();
|
package/dist/head.global.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(){'use strict';var o={constPrefix:"--const-",root:typeof document<"u"?document.documentElement:void 0};function c(){let i=o.root,
|
|
1
|
+
(function(){'use strict';var o={constPrefix:"--const-",root:typeof document<"u"?document.documentElement:void 0};function c(){let i=o.root,e=(r,s)=>i.style.setProperty(o.constPrefix+r,String(s)),t=document.createElement("div");t.style.cssText="position:absolute;top:-9999px;width:100px;height:100px;overflow:scroll;visibility:hidden;scrollbar-width:auto",(document.body??i).appendChild(t);let n=t.offsetWidth-t.clientWidth;e("scrollbar-w",n),e("scrollbar-overlay",n===0?1:0),t.style.scrollbarWidth="thin",e("scrollbar-thin-w",t.offsetWidth-t.clientWidth),t.remove(),e("dpr",window.devicePixelRatio||1),e("cores",navigator.hardwareConcurrency||0),e("mem",navigator.deviceMemory||0);}typeof document<"u"&&c();})();
|
package/dist/head.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
import {a}from'./chunk-LWKH66VY.js';function c(){let
|
|
1
|
+
import {a}from'./chunk-LWKH66VY.js';function c(){let r=a.root,o=(n,s)=>r.style.setProperty(a.constPrefix+n,String(s)),t=document.createElement("div");t.style.cssText="position:absolute;top:-9999px;width:100px;height:100px;overflow:scroll;visibility:hidden;scrollbar-width:auto",(document.body??r).appendChild(t);let i=t.offsetWidth-t.clientWidth;o("scrollbar-w",i),o("scrollbar-overlay",i===0?1:0),t.style.scrollbarWidth="thin",o("scrollbar-thin-w",t.offsetWidth-t.clientWidth),t.remove(),o("dpr",window.devicePixelRatio||1),o("cores",navigator.hardwareConcurrency||0),o("mem",navigator.deviceMemory||0);}typeof document<"u"&&c();
|