uikit-react-public 0.17.4 → 0.21.9

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 (282) hide show
  1. package/README.md +2 -4
  2. package/dist/components/Accordion/Accordion.Heading.d.ts +1 -0
  3. package/dist/components/AppHeader/AppHeader.d.ts +1 -1
  4. package/dist/components/AppHeader/AppHeaderBottom.d.ts +1 -1
  5. package/dist/components/AppHeader/AppHeaderNav.d.ts +1 -1
  6. package/dist/components/AppHeader/AppHeaderTop.d.ts +1 -1
  7. package/dist/components/Breadcrumbs/Breadcrumb.d.ts +3 -4
  8. package/dist/components/Breadcrumbs/Breadcrumbs.d.ts +1 -1
  9. package/dist/components/Breadcrumbs/Breadcrumbs.stories.d.ts +1 -1
  10. package/dist/components/Button/Button.d.ts +7 -3
  11. package/dist/components/Button/Button.stories.d.ts +17 -7
  12. package/dist/components/Button/style/buttonAccentStyle.d.ts +4 -0
  13. package/dist/components/Button/style/buttonPrimaryDestructiveStyle.d.ts +4 -0
  14. package/dist/components/Button/style/buttonPrimaryStyle.d.ts +4 -0
  15. package/dist/components/Button/style/buttonPrimarySubtleStyle.d.ts +4 -0
  16. package/dist/components/Button/style/buttonPrimaryWarningStyle.d.ts +4 -0
  17. package/dist/components/Button/style/buttonSecondaryDestructiveStyle.d.ts +4 -0
  18. package/dist/components/Button/style/buttonSecondaryStyle.d.ts +4 -0
  19. package/dist/components/Button/style/buttonSecondarySubtleStyle.d.ts +4 -0
  20. package/dist/components/Button/style/buttonTertiaryDestructiveStyle.d.ts +4 -0
  21. package/dist/components/Button/style/buttonTertiaryNoPaddingStyle.d.ts +4 -0
  22. package/dist/components/Button/style/buttonTertiaryStyle.d.ts +4 -0
  23. package/dist/components/Checkbox/Checkbox.d.ts +1 -0
  24. package/dist/components/FooterNew/BackToTop.d.ts +8 -0
  25. package/dist/components/FooterNew/Footer.d.ts +23 -0
  26. package/dist/components/FooterNew/FooterColumn.d.ts +8 -0
  27. package/dist/components/FooterNew/FooterLinks.d.ts +7 -0
  28. package/dist/components/FooterNew/FooterNavLink.d.ts +8 -0
  29. package/dist/components/FooterNew/LegalAndCopyright.d.ts +14 -0
  30. package/dist/components/FooterNew/LogoAddressAndSocial.d.ts +10 -0
  31. package/dist/components/FooterNew/SocialLink.d.ts +8 -0
  32. package/dist/components/FooterNew/__tests__/Footer.test.d.ts +1 -0
  33. package/dist/components/FooterNew/index.d.ts +2 -0
  34. package/dist/components/HeaderNew/Header.d.ts +18 -0
  35. package/dist/components/HeaderNew/HeaderBorder.d.ts +7 -0
  36. package/dist/components/HeaderNew/HeaderLogo.d.ts +9 -0
  37. package/dist/components/HeaderNew/HeaderMenuContainer.d.ts +7 -0
  38. package/dist/components/HeaderNew/HeaderTitle.d.ts +9 -0
  39. package/dist/components/HeaderNew/__tests__/Header.test.d.ts +1 -0
  40. package/dist/components/HeaderNew/constants.d.ts +3 -0
  41. package/dist/components/HeaderNew/index.d.ts +3 -0
  42. package/dist/components/Heading/Heading.d.ts +6 -4
  43. package/dist/components/Heading/Heading.stories.d.ts +8 -6
  44. package/dist/components/Icon/svgImports.d.ts +7 -881
  45. package/dist/components/Link/BaseLink.d.ts +14 -5
  46. package/dist/components/Link/Link.d.ts +8 -3
  47. package/dist/components/Link/Link.stories.d.ts +3 -1
  48. package/dist/components/MenuNew/Menu.context.d.ts +14 -0
  49. package/dist/components/MenuNew/Menu.d.ts +20 -0
  50. package/dist/components/MenuNew/MenuContent.d.ts +9 -0
  51. package/dist/components/MenuNew/MenuItem.d.ts +10 -0
  52. package/dist/components/MenuNew/MenuSection.d.ts +7 -0
  53. package/dist/components/MenuNew/index.d.ts +6 -0
  54. package/dist/components/MenuNew/trigger/ButtonMenuTrigger.d.ts +8 -0
  55. package/dist/components/MenuNew/trigger/IconMenuTrigger.d.ts +8 -0
  56. package/dist/components/Overlay/Overlay.stories.d.ts +12 -12
  57. package/dist/components/Paragraph/Paragraph.d.ts +5 -2
  58. package/dist/components/Paragraph/Paragraph.stories.d.ts +6 -3
  59. package/dist/components/Select/Select.d.ts +2 -1
  60. package/dist/components/Select/Select.stories.d.ts +13 -1
  61. package/dist/components/Select/Select.types.d.ts +40 -13
  62. package/dist/components/Select/subcomponents/CustomSelect.d.ts +3 -3
  63. package/dist/components/Select/subcomponents/FilterInput.d.ts +3 -1
  64. package/dist/components/Select/subcomponents/NativeSelect.d.ts +2 -2
  65. package/dist/components/Select/subcomponents/VisibleField.d.ts +4 -1
  66. package/dist/components/Spinner/Spinner.d.ts +2 -0
  67. package/dist/components/StandaloneLink/StandaloneLink.d.ts +8 -5
  68. package/dist/components/StandaloneLink/StandaloneLink.stories.d.ts +3 -1
  69. package/dist/components/Table/Table.d.ts +3 -3
  70. package/dist/components/Table/Table.stories.d.ts +3 -3
  71. package/dist/components/Table/Table.types.d.ts +1 -0
  72. package/dist/components/Table/subcomponents/Cell/Cell.d.ts +5 -1
  73. package/dist/components/Table/subcomponents/Cell/Cell.stories.d.ts +15 -13
  74. package/dist/components/Table/subcomponents/Cell/CellContent.d.ts +5 -1
  75. package/dist/components/Table/subcomponents/HeadCell/HeadCell.d.ts +2 -1
  76. package/dist/components/Table/subcomponents/HeadCell/HeadCell.stories.d.ts +14 -13
  77. package/dist/components/Table/subcomponents/HeadCell/HeadCellContent.d.ts +2 -1
  78. package/dist/components/Table/subcomponents/__tests__/Row.test.d.ts +1 -0
  79. package/dist/components/UclLogoNew/UclLogo.d.ts +8 -0
  80. package/dist/components/UclLogoNew/index.d.ts +2 -0
  81. package/dist/components/index.d.ts +12 -0
  82. package/dist/index.js +20104 -15317
  83. package/dist/theme/__tests__/fonts.test.d.ts +1 -0
  84. package/dist/theme/common/themeCommon.d.ts +904 -0
  85. package/dist/theme/fonts.d.ts +18 -0
  86. package/dist/theme/index.d.ts +6 -3
  87. package/dist/theme/light/lightColour.d.ts +126 -0
  88. package/dist/theme/light/lightTheme.d.ts +3 -0
  89. package/dist/theme/original/color.d.ts +166 -0
  90. package/dist/theme/original/defaultTheme.d.ts +1340 -0
  91. package/dist/theme/original/originalColourNewStructure.d.ts +126 -0
  92. package/dist/theme/useTheme.d.ts +2174 -0
  93. package/dist/utils/addAlphaToHex.d.ts +5 -0
  94. package/dist/utils/scrollToTop.d.ts +2 -0
  95. package/lib/components/Accordion/Accordion.Heading.tsx +51 -39
  96. package/lib/components/Accordion/Accordion.Panel.tsx +0 -4
  97. package/lib/components/Accordion/Accordion.tsx +34 -28
  98. package/lib/components/Accordion/__tests__/__snapshots__/Accordion.test.tsx.snap +12 -10
  99. package/lib/components/Alert/Alert.tsx +12 -12
  100. package/lib/components/Alert/__tests__/__snapshots__/Alert.test.tsx.snap +13 -39
  101. package/lib/components/AppHeader/AppHeader.tsx +6 -11
  102. package/lib/components/AppHeader/AppHeaderBottom.tsx +2 -3
  103. package/lib/components/AppHeader/AppHeaderNav.tsx +2 -3
  104. package/lib/components/AppHeader/AppHeaderTop.tsx +1 -1
  105. package/lib/components/AppHeader/__tests__/__snapshots__/AppHeader.test.tsx.snap +2 -2
  106. package/lib/components/AppMenu/__tests__/__snapshots__/AppMenu.test.tsx.snap +6 -19
  107. package/lib/components/Badge/Badge.stories.tsx +1 -1
  108. package/lib/components/Breadcrumbs/Breadcrumb.tsx +26 -12
  109. package/lib/components/Breadcrumbs/Breadcrumbs.tsx +1 -1
  110. package/lib/components/Breadcrumbs/__tests__/Breadcrumbs.test.tsx +9 -27
  111. package/lib/components/Breadcrumbs/__tests__/__snapshots__/Breadcrumbs.test.tsx.snap +24 -20
  112. package/lib/components/Button/Button.mdx +32 -279
  113. package/lib/components/Button/Button.stories.tsx +43 -50
  114. package/lib/components/Button/Button.tsx +165 -25
  115. package/lib/components/Button/__tests__/Button.test.tsx +49 -15
  116. package/lib/components/Button/__tests__/__snapshots__/Button.test.tsx.snap +80 -73
  117. package/lib/components/Button/style/buttonAccentStyle.ts +53 -0
  118. package/lib/components/Button/style/buttonPrimaryDestructiveStyle.ts +55 -0
  119. package/lib/components/Button/style/buttonPrimaryStyle.ts +53 -0
  120. package/lib/components/Button/style/buttonPrimarySubtleStyle.ts +64 -0
  121. package/lib/components/Button/style/buttonPrimaryWarningStyle.ts +56 -0
  122. package/lib/components/Button/style/buttonSecondaryDestructiveStyle.ts +63 -0
  123. package/lib/components/Button/style/buttonSecondaryStyle.ts +62 -0
  124. package/lib/components/Button/style/buttonSecondarySubtleStyle.ts +72 -0
  125. package/lib/components/Button/style/buttonTertiaryDestructiveStyle.ts +65 -0
  126. package/lib/components/Button/style/buttonTertiaryNoPaddingStyle.ts +52 -0
  127. package/lib/components/Button/style/buttonTertiaryStyle.ts +62 -0
  128. package/lib/components/Calendar/Calendar.stories.tsx +33 -13
  129. package/lib/components/Calendar/Calendar.tsx +2 -2
  130. package/lib/components/Calendar/__tests__/__snapshots__/Calendar.test.tsx.snap +99 -95
  131. package/lib/components/Calendar/subcomponents/AcademicWeek.tsx +2 -1
  132. package/lib/components/Calendar/subcomponents/AcademicWeeks.tsx +2 -3
  133. package/lib/components/Calendar/subcomponents/ColumnHeading.tsx +3 -7
  134. package/lib/components/Calendar/subcomponents/Controls.tsx +1 -1
  135. package/lib/components/Calendar/subcomponents/Day.stories.tsx +1 -1
  136. package/lib/components/Calendar/subcomponents/Day.tsx +7 -9
  137. package/lib/components/Calendar/subcomponents/EventDot.tsx +4 -8
  138. package/lib/components/Checkbox/Checkbox.stories.tsx +1 -1
  139. package/lib/components/Checkbox/Checkbox.tsx +12 -10
  140. package/lib/components/Checkbox/__tests__/Checkbox.test.tsx +29 -0
  141. package/lib/components/Checkbox/__tests__/__snapshots__/Checkbox.test.tsx.snap +4 -4
  142. package/lib/components/Datepicker/__tests__/Datepicker.test.tsx +117 -0
  143. package/lib/components/Datepicker/__tests__/__snapshots__/Datepicker.test.tsx.snap +16 -44
  144. package/lib/components/Datepicker/subcomponents/CustomDatepicker.tsx +10 -1
  145. package/lib/components/Datepicker/subcomponents/VisibleField.tsx +24 -23
  146. package/lib/components/Dialog/BaseDialog.tsx +2 -2
  147. package/lib/components/Dialog/Dialog.stories.tsx +1 -1
  148. package/lib/components/Divider/__tests__/__snapshots__/Breadcrumbs.test.tsx.snap +12 -12
  149. package/lib/components/FeedbackDialog/FeedbackDialog.stories.tsx +1 -1
  150. package/lib/components/FeedbackDialog/FeedbackDialog.tsx +4 -6
  151. package/lib/components/Field/CharacterCount.tsx +2 -2
  152. package/lib/components/Field/ErrorText.tsx +1 -1
  153. package/lib/components/Field/Field.tsx +1 -1
  154. package/lib/components/Field/HelperText.tsx +3 -1
  155. package/lib/components/FileInput/FileInput.stories.tsx +1 -1
  156. package/lib/components/FileInput/__tests__/__snapshots__/FileInput.test.tsx.snap +4 -20
  157. package/lib/components/Footer/__tests__/__snapshots__/Footer.test.tsx.snap +70 -79
  158. package/lib/components/FooterNew/BackToTop.tsx +83 -0
  159. package/lib/components/FooterNew/Footer.tsx +110 -0
  160. package/lib/components/FooterNew/FooterColumn.tsx +79 -0
  161. package/lib/components/FooterNew/FooterLinks.tsx +44 -0
  162. package/lib/components/FooterNew/FooterNavLink.tsx +63 -0
  163. package/lib/components/FooterNew/LegalAndCopyright.tsx +150 -0
  164. package/lib/components/FooterNew/LogoAddressAndSocial.tsx +154 -0
  165. package/lib/components/FooterNew/SocialLink.tsx +108 -0
  166. package/lib/components/FooterNew/__tests__/Footer.test.tsx +51 -0
  167. package/lib/components/FooterNew/__tests__/__snapshots__/Footer.test.tsx.snap +1107 -0
  168. package/lib/components/FooterNew/index.ts +2 -0
  169. package/lib/components/HeaderDraft/__tests__/__snapshots__/Header.test.tsx.snap +3 -2
  170. package/lib/components/HeaderNew/Header.tsx +93 -0
  171. package/lib/components/HeaderNew/HeaderBorder.tsx +55 -0
  172. package/lib/components/HeaderNew/HeaderLogo.tsx +70 -0
  173. package/lib/components/HeaderNew/HeaderMenuContainer.tsx +35 -0
  174. package/lib/components/HeaderNew/HeaderTitle.tsx +53 -0
  175. package/lib/components/HeaderNew/__tests__/Header.test.tsx +42 -0
  176. package/lib/components/HeaderNew/__tests__/__snapshots__/Header.test.tsx.snap +79 -0
  177. package/lib/components/HeaderNew/constants.ts +3 -0
  178. package/lib/components/HeaderNew/index.ts +7 -0
  179. package/lib/components/Heading/Heading.stories.tsx +34 -41
  180. package/lib/components/Heading/Heading.tsx +180 -49
  181. package/lib/components/Heading/__tests__/__snapshots__/Heading.test.tsx.snap +4 -4
  182. package/lib/components/Icon/__tests__/__snapshots__/Icon.test.tsx.snap +16 -12
  183. package/lib/components/Icon/svgImports.ts +318 -296
  184. package/lib/components/IconButton/IconButton.tsx +3 -4
  185. package/lib/components/IconButton/__tests__/__snapshots__/IconButton.test.tsx.snap +12 -9
  186. package/lib/components/Link/BaseLink.tsx +114 -71
  187. package/lib/components/Link/Link.stories.tsx +1 -1
  188. package/lib/components/Link/Link.tsx +120 -109
  189. package/lib/components/Link/__tests__/__snapshots__/link.test.tsx.snap +2 -2
  190. package/lib/components/MenuNew/Menu.context.tsx +149 -0
  191. package/lib/components/MenuNew/Menu.tsx +75 -0
  192. package/lib/components/MenuNew/MenuContent.tsx +140 -0
  193. package/lib/components/MenuNew/MenuItem.tsx +101 -0
  194. package/lib/components/MenuNew/MenuSection.tsx +47 -0
  195. package/lib/components/MenuNew/index.ts +8 -0
  196. package/lib/components/MenuNew/trigger/ButtonMenuTrigger.tsx +42 -0
  197. package/lib/components/MenuNew/trigger/IconMenuTrigger.tsx +40 -0
  198. package/lib/components/Pagination/Pagination.stories.tsx +1 -1
  199. package/lib/components/Pagination/PaginationControls.tsx +4 -5
  200. package/lib/components/Pagination/PaginationInfo.tsx +2 -3
  201. package/lib/components/Paragraph/Paragraph.stories.tsx +29 -27
  202. package/lib/components/Paragraph/Paragraph.tsx +212 -81
  203. package/lib/components/Paragraph/__tests__/__snapshots__/Paragraph.test.tsx.snap +5 -5
  204. package/lib/components/Radio/Radio.stories.tsx +1 -1
  205. package/lib/components/Radio/Radio.tsx +8 -8
  206. package/lib/components/Radio/__tests__/__snapshots__/Radio.test.tsx.snap +4 -4
  207. package/lib/components/Search/__tests__/__snapshots__/Search.test.tsx.snap +12 -32
  208. package/lib/components/Select/Select.mdx +23 -0
  209. package/lib/components/Select/Select.stories.tsx +43 -10
  210. package/lib/components/Select/Select.tsx +14 -3
  211. package/lib/components/Select/Select.types.ts +53 -16
  212. package/lib/components/Select/__tests__/Select.test.tsx +250 -1
  213. package/lib/components/Select/__tests__/__snapshots__/Select.test.tsx.snap +5 -4
  214. package/lib/components/Select/subcomponents/CustomOption.tsx +10 -3
  215. package/lib/components/Select/subcomponents/CustomSelect.tsx +110 -10
  216. package/lib/components/Select/subcomponents/FilterInput.tsx +13 -3
  217. package/lib/components/Select/subcomponents/NativeSelect.tsx +10 -18
  218. package/lib/components/Select/subcomponents/Panel.tsx +2 -2
  219. package/lib/components/Select/subcomponents/VisibleField.tsx +48 -3
  220. package/lib/components/Snackbar/__tests__/__snapshots__/Snackbar.test.tsx.snap +9 -15
  221. package/lib/components/Spinner/Spinner.tsx +24 -5
  222. package/lib/components/Spinner/__tests__/Spinner.test.tsx +35 -5
  223. package/lib/components/Spinner/__tests__/__snapshots__/Spinner.test.tsx.snap +40 -16
  224. package/lib/components/StandaloneLink/StandaloneLink.stories.tsx +1 -1
  225. package/lib/components/StandaloneLink/StandaloneLink.tsx +180 -163
  226. package/lib/components/StandaloneLink/__tests__/__snapshots__/StandaloneLink.test.tsx.snap +2 -2
  227. package/lib/components/Table/Table.stories.tsx +1 -1
  228. package/lib/components/Table/Table.tsx +2 -0
  229. package/lib/components/Table/Table.types.ts +1 -0
  230. package/lib/components/Table/__tests__/Table.test.tsx +19 -0
  231. package/lib/components/Table/__tests__/__snapshots__/Table.test.tsx.snap +7 -3
  232. package/lib/components/Table/subcomponents/Cell/Cell.stories.tsx +1 -1
  233. package/lib/components/Table/subcomponents/Cell/Cell.tsx +23 -2
  234. package/lib/components/Table/subcomponents/Cell/CellContent.tsx +12 -1
  235. package/lib/components/Table/subcomponents/Cell/__tests__/Cell.test.tsx +106 -0
  236. package/lib/components/Table/subcomponents/Cell/__tests__/__snapshots__/Cell.test.tsx.snap +4 -3
  237. package/lib/components/Table/subcomponents/HeadCell/HeadCell.stories.tsx +1 -1
  238. package/lib/components/Table/subcomponents/HeadCell/HeadCell.tsx +28 -6
  239. package/lib/components/Table/subcomponents/HeadCell/HeadCellContent.tsx +3 -0
  240. package/lib/components/Table/subcomponents/HeadCell/__tests__/HeadCell.test.tsx +221 -2
  241. package/lib/components/Table/subcomponents/HeadCell/__tests__/__snapshots__/HeadCell.test.tsx.snap +6 -4
  242. package/lib/components/Table/subcomponents/Row.tsx +2 -2
  243. package/lib/components/Table/subcomponents/SortIcon.tsx +1 -0
  244. package/lib/components/Table/subcomponents/__tests__/Row.test.tsx +59 -0
  245. package/lib/components/Tabs/Tab.tsx +3 -3
  246. package/lib/components/Tabs/Tabs.stories.tsx +1 -1
  247. package/lib/components/Tabs/Tabs.tsx +5 -3
  248. package/lib/components/Tabs/__tests__/__snapshots__/Tabs.test.tsx.snap +4 -4
  249. package/lib/components/Timepicker/Timepicker.stories.tsx +1 -1
  250. package/lib/components/Toggle/Toggle.tsx +5 -5
  251. package/lib/components/Toggle/ToggleHandle.tsx +2 -3
  252. package/lib/components/Tooltip/Tooltip.tsx +2 -2
  253. package/lib/components/Tooltip/__tests__/__snapshots__/tooltip.test.tsx.snap +2 -2
  254. package/lib/components/UclLogoNew/UclLogo.tsx +42 -0
  255. package/lib/components/UclLogoNew/index.ts +2 -0
  256. package/lib/components/WeekPicker/WeekPicker.stories.tsx +3 -5
  257. package/lib/components/common/Common.mdx +0 -1
  258. package/lib/components/index.ts +19 -1
  259. package/lib/theme/Colours.mdx +1 -1
  260. package/lib/theme/Theme.mdx +1 -1
  261. package/lib/theme/Typography.mdx +1 -1
  262. package/lib/theme/__tests__/fonts.test.ts +37 -0
  263. package/lib/theme/common/themeCommon.ts +515 -0
  264. package/lib/theme/fonts.ts +110 -0
  265. package/lib/theme/index.ts +6 -6
  266. package/lib/theme/light/lightColour.ts +232 -0
  267. package/lib/theme/light/lightTheme.ts +37 -0
  268. package/lib/theme/{defaultTheme.ts → original/color.ts} +17 -199
  269. package/lib/theme/original/defaultTheme.ts +207 -0
  270. package/lib/theme/original/originalColourNewStructure.ts +185 -0
  271. package/lib/theme/useTheme.tsx +72 -15
  272. package/lib/types/assets.d.ts +10 -0
  273. package/lib/utils/addAlphaToHex.ts +29 -0
  274. package/lib/utils/scrollToTop.ts +5 -0
  275. package/package.json +11 -6
  276. package/dist/components/Button/buttonPrimaryStyle.d.ts +0 -4
  277. package/dist/components/Button/buttonSecondaryStyle.d.ts +0 -4
  278. package/dist/components/Button/buttonTertiaryStyle.d.ts +0 -4
  279. package/dist/theme/defaultTheme.d.ts +0 -274
  280. package/lib/components/Button/buttonPrimaryStyle.ts +0 -62
  281. package/lib/components/Button/buttonSecondaryStyle.ts +0 -65
  282. package/lib/components/Button/buttonTertiaryStyle.ts +0 -54
@@ -0,0 +1,207 @@
1
+ import { typography, primitiveColour } from '../common/themeCommon';
2
+ import color, { blackAndWhite, displayColours } from './color';
3
+ import originalColour from './originalColourNewStructure';
4
+
5
+ // UCL Theme
6
+
7
+ const baseSizes = {
8
+ s1: '1px',
9
+ s2: '2px',
10
+ s4: '4px',
11
+ s6: '6px',
12
+ s8: '8px',
13
+ s12: '12px',
14
+ s16: '16px',
15
+ s20: '20px',
16
+ s24: '24px',
17
+ s28: '28px',
18
+ s32: '32px',
19
+ s36: '36px',
20
+ s40: '40px',
21
+ s44: '44px',
22
+ s48: '48px',
23
+ s52: '52px',
24
+ s56: '56px',
25
+ s60: '60px',
26
+ s64: '64px',
27
+ s72: '72px',
28
+ s80: '80px',
29
+ };
30
+
31
+ const margin = {
32
+ m0: 0,
33
+ m2: baseSizes.s2,
34
+ m4: baseSizes.s4,
35
+ m6: baseSizes.s6,
36
+ m8: baseSizes.s8,
37
+ m12: baseSizes.s12,
38
+ m16: baseSizes.s16,
39
+ m20: baseSizes.s20,
40
+ m24: baseSizes.s24,
41
+ m32: baseSizes.s32,
42
+ m40: baseSizes.s40,
43
+ m48: baseSizes.s48,
44
+ m56: baseSizes.s56,
45
+ m64: baseSizes.s64,
46
+ m72: baseSizes.s72,
47
+ m80: baseSizes.s80,
48
+ };
49
+
50
+ const padding = {
51
+ p0: 0,
52
+ p2: baseSizes.s2,
53
+ p4: baseSizes.s4,
54
+ p6: baseSizes.s6,
55
+ p8: baseSizes.s8,
56
+ p12: baseSizes.s12,
57
+ p16: baseSizes.s16,
58
+ p20: baseSizes.s20,
59
+ p24: baseSizes.s24,
60
+ p32: baseSizes.s32,
61
+ p40: baseSizes.s40,
62
+ p48: baseSizes.s48,
63
+ p56: baseSizes.s56,
64
+ p64: baseSizes.s64,
65
+ p72: baseSizes.s72,
66
+ p80: baseSizes.s80,
67
+ };
68
+
69
+ const breakpoints = {
70
+ mobile: 320,
71
+ tablet: 672,
72
+ desktop: 1056,
73
+ desktopLarge: 1536,
74
+ };
75
+
76
+ const createMediaQuery = (breakpoint: number) =>
77
+ // Breakpoints apply at the specified width and above
78
+ `@media (min-width: ${breakpoint}px)`;
79
+
80
+ const custom = (breakpoint: number) =>
81
+ // Fallback for edge cases
82
+ createMediaQuery(breakpoint);
83
+
84
+ const mq = {
85
+ mobile: createMediaQuery(breakpoints.mobile),
86
+ tablet: createMediaQuery(breakpoints.tablet),
87
+ desktop: createMediaQuery(breakpoints.desktop),
88
+ desktopLarge: createMediaQuery(breakpoints.desktopLarge),
89
+ custom,
90
+ };
91
+
92
+ const theme = {
93
+ // new
94
+ primitiveColour,
95
+ colour: originalColour,
96
+ typography,
97
+
98
+ // to deprecate
99
+ color,
100
+
101
+ thickness: {
102
+ t1: baseSizes.s1,
103
+ t2: baseSizes.s2,
104
+ },
105
+
106
+ width: {
107
+ h16: baseSizes.s16,
108
+ h20: baseSizes.s20,
109
+ h24: baseSizes.s24,
110
+ },
111
+
112
+ height: {
113
+ h16: baseSizes.s16,
114
+ h20: baseSizes.s20,
115
+ h24: baseSizes.s24,
116
+ h32: baseSizes.s32,
117
+ h36: baseSizes.s36,
118
+ h40: baseSizes.s40,
119
+ h80: baseSizes.s80,
120
+ },
121
+
122
+ margin,
123
+
124
+ padding,
125
+
126
+ radius: {
127
+ r2: baseSizes.s2,
128
+ r4: baseSizes.s4,
129
+ r8: baseSizes.s8,
130
+ r12: baseSizes.s12,
131
+ r16: baseSizes.s16,
132
+ },
133
+
134
+ border: {
135
+ b1: baseSizes.s1,
136
+ b2: baseSizes.s2,
137
+ },
138
+
139
+ outline: {
140
+ o2: baseSizes.s2,
141
+ o4: baseSizes.s4,
142
+ },
143
+
144
+ font: {
145
+ family: {
146
+ primary: 'Helvetica, "Helvetica Neue", Arial, sans-serif',
147
+ secondary:
148
+ 'Garamond, Baskerville, "Baskerville Old Face", "Hoefler Text", "Times New Roman", serif',
149
+ fixed: 'Courier, fixed',
150
+ },
151
+ size: {
152
+ f12: '12px',
153
+ f14: '14px', // Font should be at least 14px in most cases
154
+ f16: '16px', // Prefer 16px to 14px in most cases
155
+ f18: '18px',
156
+ f20: '20px',
157
+ f22: '22px',
158
+ f24: '24px',
159
+ f26: '26px',
160
+ f28: '28px',
161
+ f30: '30px',
162
+ f32: '32px',
163
+ f36: '36px',
164
+ f40: '40px',
165
+ },
166
+ weight: {
167
+ light: 300,
168
+ regular: 400,
169
+ medium: 500,
170
+ semiBold: 600,
171
+ bold: 700,
172
+ extraBold: 800,
173
+ },
174
+ lineHeight: {
175
+ h100: '100%',
176
+ h110: '110%',
177
+ h120: '120%',
178
+ h130: '130%',
179
+ h140: '140%',
180
+ h150: '150%',
181
+ },
182
+ },
183
+
184
+ boxShadow: {
185
+ // offset-x | offset-y | blur-radius | spread-radius | color
186
+ y1: '0 1px 4px 1px rgba(0, 0, 0, 0.1)',
187
+ y2: '0 2px 4px 1px rgba(0, 0, 0, 0.1)',
188
+ x2y4: '2px 4px 8px 4px rgba(0, 0, 0, 0.1)',
189
+ focus: `0px 0px 0px 2px ${color.neutral.white}, 0px 0px 0px 4px ${color.neutral.black}, 0px 0px 0px 6px ${color.system.orange70}`,
190
+ active: `0px 6px 0px 0px ${color.interaction.blue80} inset`,
191
+ destructiveActive: `0px 6px 0px 0px ${color.system.red100} inset`,
192
+ },
193
+
194
+ breakpoints,
195
+ mq,
196
+
197
+ // For ease of use, margin and padding are added at the top level
198
+ // Usage: margin-top: ${theme.m16};
199
+ ...margin,
200
+ ...padding,
201
+ };
202
+
203
+ export type ThemeType = typeof theme;
204
+ export type DisplayColoursType = typeof displayColours;
205
+ export type BlackAndWhiteColoursType = typeof blackAndWhite;
206
+
207
+ export default theme;
@@ -0,0 +1,185 @@
1
+ import { tokens } from 'design-system-foundations-public';
2
+ import tokenToHex from '../../utils/addAlphaToHex';
3
+ import color from './color';
4
+
5
+ const { light: lightThemeTokens } = tokens;
6
+
7
+ // UCL Original Theme Colours - in new format
8
+
9
+ const bg = {
10
+ default: tokenToHex(lightThemeTokens.colour.bg.default.$value),
11
+ brand: tokenToHex(lightThemeTokens.colour.bg.brand.$value),
12
+ inverse: color.interaction.blue70, // tokenToHex(lightThemeTokens.colour.bg.inverse.$value),
13
+ inversePrimary: color.interaction.blue100, // tokenToHex(lightThemeTokens.colour.bg['inverse-primary'].$value),
14
+ };
15
+
16
+ const border = {
17
+ default: tokenToHex(lightThemeTokens.colour.border.default.$value),
18
+ brand: color.interaction.blue70, // tokenToHex(lightThemeTokens.colour.border.brand.$value),
19
+ brandHover: color.interaction.blue80, // tokenToHex(lightThemeTokens.colour.border['brand-hover'].$value),
20
+ brandSubtle: color.base.blue20Alt, // tokenToHex(lightThemeTokens.colour.border['brand-subtle'].$value),
21
+ primary: tokenToHex(lightThemeTokens.colour.border.primary.$value),
22
+ secondary: tokenToHex(lightThemeTokens.colour.border.secondary.$value),
23
+ tertiary: tokenToHex(lightThemeTokens.colour.border.tertiary.$value),
24
+ subtle: tokenToHex(lightThemeTokens.colour.border.subtle.$value),
25
+ disabled: tokenToHex(lightThemeTokens.colour.border.disabled.$value),
26
+ inverse: tokenToHex(lightThemeTokens.colour.border.inverse.$value),
27
+ brandInverse: tokenToHex(
28
+ lightThemeTokens.colour.border['brand-inverse'].$value
29
+ ),
30
+ brandInverseSecondary: color.base.blue40, // tokenToHex(lightThemeTokens.colour.border['brand-inverse-secondary'].$value),
31
+ focus: color.interaction.blue80, // tokenToHex(lightThemeTokens.colour.border.focus.$value),
32
+ success: color.system.green70, // tokenToHex(lightThemeTokens.colour.border.success.$value),
33
+ critical: color.system.red70, // tokenToHex(lightThemeTokens.colour.border.critical.$value),
34
+ warning: color.system.orange70, // tokenToHex(lightThemeTokens.colour.border.warning.$value),
35
+ };
36
+
37
+ const fill = {
38
+ default: tokenToHex(lightThemeTokens.colour.fill.default.$value),
39
+ hover: tokenToHex(lightThemeTokens.colour.fill.hover.$value),
40
+ brand: color.interaction.blue70, // tokenToHex(lightThemeTokens.colour.fill.brand.$value),
41
+ brandHover: color.interaction.blue80, // tokenToHex(lightThemeTokens.colour.fill['brand-hover'].$value),
42
+ brandPressed: color.interaction.blue80, // tokenToHex(lightThemeTokens.colour.fill['brand-pressed'].$value),
43
+ brandSubtleSelected: color.interaction.blue10, // tokenToHex(lightThemeTokens.colour.fill['brand-subtle-selected'].$value),
44
+ brandSubtleHover: color.interaction.blue10, // tokenToHex(lightThemeTokens.colour.fill['brand-subtle-hover'].$value),
45
+ brandPrimary: color.interaction.blue100, // tokenToHex(lightThemeTokens.colour.fill['brand-primary'].$value),
46
+ disabled: tokenToHex(lightThemeTokens.colour.fill.disabled.$value),
47
+ inverse: tokenToHex(lightThemeTokens.colour.fill.inverse.$value),
48
+ brandInverseSecondary: color.base.blue40, // tokenToHex(lightThemeTokens.colour.fill['brand-inverse-secondary'].$value),
49
+ inverseHover: color.base.blue20Alt, // tokenToHex(lightThemeTokens.colour.fill['inverse-hover'].$value),
50
+ critical: color.system.red70, // tokenToHex(lightThemeTokens.colour.fill.critical.$value),
51
+ criticalHover: color.base.red80, // tokenToHex(lightThemeTokens.colour.fill['critical-hover'].$value),
52
+ criticalSelected: color.base.red80, // tokenToHex(lightThemeTokens.colour.fill['critical-selected'].$value),
53
+ criticalPressed: color.base.red90, // tokenToHex(lightThemeTokens.colour.fill['critical-pressed'].$value),
54
+ warning: tokenToHex(lightThemeTokens.colour.fill.warning.$value),
55
+ warningHover: tokenToHex(
56
+ lightThemeTokens.colour.fill['warning-hover'].$value
57
+ ),
58
+ warningSelected: tokenToHex(
59
+ lightThemeTokens.colour.fill['warning-selected'].$value
60
+ ),
61
+ warningPressed: tokenToHex(
62
+ lightThemeTokens.colour.fill['warning-pressed'].$value
63
+ ),
64
+ success: color.system.green70, // tokenToHex(lightThemeTokens.colour.fill.success.$value),
65
+ };
66
+
67
+ const icon = {
68
+ default: tokenToHex(lightThemeTokens.colour.icon.default.$value),
69
+ hover: tokenToHex(lightThemeTokens.colour.icon.hover.$value),
70
+ secondary: tokenToHex(lightThemeTokens.colour.icon.secondary.$value),
71
+ tertiary: tokenToHex(lightThemeTokens.colour.icon.tertiary.$value),
72
+ disabled: tokenToHex(lightThemeTokens.colour.icon.disabled.$value),
73
+ disabledOnBgFill: tokenToHex(
74
+ lightThemeTokens.colour.icon['disabled-on-bg-fill'].$value
75
+ ),
76
+ brand: color.interaction.blue70, // tokenToHex(lightThemeTokens.colour.icon.brand.$value),
77
+ brandHover: color.interaction.blue80, // tokenToHex(lightThemeTokens.colour.icon['brand-hover'].$value),
78
+ brandSelectedOnBgFill: color.interaction.blue80, // tokenToHex(lightThemeTokens.colour.icon['brand-selected-on-bg-fill'].$value),
79
+ visited: color.interaction.blue80, // tokenToHex(lightThemeTokens.colour.icon.visited.$value),
80
+ brandPrimary: color.interaction.blue100, // tokenToHex(lightThemeTokens.colour.icon['brand-primary'].$value),
81
+ brandInverted: tokenToHex(
82
+ lightThemeTokens.colour.icon['brand-inverted'].$value
83
+ ),
84
+ inverse: tokenToHex(lightThemeTokens.colour.icon.inverse.$value),
85
+ inverseHover: tokenToHex(
86
+ lightThemeTokens.colour.icon['inverse-hover'].$value
87
+ ),
88
+ brandInverseSecondary: color.base.blue40, // tokenToHex(lightThemeTokens.colour.icon['brand-inverse-secondary'].$value),
89
+ inverseTertiary: tokenToHex(
90
+ lightThemeTokens.colour.icon['inverse-tertiary'].$value
91
+ ),
92
+ inverseDisabled: tokenToHex(
93
+ lightThemeTokens.colour.icon['inverse-disabled'].$value
94
+ ),
95
+ critical: color.system.red70, // tokenToHex(lightThemeTokens.colour.icon.critical.$value),
96
+ criticalOnBgFill: color.base.red80, // tokenToHex(lightThemeTokens.colour.icon['critical-on-bg-fill'].$value),
97
+ success: color.system.green70, // tokenToHex(lightThemeTokens.colour.icon.success.$value),
98
+ successOnBgFill: tokenToHex(
99
+ lightThemeTokens.colour.icon['success-on-bg-fill'].$value
100
+ ),
101
+ warning: tokenToHex(lightThemeTokens.colour.icon.warning.$value),
102
+ warningOnBgFill: tokenToHex(
103
+ lightThemeTokens.colour.icon['warning-on-bg-fill'].$value
104
+ ),
105
+ };
106
+
107
+ const surface = {
108
+ default: tokenToHex(lightThemeTokens.colour.surface.default.$value),
109
+ primary: tokenToHex(lightThemeTokens.colour.surface.primary.$value),
110
+ secondary: tokenToHex(lightThemeTokens.colour.surface.secondary.$value),
111
+ brand: color.base.blue15, // tokenToHex(lightThemeTokens.colour.surface.brand.$value),
112
+ brandHover: color.interaction.blue10, // tokenToHex(lightThemeTokens.colour.surface['brand-hover'].$value),
113
+ brandSelected: color.interaction.blue10, // tokenToHex(lightThemeTokens.colour.surface['brand-selected'].$value),
114
+ warning: color.system.orange10, // tokenToHex(lightThemeTokens.colour.surface.warning.$value),
115
+ success: color.system.green10, // tokenToHex(lightThemeTokens.colour.surface.success.$value),
116
+ critical: color.system.red10, // tokenToHex(lightThemeTokens.colour.surface.critical.$value),
117
+ hover: tokenToHex(lightThemeTokens.colour.surface.hover.$value),
118
+ selected: tokenToHex(lightThemeTokens.colour.surface.selected.$value),
119
+ disabled: tokenToHex(lightThemeTokens.colour.surface.disabled.$value),
120
+ tertiary: tokenToHex(lightThemeTokens.colour.surface.tertiary.$value),
121
+ inverseBrand: color.interaction.blue70, // tokenToHex(lightThemeTokens.colour.surface['inverse-brand'].$value),
122
+ inverseBrandPrimary: color.interaction.blue100, // tokenToHex(lightThemeTokens.colour.surface['inverse-brand-primary'].$value),
123
+ backdrop: tokenToHex(lightThemeTokens.colour.surface.backdrop.$value),
124
+ };
125
+
126
+ const text = {
127
+ default: tokenToHex(lightThemeTokens.colour.text.default.$value),
128
+ secondary: tokenToHex(lightThemeTokens.colour.text.secondary.$value),
129
+ tertiary: tokenToHex(lightThemeTokens.colour.text.tertiary.$value),
130
+ disabled: tokenToHex(lightThemeTokens.colour.text.disabled.$value),
131
+ inverse: tokenToHex(lightThemeTokens.colour.text.inverse.$value),
132
+ onBgFillDisabled: tokenToHex(
133
+ lightThemeTokens.colour.text['on-bg-fill-disabled'].$value
134
+ ),
135
+ brand: color.interaction.blue70, // tokenToHex(lightThemeTokens.colour.text.brand.$value),
136
+ brandAccent: tokenToHex(lightThemeTokens.colour.text['brand-accent'].$value),
137
+ brandHover: color.interaction.blue80, // tokenToHex(lightThemeTokens.colour.text['brand-hover'].$value),
138
+ brandInverse: tokenToHex(
139
+ lightThemeTokens.colour.text['brand-inverse'].$value
140
+ ),
141
+ brandInverseSecondary: color.base.blue40, // tokenToHex(lightThemeTokens.colour.text['brand-inverse-secondary'].$value),
142
+ brandPrimary: color.interaction.blue100, // tokenToHex(lightThemeTokens.colour.text['brand-primary'].$value),
143
+ critical: color.system.red70, // tokenToHex(lightThemeTokens.colour.text.critical.$value),
144
+ warningOnBgFill: tokenToHex(
145
+ lightThemeTokens.colour.text['warning-on-bg-fill'].$value
146
+ ),
147
+ };
148
+
149
+ const link = {
150
+ default: tokenToHex(lightThemeTokens.colour.link.default.$value),
151
+ brand: color.interaction.blue70, // tokenToHex(lightThemeTokens.colour.link.brand.$value),
152
+ brandHover: color.interaction.blue80, // tokenToHex(lightThemeTokens.colour.link['brand-hover'].$value),
153
+ visited: color.interaction.blue80, // tokenToHex(lightThemeTokens.colour.link.visited.$value),
154
+ primary: color.interaction.blue100, // tokenToHex(lightThemeTokens.colour.link.primary.$value),
155
+ primaryHover: color.interaction.blue80, // tokenToHex(lightThemeTokens.colour.link['primary-hover'].$value),
156
+ disabled: tokenToHex(lightThemeTokens.colour.link.disabled.$value),
157
+ inverse: tokenToHex(lightThemeTokens.colour.link.inverse.$value),
158
+ inverseVisited: color.base.blue15, // tokenToHex(lightThemeTokens.colour.link['inverse-visited'].$value),
159
+ inverseDisabled: tokenToHex(
160
+ lightThemeTokens.colour.link['inverse-disabled'].$value
161
+ ),
162
+ inverseSecondary: color.base.blue40, // tokenToHex(lightThemeTokens.colour.link['inverse-secondary'].$value),
163
+ inverseTertiary: tokenToHex(
164
+ lightThemeTokens.colour.link['inverse-tertiary'].$value
165
+ ),
166
+ };
167
+
168
+ const speciality = {
169
+ inputDefault: tokenToHex(
170
+ lightThemeTokens.colour.speciality['input-default'].$value
171
+ ),
172
+ };
173
+
174
+ const colour = {
175
+ bg,
176
+ border,
177
+ fill,
178
+ icon,
179
+ surface,
180
+ text,
181
+ link,
182
+ speciality,
183
+ };
184
+
185
+ export default colour;
@@ -1,24 +1,81 @@
1
- // We will probably move away from context/provider to store/hook for accessing theme.
1
+ import { createContext, useState, useContext, ReactNode } from 'react';
2
+ import { Global, css } from '@emotion/react';
3
+ import { ThemeType } from './original/defaultTheme';
4
+ import theme from './original/defaultTheme';
5
+ import { uikitFontUrls } from './fonts';
2
6
 
3
- import {
4
- createContext,
5
- useState,
6
- useContext,
7
- ReactNode,
8
- } from 'react';
7
+ const useThemeState = (initialTheme: ThemeType = theme as ThemeType) =>
8
+ useState(initialTheme);
9
9
 
10
- import theme, { ThemeType } from './defaultTheme';
11
-
12
- const useThemeState = () => useState(theme as ThemeType);
10
+ const ThemeContext = createContext<ReturnType<typeof useThemeState> | null>(
11
+ null
12
+ );
13
13
 
14
- const ThemeContext = createContext<ReturnType<
15
- typeof useThemeState
16
- > | null>(null);
14
+ const fontFaces = css`
15
+ @font-face {
16
+ font-family: 'DM Sans';
17
+ src: url(${uikitFontUrls.dmSansNormal}) format('woff2');
18
+ font-weight: 100 1000;
19
+ font-style: normal;
20
+ font-display: swap;
21
+ }
22
+ @font-face {
23
+ font-family: 'DM Sans';
24
+ src: url(${uikitFontUrls.dmSansItalic}) format('woff2');
25
+ font-weight: 100 1000;
26
+ font-style: italic;
27
+ font-display: swap;
28
+ }
29
+ @font-face {
30
+ font-family: 'DM Mono';
31
+ src: url(${uikitFontUrls.dmMonoItalic}) format('woff2');
32
+ font-weight: 400;
33
+ font-style: italic;
34
+ font-display: swap;
35
+ }
36
+ @font-face {
37
+ font-family: 'DM Mono';
38
+ src: url(${uikitFontUrls.dmMonoLight}) format('woff2');
39
+ font-weight: 300;
40
+ font-style: normal;
41
+ font-display: swap;
42
+ }
43
+ @font-face {
44
+ font-family: 'DM Mono';
45
+ src: url(${uikitFontUrls.dmMonoLightItalic}) format('woff2');
46
+ font-weight: 300;
47
+ font-style: italic;
48
+ font-display: swap;
49
+ }
50
+ @font-face {
51
+ font-family: 'DM Mono';
52
+ src: url(${uikitFontUrls.dmMonoMedium}) format('woff2');
53
+ font-weight: 500;
54
+ font-style: normal;
55
+ font-display: swap;
56
+ }
57
+ @font-face {
58
+ font-family: 'DM Mono';
59
+ src: url(${uikitFontUrls.dmMonoMediumItalic}) format('woff2');
60
+ font-weight: 500;
61
+ font-style: italic;
62
+ font-display: swap;
63
+ }
64
+ @font-face {
65
+ font-family: 'DM Mono';
66
+ src: url(${uikitFontUrls.dmMonoRegular}) format('woff2');
67
+ font-weight: 400;
68
+ font-style: normal;
69
+ font-display: swap;
70
+ }
71
+ `;
17
72
 
18
73
  export const ThemeContextProvider: React.FC<{
19
74
  children: ReactNode;
20
- }> = ({ children }) => (
21
- <ThemeContext.Provider value={useThemeState()}>
75
+ initialTheme?: ThemeType;
76
+ }> = ({ children, initialTheme }) => (
77
+ <ThemeContext.Provider value={useThemeState(initialTheme)}>
78
+ <Global styles={fontFaces} />
22
79
  {children}
23
80
  </ThemeContext.Provider>
24
81
  );
@@ -0,0 +1,10 @@
1
+ // lib/types/assets.d.ts
2
+ declare module '*.woff2?url' {
3
+ const src: string;
4
+ export default src;
5
+ }
6
+
7
+ declare module '*.woff2' {
8
+ const src: string;
9
+ export default src;
10
+ }
@@ -0,0 +1,29 @@
1
+ const tokenToHex = (token: { hex: string; alpha?: number }) => {
2
+
3
+ const { hex, alpha } = token;
4
+
5
+ const effectiveAlpha = alpha ?? 1;
6
+
7
+ if (isNaN(effectiveAlpha) || effectiveAlpha === 1) {
8
+ return hex;
9
+ }
10
+
11
+ const clean = hex.replace('#', '');
12
+
13
+ // Convert #RGB to #RRGGBB
14
+ const normalized =
15
+ clean.length === 3
16
+ ? clean.split('').map((c) => c + c).join('')
17
+ : clean.slice(0, 6);
18
+
19
+ if (!effectiveAlpha || effectiveAlpha === 1) return `#${normalized}`;
20
+
21
+ const alphaHex = Math.round(effectiveAlpha * 255)
22
+ .toString(16)
23
+ .padStart(2, '0')
24
+ .toUpperCase();
25
+
26
+ return `#${normalized}${alphaHex}`;
27
+ };
28
+
29
+ export default tokenToHex;
@@ -0,0 +1,5 @@
1
+ const scrollToTop = () => {
2
+ window?.scrollTo({ top: 0, behavior: 'smooth' });
3
+ };
4
+
5
+ export default scrollToTop;
package/package.json CHANGED
@@ -2,7 +2,7 @@
2
2
  "name": "uikit-react-public",
3
3
  "private": false,
4
4
  "license": "UNLICENSED",
5
- "version": "0.17.4",
5
+ "version": "0.21.9",
6
6
  "type": "module",
7
7
  "main": "dist/index.js",
8
8
  "types": "dist/index.d.ts",
@@ -10,6 +10,9 @@
10
10
  "dist",
11
11
  "lib"
12
12
  ],
13
+ "publishConfig": {
14
+ "access": "public"
15
+ },
13
16
  "scripts": {
14
17
  "dev": "vite",
15
18
  "dev_expose": "vite --host",
@@ -25,9 +28,7 @@
25
28
  "coverage": "vitest run --coverage",
26
29
  "report": "vite ./coverage",
27
30
  "preview": "vite preview",
28
- "prepublishOnly": "npm run build",
29
- "prepare": "husky",
30
- "storybook": "storybook dev -p 6006",
31
+ "storybook": "storybook dev -p 6006 --disable-telemetry",
31
32
  "build-storybook": "storybook build",
32
33
  "predeploy": "npm run build-storybook",
33
34
  "deploy": "gh-pages -d storybook-static"
@@ -39,7 +40,9 @@
39
40
  },
40
41
  "dependencies": {
41
42
  "@emotion/css": "^11.13.5",
42
- "@floating-ui/react-dom": "^2.1.2"
43
+ "@emotion/react": "^11.14.0",
44
+ "@floating-ui/react-dom": "^2.1.2",
45
+ "design-system-foundations-public": "0.0.37"
43
46
  },
44
47
  "peerDependencies": {
45
48
  "react": "^19.0.0",
@@ -63,7 +66,8 @@
63
66
  "@testing-library/react": "^16.2.0",
64
67
  "@testing-library/user-event": "^14.6.1",
65
68
  "@types/node": "^22.13.10",
66
- "@types/react-dom": "^19.1.2",
69
+ "@types/react": "^19.2.14",
70
+ "@types/react-dom": "^19.2.3",
67
71
  "@typescript-eslint/eslint-plugin": "^8.26.1",
68
72
  "@typescript-eslint/parser": "^8.26.1",
69
73
  "@vitejs/plugin-basic-ssl": "^2.0.0",
@@ -86,6 +90,7 @@
86
90
  "prettier": "^3.5.3",
87
91
  "react": "^19.1.0",
88
92
  "react-dom": "^19.1.0",
93
+ "react-router": "^7.13.1",
89
94
  "storybook": "^8.6.4",
90
95
  "typescript": "^5.8.2",
91
96
  "typescript-eslint": "^8.26.1",
@@ -1,4 +0,0 @@
1
- import { ThemeType } from '../../theme';
2
- import { ButtonBaseProps } from './Button';
3
- declare const buttonPrimaryStyle: (theme: ThemeType, destructive: ButtonBaseProps["destructive"], disabled: ButtonBaseProps["disabled"], loading: ButtonBaseProps["loading"]) => string;
4
- export default buttonPrimaryStyle;
@@ -1,4 +0,0 @@
1
- import { ThemeType } from '../../theme';
2
- import { ButtonBaseProps } from './Button';
3
- declare const buttonSecondaryStyle: (theme: ThemeType, destructive: ButtonBaseProps["destructive"], disabled: ButtonBaseProps["disabled"], loading: ButtonBaseProps["loading"]) => string;
4
- export default buttonSecondaryStyle;
@@ -1,4 +0,0 @@
1
- import { ThemeType } from '../../theme';
2
- import { ButtonBaseProps } from './Button';
3
- declare const buttonTertiaryStyle: (theme: ThemeType, disabled: ButtonBaseProps["disabled"], loading: ButtonBaseProps["loading"]) => string;
4
- export default buttonTertiaryStyle;