@povio/ui 3.1.0 → 3.2.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.
- package/dist/assets/icons/AlignCenter.js +26 -11
- package/dist/assets/icons/AlignLeft.js +26 -11
- package/dist/assets/icons/AlignLeftRight.js +26 -11
- package/dist/assets/icons/AlignRight.js +26 -11
- package/dist/assets/icons/ArrowDropDown.js +26 -11
- package/dist/assets/icons/ArrowDropUp.js +26 -11
- package/dist/assets/icons/ArrowLeft.js +26 -11
- package/dist/assets/icons/ArrowRight.js +26 -11
- package/dist/assets/icons/Bold.js +26 -11
- package/dist/assets/icons/BulletedList.js +26 -11
- package/dist/assets/icons/Calendar.js +28 -13
- package/dist/assets/icons/Check.js +28 -13
- package/dist/assets/icons/CheckCircle.js +26 -11
- package/dist/assets/icons/CheckboxCheckmark.js +29 -14
- package/dist/assets/icons/CheckboxIndeterminate.js +29 -14
- package/dist/assets/icons/ChevronDown.js +28 -13
- package/dist/assets/icons/ChevronLeft.js +28 -13
- package/dist/assets/icons/ChevronRight.js +28 -13
- package/dist/assets/icons/ChevronUp.js +28 -13
- package/dist/assets/icons/ChevronsLeft.js +28 -13
- package/dist/assets/icons/ChevronsRight.js +28 -13
- package/dist/assets/icons/Clock.js +26 -11
- package/dist/assets/icons/Close.js +26 -11
- package/dist/assets/icons/DateTime.js +35 -14
- package/dist/assets/icons/DragIndicator.js +26 -11
- package/dist/assets/icons/File.js +28 -13
- package/dist/assets/icons/Highlight.js +26 -11
- package/dist/assets/icons/HighlightOn.js +49 -15
- package/dist/assets/icons/Home.js +26 -11
- package/dist/assets/icons/Info.js +37 -16
- package/dist/assets/icons/Italic.js +26 -11
- package/dist/assets/icons/Link.js +26 -11
- package/dist/assets/icons/Menu.js +26 -11
- package/dist/assets/icons/NumberedList.js +26 -11
- package/dist/assets/icons/PointerHorizontal.js +26 -11
- package/dist/assets/icons/PointerVertical.js +26 -11
- package/dist/assets/icons/Search.js +26 -11
- package/dist/assets/icons/Send.js +28 -13
- package/dist/assets/icons/Strikethrough.js +26 -11
- package/dist/assets/icons/TextColor.js +48 -14
- package/dist/assets/icons/Today.js +26 -11
- package/dist/assets/icons/Underlined.js +28 -13
- package/dist/assets/icons/Upload.js +35 -14
- package/dist/assets/icons/Visibility.js +26 -11
- package/dist/assets/icons/VisibilityOff.js +26 -11
- package/dist/assets/icons/WarningFilled.js +28 -13
- package/dist/components/Breadcrumbs/Breadcrumbs.js +207 -56
- package/dist/components/Menu/Menu.js +18 -2
- package/dist/components/Menu/MenuDesktop.js +41 -7
- package/dist/components/Menu/MenuItem.js +32 -9
- package/dist/components/Menu/MenuMobile.js +102 -39
- package/dist/components/Menu/MenuPopover.js +105 -29
- package/dist/components/buttons/Button/button.cva.d.ts +3 -3
- package/dist/components/buttons/IconButton/IconButton.js +40 -8
- package/dist/components/buttons/InlineIconButton/InlineIconButton.d.ts +2 -1
- package/dist/components/buttons/InlineIconButton/InlineIconButton.js +34 -9
- package/dist/components/buttons/PillButton/PillButton.js +55 -17
- package/dist/components/buttons/PillButton/pillButton.cva.d.ts +1 -1
- package/dist/components/buttons/SplitButton/SplitButton.js +103 -18
- package/dist/components/buttons/TextButton/TextButton.js +30 -8
- package/dist/components/buttons/ToggleButton/ToggleButton.js +28 -8
- package/dist/components/buttons/shared/ButtonContent.js +80 -22
- package/dist/components/inputs/Checkbox/Checkbox.d.ts +1 -0
- package/dist/components/inputs/Checkbox/Checkbox.js +201 -35
- package/dist/components/inputs/Checkbox/CheckboxCheckmark.js +24 -10
- package/dist/components/inputs/Checkbox/checkbox.cva.d.ts +3 -0
- package/dist/components/inputs/Checkbox/checkbox.cva.js +2 -1
- package/dist/components/inputs/DateTime/DatePicker/DatePicker.d.ts +12 -5
- package/dist/components/inputs/DateTime/DatePicker/DatePicker.js +380 -75
- package/dist/components/inputs/DateTime/DateRangePicker/DateRangePicker.d.ts +12 -5
- package/dist/components/inputs/DateTime/DateRangePicker/DateRangePicker.js +499 -186
- package/dist/components/inputs/DateTime/DateTimePicker/DateTimePicker.d.ts +14 -5
- package/dist/components/inputs/DateTime/DateTimePicker/DateTimePicker.js +280 -46
- package/dist/components/inputs/DateTime/TimePicker/TimePicker.d.ts +7 -3
- package/dist/components/inputs/DateTime/TimePicker/TimePicker.js +616 -121
- package/dist/components/inputs/DateTime/shared/Calendar.d.ts +5 -2
- package/dist/components/inputs/DateTime/shared/Calendar.js +342 -119
- package/dist/components/inputs/DateTime/shared/CalendarCell.d.ts +4 -2
- package/dist/components/inputs/DateTime/shared/CalendarCell.js +310 -103
- package/dist/components/inputs/DateTime/shared/CalendarGrid.d.ts +4 -2
- package/dist/components/inputs/DateTime/shared/CalendarGrid.js +150 -33
- package/dist/components/inputs/DateTime/shared/CalendarHeader.js +233 -98
- package/dist/components/inputs/DateTime/shared/CalendarSelectHeader.js +318 -137
- package/dist/components/inputs/DateTime/shared/DateField.d.ts +2 -1
- package/dist/components/inputs/DateTime/shared/DateField.js +288 -112
- package/dist/components/inputs/DateTime/shared/DatePickerInput.d.ts +14 -3
- package/dist/components/inputs/DateTime/shared/DatePickerInput.js +359 -129
- package/dist/components/inputs/DateTime/shared/DateSegmentItem.d.ts +18 -1
- package/dist/components/inputs/DateTime/shared/DateSegmentItem.js +104 -11
- package/dist/components/inputs/DateTime/shared/DateTimeDialog.js +83 -28
- package/dist/components/inputs/DateTime/shared/DateTimeDialogFooter.js +59 -10
- package/dist/components/inputs/DateTime/shared/MonthPicker.js +103 -58
- package/dist/components/inputs/DateTime/shared/RangeCalendar.js +193 -82
- package/dist/components/inputs/DateTime/shared/TimeField.js +27 -8
- package/dist/components/inputs/DateTime/shared/TimePickerForm.js +279 -110
- package/dist/components/inputs/DateTime/shared/TimePickerInput.d.ts +4 -1
- package/dist/components/inputs/DateTime/shared/TimePickerInput.js +211 -65
- package/dist/components/inputs/DateTime/shared/YearPicker.js +119 -68
- package/dist/components/inputs/DateTime/shared/datePicker.types.d.ts +5 -0
- package/dist/components/inputs/DateTime/shared/datePickerInput.cva.d.ts +16 -0
- package/dist/components/inputs/DateTime/shared/datePickerInput.cva.js +16 -0
- package/dist/components/inputs/DateTime/shared/datePickerTodayIcon.d.ts +15 -0
- package/dist/components/inputs/DateTime/shared/datePickerTodayIcon.js +32 -0
- package/dist/components/inputs/DateTime/shared/dateSegment.utils.d.ts +2 -0
- package/dist/components/inputs/DateTime/shared/dateSegment.utils.spec.d.ts +1 -0
- package/dist/components/inputs/DateTime/shared/staticDateTimeSegments.d.ts +41 -0
- package/dist/components/inputs/DateTime/shared/staticDateTimeSegments.js +99 -0
- package/dist/components/inputs/DateTime/shared/staticDateTimeSegments.spec.d.ts +1 -0
- package/dist/components/inputs/File/FileUpload.js +91 -46
- package/dist/components/inputs/File/FileUploadContainer.js +15 -7
- package/dist/components/inputs/File/InputUpload.js +317 -79
- package/dist/components/inputs/File/index.d.ts +1 -1
- package/dist/components/inputs/File/shared/FileCard.js +104 -41
- package/dist/components/inputs/File/shared/FileCardList.js +47 -12
- package/dist/components/inputs/File/shared/FileUploadContent.js +175 -44
- package/dist/components/inputs/File/shared/FileUploadContentEmpty.js +149 -46
- package/dist/components/inputs/File/shared/FileUploadContentError.js +234 -93
- package/dist/components/inputs/File/shared/FileUploadContentFilled.js +230 -97
- package/dist/components/inputs/File/shared/FileUploadContentLoading.js +199 -55
- package/dist/components/inputs/File/shared/InputUploadContent.js +148 -34
- package/dist/components/inputs/File/shared/InputUploadFilled.js +49 -8
- package/dist/components/inputs/File/shared/ProgressBar.js +102 -15
- package/dist/components/inputs/File/shared/fileUpload.cva.d.ts +0 -11
- package/dist/components/inputs/File/shared/fileUpload.cva.js +1 -18
- package/dist/components/inputs/FormField/FormField.d.ts +3 -3
- package/dist/components/inputs/FormField/FormField.js +119 -37
- package/dist/components/inputs/FormField/FormFieldError.js +25 -5
- package/dist/components/inputs/FormField/FormFieldHeader.d.ts +2 -2
- package/dist/components/inputs/FormField/FormFieldHeader.js +81 -22
- package/dist/components/inputs/FormField/FormFieldHeaderClose.js +31 -7
- package/dist/components/inputs/FormField/FormFieldHelper.js +26 -6
- package/dist/components/inputs/FormField/FormFieldLabel.d.ts +2 -2
- package/dist/components/inputs/FormField/FormFieldLabel.js +40 -9
- package/dist/components/inputs/FormField/formFieldHeader.cva.d.ts +13 -0
- package/dist/components/inputs/FormField/formFieldHeader.cva.js +14 -0
- package/dist/components/inputs/Input/NumberInput/NumberInput.d.ts +5 -2
- package/dist/components/inputs/Input/NumberInput/NumberInput.js +446 -97
- package/dist/components/inputs/Input/NumberRangeInput/NumberRangeField.d.ts +45 -0
- package/dist/components/inputs/Input/NumberRangeInput/NumberRangeField.js +571 -0
- package/dist/components/inputs/Input/NumberRangeInput/NumberRangeInput.d.ts +35 -0
- package/dist/components/inputs/Input/NumberRangeInput/NumberRangeInput.js +574 -0
- package/dist/components/inputs/Input/PasswordInput/PasswordInput.js +48 -9
- package/dist/components/inputs/Input/TextArea/TextArea.cva.d.ts +8 -0
- package/dist/components/inputs/Input/TextArea/TextArea.cva.js +5 -0
- package/dist/components/inputs/Input/TextArea/TextArea.js +305 -90
- package/dist/components/inputs/Input/TextInput/TextInput.d.ts +3 -1
- package/dist/components/inputs/Input/TextInput/TextInput.js +429 -90
- package/dist/components/inputs/Input/shared/InputContent.js +193 -59
- package/dist/components/inputs/Input/shared/numberStatic.utils.d.ts +1 -0
- package/dist/components/inputs/Input/shared/numberStatic.utils.js +7 -0
- package/dist/components/inputs/Inputs/Form.js +40 -11
- package/dist/components/inputs/Inputs/InputItem.d.ts +15 -21
- package/dist/components/inputs/Inputs/InputItem.js +69 -14
- package/dist/components/inputs/Inputs/Inputs.js +37 -11
- package/dist/components/inputs/RadioGroup/RadioGroup.d.ts +3 -1
- package/dist/components/inputs/RadioGroup/RadioGroup.js +353 -61
- package/dist/components/inputs/RadioGroup/radio.cva.d.ts +45 -0
- package/dist/components/inputs/RadioGroup/radio.cva.js +48 -1
- package/dist/components/inputs/Selection/Autocomplete/Autocomplete.d.ts +6 -2
- package/dist/components/inputs/Selection/Autocomplete/Autocomplete.js +217 -22
- package/dist/components/inputs/Selection/Autocomplete/QueryAutocomplete.d.ts +3 -18
- package/dist/components/inputs/Selection/Autocomplete/QueryAutocomplete.js +107 -8
- package/dist/components/inputs/Selection/Autocomplete/queryAutocomplete.types.d.ts +37 -0
- package/dist/components/inputs/Selection/Select/QuerySelect.d.ts +14 -0
- package/dist/components/inputs/Selection/Select/QuerySelect.js +178 -0
- package/dist/components/inputs/Selection/Select/Select.d.ts +7 -3
- package/dist/components/inputs/Selection/Select/Select.js +227 -18
- package/dist/components/inputs/Selection/shared/SelectBase.d.ts +8 -1
- package/dist/components/inputs/Selection/shared/SelectBase.js +69 -18
- package/dist/components/inputs/Selection/shared/SelectDesktop.d.ts +1 -1
- package/dist/components/inputs/Selection/shared/SelectDesktop.js +393 -138
- package/dist/components/inputs/Selection/shared/SelectInput.d.ts +2 -2
- package/dist/components/inputs/Selection/shared/SelectInput.js +397 -116
- package/dist/components/inputs/Selection/shared/SelectInputTags.js +99 -25
- package/dist/components/inputs/Selection/shared/SelectListBox.d.ts +2 -2
- package/dist/components/inputs/Selection/shared/SelectListBox.js +164 -52
- package/dist/components/inputs/Selection/shared/SelectListBoxItem.js +85 -35
- package/dist/components/inputs/Selection/shared/SelectListBoxItemSelectAll.js +69 -16
- package/dist/components/inputs/Selection/shared/SelectListBoxLoadingItem.js +70 -21
- package/dist/components/inputs/Selection/shared/SelectListBoxSelectionBar.js +58 -9
- package/dist/components/inputs/Selection/shared/SelectMobile.d.ts +1 -1
- package/dist/components/inputs/Selection/shared/SelectMobile.js +9 -3
- package/dist/components/inputs/Selection/shared/StaticSelectTrailingContent.d.ts +9 -0
- package/dist/components/inputs/Selection/shared/StaticSelectTrailingContent.js +47 -0
- package/dist/components/inputs/Selection/shared/querySelect.utils.d.ts +14 -0
- package/dist/components/inputs/Selection/shared/querySelect.utils.js +43 -0
- package/dist/components/inputs/Selection/shared/select.context.d.ts +3 -2
- package/dist/components/inputs/Selection/shared/select.context.js +67 -36
- package/dist/components/inputs/Selection/shared/select.types.d.ts +3 -2
- package/dist/components/inputs/Selection/shared/selectDesktop.cva.d.ts +6 -0
- package/dist/components/inputs/Selection/shared/selectDesktop.cva.js +5 -0
- package/dist/components/inputs/Selection/shared/selectInput.cva.d.ts +12 -0
- package/dist/components/inputs/Selection/shared/selectInput.cva.js +8 -0
- package/dist/components/inputs/Selection/shared/staticSelect.utils.d.ts +23 -0
- package/dist/components/inputs/Selection/shared/staticSelect.utils.js +54 -0
- package/dist/components/inputs/Selection/shared/staticSelect.utils.spec.d.ts +1 -0
- package/dist/components/inputs/Selection/shared/useSelectItems.js +109 -49
- package/dist/components/inputs/Skeleton/InputFrame.d.ts +83 -0
- package/dist/components/inputs/Skeleton/InputFrame.js +612 -0
- package/dist/components/inputs/Slider/Slider.d.ts +2 -1
- package/dist/components/inputs/Slider/Slider.js +265 -76
- package/dist/components/inputs/TextEditor/TextEditor.d.ts +1 -0
- package/dist/components/inputs/TextEditor/TextEditor.js +447 -98
- package/dist/components/inputs/TextEditor/Toolbar/ColorPicker.js +37 -11
- package/dist/components/inputs/TextEditor/Toolbar/ColorPickerDropdown.js +102 -30
- package/dist/components/inputs/TextEditor/Toolbar/HyperlinkAction.js +194 -45
- package/dist/components/inputs/TextEditor/Toolbar/TextAlignSelect.js +88 -28
- package/dist/components/inputs/TextEditor/Toolbar/TextColorSelect.js +48 -14
- package/dist/components/inputs/TextEditor/Toolbar/TextEditorToolbar.js +66 -19
- package/dist/components/inputs/TextEditor/Toolbar/TextHighlightSelect.js +49 -15
- package/dist/components/inputs/TextEditor/Toolbar/TextListActions.js +92 -32
- package/dist/components/inputs/TextEditor/Toolbar/TextMarksActions.js +126 -54
- package/dist/components/inputs/TextEditor/Toolbar/TextStyleSelect.js +141 -38
- package/dist/components/inputs/Toggle/Toggle.d.ts +1 -0
- package/dist/components/inputs/Toggle/Toggle.js +214 -37
- package/dist/components/inputs/Toggle/toggle.cva.d.ts +3 -0
- package/dist/components/inputs/Toggle/toggle.cva.js +2 -1
- package/dist/components/inputs/shared/CheckContent.d.ts +2 -1
- package/dist/components/inputs/shared/CheckContent.js +21 -11
- package/dist/components/inputs/shared/InputClear.d.ts +2 -1
- package/dist/components/inputs/shared/InputClear.js +88 -12
- package/dist/components/inputs/shared/TooltipWrapper.js +50 -11
- package/dist/components/inputs/shared/input.cva.d.ts +28 -0
- package/dist/components/inputs/shared/input.cva.js +38 -4
- package/dist/components/inputs/shared/tooltipWrapper.cva.d.ts +8 -0
- package/dist/components/inputs/shared/tooltipWrapper.cva.js +5 -0
- package/dist/components/inputs/shared/useStaticInputHandoff.d.ts +15 -0
- package/dist/components/inputs/shared/useStaticInputHandoff.js +112 -0
- package/dist/components/navigation/Accordion/Accordion.js +69 -22
- package/dist/components/navigation/Accordion/AccordionItem.js +86 -41
- package/dist/components/navigation/Stepper/Stepper.js +67 -22
- package/dist/components/navigation/Stepper/StepperItem.js +104 -31
- package/dist/components/navigation/Stepper/StepperSeparator.js +23 -5
- package/dist/components/overlays/ActionModal/ActionModal.js +169 -35
- package/dist/components/overlays/BottomSheet/BottomSheet.js +96 -23
- package/dist/components/overlays/BottomSheet/BottomSheetHeader.js +48 -8
- package/dist/components/overlays/Drawer/Drawer.js +62 -20
- package/dist/components/overlays/ResponsivePopover/ResponsivePopover.js +85 -28
- package/dist/components/overlays/Tooltip/Tooltip.js +137 -28
- package/dist/components/overlays/Tooltip/TooltipEllipsis.js +37 -12
- package/dist/components/segment/Segment.js +218 -57
- package/dist/components/segment/SegmentItem.js +67 -10
- package/dist/components/shared/pagination/Pagination.js +108 -22
- package/dist/components/shared/pagination/PaginationList.js +167 -64
- package/dist/components/shared/pagination/minWidth.cva.d.ts +1 -1
- package/dist/components/status/Alert/Alert.js +97 -30
- package/dist/components/status/Loader/Loader.js +77 -22
- package/dist/components/status/Toast/Toast.js +28 -14
- package/dist/components/status/Toast/toast.cva.d.ts +1 -1
- package/dist/components/status/Toast/useToast.js +62 -57
- package/dist/components/table/ColumnConfig.js +158 -54
- package/dist/components/table/InfiniteTable.js +67 -16
- package/dist/components/table/PaginatedTable.js +84 -18
- package/dist/components/table/Table.js +28 -27
- package/dist/components/text/Link/Link.js +19 -7
- package/dist/components/text/Typography/Typography.js +23 -8
- package/dist/config/confirmation.context.js +1 -1
- package/dist/config/link.context.js +23 -9
- package/dist/config/router.context.js +42 -16
- package/dist/config/theme.context.js +98 -45
- package/dist/config/uiConfig.context.d.ts +20 -6
- package/dist/config/uiConfig.context.js +68 -14
- package/dist/config/uiOverrides.context.d.ts +30 -11
- package/dist/config/uiOverrides.context.js +54 -14
- package/dist/helpers/dynamicInputs.d.ts +12 -9
- package/dist/helpers/dynamicInputs.js +13 -8
- package/dist/hooks/useAutosave.d.ts +2 -1
- package/dist/hooks/useAutosave.js +12 -4
- package/dist/hooks/useAutosave.spec.d.ts +1 -0
- package/dist/hooks/useBreakpoint.js +16 -3
- package/dist/hooks/useDebounceCallback.js +51 -17
- package/dist/hooks/useFilters.js +125 -64
- package/dist/hooks/useForm.js +42 -8
- package/dist/hooks/useFormAutosave.d.ts +3 -1
- package/dist/hooks/useFormAutosave.js +122 -30
- package/dist/hooks/useFormAutosave.spec.d.ts +1 -0
- package/dist/hooks/useIntersectionObserver.d.ts +1 -1
- package/dist/hooks/useIntersectionObserver.js +91 -24
- package/dist/hooks/useKeyInteractions.d.ts +20 -0
- package/dist/hooks/useKeyInteractions.js +54 -0
- package/dist/hooks/useKeyInteractions.spec.d.ts +1 -0
- package/dist/hooks/useLocalStorage.js +43 -10
- package/dist/hooks/useLongPressRepeat.js +55 -20
- package/dist/hooks/usePagination.js +49 -19
- package/dist/hooks/useQueryAutocomplete.d.ts +14 -0
- package/dist/hooks/useQueryAutocomplete.js +72 -0
- package/dist/hooks/useScrollableListBox.js +37 -16
- package/dist/hooks/useSorting.js +69 -28
- package/dist/hooks/useStateAndRef.js +21 -7
- package/dist/hooks/useTableColumnConfig.js +124 -31
- package/dist/hooks/useTranslationMemo.js +25 -5
- package/dist/index.d.ts +18 -3
- package/dist/index.js +15 -5
- package/dist/tw-ui-plugin.js +6 -0
- package/dist/utils/date-time.utils.d.ts +38 -10
- package/dist/utils/date-time.utils.js +136 -22
- package/dist/utils/query.utils.d.ts +4 -0
- package/dist/utils/query.utils.js +8 -0
- package/dist/utils/zod.utils.d.ts +2 -0
- package/dist/utils/zod.utils.js +5 -0
- package/package.json +2 -2
|
@@ -5,107 +5,248 @@ import { InlineIconButton } from "../../../buttons/InlineIconButton/InlineIconBu
|
|
|
5
5
|
import "../../../../config/i18n.js";
|
|
6
6
|
import { TextButton } from "../../../buttons/TextButton/TextButton.js";
|
|
7
7
|
import { WarningFilledIcon } from "../../../../assets/icons/WarningFilled.js";
|
|
8
|
+
import { c } from "react/compiler-runtime";
|
|
8
9
|
import { Fragment, jsx, jsxs } from "react/jsx-runtime";
|
|
9
10
|
import { clsx } from "clsx";
|
|
10
11
|
import { FileTrigger } from "react-aria-components";
|
|
11
12
|
import { useTranslation } from "react-i18next";
|
|
12
13
|
//#region src/components/inputs/File/shared/FileUploadContentError.tsx
|
|
13
|
-
var FileUploadContentError = (
|
|
14
|
+
var FileUploadContentError = (t0) => {
|
|
15
|
+
const $ = c(52);
|
|
16
|
+
const { variant, as, isDisabled, state, browseText, fileTriggerProps, removeWithIcon: t1, singleFile, onRemove } = t0;
|
|
17
|
+
const removeWithIcon = t1 === void 0 ? false : t1;
|
|
14
18
|
const { t } = useTranslation("ui");
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
19
|
+
let t2;
|
|
20
|
+
if ($[0] === Symbol.for("react.memo_cache_sentinel")) {
|
|
21
|
+
t2 = clsx("flex w-full flex-fill flex-col items-start");
|
|
22
|
+
$[0] = t2;
|
|
23
|
+
} else t2 = $[0];
|
|
24
|
+
const t3 = variant === "horizontal";
|
|
25
|
+
const t4 = variant === "vertical";
|
|
26
|
+
const t5 = variant === "vertical" && as === "button";
|
|
27
|
+
const t6 = variant === "vertical" && as === "link";
|
|
28
|
+
let t7;
|
|
29
|
+
if ($[1] !== t3 || $[2] !== t4 || $[3] !== t5 || $[4] !== t6) {
|
|
30
|
+
t7 = clsx("flex w-full items-center", {
|
|
31
|
+
"flex-row gap-file-upload-content-gap-left-to-right-content": t3,
|
|
32
|
+
"flex-col": t4,
|
|
33
|
+
"gap-file-upload-content-gap-content-to-button": t5,
|
|
34
|
+
"gap-file-upload-content-gap-text-to-text": t6
|
|
35
|
+
});
|
|
36
|
+
$[1] = t3;
|
|
37
|
+
$[2] = t4;
|
|
38
|
+
$[3] = t5;
|
|
39
|
+
$[4] = t6;
|
|
40
|
+
$[5] = t7;
|
|
41
|
+
} else t7 = $[5];
|
|
42
|
+
const t8 = variant === "vertical";
|
|
43
|
+
const t9 = variant === "horizontal";
|
|
44
|
+
let t10;
|
|
45
|
+
if ($[6] !== isDisabled || $[7] !== t8 || $[8] !== t9) {
|
|
46
|
+
t10 = clsx("flex min-w-0 max-w-full flex-grow items-center gap-file-upload-content-gap-icon-to-content", {
|
|
47
|
+
"flex-col": t8,
|
|
48
|
+
"flex-row": t9,
|
|
49
|
+
"opacity-50": isDisabled
|
|
50
|
+
});
|
|
51
|
+
$[6] = isDisabled;
|
|
52
|
+
$[7] = t8;
|
|
53
|
+
$[8] = t9;
|
|
54
|
+
$[9] = t10;
|
|
55
|
+
} else t10 = $[9];
|
|
56
|
+
let t11;
|
|
57
|
+
if ($[10] === Symbol.for("react.memo_cache_sentinel")) {
|
|
58
|
+
t11 = /* @__PURE__ */ jsx(WarningFilledIcon, { className: "h-6 w-6 text-elevation-fill-warning-1" });
|
|
59
|
+
$[10] = t11;
|
|
60
|
+
} else t11 = $[10];
|
|
61
|
+
const t12 = variant === "vertical";
|
|
62
|
+
const t13 = variant === "horizontal";
|
|
63
|
+
let t14;
|
|
64
|
+
if ($[11] !== t12 || $[12] !== t13) {
|
|
65
|
+
t14 = clsx("flex flex-col gap-file-upload-content-gap-text-to-text", {
|
|
66
|
+
"max-w-full items-center": t12,
|
|
67
|
+
"max-w-[calc(100%_-_32px)]": t13
|
|
68
|
+
});
|
|
69
|
+
$[11] = t12;
|
|
70
|
+
$[12] = t13;
|
|
71
|
+
$[13] = t14;
|
|
72
|
+
} else t14 = $[13];
|
|
73
|
+
const t15 = variant === "vertical";
|
|
74
|
+
let t16;
|
|
75
|
+
if ($[14] !== t15) {
|
|
76
|
+
t16 = clsx("self-stretch truncate text-text-default-1", { "text-center": t15 });
|
|
77
|
+
$[14] = t15;
|
|
78
|
+
$[15] = t16;
|
|
79
|
+
} else t16 = $[15];
|
|
80
|
+
const t17 = state.file?.name ?? state.displayName ?? "";
|
|
81
|
+
let t18;
|
|
82
|
+
if ($[16] !== t16 || $[17] !== t17) {
|
|
83
|
+
t18 = /* @__PURE__ */ jsx(Typography, {
|
|
84
|
+
variant: "prominent-1",
|
|
85
|
+
size: "label-1",
|
|
86
|
+
as: "span",
|
|
87
|
+
className: t16,
|
|
88
|
+
children: t17
|
|
89
|
+
});
|
|
90
|
+
$[16] = t16;
|
|
91
|
+
$[17] = t17;
|
|
92
|
+
$[18] = t18;
|
|
93
|
+
} else t18 = $[18];
|
|
94
|
+
const t19 = singleFile ? "label-2" : "label-3";
|
|
95
|
+
const t20 = variant === "vertical";
|
|
96
|
+
let t21;
|
|
97
|
+
if ($[19] !== t20) {
|
|
98
|
+
t21 = clsx("text-text-default-2", { "text-center": t20 });
|
|
99
|
+
$[19] = t20;
|
|
100
|
+
$[20] = t21;
|
|
101
|
+
} else t21 = $[20];
|
|
102
|
+
const t22 = state.error?.serverMessage ?? state.error?.message;
|
|
103
|
+
let t23;
|
|
104
|
+
if ($[21] !== t19 || $[22] !== t21 || $[23] !== t22) {
|
|
105
|
+
t23 = /* @__PURE__ */ jsx(Typography, {
|
|
106
|
+
variant: "default",
|
|
107
|
+
size: t19,
|
|
108
|
+
as: "span",
|
|
109
|
+
className: t21,
|
|
110
|
+
children: t22
|
|
111
|
+
});
|
|
112
|
+
$[21] = t19;
|
|
113
|
+
$[22] = t21;
|
|
114
|
+
$[23] = t22;
|
|
115
|
+
$[24] = t23;
|
|
116
|
+
} else t23 = $[24];
|
|
117
|
+
let t24;
|
|
118
|
+
if ($[25] !== t14 || $[26] !== t18 || $[27] !== t23) {
|
|
119
|
+
t24 = /* @__PURE__ */ jsxs("div", {
|
|
120
|
+
className: t14,
|
|
121
|
+
children: [t18, t23]
|
|
122
|
+
});
|
|
123
|
+
$[25] = t14;
|
|
124
|
+
$[26] = t18;
|
|
125
|
+
$[27] = t23;
|
|
126
|
+
$[28] = t24;
|
|
127
|
+
} else t24 = $[28];
|
|
128
|
+
let t25;
|
|
129
|
+
if ($[29] !== t10 || $[30] !== t24) {
|
|
130
|
+
t25 = /* @__PURE__ */ jsxs("div", {
|
|
131
|
+
className: t10,
|
|
132
|
+
children: [t11, t24]
|
|
133
|
+
});
|
|
134
|
+
$[29] = t10;
|
|
135
|
+
$[30] = t24;
|
|
136
|
+
$[31] = t25;
|
|
137
|
+
} else t25 = $[31];
|
|
138
|
+
const t26 = variant === "vertical" && as === "button";
|
|
139
|
+
const t27 = as === "link";
|
|
140
|
+
const t28 = as === "button";
|
|
141
|
+
let t29;
|
|
142
|
+
if ($[32] !== t26 || $[33] !== t27 || $[34] !== t28) {
|
|
143
|
+
t29 = clsx("flex flex-none items-center justify-end", {
|
|
144
|
+
"flex-col": t26,
|
|
145
|
+
"gap-file-upload-content-gap-text-to-text": t27,
|
|
146
|
+
"gap-file-upload-content-gap-content-to-button": t28
|
|
147
|
+
});
|
|
148
|
+
$[32] = t26;
|
|
149
|
+
$[33] = t27;
|
|
150
|
+
$[34] = t28;
|
|
151
|
+
$[35] = t29;
|
|
152
|
+
} else t29 = $[35];
|
|
153
|
+
let t30;
|
|
154
|
+
if ($[36] !== as || $[37] !== browseText || $[38] !== fileTriggerProps || $[39] !== isDisabled || $[40] !== onRemove || $[41] !== removeWithIcon || $[42] !== state.id || $[43] !== t) {
|
|
155
|
+
t30 = as === "link" ? /* @__PURE__ */ jsxs(Fragment, { children: [fileTriggerProps && /* @__PURE__ */ jsxs(Fragment, { children: [/* @__PURE__ */ jsx(FileTrigger, {
|
|
156
|
+
...fileTriggerProps,
|
|
157
|
+
children: /* @__PURE__ */ jsx(TextButton, {
|
|
158
|
+
className: "text-interactive-text-primary-idle",
|
|
159
|
+
children: browseText ?? ""
|
|
160
|
+
})
|
|
161
|
+
}), /* @__PURE__ */ jsx(Typography, {
|
|
162
|
+
variant: "default",
|
|
163
|
+
size: "label-2",
|
|
164
|
+
as: "span",
|
|
165
|
+
className: "text-text-default-2",
|
|
166
|
+
children: t(_temp)
|
|
167
|
+
})] }), removeWithIcon ? /* @__PURE__ */ jsx(InlineIconButton, {
|
|
168
|
+
label: "Cancel",
|
|
169
|
+
color: "secondary",
|
|
170
|
+
onPress: () => {
|
|
171
|
+
onRemove(state.id ?? "");
|
|
172
|
+
},
|
|
173
|
+
icon: CloseIcon
|
|
174
|
+
}) : /* @__PURE__ */ jsx(TextButton, {
|
|
175
|
+
className: "text-interactive-text-primary-idle lowercase",
|
|
176
|
+
onPress: () => {
|
|
177
|
+
onRemove(state.id ?? "");
|
|
178
|
+
},
|
|
179
|
+
children: t(_temp2)
|
|
180
|
+
})] }) : /* @__PURE__ */ jsxs("div", {
|
|
181
|
+
className: "flex items-center justify-center gap-file-upload-content-gap-button-to-button self-stretch",
|
|
182
|
+
children: [fileTriggerProps && /* @__PURE__ */ jsx(FileTrigger, {
|
|
183
|
+
...fileTriggerProps,
|
|
184
|
+
children: /* @__PURE__ */ jsx(Button$1, {
|
|
185
|
+
variant: "outlined",
|
|
186
|
+
size: "xs",
|
|
187
|
+
width: "hug",
|
|
188
|
+
isDisabled,
|
|
189
|
+
children: browseText ?? ""
|
|
105
190
|
})
|
|
191
|
+
}), removeWithIcon ? /* @__PURE__ */ jsx(InlineIconButton, {
|
|
192
|
+
label: "Cancel",
|
|
193
|
+
color: "secondary",
|
|
194
|
+
onPress: () => {
|
|
195
|
+
onRemove(state.id ?? "");
|
|
196
|
+
},
|
|
197
|
+
icon: CloseIcon
|
|
198
|
+
}) : /* @__PURE__ */ jsx(TextButton, {
|
|
199
|
+
color: "secondary",
|
|
200
|
+
onPress: () => {
|
|
201
|
+
onRemove(state.id ?? "");
|
|
202
|
+
},
|
|
203
|
+
children: t(_temp3)
|
|
106
204
|
})]
|
|
107
|
-
})
|
|
108
|
-
|
|
205
|
+
});
|
|
206
|
+
$[36] = as;
|
|
207
|
+
$[37] = browseText;
|
|
208
|
+
$[38] = fileTriggerProps;
|
|
209
|
+
$[39] = isDisabled;
|
|
210
|
+
$[40] = onRemove;
|
|
211
|
+
$[41] = removeWithIcon;
|
|
212
|
+
$[42] = state.id;
|
|
213
|
+
$[43] = t;
|
|
214
|
+
$[44] = t30;
|
|
215
|
+
} else t30 = $[44];
|
|
216
|
+
let t31;
|
|
217
|
+
if ($[45] !== t29 || $[46] !== t30) {
|
|
218
|
+
t31 = /* @__PURE__ */ jsx("div", {
|
|
219
|
+
className: t29,
|
|
220
|
+
children: t30
|
|
221
|
+
});
|
|
222
|
+
$[45] = t29;
|
|
223
|
+
$[46] = t30;
|
|
224
|
+
$[47] = t31;
|
|
225
|
+
} else t31 = $[47];
|
|
226
|
+
let t32;
|
|
227
|
+
if ($[48] !== t25 || $[49] !== t31 || $[50] !== t7) {
|
|
228
|
+
t32 = /* @__PURE__ */ jsx("div", {
|
|
229
|
+
className: t2,
|
|
230
|
+
children: /* @__PURE__ */ jsxs("div", {
|
|
231
|
+
className: t7,
|
|
232
|
+
children: [t25, t31]
|
|
233
|
+
})
|
|
234
|
+
});
|
|
235
|
+
$[48] = t25;
|
|
236
|
+
$[49] = t31;
|
|
237
|
+
$[50] = t7;
|
|
238
|
+
$[51] = t32;
|
|
239
|
+
} else t32 = $[51];
|
|
240
|
+
return t32;
|
|
109
241
|
};
|
|
242
|
+
function _temp($) {
|
|
243
|
+
return $.ui.fileUpload.or;
|
|
244
|
+
}
|
|
245
|
+
function _temp2($_0) {
|
|
246
|
+
return $_0.ui.fileUpload.removeFile;
|
|
247
|
+
}
|
|
248
|
+
function _temp3($_1) {
|
|
249
|
+
return $_1.ui.fileUpload.removeFile;
|
|
250
|
+
}
|
|
110
251
|
//#endregion
|
|
111
252
|
export { FileUploadContentError };
|