lawgic-dev-kit 0.21.6 → 0.22.4
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/README.md +54 -54
- package/dist/_virtual/index2.js +2 -3
- package/dist/_virtual/index3.js +3 -3
- package/dist/_virtual/index4.js +3 -5
- package/dist/_virtual/index5.js +5 -2
- package/dist/components/atoms/Checkbox/Checkbox.d.ts +3 -2
- package/dist/components/atoms/Checkbox/Checkbox.js +43 -30
- package/dist/components/atoms/Chip/Chip.d.ts +13 -0
- package/dist/components/atoms/Chip/Chip.js +32 -0
- package/dist/components/atoms/Chip/index.d.ts +1 -0
- package/dist/components/atoms/InformationDisclaimer/InformationDisclaimer.js +17 -30
- package/dist/components/atoms/InformationDisclaimer/InformationDisclaimer.styles.d.ts +8 -2
- package/dist/components/atoms/InformationDisclaimer/InformationDisclaimer.styles.js +46 -12
- package/dist/components/atoms/InformationDisclaimer/InformationDisclaimer.types.d.ts +3 -3
- package/dist/components/atoms/LoadingSpinner/LoadingSpinner.d.ts +1 -1
- package/dist/components/atoms/LoadingSpinner/LoadingSpinner.js +56 -12
- package/dist/components/atoms/PasswordInput/PasswordInput.d.ts +1 -1
- package/dist/components/atoms/PasswordInput/PasswordInput.js +57 -41
- package/dist/components/atoms/PasswordInput/PasswordInput.types.d.ts +1 -0
- package/dist/components/atoms/SelectInput/SelectInput.d.ts +1 -1
- package/dist/components/atoms/SelectInput/SelectInput.js +125 -140
- package/dist/components/atoms/SelectInput/SelectInput.types.d.ts +2 -0
- package/dist/components/atoms/StepIndicator/StepIndicator.d.ts +5 -0
- package/dist/components/atoms/StepIndicator/StepIndicator.js +58 -0
- package/dist/components/atoms/StepIndicator/index.d.ts +1 -0
- package/dist/components/atoms/TextInput/TextInput.js +33 -33
- package/dist/components/atoms/TextInput/TextInput.types.d.ts +1 -1
- package/dist/components/atoms/Toast/Toast.d.ts +2 -3
- package/dist/components/atoms/Toast/Toast.js +46 -53
- package/dist/components/atoms/UncontrolledSelector/UncontrolledSelector.d.ts +1 -0
- package/dist/components/atoms/UncontrolledSelector/UncontrolledSelector.js +98 -84
- package/dist/components/atoms/UncontrolledTextInput/UncontrolledTextInput.js +29 -35
- package/dist/components/atoms/UncontrolledTextInput/UncontrolledTextInput.types.d.ts +1 -1
- package/dist/components/atoms/UploadContainer/UploadContainer.js +4 -4
- package/dist/components/atoms/index.d.ts +2 -1
- package/dist/components/molecules/CalendarSelector/CalendarSelector.js +8 -8
- package/dist/components/molecules/DateInput/DateInput.d.ts +1 -1
- package/dist/components/molecules/EmptyState/EmptyState.d.ts +9 -0
- package/dist/components/molecules/EmptyState/EmptyState.js +16 -0
- package/dist/components/molecules/EmptyState/index.d.ts +1 -0
- package/dist/components/molecules/MultiSelectDropdown/MultiSelectDropdown.d.ts +24 -0
- package/dist/components/molecules/MultiSelectDropdown/MultiSelectDropdown.js +208 -0
- package/dist/components/molecules/MultiSelectDropdown/index.d.ts +1 -0
- package/dist/components/molecules/SingleSelectDropdown/SingleSelectDropdown.d.ts +25 -0
- package/dist/components/molecules/SingleSelectDropdown/SingleSelectDropdown.js +212 -0
- package/dist/components/molecules/SingleSelectDropdown/index.d.ts +1 -0
- package/dist/components/molecules/Stepper/Stepper.d.ts +1 -1
- package/dist/components/molecules/Stepper/Stepper.js +78 -231
- package/dist/components/molecules/Stepper/Stepper.styles.d.ts +7 -3
- package/dist/components/molecules/Stepper/Stepper.styles.js +23 -15
- package/dist/components/molecules/Tooltip/Tooltip.d.ts +20 -0
- package/dist/components/molecules/Tooltip/Tooltip.js +41 -0
- package/dist/components/molecules/UncontrolledDateInput/UncontrolledDateInput.d.ts +1 -1
- package/dist/components/molecules/index.d.ts +4 -0
- package/dist/index.js +139 -129
- package/dist/lawgic-dev-kit.css +1 -1
- package/dist/lawgic-dev-kit.umd.js +109 -97
- package/dist/node_modules/@floating-ui/react/dist/floating-ui.react.js +396 -712
- package/dist/node_modules/@floating-ui/react/dist/floating-ui.react.utils.js +33 -81
- package/dist/node_modules/@fortawesome/free-solid-svg-icons/index.js +7 -2
- package/dist/node_modules/@fortawesome/pro-light-svg-icons/index.js +14 -49
- package/dist/node_modules/@fortawesome/pro-regular-svg-icons/index.js +32 -12
- package/dist/node_modules/@fortawesome/pro-solid-svg-icons/index.js +14 -9
- package/dist/node_modules/prop-types/index.js +1 -1
- package/dist/node_modules/yup/index.esm.js +3 -3
- package/dist/src/Root.d.ts +2 -0
- package/dist/src/app.d.ts +1 -0
- package/dist/src/components/atoms/ActionButton/ActionButton.d.ts +11 -0
- package/dist/src/components/atoms/ActionButton/index.d.ts +1 -0
- package/dist/src/components/atoms/AsyncToast/index.d.ts +11 -0
- package/dist/src/components/atoms/Avatar/Avatar.d.ts +11 -0
- package/dist/src/components/atoms/Avatar/index.d.ts +1 -0
- package/dist/src/components/atoms/BoxContainer/BoxContainer.d.ts +4 -0
- package/dist/src/components/atoms/BoxContainer/BoxContainer.types.d.ts +6 -0
- package/dist/src/components/atoms/BoxContainer/index.d.ts +1 -0
- package/dist/src/components/atoms/Button/Button.d.ts +4 -0
- package/dist/src/components/atoms/Button/Button.styles.d.ts +26 -0
- package/dist/src/components/atoms/Button/Button.types.d.ts +12 -0
- package/dist/src/components/atoms/Button/index.d.ts +1 -0
- package/dist/src/components/atoms/CenterModal/CenterModal.d.ts +4 -0
- package/dist/src/components/atoms/CenterModal/CenterModal.types.d.ts +6 -0
- package/dist/src/components/atoms/CenterModal/index.d.ts +1 -0
- package/dist/src/components/atoms/Checkbox/Checkbox.d.ts +13 -0
- package/dist/src/components/atoms/Checkbox/index.d.ts +1 -0
- package/dist/src/components/atoms/Chip/Chip.d.ts +13 -0
- package/dist/src/components/atoms/Chip/index.d.ts +1 -0
- package/dist/src/components/atoms/CircleProgress/CircleProgress.d.ts +22 -0
- package/dist/src/components/atoms/CircleProgress/index.d.ts +1 -0
- package/dist/src/components/atoms/ClickAwayListener/ClickAwayListener.d.ts +4 -0
- package/dist/src/components/atoms/ClickAwayListener/ClickAwayListener.types.d.ts +7 -0
- package/dist/src/components/atoms/ClickAwayListener/index.d.ts +1 -0
- package/dist/src/components/atoms/CountryInput/CountryInput.d.ts +4 -0
- package/dist/src/components/atoms/CountryInput/CountryInput.types.d.ts +37 -0
- package/dist/src/components/atoms/CountryInput/index.d.ts +1 -0
- package/dist/src/components/atoms/CountryLabel/CountryLabel.d.ts +6 -0
- package/dist/src/components/atoms/CountryLabel/index.d.ts +1 -0
- package/dist/src/components/atoms/CountrySelectInput/CountryDropdown.d.ts +4 -0
- package/dist/src/components/atoms/CountrySelectInput/CountryDropdown.types.d.ts +36 -0
- package/dist/src/components/atoms/CountrySelectInput/index.d.ts +1 -0
- package/dist/src/components/atoms/Divider/Divider.d.ts +7 -0
- package/dist/src/components/atoms/Divider/index.d.ts +1 -0
- package/dist/src/components/atoms/FilterPill/FilterPill.d.ts +8 -0
- package/dist/src/components/atoms/FilterPill/index.d.ts +1 -0
- package/dist/src/components/atoms/FloatingCard/FloatingCard.d.ts +4 -0
- package/dist/{components/atoms/Tooltip/Tooltip.types.d.ts → src/components/atoms/FloatingCard/FloatingCard.types.d.ts} +3 -3
- package/dist/src/components/atoms/FloatingCard/index.d.ts +1 -0
- package/dist/src/components/atoms/IconButton/IconButton.d.ts +4 -0
- package/dist/src/components/atoms/IconButton/IconButton.styles.d.ts +10 -0
- package/dist/src/components/atoms/IconButton/IconButton.types.d.ts +11 -0
- package/dist/src/components/atoms/IconButton/index.d.ts +1 -0
- package/dist/src/components/atoms/ImageProfileInput/ImageProfileInput.d.ts +4 -0
- package/dist/src/components/atoms/ImageProfileInput/ImageProfileInput.types.d.ts +12 -0
- package/dist/src/components/atoms/ImageProfileInput/ImageProfileInput.validators.d.ts +9 -0
- package/dist/src/components/atoms/ImageProfileInput/index.d.ts +2 -0
- package/dist/src/components/atoms/IndexedStep/IndexedStep.d.ts +9 -0
- package/dist/src/components/atoms/IndexedStep/index.d.ts +1 -0
- package/dist/src/components/atoms/InfoCard/InfoCard.d.ts +3 -0
- package/dist/src/components/atoms/InfoCard/InfoCard.types.d.ts +6 -0
- package/dist/src/components/atoms/InfoCard/index.d.ts +1 -0
- package/dist/src/components/atoms/InformationDisclaimer/InformationDisclaimer.d.ts +4 -0
- package/dist/src/components/atoms/InformationDisclaimer/InformationDisclaimer.styles.d.ts +9 -0
- package/dist/src/components/atoms/InformationDisclaimer/InformationDisclaimer.types.d.ts +10 -0
- package/dist/src/components/atoms/InformationDisclaimer/index.d.ts +1 -0
- package/dist/src/components/atoms/LoadingProgress/LoadingProgress.d.ts +13 -0
- package/dist/src/components/atoms/LoadingProgress/index.d.ts +1 -0
- package/dist/src/components/atoms/LoadingSpinner/LoadingSpinner.d.ts +8 -0
- package/dist/src/components/atoms/LoadingSpinner/index.d.ts +1 -0
- package/dist/src/components/atoms/PasswordInput/PasswordInput.d.ts +5 -0
- package/dist/src/components/atoms/PasswordInput/PasswordInput.types.d.ts +12 -0
- package/dist/src/components/atoms/PasswordInput/index.d.ts +1 -0
- package/dist/src/components/atoms/PhoneInput/PhoneInput.d.ts +5 -0
- package/dist/src/components/atoms/PhoneInput/PhoneInput.types.d.ts +12 -0
- package/dist/src/components/atoms/PhoneInput/index.d.ts +1 -0
- package/dist/src/components/atoms/Pill/Pill.d.ts +8 -0
- package/dist/src/components/atoms/Pill/index.d.ts +1 -0
- package/dist/src/components/atoms/ProgressBar/ProgressBar.d.ts +3 -0
- package/dist/src/components/atoms/ProgressBar/ProgressBar.styles.d.ts +7 -0
- package/dist/src/components/atoms/ProgressBar/ProgressBar.types.d.ts +6 -0
- package/dist/src/components/atoms/ProgressBar/index.d.ts +1 -0
- package/dist/src/components/atoms/SearchBar/index.d.ts +2 -0
- package/dist/src/components/atoms/SectionButton/SectionButton.d.ts +12 -0
- package/dist/src/components/atoms/SectionButton/desktop/SectionButton.d.ts +3 -0
- package/dist/src/components/atoms/SectionButton/desktop/SectionButton.styles.d.ts +2 -0
- package/dist/src/components/atoms/SectionButton/desktop/SectionButton.types.d.ts +37 -0
- package/dist/src/components/atoms/SectionButton/desktop/index.d.ts +2 -0
- package/dist/src/components/atoms/SectionButton/index.d.ts +1 -0
- package/dist/src/components/atoms/SectionButton/mobile/MobileSectionButton.styles.d.ts +3 -0
- package/dist/src/components/atoms/SectionButton/mobile/SectionButton.d.ts +3 -0
- package/dist/src/components/atoms/SectionButton/mobile/SectionButton.types.d.ts +37 -0
- package/dist/src/components/atoms/SectionButton/mobile/index.d.ts +2 -0
- package/dist/src/components/atoms/SelectInput/SelectInput.d.ts +1 -1
- package/dist/src/components/atoms/SelectInput/SelectInput.types.d.ts +2 -0
- package/dist/src/components/atoms/SelectInput/index.d.ts +1 -0
- package/dist/src/components/atoms/SidebarButton/SidebarButton.d.ts +13 -0
- package/dist/src/components/atoms/SidebarButton/SidebarButton.styles.d.ts +9 -0
- package/dist/src/components/atoms/SidebarButton/index.d.ts +1 -0
- package/dist/src/components/atoms/StepIndicator/StepIndicator.d.ts +5 -0
- package/dist/src/components/atoms/StepIndicator/index.d.ts +1 -0
- package/dist/src/components/atoms/Switch/Switch.d.ts +7 -0
- package/dist/src/components/atoms/Switch/index.d.ts +1 -0
- package/dist/src/components/atoms/Tab/Tab.d.ts +3 -0
- package/dist/src/components/atoms/Tab/Tab.styles.d.ts +6 -0
- package/dist/src/components/atoms/Tab/Tab.types.d.ts +11 -0
- package/dist/src/components/atoms/Tab/index.d.ts +1 -0
- package/dist/src/components/atoms/TextButton/TextButton.d.ts +4 -0
- package/dist/src/components/atoms/TextButton/TextButton.styles.d.ts +2 -0
- package/dist/src/components/atoms/TextButton/TextButton.types.d.ts +6 -0
- package/dist/src/components/atoms/TextButton/index.d.ts +1 -0
- package/dist/src/components/atoms/TextInput/TextInput.d.ts +5 -0
- package/dist/src/components/atoms/TextInput/TextInput.types.d.ts +13 -0
- package/dist/src/components/atoms/TextInput/index.d.ts +1 -0
- package/dist/src/components/atoms/TextStaticInput/TextStaticInput.d.ts +3 -0
- package/dist/src/components/atoms/TextStaticInput/TextStaticInput.types.d.ts +5 -0
- package/dist/src/components/atoms/TextStaticInput/index.d.ts +1 -0
- package/dist/src/components/atoms/ThresholdCircleProgress/ThresholdCircleProgress.d.ts +4 -0
- package/dist/src/components/atoms/ThresholdCircleProgress/ThresholdCircleProgress.types.d.ts +30 -0
- package/dist/src/components/atoms/ThresholdCircleProgress/index.d.ts +1 -0
- package/dist/src/components/atoms/ThresholdProgressBar/ThresholdProgressBar.d.ts +4 -0
- package/dist/src/components/atoms/ThresholdProgressBar/ThresholdProgressBar.types.d.ts +22 -0
- package/dist/src/components/atoms/ThresholdProgressBar/index.d.ts +1 -0
- package/dist/src/components/atoms/Toast/Toast.d.ts +20 -0
- package/dist/src/components/atoms/Toast/index.d.ts +1 -0
- package/dist/src/components/atoms/UncontrolledSelector/UncontrolledSelector.d.ts +1 -0
- package/dist/src/components/atoms/UncontrolledSelector/index.d.ts +1 -0
- package/dist/src/components/atoms/UncontrolledTextInput/UncontrolledTextInput.d.ts +4 -0
- package/dist/src/components/atoms/UncontrolledTextInput/UncontrolledTextInput.types.d.ts +14 -0
- package/dist/src/components/atoms/UncontrolledTextInput/index.d.ts +1 -0
- package/dist/src/components/atoms/UploadContainer/UploadContainer.d.ts +4 -0
- package/dist/src/components/atoms/UploadContainer/UploadContainer.types.d.ts +37 -0
- package/dist/src/components/atoms/UploadContainer/index.d.ts +1 -0
- package/dist/src/components/atoms/index.d.ts +43 -0
- package/dist/src/components/index.d.ts +3 -0
- package/dist/src/components/molecules/AlertModal/AlertModal.d.ts +3 -0
- package/dist/src/components/molecules/AlertModal/AlertModal.types.d.ts +9 -0
- package/dist/src/components/molecules/AlertModal/index.d.ts +2 -0
- package/dist/src/components/molecules/AutocompleteInput/AutocompleteInput.d.ts +3 -0
- package/dist/src/components/molecules/AutocompleteInput/AutocompleteInput.types.d.ts +28 -0
- package/dist/src/components/molecules/AutocompleteInput/index.d.ts +1 -0
- package/dist/src/components/molecules/CalendarSelector/CalendarSelector.d.ts +14 -0
- package/dist/src/components/molecules/CalendarSelector/CalendarSelector.styles.d.ts +36 -0
- package/dist/src/components/molecules/CalendarSelector/PeriodToggle.d.ts +15 -0
- package/dist/src/components/molecules/CalendarSelector/TimeDisplay.d.ts +7 -0
- package/dist/src/components/molecules/CalendarSelector/index.d.ts +1 -0
- package/dist/src/components/molecules/DateInput/DateInput.d.ts +14 -0
- package/dist/src/components/molecules/DateInput/index.d.ts +1 -0
- package/dist/src/components/molecules/DialogModal/DialogModal.d.ts +3 -0
- package/dist/src/components/molecules/DialogModal/DialogModal.types.d.ts +11 -0
- package/dist/src/components/molecules/DialogModal/index.d.ts +1 -0
- package/dist/src/components/molecules/Dropdown/Dropdown.d.ts +3 -0
- package/dist/src/components/molecules/Dropdown/Dropdown.types.d.ts +9 -0
- package/dist/src/components/molecules/Dropdown/index.d.ts +1 -0
- package/dist/src/components/molecules/EmptyState/EmptyState.d.ts +9 -0
- package/dist/src/components/molecules/EmptyState/index.d.ts +1 -0
- package/dist/src/components/molecules/FileUpload/FileUpload.d.ts +4 -0
- package/dist/src/components/molecules/FileUpload/FileUpload.types.d.ts +17 -0
- package/dist/src/components/molecules/FileUpload/index.d.ts +1 -0
- package/dist/src/components/molecules/FiltersMenu/FiltersMenu.d.ts +13 -0
- package/dist/src/components/molecules/FiltersMenu/index.d.ts +1 -0
- package/dist/src/components/molecules/FloatingMenu/FloatingMenu.d.ts +4 -0
- package/dist/src/components/molecules/FloatingMenu/FloatingMenu.types.d.ts +13 -0
- package/dist/src/components/molecules/FloatingMenu/index.d.ts +1 -0
- package/dist/src/components/molecules/IndexedStepper/IndexedStepper.d.ts +7 -0
- package/dist/src/components/molecules/IndexedStepper/index.d.ts +1 -0
- package/dist/src/components/molecules/InformationContainer/InformationContainer.d.ts +14 -0
- package/dist/src/components/molecules/InformationContainer/index.d.ts +1 -0
- package/dist/src/components/molecules/MultiSelectDropdown/MultiSelectDropdown.d.ts +24 -0
- package/dist/src/components/molecules/MultiSelectDropdown/index.d.ts +1 -0
- package/dist/src/components/molecules/PillsContainer/PillsContainer.d.ts +9 -0
- package/dist/src/components/molecules/PillsContainer/index.d.ts +1 -0
- package/dist/src/components/molecules/SearchModal/SearchModal.d.ts +4 -0
- package/dist/src/components/molecules/SearchModal/SearchModal.types.d.ts +5 -0
- package/dist/src/components/molecules/SearchModal/index.d.ts +1 -0
- package/dist/src/components/molecules/SideModal/SideModal.d.ts +4 -0
- package/dist/src/components/molecules/SideModal/SideModal.types.d.ts +11 -0
- package/dist/src/components/molecules/SideModal/index.d.ts +1 -0
- package/dist/src/components/molecules/SingleSelectDropdown/SingleSelectDropdown.d.ts +25 -0
- package/dist/src/components/molecules/SingleSelectDropdown/index.d.ts +1 -0
- package/dist/src/components/molecules/Stepper/Stepper.d.ts +3 -0
- package/dist/src/components/molecules/Stepper/Stepper.styles.d.ts +15 -0
- package/dist/src/components/molecules/Stepper/index.d.ts +1 -0
- package/dist/src/components/molecules/Tabs/Tabs.d.ts +21 -0
- package/dist/src/components/molecules/Tabs/index.d.ts +1 -0
- package/dist/src/components/molecules/Tooltip/Tooltip.d.ts +20 -0
- package/dist/src/components/molecules/Tooltip/index.d.ts +1 -0
- package/dist/src/components/molecules/UncontrolledDateInput/UncontrolledDateInput.d.ts +16 -0
- package/dist/src/components/molecules/UncontrolledDateInput/index.d.ts +1 -0
- package/dist/src/components/molecules/index.d.ts +23 -0
- package/dist/src/components/organisms/index.d.ts +1 -0
- package/dist/src/constants/countries.d.ts +30 -0
- package/dist/src/contexts/index.d.ts +1 -0
- package/dist/src/contexts/themeContext.d.ts +3 -0
- package/dist/src/hooks/index.d.ts +2 -0
- package/dist/src/hooks/useFilterToggler.d.ts +5 -0
- package/dist/src/hooks/useTheme.d.ts +1 -0
- package/dist/src/index.d.ts +8 -0
- package/dist/src/lab/Laboratory.d.ts +2 -0
- package/dist/src/lab/LaboratoryLayout.d.ts +5 -0
- package/dist/src/lab/index.lab.d.ts +1 -0
- package/dist/src/providers/ThemeProvider.d.ts +7 -0
- package/dist/src/providers/index.d.ts +1 -0
- package/dist/src/themes/default.d.ts +2 -0
- package/dist/src/themes/index.d.ts +2 -0
- package/dist/src/themes/types.d.ts +6 -0
- package/dist/src/types/baseModalProps.d.ts +4 -0
- package/dist/src/types/cycles.d.ts +103 -0
- package/dist/src/types/display.d.ts +2 -0
- package/dist/src/types/fileInfo.d.ts +2 -0
- package/dist/src/types/filters.d.ts +22 -0
- package/dist/src/types/i18n.d.ts +1 -0
- package/dist/src/types/index.d.ts +10 -0
- package/dist/src/types/modal.d.ts +34 -0
- package/dist/src/types/modalType.d.ts +1 -0
- package/dist/src/types/navbarOption.d.ts +7 -0
- package/dist/src/types/sidebarOption.d.ts +7 -0
- package/dist/src/types/stepper.d.ts +23 -0
- package/dist/src/types/styleValues.d.ts +4 -0
- package/dist/src/types/toast.d.ts +29 -0
- package/dist/src/utils/cycles.d.ts +2 -0
- package/dist/src/utils/dates.d.ts +1 -0
- package/dist/src/utils/files.d.ts +8 -0
- package/dist/src/utils/images.d.ts +1 -0
- package/dist/src/utils/index.d.ts +7 -0
- package/dist/src/utils/modal.d.ts +13 -0
- package/dist/src/utils/renderContentOptions.d.ts +3 -0
- package/dist/src/utils/stepper.d.ts +2 -0
- package/dist/src/utils/strings.d.ts +2 -0
- package/dist/src/utils/toast.d.ts +15 -0
- package/dist/types/index.d.ts +1 -0
- package/dist/types/stepper.d.ts +23 -0
- package/dist/types/toast.d.ts +6 -3
- package/dist/utils/stepper.d.ts +2 -0
- package/dist/utils/toast.js +3 -3
- package/dist/vite-env.d.ts +1 -1
- package/dist/vite.config.d.ts +2 -0
- package/package.json +157 -157
- package/dist/components/atoms/Tooltip/Tooltip.d.ts +0 -4
- package/dist/components/atoms/Tooltip/Tooltip.js +0 -121
- package/dist/components/molecules/Stepper/Stepper.types.d.ts +0 -9
- /package/dist/components/{atoms → molecules}/Tooltip/index.d.ts +0 -0
|
@@ -0,0 +1,212 @@
|
|
|
1
|
+
import { j as e } from "../../../_virtual/jsx-runtime.js";
|
|
2
|
+
import Y, { useState as N, useRef as w } from "react";
|
|
3
|
+
import { useFloating as q, useClick as A, useDismiss as G, useInteractions as J, useTransitionStyles as K } from "../../../node_modules/@floating-ui/react/dist/floating-ui.react.js";
|
|
4
|
+
import "../../../node_modules/@fortawesome/react-fontawesome/index.es.js";
|
|
5
|
+
import "../../../_virtual/lodash.js";
|
|
6
|
+
import "../../../contexts/themeContext.js";
|
|
7
|
+
import "react-hook-form";
|
|
8
|
+
import "../InformationContainer/InformationContainer.js";
|
|
9
|
+
import "react-dom";
|
|
10
|
+
import Q from "../../atoms/Checkbox/Checkbox.js";
|
|
11
|
+
import "../../../constants/countries.js";
|
|
12
|
+
import "../../atoms/ImageProfileInput/ImageProfileInput.validators.js";
|
|
13
|
+
import "fuse.js";
|
|
14
|
+
import { autoUpdate as X } from "../../../node_modules/@floating-ui/dom/dist/floating-ui.dom.js";
|
|
15
|
+
import { offset as Z, flip as V, shift as ee, size as te, arrow as re } from "../../../node_modules/@floating-ui/react-dom/dist/floating-ui.react-dom.js";
|
|
16
|
+
const je = ({
|
|
17
|
+
label: u,
|
|
18
|
+
options: m,
|
|
19
|
+
selectedValue: a = null,
|
|
20
|
+
onUpdate: $,
|
|
21
|
+
placeholder: C = "Seleccionar opción",
|
|
22
|
+
allowSearch: z = !0,
|
|
23
|
+
className: S = "",
|
|
24
|
+
disabled: r = !1,
|
|
25
|
+
size: L = "md",
|
|
26
|
+
showRadio: M = !1
|
|
27
|
+
}) => {
|
|
28
|
+
var f, g, y, j;
|
|
29
|
+
const [n, i] = N(!1), [l, c] = N(""), R = w(null), B = w(null), s = {
|
|
30
|
+
sm: {
|
|
31
|
+
container: "px-16 py-8",
|
|
32
|
+
text: "text-sm",
|
|
33
|
+
label: "text-sm",
|
|
34
|
+
icon: "w-12 h-12",
|
|
35
|
+
checkboxSize: 16,
|
|
36
|
+
gap: "gap-8",
|
|
37
|
+
searchText: "text-sm",
|
|
38
|
+
searchIcon: "size-12"
|
|
39
|
+
},
|
|
40
|
+
md: {
|
|
41
|
+
container: "p-16",
|
|
42
|
+
text: "text-14",
|
|
43
|
+
label: "text-14",
|
|
44
|
+
icon: "w-16 h-16",
|
|
45
|
+
checkboxSize: 20,
|
|
46
|
+
gap: "gap-8",
|
|
47
|
+
searchText: "text-14",
|
|
48
|
+
searchIcon: "size-16"
|
|
49
|
+
}
|
|
50
|
+
}[L], { x: I, y: O, strategy: T, refs: x, context: d } = q({
|
|
51
|
+
open: n && !r,
|
|
52
|
+
onOpenChange: (t) => !r && i(t),
|
|
53
|
+
middleware: [
|
|
54
|
+
Z(8),
|
|
55
|
+
V(),
|
|
56
|
+
ee({ padding: 8 }),
|
|
57
|
+
te({
|
|
58
|
+
apply({ availableHeight: t, elements: p }) {
|
|
59
|
+
Object.assign(p.floating.style, {
|
|
60
|
+
maxHeight: `${Math.min(t - 10, 500)}px`
|
|
61
|
+
});
|
|
62
|
+
},
|
|
63
|
+
padding: 8
|
|
64
|
+
}),
|
|
65
|
+
re({ element: B })
|
|
66
|
+
],
|
|
67
|
+
placement: "bottom-start",
|
|
68
|
+
whileElementsMounted: X
|
|
69
|
+
}), F = A(d, { enabled: !r }), P = G(d), { getReferenceProps: W, getFloatingProps: D } = J([F, P]), { isMounted: E, styles: _ } = K(d, {
|
|
70
|
+
duration: { open: 200, close: 150 },
|
|
71
|
+
initial: { opacity: 0, transform: "translateY(-4px)" }
|
|
72
|
+
}), o = m.find((t) => t.value === a), H = (t) => {
|
|
73
|
+
r || ($(a === t ? null : t), i(!1), c(""));
|
|
74
|
+
}, h = m.filter(
|
|
75
|
+
(t) => t.label.toLowerCase().includes(l.toLowerCase())
|
|
76
|
+
), U = W({
|
|
77
|
+
onClick: () => !r && i(!n)
|
|
78
|
+
});
|
|
79
|
+
return /* @__PURE__ */ e.jsxs("div", { className: `flex flex-col select-none ${s.gap} ${r ? "cursor-not-allowed" : ""} ${S}`, children: [
|
|
80
|
+
u && /* @__PURE__ */ e.jsx("h6", { className: `text-gray-600 font-600 ${s.label} ${r ? "text-gray-300" : ""}`, children: u }),
|
|
81
|
+
/* @__PURE__ */ e.jsxs(
|
|
82
|
+
"div",
|
|
83
|
+
{
|
|
84
|
+
ref: x.setReference,
|
|
85
|
+
className: `
|
|
86
|
+
flex items-center justify-between rounded-full border transition-all duration-200
|
|
87
|
+
${s.container}
|
|
88
|
+
${r ? "bg-gray-50 border-gray-200 cursor-not-allowed" : "bg-blue-50 cursor-pointer"}
|
|
89
|
+
${!r && (n ? "border-blue-500" : "border-blue-100 hover:border-blue-300")}
|
|
90
|
+
`,
|
|
91
|
+
...U,
|
|
92
|
+
children: [
|
|
93
|
+
o ? /* @__PURE__ */ e.jsxs("div", { className: `flex items-center gap-[6px] overflow-hidden ${((f = o.colors) == null ? void 0 : f.bgColor) || ""} ${((g = o.colors) == null ? void 0 : g.textColor) || ""} ${o.colors ? "rounded-[8px] py-4 px-8" : ""}`, children: [
|
|
94
|
+
((y = o.colors) == null ? void 0 : y.dotColor) && /* @__PURE__ */ e.jsx(
|
|
95
|
+
"span",
|
|
96
|
+
{
|
|
97
|
+
className: "size-6 rounded-full flex-shrink-0",
|
|
98
|
+
style: { background: o.colors.dotColor }
|
|
99
|
+
}
|
|
100
|
+
),
|
|
101
|
+
/* @__PURE__ */ e.jsx("span", { className: `${s.text} font-semibold truncate`, children: o.label })
|
|
102
|
+
] }) : /* @__PURE__ */ e.jsx("span", { className: `flex-grow text-left truncate font-600 ${s.text} ${r ? "text-gray-300" : "text-gray-500"}`, children: C }),
|
|
103
|
+
/* @__PURE__ */ e.jsx(
|
|
104
|
+
"svg",
|
|
105
|
+
{
|
|
106
|
+
className: `${s.icon} transition-transform ${n ? "rotate-180" : ""} ${r ? "text-gray-300" : "text-gray-500"}`,
|
|
107
|
+
fill: "none",
|
|
108
|
+
stroke: "currentColor",
|
|
109
|
+
viewBox: "0 0 24 24",
|
|
110
|
+
children: /* @__PURE__ */ e.jsx("path", { strokeLinecap: "round", strokeLinejoin: "round", strokeWidth: "2", d: "M19 9l-7 7-7-7" })
|
|
111
|
+
}
|
|
112
|
+
)
|
|
113
|
+
]
|
|
114
|
+
}
|
|
115
|
+
),
|
|
116
|
+
E && !r && /* @__PURE__ */ e.jsxs(
|
|
117
|
+
"div",
|
|
118
|
+
{
|
|
119
|
+
ref: x.setFloating,
|
|
120
|
+
style: {
|
|
121
|
+
position: T,
|
|
122
|
+
top: O ?? 0,
|
|
123
|
+
left: I ?? 0,
|
|
124
|
+
..._,
|
|
125
|
+
width: (j = x.reference.current) == null ? void 0 : j.clientWidth,
|
|
126
|
+
zIndex: 50
|
|
127
|
+
},
|
|
128
|
+
className: "bg-white border border-blue-400 rounded-3xl shadow-lg overflow-hidden",
|
|
129
|
+
...D(),
|
|
130
|
+
children: [
|
|
131
|
+
z && /* @__PURE__ */ e.jsx("div", { className: "sticky top-0 bg-white p-8 border-b border-gray-100 z-20", children: /* @__PURE__ */ e.jsxs("div", { className: "relative", children: [
|
|
132
|
+
/* @__PURE__ */ e.jsx("div", { className: "absolute inset-y-0 left-0 pl-12 flex items-center pointer-events-none", children: /* @__PURE__ */ e.jsx("svg", { className: `${s.searchIcon} text-gray-400`, fill: "none", stroke: "currentColor", viewBox: "0 0 24 24", children: /* @__PURE__ */ e.jsx("path", { strokeLinecap: "round", strokeLinejoin: "round", strokeWidth: "2", d: "M21 21l-6-6m2-5a7 7 0 11-14 0 7 7 0 0114 0z" }) }) }),
|
|
133
|
+
/* @__PURE__ */ e.jsx(
|
|
134
|
+
"input",
|
|
135
|
+
{
|
|
136
|
+
ref: R,
|
|
137
|
+
type: "text",
|
|
138
|
+
className: `w-full py-6 pl-36 pr-12 rounded-full focus:outline-none bg-gray-50 ${s.searchText}`,
|
|
139
|
+
placeholder: "Buscar...",
|
|
140
|
+
value: l,
|
|
141
|
+
onChange: (t) => c(t.target.value),
|
|
142
|
+
onClick: (t) => t.stopPropagation(),
|
|
143
|
+
autoFocus: !0
|
|
144
|
+
}
|
|
145
|
+
),
|
|
146
|
+
l && /* @__PURE__ */ e.jsx(
|
|
147
|
+
"button",
|
|
148
|
+
{
|
|
149
|
+
className: "absolute inset-y-0 right-0 pr-12 flex items-center",
|
|
150
|
+
onClick: (t) => {
|
|
151
|
+
t.stopPropagation(), c("");
|
|
152
|
+
},
|
|
153
|
+
children: /* @__PURE__ */ e.jsx("svg", { className: "h-16 w-16 text-gray-400 hover:text-gray-600", fill: "none", stroke: "currentColor", viewBox: "0 0 24 24", children: /* @__PURE__ */ e.jsx("path", { strokeLinecap: "round", strokeLinejoin: "round", strokeWidth: "2", d: "M6 18L18 6M6 6l12 12" }) })
|
|
154
|
+
}
|
|
155
|
+
)
|
|
156
|
+
] }) }),
|
|
157
|
+
/* @__PURE__ */ e.jsx("div", { className: "max-h-[450px] overflow-y-auto", children: h.length > 0 ? /* @__PURE__ */ e.jsx("div", { className: "py-4", children: h.map((t) => {
|
|
158
|
+
var v, b, k;
|
|
159
|
+
const p = a === t.value;
|
|
160
|
+
return /* @__PURE__ */ e.jsxs(Y.Fragment, { children: [
|
|
161
|
+
t.dividerBefore && /* @__PURE__ */ e.jsx("div", { className: "px-16 py-8", children: /* @__PURE__ */ e.jsx("hr", { className: "border-t border-gray-200" }) }),
|
|
162
|
+
/* @__PURE__ */ e.jsxs(
|
|
163
|
+
"div",
|
|
164
|
+
{
|
|
165
|
+
className: "flex items-center px-16 py-10 transition-all duration-200 hover:bg-blue-50 cursor-pointer gap-12",
|
|
166
|
+
onClick: () => H(t.value),
|
|
167
|
+
children: [
|
|
168
|
+
M && /* @__PURE__ */ e.jsx(
|
|
169
|
+
Q,
|
|
170
|
+
{
|
|
171
|
+
active: p,
|
|
172
|
+
size: s.checkboxSize,
|
|
173
|
+
variant: "rounded",
|
|
174
|
+
className: "flex-shrink-0"
|
|
175
|
+
}
|
|
176
|
+
),
|
|
177
|
+
/* @__PURE__ */ e.jsxs(
|
|
178
|
+
"div",
|
|
179
|
+
{
|
|
180
|
+
className: `flex items-center rounded-[8px] py-4 px-8 gap-[6px] overflow-hidden ${((v = t.colors) == null ? void 0 : v.bgColor) || ""} ${((b = t.colors) == null ? void 0 : b.textColor) || ""}`,
|
|
181
|
+
children: [
|
|
182
|
+
((k = t.colors) == null ? void 0 : k.dotColor) && /* @__PURE__ */ e.jsx(
|
|
183
|
+
"span",
|
|
184
|
+
{
|
|
185
|
+
className: "size-6 rounded-full flex-shrink-0",
|
|
186
|
+
style: { background: t.colors.dotColor }
|
|
187
|
+
}
|
|
188
|
+
),
|
|
189
|
+
/* @__PURE__ */ e.jsx("span", { className: `${s.text} font-semibold truncate`, children: t.label })
|
|
190
|
+
]
|
|
191
|
+
}
|
|
192
|
+
)
|
|
193
|
+
]
|
|
194
|
+
}
|
|
195
|
+
)
|
|
196
|
+
] }, t.value);
|
|
197
|
+
}) }) : /* @__PURE__ */ e.jsxs("div", { className: "px-16 py-16 text-center text-gray-500", children: [
|
|
198
|
+
/* @__PURE__ */ e.jsx("svg", { className: "mx-auto h-24 w-24 text-gray-400", fill: "none", stroke: "currentColor", viewBox: "0 0 24 24", children: /* @__PURE__ */ e.jsx("path", { strokeLinecap: "round", strokeLinejoin: "round", strokeWidth: "2", d: "M9.172 16.172a4 4 0 015.656 0M9 10h.01M15 10h.01M21 12a9 9 0 11-18 0 9 9 0 0118 0z" }) }),
|
|
199
|
+
/* @__PURE__ */ e.jsxs("p", { className: "mt-8 text-body-s", children: [
|
|
200
|
+
"No se encontraron resultados para “",
|
|
201
|
+
l,
|
|
202
|
+
"”"
|
|
203
|
+
] })
|
|
204
|
+
] }) })
|
|
205
|
+
]
|
|
206
|
+
}
|
|
207
|
+
)
|
|
208
|
+
] });
|
|
209
|
+
};
|
|
210
|
+
export {
|
|
211
|
+
je as default
|
|
212
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { default as SingleSelectDropdown } from './SingleSelectDropdown';
|
|
@@ -1,249 +1,96 @@
|
|
|
1
1
|
import { j as e } from "../../../_virtual/jsx-runtime.js";
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
5
|
-
import
|
|
6
|
-
import
|
|
7
|
-
import
|
|
8
|
-
import
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
})
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
pendingBorderColor: l,
|
|
20
|
-
iconActiveColor: f
|
|
21
|
-
} = w(j);
|
|
22
|
-
return /* @__PURE__ */ e.jsxs("div", { className: "flex items-center gap-8 h-fit", children: [
|
|
23
|
-
/* @__PURE__ */ e.jsx(
|
|
24
|
-
m.div,
|
|
25
|
-
{
|
|
26
|
-
initial: t ? !1 : {
|
|
27
|
-
backgroundColor: o ? "#E0F1ED" : i ? c : "white",
|
|
28
|
-
borderWidth: i ? "1px" : "0px",
|
|
29
|
-
borderColor: i ? c : l
|
|
30
|
-
},
|
|
31
|
-
animate: {
|
|
32
|
-
backgroundColor: o ? "#E0F1ED" : i ? c : "white",
|
|
33
|
-
borderWidth: i || !o ? "1px" : "0px",
|
|
34
|
-
borderColor: i ? c : l
|
|
35
|
-
},
|
|
36
|
-
transition: { duration: t ? 0.3 : 0, ease: "easeOut" },
|
|
37
|
-
className: "min-w-28 min-h-28 rounded-full flex items-center justify-center text-xl font-bold border-[1px]",
|
|
38
|
-
children: /* @__PURE__ */ e.jsx(
|
|
39
|
-
m.div,
|
|
40
|
-
{
|
|
41
|
-
initial: t ? !1 : { color: o ? "rgb(34, 197, 94)" : "rgb(209, 213, 219)" },
|
|
42
|
-
animate: {
|
|
43
|
-
color: o || i ? "rgb(34, 197, 94)" : "rgb(209, 213, 219)"
|
|
44
|
-
},
|
|
45
|
-
transition: { duration: t ? 0.2 : 0 },
|
|
46
|
-
className: "flex items-center justify-center",
|
|
47
|
-
children: /* @__PURE__ */ e.jsx(I, { mode: "wait", children: o || i ? /* @__PURE__ */ e.jsx(
|
|
48
|
-
m.div,
|
|
49
|
-
{
|
|
50
|
-
initial: t ? { opacity: 0, scale: 0.8, rotate: -180 } : { opacity: 1, scale: 1, rotate: 0 },
|
|
51
|
-
animate: { opacity: 1, scale: 1, rotate: 0 },
|
|
52
|
-
exit: { opacity: 0, scale: 0.8, rotate: 180 },
|
|
53
|
-
transition: { duration: t ? 0.3 : 0 },
|
|
54
|
-
className: "flex items-center justify-center",
|
|
55
|
-
children: o ? /* @__PURE__ */ e.jsx(
|
|
56
|
-
h,
|
|
57
|
-
{
|
|
58
|
-
icon: S,
|
|
59
|
-
className: `w-14 h-14 min-w-14 min-h-14 ${f}`
|
|
60
|
-
}
|
|
61
|
-
) : /* @__PURE__ */ e.jsx("div", { className: "text-white leading-none font-500 text-body-s flex items-center justify-center mb-1", children: p + 1 })
|
|
62
|
-
},
|
|
63
|
-
"check"
|
|
64
|
-
) : /* @__PURE__ */ e.jsx(
|
|
65
|
-
m.div,
|
|
66
|
-
{
|
|
67
|
-
initial: t ? { opacity: 0, scale: 0.8, rotate: -180 } : { opacity: 1, scale: 1, rotate: 0 },
|
|
68
|
-
animate: { opacity: 1, scale: 1, rotate: 0 },
|
|
69
|
-
exit: { opacity: 0, scale: 0.8, rotate: 180 },
|
|
70
|
-
transition: { duration: t ? 0.3 : 0 },
|
|
71
|
-
className: "flex items-center justify-center",
|
|
72
|
-
children: /* @__PURE__ */ e.jsx(
|
|
73
|
-
h,
|
|
74
|
-
{
|
|
75
|
-
icon: k,
|
|
76
|
-
className: "w-14 h-14 min-w-14 min-h-14"
|
|
77
|
-
}
|
|
78
|
-
)
|
|
79
|
-
},
|
|
80
|
-
"clock"
|
|
81
|
-
) })
|
|
82
|
-
}
|
|
83
|
-
)
|
|
84
|
-
}
|
|
85
|
-
),
|
|
86
|
-
/* @__PURE__ */ e.jsx(
|
|
87
|
-
"span",
|
|
88
|
-
{
|
|
89
|
-
className: `text-body-s transition-all duration-300 text-center w-full font-500
|
|
90
|
-
|
|
91
|
-
`,
|
|
92
|
-
style: {
|
|
93
|
-
color: i ? c : o ? "#000" : "#8F9095"
|
|
94
|
-
},
|
|
95
|
-
children: s(u)
|
|
96
|
-
}
|
|
97
|
-
)
|
|
2
|
+
import { useState as f, useEffect as w } from "react";
|
|
3
|
+
import { useTheme as u } from "../../../hooks/useTheme.js";
|
|
4
|
+
import { resolveStepperColors as x } from "./Stepper.styles.js";
|
|
5
|
+
import "../../../node_modules/@fortawesome/react-fontawesome/index.es.js";
|
|
6
|
+
import "../../../_virtual/lodash.js";
|
|
7
|
+
import "react-hook-form";
|
|
8
|
+
import "../InformationContainer/InformationContainer.js";
|
|
9
|
+
import "react-dom";
|
|
10
|
+
import "../../../constants/countries.js";
|
|
11
|
+
import "../../atoms/ImageProfileInput/ImageProfileInput.validators.js";
|
|
12
|
+
import "fuse.js";
|
|
13
|
+
import v from "../../atoms/StepIndicator/StepIndicator.js";
|
|
14
|
+
const z = (t) => {
|
|
15
|
+
const { t: i } = u(), { labelColor: r } = x(t.color);
|
|
16
|
+
return /* @__PURE__ */ e.jsxs("div", { className: "flex items-center gap-8 h-fit min-w-0", children: [
|
|
17
|
+
/* @__PURE__ */ e.jsx("div", { className: "flex-shrink-0", children: /* @__PURE__ */ e.jsx(v, { ...t }) }),
|
|
18
|
+
t.label && /* @__PURE__ */ e.jsx("span", { className: `text-body-s transition-all duration-300 font-semibold truncate ${r}`, children: i(t.label) })
|
|
98
19
|
] });
|
|
99
|
-
},
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
}) => {
|
|
105
|
-
const { t: p } = v(), s = a === "done", o = a === "focus", {
|
|
106
|
-
completedBgColor: i,
|
|
107
|
-
focusBorderColor: c,
|
|
108
|
-
pendingBorderColor: l,
|
|
109
|
-
iconActiveColor: f
|
|
110
|
-
} = w(j);
|
|
111
|
-
return /* @__PURE__ */ e.jsxs("div", { className: "flex items-center gap-8 h-fit", children: [
|
|
112
|
-
/* @__PURE__ */ e.jsx(
|
|
113
|
-
m.div,
|
|
114
|
-
{
|
|
115
|
-
initial: t ? !1 : {
|
|
116
|
-
backgroundColor: s ? i : "white",
|
|
117
|
-
borderWidth: o || !s ? "1px" : "0px",
|
|
118
|
-
borderColor: o ? c : l
|
|
119
|
-
},
|
|
120
|
-
animate: {
|
|
121
|
-
backgroundColor: s ? i : "white",
|
|
122
|
-
borderWidth: o || !s ? "1px" : "0px",
|
|
123
|
-
borderColor: o ? c : l
|
|
124
|
-
},
|
|
125
|
-
transition: { duration: t ? 0.3 : 0, ease: "easeOut" },
|
|
126
|
-
className: "min-w-24 min-h-24 rounded-full flex items-center justify-center text-xs font-bold z-10",
|
|
127
|
-
children: /* @__PURE__ */ e.jsx(
|
|
128
|
-
m.div,
|
|
129
|
-
{
|
|
130
|
-
initial: t ? !1 : {
|
|
131
|
-
color: o || s ? "rgb(34, 197, 94)" : "rgb(209, 213, 219)"
|
|
132
|
-
},
|
|
133
|
-
animate: {
|
|
134
|
-
color: o || s ? "rgb(34, 197, 94)" : "rgb(209, 213, 219)"
|
|
135
|
-
},
|
|
136
|
-
transition: { duration: t ? 0.2 : 0 },
|
|
137
|
-
className: "flex items-center justify-center",
|
|
138
|
-
children: /* @__PURE__ */ e.jsx(I, { mode: "wait", children: s || o ? /* @__PURE__ */ e.jsx(
|
|
139
|
-
m.div,
|
|
140
|
-
{
|
|
141
|
-
initial: t ? { opacity: 0, scale: 0.8, rotate: -180 } : { opacity: 1, scale: 1, rotate: 0 },
|
|
142
|
-
animate: { opacity: 1, scale: 1, rotate: 0 },
|
|
143
|
-
exit: { opacity: 0, scale: 0.8, rotate: 180 },
|
|
144
|
-
transition: { duration: t ? 0.3 : 0 },
|
|
145
|
-
className: "flex items-center justify-center",
|
|
146
|
-
children: /* @__PURE__ */ e.jsx(
|
|
147
|
-
h,
|
|
148
|
-
{
|
|
149
|
-
icon: S,
|
|
150
|
-
className: `w-14 h-14 min-w-14 min-h-14 ${f}`
|
|
151
|
-
}
|
|
152
|
-
)
|
|
153
|
-
},
|
|
154
|
-
"check"
|
|
155
|
-
) : /* @__PURE__ */ e.jsx(
|
|
156
|
-
m.div,
|
|
157
|
-
{
|
|
158
|
-
initial: t ? { opacity: 0, scale: 0.8, rotate: -180 } : { opacity: 1, scale: 1, rotate: 0 },
|
|
159
|
-
animate: { opacity: 1, scale: 1, rotate: 0 },
|
|
160
|
-
exit: { opacity: 0, scale: 0.8, rotate: 180 },
|
|
161
|
-
transition: { duration: t ? 0.3 : 0 },
|
|
162
|
-
className: "flex items-center justify-center",
|
|
163
|
-
children: /* @__PURE__ */ e.jsx(
|
|
164
|
-
h,
|
|
165
|
-
{
|
|
166
|
-
icon: k,
|
|
167
|
-
className: "w-14 h-14 min-w-14 min-h-14"
|
|
168
|
-
}
|
|
169
|
-
)
|
|
170
|
-
},
|
|
171
|
-
"clock"
|
|
172
|
-
) })
|
|
173
|
-
}
|
|
174
|
-
)
|
|
175
|
-
}
|
|
176
|
-
),
|
|
177
|
-
/* @__PURE__ */ e.jsx(
|
|
178
|
-
"span",
|
|
179
|
-
{
|
|
180
|
-
className: `text-body-s font-medium transition-all duration-300 text-center w-full ${s || o ? "text-black" : "text-gray-400"}`,
|
|
181
|
-
children: p(u)
|
|
182
|
-
}
|
|
183
|
-
)
|
|
20
|
+
}, I = (t) => {
|
|
21
|
+
const { t: i } = u(), { labelColor: r } = x(t.color);
|
|
22
|
+
return /* @__PURE__ */ e.jsxs("div", { className: "flex flex-col items-center gap-8 h-fit min-w-fit", children: [
|
|
23
|
+
/* @__PURE__ */ e.jsx(v, { ...t }),
|
|
24
|
+
t.label && /* @__PURE__ */ e.jsx("span", { className: `text-body-s transition-all duration-300 text-center font-semibold whitespace-nowrap ${r}`, children: i(t.label) })
|
|
184
25
|
] });
|
|
185
|
-
},
|
|
186
|
-
steps:
|
|
187
|
-
direction:
|
|
188
|
-
color:
|
|
26
|
+
}, D = ({
|
|
27
|
+
steps: t,
|
|
28
|
+
direction: i = "horizontal",
|
|
29
|
+
color: r
|
|
189
30
|
}) => {
|
|
190
|
-
const { defaultColorScheme:
|
|
191
|
-
|
|
192
|
-
const
|
|
193
|
-
(
|
|
31
|
+
const { defaultColorScheme: b } = u(), c = r || b, s = x(c), [S, p] = f([]), [h, g] = f(null), [d, N] = f(!1), j = t.findIndex((o) => !o.completed), m = (o) => j === o;
|
|
32
|
+
w(() => {
|
|
33
|
+
const o = t.map(
|
|
34
|
+
(l, n) => m(n) ? "focus" : l.completed ? "done" : "pending"
|
|
194
35
|
);
|
|
195
|
-
if (!
|
|
196
|
-
|
|
36
|
+
if (!d)
|
|
37
|
+
p(o), N(!0), g(null);
|
|
197
38
|
else {
|
|
198
|
-
const
|
|
199
|
-
(
|
|
39
|
+
const l = o.findIndex(
|
|
40
|
+
(n, a) => n !== S[a]
|
|
200
41
|
);
|
|
201
|
-
|
|
42
|
+
g(l !== -1 ? l : null), p(o);
|
|
202
43
|
}
|
|
203
|
-
}, [
|
|
204
|
-
const
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
44
|
+
}, [t, j]);
|
|
45
|
+
const C = () => /* @__PURE__ */ e.jsx("div", { className: "flex flex-col h-full w-full", children: t.map((o, l) => {
|
|
46
|
+
const n = m(l) ? "focus" : o.completed ? "done" : "pending", a = d && h === l;
|
|
47
|
+
return /* @__PURE__ */ e.jsxs("div", { className: `flex flex-col ${l < t.length - 1 ? "flex-1" : "flex-initial"}`, children: [
|
|
48
|
+
/* @__PURE__ */ e.jsx("div", { className: "flex items-center gap-4 z-10", children: /* @__PURE__ */ e.jsx(
|
|
49
|
+
z,
|
|
50
|
+
{
|
|
51
|
+
index: l,
|
|
52
|
+
status: n,
|
|
53
|
+
shouldAnimate: a,
|
|
54
|
+
label: o.label,
|
|
55
|
+
color: c
|
|
56
|
+
}
|
|
57
|
+
) }),
|
|
58
|
+
l < t.length - 1 && /* @__PURE__ */ e.jsx("div", { className: "flex h-full w-[35px] justify-center my-4", children: /* @__PURE__ */ e.jsx(
|
|
209
59
|
"div",
|
|
210
60
|
{
|
|
211
|
-
className: `
|
|
61
|
+
className: `w-[1.5px] h-full transition-all duration-500 ${n === "done" ? s.lineActiveColor : n === "focus" ? `bg-gradient-to-b ${s.lineGradientFrom} ${s.lineGradientTo}` : ""}`,
|
|
62
|
+
style: {
|
|
63
|
+
backgroundColor: n === "pending" ? s.pendingBgColor : void 0
|
|
64
|
+
}
|
|
212
65
|
}
|
|
213
|
-
)
|
|
214
|
-
|
|
215
|
-
|
|
66
|
+
) })
|
|
67
|
+
] }, l);
|
|
68
|
+
}) }), $ = () => /* @__PURE__ */ e.jsx("div", { className: "w-full flex items-start", children: t.map((o, l) => {
|
|
69
|
+
const n = m(l) ? "focus" : o.completed ? "done" : "pending", a = d && h === l;
|
|
70
|
+
return /* @__PURE__ */ e.jsxs("div", { className: `flex items-start ${l < t.length - 1 ? "flex-1" : "flex-initial"}`, children: [
|
|
71
|
+
/* @__PURE__ */ e.jsx("div", { className: "flex flex-col items-center z-10", children: /* @__PURE__ */ e.jsx(
|
|
72
|
+
I,
|
|
216
73
|
{
|
|
217
|
-
index:
|
|
218
|
-
status:
|
|
219
|
-
shouldAnimate:
|
|
220
|
-
label:
|
|
221
|
-
color:
|
|
74
|
+
index: l,
|
|
75
|
+
status: n,
|
|
76
|
+
shouldAnimate: a,
|
|
77
|
+
label: o.label,
|
|
78
|
+
color: c
|
|
222
79
|
}
|
|
223
|
-
)
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
|
|
227
|
-
|
|
228
|
-
|
|
229
|
-
|
|
230
|
-
className: "flex flex-col items-center justify-evenly w-full gap-2 relative col-span-1",
|
|
231
|
-
children: /* @__PURE__ */ e.jsx(
|
|
232
|
-
W,
|
|
233
|
-
{
|
|
234
|
-
index: r,
|
|
235
|
-
status: d,
|
|
236
|
-
shouldAnimate: x,
|
|
237
|
-
label: n.label,
|
|
238
|
-
color: p
|
|
80
|
+
) }),
|
|
81
|
+
l < t.length - 1 && /* @__PURE__ */ e.jsx(
|
|
82
|
+
"div",
|
|
83
|
+
{
|
|
84
|
+
className: `flex-1 h-[1.5px] mt-[16px] mx-4 transition-all duration-500 ${n === "done" ? s.lineActiveColor : n === "focus" ? `bg-gradient-to-r ${s.lineGradientFrom} ${s.lineGradientTo}` : ""}`,
|
|
85
|
+
style: {
|
|
86
|
+
backgroundColor: n === "pending" ? s.pendingBgColor : void 0
|
|
239
87
|
}
|
|
240
|
-
|
|
241
|
-
|
|
242
|
-
|
|
243
|
-
);
|
|
88
|
+
}
|
|
89
|
+
)
|
|
90
|
+
] }, l);
|
|
244
91
|
}) });
|
|
245
|
-
return
|
|
92
|
+
return i === "horizontal" ? /* @__PURE__ */ e.jsx($, {}) : /* @__PURE__ */ e.jsx(C, {});
|
|
246
93
|
};
|
|
247
94
|
export {
|
|
248
|
-
|
|
95
|
+
D as default
|
|
249
96
|
};
|
|
@@ -1,11 +1,15 @@
|
|
|
1
1
|
import { Color } from '../../../types/styleValues';
|
|
2
2
|
interface StepperColorConfig {
|
|
3
|
+
focusIconColor: string;
|
|
4
|
+
completedIconColor: string;
|
|
5
|
+
pendingIconColor: string;
|
|
6
|
+
labelColor: string;
|
|
7
|
+
focusBgColor: string;
|
|
3
8
|
completedBgColor: string;
|
|
4
|
-
|
|
5
|
-
pendingBorderColor: string;
|
|
6
|
-
iconActiveColor: string;
|
|
9
|
+
pendingBgColor: string;
|
|
7
10
|
lineActiveColor: string;
|
|
8
11
|
lineGradientFrom: string;
|
|
12
|
+
lineGradientTo: string;
|
|
9
13
|
}
|
|
10
14
|
export declare const resolveStepperColors: (color: Color) => StepperColorConfig;
|
|
11
15
|
export {};
|
|
@@ -1,26 +1,34 @@
|
|
|
1
1
|
const e = {
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
2
|
+
focusIconColor: "text-white",
|
|
3
|
+
completedIconColor: "text-blue-500",
|
|
4
|
+
pendingIconColor: "text-blue-500",
|
|
5
|
+
labelColor: "text-blue-500",
|
|
6
|
+
focusBgColor: "#4570EB",
|
|
7
|
+
completedBgColor: "#CAD6F9",
|
|
8
|
+
pendingBgColor: "#ECF1FD",
|
|
9
|
+
lineActiveColor: "bg-blue-200",
|
|
10
|
+
lineGradientFrom: "from-blue-500",
|
|
11
|
+
lineGradientTo: "to-blue-200"
|
|
12
|
+
}, l = {
|
|
13
|
+
focusIconColor: "text-white",
|
|
14
|
+
completedIconColor: "text-aqua-500",
|
|
15
|
+
pendingIconColor: "text-aqua-500",
|
|
16
|
+
labelColor: "text-aqua-500",
|
|
17
|
+
focusBgColor: "#1DA696",
|
|
9
18
|
completedBgColor: "#C7F9F5",
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
}, l = (o) => {
|
|
19
|
+
pendingBgColor: "#C7F9F5",
|
|
20
|
+
lineActiveColor: "bg-aqua-200",
|
|
21
|
+
lineGradientFrom: "from-aqua-500",
|
|
22
|
+
lineGradientTo: "to-aqua-200"
|
|
23
|
+
}, t = (o) => {
|
|
16
24
|
switch (o) {
|
|
17
25
|
case "aqua":
|
|
18
|
-
return
|
|
26
|
+
return l;
|
|
19
27
|
case "blue":
|
|
20
28
|
default:
|
|
21
29
|
return e;
|
|
22
30
|
}
|
|
23
31
|
};
|
|
24
32
|
export {
|
|
25
|
-
|
|
33
|
+
t as resolveStepperColors
|
|
26
34
|
};
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import { ReactNode } from 'react';
|
|
2
|
+
import { IconDefinition } from '@fortawesome/fontawesome-svg-core';
|
|
3
|
+
type TooltipLocation = 'top' | 'bottom' | 'left' | 'right';
|
|
4
|
+
interface TooltipProps {
|
|
5
|
+
text: string;
|
|
6
|
+
children: ReactNode;
|
|
7
|
+
icon?: IconDefinition;
|
|
8
|
+
location?: TooltipLocation;
|
|
9
|
+
childClassName?: string;
|
|
10
|
+
}
|
|
11
|
+
/**
|
|
12
|
+
* Smart Tooltip Component
|
|
13
|
+
* * Automatically detects if the children's text is truncated.
|
|
14
|
+
* The tooltip bubble only appears if the content overflows its container.
|
|
15
|
+
* * Usage Note:
|
|
16
|
+
* By default, it truncates based on the parent's width. To truncate earlier,
|
|
17
|
+
* pass a specific width class to `childClassName` (e.g., `max-w-[200px]`).
|
|
18
|
+
*/
|
|
19
|
+
declare const Tooltip: ({ text, children, icon, location, childClassName }: TooltipProps) => import("react/jsx-runtime").JSX.Element;
|
|
20
|
+
export default Tooltip;
|