@cssints/css-grammar 0.3.1 → 0.4.0
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/README.md +1 -1
- package/dist/support.mjs +19 -1
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -191,7 +191,7 @@ and Cursor. The skills use it when it is configured and work without it.
|
|
|
191
191
|
bun install
|
|
192
192
|
bun run test # all packages (vp run -r test, cached where possible); includes the type-check of the code in docs/API.md and this file
|
|
193
193
|
bun run bench # type instantiation budgets (tsc and tsgo)
|
|
194
|
-
bun run check # format, lint, type-check (vp check), then the Effect diagnostics (bun run typecheck)
|
|
194
|
+
bun run check # format, lint, type-check (vp check), then tsc 7 with the Effect diagnostics (bun run typecheck)
|
|
195
195
|
bun run diff:check # the added lines against master: anti-slop rules, key-file changes (tools/ai-automation)
|
|
196
196
|
cd apps/demo && bun run dev
|
|
197
197
|
cd apps/docs && bun run dev # the documentation site, on the pages of README.md and docs/API.md
|
package/dist/support.mjs
CHANGED
|
@@ -58,7 +58,25 @@ function reach(syntax, seen = /* @__PURE__ */ new Set()) {
|
|
|
58
58
|
}
|
|
59
59
|
return seen;
|
|
60
60
|
}
|
|
61
|
-
const
|
|
61
|
+
const bcdGet = (key) => key.split(".").reduce((n, k) => n?.[k] ?? n?.[k.toLowerCase()], bcd);
|
|
62
|
+
const absent = (description) => ({ __compat: {
|
|
63
|
+
description,
|
|
64
|
+
support: Object.fromEntries([
|
|
65
|
+
"chrome",
|
|
66
|
+
"chrome_android",
|
|
67
|
+
"edge",
|
|
68
|
+
"firefox",
|
|
69
|
+
"firefox_android",
|
|
70
|
+
"safari",
|
|
71
|
+
"safari_ios",
|
|
72
|
+
"opera",
|
|
73
|
+
"opera_android",
|
|
74
|
+
"samsunginternet_android",
|
|
75
|
+
"webview_android"
|
|
76
|
+
].map((b) => [b, { version_added: false }]))
|
|
77
|
+
} });
|
|
78
|
+
const OWN = /* @__PURE__ */ new Map([["css.types.gradient.mesh-gradient", absent("mesh-gradient()")], ["css.types.gradient.freeform-gradient", absent("freeform-gradient()")]]);
|
|
79
|
+
const get = (key) => bcdGet(key) ?? OWN.get(key);
|
|
62
80
|
const lacks = (c, on, exact = false) => on.filter(([a, ver]) => !supports(c.support[BCD_NAME[a]], ver, exact));
|
|
63
81
|
const lackingOf = (key, ts = current(), exact = false) => {
|
|
64
82
|
const c = get(key)?.__compat;
|