@oxyhq/bloom 0.19.0 → 0.20.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 (173) hide show
  1. package/lib/commonjs/benefit-list/index.js +119 -0
  2. package/lib/commonjs/benefit-list/index.js.map +1 -0
  3. package/lib/commonjs/benefit-list/types.js +6 -0
  4. package/lib/commonjs/benefit-list/types.js.map +1 -0
  5. package/lib/commonjs/button/Button.web.js +1 -1
  6. package/lib/commonjs/connection-dots/ConnectionDots.js +112 -0
  7. package/lib/commonjs/connection-dots/ConnectionDots.js.map +1 -0
  8. package/lib/commonjs/connection-dots/ConnectionDots.web.js +116 -0
  9. package/lib/commonjs/connection-dots/ConnectionDots.web.js.map +1 -0
  10. package/lib/commonjs/connection-dots/ConnectionDotsBase.js +55 -0
  11. package/lib/commonjs/connection-dots/ConnectionDotsBase.js.map +1 -0
  12. package/lib/commonjs/connection-dots/index.js +13 -0
  13. package/lib/commonjs/connection-dots/index.js.map +1 -0
  14. package/lib/commonjs/connection-dots/index.web.js +13 -0
  15. package/lib/commonjs/connection-dots/index.web.js.map +1 -0
  16. package/lib/commonjs/connection-dots/types.js +6 -0
  17. package/lib/commonjs/connection-dots/types.js.map +1 -0
  18. package/lib/commonjs/design-tokens/color-roles.js +112 -0
  19. package/lib/commonjs/design-tokens/color-roles.js.map +1 -0
  20. package/lib/commonjs/design-tokens/index.js +89 -0
  21. package/lib/commonjs/design-tokens/index.js.map +1 -0
  22. package/lib/commonjs/design-tokens/scales.js +168 -0
  23. package/lib/commonjs/design-tokens/scales.js.map +1 -0
  24. package/lib/commonjs/design-tokens/shadows.js +48 -0
  25. package/lib/commonjs/design-tokens/shadows.js.map +1 -0
  26. package/lib/commonjs/design-tokens/shadows.native.js +53 -0
  27. package/lib/commonjs/design-tokens/shadows.native.js.map +1 -0
  28. package/lib/commonjs/design-tokens/tailwind-preset.js +139 -0
  29. package/lib/commonjs/design-tokens/tailwind-preset.js.map +1 -0
  30. package/lib/commonjs/design-tokens/theme-css.js +98 -0
  31. package/lib/commonjs/design-tokens/theme-css.js.map +1 -0
  32. package/lib/commonjs/index.js +208 -93
  33. package/lib/commonjs/index.js.map +1 -1
  34. package/lib/commonjs/index.web.js +223 -108
  35. package/lib/commonjs/index.web.js.map +1 -1
  36. package/lib/commonjs/text-field/index.js +156 -0
  37. package/lib/commonjs/text-field/index.js.map +1 -1
  38. package/lib/module/benefit-list/index.js +114 -0
  39. package/lib/module/benefit-list/index.js.map +1 -0
  40. package/lib/module/benefit-list/types.js +4 -0
  41. package/lib/module/benefit-list/types.js.map +1 -0
  42. package/lib/module/button/Button.web.js +1 -1
  43. package/lib/module/connection-dots/ConnectionDots.js +107 -0
  44. package/lib/module/connection-dots/ConnectionDots.js.map +1 -0
  45. package/lib/module/connection-dots/ConnectionDots.web.js +111 -0
  46. package/lib/module/connection-dots/ConnectionDots.web.js.map +1 -0
  47. package/lib/module/connection-dots/ConnectionDotsBase.js +50 -0
  48. package/lib/module/connection-dots/ConnectionDotsBase.js.map +1 -0
  49. package/lib/module/connection-dots/index.js +4 -0
  50. package/lib/module/connection-dots/index.js.map +1 -0
  51. package/lib/module/connection-dots/index.web.js +4 -0
  52. package/lib/module/connection-dots/index.web.js.map +1 -0
  53. package/lib/module/connection-dots/types.js +4 -0
  54. package/lib/module/connection-dots/types.js.map +1 -0
  55. package/lib/module/design-tokens/color-roles.js +108 -0
  56. package/lib/module/design-tokens/color-roles.js.map +1 -0
  57. package/lib/module/design-tokens/index.js +27 -0
  58. package/lib/module/design-tokens/index.js.map +1 -0
  59. package/lib/module/design-tokens/scales.js +164 -0
  60. package/lib/module/design-tokens/scales.js.map +1 -0
  61. package/lib/module/design-tokens/shadows.js +43 -0
  62. package/lib/module/design-tokens/shadows.js.map +1 -0
  63. package/lib/module/design-tokens/shadows.native.js +48 -0
  64. package/lib/module/design-tokens/shadows.native.js.map +1 -0
  65. package/lib/module/design-tokens/tailwind-preset.js +136 -0
  66. package/lib/module/design-tokens/tailwind-preset.js.map +1 -0
  67. package/lib/module/design-tokens/theme-css.js +94 -0
  68. package/lib/module/design-tokens/theme-css.js.map +1 -0
  69. package/lib/module/index.js +6 -1
  70. package/lib/module/index.js.map +1 -1
  71. package/lib/module/index.web.js +6 -1
  72. package/lib/module/index.web.js.map +1 -1
  73. package/lib/module/text-field/index.js +158 -2
  74. package/lib/module/text-field/index.js.map +1 -1
  75. package/lib/typescript/commonjs/benefit-list/index.d.ts +6 -0
  76. package/lib/typescript/commonjs/benefit-list/index.d.ts.map +1 -0
  77. package/lib/typescript/commonjs/benefit-list/types.d.ts +35 -0
  78. package/lib/typescript/commonjs/benefit-list/types.d.ts.map +1 -0
  79. package/lib/typescript/commonjs/connection-dots/ConnectionDots.d.ts +4 -0
  80. package/lib/typescript/commonjs/connection-dots/ConnectionDots.d.ts.map +1 -0
  81. package/lib/typescript/commonjs/connection-dots/ConnectionDots.web.d.ts +14 -0
  82. package/lib/typescript/commonjs/connection-dots/ConnectionDots.web.d.ts.map +1 -0
  83. package/lib/typescript/commonjs/connection-dots/ConnectionDotsBase.d.ts +18 -0
  84. package/lib/typescript/commonjs/connection-dots/ConnectionDotsBase.d.ts.map +1 -0
  85. package/lib/typescript/commonjs/connection-dots/index.d.ts +3 -0
  86. package/lib/typescript/commonjs/connection-dots/index.d.ts.map +1 -0
  87. package/lib/typescript/commonjs/connection-dots/index.web.d.ts +3 -0
  88. package/lib/typescript/commonjs/connection-dots/index.web.d.ts.map +1 -0
  89. package/lib/typescript/commonjs/connection-dots/types.d.ts +41 -0
  90. package/lib/typescript/commonjs/connection-dots/types.d.ts.map +1 -0
  91. package/lib/typescript/commonjs/design-tokens/color-roles.d.ts +102 -0
  92. package/lib/typescript/commonjs/design-tokens/color-roles.d.ts.map +1 -0
  93. package/lib/typescript/commonjs/design-tokens/index.d.ts +28 -0
  94. package/lib/typescript/commonjs/design-tokens/index.d.ts.map +1 -0
  95. package/lib/typescript/commonjs/design-tokens/scales.d.ts +152 -0
  96. package/lib/typescript/commonjs/design-tokens/scales.d.ts.map +1 -0
  97. package/lib/typescript/commonjs/design-tokens/shadows.d.ts +34 -0
  98. package/lib/typescript/commonjs/design-tokens/shadows.d.ts.map +1 -0
  99. package/lib/typescript/commonjs/design-tokens/shadows.native.d.ts +19 -0
  100. package/lib/typescript/commonjs/design-tokens/shadows.native.d.ts.map +1 -0
  101. package/lib/typescript/commonjs/design-tokens/tailwind-preset.d.ts +59 -0
  102. package/lib/typescript/commonjs/design-tokens/tailwind-preset.d.ts.map +1 -0
  103. package/lib/typescript/commonjs/design-tokens/theme-css.d.ts +39 -0
  104. package/lib/typescript/commonjs/design-tokens/theme-css.d.ts.map +1 -0
  105. package/lib/typescript/commonjs/index.d.ts +6 -0
  106. package/lib/typescript/commonjs/index.d.ts.map +1 -1
  107. package/lib/typescript/commonjs/index.web.d.ts +6 -0
  108. package/lib/typescript/commonjs/index.web.d.ts.map +1 -1
  109. package/lib/typescript/commonjs/text-field/index.d.ts +14 -1
  110. package/lib/typescript/commonjs/text-field/index.d.ts.map +1 -1
  111. package/lib/typescript/module/benefit-list/index.d.ts +6 -0
  112. package/lib/typescript/module/benefit-list/index.d.ts.map +1 -0
  113. package/lib/typescript/module/benefit-list/types.d.ts +35 -0
  114. package/lib/typescript/module/benefit-list/types.d.ts.map +1 -0
  115. package/lib/typescript/module/connection-dots/ConnectionDots.d.ts +4 -0
  116. package/lib/typescript/module/connection-dots/ConnectionDots.d.ts.map +1 -0
  117. package/lib/typescript/module/connection-dots/ConnectionDots.web.d.ts +14 -0
  118. package/lib/typescript/module/connection-dots/ConnectionDots.web.d.ts.map +1 -0
  119. package/lib/typescript/module/connection-dots/ConnectionDotsBase.d.ts +18 -0
  120. package/lib/typescript/module/connection-dots/ConnectionDotsBase.d.ts.map +1 -0
  121. package/lib/typescript/module/connection-dots/index.d.ts +3 -0
  122. package/lib/typescript/module/connection-dots/index.d.ts.map +1 -0
  123. package/lib/typescript/module/connection-dots/index.web.d.ts +3 -0
  124. package/lib/typescript/module/connection-dots/index.web.d.ts.map +1 -0
  125. package/lib/typescript/module/connection-dots/types.d.ts +41 -0
  126. package/lib/typescript/module/connection-dots/types.d.ts.map +1 -0
  127. package/lib/typescript/module/design-tokens/color-roles.d.ts +102 -0
  128. package/lib/typescript/module/design-tokens/color-roles.d.ts.map +1 -0
  129. package/lib/typescript/module/design-tokens/index.d.ts +28 -0
  130. package/lib/typescript/module/design-tokens/index.d.ts.map +1 -0
  131. package/lib/typescript/module/design-tokens/scales.d.ts +152 -0
  132. package/lib/typescript/module/design-tokens/scales.d.ts.map +1 -0
  133. package/lib/typescript/module/design-tokens/shadows.d.ts +34 -0
  134. package/lib/typescript/module/design-tokens/shadows.d.ts.map +1 -0
  135. package/lib/typescript/module/design-tokens/shadows.native.d.ts +19 -0
  136. package/lib/typescript/module/design-tokens/shadows.native.d.ts.map +1 -0
  137. package/lib/typescript/module/design-tokens/tailwind-preset.d.ts +59 -0
  138. package/lib/typescript/module/design-tokens/tailwind-preset.d.ts.map +1 -0
  139. package/lib/typescript/module/design-tokens/theme-css.d.ts +39 -0
  140. package/lib/typescript/module/design-tokens/theme-css.d.ts.map +1 -0
  141. package/lib/typescript/module/index.d.ts +6 -0
  142. package/lib/typescript/module/index.d.ts.map +1 -1
  143. package/lib/typescript/module/index.web.d.ts +6 -0
  144. package/lib/typescript/module/index.web.d.ts.map +1 -1
  145. package/lib/typescript/module/text-field/index.d.ts +14 -1
  146. package/lib/typescript/module/text-field/index.d.ts.map +1 -1
  147. package/package.json +50 -1
  148. package/src/__tests__/BenefitList.test.tsx +108 -0
  149. package/src/__tests__/ConnectionDots.test.tsx +86 -0
  150. package/src/__tests__/TextFieldFloatingLabel.test.tsx +93 -0
  151. package/src/__tests__/design-tokens.test.ts +169 -0
  152. package/src/benefit-list/BenefitList.stories.tsx +50 -0
  153. package/src/benefit-list/index.tsx +133 -0
  154. package/src/benefit-list/types.ts +36 -0
  155. package/src/button/Button.web.tsx +1 -1
  156. package/src/connection-dots/ConnectionDots.stories.tsx +54 -0
  157. package/src/connection-dots/ConnectionDots.tsx +139 -0
  158. package/src/connection-dots/ConnectionDots.web.tsx +122 -0
  159. package/src/connection-dots/ConnectionDotsBase.tsx +62 -0
  160. package/src/connection-dots/index.ts +2 -0
  161. package/src/connection-dots/index.web.ts +2 -0
  162. package/src/connection-dots/types.ts +41 -0
  163. package/src/design-tokens/color-roles.ts +110 -0
  164. package/src/design-tokens/index.ts +45 -0
  165. package/src/design-tokens/scales.ts +134 -0
  166. package/src/design-tokens/shadows.native.ts +44 -0
  167. package/src/design-tokens/shadows.ts +42 -0
  168. package/src/design-tokens/tailwind-preset.ts +139 -0
  169. package/src/design-tokens/theme-css.ts +99 -0
  170. package/src/index.ts +33 -0
  171. package/src/index.web.ts +33 -0
  172. package/src/text-field/TextField.stories.tsx +46 -0
  173. package/src/text-field/index.tsx +212 -1
@@ -0,0 +1,4 @@
1
+ import React from 'react';
2
+ import type { ConnectionDotsProps } from './types';
3
+ export declare const ConnectionDots: React.NamedExoticComponent<ConnectionDotsProps>;
4
+ //# sourceMappingURL=ConnectionDots.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ConnectionDots.d.ts","sourceRoot":"","sources":["../../../../src/connection-dots/ConnectionDots.tsx"],"names":[],"mappings":"AAAA,OAAO,KAA0B,MAAM,OAAO,CAAC;AAe/C,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,SAAS,CAAC;AA0HnD,eAAO,MAAM,cAAc,iDAAgC,CAAC"}
@@ -0,0 +1,14 @@
1
+ import React from 'react';
2
+ import type { ConnectionDotsProps } from './types';
3
+ /**
4
+ * CSS keyframes powering the ellipsis shimmer. Mirrors the native Reanimated
5
+ * triangle wave: each dot's opacity rises to 1 and falls back to a dim floor,
6
+ * with a per-dot `animation-delay` sweeping the bright crest left→right.
7
+ *
8
+ * A `prefers-reduced-motion: reduce` media query pins every dot to full opacity,
9
+ * matching the native `useReducedMotion` branch — defence-in-depth alongside the
10
+ * JS `matchMedia` gate below (which also stops emitting the `animation` prop).
11
+ */
12
+ export declare const BLOOM_CONNECTION_DOTS_CSS = "\n@keyframes bloomConnectionDotsWave { 0%, 100% { opacity: 0.25; } 50% { opacity: 1; } }\n@media (prefers-reduced-motion: reduce) {\n [data-bloom-connection-dot] { animation: none !important; opacity: 1 !important; }\n}\n";
13
+ export declare const ConnectionDots: React.NamedExoticComponent<ConnectionDotsProps>;
14
+ //# sourceMappingURL=ConnectionDots.web.d.ts.map
@@ -0,0 +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;AAKzD,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,SAAS,CAAC;AASnD;;;;;;;;GAQG;AACH,eAAO,MAAM,yBAAyB,mOAKrC,CAAC;AA4FF,eAAO,MAAM,cAAc,iDAAgC,CAAC"}
@@ -0,0 +1,18 @@
1
+ import React from 'react';
2
+ import type { ConnectionDotsProps } from './types';
3
+ export interface ConnectionDotsBaseProps extends Pick<ConnectionDotsProps, 'left' | 'right' | 'accessibilityLabel' | 'className' | 'style'> {
4
+ /** The platform-specific animated dots row (built by the native/web fork). */
5
+ dots: React.ReactNode;
6
+ }
7
+ /**
8
+ * Shared layout + accessibility chrome for {@link ConnectionDots}:
9
+ *
10
+ * leftSlot · (animated ellipsis dots) · rightSlot
11
+ *
12
+ * The dots themselves are supplied by the platform fork (`ConnectionDots.tsx`
13
+ * native / `ConnectionDots.web.tsx` web) because the shimmer animation impl
14
+ * differs (Reanimated vs CSS). This base owns the row layout, the slot wrappers,
15
+ * and the single accessibility label that stands in for the decorative dots.
16
+ */
17
+ export declare function ConnectionDotsBase({ left, right, dots, accessibilityLabel, className, style, }: ConnectionDotsBaseProps): import("react/jsx-runtime").JSX.Element;
18
+ //# sourceMappingURL=ConnectionDotsBase.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ConnectionDotsBase.d.ts","sourceRoot":"","sources":["../../../../src/connection-dots/ConnectionDotsBase.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAI1B,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,SAAS,CAAC;AAEnD,MAAM,WAAW,uBACf,SAAQ,IAAI,CACV,mBAAmB,EACnB,MAAM,GAAG,OAAO,GAAG,oBAAoB,GAAG,WAAW,GAAG,OAAO,CAChE;IACD,8EAA8E;IAC9E,IAAI,EAAE,KAAK,CAAC,SAAS,CAAC;CACvB;AAED;;;;;;;;;GASG;AACH,wBAAgB,kBAAkB,CAAC,EACjC,IAAI,EACJ,KAAK,EACL,IAAI,EACJ,kBAAiC,EACjC,SAAS,EACT,KAAK,GACN,EAAE,uBAAuB,2CA6BzB"}
@@ -0,0 +1,3 @@
1
+ export { ConnectionDots } from './ConnectionDots';
2
+ export type { ConnectionDotsProps } from './types';
3
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/connection-dots/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,cAAc,EAAE,MAAM,kBAAkB,CAAC;AAClD,YAAY,EAAE,mBAAmB,EAAE,MAAM,SAAS,CAAC"}
@@ -0,0 +1,3 @@
1
+ export { ConnectionDots } from './ConnectionDots.web';
2
+ export type { ConnectionDotsProps } from './types';
3
+ //# sourceMappingURL=index.web.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.web.d.ts","sourceRoot":"","sources":["../../../../src/connection-dots/index.web.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,cAAc,EAAE,MAAM,sBAAsB,CAAC;AACtD,YAAY,EAAE,mBAAmB,EAAE,MAAM,SAAS,CAAC"}
@@ -0,0 +1,41 @@
1
+ import type { ReactNode } from 'react';
2
+ import type { StyleProp, ViewStyle } from 'react-native';
3
+ export interface ConnectionDotsProps {
4
+ /**
5
+ * Left-hand content — typically a logo or avatar of the first party in a
6
+ * link/consent flow. Rendered as-is.
7
+ */
8
+ left: ReactNode;
9
+ /**
10
+ * Right-hand content — typically a logo or avatar of the second party.
11
+ * Rendered as-is.
12
+ */
13
+ right: ReactNode;
14
+ /**
15
+ * Number of ellipsis dots animating between the two slots.
16
+ * @default 6
17
+ */
18
+ dotCount?: number;
19
+ /**
20
+ * Diameter of each dot in px.
21
+ * @default 6
22
+ */
23
+ dotSize?: number;
24
+ /**
25
+ * Accessibility label for the whole connection band. Read by screen readers in
26
+ * place of the (decorative) dots.
27
+ * @default 'Connecting'
28
+ */
29
+ accessibilityLabel?: string;
30
+ /** NativeWind className passthrough on the outer row. */
31
+ className?: string;
32
+ /** Style passthrough on the outer row. */
33
+ style?: StyleProp<ViewStyle>;
34
+ /**
35
+ * Force-disable the shimmer regardless of the OS reduced-motion setting.
36
+ * (When omitted, the component reads the platform reduced-motion preference
37
+ * and renders the dots statically when it is on.)
38
+ */
39
+ reducedMotion?: boolean;
40
+ }
41
+ //# sourceMappingURL=types.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../../src/connection-dots/types.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AACvC,OAAO,KAAK,EAAE,SAAS,EAAE,SAAS,EAAE,MAAM,cAAc,CAAC;AAEzD,MAAM,WAAW,mBAAmB;IAClC;;;OAGG;IACH,IAAI,EAAE,SAAS,CAAC;IAChB;;;OAGG;IACH,KAAK,EAAE,SAAS,CAAC;IACjB;;;OAGG;IACH,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB;;;OAGG;IACH,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB;;;;OAIG;IACH,kBAAkB,CAAC,EAAE,MAAM,CAAC;IAC5B,yDAAyD;IACzD,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,0CAA0C;IAC1C,KAAK,CAAC,EAAE,SAAS,CAAC,SAAS,CAAC,CAAC;IAC7B;;;;OAIG;IACH,aAAa,CAAC,EAAE,OAAO,CAAC;CACzB"}
@@ -0,0 +1,102 @@
1
+ /**
2
+ * Semantic color-role vocabulary for the Oxy Unified Design Language.
3
+ *
4
+ * Every role is an ALIAS onto one of Bloom's existing canonical theme tokens
5
+ * (`--background`, `--surface`, `--primary`, …) — the SINGLE source of resolved
6
+ * color values produced by `getResolvedTokens` and written to the document root
7
+ * (web) / `rootVariables` (native) by `BloomThemeProvider`. No color VALUE is
8
+ * invented here: a role's value is the `var(--canonical)` reference, so it stays
9
+ * driven by the active light/dark mode and color preset automatically.
10
+ *
11
+ * The maps are consumed by the Bloom Tailwind preset (`tailwind-preset.ts`),
12
+ * which slots them into `theme.extend.{backgroundColor,textColor,borderColor}`.
13
+ * Because the values are `var(--x)` strings, the SAME class names resolve on
14
+ * Tailwind (web) and NativeWind (native): web reads the CSS custom property from
15
+ * `document.documentElement`; native reads it from react-native-css's
16
+ * `rootVariables` family — both populated by Bloom from one pipeline.
17
+ *
18
+ * Web CSS-var contract (see Bloom AGENTS.md): base `--x` tokens already resolve
19
+ * to a FULL `rgb(...)` color at runtime, so the role values reference them with
20
+ * `var(--x)` directly — NEVER `hsl(var(--x))`.
21
+ *
22
+ * ADDITIVE: these are NEW utility names (`bg-fill`, `text-text-tertiary`,
23
+ * `border-border-image`, …). They do not touch the existing app-defined color
24
+ * utilities (`bg-background`, `text-muted-foreground`, …), which keep working.
25
+ */
26
+ /**
27
+ * Surface / fill roles → background-color utilities (`bg-<role>`).
28
+ *
29
+ * | role | utility | canonical token | rationale |
30
+ * | ----------------- | ------------------ | ----------------- | ------------------------------------------- |
31
+ * | bg | bg-bg | --background | the page background |
32
+ * | fill | bg-fill | --card | default raised surface (cards/sheets) |
33
+ * | fill-secondary | bg-fill-secondary | --muted | muted/secondary fill |
34
+ * | fill-hover | bg-fill-hover | --accent | hover state of a secondary fill |
35
+ * | fill-brand | bg-fill-brand | --primary | brand-colored fill |
36
+ * | fill-brand-hover | bg-fill-brand-hover| --ring | hover of brand fill (ring == primary hue) |
37
+ * | fill-inverse | bg-fill-inverse | --foreground | inverse (high-contrast) fill |
38
+ * | fill-inverse-hover| bg-fill-inverse-hov| --muted-foreground| hover of inverse fill |
39
+ * | fill-placeholder | bg-fill-placeholder| --muted | disabled/placeholder surface |
40
+ */
41
+ export declare const FILL_ROLES: {
42
+ readonly bg: `var(--${string})`;
43
+ readonly fill: `var(--${string})`;
44
+ readonly 'fill-secondary': `var(--${string})`;
45
+ readonly 'fill-hover': `var(--${string})`;
46
+ readonly 'fill-brand': `var(--${string})`;
47
+ readonly 'fill-brand-hover': `var(--${string})`;
48
+ readonly 'fill-inverse': `var(--${string})`;
49
+ readonly 'fill-inverse-hover': `var(--${string})`;
50
+ readonly 'fill-placeholder': `var(--${string})`;
51
+ };
52
+ /**
53
+ * Text roles → text-color utilities (`text-<role>`).
54
+ *
55
+ * Tailwind prefixes text-color utilities with `text-`, so a role literally
56
+ * named `text` becomes the utility `text-text`, `text-secondary` → the utility
57
+ * `text-text-secondary`, etc. (matches the namespaced spec).
58
+ *
59
+ * | role | utility | canonical token | rationale |
60
+ * | ---------------- | --------------------- | --------------------- | ---------------------------------- |
61
+ * | text | text-text | --foreground | primary text |
62
+ * | text-secondary | text-text-secondary | --muted-foreground | secondary text |
63
+ * | text-tertiary | text-text-tertiary | --muted-foreground | tertiary/least-emphasis text |
64
+ * | text-inverse | text-text-inverse | --primary-foreground | text on a brand fill |
65
+ * | text-fixed-light | text-text-fixed-light | --primary-foreground | always-light text (on brand) |
66
+ * | text-placeholder | text-text-placeholder | --muted-foreground | placeholder/input hint |
67
+ */
68
+ export declare const TEXT_ROLES: {
69
+ readonly text: `var(--${string})`;
70
+ readonly 'text-secondary': `var(--${string})`;
71
+ readonly 'text-tertiary': `var(--${string})`;
72
+ readonly 'text-inverse': `var(--${string})`;
73
+ readonly 'text-fixed-light': `var(--${string})`;
74
+ readonly 'text-placeholder': `var(--${string})`;
75
+ };
76
+ /**
77
+ * Border roles → border-color utilities (`border-<role>`).
78
+ *
79
+ * | role | utility | canonical token | rationale |
80
+ * | ------------------ | ----------------------- | --------------- | ------------------------------------------ |
81
+ * | border | border-border | --border | default border |
82
+ * | border-image | border-border-image | --border | hairline border color (0.5px width helper) |
83
+ * | border-secondary | border-border-secondary | --input | secondary/softer border |
84
+ * | border-input | border-border-input | --input | input field border |
85
+ * | border-input-active| border-border-input-active | --ring | focused input border (== primary) |
86
+ *
87
+ * NOTE: the hairline 0.5px WIDTH for `border-image` is shipped as a separate
88
+ * `borderWidth` scale entry (`border-hairline`) in the preset; the color role
89
+ * above only provides the matching color. Consumers compose them:
90
+ * `border-hairline border-border-image`.
91
+ */
92
+ export declare const BORDER_ROLES: {
93
+ readonly border: `var(--${string})`;
94
+ readonly 'border-image': `var(--${string})`;
95
+ readonly 'border-secondary': `var(--${string})`;
96
+ readonly 'border-input': `var(--${string})`;
97
+ readonly 'border-input-active': `var(--${string})`;
98
+ };
99
+ export type FillRole = keyof typeof FILL_ROLES;
100
+ export type TextRole = keyof typeof TEXT_ROLES;
101
+ export type BorderRole = keyof typeof BORDER_ROLES;
102
+ //# sourceMappingURL=color-roles.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"color-roles.d.ts","sourceRoot":"","sources":["../../../../src/design-tokens/color-roles.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;GAwBG;AAOH;;;;;;;;;;;;;;GAcG;AACH,eAAO,MAAM,UAAU;;;;;;;;;;CAUb,CAAC;AAEX;;;;;;;;;;;;;;;GAeG;AACH,eAAO,MAAM,UAAU;;;;;;;CAOb,CAAC;AAEX;;;;;;;;;;;;;;;GAeG;AACH,eAAO,MAAM,YAAY;;;;;;CAMf,CAAC;AAEX,MAAM,MAAM,QAAQ,GAAG,MAAM,OAAO,UAAU,CAAC;AAC/C,MAAM,MAAM,QAAQ,GAAG,MAAM,OAAO,UAAU,CAAC;AAC/C,MAAM,MAAM,UAAU,GAAG,MAAM,OAAO,YAAY,CAAC"}
@@ -0,0 +1,28 @@
1
+ /**
2
+ * `@oxyhq/bloom/design-tokens` — the centralized, semantic design-token
3
+ * vocabulary for the Oxy Unified Design Language.
4
+ *
5
+ * Exposes:
6
+ * - `bloomTailwindPreset` — the Tailwind/NativeWind preset (web + native) that
7
+ * adds the semantic utility classes (`bg-fill`, `text-text-tertiary`,
8
+ * `p-space-8`, `rounded-radius-20`, `text-body`, `font-body`, `shadow-s`).
9
+ * - `bloomThemeCss` / `bloomThemeBlock` — the Tailwind v4 `@theme` equivalent
10
+ * for CSS-configured web apps.
11
+ * - The raw token maps (`FILL_ROLES`, `TEXT_ROLES`, `BORDER_ROLES`, `SPACING`,
12
+ * `RADIUS`, `TYPOGRAPHY`, `SHADOW_BOX`) for direct programmatic use.
13
+ * - `bloomShadowStyle` — platform-correct shadow style object (web box-shadow /
14
+ * native elevation) so a consumer writes one call for both platforms.
15
+ *
16
+ * Additive and non-breaking: every export here is NEW. It does not change any
17
+ * existing Bloom token, theme value, or utility class.
18
+ */
19
+ export { bloomTailwindPreset } from './tailwind-preset';
20
+ export type { TailwindPreset, TailwindPresetThemeExtend, } from './tailwind-preset';
21
+ export { bloomThemeCss, bloomThemeBlock } from './theme-css';
22
+ export { FILL_ROLES, TEXT_ROLES, BORDER_ROLES, } from './color-roles';
23
+ export type { FillRole, TextRole, BorderRole } from './color-roles';
24
+ export { SPACING, RADIUS, BORDER_WIDTH, TYPOGRAPHY, FONT_FAMILY_VARS, } from './scales';
25
+ export type { TypeRole, TypeRoleName } from './scales';
26
+ export { SHADOW_BOX, bloomShadowStyle } from './shadows';
27
+ export type { ShadowRole } from './shadows';
28
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/design-tokens/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;GAiBG;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;AAE7D,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,152 @@
1
+ /**
2
+ * Numeric design-token scales for the Oxy Unified Design Language.
3
+ *
4
+ * These are platform-agnostic plain numbers / CSS strings consumed by the Bloom
5
+ * Tailwind preset (`tailwind-preset.ts`). The SAME keys produce the SAME utility
6
+ * class names on Tailwind (web) and NativeWind (native):
7
+ * - spacing → `p-space-8`, `gap-space-20`, `px-screen-margin`, `m-space-16`
8
+ * - radius → `rounded-radius-20`
9
+ * - type → `font-body` (family/weight) + `text-body` (size/lineHeight)
10
+ * - shadow → `shadow-s`, `shadow-m`
11
+ *
12
+ * ADDITIVE: every key is namespaced (`space-*`, `radius-*`, the typography role
13
+ * names, `shadow-s/m`) and does not collide with Tailwind's built-in numeric
14
+ * scale (`p-4`, `rounded-lg`, `text-sm`) — those keep working unchanged.
15
+ */
16
+ /**
17
+ * Spacing scale (px). Consumed via every Tailwind spacing utility:
18
+ * `p-space-8`, `px-space-16`, `gap-space-20`, `m-space-24`, `py-space-12`, …
19
+ *
20
+ * `screen-margin` is the standard page gutter (left/right inset). Default 20px —
21
+ * matches Bloom's existing `space.xl` and the `Dialog` default `contentPadding`.
22
+ */
23
+ export declare const SPACING: {
24
+ readonly 'space-2': 2;
25
+ readonly 'space-4': 4;
26
+ readonly 'space-8': 8;
27
+ readonly 'space-12': 12;
28
+ readonly 'space-16': 16;
29
+ readonly 'space-20': 20;
30
+ readonly 'space-24': 24;
31
+ readonly 'space-32': 32;
32
+ readonly 'screen-margin': 20;
33
+ };
34
+ /**
35
+ * Corner-radius scale (px). Consumed via `rounded-radius-*`:
36
+ * `rounded-radius-8`, `rounded-radius-12`, `rounded-radius-20`,
37
+ * `rounded-radius-28`, `rounded-radius-max` (pill / circle).
38
+ */
39
+ export declare const RADIUS: {
40
+ readonly 'radius-8': 8;
41
+ readonly 'radius-12': 12;
42
+ readonly 'radius-20': 20;
43
+ readonly 'radius-28': 28;
44
+ readonly 'radius-max': 9999;
45
+ };
46
+ /**
47
+ * Border-width helpers. `border-hairline` is the 0.5px hairline that pairs with
48
+ * the `border-border-image` color role. (Tailwind's default `border` = 1px
49
+ * stays untouched.)
50
+ */
51
+ export declare const BORDER_WIDTH: {
52
+ readonly hairline: 0.5;
53
+ };
54
+ /**
55
+ * One typography role. `size`/`lineHeight` are px; `weight` is a CSS font-weight
56
+ * string; `family` selects the Bloom font CSS var (`sans` = body/UI,
57
+ * `display` = headings/serif).
58
+ *
59
+ * The Tailwind preset splits each role into TWO utilities so a consumer can
60
+ * apply the size/leading and the family/weight independently or together:
61
+ * - `text-<role>` → `fontSize` + `lineHeight` (via theme.fontSize)
62
+ * - `font-<role>` → `fontFamily` + `fontWeight` (via theme.fontFamily, which
63
+ * maps a key to a [family, { fontWeight }] tuple)
64
+ */
65
+ export interface TypeRole {
66
+ /** Font size in px. */
67
+ size: number;
68
+ /** Line height in px. */
69
+ lineHeight: number;
70
+ /** CSS font-weight (string for Tailwind/RN parity). */
71
+ weight: '400' | '500' | '600' | '700';
72
+ /** Which Bloom font family CSS var to use. */
73
+ family: 'sans' | 'display';
74
+ }
75
+ /**
76
+ * The coherent Oxy type scale. Sizes climb 11 → 28; line-heights use a ~1.3–1.5
77
+ * leading for body roles and tighter leading for large titles.
78
+ *
79
+ * | role | size/line | weight | family | usage |
80
+ * | --------------- | --------- | ------ | ------- | ------------------------------ |
81
+ * | caption | 11 / 14 | 400 | sans | timestamps, meta, fine print |
82
+ * | bodySmall | 13 / 18 | 400 | sans | secondary body, captions |
83
+ * | bodyTitleSmall | 13 / 18 | 600 | sans | small emphasized labels |
84
+ * | body | 15 / 22 | 400 | sans | default body text |
85
+ * | subtitle | 17 / 24 | 500 | sans | list subtitles, lead-ins |
86
+ * | sectionTitle | 20 / 26 | 600 | sans | section headers |
87
+ * | headerBold | 28 / 34 | 700 | display | screen / page titles |
88
+ * | buttonLarge | 17 / 22 | 600 | sans | primary button label |
89
+ */
90
+ export declare const TYPOGRAPHY: {
91
+ readonly caption: {
92
+ readonly size: 11;
93
+ readonly lineHeight: 14;
94
+ readonly weight: "400";
95
+ readonly family: "sans";
96
+ };
97
+ readonly bodySmall: {
98
+ readonly size: 13;
99
+ readonly lineHeight: 18;
100
+ readonly weight: "400";
101
+ readonly family: "sans";
102
+ };
103
+ readonly bodyTitleSmall: {
104
+ readonly size: 13;
105
+ readonly lineHeight: 18;
106
+ readonly weight: "600";
107
+ readonly family: "sans";
108
+ };
109
+ readonly body: {
110
+ readonly size: 15;
111
+ readonly lineHeight: 22;
112
+ readonly weight: "400";
113
+ readonly family: "sans";
114
+ };
115
+ readonly subtitle: {
116
+ readonly size: 17;
117
+ readonly lineHeight: 24;
118
+ readonly weight: "500";
119
+ readonly family: "sans";
120
+ };
121
+ readonly sectionTitle: {
122
+ readonly size: 20;
123
+ readonly lineHeight: 26;
124
+ readonly weight: "600";
125
+ readonly family: "sans";
126
+ };
127
+ readonly headerBold: {
128
+ readonly size: 28;
129
+ readonly lineHeight: 34;
130
+ readonly weight: "700";
131
+ readonly family: "display";
132
+ };
133
+ readonly buttonLarge: {
134
+ readonly size: 17;
135
+ readonly lineHeight: 22;
136
+ readonly weight: "600";
137
+ readonly family: "sans";
138
+ };
139
+ };
140
+ export type TypeRoleName = keyof typeof TYPOGRAPHY;
141
+ /**
142
+ * Bloom font-family CSS-var stacks, keyed by the `family` field above. Web reads
143
+ * `var(--bloom-font-*)` (set by `applyFontFaces`); the preset falls back to the
144
+ * literal stack so utilities still resolve before the vars are injected and on
145
+ * native (where NativeWind passes the family string straight through).
146
+ */
147
+ export declare const FONT_FAMILY_VARS: {
148
+ readonly sans: "var(--bloom-font-sans)";
149
+ readonly display: "var(--bloom-font-display)";
150
+ readonly mono: "var(--bloom-font-mono)";
151
+ };
152
+ //# sourceMappingURL=scales.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"scales.d.ts","sourceRoot":"","sources":["../../../../src/design-tokens/scales.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;GAcG;AAMH;;;;;;GAMG;AACH,eAAO,MAAM,OAAO;;;;;;;;;;CAUV,CAAC;AAMX;;;;GAIG;AACH,eAAO,MAAM,MAAM;;;;;;CAMT,CAAC;AAMX;;;;GAIG;AACH,eAAO,MAAM,YAAY;;CAEf,CAAC;AAMX;;;;;;;;;;GAUG;AACH,MAAM,WAAW,QAAQ;IACvB,uBAAuB;IACvB,IAAI,EAAE,MAAM,CAAC;IACb,yBAAyB;IACzB,UAAU,EAAE,MAAM,CAAC;IACnB,uDAAuD;IACvD,MAAM,EAAE,KAAK,GAAG,KAAK,GAAG,KAAK,GAAG,KAAK,CAAC;IACtC,8CAA8C;IAC9C,MAAM,EAAE,MAAM,GAAG,SAAS,CAAC;CAC5B;AAED;;;;;;;;;;;;;;GAcG;AACH,eAAO,MAAM,UAAU;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CASsB,CAAC;AAE9C,MAAM,MAAM,YAAY,GAAG,MAAM,OAAO,UAAU,CAAC;AAEnD;;;;;GAKG;AACH,eAAO,MAAM,gBAAgB;;;;CAInB,CAAC"}
@@ -0,0 +1,34 @@
1
+ import { type ViewStyle } from 'react-native';
2
+ /**
3
+ * Elevation / shadow tokens for the Oxy Unified Design Language.
4
+ *
5
+ * Two roles: `shadow-s` (subtle raise — cards, chips) and `shadow-m` (overlays —
6
+ * menus, popovers, dialogs). Consumers write ONE class (`shadow-s` / `shadow-m`)
7
+ * and Bloom owns the platform split:
8
+ * - Web: the Bloom Tailwind preset registers `boxShadow.s` / `boxShadow.m`
9
+ * (the `SHADOW_BOX` strings below) → `shadow-s` / `shadow-m` utilities.
10
+ * - Native: NativeWind cannot translate a multi-layer web `box-shadow` to RN
11
+ * elevation reliably, so apps that need the shadow on a React Native surface
12
+ * apply the matching style object from `bloomShadowStyle('s' | 'm')` (this
13
+ * module is platform-forked: `.native.ts` returns RN `shadow*`/`elevation`).
14
+ *
15
+ * This default file is the WEB / consumer-tsc variant. Metro selects the sibling
16
+ * `shadows.native.ts` on iOS/Android. Web bundlers and a consumer's `tsc` see
17
+ * this file (the `box-shadow` CSS string path), matching Bloom's existing
18
+ * `.native`/`.web` split convention.
19
+ */
20
+ export type ShadowRole = 's' | 'm';
21
+ /**
22
+ * Web `box-shadow` strings. Subtle, brand-neutral elevation that reads on both
23
+ * light and dark surfaces. Registered by the Tailwind preset as `boxShadow.s/m`.
24
+ */
25
+ export declare const SHADOW_BOX: Record<ShadowRole, string>;
26
+ /**
27
+ * Return the platform-appropriate shadow style for a role.
28
+ *
29
+ * On WEB this returns a `{ boxShadow }` style object (so it can also be applied
30
+ * inline without Tailwind). The `.native.ts` fork returns RN
31
+ * `shadowColor/shadowOffset/shadowOpacity/shadowRadius/elevation`.
32
+ */
33
+ export declare function bloomShadowStyle(role: ShadowRole): ViewStyle;
34
+ //# sourceMappingURL=shadows.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"shadows.d.ts","sourceRoot":"","sources":["../../../../src/design-tokens/shadows.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,SAAS,EAAE,MAAM,cAAc,CAAC;AAE9C;;;;;;;;;;;;;;;;;GAiBG;AAEH,MAAM,MAAM,UAAU,GAAG,GAAG,GAAG,GAAG,CAAC;AAEnC;;;GAGG;AACH,eAAO,MAAM,UAAU,EAAE,MAAM,CAAC,UAAU,EAAE,MAAM,CAGjD,CAAC;AAEF;;;;;;GAMG;AACH,wBAAgB,gBAAgB,CAAC,IAAI,EAAE,UAAU,GAAG,SAAS,CAE5D"}
@@ -0,0 +1,19 @@
1
+ import { type ViewStyle } from 'react-native';
2
+ /**
3
+ * NATIVE variant of the shadow tokens (see `shadows.ts` for the rationale and
4
+ * the web `box-shadow` path). Metro selects this file on iOS/Android.
5
+ *
6
+ * The `SHADOW_BOX` map is kept identical to the web file so any code that reads
7
+ * the raw string (e.g. to feed a NativeWind `boxShadow` utility on a host that
8
+ * supports it) stays in lockstep; the canonical native styling path is
9
+ * `bloomShadowStyle`, which returns RN elevation + shadow props tuned to match
10
+ * the web `shadow-s` / `shadow-m` visual weight.
11
+ */
12
+ export type ShadowRole = 's' | 'm';
13
+ export declare const SHADOW_BOX: Record<ShadowRole, string>;
14
+ /**
15
+ * RN shadow/elevation style matching the web `shadow-<role>` weight. Apply to a
16
+ * React Native `View`/surface: `style={bloomShadowStyle('m')}`.
17
+ */
18
+ export declare function bloomShadowStyle(role: ShadowRole): ViewStyle;
19
+ //# sourceMappingURL=shadows.native.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"shadows.native.d.ts","sourceRoot":"","sources":["../../../../src/design-tokens/shadows.native.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,SAAS,EAAE,MAAM,cAAc,CAAC;AAE9C;;;;;;;;;GASG;AAEH,MAAM,MAAM,UAAU,GAAG,GAAG,GAAG,GAAG,CAAC;AAEnC,eAAO,MAAM,UAAU,EAAE,MAAM,CAAC,UAAU,EAAE,MAAM,CAGjD,CAAC;AAmBF;;;GAGG;AACH,wBAAgB,gBAAgB,CAAC,IAAI,EAAE,UAAU,GAAG,SAAS,CAE5D"}
@@ -0,0 +1,59 @@
1
+ /**
2
+ * The Bloom Tailwind / NativeWind preset — the SINGLE opt-in that gives every
3
+ * Oxy app the same semantic design-token utility classes.
4
+ *
5
+ * Consumers add it to their Tailwind config:
6
+ *
7
+ * // tailwind.config.js (web Tailwind v3/v4 AND native NativeWind)
8
+ * const { bloomTailwindPreset } = require('@oxyhq/bloom/tailwind-preset');
9
+ * module.exports = {
10
+ * presets: [bloomTailwindPreset],
11
+ * content: [ ...existing globs ],
12
+ * theme: { extend: { ...existing app overrides } },
13
+ * };
14
+ *
15
+ * The preset only EXTENDS `theme` (everything lives under `theme.extend`), so it
16
+ * is purely additive: existing Tailwind built-ins (`p-4`, `rounded-lg`,
17
+ * `text-sm`) and the app's own `var(--x)`-backed color utilities keep working.
18
+ *
19
+ * Cross-platform: NativeWind reads the same `tailwind.config.js`, so the SAME
20
+ * class names (`bg-fill`, `text-text-tertiary`, `p-space-8`, `rounded-radius-20`,
21
+ * `text-body`, `font-body`, `shadow-s`) resolve on web (Tailwind → CSS) and
22
+ * native (NativeWind → react-native-css). Color roles are `var(--x)` references
23
+ * that Bloom's `BloomThemeProvider` populates at runtime on both platforms.
24
+ *
25
+ * Type: returned as a `TailwindPreset` (a structural subset of Tailwind's
26
+ * `Config`) so Bloom does not need to depend on `tailwindcss` types.
27
+ */
28
+ /** A Tailwind `fontSize` value: `[size, { lineHeight }]`. */
29
+ type FontSizeValue = [string, {
30
+ lineHeight: string;
31
+ }];
32
+ /** A Tailwind `fontFamily` value: `[family, { fontWeight }]`. */
33
+ type FontFamilyValue = [string, {
34
+ fontWeight: string;
35
+ }];
36
+ export interface TailwindPresetThemeExtend {
37
+ colors: Record<string, string>;
38
+ backgroundColor: Record<string, string>;
39
+ textColor: Record<string, string>;
40
+ borderColor: Record<string, string>;
41
+ spacing: Record<string, string>;
42
+ borderRadius: Record<string, string>;
43
+ borderWidth: Record<string, string>;
44
+ fontSize: Record<string, FontSizeValue>;
45
+ fontFamily: Record<string, FontFamilyValue>;
46
+ boxShadow: Record<string, string>;
47
+ }
48
+ export interface TailwindPreset {
49
+ theme: {
50
+ extend: TailwindPresetThemeExtend;
51
+ };
52
+ }
53
+ /**
54
+ * The Bloom Tailwind/NativeWind preset. Frozen so accidental mutation by a
55
+ * consumer's config merge cannot corrupt the shared vocabulary.
56
+ */
57
+ export declare const bloomTailwindPreset: TailwindPreset;
58
+ export {};
59
+ //# sourceMappingURL=tailwind-preset.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"tailwind-preset.d.ts","sourceRoot":"","sources":["../../../../src/design-tokens/tailwind-preset.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;GA0BG;AAaH,6DAA6D;AAC7D,KAAK,aAAa,GAAG,CAAC,MAAM,EAAE;IAAE,UAAU,EAAE,MAAM,CAAA;CAAE,CAAC,CAAC;AACtD,iEAAiE;AACjE,KAAK,eAAe,GAAG,CAAC,MAAM,EAAE;IAAE,UAAU,EAAE,MAAM,CAAA;CAAE,CAAC,CAAC;AAExD,MAAM,WAAW,yBAAyB;IACxC,MAAM,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;IAC/B,eAAe,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;IACxC,SAAS,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;IAClC,WAAW,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;IACpC,OAAO,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;IAChC,YAAY,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;IACrC,WAAW,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;IACpC,QAAQ,EAAE,MAAM,CAAC,MAAM,EAAE,aAAa,CAAC,CAAC;IACxC,UAAU,EAAE,MAAM,CAAC,MAAM,EAAE,eAAe,CAAC,CAAC;IAC5C,SAAS,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;CACnC;AAED,MAAM,WAAW,cAAc;IAC7B,KAAK,EAAE;QAAE,MAAM,EAAE,yBAAyB,CAAA;KAAE,CAAC;CAC9C;AAuDD;;;GAGG;AACH,eAAO,MAAM,mBAAmB,EAAE,cAoBhC,CAAC"}
@@ -0,0 +1,39 @@
1
+ /**
2
+ * Tailwind v4 `@theme` block generator for the Oxy Unified Design Language.
3
+ *
4
+ * Tailwind v4 web apps (auth, console, website) configure their design tokens in
5
+ * CSS via `@theme { --color-X: var(--X); … }` rather than a JS preset. This
6
+ * module produces the exact `@theme` body that mirrors `bloomTailwindPreset`, so
7
+ * a v4 app gets the SAME semantic utilities (`bg-fill`, `text-text-tertiary`,
8
+ * `p-space-8`, `rounded-radius-20`, `text-body`, `font-body`, `shadow-s`) as the
9
+ * NativeWind/Tailwind-v3 apps that consume the JS preset.
10
+ *
11
+ * Each color role is emitted as a `--color-<role>: var(--canonical)` alias.
12
+ * Per Bloom's web CSS-var contract, the canonical `--x` token already resolves
13
+ * to a full `rgb(...)` color at runtime, so the alias is a direct `var(--x)`
14
+ * reference — NEVER `hsl(var(--x))`.
15
+ *
16
+ * Usage (web Tailwind v4, in the app's global stylesheet):
17
+ *
18
+ * import { bloomThemeCss } from '@oxyhq/bloom/design-tokens';
19
+ * // build-time: write `@theme { ${bloomThemeCss()} }` into global.css, OR
20
+ * // paste the generated block once (see docs/design-tokens.md).
21
+ *
22
+ * A consumer that prefers a static stylesheet can copy the output of
23
+ * `bloomThemeCss()` directly into their `@theme { … }` — the values are stable.
24
+ */
25
+ /**
26
+ * Produce the BODY of a Tailwind v4 `@theme` block (no surrounding braces) that
27
+ * registers the full Bloom semantic vocabulary.
28
+ *
29
+ * - Colors → `--color-<role>: var(--canonical);`
30
+ * - Spacing → `--spacing-<key>: <px>;`
31
+ * - Radius → `--radius-<key>: <px>;`
32
+ * - Type → `--text-<role>: <size>; --text-<role>--line-height: <lh>;`
33
+ * `--font-<role>: var(--bloom-font-*);` (+ weight via utility doc)
34
+ * - Shadow → `--shadow-<s|m>: <box-shadow>;`
35
+ */
36
+ export declare function bloomThemeCss(): string;
37
+ /** The full `@theme { … }` block, ready to inject into a v4 stylesheet. */
38
+ export declare function bloomThemeBlock(): string;
39
+ //# sourceMappingURL=theme-css.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"theme-css.d.ts","sourceRoot":"","sources":["../../../../src/design-tokens/theme-css.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;GAuBG;AAaH;;;;;;;;;;GAUG;AACH,wBAAgB,aAAa,IAAI,MAAM,CA8CtC;AAED,2EAA2E;AAC3E,wBAAgB,eAAe,IAAI,MAAM,CAExC"}
@@ -3,6 +3,8 @@ export { atoms, flatten, Z_INDEX, zIndex } from './styles';
3
3
  export type { ViewStyleProp, TextStyleProp } from './styles';
4
4
  export * as tokens from './styles/tokens';
5
5
  export { web, native, ios, android, platform, select } from './styles/platform';
6
+ export { bloomTailwindPreset, bloomThemeCss, bloomThemeBlock, FILL_ROLES, TEXT_ROLES, BORDER_ROLES, SPACING, RADIUS, BORDER_WIDTH, TYPOGRAPHY, FONT_FAMILY_VARS, SHADOW_BOX, bloomShadowStyle, } from './design-tokens';
7
+ export type { TailwindPreset, TailwindPresetThemeExtend, FillRole, TextRole, BorderRole, TypeRole, TypeRoleName, ShadowRole, } from './design-tokens';
6
8
  export { useInteractionState } from './hooks/useInteractionState';
7
9
  export { useDelayedLoading } from './hooks/useDelayedLoading';
8
10
  export { useThrottledValue } from './hooks/useThrottledValue';
@@ -34,6 +36,10 @@ export * as Skeleton from './skeleton';
34
36
  export * as Grid from './grid';
35
37
  export { Fill } from './fill';
36
38
  export { IconCircle } from './icon-circle';
39
+ export { ConnectionDots } from './connection-dots';
40
+ export type { ConnectionDotsProps } from './connection-dots';
41
+ export { BenefitRow, BenefitList } from './benefit-list';
42
+ export type { BenefitRowProps, BenefitListProps } from './benefit-list';
37
43
  export * from './text-field';
38
44
  export * from './segmented-control';
39
45
  export { SearchInput } from './search-input';
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/index.ts"],"names":[],"mappings":"AACA,cAAc,SAAS,CAAC;AAGxB,OAAO,EAAE,KAAK,EAAE,OAAO,EAAE,OAAO,EAAE,MAAM,EAAE,MAAM,UAAU,CAAC;AAC3D,YAAY,EAAE,aAAa,EAAE,aAAa,EAAE,MAAM,UAAU,CAAC;AAC7D,OAAO,KAAK,MAAM,MAAM,iBAAiB,CAAC;AAC1C,OAAO,EAAE,GAAG,EAAE,MAAM,EAAE,GAAG,EAAE,OAAO,EAAE,QAAQ,EAAE,MAAM,EAAE,MAAM,mBAAmB,CAAC;AAGhF,OAAO,EAAE,mBAAmB,EAAE,MAAM,6BAA6B,CAAC;AAClE,OAAO,EAAE,iBAAiB,EAAE,MAAM,2BAA2B,CAAC;AAC9D,OAAO,EAAE,iBAAiB,EAAE,MAAM,2BAA2B,CAAC;AAG9D,OAAO,KAAK,KAAK,MAAM,SAAS,CAAC;AACjC,OAAO,EAAE,KAAK,KAAK,IAAI,SAAS,EAAE,KAAK,IAAI,SAAS,EAAE,iBAAiB,EAAE,MAAM,gBAAgB,CAAC;AAGhG,cAAc,UAAU,CAAC;AACzB,OAAO,EACL,MAAM,EACN,4BAA4B,EAC5B,mBAAmB,EACnB,KAAK,EACL,gBAAgB,EAChB,gBAAgB,GACjB,MAAM,UAAU,CAAC;AAClB,YAAY,EACV,WAAW,EACX,gBAAgB,EAChB,YAAY,EACZ,iBAAiB,EACjB,kBAAkB,EAClB,kBAAkB,EAClB,WAAW,EACX,eAAe,EACf,WAAW,EACX,yBAAyB,GAC1B,MAAM,UAAU,CAAC;AAClB,cAAc,UAAU,CAAC;AACzB,OAAO,EAAE,GAAG,EAAE,MAAM,OAAO,CAAC;AAC5B,YAAY,EAAE,QAAQ,EAAE,UAAU,EAAE,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