@payfit/unity-components 1.0.0 → 1.1.1-beta.1
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.
- package/dist/esm/components/action-bar/ActionBar.d.ts +153 -0
- package/dist/esm/components/action-bar/ActionBar.js +173 -0
- package/dist/esm/components/action-bar/parts/ActionBarAction.d.ts +44 -0
- package/dist/esm/components/action-bar/parts/ActionBarAction.js +45 -0
- package/dist/esm/components/action-bar/parts/ActionBarRoot.d.ts +44 -0
- package/dist/esm/components/action-bar/parts/ActionBarRoot.js +46 -0
- package/dist/esm/components/actionable/Actionable.js +20 -21
- package/dist/esm/components/alert/Alert.d.ts +1 -1
- package/dist/esm/components/alert/Alert.js +1 -1
- package/dist/esm/components/alert/parts/AlertActions.d.ts +1 -1
- package/dist/esm/components/alert/parts/AlertActions.js +1 -1
- package/dist/esm/components/alert/parts/AlertContent.d.ts +1 -1
- package/dist/esm/components/alert/parts/AlertTitle.d.ts +1 -1
- package/dist/esm/components/anchor/Anchor.js +1 -1
- package/dist/esm/components/app-layout/AppLayout.js +6 -6
- package/dist/esm/components/app-menu/parts/AppMenuFooter.js +30 -30
- package/dist/esm/components/app-menu/parts/AppMenuNavContent.js +1 -1
- package/dist/esm/components/autocomplete/Autocomplete.d.ts +1 -1
- package/dist/esm/components/autocomplete/Autocomplete.js +14 -14
- package/dist/esm/components/autocomplete/parts/AutocompleteClearButton.js +5 -5
- package/dist/esm/components/autocomplete/parts/AutocompleteItem.d.ts +1 -1
- package/dist/esm/components/autocomplete/parts/AutocompleteItem.js +4 -4
- package/dist/esm/components/autocomplete/parts/AutocompleteItemGroup.d.ts +1 -1
- package/dist/esm/components/autocomplete/parts/AutocompleteItemGroup.js +12 -12
- package/dist/esm/components/autocomplete/parts/AutocompletePanel.d.ts +1 -1
- package/dist/esm/components/autocomplete/parts/AutocompletePanel.js +7 -7
- package/dist/esm/components/avatar/Avatar.d.ts +1 -1
- package/dist/esm/components/avatar/Avatar.js +15 -16
- package/dist/esm/components/avatar/Avatar.variants.js +1 -1
- package/dist/esm/components/avatar/parts/AvatarFallback.d.ts +1 -1
- package/dist/esm/components/avatar/parts/AvatarFallback.js +9 -10
- package/dist/esm/components/avatar/parts/AvatarImage.js +12 -12
- package/dist/esm/components/avatar/parts/AvatarPair.d.ts +1 -1
- package/dist/esm/components/avatar/parts/AvatarPair.js +4 -4
- package/dist/esm/components/badge/Badge.d.ts +1 -1
- package/dist/esm/components/badge/Badge.js +31 -35
- package/dist/esm/components/bottom-sheet/BottomSheet.d.ts +1 -1
- package/dist/esm/components/bottom-sheet/BottomSheet.js +14 -14
- package/dist/esm/components/bottom-sheet/parts/BottomSheetContent.d.ts +1 -1
- package/dist/esm/components/bottom-sheet/parts/BottomSheetContent.js +4 -4
- package/dist/esm/components/bottom-sheet/parts/BottomSheetDragIndicator.js +11 -11
- package/dist/esm/components/bottom-sheet/parts/BottomSheetFooter.d.ts +1 -1
- package/dist/esm/components/bottom-sheet/parts/BottomSheetFooter.js +4 -4
- package/dist/esm/components/bottom-sheet/parts/BottomSheetHeader.d.ts +4 -4
- package/dist/esm/components/bottom-sheet/parts/BottomSheetHeader.js +6 -6
- package/dist/esm/components/breadcrumbs/Breadcrumbs.context.d.ts +1 -1
- package/dist/esm/components/breadcrumbs/Breadcrumbs.d.ts +1 -1
- package/dist/esm/components/breadcrumbs/Breadcrumbs.variant.js +3 -3
- package/dist/esm/components/button/Button.js +33 -41
- package/dist/esm/components/button/Button.variants.d.ts +1 -1
- package/dist/esm/components/button/Button.variants.js +1 -1
- package/dist/esm/components/checkbox/Checkbox.js +53 -49
- package/dist/esm/components/checkbox/Checkbox.variants.js +1 -1
- package/dist/esm/components/checkbox/parts/CheckboxIndicator.js +1 -1
- package/dist/esm/components/checkbox-field/CheckboxField.js +39 -34
- package/dist/esm/components/checkbox-group/CheckboxGroup.d.ts +1 -1
- package/dist/esm/components/checkbox-group/CheckboxGroup.js +12 -12
- package/dist/esm/components/code/Code.d.ts +7 -0
- package/dist/esm/components/code/copyToClipboard.d.ts +1 -0
- package/dist/esm/components/collapsible/Collapsible.d.ts +1 -1
- package/dist/esm/components/collapsible/Collapsible.js +20 -13
- package/dist/esm/components/collapsible/parts/CollapsibleContent.js +16 -7
- package/dist/esm/components/collapsible/parts/CollapsibleTitle.js +23 -23
- package/dist/esm/components/data-table/DataTable.d.ts +48 -17
- package/dist/esm/components/data-table/DataTable.js +104 -60
- package/dist/esm/components/data-table/mocks/employee-columns.d.ts +4 -0
- package/dist/esm/components/data-table/parts/ColumnSortHeader.js +13 -13
- package/dist/esm/components/data-table/parts/DataTableBulkActions.d.ts +55 -0
- package/dist/esm/components/data-table/parts/DataTableBulkActions.js +65 -0
- package/dist/esm/components/data-table/parts/DataTableRoot.d.ts +37 -0
- package/dist/esm/components/data-table/parts/DataTableRoot.js +13 -0
- package/dist/esm/components/date-calendar/DateCalendar.js +8 -8
- package/dist/esm/components/date-picker/DatePicker.js +9 -9
- package/dist/esm/components/date-picker/parts/DateInput.js +7 -7
- package/dist/esm/components/date-picker-field/DatePickerField.js +12 -12
- package/dist/esm/components/definition-tooltip/DefinitionTooltip.js +4 -4
- package/dist/esm/components/dialog/Dialog.d.ts +1 -1
- package/dist/esm/components/dialog/Dialog.js +9 -9
- package/dist/esm/components/dialog/parts/DialogActions/DialogButton.d.ts +1 -1
- package/dist/esm/components/fieldset/Fieldset.d.ts +1 -1
- package/dist/esm/components/fieldset/Fieldset.js +4 -4
- package/dist/esm/components/flex/Flex.d.ts +1 -1
- package/dist/esm/components/flex/Flex.variants.js +189 -207
- package/dist/esm/components/flex/FlexItem.d.ts +1 -1
- package/dist/esm/components/form/Form.context.d.ts +1 -4
- package/dist/esm/components/form/Form.context.js +11 -13
- package/dist/esm/components/form/Form.d.ts +13 -11
- package/dist/esm/components/form/Form.js +45 -48
- package/dist/esm/components/form-field/FormField.context.d.ts +1 -6
- package/dist/esm/components/form-field/FormField.context.js +39 -47
- package/dist/esm/components/form-field/FormField.d.ts +0 -2
- package/dist/esm/components/form-field/FormField.js +37 -42
- package/dist/esm/components/form-field/parts/FormContextualLink.js +17 -17
- package/dist/esm/components/form-field/parts/FormControl.js +39 -35
- package/dist/esm/components/form-field/parts/FormFeedbackText.js +15 -17
- package/dist/esm/components/full-page-loader/FullPageLoader.js +7 -7
- package/dist/esm/components/funnel-layout/FunnelLayout.d.ts +3 -3
- package/dist/esm/components/funnel-layout/FunnelLayout.js +62 -111
- package/dist/esm/components/funnel-layout/parts/FunnelBody.d.ts +2 -2
- package/dist/esm/components/funnel-layout/parts/FunnelBody.js +4 -4
- package/dist/esm/components/funnel-layout/parts/FunnelPage.d.ts +2 -2
- package/dist/esm/components/funnel-layout/parts/FunnelPage.js +14 -15
- package/dist/esm/components/funnel-layout/parts/FunnelPageAction.d.ts +1 -1
- package/dist/esm/components/funnel-layout/parts/FunnelPageActions.d.ts +2 -2
- package/dist/esm/components/funnel-layout/parts/FunnelPageActions.js +13 -13
- package/dist/esm/components/funnel-layout/parts/FunnelPageContent.d.ts +2 -2
- package/dist/esm/components/funnel-layout/parts/FunnelPageContent.js +1 -1
- package/dist/esm/components/funnel-layout/parts/FunnelPageFooter.d.ts +2 -2
- package/dist/esm/components/funnel-layout/parts/FunnelPageFooter.js +9 -10
- package/dist/esm/components/funnel-layout/parts/FunnelPageHeader.d.ts +4 -4
- package/dist/esm/components/funnel-layout/parts/FunnelPageHeader.js +4 -4
- package/dist/esm/components/funnel-layout/parts/FunnelProgressBar.d.ts +1 -1
- package/dist/esm/components/funnel-layout/parts/FunnelProgressBar.js +4 -4
- package/dist/esm/components/funnel-layout/parts/FunnelSidebar.d.ts +4 -4
- package/dist/esm/components/funnel-layout/parts/FunnelSidebar.js +9 -10
- package/dist/esm/components/funnel-layout/parts/FunnelTopBar.d.ts +2 -2
- package/dist/esm/components/funnel-layout/parts/FunnelTopBar.js +9 -10
- package/dist/esm/components/grid/Grid.d.ts +1 -1
- package/dist/esm/components/grid/Grid.variants.d.ts +1 -1
- package/dist/esm/components/grid/Grid.variants.js +3 -3
- package/dist/esm/components/grid/GridItem.d.ts +1 -1
- package/dist/esm/components/icon/Icon.d.ts +1 -1
- package/dist/esm/components/icon/Icon.js +1 -1
- package/dist/esm/components/icon-button/CircularIconButton.d.ts +1 -1
- package/dist/esm/components/icon-button/CircularIconButton.js +21 -20
- package/dist/esm/components/icon-button/IconButton.variants.d.ts +1 -1
- package/dist/esm/components/icon-button/IconButton.variants.js +2 -2
- package/dist/esm/components/input/Input.js +6 -6
- package/dist/esm/components/label/Label.js +13 -13
- package/dist/esm/components/link/Link.d.ts +11 -1
- package/dist/esm/components/link/Link.js +32 -30
- package/dist/esm/components/link/Link.variants.d.ts +141 -30
- package/dist/esm/components/link/Link.variants.js +44 -16
- package/dist/esm/components/menu/parts/MenuItem.js +8 -8
- package/dist/esm/components/multi-select/parts/MultiSelectButton.js +14 -14
- package/dist/esm/components/multi-select/parts/MultiSelectOptGroup.js +5 -5
- package/dist/esm/components/multi-select/parts/MultiSelectOption.js +3 -3
- package/dist/esm/components/multi-select/parts/MultiSelectPopover.js +1 -1
- package/dist/esm/components/multi-select-field/MultiSelectField.js +6 -6
- package/dist/esm/components/nav/parts/NavGroup.js +28 -29
- package/dist/esm/components/nav/parts/NavItem.d.ts +1 -1
- package/dist/esm/components/nav/parts/NavItem.js +13 -14
- package/dist/esm/components/number-field/NumberField.js +14 -14
- package/dist/esm/components/number-input/NumberInput.d.ts +2 -2
- package/dist/esm/components/number-input/NumberInput.js +37 -37
- package/dist/esm/components/page/Page.d.ts +1 -1
- package/dist/esm/components/page/Page.js +5 -5
- package/dist/esm/components/page/parts/PageHeader.d.ts +1 -1
- package/dist/esm/components/page/parts/PageHeader.js +4 -4
- package/dist/esm/components/pagination/Pagination.d.ts +1 -1
- package/dist/esm/components/pagination/Pagination.js +16 -16
- package/dist/esm/components/pagination/parts/PaginationEllipsis.d.ts +1 -1
- package/dist/esm/components/pagination/parts/PaginationEllipsis.js +8 -8
- package/dist/esm/components/pagination/parts/PaginationJumpDialog.js +9 -9
- package/dist/esm/components/pagination/parts/PaginationLink.d.ts +1 -1
- package/dist/esm/components/pagination/parts/PaginationLink.js +6 -6
- package/dist/esm/components/payfit-brand/PayFitBrand.js +4 -4
- package/dist/esm/components/pill/Pill.d.ts +1 -1
- package/dist/esm/components/pill/Pill.js +1 -1
- package/dist/esm/components/popover/Popover.js +5 -5
- package/dist/esm/components/popover/parts/PopoverHeader.js +7 -7
- package/dist/esm/components/progress-bar/ProgressBar.js +11 -11
- package/dist/esm/components/radio-button-group/parts/RadioButton.d.ts +1 -1
- package/dist/esm/components/radio-button-group/parts/RadioButton.js +5 -5
- package/dist/esm/components/search/Search.d.ts +1 -1
- package/dist/esm/components/search/Search.js +14 -14
- package/dist/esm/components/segmented-button-group/parts/ToggleButton.js +10 -10
- package/dist/esm/components/select/Select.js +12 -12
- package/dist/esm/components/select/parts/SearchInput.js +7 -7
- package/dist/esm/components/select/parts/SelectButton.js +17 -14
- package/dist/esm/components/select/parts/SelectOption.js +4 -4
- package/dist/esm/components/select/parts/SelectOptionGroup.js +8 -8
- package/dist/esm/components/select/parts/SelectOptionHelper.js +1 -1
- package/dist/esm/components/select-field/SelectField.d.ts +1 -1
- package/dist/esm/components/select-field/SelectField.js +16 -16
- package/dist/esm/components/selectable-button-group/SelectableButtonGroup.d.ts +1 -1
- package/dist/esm/components/selectable-button-group/SelectableButtonGroup.js +8 -8
- package/dist/esm/components/selectable-button-group/parts/SelectableButton.js +10 -10
- package/dist/esm/components/selectable-card/internals/Content.js +5 -5
- package/dist/esm/components/selectable-card/internals/Description.js +1 -1
- package/dist/esm/components/selectable-card/internals/Illustration.js +3 -3
- package/dist/esm/components/selectable-card/internals/SelectedIndicator.js +4 -4
- package/dist/esm/components/selectable-card/selectable-card-checkbox-group/parts/SelectableCardCheckbox.d.ts +1 -1
- package/dist/esm/components/selectable-card/selectable-card-radio-group/parts/RadioIndicator.js +3 -3
- package/dist/esm/components/selectable-card/selectable-card-radio-group/parts/SelectableCardRadio.d.ts +1 -1
- package/dist/esm/components/selectable-card/selectableCard.variant.js +1 -1
- package/dist/esm/components/selectable-card-radio-group-field/SelectableCardRadioGroupField.js +22 -22
- package/dist/esm/components/side-panel/SidePanel.d.ts +1 -1
- package/dist/esm/components/side-panel/SidePanel.js +6 -6
- package/dist/esm/components/side-panel/parts/SidePanelContent.d.ts +1 -1
- package/dist/esm/components/side-panel/parts/SidePanelContent.js +9 -9
- package/dist/esm/components/side-panel/parts/SidePanelDragIndicator.js +11 -11
- package/dist/esm/components/side-panel/parts/SidePanelFooter.d.ts +1 -1
- package/dist/esm/components/side-panel/parts/SidePanelFooter.js +4 -4
- package/dist/esm/components/side-panel/parts/SidePanelHeader.d.ts +4 -4
- package/dist/esm/components/side-panel/parts/SidePanelHeader.js +6 -6
- package/dist/esm/components/skip-links/SkipLinks.d.ts +79 -0
- package/dist/esm/components/skip-links/SkipLinks.js +87 -0
- package/dist/esm/components/spinner/Spinner.js +5 -5
- package/dist/esm/components/table/Table.js +101 -100
- package/dist/esm/components/table/hooks/useTableKeyboardNavigation.d.ts +1 -19
- package/dist/esm/components/table/hooks/useTableKeyboardNavigation.js +147 -95
- package/dist/esm/components/table/parts/TableBody.js +1 -1
- package/dist/esm/components/table/parts/TableCell.d.ts +17 -1
- package/dist/esm/components/table/parts/TableCell.js +45 -41
- package/dist/esm/components/table/parts/TableColumnHeader.d.ts +2 -1
- package/dist/esm/components/table/parts/TableColumnHeader.js +63 -57
- package/dist/esm/components/table/parts/TableEmptyState.d.ts +1 -1
- package/dist/esm/components/table/parts/TableEmptyState.js +1 -1
- package/dist/esm/components/table/parts/TableHeader.d.ts +3 -3
- package/dist/esm/components/table/parts/TableHeader.js +28 -26
- package/dist/esm/components/table/parts/TablePagination.d.ts +1 -1
- package/dist/esm/components/table/parts/TablePagination.js +9 -9
- package/dist/esm/components/table/parts/TableRow.d.ts +1 -1
- package/dist/esm/components/table/parts/TableRow.js +36 -34
- package/dist/esm/components/tabs/Tabs.context.d.ts +1 -1
- package/dist/esm/components/tabs/Tabs.d.ts +1 -1
- package/dist/esm/components/tabs/Tabs.variant.js +1 -1
- package/dist/esm/components/tabs/parts/NavigationButton.js +12 -12
- package/dist/esm/components/tabs/parts/Tab.d.ts +3 -2
- package/dist/esm/components/tabs/parts/Tab.js +12 -12
- package/dist/esm/components/tabs/parts/TabPanel.d.ts +4 -2
- package/dist/esm/components/tabs/parts/TabPanel.js +7 -7
- package/dist/esm/components/task-menu/TaskMenu.d.ts +1 -1
- package/dist/esm/components/task-menu/TaskMenu.js +7 -7
- package/dist/esm/components/task-menu/parts/Content.js +6 -6
- package/dist/esm/components/task-menu/parts/Header.js +7 -7
- package/dist/esm/components/task-menu/parts/SubTask.js +6 -6
- package/dist/esm/components/task-menu/parts/Task.d.ts +1 -1
- package/dist/esm/components/task-menu/parts/Task.js +12 -12
- package/dist/esm/components/task-menu/parts/TaskGroup.js +7 -7
- package/dist/esm/components/task-menu/parts/task.variants.js +1 -1
- package/dist/esm/components/text/Text.d.ts +1 -1
- package/dist/esm/components/text/Text.variants.js +1 -1
- package/dist/esm/components/text-area/TextArea.js +6 -6
- package/dist/esm/components/text-field/TextField.js +5 -5
- package/dist/esm/components/toast/UnityToast.d.ts +1 -1
- package/dist/esm/components/toast/UnityToast.js +11 -11
- package/dist/esm/components/toggle-switch/ToggleSwitch.d.ts +1 -1
- package/dist/esm/components/toggle-switch/ToggleSwitch.js +4 -4
- package/dist/esm/components/toggle-switch-field/ToggleSwitchField.js +35 -31
- package/dist/esm/components/toggle-switch-group/ToggleSwitchGroup.d.ts +1 -1
- package/dist/esm/components/toggle-switch-group/ToggleSwitchGroup.js +5 -5
- package/dist/esm/components/toggle-switch-group-field/ToggleSwitchGroupField.js +43 -38
- package/dist/esm/components/tooltip/Tooltip.d.ts +2 -0
- package/dist/esm/components/tooltip/Tooltip.js +27 -19
- package/dist/esm/hooks/use-form.js +7 -7
- package/dist/esm/index.d.ts +6 -1
- package/dist/esm/index.js +366 -352
- package/dist/esm/integrations/react-router/v5/UnityReactRouterV5Provider.js +28 -0
- package/dist/esm/integrations/react-router/v5/index.d.ts +1 -0
- package/dist/esm/integrations/react-router/v5.js +4 -0
- package/i18n/en-GB.json +7 -0
- package/i18n/es-ES.json +7 -0
- package/i18n/fr-FR.json +7 -0
- package/package.json +41 -35
- package/dist/esm/providers/router/integrations/UnityReactRouterV5Provider.js +0 -28
- /package/dist/esm/{providers/router/integrations → integrations/react-router/v5}/UnityReactRouterV5Provider.d.ts +0 -0
|
@@ -1,14 +1,14 @@
|
|
|
1
|
-
import { jsxs as
|
|
1
|
+
import { jsxs as h, jsx as r } from "react/jsx-runtime";
|
|
2
2
|
import { forwardRef as C } from "react";
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
5
|
-
import { FormField as
|
|
6
|
-
import { FormControl as
|
|
7
|
-
import { FormFeedbackText as
|
|
3
|
+
import { uyTv as I } from "@payfit/unity-themes";
|
|
4
|
+
import { useFormContext as T } from "react-hook-form";
|
|
5
|
+
import { FormField as j } from "../form-field/FormField.js";
|
|
6
|
+
import { FormControl as B } from "../form-field/parts/FormControl.js";
|
|
7
|
+
import { FormFeedbackText as P } from "../form-field/parts/FormFeedbackText.js";
|
|
8
8
|
import { FormHelperText as g } from "../form-field/parts/FormHelperText.js";
|
|
9
9
|
import { FormLabel as k } from "../form-field/parts/FormLabel.js";
|
|
10
10
|
import { NumberInput as v } from "../number-input/NumberInput.js";
|
|
11
|
-
const w =
|
|
11
|
+
const w = I({
|
|
12
12
|
base: "uy:flex uy:flex-col uy:gap-100"
|
|
13
13
|
});
|
|
14
14
|
function H({
|
|
@@ -27,17 +27,17 @@ function H({
|
|
|
27
27
|
onClearButtonPress: d,
|
|
28
28
|
...a
|
|
29
29
|
}, F) {
|
|
30
|
-
const { control: b, setValue: x } =
|
|
30
|
+
const { control: b, setValue: x } = T(), N = {
|
|
31
31
|
isRequired: l,
|
|
32
32
|
isInvalid: s,
|
|
33
33
|
isLoading: u,
|
|
34
34
|
isDisabled: c,
|
|
35
35
|
isReadOnly: p
|
|
36
|
-
},
|
|
36
|
+
}, y = d ?? (() => {
|
|
37
37
|
x(o, NaN);
|
|
38
38
|
});
|
|
39
|
-
return /* @__PURE__ */
|
|
40
|
-
|
|
39
|
+
return /* @__PURE__ */ h(
|
|
40
|
+
j,
|
|
41
41
|
{
|
|
42
42
|
control: b,
|
|
43
43
|
name: o,
|
|
@@ -46,16 +46,16 @@ function H({
|
|
|
46
46
|
children: [
|
|
47
47
|
/* @__PURE__ */ r(k, { requiredVariant: f, children: e }),
|
|
48
48
|
m && /* @__PURE__ */ r(g, { children: m }),
|
|
49
|
-
/* @__PURE__ */ r(
|
|
49
|
+
/* @__PURE__ */ r(B, { children: /* @__PURE__ */ r(
|
|
50
50
|
v,
|
|
51
51
|
{
|
|
52
52
|
ref: F,
|
|
53
|
-
onClearButtonPress:
|
|
53
|
+
onClearButtonPress: y,
|
|
54
54
|
defaultValue: t,
|
|
55
55
|
...a
|
|
56
56
|
}
|
|
57
57
|
) }),
|
|
58
|
-
/* @__PURE__ */ r(
|
|
58
|
+
/* @__PURE__ */ r(P, { children: n }),
|
|
59
59
|
i
|
|
60
60
|
]
|
|
61
61
|
}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
+
import { VariantProps } from '@payfit/unity-themes';
|
|
1
2
|
import { ReactElement } from 'react';
|
|
2
3
|
import { NumberFieldProps } from 'react-aria-components';
|
|
3
|
-
import { VariantProps } from 'tailwind-variants';
|
|
4
4
|
export declare const numberInput: import('tailwind-variants').TVReturnType<{
|
|
5
5
|
isReadOnly: {
|
|
6
6
|
true: {
|
|
@@ -136,5 +136,5 @@ export interface NumberProps extends VariantProps<typeof numberInput>, Omit<Numb
|
|
|
136
136
|
* @see {@link NumberProps} for all available props
|
|
137
137
|
* @remarks {@link https://www.payfit.design/24f360409/p/545bd2-number-field|Design docs}
|
|
138
138
|
*/
|
|
139
|
-
declare const NumberInput: import('react').ForwardRefExoticComponent<NumberProps & import('react').RefAttributes<
|
|
139
|
+
declare const NumberInput: import('react').ForwardRefExoticComponent<NumberProps & import('react').RefAttributes<HTMLInputElement>>;
|
|
140
140
|
export { NumberInput };
|
|
@@ -1,13 +1,13 @@
|
|
|
1
|
-
import { jsxs as
|
|
1
|
+
import { jsxs as t, jsx as e } from "react/jsx-runtime";
|
|
2
2
|
import { forwardRef as G } from "react";
|
|
3
|
+
import { uyTv as T } from "@payfit/unity-themes";
|
|
3
4
|
import { NumberField as W, Group as q, Input as A } from "react-aria-components";
|
|
4
|
-
import {
|
|
5
|
-
import { Icon as H } from "../icon/Icon.js";
|
|
5
|
+
import { Icon as C } from "../icon/Icon.js";
|
|
6
6
|
import "@payfit/unity-icons";
|
|
7
|
-
import { useIntl as
|
|
7
|
+
import { useIntl as H } from "react-intl";
|
|
8
8
|
import { CircularIconButton as s } from "../icon-button/CircularIconButton.js";
|
|
9
|
-
import { Spinner as
|
|
10
|
-
const
|
|
9
|
+
import { Spinner as J } from "../spinner/Spinner.js";
|
|
10
|
+
const K = T({
|
|
11
11
|
slots: {
|
|
12
12
|
base: [
|
|
13
13
|
"uy:group uy:flex uy:h-500 uy:border uy:border-solid uy:rounded-100",
|
|
@@ -81,27 +81,27 @@ const Q = C({
|
|
|
81
81
|
}
|
|
82
82
|
}
|
|
83
83
|
}
|
|
84
|
-
}),
|
|
84
|
+
}), Q = G(
|
|
85
85
|
({
|
|
86
86
|
withControls: b = !1,
|
|
87
87
|
defaultValue: u,
|
|
88
|
-
formatOptions:
|
|
88
|
+
formatOptions: g,
|
|
89
89
|
isDisabled: f,
|
|
90
90
|
isInvalid: y,
|
|
91
91
|
isLoading: a,
|
|
92
92
|
isReadOnly: d,
|
|
93
|
-
isRequired:
|
|
93
|
+
isRequired: x,
|
|
94
94
|
maxValue: n,
|
|
95
95
|
minValue: i,
|
|
96
96
|
prefix: m,
|
|
97
|
-
onBlur:
|
|
98
|
-
onChange:
|
|
97
|
+
onBlur: w,
|
|
98
|
+
onChange: v,
|
|
99
99
|
onClearButtonPress: l,
|
|
100
|
-
step:
|
|
100
|
+
step: h,
|
|
101
101
|
suffix: c,
|
|
102
102
|
value: r,
|
|
103
|
-
...
|
|
104
|
-
},
|
|
103
|
+
...N
|
|
104
|
+
}, p) => {
|
|
105
105
|
const {
|
|
106
106
|
base: M,
|
|
107
107
|
wrapper: I,
|
|
@@ -110,48 +110,48 @@ const Q = C({
|
|
|
110
110
|
suffix: O,
|
|
111
111
|
state: S,
|
|
112
112
|
controls: D
|
|
113
|
-
} =
|
|
114
|
-
return /* @__PURE__ */
|
|
113
|
+
} = K({ isReadOnly: d }), o = H(), k = r !== void 0 && !isNaN(r), z = u !== void 0 && !isNaN(u), F = (k || z) && !b && !a && !d && !f;
|
|
114
|
+
return /* @__PURE__ */ t(
|
|
115
115
|
W,
|
|
116
116
|
{
|
|
117
|
-
ref:
|
|
117
|
+
ref: p,
|
|
118
118
|
className: M(),
|
|
119
119
|
value: r,
|
|
120
120
|
defaultValue: u,
|
|
121
121
|
minValue: i,
|
|
122
122
|
maxValue: n,
|
|
123
|
-
step:
|
|
123
|
+
step: h,
|
|
124
124
|
isDisabled: f,
|
|
125
125
|
isReadOnly: d,
|
|
126
126
|
isInvalid: y,
|
|
127
|
-
isRequired:
|
|
127
|
+
isRequired: x,
|
|
128
128
|
"aria-busy": a,
|
|
129
|
-
onChange:
|
|
130
|
-
formatOptions:
|
|
131
|
-
onBlur:
|
|
132
|
-
...
|
|
129
|
+
onChange: v,
|
|
130
|
+
formatOptions: g,
|
|
131
|
+
onBlur: w,
|
|
132
|
+
...N,
|
|
133
133
|
children: [
|
|
134
134
|
m ? /* @__PURE__ */ e("span", { className: E(), children: m }) : null,
|
|
135
|
-
/* @__PURE__ */
|
|
136
|
-
/* @__PURE__ */ e(A, { className: j() }),
|
|
137
|
-
/* @__PURE__ */
|
|
135
|
+
/* @__PURE__ */ t(q, { className: I(), children: [
|
|
136
|
+
/* @__PURE__ */ e(A, { ref: p, className: j() }),
|
|
137
|
+
/* @__PURE__ */ t("div", { className: S(), children: [
|
|
138
138
|
a && /* @__PURE__ */ e(
|
|
139
|
-
|
|
139
|
+
J,
|
|
140
140
|
{
|
|
141
141
|
color: "inherit",
|
|
142
142
|
size: "small",
|
|
143
|
-
label:
|
|
143
|
+
label: o.formatMessage({
|
|
144
144
|
id: "unity:component:common:loading:label",
|
|
145
145
|
defaultMessage: "Loading..."
|
|
146
146
|
})
|
|
147
147
|
}
|
|
148
148
|
),
|
|
149
149
|
y && /* @__PURE__ */ e(
|
|
150
|
-
|
|
150
|
+
C,
|
|
151
151
|
{
|
|
152
152
|
src: "WarningCircleOutlined",
|
|
153
153
|
color: "content.form.invalid",
|
|
154
|
-
alt:
|
|
154
|
+
alt: o.formatMessage({
|
|
155
155
|
id: "unity:component:form-field:form-input:error:alt",
|
|
156
156
|
defaultMessage: "Error"
|
|
157
157
|
})
|
|
@@ -160,7 +160,7 @@ const Q = C({
|
|
|
160
160
|
F && /* @__PURE__ */ e(
|
|
161
161
|
s,
|
|
162
162
|
{
|
|
163
|
-
title:
|
|
163
|
+
title: o.formatMessage({
|
|
164
164
|
id: "unity:component:common:clear:title",
|
|
165
165
|
defaultMessage: "Clear"
|
|
166
166
|
}),
|
|
@@ -172,7 +172,7 @@ const Q = C({
|
|
|
172
172
|
}
|
|
173
173
|
)
|
|
174
174
|
] }),
|
|
175
|
-
b && /* @__PURE__ */
|
|
175
|
+
b && /* @__PURE__ */ t("div", { className: D(), children: [
|
|
176
176
|
/* @__PURE__ */ e(
|
|
177
177
|
s,
|
|
178
178
|
{
|
|
@@ -180,7 +180,7 @@ const Q = C({
|
|
|
180
180
|
icon: "MinusOutlined",
|
|
181
181
|
slot: "decrement",
|
|
182
182
|
isDisabled: i !== void 0 && r === i,
|
|
183
|
-
title:
|
|
183
|
+
title: o.formatMessage({
|
|
184
184
|
id: "unity:component:form-field:number-input:decrement:title",
|
|
185
185
|
defaultMessage: "decrement"
|
|
186
186
|
})
|
|
@@ -193,7 +193,7 @@ const Q = C({
|
|
|
193
193
|
icon: "PlusOutlined",
|
|
194
194
|
slot: "increment",
|
|
195
195
|
isDisabled: n !== void 0 && r === n,
|
|
196
|
-
title:
|
|
196
|
+
title: o.formatMessage({
|
|
197
197
|
id: "unity:component:form-field:number-input:increment:title",
|
|
198
198
|
defaultMessage: "increment"
|
|
199
199
|
})
|
|
@@ -207,8 +207,8 @@ const Q = C({
|
|
|
207
207
|
);
|
|
208
208
|
}
|
|
209
209
|
);
|
|
210
|
-
|
|
210
|
+
Q.displayName = "NumberInput";
|
|
211
211
|
export {
|
|
212
|
-
|
|
213
|
-
|
|
212
|
+
Q as NumberInput,
|
|
213
|
+
K as numberInput
|
|
214
214
|
};
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { jsx as
|
|
2
|
-
import { forwardRef as
|
|
3
|
-
import {
|
|
1
|
+
import { jsx as y } from "react/jsx-runtime";
|
|
2
|
+
import { forwardRef as m } from "react";
|
|
3
|
+
import { uyTv as t } from "@payfit/unity-themes";
|
|
4
4
|
const o = t({
|
|
5
5
|
base: "uy:min-h-dvh uy:flex uy:flex-col uy:gap-400",
|
|
6
6
|
variants: {
|
|
@@ -21,10 +21,10 @@ const o = t({
|
|
|
21
21
|
defaultVariants: {
|
|
22
22
|
variant: "default"
|
|
23
23
|
}
|
|
24
|
-
}), l =
|
|
24
|
+
}), l = m(
|
|
25
25
|
({ children: r, variant: a, ...d }, u) => {
|
|
26
26
|
const e = o({ variant: a });
|
|
27
|
-
return /* @__PURE__ */
|
|
27
|
+
return /* @__PURE__ */ y(
|
|
28
28
|
"main",
|
|
29
29
|
{
|
|
30
30
|
...d,
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
+
import { VariantProps } from '@payfit/unity-themes';
|
|
1
2
|
import { PropsWithChildren, ReactNode } from 'react';
|
|
2
|
-
import { VariantProps } from 'tailwind-variants';
|
|
3
3
|
import { BreadcrumbProps } from '../../breadcrumbs/parts/Breadcrumb.js';
|
|
4
4
|
export declare const pageHeader: import('tailwind-variants').TVReturnType<{
|
|
5
5
|
[key: string]: {
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import { jsxs as o, jsx as e } from "react/jsx-runtime";
|
|
2
2
|
import { forwardRef as p } from "react";
|
|
3
|
-
import {
|
|
4
|
-
import { Breadcrumbs as
|
|
3
|
+
import { uyTv as u } from "@payfit/unity-themes";
|
|
4
|
+
import { Breadcrumbs as n } from "../../breadcrumbs/Breadcrumbs.js";
|
|
5
5
|
import { Breadcrumb as y } from "../../breadcrumbs/parts/Breadcrumb.js";
|
|
6
|
-
const x =
|
|
6
|
+
const x = u({
|
|
7
7
|
slots: {
|
|
8
8
|
base: "uy:flex uy:flex-col uy:gap-400",
|
|
9
9
|
headingActionsWrapper: "uy:flex uy:flex-col uy:gap-400 uy:md:flex-row",
|
|
@@ -19,7 +19,7 @@ const x = n({
|
|
|
19
19
|
actions: m
|
|
20
20
|
} = x();
|
|
21
21
|
return /* @__PURE__ */ o("header", { "data-dd-privacy": "allow", ...i, ref: c, className: d(), children: [
|
|
22
|
-
r && /* @__PURE__ */ e(
|
|
22
|
+
r && /* @__PURE__ */ e(n, { items: r, wrap: "nowrap", children: (l) => /* @__PURE__ */ e(y, { href: l.href, label: l.label }) }),
|
|
23
23
|
/* @__PURE__ */ o("div", { className: f(), children: [
|
|
24
24
|
/* @__PURE__ */ e("div", { className: t(), children: s }),
|
|
25
25
|
a && /* @__PURE__ */ e("div", { className: m(), children: a })
|
|
@@ -1,21 +1,21 @@
|
|
|
1
|
-
import { jsxs as
|
|
2
|
-
import { forwardRef as
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
5
|
-
import {
|
|
6
|
-
import {
|
|
1
|
+
import { jsxs as T, jsx as o } from "react/jsx-runtime";
|
|
2
|
+
import { forwardRef as q, useRef as E, useMemo as N } from "react";
|
|
3
|
+
import { uyTv as R } from "@payfit/unity-themes";
|
|
4
|
+
import { useId as W } from "react-aria";
|
|
5
|
+
import { useIntl as $ } from "react-intl";
|
|
6
|
+
import { useOverlayTriggerState as j } from "react-stately";
|
|
7
7
|
import { usePagination as J } from "./hooks/use-pagination.js";
|
|
8
8
|
import { PaginationEllipsis as K } from "./parts/PaginationEllipsis.js";
|
|
9
9
|
import { PaginationJumpDialog as O } from "./parts/PaginationJumpDialog.js";
|
|
10
10
|
import { PaginationLink as S } from "./parts/PaginationLink.js";
|
|
11
11
|
import { PaginationNavButton as D } from "./parts/PaginationNavButton.js";
|
|
12
12
|
import { generatePaginationWithWindow as x } from "./utils/pagination-window.js";
|
|
13
|
-
const _ =
|
|
13
|
+
const _ = R({
|
|
14
14
|
slots: {
|
|
15
15
|
base: "uy:flex uy:gap-100 uy:relative",
|
|
16
16
|
pagesList: "uy:flex uy:gap-100 uy:list-none uy:m-0 uy:p-0"
|
|
17
17
|
}
|
|
18
|
-
}), z = 7, B =
|
|
18
|
+
}), z = 7, B = q(
|
|
19
19
|
({
|
|
20
20
|
pageCount: i,
|
|
21
21
|
defaultPage: p,
|
|
@@ -26,12 +26,12 @@ const _ = j({
|
|
|
26
26
|
onPreviousPress: c,
|
|
27
27
|
...A
|
|
28
28
|
}, L) => {
|
|
29
|
-
const v =
|
|
29
|
+
const v = W(), u = $(), y = d !== void 0 && g !== void 0 && p === void 0, { currentPage: s, goToPage: n } = J({
|
|
30
30
|
pageCount: i,
|
|
31
|
-
initialPage:
|
|
31
|
+
initialPage: y ? d : p,
|
|
32
32
|
onPageChange: g,
|
|
33
|
-
isControlled:
|
|
34
|
-
}), f =
|
|
33
|
+
isControlled: y
|
|
34
|
+
}), f = j({}), r = E(/* @__PURE__ */ new Map()), h = N(
|
|
35
35
|
() => x(
|
|
36
36
|
i,
|
|
37
37
|
s,
|
|
@@ -45,7 +45,7 @@ const _ = j({
|
|
|
45
45
|
const e = r.current.get(a);
|
|
46
46
|
e && e.focus();
|
|
47
47
|
});
|
|
48
|
-
},
|
|
48
|
+
}, b = (a, e) => {
|
|
49
49
|
switch (a.key) {
|
|
50
50
|
case "ArrowLeft":
|
|
51
51
|
case "ArrowUp":
|
|
@@ -90,7 +90,7 @@ const _ = j({
|
|
|
90
90
|
}
|
|
91
91
|
)
|
|
92
92
|
}, { base: I, pagesList: M } = _();
|
|
93
|
-
return /* @__PURE__ */
|
|
93
|
+
return /* @__PURE__ */ T(
|
|
94
94
|
"nav",
|
|
95
95
|
{
|
|
96
96
|
"data-dd-privacy": "allow",
|
|
@@ -136,7 +136,7 @@ const _ = j({
|
|
|
136
136
|
t && (l == null || l(a.value));
|
|
137
137
|
},
|
|
138
138
|
onKeyDown: (t) => {
|
|
139
|
-
|
|
139
|
+
b(t, a.value);
|
|
140
140
|
},
|
|
141
141
|
isActive: a.value === s,
|
|
142
142
|
value: a.value,
|
|
@@ -150,7 +150,7 @@ const _ = j({
|
|
|
150
150
|
{
|
|
151
151
|
value: a.value,
|
|
152
152
|
onKeyDown: (t) => {
|
|
153
|
-
|
|
153
|
+
b(t, -1);
|
|
154
154
|
},
|
|
155
155
|
onPress: () => {
|
|
156
156
|
f.open();
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
+
import { VariantProps } from '@payfit/unity-themes';
|
|
1
2
|
import { ButtonProps } from 'react-aria-components';
|
|
2
|
-
import { VariantProps } from 'tailwind-variants';
|
|
3
3
|
import { paginationLink } from './PaginationLink.js';
|
|
4
4
|
export interface PaginationEllipsisProps extends Omit<ButtonProps, 'value' | 'children' | 'className' | 'style' | 'slot'>, VariantProps<typeof paginationLink> {
|
|
5
5
|
value: [number, number];
|
|
@@ -1,16 +1,16 @@
|
|
|
1
|
-
import { jsxs as
|
|
1
|
+
import { jsxs as l, jsx as i } from "react/jsx-runtime";
|
|
2
2
|
import { forwardRef as r } from "react";
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
5
|
-
import {
|
|
6
|
-
const c =
|
|
3
|
+
import { uyTv as a } from "@payfit/unity-themes";
|
|
4
|
+
import { Button as y } from "react-aria-components";
|
|
5
|
+
import { useIntl as p } from "react-intl";
|
|
6
|
+
const c = a({
|
|
7
7
|
base: [
|
|
8
8
|
"uy:min-w-300 uy:h-300 uy:p-25 uy:flex uy:justify-center uy:items-center uy:typography-action uy:rounded-pill uy:cursor-default",
|
|
9
9
|
"uy:focus-visible:outline-2 uy:focus-visible:outline-solid uy:focus-visible:outline-utility-focus-ring uy:focus-visible:outline-offset-2"
|
|
10
10
|
]
|
|
11
11
|
}), f = r(({ value: s, ...e }, o) => {
|
|
12
|
-
const t =
|
|
13
|
-
return /* @__PURE__ */
|
|
12
|
+
const t = p(), [n, u] = s;
|
|
13
|
+
return /* @__PURE__ */ l(y, { ref: o, className: c(), ...e, children: [
|
|
14
14
|
/* @__PURE__ */ i("span", { "aria-hidden": !0, children: "…" }),
|
|
15
15
|
/* @__PURE__ */ i("span", { className: "uy:sr-only", children: t.formatMessage(
|
|
16
16
|
{
|
|
@@ -19,7 +19,7 @@ const c = p({
|
|
|
19
19
|
},
|
|
20
20
|
{
|
|
21
21
|
start: n,
|
|
22
|
-
end:
|
|
22
|
+
end: u
|
|
23
23
|
}
|
|
24
24
|
) })
|
|
25
25
|
] });
|
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
import { jsxs as n, Fragment as N, jsx as o } from "react/jsx-runtime";
|
|
2
2
|
import { useRef as l } from "react";
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
5
|
-
import {
|
|
3
|
+
import { uyTv as O } from "@payfit/unity-themes";
|
|
4
|
+
import { useOverlayTrigger as P, useButton as D, useOverlay as B } from "react-aria";
|
|
5
|
+
import { useIntl as I } from "react-intl";
|
|
6
6
|
import { Button as c } from "../../button/Button.js";
|
|
7
7
|
import { Icon as J } from "../../icon/Icon.js";
|
|
8
8
|
import { Label as R } from "../../label/Label.js";
|
|
9
|
-
const k =
|
|
9
|
+
const k = O({
|
|
10
10
|
slots: {
|
|
11
11
|
jumpButton: "uy:sr-only uy:outline-none uy:focus:not-sr-only uy:focus:absolute uy:focus:bottom-full uy:focus:z-10 uy:focus:m-100 uy:focus:rounded-50 uy:focus:underline uy:focus:bg-transparent uy:focus:text-content-primary uy:focus:typography-action uy:focus:ring-2 uy:focus:ring-offset-2 uy:focus:ring-utility-focus-ring",
|
|
12
12
|
jumpPopover: "uy:fixed uy:top-1/2 uy:left-1/2 uy:z-20 uy:transform uy:-translate-x-1/2 uy:-translate-y-1/2 uy:bg-surface-neutral uy:p-200 uy:rounded-200 uy:shadow-floating",
|
|
@@ -17,16 +17,16 @@ const k = I({
|
|
|
17
17
|
jumpActions: "uy:flex uy:gap-150 uy:justify-end uy:mt-100"
|
|
18
18
|
}
|
|
19
19
|
});
|
|
20
|
-
function
|
|
20
|
+
function $({
|
|
21
21
|
pageCount: t,
|
|
22
22
|
onJumpToPage: f,
|
|
23
23
|
state: e
|
|
24
24
|
}) {
|
|
25
|
-
const u =
|
|
25
|
+
const u = I(), i = l(null), p = l(null), m = l(null), { triggerProps: d } = P(
|
|
26
26
|
{ type: "dialog" },
|
|
27
27
|
e,
|
|
28
28
|
i
|
|
29
|
-
), { buttonProps: g } =
|
|
29
|
+
), { buttonProps: g } = D(
|
|
30
30
|
{
|
|
31
31
|
...d,
|
|
32
32
|
"aria-label": u.formatMessage({
|
|
@@ -35,7 +35,7 @@ function G({
|
|
|
35
35
|
})
|
|
36
36
|
},
|
|
37
37
|
i
|
|
38
|
-
), { overlayProps: a } =
|
|
38
|
+
), { overlayProps: a } = B(
|
|
39
39
|
{
|
|
40
40
|
isOpen: e.isOpen,
|
|
41
41
|
onClose: e.close.bind(e),
|
|
@@ -139,5 +139,5 @@ function G({
|
|
|
139
139
|
] });
|
|
140
140
|
}
|
|
141
141
|
export {
|
|
142
|
-
|
|
142
|
+
$ as PaginationJumpDialog
|
|
143
143
|
};
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import { jsx as r } from "react/jsx-runtime";
|
|
2
2
|
import { forwardRef as i } from "react";
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
5
|
-
import {
|
|
6
|
-
const d =
|
|
3
|
+
import { uyTv as s } from "@payfit/unity-themes";
|
|
4
|
+
import { Link as o } from "react-aria-components";
|
|
5
|
+
import { useIntl as l } from "react-intl";
|
|
6
|
+
const d = s({
|
|
7
7
|
base: [
|
|
8
8
|
"uy:min-w-300 uy:h-300 uy:p-25 uy:flex uy:justify-center uy:items-center uy:typography-action uy:rounded-pill uy:transition-colors",
|
|
9
9
|
"uy:enabled:text-content-neutral-enabled uy:enabled:bg-transparent uy:cursor-pointer",
|
|
@@ -20,9 +20,9 @@ const d = l({
|
|
|
20
20
|
}
|
|
21
21
|
}), y = i(
|
|
22
22
|
({ isActive: e, isDisabled: a, ...t }, n) => {
|
|
23
|
-
const u =
|
|
23
|
+
const u = l();
|
|
24
24
|
return /* @__PURE__ */ r(
|
|
25
|
-
|
|
25
|
+
o,
|
|
26
26
|
{
|
|
27
27
|
ref: n,
|
|
28
28
|
className: d({ isActive: e }),
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { jsxs as y, jsx as c } from "react/jsx-runtime";
|
|
2
2
|
import { forwardRef as p } from "react";
|
|
3
|
-
import {
|
|
4
|
-
import
|
|
5
|
-
const
|
|
3
|
+
import { uyTv as f } from "@payfit/unity-themes";
|
|
4
|
+
import u from "../../hooks/use-id.js";
|
|
5
|
+
const g = f({
|
|
6
6
|
slots: {
|
|
7
7
|
base: "uy:min-w-[104px] uy:aspect-[13/4]",
|
|
8
8
|
monogram: "",
|
|
@@ -29,7 +29,7 @@ const u = f({
|
|
|
29
29
|
}
|
|
30
30
|
}), Z = p(
|
|
31
31
|
({ color: l, label: n, description: a, ...r }, i) => {
|
|
32
|
-
const o =
|
|
32
|
+
const o = u(), t = `payfit-brand-title-${o}`, e = `payfit-brand-desc-${o}`, { base: h, monogram: m, logotype: s } = g({ color: l }), d = {
|
|
33
33
|
focusable: !1,
|
|
34
34
|
role: "img",
|
|
35
35
|
"aria-labelledby": t,
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { jsx as s } from "react/jsx-runtime";
|
|
2
2
|
import { forwardRef as c } from "react";
|
|
3
|
-
import {
|
|
3
|
+
import { uyTv as o } from "@payfit/unity-themes";
|
|
4
4
|
const y = o({
|
|
5
5
|
base: "uy:min-w-200 uy:max-w-400 uy:inline-flex uy:items-center uy:justify-center uy:text-center uy:typography-body-small",
|
|
6
6
|
variants: {
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import { jsx as t, jsxs as y } from "react/jsx-runtime";
|
|
2
2
|
import { forwardRef as s } from "react";
|
|
3
|
-
import {
|
|
3
|
+
import { uyTv as p } from "@payfit/unity-themes";
|
|
4
|
+
import { Popover as g, Dialog as m, DialogTrigger as c } from "react-aria-components";
|
|
4
5
|
import { DialogTrigger as j } from "react-aria-components";
|
|
5
|
-
import { tv as c } from "tailwind-variants";
|
|
6
6
|
import { PopoverHeader as f } from "./parts/PopoverHeader.js";
|
|
7
|
-
const x =
|
|
7
|
+
const x = p({
|
|
8
8
|
slots: {
|
|
9
9
|
base: [
|
|
10
10
|
"uy:border uy:border-solid uy:border-border-neutral uy:bg-surface-neutral uy:rounded-200 uy:p-200 uy:shadow-floating uy:min-w-[320px] uy:max-w-[800px] uy:overflow-auto",
|
|
@@ -21,7 +21,7 @@ const x = c({
|
|
|
21
21
|
}
|
|
22
22
|
}), b = s((a, e) => {
|
|
23
23
|
const { children: o, title: r, isTitleSrOnly: n, displayCloseButton: i, ...l } = a, { base: u, dialog: d } = x();
|
|
24
|
-
return /* @__PURE__ */ t(
|
|
24
|
+
return /* @__PURE__ */ t(g, { ref: e, className: u(), offset: 8, ...l, children: /* @__PURE__ */ y(m, { className: d(), role: "dialog", children: [
|
|
25
25
|
/* @__PURE__ */ t(
|
|
26
26
|
f,
|
|
27
27
|
{
|
|
@@ -34,7 +34,7 @@ const x = c({
|
|
|
34
34
|
] }) });
|
|
35
35
|
});
|
|
36
36
|
b.displayName = "Popover";
|
|
37
|
-
|
|
37
|
+
c.displayName = "PopoverTrigger";
|
|
38
38
|
export {
|
|
39
39
|
b as Popover,
|
|
40
40
|
j as PopoverTrigger
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import { jsxs as m, jsx as o } from "react/jsx-runtime";
|
|
2
|
-
import { forwardRef as u, useContext as
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
5
|
-
import {
|
|
2
|
+
import { forwardRef as u, useContext as y } from "react";
|
|
3
|
+
import { uyTv as d } from "@payfit/unity-themes";
|
|
4
|
+
import { OverlayTriggerStateContext as p, Heading as f } from "react-aria-components";
|
|
5
|
+
import { useIntl as g } from "react-intl";
|
|
6
6
|
import { IconButton as h } from "../../icon-button/IconButton.js";
|
|
7
|
-
const v =
|
|
7
|
+
const v = d({
|
|
8
8
|
slots: {
|
|
9
9
|
base: "uy:flex uy:justify-between",
|
|
10
10
|
heading: "uy:content-center",
|
|
@@ -23,10 +23,10 @@ const v = g({
|
|
|
23
23
|
}
|
|
24
24
|
}), b = u(
|
|
25
25
|
({ title: t, isTitleSrOnly: n, displayCloseButton: a }, r) => {
|
|
26
|
-
const e =
|
|
26
|
+
const e = y(p), s = g(), { base: l, heading: i, iconButton: c } = v({ isTitleSrOnly: n });
|
|
27
27
|
return /* @__PURE__ */ m("div", { className: l(), children: [
|
|
28
28
|
/* @__PURE__ */ o(
|
|
29
|
-
|
|
29
|
+
f,
|
|
30
30
|
{
|
|
31
31
|
ref: r,
|
|
32
32
|
slot: "title",
|