@clicoh/orion-library 1.2.0-beta.11 → 1.2.0-beta.13

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 (243) hide show
  1. package/assets/css/expresivo.css +895 -0
  2. package/assets/mascotas/svg/bugi-mascota-01-alerta.svg +39 -0
  3. package/assets/mascotas/svg/bugi-mascota-02-investigando.svg +36 -0
  4. package/assets/mascotas/svg/bugi-mascota-05-sorprendido.svg +38 -0
  5. package/assets/mascotas/svg/oculus-mascota-01-feliz.svg +52 -0
  6. package/assets/mascotas/svg/oculus-mascota-02-investigando.svg +51 -0
  7. package/assets/mascotas/svg/oculus-mascota-03-dudando.svg +51 -0
  8. package/assets/mascotas/svg/oculus-mascota-04-analizando-documento.svg +53 -0
  9. package/assets/mascotas/svg/oculus-mascota-06-celebrando.svg +54 -0
  10. package/assets/mascotas/svg/oculus-mascota-07-buscando-rapido.svg +57 -0
  11. package/assets/mascotas/svg/oculus-mascota-08-satisfecho.svg +55 -0
  12. package/assets/mascotas/webp/fixi-mascota-01-feliz-sm.webp +0 -0
  13. package/assets/mascotas/webp/fixi-mascota-02-investigando-sm.webp +0 -0
  14. package/assets/mascotas/webp/fixi-mascota-03-dudando-sm.webp +0 -0
  15. package/assets/mascotas/webp/fixi-mascota-04-reparando-sm.webp +0 -0
  16. package/assets/mascotas/webp/fixi-mascota-05-sorprendido-sm.webp +0 -0
  17. package/assets/mascotas/webp/fixi-mascota-06-celebrando-sm.webp +0 -0
  18. package/assets/mascotas/webp/fixi-mascota-07-corriendo-sm.webp +0 -0
  19. package/dist/components/01-atoms/Button/Button.d.ts +18 -1
  20. package/dist/components/01-atoms/Button/Button.d.ts.map +1 -1
  21. package/dist/components/01-atoms/Button/Button.jsx +25 -5
  22. package/dist/components/01-atoms/Button/Button.jsx.map +1 -1
  23. package/dist/components/01-atoms/CodeBlock/CodeBlock.d.ts +56 -0
  24. package/dist/components/01-atoms/CodeBlock/CodeBlock.d.ts.map +1 -0
  25. package/dist/components/01-atoms/CodeBlock/CodeBlock.jsx +97 -0
  26. package/dist/components/01-atoms/CodeBlock/CodeBlock.jsx.map +1 -0
  27. package/dist/components/01-atoms/CodeBlock/index.d.ts +2 -0
  28. package/dist/components/01-atoms/CodeBlock/index.d.ts.map +1 -0
  29. package/dist/components/01-atoms/CodeBlock/index.js +2 -0
  30. package/dist/components/01-atoms/CodeBlock/index.js.map +1 -0
  31. package/dist/components/01-atoms/Heading/Heading.jsx +1 -1
  32. package/dist/components/01-atoms/Heading/Heading.jsx.map +1 -1
  33. package/dist/components/01-atoms/Input/Input.d.ts.map +1 -1
  34. package/dist/components/01-atoms/Input/Input.jsx +9 -7
  35. package/dist/components/01-atoms/Input/Input.jsx.map +1 -1
  36. package/dist/components/01-atoms/Input/utils/RenderErrorOrHelperText.d.ts.map +1 -1
  37. package/dist/components/01-atoms/Input/utils/RenderErrorOrHelperText.jsx +1 -1
  38. package/dist/components/01-atoms/Input/utils/RenderErrorOrHelperText.jsx.map +1 -1
  39. package/dist/components/01-atoms/Select/Select.d.ts.map +1 -1
  40. package/dist/components/01-atoms/Select/Select.jsx +7 -7
  41. package/dist/components/01-atoms/Select/Select.jsx.map +1 -1
  42. package/dist/components/01-atoms/Spinner/Spinner.d.ts +24 -3
  43. package/dist/components/01-atoms/Spinner/Spinner.d.ts.map +1 -1
  44. package/dist/components/01-atoms/Spinner/Spinner.jsx +30 -4
  45. package/dist/components/01-atoms/Spinner/Spinner.jsx.map +1 -1
  46. package/dist/components/01-atoms/Spinner/index.d.ts +1 -0
  47. package/dist/components/01-atoms/Spinner/index.d.ts.map +1 -1
  48. package/dist/components/01-atoms/Stat/Stat.d.ts +47 -0
  49. package/dist/components/01-atoms/Stat/Stat.d.ts.map +1 -0
  50. package/dist/components/01-atoms/Stat/Stat.jsx +64 -0
  51. package/dist/components/01-atoms/Stat/Stat.jsx.map +1 -0
  52. package/dist/components/01-atoms/Stat/index.d.ts +2 -0
  53. package/dist/components/01-atoms/Stat/index.d.ts.map +1 -0
  54. package/dist/components/01-atoms/Stat/index.js +2 -0
  55. package/dist/components/01-atoms/Stat/index.js.map +1 -0
  56. package/dist/components/01-atoms/Textarea/Textarea.d.ts.map +1 -1
  57. package/dist/components/01-atoms/Textarea/Textarea.jsx +3 -3
  58. package/dist/components/01-atoms/Textarea/Textarea.jsx.map +1 -1
  59. package/dist/components/01-atoms/index.d.ts +2 -0
  60. package/dist/components/01-atoms/index.d.ts.map +1 -1
  61. package/dist/components/01-atoms/index.js +2 -0
  62. package/dist/components/01-atoms/index.js.map +1 -1
  63. package/dist/components/02-molecules/Accordion/AccordionSection.d.ts.map +1 -1
  64. package/dist/components/02-molecules/Accordion/AccordionSection.jsx +26 -3
  65. package/dist/components/02-molecules/Accordion/AccordionSection.jsx.map +1 -1
  66. package/dist/components/02-molecules/Card/Card.d.ts +74 -0
  67. package/dist/components/02-molecules/Card/Card.d.ts.map +1 -0
  68. package/dist/components/02-molecules/Card/Card.jsx +83 -0
  69. package/dist/components/02-molecules/Card/Card.jsx.map +1 -0
  70. package/dist/components/02-molecules/Card/index.d.ts +2 -0
  71. package/dist/components/02-molecules/Card/index.d.ts.map +1 -0
  72. package/dist/components/02-molecules/Card/index.js +2 -0
  73. package/dist/components/02-molecules/Card/index.js.map +1 -0
  74. package/dist/components/02-molecules/DatePicker/DatePicker.d.ts +37 -2
  75. package/dist/components/02-molecules/DatePicker/DatePicker.d.ts.map +1 -1
  76. package/dist/components/02-molecules/DatePicker/DatePicker.jsx +187 -32
  77. package/dist/components/02-molecules/DatePicker/DatePicker.jsx.map +1 -1
  78. package/dist/components/02-molecules/EmptyState/EmptyState.d.ts +52 -0
  79. package/dist/components/02-molecules/EmptyState/EmptyState.d.ts.map +1 -0
  80. package/dist/components/02-molecules/EmptyState/EmptyState.jsx +66 -0
  81. package/dist/components/02-molecules/EmptyState/EmptyState.jsx.map +1 -0
  82. package/dist/components/02-molecules/EmptyState/index.d.ts +2 -0
  83. package/dist/components/02-molecules/EmptyState/index.d.ts.map +1 -0
  84. package/dist/components/02-molecules/EmptyState/index.js +2 -0
  85. package/dist/components/02-molecules/EmptyState/index.js.map +1 -0
  86. package/dist/components/02-molecules/Filter/Filter.d.ts +7 -1
  87. package/dist/components/02-molecules/Filter/Filter.d.ts.map +1 -1
  88. package/dist/components/02-molecules/Filter/Filter.jsx +10 -7
  89. package/dist/components/02-molecules/Filter/Filter.jsx.map +1 -1
  90. package/dist/components/02-molecules/InlineMessage/InlineMessage.d.ts +15 -1
  91. package/dist/components/02-molecules/InlineMessage/InlineMessage.d.ts.map +1 -1
  92. package/dist/components/02-molecules/InlineMessage/InlineMessage.jsx +18 -3
  93. package/dist/components/02-molecules/InlineMessage/InlineMessage.jsx.map +1 -1
  94. package/dist/components/02-molecules/Menu/MenuItem.d.ts.map +1 -1
  95. package/dist/components/02-molecules/Menu/MenuItem.jsx +2 -2
  96. package/dist/components/02-molecules/Menu/MenuItem.jsx.map +1 -1
  97. package/dist/components/02-molecules/Menu/MenuList.d.ts.map +1 -1
  98. package/dist/components/02-molecules/Menu/MenuList.jsx +1 -1
  99. package/dist/components/02-molecules/Menu/MenuList.jsx.map +1 -1
  100. package/dist/components/02-molecules/Stepper/Stepper.d.ts +70 -0
  101. package/dist/components/02-molecules/Stepper/Stepper.d.ts.map +1 -0
  102. package/dist/components/02-molecules/Stepper/Stepper.jsx +204 -0
  103. package/dist/components/02-molecules/Stepper/Stepper.jsx.map +1 -0
  104. package/dist/components/02-molecules/Stepper/index.d.ts +2 -0
  105. package/dist/components/02-molecules/Stepper/index.d.ts.map +1 -0
  106. package/dist/components/02-molecules/Stepper/index.js +2 -0
  107. package/dist/components/02-molecules/Stepper/index.js.map +1 -0
  108. package/dist/components/02-molecules/Table/Table.d.ts +3 -1
  109. package/dist/components/02-molecules/Table/Table.d.ts.map +1 -1
  110. package/dist/components/02-molecules/Table/Table.jsx +6 -5
  111. package/dist/components/02-molecules/Table/Table.jsx.map +1 -1
  112. package/dist/components/02-molecules/Timeline/Timeline.d.ts +47 -0
  113. package/dist/components/02-molecules/Timeline/Timeline.d.ts.map +1 -0
  114. package/dist/components/02-molecules/Timeline/Timeline.jsx +65 -0
  115. package/dist/components/02-molecules/Timeline/Timeline.jsx.map +1 -0
  116. package/dist/components/02-molecules/Timeline/index.d.ts +2 -0
  117. package/dist/components/02-molecules/Timeline/index.d.ts.map +1 -0
  118. package/dist/components/02-molecules/Timeline/index.js +2 -0
  119. package/dist/components/02-molecules/Timeline/index.js.map +1 -0
  120. package/dist/components/02-molecules/index.d.ts +4 -0
  121. package/dist/components/02-molecules/index.d.ts.map +1 -1
  122. package/dist/components/02-molecules/index.js +4 -0
  123. package/dist/components/02-molecules/index.js.map +1 -1
  124. package/dist/components/03-organisms/DataTable/DataTable.d.ts +1 -1
  125. package/dist/components/03-organisms/DataTable/DataTable.d.ts.map +1 -1
  126. package/dist/components/03-organisms/DataTable/DataTable.jsx.map +1 -1
  127. package/dist/components/03-organisms/Header/Header.d.ts +3 -1
  128. package/dist/components/03-organisms/Header/Header.d.ts.map +1 -1
  129. package/dist/components/03-organisms/Header/Header.jsx +4 -5
  130. package/dist/components/03-organisms/Header/Header.jsx.map +1 -1
  131. package/dist/components/04-templates/DashboardTemplate/DashboardTemplate.d.ts +24 -4
  132. package/dist/components/04-templates/DashboardTemplate/DashboardTemplate.d.ts.map +1 -1
  133. package/dist/components/04-templates/DashboardTemplate/DashboardTemplate.jsx +31 -8
  134. package/dist/components/04-templates/DashboardTemplate/DashboardTemplate.jsx.map +1 -1
  135. package/dist/components/04-templates/DashboardTemplate/HeadingWithTitle.d.ts +6 -2
  136. package/dist/components/04-templates/DashboardTemplate/HeadingWithTitle.d.ts.map +1 -1
  137. package/dist/components/04-templates/DashboardTemplate/HeadingWithTitle.jsx +7 -3
  138. package/dist/components/04-templates/DashboardTemplate/HeadingWithTitle.jsx.map +1 -1
  139. package/dist/components/04-templates/LoginTemplate/LoginTemplate.d.ts +2 -0
  140. package/dist/components/04-templates/LoginTemplate/LoginTemplate.d.ts.map +1 -1
  141. package/dist/components/04-templates/LoginTemplate/LoginTemplate.jsx +2 -1
  142. package/dist/components/04-templates/LoginTemplate/LoginTemplate.jsx.map +1 -1
  143. package/expresivo/ExpBubble/ExpBubble.d.ts +51 -0
  144. package/expresivo/ExpBubble/ExpBubble.d.ts.map +1 -0
  145. package/expresivo/ExpBubble/ExpBubble.jsx +74 -0
  146. package/expresivo/ExpBubble/ExpBubble.jsx.map +1 -0
  147. package/expresivo/ExpBubble/index.d.ts +3 -0
  148. package/expresivo/ExpBubble/index.d.ts.map +1 -0
  149. package/expresivo/ExpBubble/index.js +2 -0
  150. package/expresivo/ExpBubble/index.js.map +1 -0
  151. package/expresivo/ExpCollapseToggle/ExpCollapseToggle.d.ts +37 -0
  152. package/expresivo/ExpCollapseToggle/ExpCollapseToggle.d.ts.map +1 -0
  153. package/expresivo/ExpCollapseToggle/ExpCollapseToggle.jsx +43 -0
  154. package/expresivo/ExpCollapseToggle/ExpCollapseToggle.jsx.map +1 -0
  155. package/expresivo/ExpCollapseToggle/index.d.ts +3 -0
  156. package/expresivo/ExpCollapseToggle/index.d.ts.map +1 -0
  157. package/expresivo/ExpCollapseToggle/index.js +2 -0
  158. package/expresivo/ExpCollapseToggle/index.js.map +1 -0
  159. package/expresivo/ExpGrowBar/ExpGrowBar.d.ts +26 -0
  160. package/expresivo/ExpGrowBar/ExpGrowBar.d.ts.map +1 -0
  161. package/expresivo/ExpGrowBar/ExpGrowBar.jsx +39 -0
  162. package/expresivo/ExpGrowBar/ExpGrowBar.jsx.map +1 -0
  163. package/expresivo/ExpGrowBar/index.d.ts +3 -0
  164. package/expresivo/ExpGrowBar/index.d.ts.map +1 -0
  165. package/expresivo/ExpGrowBar/index.js +2 -0
  166. package/expresivo/ExpGrowBar/index.js.map +1 -0
  167. package/expresivo/ExpJourneyTrack/ExpJourneyTrack.d.ts +65 -0
  168. package/expresivo/ExpJourneyTrack/ExpJourneyTrack.d.ts.map +1 -0
  169. package/expresivo/ExpJourneyTrack/ExpJourneyTrack.jsx +156 -0
  170. package/expresivo/ExpJourneyTrack/ExpJourneyTrack.jsx.map +1 -0
  171. package/expresivo/ExpJourneyTrack/index.d.ts +3 -0
  172. package/expresivo/ExpJourneyTrack/index.d.ts.map +1 -0
  173. package/expresivo/ExpJourneyTrack/index.js +2 -0
  174. package/expresivo/ExpJourneyTrack/index.js.map +1 -0
  175. package/expresivo/ExpKeyButton/ExpKeyButton.d.ts +49 -0
  176. package/expresivo/ExpKeyButton/ExpKeyButton.d.ts.map +1 -0
  177. package/expresivo/ExpKeyButton/ExpKeyButton.jsx +60 -0
  178. package/expresivo/ExpKeyButton/ExpKeyButton.jsx.map +1 -0
  179. package/expresivo/ExpKeyButton/index.d.ts +3 -0
  180. package/expresivo/ExpKeyButton/index.d.ts.map +1 -0
  181. package/expresivo/ExpKeyButton/index.js +2 -0
  182. package/expresivo/ExpKeyButton/index.js.map +1 -0
  183. package/expresivo/ExpLensIcon/ExpLensIcon.d.ts +29 -0
  184. package/expresivo/ExpLensIcon/ExpLensIcon.d.ts.map +1 -0
  185. package/expresivo/ExpLensIcon/ExpLensIcon.jsx +29 -0
  186. package/expresivo/ExpLensIcon/ExpLensIcon.jsx.map +1 -0
  187. package/expresivo/ExpLensIcon/index.d.ts +3 -0
  188. package/expresivo/ExpLensIcon/index.d.ts.map +1 -0
  189. package/expresivo/ExpLensIcon/index.js +2 -0
  190. package/expresivo/ExpLensIcon/index.js.map +1 -0
  191. package/expresivo/ExpMascot/ExpMascot.d.ts +38 -0
  192. package/expresivo/ExpMascot/ExpMascot.d.ts.map +1 -0
  193. package/expresivo/ExpMascot/ExpMascot.jsx +41 -0
  194. package/expresivo/ExpMascot/ExpMascot.jsx.map +1 -0
  195. package/expresivo/ExpMascot/catalog.d.ts +12 -0
  196. package/expresivo/ExpMascot/catalog.d.ts.map +1 -0
  197. package/expresivo/ExpMascot/catalog.js +41 -0
  198. package/expresivo/ExpMascot/catalog.js.map +1 -0
  199. package/expresivo/ExpMascot/index.d.ts +4 -0
  200. package/expresivo/ExpMascot/index.d.ts.map +1 -0
  201. package/expresivo/ExpMascot/index.js +2 -0
  202. package/expresivo/ExpMascot/index.js.map +1 -0
  203. package/expresivo/ExpMedalBadge/ExpMedalBadge.d.ts +29 -0
  204. package/expresivo/ExpMedalBadge/ExpMedalBadge.d.ts.map +1 -0
  205. package/expresivo/ExpMedalBadge/ExpMedalBadge.jsx +87 -0
  206. package/expresivo/ExpMedalBadge/ExpMedalBadge.jsx.map +1 -0
  207. package/expresivo/ExpMedalBadge/index.d.ts +3 -0
  208. package/expresivo/ExpMedalBadge/index.d.ts.map +1 -0
  209. package/expresivo/ExpMedalBadge/index.js +2 -0
  210. package/expresivo/ExpMedalBadge/index.js.map +1 -0
  211. package/expresivo/ExpPillButton/ExpPillButton.d.ts +44 -0
  212. package/expresivo/ExpPillButton/ExpPillButton.d.ts.map +1 -0
  213. package/expresivo/ExpPillButton/ExpPillButton.jsx +75 -0
  214. package/expresivo/ExpPillButton/ExpPillButton.jsx.map +1 -0
  215. package/expresivo/ExpPillButton/index.d.ts +3 -0
  216. package/expresivo/ExpPillButton/index.d.ts.map +1 -0
  217. package/expresivo/ExpPillButton/index.js +2 -0
  218. package/expresivo/ExpPillButton/index.js.map +1 -0
  219. package/expresivo/ExpScope/ExpScope.d.ts +63 -0
  220. package/expresivo/ExpScope/ExpScope.d.ts.map +1 -0
  221. package/expresivo/ExpScope/ExpScope.jsx +67 -0
  222. package/expresivo/ExpScope/ExpScope.jsx.map +1 -0
  223. package/expresivo/ExpScope/index.d.ts +3 -0
  224. package/expresivo/ExpScope/index.d.ts.map +1 -0
  225. package/expresivo/ExpScope/index.js +2 -0
  226. package/expresivo/ExpScope/index.js.map +1 -0
  227. package/expresivo/ExpScoreRing/ExpScoreRing.d.ts +35 -0
  228. package/expresivo/ExpScoreRing/ExpScoreRing.d.ts.map +1 -0
  229. package/expresivo/ExpScoreRing/ExpScoreRing.jsx +67 -0
  230. package/expresivo/ExpScoreRing/ExpScoreRing.jsx.map +1 -0
  231. package/expresivo/ExpScoreRing/index.d.ts +3 -0
  232. package/expresivo/ExpScoreRing/index.d.ts.map +1 -0
  233. package/expresivo/ExpScoreRing/index.js +2 -0
  234. package/expresivo/ExpScoreRing/index.js.map +1 -0
  235. package/expresivo/index.d.ts +12 -0
  236. package/expresivo/index.d.ts.map +1 -0
  237. package/expresivo/index.js +12 -0
  238. package/expresivo/index.js.map +1 -0
  239. package/expresivo/shared/glyphs.d.ts +20 -0
  240. package/expresivo/shared/glyphs.d.ts.map +1 -0
  241. package/expresivo/shared/glyphs.jsx +60 -0
  242. package/expresivo/shared/glyphs.jsx.map +1 -0
  243. package/package.json +3 -2
@@ -0,0 +1,75 @@
1
+ 'use client';
2
+ import clsx from 'clsx';
3
+ import { FiLogIn, FiRefreshCw, FiSearch } from 'react-icons/fi';
4
+ import { Button } from '@clicoh/orion-library';
5
+ import { useExpScope } from '../ExpScope/ExpScope';
6
+ import { EnterGlyph, LensGlyph, SyncBadgeGlyph, SyncGlyph, } from '../shared/glyphs';
7
+ const fallbackIconMap = {
8
+ lens: <FiSearch />,
9
+ sync: <FiRefreshCw />,
10
+ enter: <FiLogIn />,
11
+ none: undefined,
12
+ };
13
+ const toneMap = {
14
+ brand: {
15
+ idle: clsx('bg-lavender dark:bg-lavender-dark text-white shadow-[0_3px_10px_rgba(106,93,249,0.22)]', 'hover:from-lavender hover:to-violet hover:bg-linear-135 hover:shadow-[0_8px_20px_rgba(200,84,228,0.28)]', 'hover:-translate-y-px active:translate-y-0 active:scale-[.98]'),
16
+ busy: 'bg-lavender dark:bg-lavender-dark cursor-progress text-white shadow-[0_3px_10px_rgba(106,93,249,0.22)]',
17
+ disabled: 'bg-gray-5 text-gray-2 dark:bg-gray-dark-1 cursor-not-allowed',
18
+ },
19
+ soft: {
20
+ idle: clsx('bg-lavender-2 text-lavender dark:bg-lavender-dark-1 dark:text-lavender-dark', 'hover:bg-lavender-1 hover:-translate-y-px active:translate-y-0 active:scale-[.98]'),
21
+ busy: 'bg-lavender-2 text-lavender dark:bg-lavender-dark-1 dark:text-lavender-dark cursor-progress',
22
+ disabled: 'bg-gray-5 text-gray-2 dark:bg-gray-dark-1 cursor-not-allowed',
23
+ },
24
+ };
25
+ /**
26
+ * Light pill-shaped call to action, the same 44px height as the core
27
+ * `Button`. `brand` is a filled lavender pill that turns into the clicOH
28
+ * gradient on hover, with its glyph in a white disc; `soft` is a tinted pill
29
+ * for secondary actions, such as a button inside a field.
30
+ *
31
+ * Outside an `ExpScope` it falls back to the core `Button`: `brand` maps to
32
+ * `principal` and `soft` to `second`.
33
+ *
34
+ * @component
35
+ * @example
36
+ * <ExpPillButton onClick={search}>Search</ExpPillButton>
37
+ *
38
+ * @example
39
+ * <ExpPillButton tone="soft" icon="sync" busy={isSyncing} busyLabel="Syncing…">
40
+ * Sync
41
+ * </ExpPillButton>
42
+ *
43
+ * @param {Object} props - The properties of the ExpPillButton component.
44
+ * @param {'brand' | 'soft'} [props.tone='brand'] - Filled lavender or tinted.
45
+ * @param {'lens' | 'sync' | 'enter' | 'none'} [props.icon='lens'] - Glyph before the label.
46
+ * @param {boolean} [props.busy=false] - Blocks the button and animates its glyph.
47
+ * @param {string} [props.busyLabel] - Label shown while `busy`.
48
+ * @param {boolean} [props.block=false] - Takes the full width of its container.
49
+ * @param {ReactNode} props.children - Label of the action.
50
+ * @param {ButtonHTMLAttributes<HTMLButtonElement>} restProps - Additional properties for the button element.
51
+ *
52
+ * @returns {ReactNode} The rendered pill, or a core `Button` outside an `ExpScope`.
53
+ */
54
+ export function ExpPillButton({ tone = 'brand', icon = 'lens', busy = false, busyLabel, block = false, disabled = false, children, ...restProps }) {
55
+ const inScope = useExpScope();
56
+ const label = busy && busyLabel ? busyLabel : children;
57
+ if (!inScope) {
58
+ return (<Button {...restProps} modifier={tone === 'brand' ? 'principal' : 'second'} iconL={fallbackIconMap[icon]} disabled={disabled || busy} aria-busy={busy || undefined} className={clsx(block && 'w-full', restProps.className)}>
59
+ {label}
60
+ </Button>);
61
+ }
62
+ const state = disabled ? 'disabled' : busy ? 'busy' : 'idle';
63
+ const hasDisc = tone === 'brand' && (icon === 'lens' || icon === 'sync');
64
+ return (<button {...restProps} disabled={disabled || busy} aria-busy={busy || undefined} className={clsx('h-11 items-center gap-2.5 rounded-full text-sm leading-5 font-semibold whitespace-nowrap', 'transition-[background-color,box-shadow,translate,scale] duration-200 motion-reduce:translate-none motion-reduce:scale-none motion-reduce:transition-none', block ? 'flex w-full justify-center' : 'inline-flex', icon === 'none' && 'px-6', icon !== 'none' && (hasDisc ? 'pr-[22px] pl-1.5' : 'pr-[18px] pl-3'), toneMap[tone][state], restProps.className)}>
65
+ {tone === 'brand' && icon === 'lens' && (<span aria-hidden="true" className={clsx('flex size-8 shrink-0 items-center justify-center rounded-full', disabled ? 'bg-gray-6' : 'bg-white')}>
66
+ <LensGlyph size={22} busy={busy} disabled={disabled}/>
67
+ </span>)}
68
+ {tone === 'brand' && icon === 'sync' && (<SyncBadgeGlyph size={32} busy={busy} disabled={disabled}/>)}
69
+ {tone === 'soft' && icon === 'lens' && (<LensGlyph size={20} busy={busy} disabled={disabled}/>)}
70
+ {tone === 'soft' && icon === 'sync' && (<SyncGlyph size={20} busy={busy} disabled={disabled}/>)}
71
+ {icon === 'enter' && (<EnterGlyph size={20} busy={busy} disabled={disabled}/>)}
72
+ {label}
73
+ </button>);
74
+ }
75
+ //# sourceMappingURL=ExpPillButton.jsx.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ExpPillButton.jsx","sourceRoot":"","sources":["../../src/expresivo/ExpPillButton/ExpPillButton.tsx"],"names":[],"mappings":"AAAA,YAAY,CAAC;AAEb,OAAO,IAAI,MAAM,MAAM,CAAC;AAExB,OAAO,EAAE,OAAO,EAAE,WAAW,EAAE,QAAQ,EAAE,MAAM,gBAAgB,CAAC;AAChE,OAAO,EAAE,MAAM,EAAE,MAAM,uBAAuB,CAAC;AAC/C,OAAO,EAAE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1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/expresivo/ExpPillButton/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,aAAa,EAAE,MAAM,iBAAiB,CAAC;AAChD,YAAY,EACV,iBAAiB,EACjB,kBAAkB,EAClB,iBAAiB,GAClB,MAAM,iBAAiB,CAAC"}
@@ -0,0 +1,2 @@
1
+ export { ExpPillButton } from './ExpPillButton';
2
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/expresivo/ExpPillButton/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,aAAa,EAAE,MAAM,iBAAiB,CAAC"}
@@ -0,0 +1,63 @@
1
+ import { type ReactNode } from 'react';
2
+ export type ExpScopeTitles = 'playful' | 'plain';
3
+ export type ExpScopeTables = 'cards' | 'plain';
4
+ export type ExpScopeMascots = 'shown' | 'hidden';
5
+ export type ExpScopeOptions = {
6
+ /** `playful` sets core headings, top menu links and table headers in the title font. */
7
+ titles: ExpScopeTitles;
8
+ /** `cards` turns core table rows into separate cards that lift on hover. */
9
+ tables: ExpScopeTables;
10
+ /** `hidden` silences every mascot, for users who prefer a quiet interface. */
11
+ mascots: ExpScopeMascots;
12
+ };
13
+ export type ExpScopeProps = {
14
+ children: ReactNode;
15
+ } & Partial<ExpScopeOptions>;
16
+ /**
17
+ * ExpScope turns on Orion's expressive layer for the page it renders in.
18
+ *
19
+ * Inside it, `Exp*` components render in full; outside it, they fall back to
20
+ * their core equivalent. While it is mounted, `assets/css/expresivo.css`
21
+ * reskins the core parts marked with `data-orion-part`, including the ones
22
+ * rendered in portals (tooltips, side filters, header menus).
23
+ *
24
+ * The options tune how loud the layer is, so a product can let its users
25
+ * pick a calmer look without leaving the scope.
26
+ *
27
+ * Only for consumers whose own docs declare `capa expresiva: sí`.
28
+ *
29
+ * @component
30
+ * @example
31
+ * <ExpScope>
32
+ * <App />
33
+ * </ExpScope>
34
+ *
35
+ * @example
36
+ * // Core table rows and plain titles, no mascots
37
+ * <ExpScope titles="plain" tables="plain" mascots="hidden">
38
+ * <App />
39
+ * </ExpScope>
40
+ *
41
+ * @param {ExpScopeProps} props
42
+ * @param {ReactNode} props.children - Content that gets the expressive layer.
43
+ * @param {'playful' | 'plain'} [props.titles='playful'] - `playful` sets core headings, top menu links and table headers in the title font.
44
+ * @param {'cards' | 'plain'} [props.tables='cards'] - `cards` turns core table rows into separate cards; `plain` keeps the core rows.
45
+ * @param {'shown' | 'hidden'} [props.mascots='shown'] - `hidden` stops every `Exp*` component from drawing a mascot.
46
+ * @returns {ReactNode} The children inside a wrapper that adds no box.
47
+ */
48
+ export declare function ExpScope({ children, titles, tables, mascots, }: ExpScopeProps): ReactNode;
49
+ /**
50
+ * Tells whether the caller renders inside an `ExpScope`. `Exp*` components
51
+ * use it to choose between their full look and their core fallback.
52
+ *
53
+ * @returns {boolean} `true` inside an `ExpScope`.
54
+ */
55
+ export declare function useExpScope(): boolean;
56
+ /**
57
+ * Options of the nearest `ExpScope`, for `Exp*` components that change with
58
+ * them.
59
+ *
60
+ * @returns {ExpScopeOptions | null} The options, or `null` outside an `ExpScope`.
61
+ */
62
+ export declare function useExpScopeOptions(): ExpScopeOptions | null;
63
+ //# sourceMappingURL=ExpScope.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ExpScope.d.ts","sourceRoot":"","sources":["../../src/expresivo/ExpScope/ExpScope.tsx"],"names":[],"mappings":"AAGA,OAAO,EAAiB,KAAK,SAAS,EAAuB,MAAM,OAAO,CAAC;AAE3E,MAAM,MAAM,cAAc,GAAG,SAAS,GAAG,OAAO,CAAC;AAEjD,MAAM,MAAM,cAAc,GAAG,OAAO,GAAG,OAAO,CAAC;AAE/C,MAAM,MAAM,eAAe,GAAG,OAAO,GAAG,QAAQ,CAAC;AAEjD,MAAM,MAAM,eAAe,GAAG;IAC5B,wFAAwF;IACxF,MAAM,EAAE,cAAc,CAAC;IACvB,4EAA4E;IAC5E,MAAM,EAAE,cAAc,CAAC;IACvB,8EAA8E;IAC9E,OAAO,EAAE,eAAe,CAAC;CAC1B,CAAC;AAEF,MAAM,MAAM,aAAa,GAAG;IAC1B,QAAQ,EAAE,SAAS,CAAC;CACrB,GAAG,OAAO,CAAC,eAAe,CAAC,CAAC;AAM7B;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA+BG;AACH,wBAAgB,QAAQ,CAAC,EACvB,QAAQ,EACR,MAAkB,EAClB,MAAgB,EAChB,OAAiB,GAClB,EAAE,aAAa,GAAG,SAAS,CAqB3B;AAED;;;;;GAKG;AACH,wBAAgB,WAAW,IAAI,OAAO,CAErC;AAED;;;;;GAKG;AACH,wBAAgB,kBAAkB,IAAI,eAAe,GAAG,IAAI,CAE3D"}
@@ -0,0 +1,67 @@
1
+ 'use client';
2
+ import { DynaPuff } from 'next/font/google';
3
+ import { createContext, useContext, useMemo } from 'react';
4
+ const titleFont = DynaPuff({ subsets: ['latin'], display: 'swap' });
5
+ const ExpScopeContext = createContext(null);
6
+ /**
7
+ * ExpScope turns on Orion's expressive layer for the page it renders in.
8
+ *
9
+ * Inside it, `Exp*` components render in full; outside it, they fall back to
10
+ * their core equivalent. While it is mounted, `assets/css/expresivo.css`
11
+ * reskins the core parts marked with `data-orion-part`, including the ones
12
+ * rendered in portals (tooltips, side filters, header menus).
13
+ *
14
+ * The options tune how loud the layer is, so a product can let its users
15
+ * pick a calmer look without leaving the scope.
16
+ *
17
+ * Only for consumers whose own docs declare `capa expresiva: sí`.
18
+ *
19
+ * @component
20
+ * @example
21
+ * <ExpScope>
22
+ * <App />
23
+ * </ExpScope>
24
+ *
25
+ * @example
26
+ * // Core table rows and plain titles, no mascots
27
+ * <ExpScope titles="plain" tables="plain" mascots="hidden">
28
+ * <App />
29
+ * </ExpScope>
30
+ *
31
+ * @param {ExpScopeProps} props
32
+ * @param {ReactNode} props.children - Content that gets the expressive layer.
33
+ * @param {'playful' | 'plain'} [props.titles='playful'] - `playful` sets core headings, top menu links and table headers in the title font.
34
+ * @param {'cards' | 'plain'} [props.tables='cards'] - `cards` turns core table rows into separate cards; `plain` keeps the core rows.
35
+ * @param {'shown' | 'hidden'} [props.mascots='shown'] - `hidden` stops every `Exp*` component from drawing a mascot.
36
+ * @returns {ReactNode} The children inside a wrapper that adds no box.
37
+ */
38
+ export function ExpScope({ children, titles = 'playful', tables = 'cards', mascots = 'shown', }) {
39
+ const options = useMemo(() => ({ titles, tables, mascots }), [titles, tables, mascots]);
40
+ return (<ExpScopeContext.Provider value={options}>
41
+ <style href="exp-title-font" precedence="exp">
42
+ {`:root{--exp-title-font:${titleFont.style.fontFamily}}`}
43
+ </style>
44
+ <div className="exp-scope" data-exp-titles={titles} data-exp-tables={tables} data-exp-mascots={mascots}>
45
+ {children}
46
+ </div>
47
+ </ExpScopeContext.Provider>);
48
+ }
49
+ /**
50
+ * Tells whether the caller renders inside an `ExpScope`. `Exp*` components
51
+ * use it to choose between their full look and their core fallback.
52
+ *
53
+ * @returns {boolean} `true` inside an `ExpScope`.
54
+ */
55
+ export function useExpScope() {
56
+ return useContext(ExpScopeContext) !== null;
57
+ }
58
+ /**
59
+ * Options of the nearest `ExpScope`, for `Exp*` components that change with
60
+ * them.
61
+ *
62
+ * @returns {ExpScopeOptions | null} The options, or `null` outside an `ExpScope`.
63
+ */
64
+ export function useExpScopeOptions() {
65
+ return useContext(ExpScopeContext);
66
+ }
67
+ //# sourceMappingURL=ExpScope.jsx.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ExpScope.jsx","sourceRoot":"","sources":["../../src/expresivo/ExpScope/ExpScope.tsx"],"names":[],"mappings":"AAAA,YAAY,CAAC;AAEb,OAAO,EAAE,QAAQ,EAAE,MAAM,kBAAkB,CAAC;AAC5C,OAAO,EAAE,aAAa,EAAkB,UAAU,EAAE,OAAO,EAAE,MAAM,OAAO,CAAC;AAqB3E,MAAM,SAAS,GAAG,QAAQ,CAAC,EAAE,OAAO,EAAE,CAAC,O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eMascots, ExpScopeOptions, ExpScopeProps, ExpScopeTables, ExpScopeTitles, } from './ExpScope';
3
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/expresivo/ExpScope/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,QAAQ,EAAE,WAAW,EAAE,MAAM,YAAY,CAAC;AACnD,YAAY,EACV,eAAe,EACf,eAAe,EACf,aAAa,EACb,cAAc,EACd,cAAc,GACf,MAAM,YAAY,CAAC"}
@@ -0,0 +1,2 @@
1
+ export { ExpScope, useExpScope } from './ExpScope';
2
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/expresivo/ExpScope/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,QAAQ,EAAE,WAAW,EAAE,MAAM,YAAY,CAAC"}
@@ -0,0 +1,35 @@
1
+ import { type HTMLAttributes, type ReactNode } from 'react';
2
+ export type ExpScoreRingProps = {
3
+ /** Score between 0 and 100. */
4
+ value: number;
5
+ /** Target score between 0 and 100, marked with a tick on the ring. */
6
+ goal?: number;
7
+ /** Width and height in pixels. */
8
+ size?: number;
9
+ /** Content centered inside the ring, such as the score and its caption. */
10
+ children?: ReactNode;
11
+ } & Omit<HTMLAttributes<HTMLDivElement>, 'children'>;
12
+ /**
13
+ * Score ring with an optional goal tick. The arc grows in the clicOH
14
+ * gradient when it mounts. The ring is decorative: put the score as text in
15
+ * `children`, centered inside it.
16
+ *
17
+ * Outside an `ExpScope` it falls back to the core `RadialProgressBar`, with
18
+ * `children` still centered on top.
19
+ *
20
+ * @component
21
+ * @example
22
+ * <ExpScoreRing value={57} goal={70}>
23
+ * <Heading level="h4">57</Heading>
24
+ * </ExpScoreRing>
25
+ *
26
+ * @param {Object} props - The properties of the ExpScoreRing component.
27
+ * @param {number} props.value - Score between 0 and 100.
28
+ * @param {number} [props.goal] - Target score, marked with a tick.
29
+ * @param {number} [props.size=120] - Width and height in pixels.
30
+ * @param {ReactNode} [props.children] - Content centered inside the ring.
31
+ *
32
+ * @returns {ReactNode} The ring, or a core `RadialProgressBar` outside an `ExpScope`.
33
+ */
34
+ export declare function ExpScoreRing({ value, goal, size, children, ...restProps }: ExpScoreRingProps): ReactNode;
35
+ //# sourceMappingURL=ExpScoreRing.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ExpScoreRing.d.ts","sourceRoot":"","sources":["../../src/expresivo/ExpScoreRing/ExpScoreRing.tsx"],"names":[],"mappings":"AAGA,OAAO,EACL,KAAK,cAAc,EACnB,KAAK,SAAS,EAIf,MAAM,OAAO,CAAC;AAIf,MAAM,MAAM,iBAAiB,GAAG;IAC9B,+BAA+B;IAC/B,KAAK,EAAE,MAAM,CAAC;IACd,sEAAsE;IACtE,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,kCAAkC;IAClC,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,2EAA2E;IAC3E,QAAQ,CAAC,EAAE,SAAS,CAAC;CACtB,GAAG,IAAI,CAAC,cAAc,CAAC,cAAc,CAAC,EAAE,UAAU,CAAC,CAAC;AAOrD;;;;;;;;;;;;;;;;;;;;;GAqBG;AACH,wBAAgB,YAAY,CAAC,EAC3B,KAAK,EACL,IAAI,EACJ,IAAU,EACV,QAAQ,EACR,GAAG,SAAS,EACb,EAAE,iBAAiB,GAAG,SAAS,CAoF/B"}
@@ -0,0 +1,67 @@
1
+ 'use client';
2
+ import clsx from 'clsx';
3
+ import { useEffect, useId, useState, } from 'react';
4
+ import { RadialProgressBar, Show } from '@clicoh/orion-library';
5
+ import { useExpScope } from '../ExpScope/ExpScope';
6
+ const RADIUS = 50;
7
+ const CIRCUMFERENCE = 2 * Math.PI * RADIUS;
8
+ const clamp = (value) => Math.min(100, Math.max(0, value));
9
+ /**
10
+ * Score ring with an optional goal tick. The arc grows in the clicOH
11
+ * gradient when it mounts. The ring is decorative: put the score as text in
12
+ * `children`, centered inside it.
13
+ *
14
+ * Outside an `ExpScope` it falls back to the core `RadialProgressBar`, with
15
+ * `children` still centered on top.
16
+ *
17
+ * @component
18
+ * @example
19
+ * <ExpScoreRing value={57} goal={70}>
20
+ * <Heading level="h4">57</Heading>
21
+ * </ExpScoreRing>
22
+ *
23
+ * @param {Object} props - The properties of the ExpScoreRing component.
24
+ * @param {number} props.value - Score between 0 and 100.
25
+ * @param {number} [props.goal] - Target score, marked with a tick.
26
+ * @param {number} [props.size=120] - Width and height in pixels.
27
+ * @param {ReactNode} [props.children] - Content centered inside the ring.
28
+ *
29
+ * @returns {ReactNode} The ring, or a core `RadialProgressBar` outside an `ExpScope`.
30
+ */
31
+ export function ExpScoreRing({ value, goal, size = 120, children, ...restProps }) {
32
+ const inScope = useExpScope();
33
+ const gradientId = useId();
34
+ const [shown, setShown] = useState(0);
35
+ const percent = clamp(value);
36
+ useEffect(() => {
37
+ const timer = setTimeout(() => setShown(percent), 60);
38
+ return () => clearTimeout(timer);
39
+ }, [percent]);
40
+ const goalAngle = typeof goal === 'number'
41
+ ? ((clamp(goal) / 100) * 360 - 90) * (Math.PI / 180)
42
+ : null;
43
+ return (<div {...restProps} style={{ width: size, height: size, ...restProps.style }} className={clsx('relative inline-flex shrink-0', restProps.className)}>
44
+ <Show>
45
+ <Show.When isTrue={inScope}>
46
+ <svg aria-hidden="true" width={size} height={size} viewBox="0 0 120 120">
47
+ <defs>
48
+ <linearGradient id={gradientId} x1={0} y1={0} x2={1} y2={1}>
49
+ <stop offset={0} className="[stop-color:var(--color-lavender)]"/>
50
+ <stop offset={1} className="[stop-color:var(--color-violet)]"/>
51
+ </linearGradient>
52
+ </defs>
53
+ <circle cx={60} cy={60} r={RADIUS} fill="none" strokeWidth={10} className="stroke-gray-5 dark:stroke-gray-dark-1"/>
54
+ <circle cx={60} cy={60} r={RADIUS} fill="none" stroke={`url(#${gradientId})`} strokeWidth={10} strokeLinecap="round" strokeDasharray={CIRCUMFERENCE} strokeDashoffset={CIRCUMFERENCE * (1 - shown / 100)} transform="rotate(-90 60 60)" className="transition-[stroke-dashoffset] duration-900 ease-[cubic-bezier(.22,1,.36,1)] motion-reduce:transition-none"/>
55
+ {goalAngle !== null && (<line x1={60 + Math.cos(goalAngle) * 42} y1={60 + Math.sin(goalAngle) * 42} x2={60 + Math.cos(goalAngle) * 58} y2={60 + Math.sin(goalAngle) * 58} strokeWidth={2.5} strokeLinecap="round" className="stroke-black dark:stroke-white"/>)}
56
+ </svg>
57
+ </Show.When>
58
+ <Show.Else>
59
+ <RadialProgressBar value={percent} className="h-full w-full"/>
60
+ </Show.Else>
61
+ </Show>
62
+ {!!children && (<div className="absolute inset-0 flex flex-col items-center justify-center text-center">
63
+ {children}
64
+ </div>)}
65
+ </div>);
66
+ }
67
+ //# sourceMappingURL=ExpScoreRing.jsx.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ExpScoreRing.jsx","sourceRoot":"","sources":["../../src/expresivo/ExpScoreRing/ExpScoreRing.tsx"],"names":[],"mappings":"AAAA,YAAY,CAAC;AAEb,OAAO,IAAI,MAAM,MAAM,CAAC;AACxB,OAAO,EAGL,SAAS,EACT,KAAK,EACL,QAAQ,GACT,MAAM,OAAO,CAAC;AACf,OAAO,EAAE,iBAAiB,EAAE,IAAI,EAAE,MAAM,uBAAuB,CAAC;AAChE,OAAO,EAAE,WAAW,EAAE,MAAM,sBAAsB,CAAC;AAanD,MAAM,MAAM,GAAG,EAAE,CAAC;AAClB,MAAM,aAAa,GAAG,CAAC,GAAG,IAAI,CAAC,EAAE,GAAG,MAAM,CAAC;AAE3C,MAAM,KAAK,GAAG,CAAC,KAAa,EAAU,EAAE,CAAC,IAAI,CAAC,GAAG,CAAC,GAAG,EAAE,IAAI,CAAC,GAAG,CAAC,CAAC,EAAE,KAAK,CAAC,CAAC,CAAC;AAE3E;;;;;;;;;;;;;;;;;;;;;GAqBG;AACH,MAAM,UAAU,YAAY,CAAC,EAC3B,KAAK,EACL,IAAI,EACJ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AAG,EAAE,CAAC,CAClC,EAAE,CAAC,CAAC,EAAE,GAAG,IAAI,CAAC,GAAG,CAAC,SAAS,CAAC,GAAG,EAAE,CAAC,CAClC,EAAE,CAAC,CAAC,EAAE,GAAG,IAAI,CAAC,GAAG,CAAC,SAAS,CAAC,GAAG,EAAE,CAAC,CAClC,EAAE,CAAC,CAAC,EAAE,GAAG,IAAI,CAAC,GAAG,CAAC,SAAS,CAAC,GAAG,EAAE,CAAC,CAClC,WAAW,CAAC,CAAC,GAAG,CAAC,CACjB,aAAa,CAAC,OAAO,CACrB,SAAS,CAAC,gCAAgC,EAC1C,CACH,CACH;UAAA,EAAE,GAAG,CACP;QAAA,EAAE,IAAI,CAAC,IAAI,CACX;QAAA,CAAC,IAAI,CAAC,IAAI,CACR;UAAA,CAAC,iBAAiB,CAAC,KAAK,CAAC,CAAC,OAAO,CAAC,CAAC,SAAS,CAAC,eAAe,EAC9D;QAAA,EAAE,IAAI,CAAC,IAAI,CACb;MAAA,EAAE,IAAI,CACN;MAAA,CAAC,CAAC,CAAC,QAAQ,IAAI,CACb,CAAC,GAAG,CAAC,SAAS,CAAC,wEAAwE,CACrF;UAAA,CAAC,QAAQ,CACX;QAAA,EAAE,GAAG,CAAC,CACP,CACH;IAAA,EAAE,GAAG,CAAC,CACP,CAAC;AACJ,CAAC"}
@@ -0,0 +1,3 @@
1
+ export { ExpScoreRing } from './ExpScoreRing';
2
+ export type { ExpScoreRingProps } from './ExpScoreRing';
3
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/expresivo/ExpScoreRing/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,YAAY,EAAE,MAAM,gBAAgB,CAAC;AAC9C,YAAY,EAAE,iBAAiB,EAAE,MAAM,gBAAgB,CAAC"}
@@ -0,0 +1,2 @@
1
+ export { ExpScoreRing } from './ExpScoreRing';
2
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/expresivo/ExpScoreRing/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,YAAY,EAAE,MAAM,gBAAgB,CAAC"}
@@ -0,0 +1,12 @@
1
+ export * from './ExpScope';
2
+ export * from './ExpMascot';
3
+ export * from './ExpLensIcon';
4
+ export * from './ExpKeyButton';
5
+ export * from './ExpPillButton';
6
+ export * from './ExpMedalBadge';
7
+ export * from './ExpScoreRing';
8
+ export * from './ExpGrowBar';
9
+ export * from './ExpJourneyTrack';
10
+ export * from './ExpBubble';
11
+ export * from './ExpCollapseToggle';
12
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/expresivo/index.ts"],"names":[],"mappings":"AAAA,cAAc,YAAY,CAAC;AAC3B,cAAc,aAAa,CAAC;AAC5B,cAAc,eAAe,CAAC;AAC9B,cAAc,gBAAgB,CAAC;AAC/B,cAAc,iBAAiB,CAAC;AAChC,cAAc,iBAAiB,CAAC;AAChC,cAAc,gBAAgB,CAAC;AAC/B,cAAc,cAAc,CAAC;AAC7B,cAAc,mBAAmB,CAAC;AAClC,cAAc,aAAa,CAAC;AAC5B,cAAc,qBAAqB,CAAC"}
@@ -0,0 +1,12 @@
1
+ export * from './ExpScope';
2
+ export * from './ExpMascot';
3
+ export * from './ExpLensIcon';
4
+ export * from './ExpKeyButton';
5
+ export * from './ExpPillButton';
6
+ export * from './ExpMedalBadge';
7
+ export * from './ExpScoreRing';
8
+ export * from './ExpGrowBar';
9
+ export * from './ExpJourneyTrack';
10
+ export * from './ExpBubble';
11
+ export * from './ExpCollapseToggle';
12
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../src/expresivo/index.ts"],"names":[],"mappings":"AAAA,cAAc,YAAY,CAAC;AAC3B,cAAc,aAAa,CAAC;AAC5B,cAAc,eAAe,CAAC;AAC9B,cAAc,gBAAgB,CAAC;AAC/B,cAAc,iBAAiB,CAAC;AAChC,cAAc,iBAAiB,CAAC;AAChC,cAAc,gBAAgB,CAAC;AAC/B,cAAc,cAAc,CAAC;AAC7B,cAAc,mBAAmB,CAAC;AAClC,cAAc,aAAa,CAAC;AAC5B,cAAc,qBAAqB,CAAC"}
@@ -0,0 +1,20 @@
1
+ import type { ReactNode } from 'react';
2
+ export type GlyphProps = {
3
+ size: number;
4
+ busy?: boolean;
5
+ disabled?: boolean;
6
+ };
7
+ /**
8
+ * Magnifier with an eye inside. Blinks at rest, looks towards the label
9
+ * while its button is hovered and scans while busy.
10
+ */
11
+ export declare function LensGlyph({ size, busy, disabled }: GlyphProps): ReactNode;
12
+ /** Two arrows in a white disc. Turn while hovered, spin while busy. */
13
+ export declare function SyncBadgeGlyph({ size, busy, disabled, }: GlyphProps): ReactNode;
14
+ /** Two arrows in the text color. Half turn while hovered, spin while busy. */
15
+ export declare function SyncGlyph({ size, busy, disabled }: GlyphProps): ReactNode;
16
+ /** A door with an arrow going in. The arrow steps in while hovered or busy. */
17
+ export declare function EnterGlyph({ size, busy, disabled }: GlyphProps): ReactNode;
18
+ /** Right arrow that steps forward while its button is hovered. */
19
+ export declare function ArrowGlyph({ size }: Pick<GlyphProps, 'size'>): ReactNode;
20
+ //# sourceMappingURL=glyphs.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"glyphs.d.ts","sourceRoot":"","sources":["../../src/expresivo/shared/glyphs.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AAEvC,MAAM,MAAM,UAAU,GAAG;IACvB,IAAI,EAAE,MAAM,CAAC;IACb,IAAI,CAAC,EAAE,OAAO,CAAC;IACf,QAAQ,CAAC,EAAE,OAAO,CAAC;CACpB,CAAC;AAEF;;;GAGG;AACH,wBAAgB,SAAS,CAAC,EAAE,IAAI,EAAE,IAAI,EAAE,QAAQ,EAAE,EAAE,UAAU,GAAG,SAAS,CAqDzE;AAED,uEAAuE;AACvE,wBAAgB,cAAc,CAAC,EAC7B,IAAI,EACJ,IAAI,EACJ,QAAQ,GACT,EAAE,UAAU,GAAG,SAAS,CAwCxB;AAED,8EAA8E;AAC9E,wBAAgB,SAAS,CAAC,EAAE,IAAI,EAAE,IAAI,EAAE,QAAQ,EAAE,EAAE,UAAU,GAAG,SAAS,CA4BzE;AAED,+EAA+E;AAC/E,wBAAgB,UAAU,CAAC,EAAE,IAAI,EAAE,IAAI,EAAE,QAAQ,EAAE,EAAE,UAAU,GAAG,SAAS,CAyB1E;AAED,kEAAkE;AAClE,wBAAgB,UAAU,CAAC,EAAE,IAAI,EAAE,EAAE,IAAI,CAAC,UAAU,EAAE,MAAM,CAAC,GAAG,SAAS,CAiBxE"}
@@ -0,0 +1,60 @@
1
+ import clsx from 'clsx';
2
+ /**
3
+ * Magnifier with an eye inside. Blinks at rest, looks towards the label
4
+ * while its button is hovered and scans while busy.
5
+ */
6
+ export function LensGlyph({ size, busy, disabled }) {
7
+ return (<svg aria-hidden="true" width={size} height={size} viewBox="0 0 34 34" className={clsx('exp-lens shrink-0 overflow-visible', busy && 'exp-glyph--busy', disabled && 'exp-glyph--disabled')}>
8
+ <path d="M22.5 22.5 30 30" strokeWidth={4.5} strokeLinecap="round" className={disabled ? 'stroke-gray-3' : 'stroke-amber'}/>
9
+ <path d="M22.5 22.5 30 30" strokeWidth={2} strokeLinecap="round" className={disabled ? 'stroke-gray-4' : 'stroke-warning'}/>
10
+ <circle cx={14} cy={14} r={12.5} strokeWidth={2} className={clsx('fill-white', disabled ? 'stroke-gray-4' : 'stroke-lavender-1')}/>
11
+ <g className="exp-lens-lid">
12
+ <path d="M5 14C7.2 10.2 10.4 8.3 14 8.3S20.8 10.2 23 14C20.8 17.8 17.6 19.7 14 19.7S7.2 17.8 5 14Z" className={disabled ? 'fill-gray-6' : 'fill-lavender-2'}/>
13
+ <g className="exp-lens-pupil">
14
+ <circle cx={14} cy={14} r={4.6} className={disabled ? 'fill-gray-2' : 'fill-lavender'}/>
15
+ <circle cx={14} cy={14} r={2.2} className="fill-black"/>
16
+ <circle cx={15.6} cy={12.4} r={1.2} className="fill-white"/>
17
+ </g>
18
+ </g>
19
+ </svg>);
20
+ }
21
+ /** Two arrows in a white disc. Turn while hovered, spin while busy. */
22
+ export function SyncBadgeGlyph({ size, busy, disabled, }) {
23
+ return (<svg aria-hidden="true" width={size} height={size} viewBox="0 0 34 34" className={clsx('shrink-0 overflow-visible [--exp-rotor-turn:150deg]', busy && 'exp-glyph--busy', disabled && 'exp-glyph--disabled')}>
24
+ <circle cx={17} cy={17} r={15.5} strokeWidth={2} className={clsx('fill-white', disabled ? 'stroke-gray-4' : 'stroke-lavender-1')}/>
25
+ <g fill="none" strokeWidth={2.4} strokeLinecap="round" strokeLinejoin="round" className={clsx('exp-rotor', disabled ? 'stroke-gray-2' : 'stroke-lavender')}>
26
+ <path d="M24.5 13.5A8 8 0 0 0 10 12"/>
27
+ <polyline points="24.8 8.5 24.8 13.8 19.5 13.8"/>
28
+ <path d="M9.5 20.5A8 8 0 0 0 24 22"/>
29
+ <polyline points="9.2 25.5 9.2 20.2 14.5 20.2"/>
30
+ </g>
31
+ </svg>);
32
+ }
33
+ /** Two arrows in the text color. Half turn while hovered, spin while busy. */
34
+ export function SyncGlyph({ size, busy, disabled }) {
35
+ return (<svg aria-hidden="true" width={size} height={size} viewBox="0 0 24 24" className={clsx('shrink-0 overflow-visible', busy && 'exp-glyph--busy', disabled && 'exp-glyph--disabled')}>
36
+ <g fill="none" stroke="currentColor" strokeWidth={2.2} strokeLinecap="round" strokeLinejoin="round" className="exp-rotor">
37
+ <path d="M20 9A8 8 0 0 0 5.6 7.2"/>
38
+ <polyline points="20.5 4 20.5 9.2 15.3 9.2"/>
39
+ <path d="M4 15a8 8 0 0 0 14.4 1.8"/>
40
+ <polyline points="3.5 20 3.5 14.8 8.7 14.8"/>
41
+ </g>
42
+ </svg>);
43
+ }
44
+ /** A door with an arrow going in. The arrow steps in while hovered or busy. */
45
+ export function EnterGlyph({ size, busy, disabled }) {
46
+ return (<svg aria-hidden="true" width={size} height={size} viewBox="0 0 24 24" fill="none" stroke="currentColor" strokeWidth={2.2} strokeLinecap="round" strokeLinejoin="round" className={clsx('shrink-0 overflow-visible', busy && 'exp-glyph--busy', disabled && 'exp-glyph--disabled')}>
47
+ <path d="M14 4h4a2 2 0 0 1 2 2v12a2 2 0 0 1-2 2h-4"/>
48
+ <g className="exp-enter-arrow">
49
+ <polyline points="10 17 15 12 10 7"/>
50
+ <line x1={15} y1={12} x2={3} y2={12}/>
51
+ </g>
52
+ </svg>);
53
+ }
54
+ /** Right arrow that steps forward while its button is hovered. */
55
+ export function ArrowGlyph({ size }) {
56
+ return (<svg aria-hidden="true" width={size} height={size} viewBox="0 0 24 24" fill="none" stroke="currentColor" strokeWidth={2.4} strokeLinecap="round" strokeLinejoin="round" className="exp-arrow shrink-0">
57
+ <path d="M5 12h14M13 6l6 6-6 6"/>
58
+ </svg>);
59
+ }
60
+ //# sourceMappingURL=glyphs.jsx.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"glyphs.jsx","sourceRoot":"","sources":["../../src/expresivo/shared/glyphs.tsx"],"names":[],"mappings":"AAAA,OAAO,IAAI,MAAM,MAAM,CAAC;AASxB;;;GAGG;AACH,MAAM,UAAU,SAAS,CAAC,EAAE,IAAI,EAAE,IAAI,EAAE,QAAQ,EAAc;IAC5D,OAAO,CACL,CAAC,GAAG,CACF,WAAW,CAAC,MAAM,CAClB,KAAK,CAAC,CAAC,IAAI,CAAC,CACZ,MAAM,CAAC,CAAC,IAAI,CAAC,CACb,OAAO,CAAC,WAAW,CACnB,SAAS,CAAC,CAAC,IAAI,CACb,oCAAoC,EACpC,IAAI,IAAI,iBAAiB,EACzB,QAAQ,IAAI,qBAAqB,CAClC,CAAC,CAEF;MAAA,CAAC,IAAI,CACH,CAAC,CAAC,kBAAkB,CACpB,WAAW,CAAC,C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M,CAAC,cAAc,CACrB,WAAW,CAAC,CAAC,GAAG,CAAC,CACjB,aAAa,CAAC,OAAO,CACrB,cAAc,CAAC,OAAO,CACtB,SAAS,CAAC,CAAC,IAAI,CACb,2BAA2B,EAC3B,IAAI,IAAI,iBAAiB,EACzB,QAAQ,IAAI,qBAAqB,CAClC,CAAC,CAEF;MAAA,CAAC,IAAI,CAAC,CAAC,CAAC,2CAA2C,EACnD;MAAA,CAAC,CAAC,CAAC,SAAS,CAAC,iBAAiB,CAC5B;QAAA,CAAC,QAAQ,CAAC,MAAM,CAAC,kBAAkB,EACnC;QAAA,CAAC,IAAI,CAAC,EAAE,CAAC,CAAC,EAAE,CAAC,CAAC,EAAE,CAAC,CAAC,EAAE,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,EAAE,CAAC,EACtC;MAAA,EAAE,CAAC,CACL;IAAA,EAAE,GAAG,CAAC,CACP,CAAC;AACJ,CAAC;AAED,kEAAkE;AAClE,MAAM,UAAU,UAAU,CAAC,EAAE,IAAI,EAA4B;IAC3D,OAAO,CACL,CAAC,GAAG,CACF,WAAW,CAAC,MAAM,CAClB,KAAK,CAAC,CAAC,IAAI,CAAC,CACZ,MAAM,CAAC,CAAC,IAAI,CAAC,CACb,OAAO,CAAC,WAAW,CACnB,IAAI,CAAC,MAAM,CACX,MAAM,CAAC,cAAc,CACrB,WAAW,CAAC,CAAC,GAAG,CAAC,CACjB,aAAa,CAAC,OAAO,CACrB,cAAc,CAAC,OAAO,CACtB,SAAS,CAAC,oBAAoB,CAE9B;MAAA,CAAC,IAAI,CAAC,CAAC,CAAC,uBAAuB,EACjC;IAAA,EAAE,GAAG,CAAC,CACP,CAAC;AACJ,CAAC"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@clicoh/orion-library",
3
- "version": "1.2.0-beta.11",
3
+ "version": "1.2.0-beta.13",
4
4
  "main": "index.js",
5
5
  "dependencies": {
6
6
  "@floating-ui/react": "0.26.19",
@@ -50,6 +50,7 @@
50
50
  "index.d.ts",
51
51
  "tailwind.config.ts",
52
52
  "dist",
53
+ "expresivo",
53
54
  "assets"
54
55
  ],
55
56
  "publishConfig": {
@@ -62,7 +63,7 @@
62
63
  "author": "",
63
64
  "license": "ISC",
64
65
  "scripts": {
65
- "build": "node scripts/sync-rules.mjs --check && tsc --project tsconfig.components.json",
66
+ "build": "node scripts/sync-rules.mjs --check && node scripts/check-expresivo.mjs && tsc --project tsconfig.components.json && tsc --project tsconfig.expresivo.json",
66
67
  "rules:sync": "node scripts/sync-rules.mjs",
67
68
  "format": "prettier --write src",
68
69
  "storybook": "storybook dev -p 6006 --ci",