@payfit/unity-components 1.0.0 → 1.1.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 (254) hide show
  1. package/dist/esm/components/action-bar/ActionBar.d.ts +153 -0
  2. package/dist/esm/components/action-bar/ActionBar.js +173 -0
  3. package/dist/esm/components/action-bar/parts/ActionBarAction.d.ts +44 -0
  4. package/dist/esm/components/action-bar/parts/ActionBarAction.js +45 -0
  5. package/dist/esm/components/action-bar/parts/ActionBarRoot.d.ts +44 -0
  6. package/dist/esm/components/action-bar/parts/ActionBarRoot.js +46 -0
  7. package/dist/esm/components/actionable/Actionable.js +20 -21
  8. package/dist/esm/components/alert/Alert.d.ts +1 -1
  9. package/dist/esm/components/alert/Alert.js +1 -1
  10. package/dist/esm/components/alert/parts/AlertActions.d.ts +1 -1
  11. package/dist/esm/components/alert/parts/AlertActions.js +1 -1
  12. package/dist/esm/components/alert/parts/AlertContent.d.ts +1 -1
  13. package/dist/esm/components/alert/parts/AlertTitle.d.ts +1 -1
  14. package/dist/esm/components/anchor/Anchor.js +1 -1
  15. package/dist/esm/components/app-layout/AppLayout.js +6 -6
  16. package/dist/esm/components/app-menu/parts/AppMenuFooter.js +30 -30
  17. package/dist/esm/components/app-menu/parts/AppMenuNavContent.js +1 -1
  18. package/dist/esm/components/autocomplete/Autocomplete.d.ts +1 -1
  19. package/dist/esm/components/autocomplete/Autocomplete.js +14 -14
  20. package/dist/esm/components/autocomplete/parts/AutocompleteClearButton.js +5 -5
  21. package/dist/esm/components/autocomplete/parts/AutocompleteItem.d.ts +1 -1
  22. package/dist/esm/components/autocomplete/parts/AutocompleteItem.js +4 -4
  23. package/dist/esm/components/autocomplete/parts/AutocompleteItemGroup.d.ts +1 -1
  24. package/dist/esm/components/autocomplete/parts/AutocompleteItemGroup.js +12 -12
  25. package/dist/esm/components/autocomplete/parts/AutocompletePanel.d.ts +1 -1
  26. package/dist/esm/components/autocomplete/parts/AutocompletePanel.js +7 -7
  27. package/dist/esm/components/avatar/Avatar.d.ts +1 -1
  28. package/dist/esm/components/avatar/Avatar.js +15 -16
  29. package/dist/esm/components/avatar/Avatar.variants.js +1 -1
  30. package/dist/esm/components/avatar/parts/AvatarFallback.d.ts +1 -1
  31. package/dist/esm/components/avatar/parts/AvatarFallback.js +9 -10
  32. package/dist/esm/components/avatar/parts/AvatarImage.js +12 -12
  33. package/dist/esm/components/avatar/parts/AvatarPair.d.ts +1 -1
  34. package/dist/esm/components/avatar/parts/AvatarPair.js +4 -4
  35. package/dist/esm/components/badge/Badge.d.ts +1 -1
  36. package/dist/esm/components/badge/Badge.js +31 -35
  37. package/dist/esm/components/bottom-sheet/BottomSheet.d.ts +1 -1
  38. package/dist/esm/components/bottom-sheet/BottomSheet.js +14 -14
  39. package/dist/esm/components/bottom-sheet/parts/BottomSheetContent.d.ts +1 -1
  40. package/dist/esm/components/bottom-sheet/parts/BottomSheetContent.js +4 -4
  41. package/dist/esm/components/bottom-sheet/parts/BottomSheetDragIndicator.js +11 -11
  42. package/dist/esm/components/bottom-sheet/parts/BottomSheetFooter.d.ts +1 -1
  43. package/dist/esm/components/bottom-sheet/parts/BottomSheetFooter.js +4 -4
  44. package/dist/esm/components/bottom-sheet/parts/BottomSheetHeader.d.ts +4 -4
  45. package/dist/esm/components/bottom-sheet/parts/BottomSheetHeader.js +6 -6
  46. package/dist/esm/components/breadcrumbs/Breadcrumbs.context.d.ts +1 -1
  47. package/dist/esm/components/breadcrumbs/Breadcrumbs.d.ts +1 -1
  48. package/dist/esm/components/breadcrumbs/Breadcrumbs.variant.js +3 -3
  49. package/dist/esm/components/button/Button.js +33 -41
  50. package/dist/esm/components/button/Button.variants.d.ts +1 -1
  51. package/dist/esm/components/button/Button.variants.js +1 -1
  52. package/dist/esm/components/checkbox/Checkbox.js +53 -49
  53. package/dist/esm/components/checkbox/Checkbox.variants.js +1 -1
  54. package/dist/esm/components/checkbox/parts/CheckboxIndicator.js +1 -1
  55. package/dist/esm/components/checkbox-field/CheckboxField.js +39 -34
  56. package/dist/esm/components/checkbox-group/CheckboxGroup.d.ts +1 -1
  57. package/dist/esm/components/checkbox-group/CheckboxGroup.js +12 -12
  58. package/dist/esm/components/collapsible/Collapsible.js +22 -16
  59. package/dist/esm/components/collapsible/parts/CollapsibleContent.js +16 -7
  60. package/dist/esm/components/collapsible/parts/CollapsibleTitle.js +23 -23
  61. package/dist/esm/components/data-table/DataTable.d.ts +48 -17
  62. package/dist/esm/components/data-table/DataTable.js +104 -60
  63. package/dist/esm/components/data-table/mocks/employee-columns.d.ts +4 -0
  64. package/dist/esm/components/data-table/parts/DataTableBulkActions.d.ts +55 -0
  65. package/dist/esm/components/data-table/parts/DataTableBulkActions.js +65 -0
  66. package/dist/esm/components/data-table/parts/DataTableRoot.d.ts +37 -0
  67. package/dist/esm/components/data-table/parts/DataTableRoot.js +13 -0
  68. package/dist/esm/components/date-calendar/DateCalendar.js +8 -8
  69. package/dist/esm/components/date-picker/DatePicker.js +9 -9
  70. package/dist/esm/components/date-picker/parts/DateInput.js +7 -7
  71. package/dist/esm/components/date-picker-field/DatePickerField.js +12 -12
  72. package/dist/esm/components/definition-tooltip/DefinitionTooltip.js +4 -4
  73. package/dist/esm/components/dialog/Dialog.d.ts +1 -1
  74. package/dist/esm/components/dialog/Dialog.js +9 -9
  75. package/dist/esm/components/dialog/parts/DialogActions/DialogButton.d.ts +1 -1
  76. package/dist/esm/components/fieldset/Fieldset.d.ts +1 -1
  77. package/dist/esm/components/fieldset/Fieldset.js +4 -4
  78. package/dist/esm/components/flex/Flex.d.ts +1 -1
  79. package/dist/esm/components/flex/Flex.variants.js +189 -207
  80. package/dist/esm/components/flex/FlexItem.d.ts +1 -1
  81. package/dist/esm/components/form/Form.context.d.ts +1 -4
  82. package/dist/esm/components/form/Form.context.js +11 -13
  83. package/dist/esm/components/form/Form.d.ts +13 -11
  84. package/dist/esm/components/form/Form.js +45 -48
  85. package/dist/esm/components/form-field/FormField.context.d.ts +1 -6
  86. package/dist/esm/components/form-field/FormField.context.js +39 -47
  87. package/dist/esm/components/form-field/FormField.d.ts +0 -2
  88. package/dist/esm/components/form-field/FormField.js +37 -42
  89. package/dist/esm/components/form-field/parts/FormContextualLink.js +17 -17
  90. package/dist/esm/components/form-field/parts/FormControl.js +39 -35
  91. package/dist/esm/components/form-field/parts/FormFeedbackText.js +15 -17
  92. package/dist/esm/components/full-page-loader/FullPageLoader.js +7 -7
  93. package/dist/esm/components/funnel-layout/FunnelLayout.d.ts +2 -2
  94. package/dist/esm/components/funnel-layout/FunnelLayout.js +26 -26
  95. package/dist/esm/components/funnel-layout/parts/FunnelBody.d.ts +2 -2
  96. package/dist/esm/components/funnel-layout/parts/FunnelBody.js +4 -4
  97. package/dist/esm/components/funnel-layout/parts/FunnelPage.d.ts +2 -2
  98. package/dist/esm/components/funnel-layout/parts/FunnelPage.js +10 -10
  99. package/dist/esm/components/funnel-layout/parts/FunnelPageAction.d.ts +1 -1
  100. package/dist/esm/components/funnel-layout/parts/FunnelPageActions.d.ts +2 -2
  101. package/dist/esm/components/funnel-layout/parts/FunnelPageActions.js +13 -13
  102. package/dist/esm/components/funnel-layout/parts/FunnelPageContent.d.ts +2 -2
  103. package/dist/esm/components/funnel-layout/parts/FunnelPageContent.js +1 -1
  104. package/dist/esm/components/funnel-layout/parts/FunnelPageFooter.d.ts +2 -2
  105. package/dist/esm/components/funnel-layout/parts/FunnelPageFooter.js +7 -7
  106. package/dist/esm/components/funnel-layout/parts/FunnelPageHeader.d.ts +2 -2
  107. package/dist/esm/components/funnel-layout/parts/FunnelPageHeader.js +4 -4
  108. package/dist/esm/components/funnel-layout/parts/FunnelProgressBar.d.ts +1 -1
  109. package/dist/esm/components/funnel-layout/parts/FunnelProgressBar.js +4 -4
  110. package/dist/esm/components/funnel-layout/parts/FunnelSidebar.d.ts +2 -2
  111. package/dist/esm/components/funnel-layout/parts/FunnelSidebar.js +7 -7
  112. package/dist/esm/components/funnel-layout/parts/FunnelTopBar.d.ts +2 -2
  113. package/dist/esm/components/funnel-layout/parts/FunnelTopBar.js +9 -9
  114. package/dist/esm/components/grid/Grid.d.ts +1 -1
  115. package/dist/esm/components/grid/Grid.variants.d.ts +1 -1
  116. package/dist/esm/components/grid/Grid.variants.js +3 -3
  117. package/dist/esm/components/grid/GridItem.d.ts +1 -1
  118. package/dist/esm/components/icon/Icon.d.ts +1 -1
  119. package/dist/esm/components/icon/Icon.js +1 -1
  120. package/dist/esm/components/icon-button/CircularIconButton.d.ts +1 -1
  121. package/dist/esm/components/icon-button/CircularIconButton.js +21 -20
  122. package/dist/esm/components/icon-button/IconButton.variants.d.ts +1 -1
  123. package/dist/esm/components/icon-button/IconButton.variants.js +2 -2
  124. package/dist/esm/components/input/Input.js +6 -6
  125. package/dist/esm/components/label/Label.js +13 -13
  126. package/dist/esm/components/link/Link.d.ts +11 -1
  127. package/dist/esm/components/link/Link.js +32 -30
  128. package/dist/esm/components/link/Link.variants.d.ts +141 -30
  129. package/dist/esm/components/link/Link.variants.js +44 -16
  130. package/dist/esm/components/menu/parts/MenuItem.js +8 -8
  131. package/dist/esm/components/multi-select/parts/MultiSelectButton.js +14 -14
  132. package/dist/esm/components/multi-select/parts/MultiSelectOptGroup.js +5 -5
  133. package/dist/esm/components/multi-select/parts/MultiSelectOption.js +3 -3
  134. package/dist/esm/components/multi-select/parts/MultiSelectPopover.js +1 -1
  135. package/dist/esm/components/multi-select-field/MultiSelectField.js +6 -6
  136. package/dist/esm/components/nav/parts/NavGroup.js +28 -29
  137. package/dist/esm/components/nav/parts/NavItem.d.ts +1 -1
  138. package/dist/esm/components/nav/parts/NavItem.js +13 -14
  139. package/dist/esm/components/number-field/NumberField.js +14 -14
  140. package/dist/esm/components/number-input/NumberInput.d.ts +2 -2
  141. package/dist/esm/components/number-input/NumberInput.js +37 -37
  142. package/dist/esm/components/page/Page.d.ts +1 -1
  143. package/dist/esm/components/page/Page.js +5 -5
  144. package/dist/esm/components/page/parts/PageHeader.d.ts +1 -1
  145. package/dist/esm/components/page/parts/PageHeader.js +4 -4
  146. package/dist/esm/components/pagination/Pagination.d.ts +1 -1
  147. package/dist/esm/components/pagination/Pagination.js +16 -16
  148. package/dist/esm/components/pagination/parts/PaginationEllipsis.d.ts +1 -1
  149. package/dist/esm/components/pagination/parts/PaginationEllipsis.js +8 -8
  150. package/dist/esm/components/pagination/parts/PaginationJumpDialog.js +9 -9
  151. package/dist/esm/components/pagination/parts/PaginationLink.d.ts +1 -1
  152. package/dist/esm/components/pagination/parts/PaginationLink.js +6 -6
  153. package/dist/esm/components/payfit-brand/PayFitBrand.js +4 -4
  154. package/dist/esm/components/pill/Pill.d.ts +1 -1
  155. package/dist/esm/components/pill/Pill.js +1 -1
  156. package/dist/esm/components/popover/Popover.js +5 -5
  157. package/dist/esm/components/popover/parts/PopoverHeader.js +7 -7
  158. package/dist/esm/components/progress-bar/ProgressBar.js +11 -11
  159. package/dist/esm/components/radio-button-group/parts/RadioButton.d.ts +1 -1
  160. package/dist/esm/components/radio-button-group/parts/RadioButton.js +5 -5
  161. package/dist/esm/components/search/Search.d.ts +1 -1
  162. package/dist/esm/components/search/Search.js +14 -14
  163. package/dist/esm/components/segmented-button-group/parts/ToggleButton.js +10 -10
  164. package/dist/esm/components/select/Select.js +12 -12
  165. package/dist/esm/components/select/parts/SearchInput.js +7 -7
  166. package/dist/esm/components/select/parts/SelectButton.js +17 -14
  167. package/dist/esm/components/select/parts/SelectOption.js +4 -4
  168. package/dist/esm/components/select/parts/SelectOptionGroup.js +8 -8
  169. package/dist/esm/components/select/parts/SelectOptionHelper.js +1 -1
  170. package/dist/esm/components/select-field/SelectField.d.ts +1 -1
  171. package/dist/esm/components/select-field/SelectField.js +16 -16
  172. package/dist/esm/components/selectable-button-group/SelectableButtonGroup.d.ts +1 -1
  173. package/dist/esm/components/selectable-button-group/SelectableButtonGroup.js +8 -8
  174. package/dist/esm/components/selectable-button-group/parts/SelectableButton.js +10 -10
  175. package/dist/esm/components/selectable-card/internals/Content.js +5 -5
  176. package/dist/esm/components/selectable-card/internals/Description.js +1 -1
  177. package/dist/esm/components/selectable-card/internals/Illustration.js +3 -3
  178. package/dist/esm/components/selectable-card/internals/SelectedIndicator.js +4 -4
  179. package/dist/esm/components/selectable-card/selectable-card-checkbox-group/parts/SelectableCardCheckbox.d.ts +1 -1
  180. package/dist/esm/components/selectable-card/selectable-card-radio-group/parts/RadioIndicator.js +3 -3
  181. package/dist/esm/components/selectable-card/selectable-card-radio-group/parts/SelectableCardRadio.d.ts +1 -1
  182. package/dist/esm/components/selectable-card/selectableCard.variant.js +1 -1
  183. package/dist/esm/components/selectable-card-radio-group-field/SelectableCardRadioGroupField.js +22 -22
  184. package/dist/esm/components/side-panel/SidePanel.d.ts +1 -1
  185. package/dist/esm/components/side-panel/SidePanel.js +6 -6
  186. package/dist/esm/components/side-panel/parts/SidePanelContent.d.ts +1 -1
  187. package/dist/esm/components/side-panel/parts/SidePanelContent.js +9 -9
  188. package/dist/esm/components/side-panel/parts/SidePanelDragIndicator.js +11 -11
  189. package/dist/esm/components/side-panel/parts/SidePanelFooter.d.ts +1 -1
  190. package/dist/esm/components/side-panel/parts/SidePanelFooter.js +4 -4
  191. package/dist/esm/components/side-panel/parts/SidePanelHeader.d.ts +4 -4
  192. package/dist/esm/components/side-panel/parts/SidePanelHeader.js +6 -6
  193. package/dist/esm/components/skip-links/SkipLinks.d.ts +79 -0
  194. package/dist/esm/components/skip-links/SkipLinks.js +80 -0
  195. package/dist/esm/components/spinner/Spinner.js +5 -5
  196. package/dist/esm/components/table/Table.js +101 -100
  197. package/dist/esm/components/table/hooks/useTableKeyboardNavigation.d.ts +1 -19
  198. package/dist/esm/components/table/hooks/useTableKeyboardNavigation.js +147 -95
  199. package/dist/esm/components/table/parts/TableBody.js +1 -1
  200. package/dist/esm/components/table/parts/TableCell.d.ts +17 -1
  201. package/dist/esm/components/table/parts/TableCell.js +45 -41
  202. package/dist/esm/components/table/parts/TableColumnHeader.d.ts +2 -1
  203. package/dist/esm/components/table/parts/TableColumnHeader.js +63 -57
  204. package/dist/esm/components/table/parts/TableEmptyState.d.ts +1 -1
  205. package/dist/esm/components/table/parts/TableEmptyState.js +1 -1
  206. package/dist/esm/components/table/parts/TableHeader.d.ts +3 -3
  207. package/dist/esm/components/table/parts/TableHeader.js +28 -26
  208. package/dist/esm/components/table/parts/TablePagination.d.ts +1 -1
  209. package/dist/esm/components/table/parts/TablePagination.js +9 -9
  210. package/dist/esm/components/table/parts/TableRow.d.ts +1 -1
  211. package/dist/esm/components/table/parts/TableRow.js +36 -34
  212. package/dist/esm/components/tabs/Tabs.context.d.ts +1 -1
  213. package/dist/esm/components/tabs/Tabs.d.ts +1 -1
  214. package/dist/esm/components/tabs/Tabs.variant.js +1 -1
  215. package/dist/esm/components/tabs/parts/NavigationButton.js +12 -12
  216. package/dist/esm/components/tabs/parts/Tab.d.ts +3 -2
  217. package/dist/esm/components/tabs/parts/Tab.js +12 -12
  218. package/dist/esm/components/tabs/parts/TabPanel.d.ts +4 -2
  219. package/dist/esm/components/tabs/parts/TabPanel.js +7 -7
  220. package/dist/esm/components/task-menu/TaskMenu.d.ts +1 -1
  221. package/dist/esm/components/task-menu/TaskMenu.js +7 -7
  222. package/dist/esm/components/task-menu/parts/Content.js +6 -6
  223. package/dist/esm/components/task-menu/parts/Header.js +7 -7
  224. package/dist/esm/components/task-menu/parts/SubTask.js +6 -6
  225. package/dist/esm/components/task-menu/parts/Task.d.ts +1 -1
  226. package/dist/esm/components/task-menu/parts/Task.js +12 -12
  227. package/dist/esm/components/task-menu/parts/TaskGroup.js +7 -7
  228. package/dist/esm/components/task-menu/parts/task.variants.js +1 -1
  229. package/dist/esm/components/text/Text.d.ts +1 -1
  230. package/dist/esm/components/text/Text.variants.js +1 -1
  231. package/dist/esm/components/text-area/TextArea.js +6 -6
  232. package/dist/esm/components/text-field/TextField.js +5 -5
  233. package/dist/esm/components/toast/UnityToast.d.ts +1 -1
  234. package/dist/esm/components/toast/UnityToast.js +11 -11
  235. package/dist/esm/components/toggle-switch/ToggleSwitch.d.ts +1 -1
  236. package/dist/esm/components/toggle-switch/ToggleSwitch.js +4 -4
  237. package/dist/esm/components/toggle-switch-field/ToggleSwitchField.js +35 -31
  238. package/dist/esm/components/toggle-switch-group/ToggleSwitchGroup.d.ts +1 -1
  239. package/dist/esm/components/toggle-switch-group/ToggleSwitchGroup.js +5 -5
  240. package/dist/esm/components/toggle-switch-group-field/ToggleSwitchGroupField.js +43 -38
  241. package/dist/esm/components/tooltip/Tooltip.d.ts +2 -0
  242. package/dist/esm/components/tooltip/Tooltip.js +27 -19
  243. package/dist/esm/hooks/use-form.js +7 -7
  244. package/dist/esm/index.d.ts +6 -1
  245. package/dist/esm/index.js +366 -352
  246. package/dist/esm/integrations/react-router/v5/UnityReactRouterV5Provider.js +28 -0
  247. package/dist/esm/integrations/react-router/v5/index.d.ts +1 -0
  248. package/dist/esm/integrations/react-router/v5.js +4 -0
  249. package/i18n/en-GB.json +6 -0
  250. package/i18n/es-ES.json +6 -0
  251. package/i18n/fr-FR.json +6 -0
  252. package/package.json +38 -35
  253. package/dist/esm/providers/router/integrations/UnityReactRouterV5Provider.js +0 -28
  254. /package/dist/esm/{providers/router/integrations → integrations/react-router/v5}/UnityReactRouterV5Provider.d.ts +0 -0
@@ -1,10 +1,10 @@
1
1
  import { jsxs as r, jsx as n } from "react/jsx-runtime";
2
2
  import { forwardRef as u } from "react";
3
- import { mergeProps as b } from "react-aria";
4
- import { useSlottedContext as f, InputContext as g, Label as N } from "react-aria-components";
5
- import { useIntl as h } from "react-intl";
6
- import { tv as q } from "tailwind-variants";
7
- const x = q({
3
+ import { uyTv as b } from "@payfit/unity-themes";
4
+ import { mergeProps as f } from "react-aria";
5
+ import { useSlottedContext as g, InputContext as N, Label as h } from "react-aria-components";
6
+ import { useIntl as q } from "react-intl";
7
+ const x = b({
8
8
  slots: {
9
9
  base: "uy:typography-body-strong uy:text-content-form-enabled uy:flex uy:gap-25",
10
10
  asterisk: "uy:text-content-danger",
@@ -25,31 +25,31 @@ const x = q({
25
25
  }
26
26
  }), v = u(
27
27
  ({ children: l, ...a }, i) => {
28
- const t = h(), e = f(g), d = b(
28
+ const s = q(), e = g(N), d = f(
29
29
  { isRequired: e == null ? void 0 : e["aria-required"] },
30
30
  a
31
31
  ), {
32
- isRequired: s = !1,
32
+ isRequired: t = !1,
33
33
  requiredVariant: o = "required",
34
34
  ...p
35
- } = d, { base: m, asterisk: y, optionalTag: c } = x();
35
+ } = d, { base: y, asterisk: m, optionalTag: c } = x();
36
36
  return /* @__PURE__ */ r(
37
- N,
37
+ h,
38
38
  {
39
39
  "data-dd-privacy": "allow",
40
40
  ...p,
41
41
  ref: i,
42
- className: m({ className: a.className }),
42
+ className: y({ className: a.className }),
43
43
  children: [
44
44
  l,
45
- o === "required" && s && /* @__PURE__ */ r("span", { className: y(), children: [
45
+ o === "required" && t && /* @__PURE__ */ r("span", { className: m(), children: [
46
46
  "*",
47
- /* @__PURE__ */ n("span", { className: "uy:sr-only", children: t.formatMessage({
47
+ /* @__PURE__ */ n("span", { className: "uy:sr-only", children: s.formatMessage({
48
48
  id: "unity:component:label:required",
49
49
  defaultMessage: "required"
50
50
  }) })
51
51
  ] }),
52
- o === "optional" && !s && /* @__PURE__ */ n("span", { className: c({ className: a.className }), children: t.formatMessage({
52
+ o === "optional" && !t && /* @__PURE__ */ n("span", { className: c({ className: a.className }), children: s.formatMessage({
53
53
  id: "unity:component:label:optional",
54
54
  defaultMessage: "(optional)"
55
55
  }) })
@@ -1,7 +1,7 @@
1
+ import { VariantProps } from '@payfit/unity-themes';
1
2
  import { HTMLAttributes } from 'react';
2
3
  import { LinkProps as AriaLinkProps } from 'react-aria-components';
3
4
  import { NavLinkProps as NavRouterLinkProps } from 'react-router-dom';
4
- import { VariantProps } from 'tailwind-variants';
5
5
  import { link } from './Link.variants.js';
6
6
  export type LinkProps = Omit<AriaLinkProps, 'style' | 'className'> & {
7
7
  /**
@@ -12,6 +12,11 @@ export type LinkProps = Omit<AriaLinkProps, 'style' | 'className'> & {
12
12
  * The link id
13
13
  */
14
14
  id?: HTMLAttributes<HTMLLinkElement>['id'];
15
+ /**
16
+ * The link's size.
17
+ * @default 'inherit'
18
+ */
19
+ size?: VariantProps<typeof link>['size'];
15
20
  /**
16
21
  * The link's display variant. Links can be inline with text or standalone (block).
17
22
  * @default 'inline'
@@ -51,6 +56,11 @@ declare const Link: import('react').ForwardRefExoticComponent<Omit<AriaLinkProps
51
56
  * The link id
52
57
  */
53
58
  id?: HTMLAttributes<HTMLLinkElement>["id"];
59
+ /**
60
+ * The link's size.
61
+ * @default 'inherit'
62
+ */
63
+ size?: VariantProps<typeof link>["size"];
54
64
  /**
55
65
  * The link's display variant. Links can be inline with text or standalone (block).
56
66
  * @default 'inline'
@@ -1,58 +1,60 @@
1
- import { jsxs as k, jsx as y } from "react/jsx-runtime";
2
- import { forwardRef as v } from "react";
3
- import { IconSprite as g } from "@payfit/unity-icons";
4
- import { Link as w } from "react-aria-components";
5
- import { useRouter as x } from "../../providers/router/RouterProvider.js";
6
- import { link as L } from "./Link.variants.js";
7
- import { isExternalUrl as A } from "./utils.js";
8
- const E = v(
1
+ import { jsxs as g, jsx as w } from "react/jsx-runtime";
2
+ import { forwardRef as x } from "react";
3
+ import { IconSprite as y } from "@payfit/unity-icons";
4
+ import { Link as L } from "react-aria-components";
5
+ import { useRouter as A } from "../../providers/router/RouterProvider.js";
6
+ import { link as E } from "./Link.variants.js";
7
+ import { isExternalUrl as N } from "./utils.js";
8
+ const S = x(
9
9
  ({
10
10
  href: o,
11
- children: a,
11
+ children: l,
12
12
  variant: s = "inline",
13
13
  color: c = "primary",
14
14
  isDisabled: n = !1,
15
15
  isExact: m = !1,
16
16
  isCurrent: p = void 0,
17
17
  isExternal: d,
18
- maxCharactersTruncation: t,
18
+ maxCharactersTruncation: i,
19
+ size: u = "inherit",
19
20
  ...r
20
- }, u) => {
21
- const l = x(), e = d ?? A(o), i = !e && l ? l.isActive(o.toString(), m) : p, f = L({
21
+ }, f) => {
22
+ const a = A(), e = d ?? N(o), t = !e && a ? a.isActive(o.toString(), m) : p, { base: k, icon: v } = E({
22
23
  variant: s,
23
24
  color: c,
24
25
  isDisabled: n,
25
- isTruncated: !!t
26
+ size: u,
27
+ isTruncated: !!i
26
28
  });
27
- return /* @__PURE__ */ k(
28
- w,
29
+ return /* @__PURE__ */ g(
30
+ L,
29
31
  {
30
32
  "data-dd-privacy": "allow",
31
33
  ...r,
32
34
  href: o,
33
- ref: u,
34
- style: !!t ? {
35
- "--uy-link-max-w": `${t}ch`
35
+ ref: f,
36
+ style: !!i ? {
37
+ "--uy-link-max-w": `${i}ch`
36
38
  } : {},
37
- className: f,
39
+ className: k(),
38
40
  isDisabled: n,
39
41
  target: e ? "_blank" : r.target,
40
42
  rel: e && !r.rel ? "noopener noreferrer" : r.rel,
41
- ...i !== void 0 && {
42
- "data-current": i,
43
- "aria-current": i ? "page" : void 0
43
+ ...t !== void 0 && {
44
+ "data-current": t,
45
+ "aria-current": t ? "page" : void 0
44
46
  },
45
47
  children: [
46
- a,
47
- e && /* @__PURE__ */ y(
48
- g,
48
+ l,
49
+ e && /* @__PURE__ */ w(
50
+ y,
49
51
  {
50
52
  src: "ArrowSquareOutOutlined",
51
53
  color: "currentColor",
52
- width: "1em",
53
- height: "1em",
54
+ width: "1.45em",
55
+ height: "1.45em",
54
56
  role: "presentation",
55
- className: "uy:self-center uy:inline"
57
+ className: v()
56
58
  }
57
59
  )
58
60
  ]
@@ -60,7 +62,7 @@ const E = v(
60
62
  );
61
63
  }
62
64
  );
63
- E.displayName = "Link";
65
+ S.displayName = "Link";
64
66
  export {
65
- E as Link
67
+ S as Link
66
68
  };
@@ -1,55 +1,166 @@
1
1
  export declare const link: import('tailwind-variants').TVReturnType<{
2
2
  variant: {
3
- inline: string;
4
- standalone: string;
3
+ inline: {
4
+ base: string;
5
+ icon: string;
6
+ };
7
+ standalone: {
8
+ base: string;
9
+ icon: string;
10
+ };
11
+ };
12
+ size: {
13
+ default: {
14
+ base: string;
15
+ };
16
+ large: {
17
+ base: string;
18
+ };
19
+ small: {
20
+ base: string;
21
+ };
22
+ inherit: {
23
+ base: string;
24
+ };
5
25
  };
6
26
  color: {
7
- primary: string;
8
- secondary: string;
9
- inherit: string;
27
+ primary: {
28
+ base: string;
29
+ };
30
+ secondary: {
31
+ base: string;
32
+ };
33
+ inherit: {
34
+ base: string;
35
+ };
10
36
  };
11
37
  isDisabled: {
12
- true: string;
13
- false: string;
38
+ true: {
39
+ base: string;
40
+ };
41
+ false: {
42
+ base: string;
43
+ };
14
44
  };
15
45
  isTruncated: {
16
- true: string;
17
- false: string;
46
+ true: {
47
+ base: string;
48
+ };
49
+ false: {
50
+ base: string;
51
+ };
18
52
  };
19
- }, undefined, "uy:rounded-50 uy:underline uy:transition-colors uy:disabled:text-content-neutral-disabled uy:focus-visible:outline-none uy:focus-visible:text-content-neutral-focus uy:focus-visible:ring-2 uy:focus-visible:ring-offset-2 uy:focus-visible:ring-utility-focus-ring", {
53
+ }, {
54
+ base: string[];
55
+ icon: string[];
56
+ }, undefined, {
20
57
  variant: {
21
- inline: string;
22
- standalone: string;
58
+ inline: {
59
+ base: string;
60
+ icon: string;
61
+ };
62
+ standalone: {
63
+ base: string;
64
+ icon: string;
65
+ };
66
+ };
67
+ size: {
68
+ default: {
69
+ base: string;
70
+ };
71
+ large: {
72
+ base: string;
73
+ };
74
+ small: {
75
+ base: string;
76
+ };
77
+ inherit: {
78
+ base: string;
79
+ };
23
80
  };
24
81
  color: {
25
- primary: string;
26
- secondary: string;
27
- inherit: string;
82
+ primary: {
83
+ base: string;
84
+ };
85
+ secondary: {
86
+ base: string;
87
+ };
88
+ inherit: {
89
+ base: string;
90
+ };
28
91
  };
29
92
  isDisabled: {
30
- true: string;
31
- false: string;
93
+ true: {
94
+ base: string;
95
+ };
96
+ false: {
97
+ base: string;
98
+ };
32
99
  };
33
100
  isTruncated: {
34
- true: string;
35
- false: string;
101
+ true: {
102
+ base: string;
103
+ };
104
+ false: {
105
+ base: string;
106
+ };
36
107
  };
37
- }, undefined, import('tailwind-variants').TVReturnType<{
108
+ }, {
109
+ base: string[];
110
+ icon: string[];
111
+ }, import('tailwind-variants').TVReturnType<{
38
112
  variant: {
39
- inline: string;
40
- standalone: string;
113
+ inline: {
114
+ base: string;
115
+ icon: string;
116
+ };
117
+ standalone: {
118
+ base: string;
119
+ icon: string;
120
+ };
121
+ };
122
+ size: {
123
+ default: {
124
+ base: string;
125
+ };
126
+ large: {
127
+ base: string;
128
+ };
129
+ small: {
130
+ base: string;
131
+ };
132
+ inherit: {
133
+ base: string;
134
+ };
41
135
  };
42
136
  color: {
43
- primary: string;
44
- secondary: string;
45
- inherit: string;
137
+ primary: {
138
+ base: string;
139
+ };
140
+ secondary: {
141
+ base: string;
142
+ };
143
+ inherit: {
144
+ base: string;
145
+ };
46
146
  };
47
147
  isDisabled: {
48
- true: string;
49
- false: string;
148
+ true: {
149
+ base: string;
150
+ };
151
+ false: {
152
+ base: string;
153
+ };
50
154
  };
51
155
  isTruncated: {
52
- true: string;
53
- false: string;
156
+ true: {
157
+ base: string;
158
+ };
159
+ false: {
160
+ base: string;
161
+ };
54
162
  };
55
- }, undefined, "uy:rounded-50 uy:underline uy:transition-colors uy:disabled:text-content-neutral-disabled uy:focus-visible:outline-none uy:focus-visible:text-content-neutral-focus uy:focus-visible:ring-2 uy:focus-visible:ring-offset-2 uy:focus-visible:ring-utility-focus-ring", unknown, unknown, undefined>>;
163
+ }, {
164
+ base: string[];
165
+ icon: string[];
166
+ }, undefined, unknown, unknown, undefined>>;
@@ -1,46 +1,74 @@
1
- import { tv as t } from "tailwind-variants";
2
- const a = t({
3
- base: "uy:rounded-50 uy:underline uy:transition-colors uy:disabled:text-content-neutral-disabled uy:focus-visible:outline-none uy:focus-visible:text-content-neutral-focus uy:focus-visible:ring-2 uy:focus-visible:ring-offset-2 uy:focus-visible:ring-utility-focus-ring",
1
+ import { uyTv as e } from "@payfit/unity-themes";
2
+ const a = e({
3
+ slots: {
4
+ base: [
5
+ "uy:rounded-50 uy:underline uy:transition-colors uy:underline-offset-3",
6
+ "uy:disabled:text-content-neutral-disabled",
7
+ "uy:focus-visible:outline-none uy:focus-visible:text-content-neutral-focus uy:focus-visible:ring-2 uy:focus-visible:ring-offset-2 uy:focus-visible:ring-utility-focus-ring"
8
+ ],
9
+ icon: ["uy:inline uy:ml-25"]
10
+ },
4
11
  variants: {
5
12
  variant: {
6
- inline: "uy:inline uy:text-(length:inherit) uy:font-medium uy:leading-inherit",
7
- standalone: "uy:flex uy:typography-action uy:gap-x-25 uy:items-end"
13
+ inline: {
14
+ base: "uy:inline uy:text-(length:inherit) uy:font-medium uy:leading-inherit",
15
+ icon: "uy:align-top"
16
+ },
17
+ standalone: {
18
+ base: "uy:flex uy:gap-x-25 uy:items-end",
19
+ icon: "uy:self-center"
20
+ }
21
+ },
22
+ size: {
23
+ default: { base: "uy:typography-action" },
24
+ large: { base: "uy:typography-action-large" },
25
+ small: { base: "uy:typography-action-small" },
26
+ inherit: { base: "uy:text-inherit" }
8
27
  },
9
28
  color: {
10
- primary: "uy:text-content-primary-enabled uy:hover:text-content-primary-hover uy:active:text-content-primary-active uy:data-[pressed]:text-content-primary-active uy:data-[current]:text-content-primary-active uy:aria-[current]:text-content-primary-active",
11
- secondary: "uy:text-content-neutral-enabled uy:hover:text-content-neutral-hover uy:active:text-content-neutral-active uy:data-[pressed]:text-content-neutral-pressed uy:data-[current]:text-content-neutral-active uy:aria-[current]:text-content-neutral-active",
12
- inherit: "uy:text-(color:inherit)"
29
+ primary: {
30
+ base: "uy:text-content-primary-enabled uy:hover:text-content-primary-hover uy:active:text-content-primary-active uy:data-[pressed]:text-content-primary-active uy:data-[current]:text-content-primary-active uy:aria-[current]:text-content-primary-active"
31
+ },
32
+ secondary: {
33
+ base: "uy:text-content-neutral-enabled uy:hover:text-content-neutral-hover uy:active:text-content-neutral-active uy:data-[pressed]:text-content-neutral-pressed uy:data-[current]:text-content-neutral-active uy:aria-[current]:text-content-neutral-active"
34
+ },
35
+ inherit: { base: "uy:text-(color:inherit)" }
13
36
  },
14
37
  isDisabled: {
15
- true: "uy:data-[disabled]:cursor-not-allowed",
16
- false: "uy:enabled:cursor-pointer"
38
+ true: { base: "uy:data-[disabled]:cursor-not-allowed" },
39
+ false: { base: "uy:enabled:cursor-pointer" }
17
40
  },
18
41
  isTruncated: {
19
- true: "uy:truncate uy:max-w-[var(--uy-link-max-w)]",
20
- false: ""
42
+ true: { base: "uy:truncate uy:max-w-[var(--uy-link-max-w)]" },
43
+ false: { base: "" }
21
44
  }
22
45
  },
23
46
  compoundVariants: [
24
47
  {
25
48
  color: "primary",
26
49
  isDisabled: !0,
27
- class: "uy:data-[disabled]:text-content-primary-disabled"
50
+ class: { base: "uy:data-[disabled]:text-content-primary-disabled" }
28
51
  },
29
52
  {
30
53
  color: "secondary",
31
54
  isDisabled: !0,
32
- class: "uy:data-[disabled]:text-content-neutral-lowest-disabled"
55
+ class: {
56
+ base: "uy:data-[disabled]:text-content-neutral-lowest-disabled"
57
+ }
33
58
  },
34
59
  {
35
60
  color: "inherit",
36
61
  isDisabled: !0,
37
- class: "uy:data-[disabled]:text-content-neutral-lowest-disabled"
62
+ class: {
63
+ base: "uy:data-[disabled]:text-content-neutral-lowest-disabled"
64
+ }
38
65
  }
39
66
  ],
40
67
  defaultVariants: {
41
68
  variant: "inline",
42
69
  color: "primary",
43
- isDisabled: !1
70
+ isDisabled: !1,
71
+ size: "inherit"
44
72
  }
45
73
  });
46
74
  export {
@@ -1,27 +1,27 @@
1
1
  import { jsxs as s, jsx as o } from "react/jsx-runtime";
2
- import { MenuItem as y } from "react-aria-components";
3
- import { twMerge as i } from "tailwind-merge";
2
+ import { uyMerge as y } from "@payfit/unity-themes";
3
+ import { MenuItem as i } from "react-aria-components";
4
4
  function l({
5
5
  prefix: e,
6
- children: t,
7
- href: u,
6
+ children: u,
7
+ href: t,
8
8
  onAction: r,
9
9
  className: n,
10
10
  ...a
11
11
  }) {
12
12
  return /* @__PURE__ */ s(
13
- y,
13
+ i,
14
14
  {
15
- href: u,
15
+ href: t,
16
16
  onAction: r,
17
- className: i(
17
+ className: y(
18
18
  "uy:cursor-pointer uy:flex uy:p-100 uy:items-start uy:gap-100 uy:rounded-25 uy:typography-body uy:text-content-neutral uy:hover:bg-surface-neutral-hover uy:data-[pressed]:bg-surface-neutral-pressed uy:focus-visible:outline-utility-focus-ring uy:active:bg-surface-neutral-active",
19
19
  n
20
20
  ),
21
21
  ...a,
22
22
  children: [
23
23
  /* @__PURE__ */ o("div", { className: "uy:text-content-neutral-low", children: e || null }),
24
- t
24
+ u
25
25
  ]
26
26
  }
27
27
  );
@@ -1,15 +1,15 @@
1
1
  import { jsxs as c, jsx as e } from "react/jsx-runtime";
2
2
  import { memo as j, forwardRef as E, useContext as k, useMemo as A } from "react";
3
3
  import { useSelectContext as D, useStoreState as K, Select as $ } from "@ariakit/react";
4
- import { useId as L } from "react-aria";
5
- import { useIntl as R } from "react-intl";
6
- import { tv as U } from "tailwind-variants";
7
- import { Badge as W } from "../../badge/Badge.js";
8
- import { CircularIconButton as q } from "../../icon-button/CircularIconButton.js";
4
+ import { uyTv as L } from "@payfit/unity-themes";
5
+ import { useId as R } from "react-aria";
6
+ import { useIntl as T } from "react-intl";
7
+ import { Badge as U } from "../../badge/Badge.js";
8
+ import { CircularIconButton as W } from "../../icon-button/CircularIconButton.js";
9
9
  import { Icon as p } from "../../icon/Icon.js";
10
- import { Spinner as F } from "../../spinner/Spinner.js";
11
- import { MultiSelectContext as G } from "../Multiselect.context.js";
12
- const H = U({
10
+ import { Spinner as q } from "../../spinner/Spinner.js";
11
+ import { MultiSelectContext as F } from "../Multiselect.context.js";
12
+ const G = L({
13
13
  slots: {
14
14
  base: "uy:h-500 uy:flex uy:items-center uy:justify-between uy:py-100 uy:px-150 uy:w-full uy:border uy:border-solid uy:rounded-75 uy:focus-within:outline-none uy:focus-within:ring-2 uy:focus-within:ring-utility-focus-ring uy:focus-within:ring-offset-2 uy:active:not([disabled]):border-border-form-active uy:pointer-events-auto!",
15
15
  inputValue: "uy:flex-1 uy:typography-body uy:text-content-form-enabled uy:text-left uy:line-clamp-1",
@@ -61,7 +61,7 @@ const H = U({
61
61
  }
62
62
  ]
63
63
  });
64
- function J({
64
+ function H({
65
65
  isDisabled: r,
66
66
  isReadOnly: t,
67
67
  isLoading: d,
@@ -72,7 +72,7 @@ function J({
72
72
  onClearButtonPress: i,
73
73
  ...w
74
74
  }, h) {
75
- const f = L(), s = R(), S = D(), M = K(S, "open"), y = k(G), a = y.maxVisibleItems ?? 0, l = y.selectedKeys ?? /* @__PURE__ */ new Set(), o = Array.from(g), { base: v, inputValue: I, state: C, suffix: V } = H({
75
+ const f = R(), s = T(), S = D(), M = K(S, "open"), y = k(F), a = y.maxVisibleItems ?? 0, l = y.selectedKeys ?? /* @__PURE__ */ new Set(), o = Array.from(g), { base: v, inputValue: I, state: C, suffix: V } = G({
76
76
  isDisabled: !!r,
77
77
  isReadOnly: !!t,
78
78
  isInvalid: !!n,
@@ -100,7 +100,7 @@ function J({
100
100
  /* @__PURE__ */ e("span", { id: `${f}-select-button-label`, className: I(), children: l.size > 0 ? B : u }),
101
101
  /* @__PURE__ */ c("div", { className: C(), children: [
102
102
  d && /* @__PURE__ */ e(
103
- F,
103
+ q,
104
104
  {
105
105
  color: "inherit",
106
106
  size: "small",
@@ -121,12 +121,12 @@ function J({
121
121
  })
122
122
  }
123
123
  ),
124
- b > 0 && /* @__PURE__ */ c(W, { variant: "numeric", children: [
124
+ b > 0 && /* @__PURE__ */ c(U, { variant: "numeric", children: [
125
125
  "+",
126
126
  b
127
127
  ] }),
128
128
  N && /* @__PURE__ */ e(
129
- q,
129
+ W,
130
130
  {
131
131
  title: s.formatMessage({
132
132
  id: "unity:component:common:clear:title",
@@ -153,7 +153,7 @@ function J({
153
153
  }
154
154
  );
155
155
  }
156
- const x = j(E(J));
156
+ const x = j(E(H));
157
157
  x.displayName = "MultiselectButton";
158
158
  const ne = x;
159
159
  export {
@@ -1,7 +1,7 @@
1
- import { jsxs as u, jsx as t } from "react/jsx-runtime";
1
+ import { jsxs as s, jsx as t } from "react/jsx-runtime";
2
2
  import { useContext as h } from "react";
3
3
  import { ComboboxGroup as x, ComboboxGroupLabel as C, SelectGroup as G, SelectGroupLabel as S } from "@ariakit/react";
4
- import { tv as N } from "tailwind-variants";
4
+ import { uyTv as N } from "@payfit/unity-themes";
5
5
  import { MultiSelectContext as g } from "../Multiselect.context.js";
6
6
  const M = N({
7
7
  slots: {
@@ -14,15 +14,15 @@ function O(e) {
14
14
  return "items" in e && Array.isArray(e.items) && typeof e.children == "function";
15
15
  }
16
16
  function j(e) {
17
- const i = h(g), { base: c, label: r, separator: o } = M(), { label: n, withSeparator: a, className: m, ...y } = e, d = (b, p) => b.map((f) => p(f)), l = O(e) ? d(e.items, e.children) : e.children, s = {
17
+ const i = h(g), { base: c, label: r, separator: o } = M(), { label: n, withSeparator: a, className: m, ...y } = e, d = (b, p) => b.map((f) => p(f)), l = O(e) ? d(e.items, e.children) : e.children, u = {
18
18
  className: c({ className: m }),
19
19
  ...y
20
20
  };
21
- return i.isSearchable ? /* @__PURE__ */ u(x, { ...s, children: [
21
+ return i.isSearchable ? /* @__PURE__ */ s(x, { ...u, children: [
22
22
  /* @__PURE__ */ t(C, { className: r(), children: n }),
23
23
  l,
24
24
  a && /* @__PURE__ */ t("hr", { className: o(), "aria-hidden": !0, role: "presentation" })
25
- ] }) : /* @__PURE__ */ u(G, { ...s, children: [
25
+ ] }) : /* @__PURE__ */ s(G, { ...u, children: [
26
26
  /* @__PURE__ */ t(S, { className: r(), children: n }),
27
27
  l,
28
28
  a && /* @__PURE__ */ t("hr", { className: o(), "aria-hidden": !0, role: "presentation" })
@@ -1,7 +1,7 @@
1
1
  import { jsx as e, jsxs as m } from "react/jsx-runtime";
2
2
  import { forwardRef as p, useContext as b, createElement as v } from "react";
3
3
  import { SelectItem as x, ComboboxItem as h, SelectItemCheck as S } from "@ariakit/react";
4
- import { tv as g } from "tailwind-variants";
4
+ import { uyTv as g } from "@payfit/unity-themes";
5
5
  import C from "../../../hooks/use-id.js";
6
6
  import { CheckboxIndicator as k } from "../../checkbox/parts/CheckboxIndicator.js";
7
7
  import { MultiSelectContext as I } from "../Multiselect.context.js";
@@ -81,7 +81,7 @@ function r({
81
81
  );
82
82
  }
83
83
  r.displayName = "MultiSelectOption";
84
- const R = p(r);
84
+ const H = p(r);
85
85
  export {
86
- R as MultiSelectOption
86
+ H as MultiSelectOption
87
87
  };
@@ -1,7 +1,7 @@
1
1
  import { jsx as e, jsxs as r, Fragment as m } from "react/jsx-runtime";
2
2
  import { memo as b, useContext as f } from "react";
3
3
  import { SelectPopover as h, Combobox as v, ComboboxList as x } from "@ariakit/react";
4
- import { tv as i } from "tailwind-variants";
4
+ import { uyTv as i } from "@payfit/unity-themes";
5
5
  import { Icon as g } from "../../icon/Icon.js";
6
6
  import { MultiSelectContext as w } from "../Multiselect.context.js";
7
7
  const S = i({