@oxyhq/bloom 0.87.0 → 0.88.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.
Files changed (105) hide show
  1. package/NOTICE +1 -1
  2. package/README.md +1 -1
  3. package/lib/commonjs/bottom-sheet/BottomSheetBase.js +7 -12
  4. package/lib/commonjs/bottom-sheet/BottomSheetBase.js.map +1 -1
  5. package/lib/commonjs/button/Button.web.js +2 -6
  6. package/lib/commonjs/button/Button.web.js.map +1 -1
  7. package/lib/commonjs/connection-dots/ConnectionDots.web.js +2 -6
  8. package/lib/commonjs/connection-dots/ConnectionDots.web.js.map +1 -1
  9. package/lib/commonjs/design-tokens/index.js +19 -0
  10. package/lib/commonjs/design-tokens/index.js.map +1 -1
  11. package/lib/commonjs/design-tokens/tokens-json.js +149 -0
  12. package/lib/commonjs/design-tokens/tokens-json.js.map +1 -0
  13. package/lib/commonjs/design-tokens/tokens.json +6681 -0
  14. package/lib/commonjs/dialog/Dialog.web.js +2 -6
  15. package/lib/commonjs/dialog/Dialog.web.js.map +1 -1
  16. package/lib/commonjs/fab/Fab.web.js +2 -6
  17. package/lib/commonjs/fab/Fab.web.js.map +1 -1
  18. package/lib/commonjs/fonts/apply-font-faces.web.js +8 -10
  19. package/lib/commonjs/fonts/apply-font-faces.web.js.map +1 -1
  20. package/lib/commonjs/frosted-icon-button/FrostedIconButton.web.js +2 -6
  21. package/lib/commonjs/frosted-icon-button/FrostedIconButton.web.js.map +1 -1
  22. package/lib/commonjs/loading/SpinnerIcon.web.js +2 -6
  23. package/lib/commonjs/loading/SpinnerIcon.web.js.map +1 -1
  24. package/lib/commonjs/overlay/index.js +102 -24
  25. package/lib/commonjs/overlay/index.js.map +1 -1
  26. package/lib/commonjs/styles/adopt-style-sheet.js +126 -0
  27. package/lib/commonjs/styles/adopt-style-sheet.js.map +1 -0
  28. package/lib/module/bottom-sheet/BottomSheetBase.js +7 -12
  29. package/lib/module/bottom-sheet/BottomSheetBase.js.map +1 -1
  30. package/lib/module/button/Button.web.js +2 -6
  31. package/lib/module/button/Button.web.js.map +1 -1
  32. package/lib/module/connection-dots/ConnectionDots.web.js +2 -6
  33. package/lib/module/connection-dots/ConnectionDots.web.js.map +1 -1
  34. package/lib/module/design-tokens/index.js +5 -0
  35. package/lib/module/design-tokens/index.js.map +1 -1
  36. package/lib/module/design-tokens/tokens-json.js +144 -0
  37. package/lib/module/design-tokens/tokens-json.js.map +1 -0
  38. package/lib/module/design-tokens/tokens.json +6681 -0
  39. package/lib/module/dialog/Dialog.web.js +2 -6
  40. package/lib/module/dialog/Dialog.web.js.map +1 -1
  41. package/lib/module/fab/Fab.web.js +2 -6
  42. package/lib/module/fab/Fab.web.js.map +1 -1
  43. package/lib/module/fonts/apply-font-faces.web.js +8 -10
  44. package/lib/module/fonts/apply-font-faces.web.js.map +1 -1
  45. package/lib/module/frosted-icon-button/FrostedIconButton.web.js +2 -6
  46. package/lib/module/frosted-icon-button/FrostedIconButton.web.js.map +1 -1
  47. package/lib/module/loading/SpinnerIcon.web.js +2 -6
  48. package/lib/module/loading/SpinnerIcon.web.js.map +1 -1
  49. package/lib/module/overlay/index.js +103 -25
  50. package/lib/module/overlay/index.js.map +1 -1
  51. package/lib/module/styles/adopt-style-sheet.js +121 -0
  52. package/lib/module/styles/adopt-style-sheet.js.map +1 -0
  53. package/lib/typescript/commonjs/bottom-sheet/BottomSheetBase.d.ts.map +1 -1
  54. package/lib/typescript/commonjs/button/Button.web.d.ts.map +1 -1
  55. package/lib/typescript/commonjs/connection-dots/ConnectionDots.web.d.ts.map +1 -1
  56. package/lib/typescript/commonjs/design-tokens/index.d.ts +2 -0
  57. package/lib/typescript/commonjs/design-tokens/index.d.ts.map +1 -1
  58. package/lib/typescript/commonjs/design-tokens/tokens-json.d.ts +85 -0
  59. package/lib/typescript/commonjs/design-tokens/tokens-json.d.ts.map +1 -0
  60. package/lib/typescript/commonjs/dialog/Dialog.web.d.ts.map +1 -1
  61. package/lib/typescript/commonjs/fab/Fab.web.d.ts.map +1 -1
  62. package/lib/typescript/commonjs/fonts/apply-font-faces.web.d.ts +5 -3
  63. package/lib/typescript/commonjs/fonts/apply-font-faces.web.d.ts.map +1 -1
  64. package/lib/typescript/commonjs/frosted-icon-button/FrostedIconButton.web.d.ts.map +1 -1
  65. package/lib/typescript/commonjs/loading/SpinnerIcon.web.d.ts.map +1 -1
  66. package/lib/typescript/commonjs/overlay/index.d.ts.map +1 -1
  67. package/lib/typescript/commonjs/styles/adopt-style-sheet.d.ts +22 -0
  68. package/lib/typescript/commonjs/styles/adopt-style-sheet.d.ts.map +1 -0
  69. package/lib/typescript/module/bottom-sheet/BottomSheetBase.d.ts.map +1 -1
  70. package/lib/typescript/module/button/Button.web.d.ts.map +1 -1
  71. package/lib/typescript/module/connection-dots/ConnectionDots.web.d.ts.map +1 -1
  72. package/lib/typescript/module/design-tokens/index.d.ts +2 -0
  73. package/lib/typescript/module/design-tokens/index.d.ts.map +1 -1
  74. package/lib/typescript/module/design-tokens/tokens-json.d.ts +85 -0
  75. package/lib/typescript/module/design-tokens/tokens-json.d.ts.map +1 -0
  76. package/lib/typescript/module/dialog/Dialog.web.d.ts.map +1 -1
  77. package/lib/typescript/module/fab/Fab.web.d.ts.map +1 -1
  78. package/lib/typescript/module/fonts/apply-font-faces.web.d.ts +5 -3
  79. package/lib/typescript/module/fonts/apply-font-faces.web.d.ts.map +1 -1
  80. package/lib/typescript/module/frosted-icon-button/FrostedIconButton.web.d.ts.map +1 -1
  81. package/lib/typescript/module/loading/SpinnerIcon.web.d.ts.map +1 -1
  82. package/lib/typescript/module/overlay/index.d.ts.map +1 -1
  83. package/lib/typescript/module/styles/adopt-style-sheet.d.ts +22 -0
  84. package/lib/typescript/module/styles/adopt-style-sheet.d.ts.map +1 -0
  85. package/package.json +4 -2
  86. package/src/__tests__/adopt-style-sheet.node.test.ts +21 -0
  87. package/src/__tests__/adopt-style-sheet.test.ts +165 -0
  88. package/src/__tests__/apply-font-faces.test.ts +32 -0
  89. package/src/__tests__/design-tokens-json.test.ts +112 -0
  90. package/src/__tests__/exports-map-contract.test.ts +5 -1
  91. package/src/__tests__/support/constructed-style-sheets.ts +68 -0
  92. package/src/bottom-sheet/BottomSheetBase.tsx +10 -14
  93. package/src/button/Button.web.tsx +2 -6
  94. package/src/connection-dots/ConnectionDots.web.tsx +2 -6
  95. package/src/design-tokens/index.ts +16 -0
  96. package/src/design-tokens/tokens-json.ts +214 -0
  97. package/src/design-tokens/tokens.json +6681 -0
  98. package/src/dialog/Dialog.stories.tsx +37 -0
  99. package/src/dialog/Dialog.web.tsx +2 -6
  100. package/src/fab/Fab.web.tsx +2 -6
  101. package/src/fonts/apply-font-faces.web.ts +11 -11
  102. package/src/frosted-icon-button/FrostedIconButton.web.tsx +2 -6
  103. package/src/loading/SpinnerIcon.web.tsx +2 -6
  104. package/src/overlay/index.tsx +123 -24
  105. package/src/styles/adopt-style-sheet.ts +131 -0
@@ -0,0 +1,121 @@
1
+ "use strict";
2
+
3
+ // ---------------------------------------------------------------------------
4
+ // adoptStyleSheet — the ONE way a Bloom web fork puts CSS on the page.
5
+ //
6
+ // Bloom's `.web.tsx` forks self-inject the CSS they need (`@keyframes`,
7
+ // pseudo-classes, `::-webkit-scrollbar`) rather than asking consumers to paste
8
+ // it into a global stylesheet — see AGENTS.md, "Web Fork CSS & Style
9
+ // Conventions". The mechanism used to be a `<style>` element carrying the CSS
10
+ // as text content. That is exactly the shape a Content-Security-Policy of
11
+ // `style-src 'self'` blocks: the check runs when a style element's text
12
+ // content is parsed into a sheet, so the rules are dropped, the component
13
+ // renders with none of its CSS, and NOTHING is thrown — the fork's own
14
+ // "already injected?" guard even finds its element in the DOM and reports
15
+ // success. Astro's `astro://` WebUI pages ship that CSP, and every other Oxy
16
+ // surface behind one would fail the same silent way.
17
+ //
18
+ // A constructed stylesheet is not subject to `style-src` at all — CSSOM is
19
+ // outside CSP's inline hooks — so `new CSSStyleSheet()` + `replaceSync()` +
20
+ // `document.adoptedStyleSheets` applies the same CSS under a strict policy
21
+ // with no nonce, no hash, and no consumer-side wiring. (This is also why
22
+ // react-native-web is unaffected: it appends an EMPTY style element and fills
23
+ // it through `sheet.insertRule`, never through text content.)
24
+ //
25
+ // The `<style>` path survives only as the fallback for a document without
26
+ // constructed-stylesheet support — jsdom 26 has the `CSSStyleSheet`
27
+ // constructor but neither `replaceSync` nor `adoptedStyleSheets`, so the whole
28
+ // jest suite takes it, and so do browsers older than Chrome 73 / Safari 16.4 /
29
+ // Firefox 101. There it behaves exactly as Bloom did before, CSP included:
30
+ // the fallback cannot make anything worse, and cannot make a strict policy
31
+ // work either.
32
+ // ---------------------------------------------------------------------------
33
+
34
+ /**
35
+ * The sheets Bloom has constructed, per document. Keyed by document rather than
36
+ * held in one flat map because a constructed sheet belongs to the realm that
37
+ * created it — adopting one into a different document throws — and Bloom runs
38
+ * in more than one when a consumer opens a popout window.
39
+ */
40
+ const adoptedByDocument = new WeakMap();
41
+ function sheetsFor(doc) {
42
+ const existing = adoptedByDocument.get(doc);
43
+ if (existing) return existing;
44
+ const created = new Map();
45
+ adoptedByDocument.set(doc, created);
46
+ return created;
47
+ }
48
+
49
+ /**
50
+ * Whether `doc` can take a constructed stylesheet. Evaluated per call, not once
51
+ * at module scope: a test installs the API on its window after this module has
52
+ * already been imported, and a module-scope constant would freeze the answer
53
+ * from before that.
54
+ */
55
+ function supportsAdoption(doc) {
56
+ return 'adoptedStyleSheets' in doc && typeof CSSStyleSheet === 'function' && typeof CSSStyleSheet.prototype.replaceSync === 'function';
57
+ }
58
+
59
+ /**
60
+ * Make `css` apply to the document, under the identity `id`.
61
+ *
62
+ * Idempotent in both directions: calling it again with the same CSS re-parses
63
+ * nothing and adopts nothing twice (the usual case — every mount of every
64
+ * instance of a component calls it), and calling it with DIFFERENT CSS under
65
+ * the same id replaces the previous content in place (the theme-dependent case,
66
+ * `BottomSheetBase`'s scrollbar colours).
67
+ *
68
+ * No-op off the web, so a platform-neutral component can call it unguarded.
69
+ */
70
+ export function adoptStyleSheet(id, css) {
71
+ if (typeof document === 'undefined') return;
72
+ if (supportsAdoption(document)) {
73
+ const sheets = sheetsFor(document);
74
+ let entry = sheets.get(id);
75
+ if (!entry) {
76
+ entry = {
77
+ sheet: new CSSStyleSheet(),
78
+ css: ''
79
+ };
80
+ sheets.set(id, entry);
81
+ }
82
+ if (entry.css !== css) {
83
+ entry.sheet.replaceSync(css);
84
+ entry.css = css;
85
+ }
86
+ // Re-adoption after a consumer (or a test) has reset the list. `includes`
87
+ // is what makes the common repeat call free.
88
+ if (!document.adoptedStyleSheets.includes(entry.sheet)) {
89
+ document.adoptedStyleSheets = [...document.adoptedStyleSheets, entry.sheet];
90
+ }
91
+ return;
92
+ }
93
+ const existing = document.getElementById(id);
94
+ if (existing instanceof HTMLStyleElement) {
95
+ if (existing.textContent !== css) existing.textContent = css;
96
+ return;
97
+ }
98
+ const element = document.createElement('style');
99
+ element.id = id;
100
+ element.textContent = css;
101
+ document.head.appendChild(element);
102
+ }
103
+
104
+ /**
105
+ * Detach the stylesheet `id`, whichever path installed it.
106
+ *
107
+ * Only for CSS whose lifetime is a component's — `BottomSheetBase` removes its
108
+ * scrollbar rules when the last sheet unmounts. The static per-component CSS is
109
+ * never dropped: it is the same bytes for the life of the page, and removing it
110
+ * on unmount would make a re-mount re-parse it.
111
+ */
112
+ export function dropStyleSheet(id) {
113
+ if (typeof document === 'undefined') return;
114
+ const entry = adoptedByDocument.get(document)?.get(id);
115
+ if (entry) {
116
+ document.adoptedStyleSheets = document.adoptedStyleSheets.filter(sheet => sheet !== entry.sheet);
117
+ adoptedByDocument.get(document)?.delete(id);
118
+ }
119
+ document.getElementById(id)?.remove();
120
+ }
121
+ //# sourceMappingURL=adopt-style-sheet.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"names":["adoptedByDocument","WeakMap","sheetsFor","doc","existing","get","created","Map","set","supportsAdoption","CSSStyleSheet","prototype","replaceSync","adoptStyleSheet","id","css","document","sheets","entry","sheet","adoptedStyleSheets","includes","getElementById","HTMLStyleElement","textContent","element","createElement","head","appendChild","dropStyleSheet","filter","delete","remove"],"sourceRoot":"../../../src","sources":["styles/adopt-style-sheet.ts"],"mappings":";;AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAQA;AACA;AACA;AACA;AACA;AACA;AACA,MAAMA,iBAAiB,GAAG,IAAIC,OAAO,CAAsC,CAAC;AAE5E,SAASC,SAASA,CAACC,GAAa,EAA6B;EAC3D,MAAMC,QAAQ,GAAGJ,iBAAiB,CAACK,GAAG,CAACF,GAAG,CAAC;EAC3C,IAAIC,QAAQ,EAAE,OAAOA,QAAQ;EAC7B,MAAME,OAAO,GAAG,IAAIC,GAAG,CAAuB,CAAC;EAC/CP,iBAAiB,CAACQ,GAAG,CAACL,GAAG,EAAEG,OAAO,CAAC;EACnC,OAAOA,OAAO;AAChB;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA,SAASG,gBAAgBA,CAACN,GAAa,EAAW;EAChD,OACE,oBAAoB,IAAIA,GAAG,IAC3B,OAAOO,aAAa,KAAK,UAAU,IACnC,OAAOA,aAAa,CAACC,SAAS,CAACC,WAAW,KAAK,UAAU;AAE7D;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,OAAO,SAASC,eAAeA,CAACC,EAAU,EAAEC,GAAW,EAAQ;EAC7D,IAAI,OAAOC,QAAQ,KAAK,WAAW,EAAE;EAErC,IAAIP,gBAAgB,CAACO,QAAQ,CAAC,EAAE;IAC9B,MAAMC,MAAM,GAAGf,SAAS,CAACc,QAAQ,CAAC;IAClC,IAAIE,KAAK,GAAGD,MAAM,CAACZ,GAAG,CAACS,EAAE,CAAC;IAC1B,IAAI,CAACI,KAAK,EAAE;MACVA,KAAK,GAAG;QAAEC,KAAK,EAAE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,CAAC;CACrD;AAED,eAAO,MAAM,eAAe,6FA8nB1B,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"Button.web.d.ts","sourceRoot":"","sources":["../../../../src/button/Button.web.tsx"],"names":[],"mappings":"AAAA,OAAO,KASN,MAAM,OAAO,CAAC;AAMf,OAAO,KAAK,EAAE,WAAW,EAA6B,MAAM,SAAS,CAAC;AAEtE,YAAY,EAAE,WAAW,EAAE,aAAa,EAAE,UAAU,EAAE,MAAM,SAAS,CAAC;AAuatE,eAAO,MAAM,MAAM,yCAA2B,CAAC;AAG/C,eAAO,MAAM,aAAa,oCAAgB,IAAI,CAAC,WAAW,EAAE,SAAS,CAAC,6CAEpE,CAAC;AAGH,eAAO,MAAM,eAAe,oCAAgB,IAAI,CAAC,WAAW,EAAE,SAAS,CAAC,6CAEtE,CAAC;AAGH,eAAO,MAAM,UAAU,oCAAgB,IAAI,CAAC,WAAW,EAAE,SAAS,CAAC,6CAEjE,CAAC;AAGH,eAAO,MAAM,WAAW,oCAAgB,IAAI,CAAC,WAAW,EAAE,SAAS,CAAC,6CAElE,CAAC;AAGH,eAAO,MAAM,aAAa,oCAAgB,IAAI,CAAC,WAAW,EAAE,SAAS,CAAC,6CAEpE,CAAC;AAGH,eAAO,MAAM,UAAU,oCAAgB,IAAI,CAAC,WAAW,EAAE,SAAS,CAAC,6CAEjE,CAAC;AAGH,eAAO,MAAM,aAAa,oCAAgB,IAAI,CAAC,WAAW,EAAE,SAAS,CAAC,6CAEpE,CAAC;AAGH,eAAO,MAAM,UAAU,oCAAgB,IAAI,CAAC,WAAW,EAAE,SAAS,CAAC,6CAEjE,CAAC;AAGH,eAAO,MAAM,iBAAiB,oCAAgB,IAAI,CAAC,WAAW,EAAE,SAAS,CAAC,6CAExE,CAAC"}
1
+ {"version":3,"file":"Button.web.d.ts","sourceRoot":"","sources":["../../../../src/button/Button.web.tsx"],"names":[],"mappings":"AAAA,OAAO,KASN,MAAM,OAAO,CAAC;AAOf,OAAO,KAA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ionDots.web.d.ts","sourceRoot":"","sources":["../../../../src/connection-dots/ConnectionDots.web.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAoC,MAAM,OAAO,CAAC;AAOzD,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,SAAS,CAAC;AASnD;;;;;;;;GAQG;AACH,eAAO,MAAM,yBAAyB,mOAKrC,CAAC;AAuFF,eAAO,MAAM,cAAc,iDAAgC,CAAC"}
@@ -21,6 +21,8 @@
21
21
  export { bloomTailwindPreset } from './tailwind-preset';
22
22
  export type { TailwindPreset, TailwindPresetThemeExtend, } from './tailwind-preset';
23
23
  export { bloomThemeCss, bloomThemeBlock } from './theme-css';
24
+ export { bloomDesignTokens, renderBloomTokensJson, resolvedColorToHex, } from './tokens-json';
25
+ export type { BloomDesignTokens, DesignToken, PresetExtensions, PresetGroup, } from './tokens-json';
24
26
  export { getPresetVars } from '../theme/preset-vars';
25
27
  export type { ExplicitAccents } from '../theme/preset-vars';
26
28
  export { buildSeedScopeVars } from '../theme/color-scope/seed-scope';
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/design-tokens/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;GAmBG;AAEH,OAAO,EAAE,mBAAmB,EAAE,MAAM,mBAAmB,CAAC;AACxD,YAAY,EACV,cAAc,EACd,yBAAyB,GAC1B,MAAM,mBAAmB,CAAC;AAE3B,OAAO,EAAE,aAAa,EAAE,eAAe,EAAE,MAAM,aAAa,CAAC;AAgB7D,OAAO,EAAE,aAAa,EAAE,MAAM,sBAAsB,CAAC;AACrD,YAAY,EAAE,eAAe,EAAE,MAAM,sBAAsB,CAAC;AAC5D,OAAO,EAAE,kBAAkB,EAAE,MAAM,iCAAiC,CAAC;AACrE,YAAY,EAAE,gBAAgB,EAAE,MAAM,iCAAiC,CAAC;AAExE,OAAO,EACL,UAAU,EACV,UAAU,EACV,YAAY,GACb,MAAM,eAAe,CAAC;AACvB,YA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,CAAC;AAClB,YAAY,EAAE,QAAQ,EAAE,YAAY,EAAE,MAAM,UAAU,CAAC;AAEvD,OAAO,EAAE,UAAU,EAAE,gBAAgB,EAAE,MAAM,WAAW,CAAC;AACzD,YAAY,EAAE,UAAU,EAAE,MAAM,WAAW,CAAC"}
@@ -0,0 +1,85 @@
1
+ /**
2
+ * The machine-readable form of every Bloom design token, in W3C Design Tokens
3
+ * (DTCG) format.
4
+ *
5
+ * The CSS artifacts next to this file (`theme.css`, `bloomThemeCss()`) are the
6
+ * ALIAS layer and only make sense to a browser. A consumer that is not a
7
+ * browser — Astro codegens `SkColor` tables for Chromium's native UI so the
8
+ * toolbar and the WebUI pages cannot disagree about what "primary" is — needs
9
+ * the RESOLVED values, for every preset and both schemes, in a format it can
10
+ * read without running Bloom's colour engine. That is this file.
11
+ *
12
+ * Same single source as everything else: `getResolvedTokens`, i.e. the colour
13
+ * engine. `tokens.json` is generated from it by
14
+ * `scripts/generate-design-tokens-json.ts`, and
15
+ * `src/__tests__/design-tokens-json.test.ts` fails if the checked-in file is
16
+ * not byte-identical to a fresh render — so the JSON, the CSS and the runtime
17
+ * palette cannot drift from each other.
18
+ */
19
+ /** One DTCG token. `$type` is inherited from the nearest group that declares it. */
20
+ export interface DesignToken {
21
+ $value: string | number;
22
+ $type?: string;
23
+ $description?: string;
24
+ }
25
+ /** Bloom-specific metadata on a preset group, namespaced per the DTCG `$extensions` rule. */
26
+ export interface PresetExtensions {
27
+ 'so.oxy.bloom': {
28
+ /** The brand seed the engine derived the whole palette from. */
29
+ seed: string;
30
+ /** The tonal scheme variant used with that seed. */
31
+ variant: string;
32
+ /** Who may pick the preset; absent means everyone. */
33
+ gate?: string;
34
+ /** Present when the preset forces a white label in both schemes. */
35
+ label?: string;
36
+ };
37
+ }
38
+ export interface PresetGroup {
39
+ $description: string;
40
+ $extensions: PresetExtensions;
41
+ light: Record<string, DesignToken>;
42
+ dark: Record<string, DesignToken>;
43
+ }
44
+ export interface BloomDesignTokens {
45
+ $description: string;
46
+ color: {
47
+ $type: 'color';
48
+ $description: string;
49
+ } & Record<string, unknown>;
50
+ spacing: {
51
+ $type: 'dimension';
52
+ $description: string;
53
+ } & Record<string, unknown>;
54
+ radius: {
55
+ $type: 'dimension';
56
+ $description: string;
57
+ } & Record<string, unknown>;
58
+ borderWidth: {
59
+ $type: 'dimension';
60
+ $description: string;
61
+ } & Record<string, unknown>;
62
+ typography: {
63
+ $description: string;
64
+ } & Record<string, unknown>;
65
+ }
66
+ /**
67
+ * Turn one resolved token value into an sRGB hex string.
68
+ *
69
+ * The engine emits exactly two forms — `rgb(r g b)` for opaque tokens and
70
+ * `rgba(r, g, b, a)` for the translucent `-subtle` family. Anything else is a
71
+ * change in the engine's output that this file has not been taught about, and
72
+ * throwing at generation time is the only way that surfaces: a silently
73
+ * passed-through CSS string would end up in a C++ colour table as garbage.
74
+ */
75
+ export declare function resolvedColorToHex(value: string): string;
76
+ /** The whole token file, as a plain object. */
77
+ export declare function bloomDesignTokens(): BloomDesignTokens;
78
+ /**
79
+ * The exact bytes of `design-tokens/tokens.json`.
80
+ *
81
+ * Both the generator script and the drift test call this, so neither can be
82
+ * right about the file while the other is wrong.
83
+ */
84
+ export declare function renderBloomTokensJson(): string;
85
+ //# sourceMappingURL=tokens-json.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"tokens-json.d.ts","sourceRoot":"","sources":["../../../../src/design-tokens/tokens-json.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;GAiBG;AAgBH,oFAAoF;AACpF,MAAM,WAAW,WAAW;IAC1B,MAAM,EAAE,MAAM,GAAG,MAAM,CAAC;IACxB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,YAAY,CAAC,EAAE,MAAM,CAAC;CACvB;AAED,6FAA6F;AAC7F,MAAM,WAAW,gBAAgB;IAC/B,cAAc,EAAE;QACd,gEAAgE;QAChE,IAAI,EAAE,MAAM,CAAC;QACb,oDAAoD;QACpD,OAAO,EAAE,M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AM,CAE9C"}
@@ -1 +1 @@
1
- {"version":3,"file":"Dialog.web.d.ts","sourceRoot":"","sources":["../../../../src/dialog/Dialog.web.tsx"],"names":[],"mappings":"AA2CA,OAAO,EAOL,4BAA4B,EAK7B,MAAM,aAAa,CAAC;AACrB,OAAO,KAAK,EACV,YAAY,EAGZ,WAAW,EACZ,MAAM,SAAS,CAAC;AAwDjB;;;;;;;;;;;;;;;;;;;;;;GAsBG;AACH,wBAAgB,MAAM,CAAC,EAAE,SAAS,EAAE,GAAG,IAAI,EAAE,EAAE,WAAW,2CAazD;AAobD,OAAO,EAAE,4BAA4B,EAAE,CAAC;AAkPxC;;;;GAIG;AACH,wBAAgB,iBAAiB,CAAC,EAChC,KAAK,EACL,WAAW,EACX,OAAO,EACP,SAAS,GACV,EAAE;IACD,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,OAAO,EAAE,YAAY,EAAE,CAAC;IACxB,SAAS,EAAE,MAAM,IAAI,CAAC;CACvB,2CAgBA;AAkCD;;;;;;;;;;;;;;;;;;GAkBG;AACH,eAAO,MAAM,gBAAgB,8PAG5B,CAAC"}
1
+ {"version":3,"file":"Dialog.web.d.ts","sourceRoot":"","sources":["../../../../src/dialog/Dialog.web.tsx"],"names":[],"mappings":"AA4CA,OAAO,EAOL,4BAA4B,EAK7B,MAAM,aAAa,CAAC;AACrB,OAAO,KAAK,EACV,YAAY,EAGZ,WAAW,EACZ,MAAM,SAAS,CAAC;AAmDjB;;;;;;;;;;;;;;;;;;;;;;GAsBG;AACH,wBAAgB,MAAM,CAAC,EAAE,SAAS,EAAE,GAAG,IAAI,EAAE,EAAE,WAAW,2CAazD;AAobD,OAAO,EAAE,4BAA4B,EAAE,CAAC;AAkPxC;;;;GAIG;AACH,wBAAgB,iBAAiB,CAAC,EAChC,KAAK,EACL,WAAW,EACX,OAAO,EACP,SAAS,GACV,EAAE;IACD,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,OAAO,EAAE,YAAY,EAAE,CAAC;IACxB,SAAS,EAAE,MAAM,IAAI,CAAC;CACvB,2CAgBA;AAkCD;;;;;;;;;;;;;;;;;;GAkBG;AACH,eAAO,MAAM,gBAAgB,8PAG5B,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"Fab.web.d.ts","sourceRoot":"","sources":["../../../../src/fab/Fab.web.tsx"],"names":[],"mappings":"AAAA,OAAO,KAQN,MAAM,OAAO,CAAC;AAKf,OAAO,KAAK,EAAgB,QAAQ,EAAuB,MAAM,SAAS,CAAC;AAE3E,YAAY,EAAE,QAAQ,EAAE,UAAU,EAAE,OAAO,EAAE,YAAY,EAAE,MAAM,SAAS,CAAC;AAoS3E,eAAO,MAAM,GAAG,sCAAwB,CAAC"}
1
+ {"version":3,"file":"Fab.web.d.ts","sourceRoot":"","sources":["../../../../src/fab/Fab.web.tsx"],"names":[],"mappings":"AAAA,OAAO,KAQN,MAAM,OAAO,CAAC;AAMf,OAAO,KAAK,EAAgB,QAAQ,EAAuB,MAAM,SAAS,CAAC;AAE3E,YAAY,EAAE,QAAQ,EAAE,UAAU,EAAE,OAAO,EAAE,YAAY,EAAE,MAAM,SAAS,CAAC;AA+R3E,eAAO,MAAM,GAAG,sCAAwB,CAAC"}
@@ -4,9 +4,11 @@
4
4
  * Web-only. The native counterpart in `apply-font-faces.ts` is a no-op
5
5
  * stub — native loads its fonts through `useFonts(FONT_ASSETS)`, so the file
6
6
  * split keeps the web font payload out of the native bundle entirely.
7
- * Idempotent: safe to call multiple times; subsequent calls early-return
8
- * after the `<style id="bloom-fonts">` tag has been mounted. SSR-safe via
9
- * the `typeof document === 'undefined'` guard.
7
+ * Idempotent: safe to call multiple times; `adoptStyleSheet` keys the sheet by
8
+ * id, so repeat calls re-parse nothing. SSR-safe via its `typeof document`
9
+ * guard. `BloomThemeProvider` calls this on every mount by default, which is
10
+ * why it also has to survive a page whose CSP forbids inline styles — see
11
+ * `styles/adopt-style-sheet.ts`.
10
12
  *
11
13
  * The URLs come from `./font-urls.web`, which imports the `.woff2` files so
12
14
  * the consuming bundler emits them as separate, cacheable assets. See that
@@ -1 +1 @@
1
- {"version":3,"file":"apply-font-faces.web.d.ts","sourceRoot":"","sources":["../../../../src/fonts/apply-font-faces.web.ts"],"names":[],"mappings":"AAUA;;;;;;;;;;;;;;GAcG;AACH,wBAAgB,cAAc,IAAI,IAAI,CAkBrC"}
1
+ {"version":3,"file":"apply-font-faces.web.d.ts","sourceRoot":"","sources":["../../../../src/fonts/apply-font-faces.web.ts"],"names":[],"mappings":"AAWA;;;;;;;;;;;;;;;;GAgBG;AACH,wBAAgB,cAAc,IAAI,IAAI,CAerC"}
@@ -1 +1 @@
1
- {"version":3,"file":"FrostedIconButton.web.d.ts","sourceRoot":"","sources":["../../../../src/frosted-icon-button/FrostedIconButton.web.tsx"],"names":[],"mappings":"AAAA,OAAO,KAQN,MAAM,OAAO,CAAC;AASf,OAAO,KAAK,EAAE,sBAAsB,EAAE,MAAM,SAAS,CAAC;AAEtD,YAAY,EAAE,sBAAsB,EAAE,qBAAqB,EAAE,MAAM,SAAS,CAAC;AA0L7E,eAAO,MAAM,iBAAiB,oDAAsC,CAAC"}
1
+ {"version":3,"file":"FrostedIconButton.web.d.ts","sourceRoot":"","sources":["../../../../src/frosted-icon-button/FrostedIconButton.web.tsx"],"names":[],"mappings":"AAAA,OAAO,KAQN,MAAM,OAAO,CAAC;AAUf,OAAO,KAAK,EAAE,sBAAsB,EAAE,MAAM,SAAS,CAAC;AAEtD,YAAY,EAAE,sBAAsB,EAAE,qBAAqB,EAAE,MAAM,SAAS,CAAC;AAqL7E,eAAO,MAAM,iBAAiB,oDAAsC,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"SpinnerIcon.web.d.ts","sourceRoot":"","sources":["../../../../src/loading/SpinnerIcon.web.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAoB,MAAM,OAAO,CAAC;AACzC,OAAO,EAAoB,KAAK,SAAS,EAAE,MAAM,cAAc,CAAC;AAIhE,UAAU,gBAAgB;IACxB,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,KAAK,CAAC,EAAE,SAAS,CAAC;CACnB;AA4CD;;;;GAIG;AACH,eAAO,MAAM,iBAAiB,8GAE7B,CAAC;AAsBF,eAAO,MAAM,WAAW,EAAE,KAAK,CAAC,EAAE,CAAC,gBAAgB,CAuClD,CAAC"}
1
+ {"version":3,"file":"SpinnerIcon.web.d.ts","sourceRoot":"","sources":["../../../../src/loading/SpinnerIcon.web.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAoB,MAAM,OAAO,CAAC;AACzC,OAAO,EAAoB,KAAK,SAAS,EAAE,MAAM,cAAc,CAAC;AAKhE,UAAU,gBAAgB;IACxB,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,KAAK,CAAC,EAAE,SAAS,CAAC;CACnB;AA4CD;;;;GAIG;AACH,eAAO,MAAM,iBAAiB,8GAE7B,CAAC;AAiBF,eAAO,MAAM,WAAW,EAAE,KAAK,CAAC,EAAE,CAAC,gBAAgB,CAuClD,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/overlay/index.tsx"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAwCG;AACH,OAAO,EAA4C,KAAK,SAAS,EAAE,MAAM,OAAO,CAAC;AAEjF,OAAO,EAKL,KAAK,SAAS,EACd,KAAK,SAAS,EACf,MAAM,cAAc,CAAC;AACtB,OAAiB,EAAoB,KAAK,WAAW,EAAE,MAAM,yBAAyB,CAAC;AAGvF,OAAO,EAAgB,KAAK,YAAY,EAAE,MAAM,SAAS,C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AAI,CAAC;IACrB;;;;OAIG;IACH,QAAQ,CAAC,EAAE,WAAW,CAAC,MAAM,CAAC,CAAC;IAC/B,iFAAiF;IACjF,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,6DAA6D;IAC7D,aAAa,CAAC,EAAE,MAAM,CAAC;IACvB,iFAAiF;IACjF,QAAQ,CAAC,EAAE,OAAO,GAAG,MAAM,GAAG,SAAS,CAAC;IACxC,gCAAgC;IAChC,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,wBAAwB;IACxB,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB;;;;;;;;;OASG;IACH,KAAK,CAAC,EAAE,SAAS,CAAC,SAAS,CAAC,CAAC;IAC7B;;;OAGG;IACH,UAAU,CAAC,EAAE,SAAS,CAAC,SAAS,CAAC,CAAC;IAClC,+FAA+F;IAC/F,QAAQ,CAAC,EAAE,SAAS,CAAC;IACrB,kBAAkB,CAAC,EAAE,MAAM,CAAC;IAC5B,MAAM,CAAC,EAAE,MAAM,CAAC;CACjB;AA2GD;;;;;;;;;;;;;;;;GAgBG;AACH,eAAO,MAAM,QAAQ,qDAqEnB,CAAC;AAmBH,OAAO,EACL,YAAY,EACZ,kBAAkB,EAClB,kBAAkB,EAClB,sBAAsB,EACtB,aAAa,EACb,KAAK,YAAY,GAClB,MAAM,SAAS,CAAC;AACjB,OAAO,EAAE,eAAe,EAAE,MAAM,qBAAqB,CAAC"}
@@ -0,0 +1,22 @@
1
+ /**
2
+ * Make `css` apply to the document, under the identity `id`.
3
+ *
4
+ * Idempotent in both directions: calling it again with the same CSS re-parses
5
+ * nothing and adopts nothing twice (the usual case — every mount of every
6
+ * instance of a component calls it), and calling it with DIFFERENT CSS under
7
+ * the same id replaces the previous content in place (the theme-dependent case,
8
+ * `BottomSheetBase`'s scrollbar colours).
9
+ *
10
+ * No-op off the web, so a platform-neutral component can call it unguarded.
11
+ */
12
+ export declare function adoptStyleSheet(id: string, css: string): void;
13
+ /**
14
+ * Detach the stylesheet `id`, whichever path installed it.
15
+ *
16
+ * Only for CSS whose lifetime is a component's — `BottomSheetBase` removes its
17
+ * scrollbar rules when the last sheet unmounts. The static per-component CSS is
18
+ * never dropped: it is the same bytes for the life of the page, and removing it
19
+ * on unmount would make a re-mount re-parse it.
20
+ */
21
+ export declare function dropStyleSheet(id: string): void;
22
+ //# sourceMappingURL=adopt-style-sheet.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"adopt-style-sheet.d.ts","sourceRoot":"","sources":["../../../../src/styles/adopt-style-sheet.ts"],"names":[],"mappings":"AAmEA;;;;;;;;;;GAUG;AACH,wBAAgB,eAAe,CAAC,EAAE,EAAE,MAAM,EAAE,GAAG,EAAE,MAAM,GAAG,IAAI,CA+B7D;AAED;;;;;;;GAOG;AACH,wBAAgB,cAAc,CAAC,EAAE,EAAE,MAAM,GAAG,IAAI,CAW/C"}
@@ -1 +1 @@
1
- {"version":3,"file":"BottomSheetBase.d.ts","sourceRoot":"","sources":["../../../../src/bottom-sheet/BottomSheetBase.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAE/B,OAAO,EAMH,KAAK,iBAAiB,EACtB,KAAK,SAAS,EACd,KAAK,SAAS,EACjB,MAAM,cAAc,CAAC;AAItB,OAAiB,EACb,KAAK,aAAa,EAGlB,KAAK,WAAW,EAOnB,MAAM,yBAAyB,CAAC;AAyBjC,MAAM,WAAW,cAAc;IAC3B,OAAO,EAAE,MAAM,IAAI,CAAC;IACpB,OAAO,EAAE,MAAM,IAAI,CAAC;IACpB,KAAK,EAAE,MAAM,IAAI,CAAC;IAClB,MAAM,EAAE,MAAM,IAAI,CAAC;IACnB,QAAQ,EAAE,MAAM,IAAI,CAAC;IACrB,QAAQ,EAAE,CAAC,CAAC,EAAE,MAAM,EAAE,QAAQ,CAAC,EAAE,OAAO,KAAK,IAAI,CAAC;CACrD;AAED,MAAM,WAAW,gBAAgB;IAC7B,QAAQ,EAAE,KAAK,CA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-1 +1 @@
1
- {"version":3,"file":"ConnectionDots.web.d.ts","sourceRoot":"","sources":["../../../../src/connection-dots/ConnectionDots.web.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAoC,MAAM,OAAO,CAAC;AAMzD,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,SAAS,CAAC;AASnD;;;;;;;;GAQG;AACH,eAAO,MAAM,yBAAyB,mOAKrC,CAAC;AA4FF,eAAO,MAAM,cAAc,iDAAgC,CAAC"}
1
+ {"version":3,"file":"ConnectionDots.web.d.ts","sourceRoot":"","sources":["../../../../src/connection-dots/ConnectionDots.web.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAoC,MAAM,OAAO,CAAC;AAOzD,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,SAAS,CAAC;AASnD;;;;;;;;GAQG;AACH,eAAO,MAAM,yBAAyB,mOAKrC,CAAC;AAuFF,eAAO,MAAM,cAAc,iDAAgC,CAAC"}
@@ -21,6 +21,8 @@
21
21
  export { bloomTailwindPreset } from './tailwind-preset';
22
22
  export type { TailwindPreset, TailwindPresetThemeExtend, } from './tailwind-preset';
23
23
  export { bloomThemeCss, bloomThemeBlock } from './theme-css';
24
+ export { bloomDesignTokens, renderBloomTokensJson, resolvedColorToHex, } from './tokens-json';
25
+ export type { BloomDesignTokens, DesignToken, PresetExtensions, PresetGroup, } from './tokens-json';
24
26
  export { getPresetVars } from '../theme/preset-vars';
25
27
  export type { ExplicitAccents } from '../theme/preset-vars';
26
28
  export { buildSeedScopeVars } from '../theme/color-scope/seed-scope';
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/design-tokens/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;GAmBG;AAEH,OAAO,EAAE,mBAAmB,EAAE,MAAM,mBAAmB,CAAC;AACxD,YAAY,EACV,cAAc,EACd,yBAAyB,GAC1B,MAAM,mBAAmB,CAAC;AAE3B,OAAO,EAAE,aAA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,EAAE,kBAAkB,EAAE,MAAM,iCAAiC,CAAC;AACrE,YAAY,EAAE,gBAAgB,EAAE,MAAM,iCAAiC,CAAC;AAExE,OAAO,EACL,UAAU,EACV,UAAU,EACV,YAAY,GACb,MAAM,eAAe,CAAC;AACvB,YAAY,EAAE,QAAQ,EAAE,QAAQ,EAAE,UAAU,EAAE,MAAM,eAAe,CAAC;AAEpE,OAAO,EACL,OAAO,EACP,MAAM,EACN,YAAY,EACZ,UAAU,EACV,gBAAgB,GACjB,MAAM,UAAU,CAAC;AAClB,YAAY,EAAE,QAAQ,EAAE,YAAY,EAAE,MAAM,UAAU,CAAC;AAEvD,OAAO,EAAE,UAAU,EAAE,gBAAgB,EAAE,MAAM,WAAW,CAAC;AACzD,YAAY,EAAE,UAAU,EAAE,MAAM,WAAW,CAAC"}
@@ -0,0 +1,85 @@
1
+ /**
2
+ * The machine-readable form of every Bloom design token, in W3C Design Tokens
3
+ * (DTCG) format.
4
+ *
5
+ * The CSS artifacts next to this file (`theme.css`, `bloomThemeCss()`) are the
6
+ * ALIAS layer and only make sense to a browser. A consumer that is not a
7
+ * browser — Astro codegens `SkColor` tables for Chromium's native UI so the
8
+ * toolbar and the WebUI pages cannot disagree about what "primary" is — needs
9
+ * the RESOLVED values, for every preset and both schemes, in a format it can
10
+ * read without running Bloom's colour engine. That is this file.
11
+ *
12
+ * Same single source as everything else: `getResolvedTokens`, i.e. the colour
13
+ * engine. `tokens.json` is generated from it by
14
+ * `scripts/generate-design-tokens-json.ts`, and
15
+ * `src/__tests__/design-tokens-json.test.ts` fails if the checked-in file is
16
+ * not byte-identical to a fresh render — so the JSON, the CSS and the runtime
17
+ * palette cannot drift from each other.
18
+ */
19
+ /** One DTCG token. `$type` is inherited from the nearest group that declares it. */
20
+ export interface DesignToken {
21
+ $value: string | number;
22
+ $type?: string;
23
+ $description?: string;
24
+ }
25
+ /** Bloom-specific metadata on a preset group, namespaced per the DTCG `$extensions` rule. */
26
+ export interface PresetExtensions {
27
+ 'so.oxy.bloom': {
28
+ /** The brand seed the engine derived the whole palette from. */
29
+ seed: string;
30
+ /** The tonal scheme variant used with that seed. */
31
+ variant: string;
32
+ /** Who may pick the preset; absent means everyone. */
33
+ gate?: string;
34
+ /** Present when the preset forces a white label in both schemes. */
35
+ label?: string;
36
+ };
37
+ }
38
+ export interface PresetGroup {
39
+ $description: string;
40
+ $extensions: PresetExtensions;
41
+ light: Record<string, DesignToken>;
42
+ dark: Record<string, DesignToken>;
43
+ }
44
+ export interface BloomDesignTokens {
45
+ $description: string;
46
+ color: {
47
+ $type: 'color';
48
+ $description: string;
49
+ } & Record<string, unknown>;
50
+ spacing: {
51
+ $type: 'dimension';
52
+ $description: string;
53
+ } & Record<string, unknown>;
54
+ radius: {
55
+ $type: 'dimension';
56
+ $description: string;
57
+ } & Record<string, unknown>;
58
+ borderWidth: {
59
+ $type: 'dimension';
60
+ $description: string;
61
+ } & Record<string, unknown>;
62
+ typography: {
63
+ $description: string;
64
+ } & Record<string, unknown>;
65
+ }
66
+ /**
67
+ * Turn one resolved token value into an sRGB hex string.
68
+ *
69
+ * The engine emits exactly two forms — `rgb(r g b)` for opaque tokens and
70
+ * `rgba(r, g, b, a)` for the translucent `-subtle` family. Anything else is a
71
+ * change in the engine's output that this file has not been taught about, and
72
+ * throwing at generation time is the only way that surfaces: a silently
73
+ * passed-through CSS string would end up in a C++ colour table as garbage.
74
+ */
75
+ export declare function resolvedColorToHex(value: string): string;
76
+ /** The whole token file, as a plain object. */
77
+ export declare function bloomDesignTokens(): BloomDesignTokens;
78
+ /**
79
+ * The exact bytes of `design-tokens/tokens.json`.
80
+ *
81
+ * Both the generator script and the drift test call this, so neither can be
82
+ * right about the file while the other is wrong.
83
+ */
84
+ export declare function renderBloomTokensJson(): string;
85
+ //# sourceMappingURL=tokens-json.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"tokens-json.d.ts","sourceRoot":"","sources":["../../../../src/design-tokens/tokens-json.ts"],"names":[],"mappings":"AAA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AE,OAAO,CAAC,CAAC;IACpF,UAAU,EAAE;QAAE,YAAY,EAAE,MAAM,CAAA;KAAE,GAAG,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;CAChE;AAiBD;;;;;;;;GAQG;AACH,wBAAgB,kBAAkB,CAAC,KAAK,EAAE,MAAM,GAAG,MAAM,CAqBxD;AAqED,+CAA+C;AAC/C,wBAAgB,iBAAiB,IAAI,iBAAiB,CAkBrD;AAED;;;;;GAKG;AACH,wBAAgB,qBAAqB,IAAI,MAAM,CAE9C"}
@@ -1 +1 @@
1
- {"version":3,"file":"Dialog.web.d.ts","sourceRoot":"","sources":["../../../../src/dialog/Dialog.web.tsx"],"names":[],"mappings":"AA2CA,OAAO,EAOL,4BAA4B,EAK7B,MAAM,aAAa,CAAC;AACrB,OAAO,KAAK,EACV,YAAY,EAGZ,WAAW,EACZ,MAAM,SAAS,CAAC;AAwDjB;;;;;;;;;;;;;;;;;;;;;;GAsBG;AACH,wBAAgB,MAAM,CAAC,EAAE,SAAS,EAAE,GAAG,IAAI,EAAE,EAAE,WAAW,2CAazD;AAobD,OAAO,EAAE,4BAA4B,EAAE,CAAC;AAkPxC;;;;GAIG;AACH,wBAAgB,iBAAiB,CAAC,EAChC,KAAK,EACL,WAAW,EACX,OAAO,EACP,SAAS,GACV,EAAE;IACD,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,OAAO,EAAE,YAAY,EAAE,CAAC;IACxB,SAAS,EAAE,MAAM,IAAI,CAAC;CACvB,2CAgBA;AAkCD;;;;;;;;;;;;;;;;;;GAkBG;AACH,eAAO,MAAM,gBAAgB,8PAG5B,CAAC"}
1
+ {"version":3,"file":"Dialog.web.d.ts","sourceRoot":"","sources":["../../../../src/dialog/Dialog.web.tsx"],"names":[],"mappings":"AA4CA,OAAO,EAOL,4BAA4B,EAK7B,MAAM,aAAa,CAAC;AACrB,OAAO,KAAK,EACV,YAAY,EAGZ,WAAW,EACZ,MAAM,SAAS,CAAC;AAmDjB;;;;;;;;;;;;;;;;;;;;;;GAsBG;AACH,wBAAgB,MAAM,CAAC,EAAE,SAAS,EAAE,GAAG,IAAI,EAAE,EAAE,WAAW,2CAazD;AAobD,OAAO,EAAE,4BAA4B,EAAE,CAAC;AAkPxC;;;;GAIG;AACH,wBAAgB,iBAAiB,CAAC,EAChC,KAAK,EACL,WAAW,EACX,OAAO,EACP,SAAS,GACV,EAAE;IACD,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,OAAO,EAAE,YAAY,EAAE,CAAC;IACxB,SAAS,EAAE,MAAM,IAAI,CAAC;CACvB,2CAgBA;AAkCD;;;;;;;;;;;;;;;;;;GAkBG;AACH,eAAO,MAAM,gBAAgB,8PAG5B,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"Fab.web.d.ts","sourceRoot":"","sources":["../../../../src/fab/Fab.web.tsx"],"names":[],"mappings":"AAAA,OAAO,KAQN,MAAM,OAAO,CAAC;AAKf,OAAO,KAAK,EAAgB,QAAQ,EAAuB,MAAM,SAAS,CAAC;AAE3E,YAAY,EAAE,QAAQ,EAAE,UAAU,EAAE,OAAO,EAAE,YAAY,EAAE,MAAM,SAAS,CAAC;AAoS3E,eAAO,MAAM,GAAG,sCAAwB,CAAC"}
1
+ {"version":3,"file":"Fab.web.d.ts","sourceRoot":"","sources":["../../../../src/fab/Fab.web.tsx"],"names":[],"mappings":"AAAA,OAAO,KAQN,MAAM,OAAO,CAAC;AAMf,OAAO,KAAK,EAAgB,QAAQ,EAAuB,MAAM,SAAS,CAAC;AAE3E,YAAY,EAAE,QAAQ,EAAE,UAAU,EAAE,OAAO,EAAE,YAAY,EAAE,MAAM,SAAS,CAAC;AA+R3E,eAAO,MAAM,GAAG,sCAAwB,CAAC"}
@@ -4,9 +4,11 @@
4
4
  * Web-only. The native counterpart in `apply-font-faces.ts` is a no-op
5
5
  * stub — native loads its fonts through `useFonts(FONT_ASSETS)`, so the file
6
6
  * split keeps the web font payload out of the native bundle entirely.
7
- * Idempotent: safe to call multiple times; subsequent calls early-return
8
- * after the `<style id="bloom-fonts">` tag has been mounted. SSR-safe via
9
- * the `typeof document === 'undefined'` guard.
7
+ * Idempotent: safe to call multiple times; `adoptStyleSheet` keys the sheet by
8
+ * id, so repeat calls re-parse nothing. SSR-safe via its `typeof document`
9
+ * guard. `BloomThemeProvider` calls this on every mount by default, which is
10
+ * why it also has to survive a page whose CSP forbids inline styles — see
11
+ * `styles/adopt-style-sheet.ts`.
10
12
  *
11
13
  * The URLs come from `./font-urls.web`, which imports the `.woff2` files so
12
14
  * the consuming bundler emits them as separate, cacheable assets. See that
@@ -1 +1 @@
1
- {"version":3,"file":"apply-font-faces.web.d.ts","sourceRoot":"","sources":["../../../../src/fonts/apply-font-faces.web.ts"],"names":[],"mappings":"AAUA;;;;;;;;;;;;;;GAcG;AACH,wBAAgB,cAAc,IAAI,IAAI,CAkBrC"}
1
+ {"version":3,"file":"apply-font-faces.web.d.ts","sourceRoot":"","sources":["../../../../src/fonts/apply-font-faces.web.ts"],"names":[],"mappings":"AAWA;;;;;;;;;;;;;;;;GAgBG;AACH,wBAAgB,cAAc,IAAI,IAAI,CAerC"}
@@ -1 +1 @@
1
- {"version":3,"file":"FrostedIconButton.web.d.ts","sourceRoot":"","sources":["../../../../src/frosted-icon-button/FrostedIconButton.web.tsx"],"names":[],"mappings":"AAAA,OAAO,KAQN,MAAM,OAAO,CAAC;AASf,OAAO,KAAK,EAAE,sBAAsB,EAAE,MAAM,SAAS,CAAC;AAEtD,YAAY,EAAE,sBAAsB,EAAE,qBAAqB,EAAE,MAAM,SAAS,CAAC;AA0L7E,eAAO,MAAM,iBAAiB,oDAAsC,CAAC"}
1
+ {"version":3,"file":"FrostedIconButton.web.d.ts","sourceRoot":"","sources":["../../../../src/frosted-icon-button/FrostedIconButton.web.tsx"],"names":[],"mappings":"AAAA,OAAO,KAQN,MAAM,OAAO,CAAC;AAUf,OAAO,KAAK,EAAE,sBAAsB,EAAE,MAAM,SAAS,CAAC;AAEtD,YAAY,EAAE,sBAAsB,EAAE,qBAAqB,EAAE,MAAM,SAAS,CAAC;AAqL7E,eAAO,MAAM,iBAAiB,oDAAsC,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"SpinnerIcon.web.d.ts","sourceRoot":"","sources":["../../../../src/loading/SpinnerIcon.web.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAoB,MAAM,OAAO,CAAC;AACzC,OAAO,EAAoB,KAAK,SAAS,EAAE,MAAM,cAAc,CAAC;AAIhE,UAAU,gBAAgB;IACxB,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,KAAK,CAAC,EAAE,SAAS,CAAC;CACnB;AA4CD;;;;GAIG;AACH,eAAO,MAAM,iBAAiB,8GAE7B,CAAC;AAsBF,eAAO,MAAM,WAAW,EAAE,KAAK,CAAC,EAAE,CAAC,gBAAgB,CAuClD,CAAC"}
1
+ {"version":3,"file":"SpinnerIcon.web.d.ts","sourceRoot":"","sources":["../../../../src/loading/SpinnerIcon.web.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAoB,MAAM,OAAO,CAAC;AACzC,OAAO,EAAoB,KAAK,SAAS,EAAE,MAAM,cAAc,CAAC;AAKhE,UAAU,gBAAgB;IACxB,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,KAAK,CAAC,EAAE,SAAS,CAAC;CACnB;AA4CD;;;;GAIG;AACH,eAAO,MAAM,iBAAiB,8GAE7B,CAAC;AAiBF,eAAO,MAAM,WAAW,EAAE,KAAK,CAAC,EAAE,CAAC,gBAAgB,CAuClD,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../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+ /**
2
+ * Make `css` apply to the document, under the identity `id`.
3
+ *
4
+ * Idempotent in both directions: calling it again with the same CSS re-parses
5
+ * nothing and adopts nothing twice (the usual case — every mount of every
6
+ * instance of a component calls it), and calling it with DIFFERENT CSS under
7
+ * the same id replaces the previous content in place (the theme-dependent case,
8
+ * `BottomSheetBase`'s scrollbar colours).
9
+ *
10
+ * No-op off the web, so a platform-neutral component can call it unguarded.
11
+ */
12
+ export declare function adoptStyleSheet(id: string, css: string): void;
13
+ /**
14
+ * Detach the stylesheet `id`, whichever path installed it.
15
+ *
16
+ * Only for CSS whose lifetime is a component's — `BottomSheetBase` removes its
17
+ * scrollbar rules when the last sheet unmounts. The static per-component CSS is
18
+ * never dropped: it is the same bytes for the life of the page, and removing it
19
+ * on unmount would make a re-mount re-parse it.
20
+ */
21
+ export declare function dropStyleSheet(id: string): void;
22
+ //# sourceMappingURL=adopt-style-sheet.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"adopt-style-sheet.d.ts","sourceRoot":"","sources":["../../../../src/styles/adopt-style-sheet.ts"],"names":[],"mappings":"AAmEA;;;;;;;;;;GAUG;AACH,wBAAgB,eAAe,CAAC,EAAE,EAAE,MAAM,EAAE,GAAG,EAAE,MAAM,GAAG,IAAI,CA+B7D;AAED;;;;;;;GAOG;AACH,wBAAgB,cAAc,CAAC,EAAE,EAAE,MAAM,GAAG,IAAI,CAW/C"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@oxyhq/bloom",
3
- "version": "0.87.0",
3
+ "version": "0.88.0",
4
4
  "packageManager": "bun@1.3.14",
5
5
  "description": "Bloom UI — Oxy ecosystem component library for React Native + Expo + Web",
6
6
  "main": "lib/commonjs/index.js",
@@ -1386,6 +1386,7 @@
1386
1386
  }
1387
1387
  },
1388
1388
  "./design-tokens/theme.css": "./src/design-tokens/theme.css",
1389
+ "./design-tokens/tokens.json": "./src/design-tokens/tokens.json",
1389
1390
  "./package.json": "./package.json"
1390
1391
  },
1391
1392
  "files": [
@@ -1454,7 +1455,8 @@
1454
1455
  "scripts": {
1455
1456
  "generate:exports": "node scripts/generate-platform-exports.mjs",
1456
1457
  "generate:theme-css": "bun scripts/generate-theme-css.ts",
1457
- "prebuild": "node scripts/generate-platform-exports.mjs && bun scripts/generate-theme-css.ts",
1458
+ "generate:tokens-json": "bun scripts/generate-design-tokens-json.ts",
1459
+ "prebuild": "node scripts/generate-platform-exports.mjs && bun scripts/generate-theme-css.ts && bun scripts/generate-design-tokens-json.ts",
1458
1460
  "build": "bob build",
1459
1461
  "postbuild": "node scripts/verify-package.mjs",
1460
1462
  "verify:package": "node scripts/verify-package.mjs",