@arkyn/components 3.0.1-beta.99 → 3.0.3
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/LICENSE.txt +184 -1
- package/README.md +198 -22
- package/dist/components/alert/alertContainer/index.d.ts +30 -46
- package/dist/components/alert/alertContainer/index.d.ts.map +1 -1
- package/dist/components/alert/alertContent/index.d.ts +12 -37
- package/dist/components/alert/alertContent/index.d.ts.map +1 -1
- package/dist/components/alert/alertDescription/index.d.ts +11 -39
- package/dist/components/alert/alertDescription/index.d.ts.map +1 -1
- package/dist/components/alert/alertIcon/index.d.ts +16 -40
- package/dist/components/alert/alertIcon/index.d.ts.map +1 -1
- package/dist/components/alert/alertTitle/index.d.ts +13 -36
- package/dist/components/alert/alertTitle/index.d.ts.map +1 -1
- package/dist/components/audioPlayer/index.d.ts +25 -33
- package/dist/components/audioPlayer/index.d.ts.map +1 -1
- package/dist/components/audioUpload/hasFileContent/index.d.ts +1 -1
- package/dist/components/audioUpload/hasFileContent/index.d.ts.map +1 -1
- package/dist/components/audioUpload/index.d.ts +38 -49
- package/dist/components/audioUpload/index.d.ts.map +1 -1
- package/dist/components/audioUpload/noFileContent/index.d.ts +1 -1
- package/dist/components/audioUpload/noFileContent/index.d.ts.map +1 -1
- package/dist/components/badge/index.d.ts +34 -25
- package/dist/components/badge/index.d.ts.map +1 -1
- package/dist/components/button/index.d.ts +42 -32
- package/dist/components/button/index.d.ts.map +1 -1
- package/dist/components/calendar/_calendarProvider.d.ts +52 -0
- package/dist/components/calendar/_calendarProvider.d.ts.map +1 -0
- package/dist/components/calendar/_viewService.d.ts +32 -0
- package/dist/components/calendar/_viewService.d.ts.map +1 -0
- package/dist/components/calendar/calendarContainer/index.d.ts +8 -0
- package/dist/components/calendar/calendarContainer/index.d.ts.map +1 -0
- package/dist/components/calendar/calendarHeader/index.d.ts +7 -0
- package/dist/components/calendar/calendarHeader/index.d.ts.map +1 -0
- package/dist/components/calendar/calendarTableBody/index.d.ts +4 -0
- package/dist/components/calendar/calendarTableBody/index.d.ts.map +1 -0
- package/dist/components/calendar/calendarTableContainer/index.d.ts +8 -0
- package/dist/components/calendar/calendarTableContainer/index.d.ts.map +1 -0
- package/dist/components/calendar/calendarTableHeader/index.d.ts +4 -0
- package/dist/components/calendar/calendarTableHeader/index.d.ts.map +1 -0
- package/dist/components/calendar/calendarTableTd/index.d.ts +11 -0
- package/dist/components/calendar/calendarTableTd/index.d.ts.map +1 -0
- package/dist/components/calendar/index.d.ts +100 -0
- package/dist/components/calendar/index.d.ts.map +1 -0
- package/dist/components/cardTab/cardTabButton/index.d.ts +16 -54
- package/dist/components/cardTab/cardTabButton/index.d.ts.map +1 -1
- package/dist/components/cardTab/cardTabContainer/index.d.ts +18 -60
- package/dist/components/cardTab/cardTabContainer/index.d.ts.map +1 -1
- package/dist/components/cardTab/cardTabContext.d.ts +4 -4
- package/dist/components/cardTab/cardTabContext.d.ts.map +1 -1
- package/dist/components/checkbox/index.d.ts +42 -37
- package/dist/components/checkbox/index.d.ts.map +1 -1
- package/dist/components/clientOnly.d.ts +14 -67
- package/dist/components/clientOnly.d.ts.map +1 -1
- package/dist/components/currencyInput/index.d.ts +75 -53
- package/dist/components/currencyInput/index.d.ts.map +1 -1
- package/dist/components/datePicker/datePickerCalendarContainer/index.d.ts +9 -0
- package/dist/components/datePicker/datePickerCalendarContainer/index.d.ts.map +1 -0
- package/dist/components/datePicker/datePickerChevron/index.d.ts +11 -0
- package/dist/components/datePicker/datePickerChevron/index.d.ts.map +1 -0
- package/dist/components/datePicker/datePickerContainer/index.d.ts +19 -0
- package/dist/components/datePicker/datePickerContainer/index.d.ts.map +1 -0
- package/dist/components/datePicker/datePickerContent/index.d.ts +9 -0
- package/dist/components/datePicker/datePickerContent/index.d.ts.map +1 -0
- package/dist/components/datePicker/datePickerOverlay/index.d.ts +8 -0
- package/dist/components/datePicker/datePickerOverlay/index.d.ts.map +1 -0
- package/dist/components/datePicker/datePickerSpinner/index.d.ts +8 -0
- package/dist/components/datePicker/datePickerSpinner/index.d.ts.map +1 -0
- package/dist/components/datePicker/index.d.ts +155 -0
- package/dist/components/datePicker/index.d.ts.map +1 -0
- package/dist/components/divider/index.d.ts +14 -27
- package/dist/components/divider/index.d.ts.map +1 -1
- package/dist/components/drawer/drawerContainer/index.d.ts +18 -52
- package/dist/components/drawer/drawerContainer/index.d.ts.map +1 -1
- package/dist/components/drawer/drawerContext.d.ts +2 -2
- package/dist/components/drawer/drawerContext.d.ts.map +1 -1
- package/dist/components/drawer/drawerHeader/index.d.ts +11 -35
- package/dist/components/drawer/drawerHeader/index.d.ts.map +1 -1
- package/dist/components/facebookPixel/facebookPixel.client.d.ts +4 -0
- package/dist/components/facebookPixel/facebookPixel.client.d.ts.map +1 -0
- package/dist/components/facebookPixel/index.d.ts +65 -0
- package/dist/components/facebookPixel/index.d.ts.map +1 -0
- package/dist/components/facebookPixel/pixel.d.ts +21 -0
- package/dist/components/facebookPixel/pixel.d.ts.map +1 -0
- package/dist/components/fieldError/index.d.ts +6 -13
- package/dist/components/fieldError/index.d.ts.map +1 -1
- package/dist/components/fieldLabel/index.d.ts +8 -23
- package/dist/components/fieldLabel/index.d.ts.map +1 -1
- package/dist/components/fieldWrapper/index.d.ts +14 -24
- package/dist/components/fieldWrapper/index.d.ts.map +1 -1
- package/dist/components/fileUpload/hasFileContent/index.d.ts +1 -1
- package/dist/components/fileUpload/hasFileContent/index.d.ts.map +1 -1
- package/dist/components/fileUpload/index.d.ts +37 -62
- package/dist/components/fileUpload/index.d.ts.map +1 -1
- package/dist/components/fileUpload/noFileContent/index.d.ts +1 -1
- package/dist/components/fileUpload/noFileContent/index.d.ts.map +1 -1
- package/dist/components/fullCalendar/_fullCalendarProvider.d.ts +44 -0
- package/dist/components/fullCalendar/_fullCalendarProvider.d.ts.map +1 -0
- package/dist/components/fullCalendar/_viewService.d.ts +28 -0
- package/dist/components/fullCalendar/_viewService.d.ts.map +1 -0
- package/dist/components/fullCalendar/dayCalendar/dayCalendarContainer/index.d.ts +8 -0
- package/dist/components/fullCalendar/dayCalendar/dayCalendarContainer/index.d.ts.map +1 -0
- package/dist/components/fullCalendar/dayCalendar/dayCalendarEvent/index.d.ts +7 -0
- package/dist/components/fullCalendar/dayCalendar/dayCalendarEvent/index.d.ts.map +1 -0
- package/dist/components/fullCalendar/dayCalendar/dayCalendarRow/index.d.ts +8 -0
- package/dist/components/fullCalendar/dayCalendar/dayCalendarRow/index.d.ts.map +1 -0
- package/dist/components/fullCalendar/dayCalendar/index.d.ts +3 -0
- package/dist/components/fullCalendar/dayCalendar/index.d.ts.map +1 -0
- package/dist/components/fullCalendar/fullCalendarContainer/index.d.ts +8 -0
- package/dist/components/fullCalendar/fullCalendarContainer/index.d.ts.map +1 -0
- package/dist/components/fullCalendar/fullCalendarHeader/index.d.ts +8 -0
- package/dist/components/fullCalendar/fullCalendarHeader/index.d.ts.map +1 -0
- package/dist/components/fullCalendar/index.d.ts +94 -0
- package/dist/components/fullCalendar/index.d.ts.map +1 -0
- package/dist/components/fullCalendar/monthlyCalendar/index.d.ts +3 -0
- package/dist/components/fullCalendar/monthlyCalendar/index.d.ts.map +1 -0
- package/dist/components/fullCalendar/monthlyCalendar/monthlyCalendarEvent/index.d.ts +9 -0
- package/dist/components/fullCalendar/monthlyCalendar/monthlyCalendarEvent/index.d.ts.map +1 -0
- package/dist/components/fullCalendar/monthlyCalendar/monthlyCalendarTableBody/index.d.ts +4 -0
- package/dist/components/fullCalendar/monthlyCalendar/monthlyCalendarTableBody/index.d.ts.map +1 -0
- package/dist/components/fullCalendar/monthlyCalendar/monthlyCalendarTableContainer/index.d.ts +8 -0
- package/dist/components/fullCalendar/monthlyCalendar/monthlyCalendarTableContainer/index.d.ts.map +1 -0
- package/dist/components/fullCalendar/monthlyCalendar/monthlyCalendarTableHeader/index.d.ts +4 -0
- package/dist/components/fullCalendar/monthlyCalendar/monthlyCalendarTableHeader/index.d.ts.map +1 -0
- package/dist/components/fullCalendar/monthlyCalendar/monthlyCalendarTableTd/index.d.ts +10 -0
- package/dist/components/fullCalendar/monthlyCalendar/monthlyCalendarTableTd/index.d.ts.map +1 -0
- package/dist/components/fullCalendar/weekCalendar/index.d.ts +3 -0
- package/dist/components/fullCalendar/weekCalendar/index.d.ts.map +1 -0
- package/dist/components/fullCalendar/weekCalendar/weekCalendarEvent/index.d.ts +10 -0
- package/dist/components/fullCalendar/weekCalendar/weekCalendarEvent/index.d.ts.map +1 -0
- package/dist/components/fullCalendar/weekCalendar/weekCalendarTableBody/index.d.ts +4 -0
- package/dist/components/fullCalendar/weekCalendar/weekCalendarTableBody/index.d.ts.map +1 -0
- package/dist/components/fullCalendar/weekCalendar/weekCalendarTableContainer/index.d.ts +8 -0
- package/dist/components/fullCalendar/weekCalendar/weekCalendarTableContainer/index.d.ts.map +1 -0
- package/dist/components/fullCalendar/weekCalendar/weekCalendarTableHeader/index.d.ts +4 -0
- package/dist/components/fullCalendar/weekCalendar/weekCalendarTableHeader/index.d.ts.map +1 -0
- package/dist/components/fullCalendar/weekCalendar/weekCalendarTableTd/index.d.ts +11 -0
- package/dist/components/fullCalendar/weekCalendar/weekCalendarTableTd/index.d.ts.map +1 -0
- package/dist/components/googleAnalytics/googleAnalytics.client.d.ts +6 -0
- package/dist/components/googleAnalytics/googleAnalytics.client.d.ts.map +1 -0
- package/dist/components/googleAnalytics/googleAnalytics.d.ts +10 -0
- package/dist/components/googleAnalytics/googleAnalytics.d.ts.map +1 -0
- package/dist/components/googleAnalytics/index.d.ts +30 -0
- package/dist/components/googleAnalytics/index.d.ts.map +1 -0
- package/dist/components/googleAnalytics/snippets/generateGAElements.d.ts +9 -0
- package/dist/components/googleAnalytics/snippets/generateGAElements.d.ts.map +1 -0
- package/dist/components/googleTagManager/googleTagManager.client.d.ts +11 -0
- package/dist/components/googleTagManager/googleTagManager.client.d.ts.map +1 -0
- package/dist/components/googleTagManager/googleTagManager.d.ts +20 -0
- package/dist/components/googleTagManager/googleTagManager.d.ts.map +1 -0
- package/dist/components/googleTagManager/index.d.ts +55 -0
- package/dist/components/googleTagManager/index.d.ts.map +1 -0
- package/dist/components/googleTagManager/snippets/appendToDataLayer.d.ts +7 -0
- package/dist/components/googleTagManager/snippets/appendToDataLayer.d.ts.map +1 -0
- package/dist/components/googleTagManager/snippets/generateGTMElements.d.ts +15 -0
- package/dist/components/googleTagManager/snippets/generateGTMElements.d.ts.map +1 -0
- package/dist/components/iconButton/index.d.ts +35 -19
- package/dist/components/iconButton/index.d.ts.map +1 -1
- package/dist/components/imageUpload/hasFileContent/index.d.ts +1 -1
- package/dist/components/imageUpload/hasFileContent/index.d.ts.map +1 -1
- package/dist/components/imageUpload/index.d.ts +51 -75
- package/dist/components/imageUpload/index.d.ts.map +1 -1
- package/dist/components/imageUpload/noFileContent/index.d.ts +1 -1
- package/dist/components/imageUpload/noFileContent/index.d.ts.map +1 -1
- package/dist/components/input/index.d.ts +58 -47
- package/dist/components/input/index.d.ts.map +1 -1
- package/dist/components/mapView/index.d.ts +55 -7
- package/dist/components/mapView/index.d.ts.map +1 -1
- package/dist/components/mapView/mapView.client.d.ts +17 -0
- package/dist/components/mapView/mapView.client.d.ts.map +1 -0
- package/dist/components/maskedInput/index.d.ts +71 -56
- package/dist/components/maskedInput/index.d.ts.map +1 -1
- package/dist/components/modal/modalContainer/index.d.ts +19 -59
- package/dist/components/modal/modalContainer/index.d.ts.map +1 -1
- package/dist/components/modal/modalContext.d.ts +2 -2
- package/dist/components/modal/modalContext.d.ts.map +1 -1
- package/dist/components/modal/modalFooter/index.d.ts +19 -52
- package/dist/components/modal/modalFooter/index.d.ts.map +1 -1
- package/dist/components/modal/modalHeader/index.d.ts +15 -49
- package/dist/components/modal/modalHeader/index.d.ts.map +1 -1
- package/dist/components/multiSelect/index.d.ts +72 -63
- package/dist/components/multiSelect/index.d.ts.map +1 -1
- package/dist/components/multiSelect/multiSelectChevron/index.d.ts +1 -1
- package/dist/components/multiSelect/multiSelectChevron/index.d.ts.map +1 -1
- package/dist/components/multiSelect/multiSelectContainer/index.d.ts +2 -2
- package/dist/components/multiSelect/multiSelectContainer/index.d.ts.map +1 -1
- package/dist/components/multiSelect/multiSelectContent/index.d.ts +2 -2
- package/dist/components/multiSelect/multiSelectContent/index.d.ts.map +1 -1
- package/dist/components/multiSelect/multiSelectMark/index.d.ts +1 -1
- package/dist/components/multiSelect/multiSelectMark/index.d.ts.map +1 -1
- package/dist/components/multiSelect/multiSelectOption/index.d.ts +1 -1
- package/dist/components/multiSelect/multiSelectOption/index.d.ts.map +1 -1
- package/dist/components/multiSelect/multiSelectOptionsContainer/index.d.ts +2 -2
- package/dist/components/multiSelect/multiSelectOptionsContainer/index.d.ts.map +1 -1
- package/dist/components/multiSelect/multiSelectOverlay/index.d.ts +1 -1
- package/dist/components/multiSelect/multiSelectOverlay/index.d.ts.map +1 -1
- package/dist/components/multiSelect/multiSelectSpinner/index.d.ts +1 -1
- package/dist/components/multiSelect/multiSelectSpinner/index.d.ts.map +1 -1
- package/dist/components/pagination/chevronButton/index.d.ts +1 -1
- package/dist/components/pagination/chevronButton/index.d.ts.map +1 -1
- package/dist/components/pagination/currentButton/index.d.ts +1 -1
- package/dist/components/pagination/currentButton/index.d.ts.map +1 -1
- package/dist/components/pagination/index.d.ts +20 -11
- package/dist/components/pagination/index.d.ts.map +1 -1
- package/dist/components/pagination/pageButton/index.d.ts +1 -1
- package/dist/components/pagination/pageButton/index.d.ts.map +1 -1
- package/dist/components/pagination/paginationService.d.ts.map +1 -1
- package/dist/components/pagination/spread/index.d.ts +1 -1
- package/dist/components/pagination/spread/index.d.ts.map +1 -1
- package/dist/components/phoneInput/index.d.ts +68 -89
- package/dist/components/phoneInput/index.d.ts.map +1 -1
- package/dist/components/phoneInput/phoneInputContainer/index.d.ts +2 -2
- package/dist/components/phoneInput/phoneInputContainer/index.d.ts.map +1 -1
- package/dist/components/phoneInput/phoneInputCountriesOverlay/index.d.ts +1 -1
- package/dist/components/phoneInput/phoneInputCountriesOverlay/index.d.ts.map +1 -1
- package/dist/components/phoneInput/phoneInputCountryOption/index.d.ts +2 -3
- package/dist/components/phoneInput/phoneInputCountryOption/index.d.ts.map +1 -1
- package/dist/components/phoneInput/phoneInputCountryOptionsContainer/index.d.ts +2 -2
- package/dist/components/phoneInput/phoneInputCountryOptionsContainer/index.d.ts.map +1 -1
- package/dist/components/phoneInput/phoneInputCountrySelector/index.d.ts +2 -3
- package/dist/components/phoneInput/phoneInputCountrySelector/index.d.ts.map +1 -1
- package/dist/components/phoneInput/phoneInputMask/index.d.ts +1 -2
- package/dist/components/phoneInput/phoneInputMask/index.d.ts.map +1 -1
- package/dist/components/popover/index.d.ts +36 -116
- package/dist/components/popover/index.d.ts.map +1 -1
- package/dist/components/radio/radioBox/index.d.ts +19 -67
- package/dist/components/radio/radioBox/index.d.ts.map +1 -1
- package/dist/components/radio/radioContext.d.ts +2 -2
- package/dist/components/radio/radioContext.d.ts.map +1 -1
- package/dist/components/radio/radioGroup/index.d.ts +40 -67
- package/dist/components/radio/radioGroup/index.d.ts.map +1 -1
- package/dist/components/richText/blockButton/index.d.ts +3 -3
- package/dist/components/richText/blockButton/index.d.ts.map +1 -1
- package/dist/components/richText/element/index.d.ts +2 -2
- package/dist/components/richText/element/index.d.ts.map +1 -1
- package/dist/components/richText/index.d.ts +35 -47
- package/dist/components/richText/index.d.ts.map +1 -1
- package/dist/components/richText/insertImage/index.d.ts +2 -2
- package/dist/components/richText/insertImage/index.d.ts.map +1 -1
- package/dist/components/richText/insertVideo/index.d.ts +5 -0
- package/dist/components/richText/insertVideo/index.d.ts.map +1 -0
- package/dist/components/richText/leaf/index.d.ts +2 -2
- package/dist/components/richText/leaf/index.d.ts.map +1 -1
- package/dist/components/richText/markButton/index.d.ts +3 -3
- package/dist/components/richText/markButton/index.d.ts.map +1 -1
- package/dist/components/richText/toolbar/index.d.ts +2 -2
- package/dist/components/richText/toolbar/index.d.ts.map +1 -1
- package/dist/components/searchPlaces.d.ts +55 -52
- package/dist/components/searchPlaces.d.ts.map +1 -1
- package/dist/components/select/index.d.ts +73 -64
- package/dist/components/select/index.d.ts.map +1 -1
- package/dist/components/select/selectChevron/index.d.ts +1 -1
- package/dist/components/select/selectChevron/index.d.ts.map +1 -1
- package/dist/components/select/selectContainer/index.d.ts +2 -2
- package/dist/components/select/selectContainer/index.d.ts.map +1 -1
- package/dist/components/select/selectContent/index.d.ts +2 -2
- package/dist/components/select/selectContent/index.d.ts.map +1 -1
- package/dist/components/select/selectOption/index.d.ts +1 -1
- package/dist/components/select/selectOption/index.d.ts.map +1 -1
- package/dist/components/select/selectOptionsContainer/index.d.ts +2 -2
- package/dist/components/select/selectOptionsContainer/index.d.ts.map +1 -1
- package/dist/components/select/selectOverlay/index.d.ts +1 -1
- package/dist/components/select/selectOverlay/index.d.ts.map +1 -1
- package/dist/components/select/selectSpinner/index.d.ts +1 -1
- package/dist/components/select/selectSpinner/index.d.ts.map +1 -1
- package/dist/components/slider/index.d.ts +22 -36
- package/dist/components/slider/index.d.ts.map +1 -1
- package/dist/components/switch/index.d.ts +46 -58
- package/dist/components/switch/index.d.ts.map +1 -1
- package/dist/components/tab/tabButton/index.d.ts +16 -54
- package/dist/components/tab/tabButton/index.d.ts.map +1 -1
- package/dist/components/tab/tabContainer/index.d.ts +18 -60
- package/dist/components/tab/tabContainer/index.d.ts.map +1 -1
- package/dist/components/tab/tabContext.d.ts +2 -2
- package/dist/components/tab/tabContext.d.ts.map +1 -1
- package/dist/components/table/tableBody/index.d.ts +15 -49
- package/dist/components/table/tableBody/index.d.ts.map +1 -1
- package/dist/components/table/tableCaption/index.d.ts +8 -48
- package/dist/components/table/tableCaption/index.d.ts.map +1 -1
- package/dist/components/table/tableContainer/index.d.ts +14 -43
- package/dist/components/table/tableContainer/index.d.ts.map +1 -1
- package/dist/components/table/tableFooter/index.d.ts +7 -31
- package/dist/components/table/tableFooter/index.d.ts.map +1 -1
- package/dist/components/table/tableHeader/index.d.ts +6 -27
- package/dist/components/table/tableHeader/index.d.ts.map +1 -1
- package/dist/components/textarea/index.d.ts +36 -68
- package/dist/components/textarea/index.d.ts.map +1 -1
- package/dist/components/tooltip/index.d.ts +29 -57
- package/dist/components/tooltip/index.d.ts.map +1 -1
- package/dist/hooks/useAutomation.d.ts +22 -25
- package/dist/hooks/useAutomation.d.ts.map +1 -1
- package/dist/hooks/useDrawer.d.ts +20 -65
- package/dist/hooks/useDrawer.d.ts.map +1 -1
- package/dist/hooks/useForm.d.ts +12 -29
- package/dist/hooks/useForm.d.ts.map +1 -1
- package/dist/hooks/useHydrated.d.ts +8 -63
- package/dist/hooks/useHydrated.d.ts.map +1 -1
- package/dist/hooks/useModal.d.ts +20 -60
- package/dist/hooks/useModal.d.ts.map +1 -1
- package/dist/hooks/useScopedParams.d.ts +18 -70
- package/dist/hooks/useScopedParams.d.ts.map +1 -1
- package/dist/hooks/useScrollLock.d.ts +11 -27
- package/dist/hooks/useScrollLock.d.ts.map +1 -1
- package/dist/hooks/useSearchAutomation.d.ts +31 -0
- package/dist/hooks/useSearchAutomation.d.ts.map +1 -0
- package/dist/hooks/useSlider.d.ts +5 -19
- package/dist/hooks/useSlider.d.ts.map +1 -1
- package/dist/hooks/useToast.d.ts +8 -52
- package/dist/hooks/useToast.d.ts.map +1 -1
- package/dist/index.d.ts +7 -0
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +4644 -69
- package/dist/index.js.map +1 -0
- package/dist/modules/components/alert/alertContainer/index.js +29 -0
- package/dist/modules/components/alert/alertContainer/index.js.map +1 -0
- package/dist/modules/components/alert/alertContainer/styles.css +3 -0
- package/dist/modules/components/alert/alertContent/index.js +14 -0
- package/dist/modules/components/alert/alertContent/index.js.map +1 -0
- package/dist/modules/components/alert/alertContent/styles.css +1 -0
- package/dist/modules/components/alert/alertDescription/index.js +14 -0
- package/dist/modules/components/alert/alertDescription/index.js.map +1 -0
- package/dist/modules/components/alert/alertDescription/styles.css +1 -0
- package/dist/modules/components/alert/alertIcon/index.js +30 -0
- package/dist/modules/components/alert/alertIcon/index.js.map +1 -0
- package/dist/modules/components/alert/alertIcon/styles.css +7 -0
- package/dist/modules/components/alert/alertTitle/index.js +14 -0
- package/dist/modules/components/alert/alertTitle/index.js.map +1 -0
- package/dist/modules/components/alert/alertTitle/styles.css +1 -0
- package/dist/modules/components/audioPlayer/index.js +77 -0
- package/dist/modules/components/audioPlayer/index.js.map +1 -0
- package/dist/modules/components/audioPlayer/styles.css +3 -0
- package/dist/modules/components/audioUpload/hasFileContent/index.js +57 -0
- package/dist/modules/components/audioUpload/hasFileContent/index.js.map +1 -0
- package/dist/modules/components/audioUpload/hasFileContent/styles.css +1 -0
- package/dist/modules/components/audioUpload/index.js +74 -0
- package/dist/modules/components/audioUpload/index.js.map +1 -0
- package/dist/modules/components/audioUpload/noFileContent/index.js +38 -0
- package/dist/modules/components/audioUpload/noFileContent/index.js.map +1 -0
- package/dist/modules/components/audioUpload/noFileContent/styles.css +1 -0
- package/dist/modules/components/audioUpload/styles.css +25 -0
- package/dist/modules/components/badge/index.js +29 -0
- package/dist/modules/components/badge/index.js.map +1 -0
- package/dist/modules/components/badge/styles.css +1 -0
- package/dist/modules/components/button/index.js +42 -0
- package/dist/modules/components/button/index.js.map +1 -0
- package/dist/modules/components/button/styles.css +1 -0
- package/dist/modules/components/calendar/_calendarProvider.js +42 -0
- package/dist/modules/components/calendar/_calendarProvider.js.map +1 -0
- package/dist/modules/components/calendar/_viewService.js +135 -0
- package/dist/modules/components/calendar/_viewService.js.map +1 -0
- package/dist/modules/components/calendar/calendarContainer/index.js +13 -0
- package/dist/modules/components/calendar/calendarContainer/index.js.map +1 -0
- package/dist/modules/components/calendar/calendarContainer/styles.css +1 -0
- package/dist/modules/components/calendar/calendarHeader/index.js +58 -0
- package/dist/modules/components/calendar/calendarHeader/index.js.map +1 -0
- package/dist/modules/components/calendar/calendarHeader/styles.css +1 -0
- package/dist/modules/components/calendar/calendarTableBody/index.js +15 -0
- package/dist/modules/components/calendar/calendarTableBody/index.js.map +1 -0
- package/dist/modules/components/calendar/calendarTableBody/styles.css +1 -0
- package/dist/modules/components/calendar/calendarTableContainer/index.js +13 -0
- package/dist/modules/components/calendar/calendarTableContainer/index.js.map +1 -0
- package/dist/modules/components/calendar/calendarTableContainer/styles.css +1 -0
- package/dist/modules/components/calendar/calendarTableHeader/index.js +16 -0
- package/dist/modules/components/calendar/calendarTableHeader/index.js.map +1 -0
- package/dist/modules/components/calendar/calendarTableHeader/styles.css +1 -0
- package/dist/modules/components/calendar/calendarTableTd/index.js +23 -0
- package/dist/modules/components/calendar/calendarTableTd/index.js.map +1 -0
- package/dist/modules/components/calendar/calendarTableTd/styles.css +1 -0
- package/dist/modules/components/calendar/index.js +34 -0
- package/dist/modules/components/calendar/index.js.map +1 -0
- package/dist/modules/components/calendar/styles.css +33 -0
- package/dist/modules/components/cardTab/cardTabButton/index.js +22 -0
- package/dist/modules/components/cardTab/cardTabButton/index.js.map +1 -0
- package/dist/modules/components/cardTab/cardTabButton/styles.css +1 -0
- package/dist/modules/components/cardTab/cardTabContainer/index.js +25 -0
- package/dist/modules/components/cardTab/cardTabContainer/index.js.map +1 -0
- package/dist/modules/components/cardTab/cardTabContainer/styles.css +1 -0
- package/dist/modules/components/cardTab/cardTabContext.js +26 -0
- package/dist/modules/components/cardTab/cardTabContext.js.map +1 -0
- package/dist/modules/components/checkbox/index.js +40 -0
- package/dist/modules/components/checkbox/index.js.map +1 -0
- package/dist/modules/components/checkbox/styles.css +7 -0
- package/dist/modules/components/clientOnly.js +10 -0
- package/dist/modules/components/clientOnly.js.map +1 -0
- package/dist/modules/components/currencyInput/index.js +114 -0
- package/dist/modules/components/currencyInput/index.js.map +1 -0
- package/dist/modules/components/currencyInput/style.css +1 -0
- package/dist/modules/components/currencyInput/styles.css +7 -0
- package/dist/modules/components/datePicker/datePickerCalendarContainer/index.js +25 -0
- package/dist/modules/components/datePicker/datePickerCalendarContainer/index.js.map +1 -0
- package/dist/modules/components/datePicker/datePickerCalendarContainer/styles.css +1 -0
- package/dist/modules/components/datePicker/datePickerChevron/index.js +21 -0
- package/dist/modules/components/datePicker/datePickerChevron/index.js.map +1 -0
- package/dist/modules/components/datePicker/datePickerChevron/styles.css +1 -0
- package/dist/modules/components/datePicker/datePickerContainer/index.js +16 -0
- package/dist/modules/components/datePicker/datePickerContainer/index.js.map +1 -0
- package/dist/modules/components/datePicker/datePickerContainer/styles.css +1 -0
- package/dist/modules/components/datePicker/datePickerContent/index.js +14 -0
- package/dist/modules/components/datePicker/datePickerContent/index.js.map +1 -0
- package/dist/modules/components/datePicker/datePickerContent/styles.css +1 -0
- package/dist/modules/components/datePicker/datePickerOverlay/index.js +14 -0
- package/dist/modules/components/datePicker/datePickerOverlay/index.js.map +1 -0
- package/dist/modules/components/datePicker/datePickerOverlay/styles.css +1 -0
- package/dist/modules/components/datePicker/datePickerSpinner/index.js +16 -0
- package/dist/modules/components/datePicker/datePickerSpinner/index.js.map +1 -0
- package/dist/modules/components/datePicker/datePickerSpinner/styles.css +1 -0
- package/dist/modules/components/datePicker/index.js +194 -0
- package/dist/modules/components/datePicker/index.js.map +1 -0
- package/dist/modules/components/datePicker/styles.css +79 -0
- package/dist/modules/components/divider/index.js +14 -0
- package/dist/modules/components/divider/index.js.map +1 -0
- package/dist/modules/components/divider/styles.css +1 -0
- package/dist/modules/components/drawer/drawerContainer/index.js +39 -0
- package/dist/modules/components/drawer/drawerContainer/index.js.map +1 -0
- package/dist/modules/components/drawer/drawerContainer/styles.css +1 -0
- package/dist/modules/components/drawer/drawerContext.js +18 -0
- package/dist/modules/components/drawer/drawerContext.js.map +1 -0
- package/dist/modules/components/drawer/drawerHeader/index.js +23 -0
- package/dist/modules/components/drawer/drawerHeader/index.js.map +1 -0
- package/dist/modules/components/drawer/drawerHeader/styles.css +1 -0
- package/dist/modules/components/facebookPixel/facebookPixel.client.js +10 -0
- package/dist/modules/components/facebookPixel/facebookPixel.client.js.map +1 -0
- package/dist/modules/components/facebookPixel/index.js +11 -0
- package/dist/modules/components/facebookPixel/index.js.map +1 -0
- package/dist/modules/components/facebookPixel/pixel.js +50 -0
- package/dist/modules/components/facebookPixel/pixel.js.map +1 -0
- package/dist/modules/components/fieldError/index.js +15 -0
- package/dist/modules/components/fieldError/index.js.map +1 -0
- package/dist/modules/components/fieldError/styles.css +1 -0
- package/dist/modules/components/fieldLabel/index.js +14 -0
- package/dist/modules/components/fieldLabel/index.js.map +1 -0
- package/dist/modules/components/fieldLabel/styles.css +1 -0
- package/dist/modules/components/fieldWrapper/index.js +15 -0
- package/dist/modules/components/fieldWrapper/index.js.map +1 -0
- package/dist/modules/components/fieldWrapper/styles.css +1 -0
- package/dist/modules/components/fileUpload/hasFileContent/index.js +62 -0
- package/dist/modules/components/fileUpload/hasFileContent/index.js.map +1 -0
- package/dist/modules/components/fileUpload/hasFileContent/styles.css +1 -0
- package/dist/modules/components/fileUpload/index.js +68 -0
- package/dist/modules/components/fileUpload/index.js.map +1 -0
- package/dist/modules/components/fileUpload/noFileContent/index.js +38 -0
- package/dist/modules/components/fileUpload/noFileContent/index.js.map +1 -0
- package/dist/modules/components/fileUpload/noFileContent/styles.css +1 -0
- package/dist/modules/components/fileUpload/styles.css +19 -0
- package/dist/modules/components/fullCalendar/_fullCalendarProvider.js +37 -0
- package/dist/modules/components/fullCalendar/_fullCalendarProvider.js.map +1 -0
- package/dist/modules/components/fullCalendar/_viewService.js +103 -0
- package/dist/modules/components/fullCalendar/_viewService.js.map +1 -0
- package/dist/modules/components/fullCalendar/dayCalendar/dayCalendarContainer/index.js +13 -0
- package/dist/modules/components/fullCalendar/dayCalendar/dayCalendarContainer/index.js.map +1 -0
- package/dist/modules/components/fullCalendar/dayCalendar/dayCalendarContainer/styles.css +1 -0
- package/dist/modules/components/fullCalendar/dayCalendar/dayCalendarEvent/index.js +73 -0
- package/dist/modules/components/fullCalendar/dayCalendar/dayCalendarEvent/index.js.map +1 -0
- package/dist/modules/components/fullCalendar/dayCalendar/dayCalendarEvent/styles.css +1 -0
- package/dist/modules/components/fullCalendar/dayCalendar/dayCalendarRow/index.js +31 -0
- package/dist/modules/components/fullCalendar/dayCalendar/dayCalendarRow/index.js.map +1 -0
- package/dist/modules/components/fullCalendar/dayCalendar/dayCalendarRow/styles.css +1 -0
- package/dist/modules/components/fullCalendar/dayCalendar/index.js +16 -0
- package/dist/modules/components/fullCalendar/dayCalendar/index.js.map +1 -0
- package/dist/modules/components/fullCalendar/fullCalendarContainer/index.js +13 -0
- package/dist/modules/components/fullCalendar/fullCalendarContainer/index.js.map +1 -0
- package/dist/modules/components/fullCalendar/fullCalendarContainer/styles.css +1 -0
- package/dist/modules/components/fullCalendar/fullCalendarHeader/index.js +71 -0
- package/dist/modules/components/fullCalendar/fullCalendarHeader/index.js.map +1 -0
- package/dist/modules/components/fullCalendar/fullCalendarHeader/styles.css +1 -0
- package/dist/modules/components/fullCalendar/index.js +33 -0
- package/dist/modules/components/fullCalendar/index.js.map +1 -0
- package/dist/modules/components/fullCalendar/monthlyCalendar/index.js +12 -0
- package/dist/modules/components/fullCalendar/monthlyCalendar/index.js.map +1 -0
- package/dist/modules/components/fullCalendar/monthlyCalendar/monthlyCalendarEvent/index.js +31 -0
- package/dist/modules/components/fullCalendar/monthlyCalendar/monthlyCalendarEvent/index.js.map +1 -0
- package/dist/modules/components/fullCalendar/monthlyCalendar/monthlyCalendarEvent/styles.css +1 -0
- package/dist/modules/components/fullCalendar/monthlyCalendar/monthlyCalendarTableBody/index.js +15 -0
- package/dist/modules/components/fullCalendar/monthlyCalendar/monthlyCalendarTableBody/index.js.map +1 -0
- package/dist/modules/components/fullCalendar/monthlyCalendar/monthlyCalendarTableBody/styles.css +1 -0
- package/dist/modules/components/fullCalendar/monthlyCalendar/monthlyCalendarTableContainer/index.js +13 -0
- package/dist/modules/components/fullCalendar/monthlyCalendar/monthlyCalendarTableContainer/index.js.map +1 -0
- package/dist/modules/components/fullCalendar/monthlyCalendar/monthlyCalendarTableContainer/styles.css +1 -0
- package/dist/modules/components/fullCalendar/monthlyCalendar/monthlyCalendarTableHeader/index.js +16 -0
- package/dist/modules/components/fullCalendar/monthlyCalendar/monthlyCalendarTableHeader/index.js.map +1 -0
- package/dist/modules/components/fullCalendar/monthlyCalendar/monthlyCalendarTableHeader/styles.css +1 -0
- package/dist/modules/components/fullCalendar/monthlyCalendar/monthlyCalendarTableTd/index.js +38 -0
- package/dist/modules/components/fullCalendar/monthlyCalendar/monthlyCalendarTableTd/index.js.map +1 -0
- package/dist/modules/components/fullCalendar/monthlyCalendar/monthlyCalendarTableTd/styles.css +1 -0
- package/dist/modules/components/fullCalendar/styles.css +35 -0
- package/dist/modules/components/fullCalendar/weekCalendar/index.js +12 -0
- package/dist/modules/components/fullCalendar/weekCalendar/index.js.map +1 -0
- package/dist/modules/components/fullCalendar/weekCalendar/weekCalendarEvent/index.js +73 -0
- package/dist/modules/components/fullCalendar/weekCalendar/weekCalendarEvent/index.js.map +1 -0
- package/dist/modules/components/fullCalendar/weekCalendar/weekCalendarEvent/styles.css +1 -0
- package/dist/modules/components/fullCalendar/weekCalendar/weekCalendarTableBody/index.js +20 -0
- package/dist/modules/components/fullCalendar/weekCalendar/weekCalendarTableBody/index.js.map +1 -0
- package/dist/modules/components/fullCalendar/weekCalendar/weekCalendarTableBody/styles.css +1 -0
- package/dist/modules/components/fullCalendar/weekCalendar/weekCalendarTableContainer/index.js +13 -0
- package/dist/modules/components/fullCalendar/weekCalendar/weekCalendarTableContainer/index.js.map +1 -0
- package/dist/modules/components/fullCalendar/weekCalendar/weekCalendarTableContainer/styles.css +1 -0
- package/dist/modules/components/fullCalendar/weekCalendar/weekCalendarTableHeader/index.js +19 -0
- package/dist/modules/components/fullCalendar/weekCalendar/weekCalendarTableHeader/index.js.map +1 -0
- package/dist/modules/components/fullCalendar/weekCalendar/weekCalendarTableHeader/styles.css +1 -0
- package/dist/modules/components/fullCalendar/weekCalendar/weekCalendarTableTd/index.js +37 -0
- package/dist/modules/components/fullCalendar/weekCalendar/weekCalendarTableTd/index.js.map +1 -0
- package/dist/modules/components/fullCalendar/weekCalendar/weekCalendarTableTd/styles.css +1 -0
- package/dist/modules/components/googleAnalytics/googleAnalytics.client.js +9 -0
- package/dist/modules/components/googleAnalytics/googleAnalytics.client.js.map +1 -0
- package/dist/modules/components/googleAnalytics/googleAnalytics.js +20 -0
- package/dist/modules/components/googleAnalytics/googleAnalytics.js.map +1 -0
- package/dist/modules/components/googleAnalytics/index.js +12 -0
- package/dist/modules/components/googleAnalytics/index.js.map +1 -0
- package/dist/modules/components/googleAnalytics/snippets/generateGAElements.js +16 -0
- package/dist/modules/components/googleAnalytics/snippets/generateGAElements.js.map +1 -0
- package/dist/modules/components/googleTagManager/googleTagManager.client.js +9 -0
- package/dist/modules/components/googleTagManager/googleTagManager.client.js.map +1 -0
- package/dist/modules/components/googleTagManager/googleTagManager.js +47 -0
- package/dist/modules/components/googleTagManager/googleTagManager.js.map +1 -0
- package/dist/modules/components/googleTagManager/index.js +19 -0
- package/dist/modules/components/googleTagManager/index.js.map +1 -0
- package/dist/modules/components/googleTagManager/snippets/appendToDataLayer.js +11 -0
- package/dist/modules/components/googleTagManager/snippets/appendToDataLayer.js.map +1 -0
- package/dist/modules/components/googleTagManager/snippets/generateGTMElements.js +25 -0
- package/dist/modules/components/googleTagManager/snippets/generateGTMElements.js.map +1 -0
- package/dist/modules/components/iconButton/index.js +34 -0
- package/dist/modules/components/iconButton/index.js.map +1 -0
- package/dist/modules/components/iconButton/styles.css +1 -0
- package/dist/modules/components/imageUpload/hasFileContent/index.js +49 -0
- package/dist/modules/components/imageUpload/hasFileContent/index.js.map +1 -0
- package/dist/modules/components/imageUpload/hasFileContent/styles.css +1 -0
- package/dist/modules/components/imageUpload/index.js +68 -0
- package/dist/modules/components/imageUpload/index.js.map +1 -0
- package/dist/modules/components/imageUpload/noFileContent/index.js +38 -0
- package/dist/modules/components/imageUpload/noFileContent/index.js.map +1 -0
- package/dist/modules/components/imageUpload/noFileContent/styles.css +1 -0
- package/dist/modules/components/imageUpload/styles.css +17 -0
- package/dist/modules/components/input/index.js +95 -0
- package/dist/modules/components/input/index.js.map +1 -0
- package/dist/modules/components/input/style.css +1 -0
- package/dist/modules/components/input/styles.css +7 -0
- package/dist/modules/components/mapView/index.js +31 -0
- package/dist/modules/components/mapView/index.js.map +1 -0
- package/dist/modules/components/mapView/mapView.client.js +58 -0
- package/dist/modules/components/mapView/mapView.client.js.map +1 -0
- package/dist/modules/components/mapView/mapbox.css +1 -0
- package/dist/modules/components/mapView/styles.css +1 -0
- package/dist/modules/components/maskedInput/index.js +104 -0
- package/dist/modules/components/maskedInput/index.js.map +1 -0
- package/dist/modules/components/maskedInput/style.css +1 -0
- package/dist/modules/components/maskedInput/styles.css +7 -0
- package/dist/modules/components/modal/modalContainer/index.js +38 -0
- package/dist/modules/components/modal/modalContainer/index.js.map +1 -0
- package/dist/modules/components/modal/modalContainer/styles.css +1 -0
- package/dist/modules/components/modal/modalContext.js +18 -0
- package/dist/modules/components/modal/modalContext.js.map +1 -0
- package/dist/modules/components/modal/modalFooter/index.js +14 -0
- package/dist/modules/components/modal/modalFooter/index.js.map +1 -0
- package/dist/modules/components/modal/modalFooter/styles.css +1 -0
- package/dist/modules/components/modal/modalHeader/index.js +23 -0
- package/dist/modules/components/modal/modalHeader/index.js.map +1 -0
- package/dist/modules/components/modal/modalHeader/styles.css +1 -0
- package/dist/modules/components/multiSelect/index.js +118 -0
- package/dist/modules/components/multiSelect/index.js.map +1 -0
- package/dist/modules/components/multiSelect/multiSelectChevron/index.js +21 -0
- package/dist/modules/components/multiSelect/multiSelectChevron/index.js.map +1 -0
- package/dist/modules/components/multiSelect/multiSelectChevron/styles.css +1 -0
- package/dist/modules/components/multiSelect/multiSelectContainer/index.js +16 -0
- package/dist/modules/components/multiSelect/multiSelectContainer/index.js.map +1 -0
- package/dist/modules/components/multiSelect/multiSelectContainer/styles.css +1 -0
- package/dist/modules/components/multiSelect/multiSelectContent/index.js +14 -0
- package/dist/modules/components/multiSelect/multiSelectContent/index.js.map +1 -0
- package/dist/modules/components/multiSelect/multiSelectContent/styles.css +1 -0
- package/dist/modules/components/multiSelect/multiSelectMark/index.js +22 -0
- package/dist/modules/components/multiSelect/multiSelectMark/index.js.map +1 -0
- package/dist/modules/components/multiSelect/multiSelectMark/styles.css +1 -0
- package/dist/modules/components/multiSelect/multiSelectOption/index.js +20 -0
- package/dist/modules/components/multiSelect/multiSelectOption/index.js.map +1 -0
- package/dist/modules/components/multiSelect/multiSelectOption/styles.css +1 -0
- package/dist/modules/components/multiSelect/multiSelectOptionsContainer/index.js +38 -0
- package/dist/modules/components/multiSelect/multiSelectOptionsContainer/index.js.map +1 -0
- package/dist/modules/components/multiSelect/multiSelectOptionsContainer/styles.css +1 -0
- package/dist/modules/components/multiSelect/multiSelectOverlay/index.js +14 -0
- package/dist/modules/components/multiSelect/multiSelectOverlay/index.js.map +1 -0
- package/dist/modules/components/multiSelect/multiSelectOverlay/styles.css +1 -0
- package/dist/modules/components/multiSelect/multiSelectSpinner/index.js +16 -0
- package/dist/modules/components/multiSelect/multiSelectSpinner/index.js.map +1 -0
- package/dist/modules/components/multiSelect/multiSelectSpinner/styles.css +1 -0
- package/dist/modules/components/multiSelect/styles.css +31 -0
- package/dist/modules/components/pagination/chevronButton/index.js +21 -0
- package/dist/modules/components/pagination/chevronButton/index.js.map +1 -0
- package/dist/modules/components/pagination/chevronButton/styles.css +1 -0
- package/dist/modules/components/pagination/currentButton/index.js +15 -0
- package/dist/modules/components/pagination/currentButton/index.js.map +1 -0
- package/dist/modules/components/pagination/currentButton/styles.css +1 -0
- package/dist/modules/components/pagination/index.js +54 -0
- package/dist/modules/components/pagination/index.js.map +1 -0
- package/dist/modules/components/pagination/pageButton/index.js +16 -0
- package/dist/modules/components/pagination/pageButton/index.js.map +1 -0
- package/dist/modules/components/pagination/pageButton/styles.css +1 -0
- package/dist/modules/components/pagination/paginationService.js +36 -0
- package/dist/modules/components/pagination/paginationService.js.map +1 -0
- package/dist/modules/components/pagination/spread/index.js +14 -0
- package/dist/modules/components/pagination/spread/index.js.map +1 -0
- package/dist/modules/components/pagination/spread/styles.css +1 -0
- package/dist/modules/components/pagination/styles.css +9 -0
- package/dist/modules/components/phoneInput/index.js +111 -0
- package/dist/modules/components/phoneInput/index.js.map +1 -0
- package/dist/modules/components/phoneInput/phoneInputContainer/index.js +15 -0
- package/dist/modules/components/phoneInput/phoneInputContainer/index.js.map +1 -0
- package/dist/modules/components/phoneInput/phoneInputContainer/styles.css +1 -0
- package/dist/modules/components/phoneInput/phoneInputCountriesOverlay/index.js +14 -0
- package/dist/modules/components/phoneInput/phoneInputCountriesOverlay/index.js.map +1 -0
- package/dist/modules/components/phoneInput/phoneInputCountriesOverlay/styles.css +1 -0
- package/dist/modules/components/phoneInput/phoneInputCountryOption/index.js +26 -0
- package/dist/modules/components/phoneInput/phoneInputCountryOption/index.js.map +1 -0
- package/dist/modules/components/phoneInput/phoneInputCountryOption/styles.css +1 -0
- package/dist/modules/components/phoneInput/phoneInputCountryOptionsContainer/index.js +36 -0
- package/dist/modules/components/phoneInput/phoneInputCountryOptionsContainer/index.js.map +1 -0
- package/dist/modules/components/phoneInput/phoneInputCountryOptionsContainer/styles.css +1 -0
- package/dist/modules/components/phoneInput/phoneInputCountrySelector/index.js +28 -0
- package/dist/modules/components/phoneInput/phoneInputCountrySelector/index.js.map +1 -0
- package/dist/modules/components/phoneInput/phoneInputCountrySelector/styles.css +1 -0
- package/dist/modules/components/phoneInput/phoneInputMask/index.js +55 -0
- package/dist/modules/components/phoneInput/phoneInputMask/index.js.map +1 -0
- package/dist/modules/components/phoneInput/phoneInputMask/style.css +1 -0
- package/dist/modules/components/phoneInput/styles.css +19 -0
- package/dist/modules/components/popover/index.js +32 -0
- package/dist/modules/components/popover/index.js.map +1 -0
- package/dist/modules/components/popover/styles.css +1 -0
- package/dist/modules/components/radio/radioBox/index.js +27 -0
- package/dist/modules/components/radio/radioBox/index.js.map +1 -0
- package/dist/modules/components/radio/radioBox/styles.css +1 -0
- package/dist/modules/components/radio/radioContext.js +24 -0
- package/dist/modules/components/radio/radioContext.js.map +1 -0
- package/dist/modules/components/radio/radioGroup/index.js +44 -0
- package/dist/modules/components/radio/radioGroup/index.js.map +1 -0
- package/dist/modules/components/radio/radioGroup/styles.css +7 -0
- package/dist/modules/components/richText/blockButton/index.js +23 -0
- package/dist/modules/components/richText/blockButton/index.js.map +1 -0
- package/dist/modules/components/richText/blockButton/styles.css +1 -0
- package/dist/modules/components/richText/element/index.js +75 -0
- package/dist/modules/components/richText/element/index.js.map +1 -0
- package/dist/modules/components/richText/element/styles.css +1 -0
- package/dist/modules/components/richText/index.js +144 -0
- package/dist/modules/components/richText/index.js.map +1 -0
- package/dist/modules/components/richText/insertImage/index.js +97 -0
- package/dist/modules/components/richText/insertImage/index.js.map +1 -0
- package/dist/modules/components/richText/insertImage/styles.css +1 -0
- package/dist/modules/components/richText/insertVideo/index.js +88 -0
- package/dist/modules/components/richText/insertVideo/index.js.map +1 -0
- package/dist/modules/components/richText/insertVideo/styles.css +1 -0
- package/dist/modules/components/richText/leaf/index.js +12 -0
- package/dist/modules/components/richText/leaf/index.js.map +1 -0
- package/dist/modules/components/richText/markButton/index.js +22 -0
- package/dist/modules/components/richText/markButton/index.js.map +1 -0
- package/dist/modules/components/richText/markButton/styles.css +1 -0
- package/dist/modules/components/richText/styles.css +67 -0
- package/dist/modules/components/richText/toolbar/index.js +13 -0
- package/dist/modules/components/richText/toolbar/index.js.map +1 -0
- package/dist/modules/components/richText/toolbar/styles.css +1 -0
- package/dist/modules/components/searchPlaces.js +60 -0
- package/dist/modules/components/searchPlaces.js.map +1 -0
- package/dist/modules/components/select/index.js +115 -0
- package/dist/modules/components/select/index.js.map +1 -0
- package/dist/modules/components/select/selectChevron/index.js +21 -0
- package/dist/modules/components/select/selectChevron/index.js.map +1 -0
- package/dist/modules/components/select/selectChevron/styles.css +1 -0
- package/dist/modules/components/select/selectContainer/index.js +16 -0
- package/dist/modules/components/select/selectContainer/index.js.map +1 -0
- package/dist/modules/components/select/selectContainer/styles.css +1 -0
- package/dist/modules/components/select/selectContent/index.js +14 -0
- package/dist/modules/components/select/selectContent/index.js.map +1 -0
- package/dist/modules/components/select/selectContent/styles.css +1 -0
- package/dist/modules/components/select/selectOption/index.js +21 -0
- package/dist/modules/components/select/selectOption/index.js.map +1 -0
- package/dist/modules/components/select/selectOption/styles.css +1 -0
- package/dist/modules/components/select/selectOptionsContainer/index.js +38 -0
- package/dist/modules/components/select/selectOptionsContainer/index.js.map +1 -0
- package/dist/modules/components/select/selectOptionsContainer/styles.css +1 -0
- package/dist/modules/components/select/selectOverlay/index.js +14 -0
- package/dist/modules/components/select/selectOverlay/index.js.map +1 -0
- package/dist/modules/components/select/selectOverlay/styles.css +1 -0
- package/dist/modules/components/select/selectSpinner/index.js +16 -0
- package/dist/modules/components/select/selectSpinner/index.js.map +1 -0
- package/dist/modules/components/select/selectSpinner/styles.css +1 -0
- package/dist/modules/components/select/styles.css +29 -0
- package/dist/modules/components/slider/index.js +46 -0
- package/dist/modules/components/slider/index.js.map +1 -0
- package/dist/modules/components/slider/styles.css +1 -0
- package/dist/modules/components/switch/index.js +38 -0
- package/dist/modules/components/switch/index.js.map +1 -0
- package/dist/modules/components/switch/styles.css +7 -0
- package/dist/modules/components/tab/tabButton/index.js +22 -0
- package/dist/modules/components/tab/tabButton/index.js.map +1 -0
- package/dist/modules/components/tab/tabButton/styles.css +1 -0
- package/dist/modules/components/tab/tabContainer/index.js +25 -0
- package/dist/modules/components/tab/tabContainer/index.js.map +1 -0
- package/dist/modules/components/tab/tabContainer/styles.css +1 -0
- package/dist/modules/components/tab/tabContext.js +26 -0
- package/dist/modules/components/tab/tabContext.js.map +1 -0
- package/dist/modules/components/table/tableBody/index.js +22 -0
- package/dist/modules/components/table/tableBody/index.js.map +1 -0
- package/dist/modules/components/table/tableBody/styles.css +1 -0
- package/dist/modules/components/table/tableCaption/index.js +18 -0
- package/dist/modules/components/table/tableCaption/index.js.map +1 -0
- package/dist/modules/components/table/tableCaption/styles.css +1 -0
- package/dist/modules/components/table/tableContainer/index.js +15 -0
- package/dist/modules/components/table/tableContainer/index.js.map +1 -0
- package/dist/modules/components/table/tableContainer/styles.css +1 -0
- package/dist/modules/components/table/tableFooter/index.js +21 -0
- package/dist/modules/components/table/tableFooter/index.js.map +1 -0
- package/dist/modules/components/table/tableFooter/styles.css +1 -0
- package/dist/modules/components/table/tableHeader/index.js +15 -0
- package/dist/modules/components/table/tableHeader/index.js.map +1 -0
- package/dist/modules/components/table/tableHeader/styles.css +1 -0
- package/dist/modules/components/textarea/index.js +54 -0
- package/dist/modules/components/textarea/index.js.map +1 -0
- package/dist/modules/components/textarea/styles.css +7 -0
- package/dist/modules/components/tooltip/index.js +37 -0
- package/dist/modules/components/tooltip/index.js.map +1 -0
- package/dist/modules/components/tooltip/styles.css +1 -0
- package/dist/modules/hooks/useAutomation.js +47 -0
- package/dist/modules/hooks/useAutomation.js.map +1 -0
- package/dist/modules/hooks/useDrawer.js +20 -0
- package/dist/modules/hooks/useDrawer.js.map +1 -0
- package/dist/modules/hooks/useForm.js +10 -0
- package/dist/modules/hooks/useForm.js.map +1 -0
- package/dist/modules/hooks/useHydrated.js +12 -0
- package/dist/modules/hooks/useHydrated.js.map +1 -0
- package/dist/modules/hooks/useModal.js +20 -0
- package/dist/modules/hooks/useModal.js.map +1 -0
- package/dist/modules/hooks/useScopedParams.js +20 -0
- package/dist/modules/hooks/useScopedParams.js.map +1 -0
- package/dist/modules/hooks/useScrollLock.js +23 -0
- package/dist/modules/hooks/useScrollLock.js.map +1 -0
- package/dist/modules/hooks/useSearchAutomation.js +36 -0
- package/dist/modules/hooks/useSearchAutomation.js.map +1 -0
- package/dist/modules/hooks/useSlider.js +16 -0
- package/dist/modules/hooks/useSlider.js.map +1 -0
- package/dist/modules/hooks/useToast.js +12 -0
- package/dist/modules/hooks/useToast.js.map +1 -0
- package/dist/modules/providers/drawerProvider.js +38 -0
- package/dist/modules/providers/drawerProvider.js.map +1 -0
- package/dist/modules/providers/formProvider.js +15 -0
- package/dist/modules/providers/formProvider.js.map +1 -0
- package/dist/modules/providers/modalProvider.js +36 -0
- package/dist/modules/providers/modalProvider.js.map +1 -0
- package/dist/modules/providers/placesProvider.js +20 -0
- package/dist/modules/providers/placesProvider.js.map +1 -0
- package/dist/modules/providers/toastProvider.js +49 -0
- package/dist/modules/providers/toastProvider.js.map +1 -0
- package/dist/modules/services/extractTextFromNode.js +9 -0
- package/dist/modules/services/extractTextFromNode.js.map +1 -0
- package/dist/modules/services/fieldTemplate.js +26 -0
- package/dist/modules/services/fieldTemplate.js.map +1 -0
- package/dist/modules/services/iconRenderer.js +17 -0
- package/dist/modules/services/iconRenderer.js.map +1 -0
- package/dist/modules/services/isBlockActive.js +15 -0
- package/dist/modules/services/isBlockActive.js.map +1 -0
- package/dist/modules/services/isMarkActive.js +10 -0
- package/dist/modules/services/isMarkActive.js.map +1 -0
- package/dist/modules/services/maskCurrencyValues.js +15 -0
- package/dist/modules/services/maskCurrencyValues.js.map +1 -0
- package/dist/modules/services/toHtml.js +9 -0
- package/dist/modules/services/toHtml.js.map +1 -0
- package/dist/modules/services/toRichTextValue.js +11 -0
- package/dist/modules/services/toRichTextValue.js.map +1 -0
- package/dist/modules/services/toggleBlock.js +23 -0
- package/dist/modules/services/toggleBlock.js.map +1 -0
- package/dist/modules/services/toggleMark.js +10 -0
- package/dist/modules/services/toggleMark.js.map +1 -0
- package/dist/modules/templates/badResponses.js +16 -0
- package/dist/modules/templates/badResponses.js.map +1 -0
- package/dist/modules/templates/richTextTemplates.js +19 -0
- package/dist/modules/templates/richTextTemplates.js.map +1 -0
- package/dist/modules/templates/successResponses.js +11 -0
- package/dist/modules/templates/successResponses.js.map +1 -0
- package/dist/modules/utils/phoneInputUtilities.js +24 -0
- package/dist/modules/utils/phoneInputUtilities.js.map +1 -0
- package/dist/modules/utils/richTextUtilities.js +92 -0
- package/dist/modules/utils/richTextUtilities.js.map +1 -0
- package/dist/providers/drawerProvider.d.ts +18 -84
- package/dist/providers/drawerProvider.d.ts.map +1 -1
- package/dist/providers/formProvider.d.ts +20 -56
- package/dist/providers/formProvider.d.ts.map +1 -1
- package/dist/providers/modalProvider.d.ts +19 -80
- package/dist/providers/modalProvider.d.ts.map +1 -1
- package/dist/providers/placesProvider.d.ts +18 -13
- package/dist/providers/placesProvider.d.ts.map +1 -1
- package/dist/providers/toastProvider.d.ts +13 -24
- package/dist/providers/toastProvider.d.ts.map +1 -1
- package/dist/services/extractTextFromNode.d.ts +1 -1
- package/dist/services/extractTextFromNode.d.ts.map +1 -1
- package/dist/services/fieldTemplate.d.ts +14 -0
- package/dist/services/fieldTemplate.d.ts.map +1 -0
- package/dist/services/iconRenderer.d.ts +2 -2
- package/dist/services/iconRenderer.d.ts.map +1 -1
- package/dist/services/isBlockActive.d.ts +1 -1
- package/dist/services/isBlockActive.d.ts.map +1 -1
- package/dist/services/isMarkActive.d.ts +1 -1
- package/dist/services/isMarkActive.d.ts.map +1 -1
- package/dist/services/maskCurrencyValues.d.ts.map +1 -1
- package/dist/services/toHtml.d.ts +12 -11
- package/dist/services/toHtml.d.ts.map +1 -1
- package/dist/services/toRichTextValue.d.ts +12 -18
- package/dist/services/toRichTextValue.d.ts.map +1 -1
- package/dist/services/toggleBlock.d.ts +1 -1
- package/dist/services/toggleBlock.d.ts.map +1 -1
- package/dist/services/toggleMark.d.ts +1 -1
- package/dist/services/toggleMark.d.ts.map +1 -1
- package/dist/style.css +1 -1
- package/dist/templates/richTextTemplates.d.ts +1 -1
- package/dist/templates/richTextTemplates.d.ts.map +1 -1
- package/dist/types/richTextTypes.d.ts +14 -3
- package/dist/types/richTextTypes.d.ts.map +1 -1
- package/dist/utils/phoneInputUtilities.d.ts +2 -1714
- package/dist/utils/phoneInputUtilities.d.ts.map +1 -1
- package/dist/utils/richTextUtilities.d.ts +1 -1
- package/dist/utils/richTextUtilities.d.ts.map +1 -1
- package/package.json +1100 -27
- package/styles.d.ts +3 -0
- package/dist/bundle.js +0 -18048
- package/dist/bundle.umd.cjs +0 -219
- package/dist/components/alert/alertContainer/index.js +0 -91
- package/dist/components/alert/alertContent/index.js +0 -46
- package/dist/components/alert/alertDescription/index.js +0 -48
- package/dist/components/alert/alertIcon/index.js +0 -61
- package/dist/components/alert/alertTitle/index.js +0 -42
- package/dist/components/audioPlayer/index.js +0 -115
- package/dist/components/audioUpload/hasFileContent/index.js +0 -26
- package/dist/components/audioUpload/index.js +0 -120
- package/dist/components/audioUpload/noFileContent/index.js +0 -29
- package/dist/components/badge/index.js +0 -49
- package/dist/components/button/index.js +0 -61
- package/dist/components/cardTab/cardTabButton/index.js +0 -80
- package/dist/components/cardTab/cardTabContainer/index.js +0 -88
- package/dist/components/cardTab/cardTabContext.js +0 -10
- package/dist/components/checkbox/index.js +0 -87
- package/dist/components/clientOnly.js +0 -86
- package/dist/components/currencyInput/index.js +0 -141
- package/dist/components/divider/index.js +0 -45
- package/dist/components/drawer/drawerContainer/index.js +0 -75
- package/dist/components/drawer/drawerContext.js +0 -10
- package/dist/components/drawer/drawerHeader/index.js +0 -58
- package/dist/components/fieldError/index.js +0 -33
- package/dist/components/fieldLabel/index.js +0 -39
- package/dist/components/fieldWrapper/index.js +0 -42
- package/dist/components/fileUpload/hasFileContent/index.js +0 -34
- package/dist/components/fileUpload/index.js +0 -127
- package/dist/components/fileUpload/noFileContent/index.js +0 -29
- package/dist/components/iconButton/index.js +0 -41
- package/dist/components/imageUpload/hasFileContent/index.js +0 -24
- package/dist/components/imageUpload/index.js +0 -149
- package/dist/components/imageUpload/noFileContent/index.js +0 -29
- package/dist/components/input/index.js +0 -114
- package/dist/components/mapView/index.js +0 -16
- package/dist/components/maskedInput/index.js +0 -131
- package/dist/components/modal/modalContainer/index.js +0 -82
- package/dist/components/modal/modalContext.js +0 -10
- package/dist/components/modal/modalFooter/index.js +0 -72
- package/dist/components/modal/modalHeader/index.js +0 -69
- package/dist/components/multiSelect/index.js +0 -169
- package/dist/components/multiSelect/multiSelectChevron/index.js +0 -18
- package/dist/components/multiSelect/multiSelectContainer/index.js +0 -11
- package/dist/components/multiSelect/multiSelectContent/index.js +0 -8
- package/dist/components/multiSelect/multiSelectMark/index.js +0 -11
- package/dist/components/multiSelect/multiSelectOption/index.js +0 -10
- package/dist/components/multiSelect/multiSelectOptionsContainer/index.js +0 -44
- package/dist/components/multiSelect/multiSelectOverlay/index.js +0 -9
- package/dist/components/multiSelect/multiSelectSpinner/index.js +0 -10
- package/dist/components/pagination/chevronButton/index.js +0 -9
- package/dist/components/pagination/currentButton/index.js +0 -6
- package/dist/components/pagination/index.js +0 -37
- package/dist/components/pagination/pageButton/index.js +0 -7
- package/dist/components/pagination/paginationService.js +0 -62
- package/dist/components/pagination/spread/index.js +0 -7
- package/dist/components/phoneInput/index.js +0 -205
- package/dist/components/phoneInput/phoneInputContainer/index.js +0 -11
- package/dist/components/phoneInput/phoneInputCountriesOverlay/index.js +0 -9
- package/dist/components/phoneInput/phoneInputCountryOption/index.js +0 -10
- package/dist/components/phoneInput/phoneInputCountryOptionsContainer/index.js +0 -40
- package/dist/components/phoneInput/phoneInputCountrySelector/index.js +0 -9
- package/dist/components/phoneInput/phoneInputMask/index.js +0 -34
- package/dist/components/popover/index.js +0 -151
- package/dist/components/radio/radioBox/index.js +0 -99
- package/dist/components/radio/radioContext.js +0 -11
- package/dist/components/radio/radioGroup/index.js +0 -100
- package/dist/components/richText/blockButton/index.js +0 -18
- package/dist/components/richText/element/index.js +0 -24
- package/dist/components/richText/index.js +0 -149
- package/dist/components/richText/insertImage/index.js +0 -33
- package/dist/components/richText/leaf/index.js +0 -13
- package/dist/components/richText/markButton/index.js +0 -16
- package/dist/components/richText/toolbar/index.js +0 -6
- package/dist/components/searchPlaces.js +0 -91
- package/dist/components/select/index.js +0 -168
- package/dist/components/select/selectChevron/index.js +0 -18
- package/dist/components/select/selectContainer/index.js +0 -11
- package/dist/components/select/selectContent/index.js +0 -8
- package/dist/components/select/selectOption/index.js +0 -10
- package/dist/components/select/selectOptionsContainer/index.js +0 -44
- package/dist/components/select/selectOverlay/index.js +0 -9
- package/dist/components/select/selectSpinner/index.js +0 -10
- package/dist/components/slider/index.js +0 -97
- package/dist/components/switch/index.js +0 -100
- package/dist/components/tab/tabButton/index.js +0 -80
- package/dist/components/tab/tabContainer/index.js +0 -88
- package/dist/components/tab/tabContext.js +0 -10
- package/dist/components/table/tableBody/index.js +0 -69
- package/dist/components/table/tableCaption/index.js +0 -64
- package/dist/components/table/tableContainer/index.js +0 -66
- package/dist/components/table/tableFooter/index.js +0 -47
- package/dist/components/table/tableHeader/index.js +0 -46
- package/dist/components/textarea/index.js +0 -128
- package/dist/components/tooltip/index.js +0 -135
- package/dist/hooks/useAutomation.js +0 -67
- package/dist/hooks/useDrawer.js +0 -20
- package/dist/hooks/useForm.js +0 -52
- package/dist/hooks/useHydrated.js +0 -81
- package/dist/hooks/useModal.js +0 -20
- package/dist/hooks/useScopedParams.js +0 -107
- package/dist/hooks/useScrollLock.js +0 -68
- package/dist/hooks/useSlider.js +0 -49
- package/dist/hooks/useToast.js +0 -72
- package/dist/providers/drawerProvider.js +0 -120
- package/dist/providers/formProvider.js +0 -69
- package/dist/providers/modalProvider.js +0 -119
- package/dist/providers/placesProvider.js +0 -35
- package/dist/providers/toastProvider.js +0 -73
- package/dist/services/extractTextFromNode.js +0 -5
- package/dist/services/iconRenderer.js +0 -13
- package/dist/services/isBlockActive.js +0 -14
- package/dist/services/isMarkActive.js +0 -6
- package/dist/services/maskCurrencyValues.js +0 -23
- package/dist/services/toHtml.js +0 -21
- package/dist/services/toRichTextValue.js +0 -40
- package/dist/services/toggleBlock.js +0 -32
- package/dist/services/toggleMark.js +0 -10
- package/dist/templates/badResponses.js +0 -12
- package/dist/templates/richTextTemplates.js +0 -12
- package/dist/templates/successResponses.js +0 -2
- package/dist/types/richTextTypes.js +0 -1
- package/dist/utils/phoneInputUtilities.js +0 -99
- package/dist/utils/richTextUtilities.js +0 -87
package/dist/index.js
CHANGED
|
@@ -1,69 +1,4644 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
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
|
-
|
|
1
|
+
import { Children as e, cloneElement as t, createContext as n, forwardRef as r, useCallback as i, useContext as a, useEffect as o, useId as s, useMemo as c, useRef as l, useState as u, useSyncExternalStore as d } from "react";
|
|
2
|
+
import { Fragment as f, jsx as p, jsxs as m } from "react/jsx-runtime";
|
|
3
|
+
import { AlertTriangle as h, AlignCenter as g, AlignJustify as _, AlignLeft as v, AlignRight as y, Bold as b, Check as x, CheckCircle2 as S, ChevronDown as C, ChevronLeft as w, ChevronRight as T, Code as E, Ellipsis as D, File as O, FileArchive as k, FileAudio as A, FileImage as j, Heading1 as M, Heading2 as N, Image as P, Info as F, Italic as I, Loader2 as L, MapPinned as R, Pause as z, Play as B, Quote as V, RefreshCw as H, Search as U, Underline as W, Video as G, X as K, XCircle as q } from "lucide-react";
|
|
4
|
+
import { findCountryMask as ee, formatToCapitalizeFirstWordLetter as J, formatToCurrency as te, formatToPhone as ne, removeNonNumeric as re } from "@arkyn/shared";
|
|
5
|
+
import ie from "mapbox-gl";
|
|
6
|
+
import { createRoot as ae } from "react-dom/client";
|
|
7
|
+
import { InputMask as Y } from "@react-input/mask";
|
|
8
|
+
import { countries as oe } from "@arkyn/templates";
|
|
9
|
+
import se from "is-hotkey";
|
|
10
|
+
import { Editor as ce, Element as le, Node as ue, Text as de, Transforms as fe, createEditor as pe } from "slate";
|
|
11
|
+
import { withHistory as me } from "slate-history";
|
|
12
|
+
import { Editable as he, Slate as ge, useSlate as _e, withReact as ve } from "slate-react";
|
|
13
|
+
import { StandaloneSearchBox as ye, useLoadScript as be } from "@react-google-maps/api";
|
|
14
|
+
import { scroller as xe } from "react-scroll";
|
|
15
|
+
import Se, { Toaster as Ce } from "react-hot-toast";
|
|
16
|
+
import we from "html-react-parser";
|
|
17
|
+
//#region src/components/alert/alertTitle/index.tsx
|
|
18
|
+
function Te(e) {
|
|
19
|
+
let { className: t, ...n } = e;
|
|
20
|
+
return /* @__PURE__ */ p("div", {
|
|
21
|
+
className: `arkynAlertTitle ${t}`.trim(),
|
|
22
|
+
...n
|
|
23
|
+
});
|
|
24
|
+
}
|
|
25
|
+
//#endregion
|
|
26
|
+
//#region src/components/alert/alertContainer/index.tsx
|
|
27
|
+
var Ee = n({});
|
|
28
|
+
function De() {
|
|
29
|
+
return a(Ee);
|
|
30
|
+
}
|
|
31
|
+
function Oe(e) {
|
|
32
|
+
let { scheme: t, children: n, className: r, ...i } = e, a = `arkynAlertContainer ${t} ${((e) => {
|
|
33
|
+
let t = !1, n = (e) => {
|
|
34
|
+
Array.isArray(e) ? e.forEach(n) : e && typeof e == "object" && "type" in e && (e.type === Te ? t = !0 : e.props && typeof e.props == "object" && e.props !== null && "children" in e.props && n(e.props.children));
|
|
35
|
+
};
|
|
36
|
+
return n(e), t;
|
|
37
|
+
})(n) ? "existsAlertTitle" : "nonExistsAlertTitle"} ${r}`, o = c(() => ({ scheme: t }), [t]);
|
|
38
|
+
return /* @__PURE__ */ p(Ee.Provider, {
|
|
39
|
+
value: o,
|
|
40
|
+
children: /* @__PURE__ */ p("div", {
|
|
41
|
+
className: a.trim(),
|
|
42
|
+
...i,
|
|
43
|
+
children: n
|
|
44
|
+
})
|
|
45
|
+
});
|
|
46
|
+
}
|
|
47
|
+
//#endregion
|
|
48
|
+
//#region src/components/alert/alertContent/index.tsx
|
|
49
|
+
function ke(e) {
|
|
50
|
+
let { className: t, ...n } = e;
|
|
51
|
+
return /* @__PURE__ */ p("div", {
|
|
52
|
+
className: `arkynAlertContent ${t}`.trim(),
|
|
53
|
+
...n
|
|
54
|
+
});
|
|
55
|
+
}
|
|
56
|
+
//#endregion
|
|
57
|
+
//#region src/components/alert/alertDescription/index.tsx
|
|
58
|
+
function Ae(e) {
|
|
59
|
+
let { className: t, ...n } = e;
|
|
60
|
+
return /* @__PURE__ */ p("div", {
|
|
61
|
+
className: `arkynAlertDescription ${t}`.trim(),
|
|
62
|
+
...n
|
|
63
|
+
});
|
|
64
|
+
}
|
|
65
|
+
//#endregion
|
|
66
|
+
//#region src/components/alert/alertIcon/index.tsx
|
|
67
|
+
function je(e) {
|
|
68
|
+
let { className: t, ...n } = e, { scheme: r } = De(), i = `arkynAlertIcon ${r} ${t}`;
|
|
69
|
+
switch (r) {
|
|
70
|
+
case "success": return /* @__PURE__ */ p(S, {
|
|
71
|
+
className: i,
|
|
72
|
+
...n
|
|
73
|
+
});
|
|
74
|
+
case "danger": return /* @__PURE__ */ p(q, {
|
|
75
|
+
className: i,
|
|
76
|
+
...n
|
|
77
|
+
});
|
|
78
|
+
case "warning": return /* @__PURE__ */ p(h, {
|
|
79
|
+
className: i,
|
|
80
|
+
...n
|
|
81
|
+
});
|
|
82
|
+
case "info": return /* @__PURE__ */ p(F, {
|
|
83
|
+
className: i,
|
|
84
|
+
...n
|
|
85
|
+
});
|
|
86
|
+
}
|
|
87
|
+
}
|
|
88
|
+
//#endregion
|
|
89
|
+
//#region src/hooks/useSlider.ts
|
|
90
|
+
function Me(e) {
|
|
91
|
+
function t() {
|
|
92
|
+
return !e || e <= 0 ? 0 : e >= 100 ? 100 : e;
|
|
93
|
+
}
|
|
94
|
+
let [n, r] = u(t());
|
|
95
|
+
function i(e) {
|
|
96
|
+
return r(e <= 0 ? 0 : e >= 100 ? 100 : e);
|
|
97
|
+
}
|
|
98
|
+
return [n, i];
|
|
99
|
+
}
|
|
100
|
+
//#endregion
|
|
101
|
+
//#region src/components/slider/index.tsx
|
|
102
|
+
function Ne(e) {
|
|
103
|
+
let { onChange: t, value: n, disabled: r = !1, onDragging: a, className: s = "", ...c } = e, [d, f] = u(!1), h = l(null), g = () => f(!0), _ = i(() => f(!1), []), v = i((e) => {
|
|
104
|
+
if (r || !d || !h.current) return;
|
|
105
|
+
let n = h.current.getBoundingClientRect(), i = e.clientX - n.left;
|
|
106
|
+
t(Math.min(Math.max(i / n.width * 100, 0), 100));
|
|
107
|
+
}, [
|
|
108
|
+
r,
|
|
109
|
+
d,
|
|
110
|
+
t
|
|
111
|
+
]), y = (e) => {
|
|
112
|
+
if (r || !h.current) return;
|
|
113
|
+
let n = h.current.getBoundingClientRect(), i = e.clientX - n.left;
|
|
114
|
+
t(Math.min(Math.max(i / n.width * 100, 0), 100));
|
|
115
|
+
};
|
|
116
|
+
o(() => (d ? (a?.(!0), document.addEventListener("mousemove", v), document.addEventListener("mouseup", _)) : (a?.(!1), document.removeEventListener("mousemove", v), document.removeEventListener("mouseup", _)), () => {
|
|
117
|
+
document.removeEventListener("mousemove", v), document.removeEventListener("mouseup", _);
|
|
118
|
+
}), [
|
|
119
|
+
d,
|
|
120
|
+
a,
|
|
121
|
+
_,
|
|
122
|
+
v
|
|
123
|
+
]);
|
|
124
|
+
let b = `arkynSliderTrack ${d ? "isDragging" : "isNotDragging"} ${r ? "isDisabled" : "isEnabled"} ${s}`;
|
|
125
|
+
return /* @__PURE__ */ m("div", {
|
|
126
|
+
...c,
|
|
127
|
+
className: b,
|
|
128
|
+
onMouseDown: g,
|
|
129
|
+
onClick: y,
|
|
130
|
+
ref: h,
|
|
131
|
+
children: [/* @__PURE__ */ p("div", {
|
|
132
|
+
className: "arkynSliderFill",
|
|
133
|
+
style: { width: `${n}%` }
|
|
134
|
+
}), /* @__PURE__ */ p("div", {
|
|
135
|
+
className: "arkynSliderThumb",
|
|
136
|
+
style: { left: `${n}%` }
|
|
137
|
+
})]
|
|
138
|
+
});
|
|
139
|
+
}
|
|
140
|
+
//#endregion
|
|
141
|
+
//#region src/components/audioPlayer/index.tsx
|
|
142
|
+
function Pe(e) {
|
|
143
|
+
let { onPlayAudio: t, onPauseAudio: n, disabled: r, style: i, ...a } = e, [s, c] = Me(0), [d, f] = u(!1), [h, g] = u(!1), _ = l(null), v = _.current?.currentTime || 0, y = _.current?.duration || 0, b = C(v), x = C(y), S = {
|
|
144
|
+
totalTime: y,
|
|
145
|
+
currentTime: v,
|
|
146
|
+
formattedCurrentTime: b,
|
|
147
|
+
formattedTotalTime: x
|
|
148
|
+
};
|
|
149
|
+
function C(e) {
|
|
150
|
+
if (!e) return "00:00";
|
|
151
|
+
let t = Math.floor(e / 60), n = Math.floor(e % 60);
|
|
152
|
+
return `${String(t).padStart(2, "0")}:${String(n).padStart(2, "0")}`;
|
|
153
|
+
}
|
|
154
|
+
function w() {
|
|
155
|
+
let t = _.current;
|
|
156
|
+
t && (e.onPlayAudio && e.onPlayAudio(S), t.play(), f(!0));
|
|
157
|
+
}
|
|
158
|
+
function T() {
|
|
159
|
+
let t = _.current;
|
|
160
|
+
t && (e.onPauseAudio && e.onPauseAudio(S), t.pause(), f(!1));
|
|
161
|
+
}
|
|
162
|
+
function E() {
|
|
163
|
+
d ? T() : w();
|
|
164
|
+
}
|
|
165
|
+
function D(e) {
|
|
166
|
+
let t = _.current;
|
|
167
|
+
if (!t) return;
|
|
168
|
+
let n = t.duration;
|
|
169
|
+
t.currentTime = e / 100 * n;
|
|
170
|
+
}
|
|
171
|
+
return h || !d ? _.current?.pause() : d && _.current?.play(), o(() => {
|
|
172
|
+
let e = _.current;
|
|
173
|
+
if (!e) return;
|
|
174
|
+
let t = () => {
|
|
175
|
+
let t = e.duration;
|
|
176
|
+
c(e.currentTime / t * 100);
|
|
177
|
+
};
|
|
178
|
+
return e.addEventListener("timeupdate", t), () => {
|
|
179
|
+
e.removeEventListener("timeupdate", t);
|
|
180
|
+
};
|
|
181
|
+
}, [c]), /* @__PURE__ */ m("div", {
|
|
182
|
+
className: "arkynAudioPlayer",
|
|
183
|
+
style: i,
|
|
184
|
+
children: [
|
|
185
|
+
/* @__PURE__ */ p("audio", {
|
|
186
|
+
...a,
|
|
187
|
+
ref: _,
|
|
188
|
+
src: e.src || void 0,
|
|
189
|
+
onEnded: T
|
|
190
|
+
}),
|
|
191
|
+
/* @__PURE__ */ m("button", {
|
|
192
|
+
type: "button",
|
|
193
|
+
disabled: r,
|
|
194
|
+
onClick: E,
|
|
195
|
+
children: [d && /* @__PURE__ */ p(z, {}), !d && /* @__PURE__ */ p(B, {})]
|
|
196
|
+
}),
|
|
197
|
+
/* @__PURE__ */ p("p", { children: b }),
|
|
198
|
+
/* @__PURE__ */ p(Ne, {
|
|
199
|
+
value: s,
|
|
200
|
+
onChange: D,
|
|
201
|
+
onDragging: g,
|
|
202
|
+
disabled: r
|
|
203
|
+
}),
|
|
204
|
+
/* @__PURE__ */ p("p", { children: x })
|
|
205
|
+
]
|
|
206
|
+
});
|
|
207
|
+
}
|
|
208
|
+
//#endregion
|
|
209
|
+
//#region src/providers/formProvider.tsx
|
|
210
|
+
var Fe = n({});
|
|
211
|
+
function Ie(e) {
|
|
212
|
+
let { children: n, fieldErrors: r, form: i } = e, a = c(() => ({ fieldErrors: r }), [r]);
|
|
213
|
+
return /* @__PURE__ */ m(Fe.Provider, {
|
|
214
|
+
value: a,
|
|
215
|
+
children: [!i && n, i && t(i, i.props, n)]
|
|
216
|
+
});
|
|
217
|
+
}
|
|
218
|
+
//#endregion
|
|
219
|
+
//#region src/hooks/useForm.ts
|
|
220
|
+
function X() {
|
|
221
|
+
return a(Fe);
|
|
222
|
+
}
|
|
223
|
+
//#endregion
|
|
224
|
+
//#region src/components/fieldError/index.tsx
|
|
225
|
+
function Le(e) {
|
|
226
|
+
let { children: t, className: n, ...r } = e, i = `arkynFieldError ${n}`;
|
|
227
|
+
return t ? /* @__PURE__ */ p("strong", {
|
|
228
|
+
className: i.trim(),
|
|
229
|
+
...r,
|
|
230
|
+
children: t
|
|
231
|
+
}) : null;
|
|
232
|
+
}
|
|
233
|
+
//#endregion
|
|
234
|
+
//#region src/components/fieldLabel/index.tsx
|
|
235
|
+
function Re(e) {
|
|
236
|
+
let { showAsterisk: t = !1, className: n = "", ...r } = e;
|
|
237
|
+
return /* @__PURE__ */ p("label", {
|
|
238
|
+
className: `arkynFieldLabel ${t ? "asteriskTrue" : "asteriskFalse"} ${n}`.trim(),
|
|
239
|
+
...r
|
|
240
|
+
});
|
|
241
|
+
}
|
|
242
|
+
//#endregion
|
|
243
|
+
//#region src/components/fieldWrapper/index.tsx
|
|
244
|
+
function ze(e) {
|
|
245
|
+
let { children: t, className: n, orientation: r = "vertical", ...i } = e;
|
|
246
|
+
return /* @__PURE__ */ p("section", {
|
|
247
|
+
className: `arkynFieldWrapper ${n} ${r}`.trim(),
|
|
248
|
+
...i,
|
|
249
|
+
children: t
|
|
250
|
+
});
|
|
251
|
+
}
|
|
252
|
+
//#endregion
|
|
253
|
+
//#region src/services/iconRenderer.tsx
|
|
254
|
+
function Z(e) {
|
|
255
|
+
let { iconSize: t, icon: n, className: r, show: i = !0 } = e;
|
|
256
|
+
return !i || !n ? null : typeof n == "string" ? /* @__PURE__ */ p("p", {
|
|
257
|
+
className: r,
|
|
258
|
+
children: n
|
|
259
|
+
}) : /* @__PURE__ */ p(n, {
|
|
260
|
+
size: t,
|
|
261
|
+
strokeWidth: 2.5,
|
|
262
|
+
className: r
|
|
263
|
+
});
|
|
264
|
+
}
|
|
265
|
+
//#endregion
|
|
266
|
+
//#region src/components/button/index.tsx
|
|
267
|
+
function Be(e) {
|
|
268
|
+
let { isLoading: t = !1, scheme: n = "primary", variant: r = "solid", loadingText: i, size: a = "md", leftIcon: o, rightIcon: s, disabled: c, className: l = "", children: u, ...d } = e, f = {
|
|
269
|
+
xs: 12,
|
|
270
|
+
sm: 16,
|
|
271
|
+
md: 20,
|
|
272
|
+
lg: 24
|
|
273
|
+
}[a];
|
|
274
|
+
return /* @__PURE__ */ m("button", {
|
|
275
|
+
className: `arkynButton ${t ? "loadingTrue" : "loadingFalse"} ${r} ${n} ${a} ${i ? "loadingTextTrue" : "loadingTextFalse"} ${l}`,
|
|
276
|
+
disabled: c || t,
|
|
277
|
+
...d,
|
|
278
|
+
children: [/* @__PURE__ */ m("div", {
|
|
279
|
+
className: "arkynButtonSpinner",
|
|
280
|
+
children: [/* @__PURE__ */ p(L, {
|
|
281
|
+
size: f,
|
|
282
|
+
strokeWidth: 2.5
|
|
283
|
+
}), i && i]
|
|
284
|
+
}), /* @__PURE__ */ m("div", {
|
|
285
|
+
className: "arkynButtonContent",
|
|
286
|
+
children: [
|
|
287
|
+
/* @__PURE__ */ p(Z, {
|
|
288
|
+
iconSize: f,
|
|
289
|
+
icon: o
|
|
290
|
+
}),
|
|
291
|
+
u,
|
|
292
|
+
/* @__PURE__ */ p(Z, {
|
|
293
|
+
iconSize: f,
|
|
294
|
+
icon: s
|
|
295
|
+
})
|
|
296
|
+
]
|
|
297
|
+
})]
|
|
298
|
+
});
|
|
299
|
+
}
|
|
300
|
+
//#endregion
|
|
301
|
+
//#region src/components/divider/index.tsx
|
|
302
|
+
function Ve(e) {
|
|
303
|
+
let { className: t, orientation: n = "horizontal", ...r } = e;
|
|
304
|
+
return /* @__PURE__ */ p("div", {
|
|
305
|
+
className: `arkynDivider ${n} ${t}`.trim(),
|
|
306
|
+
...r
|
|
307
|
+
});
|
|
308
|
+
}
|
|
309
|
+
//#endregion
|
|
310
|
+
//#region src/components/iconButton/index.tsx
|
|
311
|
+
function He(e) {
|
|
312
|
+
let { isLoading: t = !1, scheme: n = "primary", variant: r = "solid", size: i = "md", icon: a, disabled: o, className: s = "", ...c } = e, l = {
|
|
313
|
+
xs: 12,
|
|
314
|
+
sm: 16,
|
|
315
|
+
md: 20,
|
|
316
|
+
lg: 24
|
|
317
|
+
}, u = `arkynIconButton ${r} ${n} ${i} ${t ? "loadingTrue" : "loadingFalse"} ${s}`;
|
|
318
|
+
return /* @__PURE__ */ m("button", {
|
|
319
|
+
disabled: o || t,
|
|
320
|
+
className: u.trim(),
|
|
321
|
+
...c,
|
|
322
|
+
children: [/* @__PURE__ */ p("div", {
|
|
323
|
+
className: "arkynIconButtonSpinner",
|
|
324
|
+
children: /* @__PURE__ */ p(L, {
|
|
325
|
+
size: l[i],
|
|
326
|
+
strokeWidth: 2.5
|
|
327
|
+
})
|
|
328
|
+
}), /* @__PURE__ */ p("div", {
|
|
329
|
+
className: "arkynIconButtonContent",
|
|
330
|
+
children: /* @__PURE__ */ p(a, {
|
|
331
|
+
size: l[i],
|
|
332
|
+
strokeWidth: 2.5
|
|
333
|
+
})
|
|
334
|
+
})]
|
|
335
|
+
});
|
|
336
|
+
}
|
|
337
|
+
//#endregion
|
|
338
|
+
//#region src/components/tooltip/index.tsx
|
|
339
|
+
function Ue(e) {
|
|
340
|
+
let { text: t, size: n = "lg", children: r, orientation: i = "top", className: a = "", ...c } = e, d = s(), f = l(null), [h, g] = u(i);
|
|
341
|
+
return o(() => {
|
|
342
|
+
let e = () => {
|
|
343
|
+
if (!f.current) return;
|
|
344
|
+
let e = document.getElementById(d);
|
|
345
|
+
e && (g(i), requestAnimationFrame(() => {
|
|
346
|
+
let t = e.getBoundingClientRect(), n = window.innerWidth, r = window.innerHeight, a = i;
|
|
347
|
+
i === "left" && t.left < 0 ? a = "right" : i === "right" && t.right > n ? a = "left" : i === "top" && t.top < 0 ? a = "bottom" : i === "bottom" && t.bottom > r && (a = "top"), a === "right" && t.right > n ? a = "left" : a === "left" && t.left < 0 ? a = "right" : a === "bottom" && t.bottom > r ? a = "top" : a === "top" && t.top < 0 && (a = "bottom"), g(a);
|
|
348
|
+
}));
|
|
349
|
+
}, t = f.current;
|
|
350
|
+
if (!t) return;
|
|
351
|
+
let n = () => {
|
|
352
|
+
setTimeout(e, 1);
|
|
353
|
+
};
|
|
354
|
+
return t.addEventListener("mouseenter", n), window.addEventListener("resize", e), () => {
|
|
355
|
+
t.removeEventListener("mouseenter", n), window.removeEventListener("resize", e);
|
|
356
|
+
};
|
|
357
|
+
}, [i, d]), /* @__PURE__ */ m("div", {
|
|
358
|
+
className: `arkynTooltip ${n} ${h} ${a}`.trim(),
|
|
359
|
+
...c,
|
|
360
|
+
ref: f,
|
|
361
|
+
children: [r, /* @__PURE__ */ p("div", {
|
|
362
|
+
className: "arkynTooltipText",
|
|
363
|
+
id: d,
|
|
364
|
+
dangerouslySetInnerHTML: { __html: t }
|
|
365
|
+
})]
|
|
366
|
+
});
|
|
367
|
+
}
|
|
368
|
+
//#endregion
|
|
369
|
+
//#region src/components/audioUpload/hasFileContent/index.tsx
|
|
370
|
+
function We(e) {
|
|
371
|
+
let { filePath: t, disabled: n, acceptAudio: r, handleSelectFile: i, isLoading: a, reSendAudio: o, changeAudioButtonText: s } = e;
|
|
372
|
+
function c() {
|
|
373
|
+
if (n) return;
|
|
374
|
+
let e = document.createElement("input");
|
|
375
|
+
e.type = "file", e.accept = r, e.onchange = (e) => {
|
|
376
|
+
let t = e.target.files?.[0];
|
|
377
|
+
t && i(t);
|
|
378
|
+
}, e.click();
|
|
379
|
+
}
|
|
380
|
+
return /* @__PURE__ */ m("div", {
|
|
381
|
+
className: "arkynAudioUploadHasFileContentContainer",
|
|
382
|
+
children: [
|
|
383
|
+
/* @__PURE__ */ p(Pe, { src: t }),
|
|
384
|
+
/* @__PURE__ */ p(Ve, {}),
|
|
385
|
+
/* @__PURE__ */ m("div", {
|
|
386
|
+
className: "arkynAudioUploadButtonsContainer",
|
|
387
|
+
children: [!!o && /* @__PURE__ */ p(Ue, {
|
|
388
|
+
orientation: "bottom",
|
|
389
|
+
text: "Reenviar áudio",
|
|
390
|
+
children: /* @__PURE__ */ p(He, {
|
|
391
|
+
type: "button",
|
|
392
|
+
"aria-label": "resend image",
|
|
393
|
+
variant: "outline",
|
|
394
|
+
scheme: "danger",
|
|
395
|
+
size: "sm",
|
|
396
|
+
isLoading: a,
|
|
397
|
+
onClick: o,
|
|
398
|
+
icon: H,
|
|
399
|
+
disabled: n
|
|
400
|
+
})
|
|
401
|
+
}), /* @__PURE__ */ p(Be, {
|
|
402
|
+
isLoading: a,
|
|
403
|
+
onClick: c,
|
|
404
|
+
variant: "outline",
|
|
405
|
+
size: "sm",
|
|
406
|
+
type: "button",
|
|
407
|
+
disabled: n,
|
|
408
|
+
children: s
|
|
409
|
+
})]
|
|
410
|
+
})
|
|
411
|
+
]
|
|
412
|
+
});
|
|
413
|
+
}
|
|
414
|
+
//#endregion
|
|
415
|
+
//#region src/components/audioUpload/noFileContent/index.tsx
|
|
416
|
+
function Ge(e) {
|
|
417
|
+
let { dropAudioText: t, isLoading: n, acceptAudio: r, handleSelectFile: i, selectAudioButtonText: a, disabled: o } = e;
|
|
418
|
+
function s(e) {
|
|
419
|
+
if (o) return;
|
|
420
|
+
e.preventDefault();
|
|
421
|
+
let t = e.dataTransfer.files[0];
|
|
422
|
+
t && i(t);
|
|
423
|
+
}
|
|
424
|
+
function c() {
|
|
425
|
+
if (o) return;
|
|
426
|
+
let e = document.createElement("input");
|
|
427
|
+
e.type = "file", e.accept = r, e.onchange = (e) => {
|
|
428
|
+
let t = e.target.files?.[0];
|
|
429
|
+
t && i(t);
|
|
430
|
+
}, e.click();
|
|
431
|
+
}
|
|
432
|
+
return /* @__PURE__ */ m("div", {
|
|
433
|
+
onDrop: s,
|
|
434
|
+
className: "arkynAudioUploadNoFileContent",
|
|
435
|
+
children: [/* @__PURE__ */ p(Be, {
|
|
436
|
+
isLoading: n,
|
|
437
|
+
onClick: c,
|
|
438
|
+
variant: "ghost",
|
|
439
|
+
size: "sm",
|
|
440
|
+
type: "button",
|
|
441
|
+
disabled: o,
|
|
442
|
+
children: a
|
|
443
|
+
}), /* @__PURE__ */ p("p", { children: t })]
|
|
444
|
+
});
|
|
445
|
+
}
|
|
446
|
+
//#endregion
|
|
447
|
+
//#region src/components/audioUpload/index.tsx
|
|
448
|
+
function Ke(e) {
|
|
449
|
+
let { name: t, label: n, fileName: r = "file", method: i = "POST", onChange: a, fileResponseName: o = "url", selectAudioButtonText: s = "Selecionar arquivo de áudio", dropAudioText: c = "Ou arraste e solte um arquivo de áudio aqui", changeAudioButtonText: l = "Trocar arquivo de áudio", acceptAudio: d = "audio/*", action: f, defaultValue: h = "", showAsterisk: g = !1, disabled: _ = !1 } = e, { fieldErrors: v } = X(), y = v?.[t], [b, x] = u(h), [S, C] = u(""), [w, T] = u(null), [E, D] = u(h), [O, k] = u(!1);
|
|
450
|
+
async function A(e) {
|
|
451
|
+
if (_) return;
|
|
452
|
+
k(!0), T(e), C("");
|
|
453
|
+
let t = new FormData();
|
|
454
|
+
t.append(r, e), await fetch(f, {
|
|
455
|
+
method: i,
|
|
456
|
+
body: t
|
|
457
|
+
}).then(async (e) => await e.json()).then((e) => {
|
|
458
|
+
e?.error ? C(e.error) : x(e?.[o]), a?.(e?.[o]);
|
|
459
|
+
}).catch((e) => {
|
|
460
|
+
console.error(e), C("Erro ao enviar audio");
|
|
461
|
+
}).finally(() => k(!1));
|
|
462
|
+
}
|
|
463
|
+
function j(e) {
|
|
464
|
+
if (!_) {
|
|
465
|
+
if (e.type.indexOf("audio") === -1) {
|
|
466
|
+
C("O arquivo selecionado não é um arquivo de áudio");
|
|
467
|
+
return;
|
|
468
|
+
}
|
|
469
|
+
D(URL.createObjectURL(e)), A(e);
|
|
470
|
+
}
|
|
471
|
+
}
|
|
472
|
+
let M = y || S;
|
|
473
|
+
return /* @__PURE__ */ m(ze, { children: [
|
|
474
|
+
n && /* @__PURE__ */ p(Re, {
|
|
475
|
+
showAsterisk: g,
|
|
476
|
+
children: n
|
|
477
|
+
}),
|
|
478
|
+
/* @__PURE__ */ m("div", {
|
|
479
|
+
className: `arkynAudioUpload ${M ? "hasError" : "noHasError"} ${E ? "hasAudio" : "noHasAudio"}`,
|
|
480
|
+
children: [
|
|
481
|
+
/* @__PURE__ */ p("input", {
|
|
482
|
+
type: "hidden",
|
|
483
|
+
name: t,
|
|
484
|
+
value: b || ""
|
|
485
|
+
}),
|
|
486
|
+
!E && /* @__PURE__ */ p(Ge, {
|
|
487
|
+
disabled: _,
|
|
488
|
+
isLoading: O,
|
|
489
|
+
acceptAudio: d,
|
|
490
|
+
dropAudioText: c,
|
|
491
|
+
handleSelectFile: j,
|
|
492
|
+
selectAudioButtonText: s
|
|
493
|
+
}),
|
|
494
|
+
E && /* @__PURE__ */ p(We, {
|
|
495
|
+
filePath: E,
|
|
496
|
+
acceptAudio: d,
|
|
497
|
+
changeAudioButtonText: l,
|
|
498
|
+
disabled: _,
|
|
499
|
+
handleSelectFile: j,
|
|
500
|
+
isLoading: O,
|
|
501
|
+
reSendAudio: M && w ? () => A(w) : void 0
|
|
502
|
+
})
|
|
503
|
+
]
|
|
504
|
+
}),
|
|
505
|
+
M && /* @__PURE__ */ p(Le, { children: M })
|
|
506
|
+
] });
|
|
507
|
+
}
|
|
508
|
+
//#endregion
|
|
509
|
+
//#region src/components/badge/index.tsx
|
|
510
|
+
function qe(e) {
|
|
511
|
+
let { variant: t = "ghost", scheme: n = "primary", size: r = "lg", leftIcon: i, rightIcon: a, className: o = "", children: s, ...c } = e, l = {
|
|
512
|
+
md: 12,
|
|
513
|
+
lg: 14
|
|
514
|
+
}[r];
|
|
515
|
+
return /* @__PURE__ */ m("div", {
|
|
516
|
+
className: `arkynBadge ${t} ${n} ${r} ${o}`.trim(),
|
|
517
|
+
...c,
|
|
518
|
+
children: [
|
|
519
|
+
/* @__PURE__ */ p(Z, {
|
|
520
|
+
iconSize: l,
|
|
521
|
+
icon: i
|
|
522
|
+
}),
|
|
523
|
+
/* @__PURE__ */ p("p", { children: s }),
|
|
524
|
+
/* @__PURE__ */ p(Z, {
|
|
525
|
+
iconSize: l,
|
|
526
|
+
icon: a
|
|
527
|
+
})
|
|
528
|
+
]
|
|
529
|
+
});
|
|
530
|
+
}
|
|
531
|
+
//#endregion
|
|
532
|
+
//#region src/components/calendar/_viewService.ts
|
|
533
|
+
var Je = class {
|
|
534
|
+
currentDay(e) {
|
|
535
|
+
return String(e.getDate()).padStart(2, "0");
|
|
536
|
+
}
|
|
537
|
+
currentMonth(e) {
|
|
538
|
+
return String(e.getMonth() + 1).padStart(2, "0");
|
|
539
|
+
}
|
|
540
|
+
currentYear(e) {
|
|
541
|
+
return String(e.getFullYear());
|
|
542
|
+
}
|
|
543
|
+
capitalize(e) {
|
|
544
|
+
return J(e);
|
|
545
|
+
}
|
|
546
|
+
parseDayType(e, t, n, r) {
|
|
547
|
+
let i = r[0].getDate(), a = r[0].getMonth(), o = r[0].getFullYear(), s = r[1].getDate(), c = r[1].getMonth(), l = r[1].getFullYear(), u = new Date(o, a, i), d = new Date(l, c, s), f = new Date(n, t, e);
|
|
548
|
+
return u.getTime() === f.getTime() || d.getTime() === f.getTime() ? "checkedDay" : f > u && f < d ? "middleDay" : "uncheckedDay";
|
|
549
|
+
}
|
|
550
|
+
listWeek(e) {
|
|
551
|
+
let t = [], n = new Date(Date.UTC(2023, 0, 1));
|
|
552
|
+
for (let r = 0; r < 7; r++) {
|
|
553
|
+
let i = new Date(n);
|
|
554
|
+
i.setUTCDate(n.getUTCDate() + r);
|
|
555
|
+
let a = i.toLocaleDateString(e, {
|
|
556
|
+
weekday: "short",
|
|
557
|
+
timeZone: "UTC"
|
|
558
|
+
});
|
|
559
|
+
t.push(a);
|
|
560
|
+
}
|
|
561
|
+
return t;
|
|
562
|
+
}
|
|
563
|
+
listMonths(e, t) {
|
|
564
|
+
let n = new Intl.DateTimeFormat(t, { month: "long" });
|
|
565
|
+
return Array.from({ length: 12 }, (t, r) => {
|
|
566
|
+
let i = new Date(e.getFullYear(), r, 1), a = n.format(i);
|
|
567
|
+
return {
|
|
568
|
+
label: this.capitalize(a),
|
|
569
|
+
value: String(r).padStart(2, "0")
|
|
570
|
+
};
|
|
571
|
+
});
|
|
572
|
+
}
|
|
573
|
+
listYears(e) {
|
|
574
|
+
let t = (/* @__PURE__ */ new Date()).getFullYear();
|
|
575
|
+
return Array.from({ length: e + 1 }, (n, r) => {
|
|
576
|
+
let i = t - e + r;
|
|
577
|
+
return {
|
|
578
|
+
label: String(i),
|
|
579
|
+
value: String(i)
|
|
580
|
+
};
|
|
581
|
+
}).reverse();
|
|
582
|
+
}
|
|
583
|
+
listMatrix(e, t) {
|
|
584
|
+
let n = e.getFullYear(), r = e.getMonth(), i = new Date(n, r, 1).getDay(), a = new Date(n, r + 1, 0).getDate(), o = new Date(n, r, 0).getDate(), s = Math.ceil((i + a) / 7) * 7, c = [], l = 1, u = 1;
|
|
585
|
+
for (let e = 0; e < s; e++) {
|
|
586
|
+
let s = Math.floor(e / 7);
|
|
587
|
+
if (c[s] || (c[s] = []), e < i) {
|
|
588
|
+
let a = o - (i - e - 1), l = r === 0 ? 11 : r - 1, u = r === 0 ? n - 1 : n;
|
|
589
|
+
c[s].push({
|
|
590
|
+
day: a,
|
|
591
|
+
month: l,
|
|
592
|
+
year: u,
|
|
593
|
+
dayOwner: "previous",
|
|
594
|
+
dayType: this.parseDayType(a, l, u, t)
|
|
595
|
+
});
|
|
596
|
+
} else if (l <= a) c[s].push({
|
|
597
|
+
day: l,
|
|
598
|
+
month: r,
|
|
599
|
+
year: n,
|
|
600
|
+
dayOwner: "current",
|
|
601
|
+
dayType: this.parseDayType(l, r, n, t)
|
|
602
|
+
}), l++;
|
|
603
|
+
else {
|
|
604
|
+
let e = r === 11 ? 0 : r + 1, i = r === 11 ? n + 1 : n;
|
|
605
|
+
c[s].push({
|
|
606
|
+
day: u,
|
|
607
|
+
month: e,
|
|
608
|
+
year: i,
|
|
609
|
+
dayOwner: "next",
|
|
610
|
+
dayType: this.parseDayType(u, e, i, t)
|
|
611
|
+
}), u++;
|
|
612
|
+
}
|
|
613
|
+
}
|
|
614
|
+
return c;
|
|
615
|
+
}
|
|
616
|
+
changeDay(e, t, n, r, i, a, o) {
|
|
617
|
+
let s = (e) => new Date(e.getFullYear(), e.getMonth(), e.getDate()), c = s(new Date(n, t, e));
|
|
618
|
+
if (o(c), r === "single") {
|
|
619
|
+
a([c, c]);
|
|
620
|
+
return;
|
|
621
|
+
}
|
|
622
|
+
let l = s(i[0]), u = s(i[1]), d = c.getTime(), f = l.getTime(), p = u.getTime();
|
|
623
|
+
if (d === f) {
|
|
624
|
+
a([c, c]);
|
|
625
|
+
return;
|
|
626
|
+
}
|
|
627
|
+
if (d === p) {
|
|
628
|
+
a([c, c]);
|
|
629
|
+
return;
|
|
630
|
+
}
|
|
631
|
+
if (c < l) {
|
|
632
|
+
a([c, u]);
|
|
633
|
+
return;
|
|
634
|
+
}
|
|
635
|
+
if (c > u) {
|
|
636
|
+
a([l, c]);
|
|
637
|
+
return;
|
|
638
|
+
}
|
|
639
|
+
if (Math.abs(d - f) <= Math.abs(p - d)) {
|
|
640
|
+
a([c, u]);
|
|
641
|
+
return;
|
|
642
|
+
}
|
|
643
|
+
a([l, c]);
|
|
644
|
+
}
|
|
645
|
+
changeMonth(e, t, n) {
|
|
646
|
+
let r = new Date(t);
|
|
647
|
+
r.setMonth(e), n(r);
|
|
648
|
+
}
|
|
649
|
+
changeYear(e, t, n) {
|
|
650
|
+
let r = new Date(t);
|
|
651
|
+
r.setFullYear(e), n(r);
|
|
652
|
+
}
|
|
653
|
+
nextMonth(e, t) {
|
|
654
|
+
let n = new Date(e);
|
|
655
|
+
n.setDate(1), n.setMonth(n.getMonth() + 1), t(n);
|
|
656
|
+
}
|
|
657
|
+
previousMonth(e, t) {
|
|
658
|
+
let n = new Date(e);
|
|
659
|
+
n.setDate(1), n.setMonth(n.getMonth() - 1), t(n);
|
|
660
|
+
}
|
|
661
|
+
}, Ye = n({});
|
|
662
|
+
function Xe() {
|
|
663
|
+
return a(Ye);
|
|
664
|
+
}
|
|
665
|
+
function Ze(e) {
|
|
666
|
+
let { calendarType: t, children: n, defaultValue: r, defaultViewValue: i = /* @__PURE__ */ new Date(), language: a = "pt-BR", onChange: o, onChangeView: s, value: c, viewValue: l } = e, d = t === "single" ? [r || /* @__PURE__ */ new Date(), r || /* @__PURE__ */ new Date()] : r || [/* @__PURE__ */ new Date(), /* @__PURE__ */ new Date()], [f, m] = u(i), [h, g] = u(d), _ = l || f, v = c ? t === "single" ? [c, c] : c : h, y = new Je();
|
|
667
|
+
function b(e) {
|
|
668
|
+
let n = [new Date(e[0]), new Date(e[1])];
|
|
669
|
+
o && t === "range" && o(n), o && t === "single" && o(n[0]), g(n);
|
|
670
|
+
}
|
|
671
|
+
function x(e) {
|
|
672
|
+
s && s(e), m(e);
|
|
673
|
+
}
|
|
674
|
+
return /* @__PURE__ */ p(Ye.Provider, {
|
|
675
|
+
value: {
|
|
676
|
+
valueDate: v,
|
|
677
|
+
viewDate: _,
|
|
678
|
+
currentDate: _.toLocaleDateString(a).slice(3),
|
|
679
|
+
currentDay: y.currentDay(_),
|
|
680
|
+
currentMonth: y.currentMonth(_),
|
|
681
|
+
currentYear: y.currentYear(_),
|
|
682
|
+
listWeek: y.listWeek(a),
|
|
683
|
+
listMonths: y.listMonths(_, a),
|
|
684
|
+
listYears: y.listYears(100),
|
|
685
|
+
listMatrix: y.listMatrix(_, v),
|
|
686
|
+
changeDay: (e, n, r) => y.changeDay(e, n, r, t, v, b, x),
|
|
687
|
+
changeMonth: (e) => y.changeMonth(e, _, x),
|
|
688
|
+
changeYear: (e) => y.changeYear(e, _, x),
|
|
689
|
+
nextMonth: () => y.nextMonth(_, x),
|
|
690
|
+
previousMonth: () => y.previousMonth(_, x)
|
|
691
|
+
},
|
|
692
|
+
children: n
|
|
693
|
+
});
|
|
694
|
+
}
|
|
695
|
+
//#endregion
|
|
696
|
+
//#region src/components/calendar/calendarContainer/index.tsx
|
|
697
|
+
function Qe({ children: e }) {
|
|
698
|
+
return /* @__PURE__ */ p("div", {
|
|
699
|
+
className: "arkynCalendarContainer",
|
|
700
|
+
children: e
|
|
701
|
+
});
|
|
702
|
+
}
|
|
703
|
+
//#endregion
|
|
704
|
+
//#region src/services/fieldTemplate.tsx
|
|
705
|
+
function Q(e) {
|
|
706
|
+
let { name: t, label: n, showAsterisk: r, className: i, unShowFieldTemplate: a, errorMessage: o, children: s, orientation: c } = e;
|
|
707
|
+
return a ? s : /* @__PURE__ */ m(ze, {
|
|
708
|
+
id: t,
|
|
709
|
+
className: i,
|
|
710
|
+
orientation: c,
|
|
711
|
+
children: [
|
|
712
|
+
n && /* @__PURE__ */ p(Re, {
|
|
713
|
+
htmlFor: t,
|
|
714
|
+
showAsterisk: r,
|
|
715
|
+
children: n
|
|
716
|
+
}),
|
|
717
|
+
s,
|
|
718
|
+
o && /* @__PURE__ */ p(Le, { children: o })
|
|
719
|
+
]
|
|
720
|
+
});
|
|
721
|
+
}
|
|
722
|
+
//#endregion
|
|
723
|
+
//#region src/components/select/selectChevron/index.tsx
|
|
724
|
+
function $e(e) {
|
|
725
|
+
let { iconSize: t, isLoading: n, disabled: r, readOnly: i, isFocused: a } = e;
|
|
726
|
+
return n ? null : /* @__PURE__ */ p(C, {
|
|
727
|
+
className: `arkynSelectChevron ${r || i ? "notAnimate" : ""} ${a ? "focused" : ""}`,
|
|
728
|
+
strokeWidth: 2.5,
|
|
729
|
+
style: {
|
|
730
|
+
minWidth: t,
|
|
731
|
+
minHeight: t,
|
|
732
|
+
maxWidth: t,
|
|
733
|
+
maxHeight: t
|
|
734
|
+
}
|
|
735
|
+
});
|
|
736
|
+
}
|
|
737
|
+
//#endregion
|
|
738
|
+
//#region src/components/select/selectContainer/index.tsx
|
|
739
|
+
function et(e) {
|
|
740
|
+
let { children: t, handleContainerFocus: n, disabled: r, isError: i, isLoading: a, isFocused: o, className: s, readOnly: c, variant: l, size: u, id: d, prefixExists: f } = e;
|
|
741
|
+
return /* @__PURE__ */ p("section", {
|
|
742
|
+
id: d,
|
|
743
|
+
className: `arkynSelectContainer ${f ? "hasPrefix" : ""} ${l} ${u} ${r || c || a ? "opacity" : ""} ${i ? "errored" : ""} ${o ? "focused" : ""} ${s}`,
|
|
744
|
+
onClick: n,
|
|
745
|
+
children: t
|
|
746
|
+
});
|
|
747
|
+
}
|
|
748
|
+
//#endregion
|
|
749
|
+
//#region src/components/select/selectContent/index.tsx
|
|
750
|
+
function tt(e) {
|
|
751
|
+
let { children: t, size: n } = e;
|
|
752
|
+
return /* @__PURE__ */ p("div", {
|
|
753
|
+
className: `arkynSelectContent ${n}`,
|
|
754
|
+
children: t
|
|
755
|
+
});
|
|
756
|
+
}
|
|
757
|
+
//#endregion
|
|
758
|
+
//#region src/components/select/selectOption/index.tsx
|
|
759
|
+
function nt(e) {
|
|
760
|
+
let { label: t, optionHasSelected: n, handleChangeValue: r, value: i, size: a } = e;
|
|
761
|
+
return /* @__PURE__ */ m("button", {
|
|
762
|
+
type: "button",
|
|
763
|
+
onClick: () => r(i),
|
|
764
|
+
className: `arkynSelectOption ${a} ${n(i) ? "active" : ""}`,
|
|
765
|
+
children: [
|
|
766
|
+
t,
|
|
767
|
+
" ",
|
|
768
|
+
/* @__PURE__ */ p(x, {})
|
|
769
|
+
]
|
|
770
|
+
});
|
|
771
|
+
}
|
|
772
|
+
//#endregion
|
|
773
|
+
//#region src/hooks/useScrollLock.ts
|
|
774
|
+
function rt() {
|
|
775
|
+
return typeof window > "u" ? 0 : window.innerWidth - document.documentElement.clientWidth;
|
|
776
|
+
}
|
|
777
|
+
function it(e) {
|
|
778
|
+
o(() => {
|
|
779
|
+
if (e) {
|
|
780
|
+
let e = document.body.style.overflow, t = document.body.style.paddingRight, n = rt();
|
|
781
|
+
if (n > 0) {
|
|
782
|
+
let e = window.getComputedStyle(document.body), t = parseInt(e.paddingRight, 10) || 0;
|
|
783
|
+
document.body.style.paddingRight = `${t + n}px`;
|
|
784
|
+
}
|
|
785
|
+
return document.body.style.overflow = "hidden", () => {
|
|
786
|
+
document.body.style.overflow = e, document.body.style.paddingRight = t;
|
|
787
|
+
};
|
|
788
|
+
}
|
|
789
|
+
}, [e]);
|
|
790
|
+
}
|
|
791
|
+
//#endregion
|
|
792
|
+
//#region src/components/input/index.tsx
|
|
793
|
+
function at(e) {
|
|
794
|
+
let { name: t, disabled: n, title: r, style: i, variant: a = "solid", label: o, className: c = "", prefix: d, suffix: f, isLoading: h = !1, leftIcon: g, readOnly: _, onFocus: v, onBlur: y, unShowFieldTemplate: b = !1, errorMessage: x, showAsterisk: S, rightIcon: C, type: w = "text", size: T = "md", id: E, value: D, placeholder: O, orientation: k, ...A } = e, { fieldErrors: j } = X(), [M, N] = u(!1), P = l(null), F = s(), I = E || F, R = x || j?.[t], z = !!R, B = n || h, V = {
|
|
795
|
+
md: 20,
|
|
796
|
+
lg: 20
|
|
797
|
+
}[T], H = C ? "right" : "left", U = H === "left" && h, W = H === "right" && h;
|
|
798
|
+
function G() {
|
|
799
|
+
B || !P?.current || (N(!0), P.current.focus());
|
|
800
|
+
}
|
|
801
|
+
function K(e) {
|
|
802
|
+
N(!0), v && v(e);
|
|
803
|
+
}
|
|
804
|
+
function q(e) {
|
|
805
|
+
N(!1), y && y(e);
|
|
806
|
+
}
|
|
807
|
+
return w === "hidden" ? /* @__PURE__ */ p("input", {
|
|
808
|
+
style: { display: "none" },
|
|
809
|
+
readOnly: !0,
|
|
810
|
+
type: "text",
|
|
811
|
+
ref: P,
|
|
812
|
+
...A
|
|
813
|
+
}) : /* @__PURE__ */ p(Q, {
|
|
814
|
+
name: t,
|
|
815
|
+
label: o,
|
|
816
|
+
showAsterisk: S,
|
|
817
|
+
className: c,
|
|
818
|
+
errorMessage: R,
|
|
819
|
+
unShowFieldTemplate: b,
|
|
820
|
+
orientation: k,
|
|
821
|
+
children: /* @__PURE__ */ m("section", {
|
|
822
|
+
title: r,
|
|
823
|
+
style: i,
|
|
824
|
+
onClick: G,
|
|
825
|
+
className: `arkynInput ${d ? "hasPrefix" : ""} ${n ? "disabled" : ""} ${f ? "hasSuffix" : ""} ${a} ${T} ${B || _ || h ? "opacity" : ""} ${z ? "errored" : ""} ${M ? "focused" : ""}`,
|
|
826
|
+
children: [
|
|
827
|
+
/* @__PURE__ */ p(Z, {
|
|
828
|
+
iconSize: V,
|
|
829
|
+
icon: d,
|
|
830
|
+
className: "prefix"
|
|
831
|
+
}),
|
|
832
|
+
/* @__PURE__ */ p(Z, {
|
|
833
|
+
show: U,
|
|
834
|
+
iconSize: V,
|
|
835
|
+
className: "spinner",
|
|
836
|
+
icon: L
|
|
837
|
+
}),
|
|
838
|
+
/* @__PURE__ */ p(Z, {
|
|
839
|
+
show: !h,
|
|
840
|
+
icon: g,
|
|
841
|
+
iconSize: V
|
|
842
|
+
}),
|
|
843
|
+
/* @__PURE__ */ p("input", {
|
|
844
|
+
disabled: B,
|
|
845
|
+
readOnly: _,
|
|
846
|
+
ref: P,
|
|
847
|
+
onFocus: K,
|
|
848
|
+
onBlur: q,
|
|
849
|
+
type: w,
|
|
850
|
+
id: I,
|
|
851
|
+
name: t,
|
|
852
|
+
placeholder: B && D || O,
|
|
853
|
+
value: B ? void 0 : D,
|
|
854
|
+
...A
|
|
855
|
+
}),
|
|
856
|
+
/* @__PURE__ */ p(Z, {
|
|
857
|
+
show: !h,
|
|
858
|
+
icon: C,
|
|
859
|
+
iconSize: V
|
|
860
|
+
}),
|
|
861
|
+
/* @__PURE__ */ p(Z, {
|
|
862
|
+
show: W,
|
|
863
|
+
iconSize: V,
|
|
864
|
+
className: "spinner",
|
|
865
|
+
icon: L
|
|
866
|
+
}),
|
|
867
|
+
/* @__PURE__ */ p(Z, {
|
|
868
|
+
iconSize: V,
|
|
869
|
+
icon: f,
|
|
870
|
+
className: "suffix"
|
|
871
|
+
})
|
|
872
|
+
]
|
|
873
|
+
})
|
|
874
|
+
});
|
|
875
|
+
}
|
|
876
|
+
//#endregion
|
|
877
|
+
//#region src/components/select/selectOptionsContainer/index.tsx
|
|
878
|
+
function ot(e) {
|
|
879
|
+
let { children: t, isFocused: n, isSearchable: r, search: i, onSearch: a } = e, s = l(null), [c, d] = u("bottom");
|
|
880
|
+
it(n), o(() => {
|
|
881
|
+
n && (() => {
|
|
882
|
+
if (!s.current) return;
|
|
883
|
+
let e = s.current.parentElement;
|
|
884
|
+
if (!e) return;
|
|
885
|
+
let t = e.getBoundingClientRect();
|
|
886
|
+
window.innerHeight - t.bottom < 300 && t.top > 300 ? d("top") : d("bottom");
|
|
887
|
+
})();
|
|
888
|
+
}, [n]);
|
|
889
|
+
function f(e) {
|
|
890
|
+
r && a(e.target.value);
|
|
891
|
+
}
|
|
892
|
+
return n ? /* @__PURE__ */ m("div", {
|
|
893
|
+
ref: s,
|
|
894
|
+
className: `arkynSelectOptionsContainer ${c}`,
|
|
895
|
+
children: [r && /* @__PURE__ */ p(at, {
|
|
896
|
+
type: "search",
|
|
897
|
+
name: "search-select",
|
|
898
|
+
variant: "underline",
|
|
899
|
+
leftIcon: U,
|
|
900
|
+
value: i,
|
|
901
|
+
onChange: f
|
|
902
|
+
}), t]
|
|
903
|
+
}) : null;
|
|
904
|
+
}
|
|
905
|
+
//#endregion
|
|
906
|
+
//#region src/components/select/selectOverlay/index.tsx
|
|
907
|
+
function st(e) {
|
|
908
|
+
let { isFocused: t, handleBlur: n } = e;
|
|
909
|
+
return t ? /* @__PURE__ */ p("aside", {
|
|
910
|
+
className: "arkynSelectOverlay",
|
|
911
|
+
onClick: n
|
|
912
|
+
}) : null;
|
|
913
|
+
}
|
|
914
|
+
//#endregion
|
|
915
|
+
//#region src/components/select/selectSpinner/index.tsx
|
|
916
|
+
function ct(e) {
|
|
917
|
+
let { iconSize: t, isLoading: n } = e;
|
|
918
|
+
return n ? /* @__PURE__ */ p(L, {
|
|
919
|
+
className: "arkynSelectSpinner",
|
|
920
|
+
size: t,
|
|
921
|
+
strokeWidth: 2.5
|
|
922
|
+
}) : null;
|
|
923
|
+
}
|
|
924
|
+
//#endregion
|
|
925
|
+
//#region src/components/select/index.tsx
|
|
926
|
+
function lt(e) {
|
|
927
|
+
let { name: t, options: n, className: r = "", placeholder: i = "Selecione...", closeOnSelect: a = !0, defaultValue: o = "", errorMessage: c, isLoading: d = !1, readOnly: f = !1, isSearchable: h = !1, id: g, label: _, showAsterisk: v, leftIcon: y, onSearch: b, onChange: x, onBlur: S, notFoundText: C = "Sem opções disponíveis", onFocus: w, disabled: T = !1, prefix: E, size: D = "md", value: O, variant: k = "solid", orientation: A = "vertical", unShowFieldTemplate: j = !1 } = e, { fieldErrors: M } = X(), N = l(null), P = s(), F = g || P, I = c || M?.[t], L = !!I, R = T || d || f, z = {
|
|
928
|
+
md: 20,
|
|
929
|
+
lg: 20
|
|
930
|
+
}[D], [B, V] = u(""), [H, U] = u(!1), [W, G] = u(o), K = O || W;
|
|
931
|
+
function q(e) {
|
|
932
|
+
return K === e;
|
|
933
|
+
}
|
|
934
|
+
function ee(e) {
|
|
935
|
+
return n.find((t) => t.value === e)?.label || "";
|
|
936
|
+
}
|
|
937
|
+
function J() {
|
|
938
|
+
R || !N?.current || H || (U(!0), N.current.focus(), w?.());
|
|
939
|
+
}
|
|
940
|
+
function te() {
|
|
941
|
+
U(!1), S && N.current && N.current.blur();
|
|
942
|
+
}
|
|
943
|
+
function ne(e) {
|
|
944
|
+
V(e), b && b(e);
|
|
945
|
+
}
|
|
946
|
+
function re(e) {
|
|
947
|
+
q(e) ? (G(""), x && x("")) : (G(e), x && x(e)), a && te();
|
|
948
|
+
}
|
|
949
|
+
let ie = n.filter((t) => !!(e.onSearch || !e.isSearchable || t.label.toLowerCase().includes(B.toLowerCase())));
|
|
950
|
+
return /* @__PURE__ */ p(Q, {
|
|
951
|
+
name: t,
|
|
952
|
+
label: _,
|
|
953
|
+
showAsterisk: v,
|
|
954
|
+
className: r,
|
|
955
|
+
errorMessage: I,
|
|
956
|
+
unShowFieldTemplate: j,
|
|
957
|
+
orientation: A,
|
|
958
|
+
children: /* @__PURE__ */ m(et, {
|
|
959
|
+
handleContainerFocus: J,
|
|
960
|
+
disabled: R,
|
|
961
|
+
isError: L,
|
|
962
|
+
isFocused: H,
|
|
963
|
+
isLoading: d,
|
|
964
|
+
readOnly: f,
|
|
965
|
+
size: D,
|
|
966
|
+
variant: k,
|
|
967
|
+
prefixExists: !!E,
|
|
968
|
+
id: F,
|
|
969
|
+
children: [
|
|
970
|
+
/* @__PURE__ */ p("input", {
|
|
971
|
+
ref: N,
|
|
972
|
+
name: t,
|
|
973
|
+
value: K,
|
|
974
|
+
type: "hidden"
|
|
975
|
+
}),
|
|
976
|
+
/* @__PURE__ */ p(Z, {
|
|
977
|
+
iconSize: z,
|
|
978
|
+
icon: E,
|
|
979
|
+
className: "prefix"
|
|
980
|
+
}),
|
|
981
|
+
y && /* @__PURE__ */ p(y, {
|
|
982
|
+
size: z,
|
|
983
|
+
strokeWidth: 2.5
|
|
984
|
+
}),
|
|
985
|
+
/* @__PURE__ */ m(tt, {
|
|
986
|
+
size: D,
|
|
987
|
+
children: [K !== "" && /* @__PURE__ */ p("p", {
|
|
988
|
+
className: "hasValue",
|
|
989
|
+
children: ee(K)
|
|
990
|
+
}), K === "" && /* @__PURE__ */ p("p", { children: i })]
|
|
991
|
+
}),
|
|
992
|
+
/* @__PURE__ */ m(ot, {
|
|
993
|
+
isFocused: H,
|
|
994
|
+
isSearchable: h,
|
|
995
|
+
search: B,
|
|
996
|
+
onSearch: ne,
|
|
997
|
+
children: [ie.map(({ label: e, value: t }) => /* @__PURE__ */ p(nt, {
|
|
998
|
+
label: e,
|
|
999
|
+
value: t,
|
|
1000
|
+
size: D,
|
|
1001
|
+
handleChangeValue: re,
|
|
1002
|
+
optionHasSelected: q
|
|
1003
|
+
}, t)), ie.length <= 0 && /* @__PURE__ */ p("p", { children: C })]
|
|
1004
|
+
}),
|
|
1005
|
+
/* @__PURE__ */ p($e, {
|
|
1006
|
+
disabled: R,
|
|
1007
|
+
isFocused: H,
|
|
1008
|
+
readOnly: f,
|
|
1009
|
+
iconSize: z,
|
|
1010
|
+
isLoading: d
|
|
1011
|
+
}),
|
|
1012
|
+
/* @__PURE__ */ p(ct, {
|
|
1013
|
+
iconSize: z,
|
|
1014
|
+
isLoading: d
|
|
1015
|
+
}),
|
|
1016
|
+
/* @__PURE__ */ p(st, {
|
|
1017
|
+
handleBlur: te,
|
|
1018
|
+
isFocused: H
|
|
1019
|
+
})
|
|
1020
|
+
]
|
|
1021
|
+
})
|
|
1022
|
+
});
|
|
1023
|
+
}
|
|
1024
|
+
//#endregion
|
|
1025
|
+
//#region src/components/calendar/calendarHeader/index.tsx
|
|
1026
|
+
function ut({ basicMode: e }) {
|
|
1027
|
+
let t = Xe();
|
|
1028
|
+
return e ? /* @__PURE__ */ m("div", {
|
|
1029
|
+
className: "arkynCalendarHeader",
|
|
1030
|
+
children: [
|
|
1031
|
+
/* @__PURE__ */ p("button", {
|
|
1032
|
+
type: "button",
|
|
1033
|
+
className: "arkynCalendarButton",
|
|
1034
|
+
onClick: () => t.previousMonth(),
|
|
1035
|
+
children: /* @__PURE__ */ p(w, {})
|
|
1036
|
+
}),
|
|
1037
|
+
/* @__PURE__ */ p("p", { children: t.currentDate }),
|
|
1038
|
+
/* @__PURE__ */ p("button", {
|
|
1039
|
+
type: "button",
|
|
1040
|
+
className: "arkynCalendarButton",
|
|
1041
|
+
onClick: () => t.nextMonth(),
|
|
1042
|
+
children: /* @__PURE__ */ p(T, {})
|
|
1043
|
+
})
|
|
1044
|
+
]
|
|
1045
|
+
}) : /* @__PURE__ */ m("div", {
|
|
1046
|
+
className: "arkynCalendarHeader",
|
|
1047
|
+
children: [/* @__PURE__ */ m("div", { children: [/* @__PURE__ */ p("button", {
|
|
1048
|
+
type: "button",
|
|
1049
|
+
className: "arkynCalendarButton",
|
|
1050
|
+
onClick: () => t.previousMonth(),
|
|
1051
|
+
children: /* @__PURE__ */ p(w, {})
|
|
1052
|
+
}), /* @__PURE__ */ p("button", {
|
|
1053
|
+
type: "button",
|
|
1054
|
+
className: "arkynCalendarButton",
|
|
1055
|
+
onClick: () => t.nextMonth(),
|
|
1056
|
+
children: /* @__PURE__ */ p(T, {})
|
|
1057
|
+
})] }), /* @__PURE__ */ m("div", { children: [/* @__PURE__ */ p(lt, {
|
|
1058
|
+
name: "calendarMonth",
|
|
1059
|
+
variant: "underline",
|
|
1060
|
+
className: "calendarMonthSelect",
|
|
1061
|
+
value: t.currentMonth,
|
|
1062
|
+
options: t.listMonths,
|
|
1063
|
+
onChange: (e) => t.changeMonth(+e)
|
|
1064
|
+
}), /* @__PURE__ */ p(lt, {
|
|
1065
|
+
name: "calendarYear",
|
|
1066
|
+
variant: "underline",
|
|
1067
|
+
className: "calendarYearSelect",
|
|
1068
|
+
value: t.currentYear,
|
|
1069
|
+
options: t.listYears,
|
|
1070
|
+
onChange: (e) => t.changeYear(+e)
|
|
1071
|
+
})] })]
|
|
1072
|
+
});
|
|
1073
|
+
}
|
|
1074
|
+
//#endregion
|
|
1075
|
+
//#region src/components/calendar/calendarTableTd/index.tsx
|
|
1076
|
+
function dt(e) {
|
|
1077
|
+
let { day: t, month: n, year: r, dayOwner: i, dayType: a } = e, { changeDay: o } = Xe();
|
|
1078
|
+
function s() {
|
|
1079
|
+
let e = /* @__PURE__ */ new Date();
|
|
1080
|
+
return t === e.getDate() && n === e.getMonth() && r === e.getFullYear();
|
|
1081
|
+
}
|
|
1082
|
+
return /* @__PURE__ */ p("td", {
|
|
1083
|
+
onClick: () => o(t, n, r),
|
|
1084
|
+
className: `arkynCalendarTableTd ${i} ${a} ${s() ? "today" : ""}`,
|
|
1085
|
+
children: /* @__PURE__ */ m("div", {
|
|
1086
|
+
className: "textGroup",
|
|
1087
|
+
children: [/* @__PURE__ */ p("span", {}), /* @__PURE__ */ p("p", { children: t })]
|
|
1088
|
+
})
|
|
1089
|
+
});
|
|
1090
|
+
}
|
|
1091
|
+
//#endregion
|
|
1092
|
+
//#region src/components/calendar/calendarTableBody/index.tsx
|
|
1093
|
+
function ft() {
|
|
1094
|
+
return /* @__PURE__ */ p("tbody", {
|
|
1095
|
+
className: "arkynCalendarTableBody",
|
|
1096
|
+
children: Xe().listMatrix.map((e, t) => /* @__PURE__ */ p("tr", { children: e.map((e, n) => /* @__PURE__ */ p(dt, { ...e }, `day-${t}-${n}`)) }, `week-${t}`))
|
|
1097
|
+
});
|
|
1098
|
+
}
|
|
1099
|
+
//#endregion
|
|
1100
|
+
//#region src/components/calendar/calendarTableContainer/index.tsx
|
|
1101
|
+
function pt({ children: e }) {
|
|
1102
|
+
return /* @__PURE__ */ p("table", {
|
|
1103
|
+
className: "arkynCalendarTableContainer",
|
|
1104
|
+
children: e
|
|
1105
|
+
});
|
|
1106
|
+
}
|
|
1107
|
+
//#endregion
|
|
1108
|
+
//#region src/components/calendar/calendarTableHeader/index.tsx
|
|
1109
|
+
function mt() {
|
|
1110
|
+
let { listWeek: e } = Xe();
|
|
1111
|
+
return /* @__PURE__ */ p("thead", {
|
|
1112
|
+
className: "arkynCalendarTableHeader",
|
|
1113
|
+
children: /* @__PURE__ */ p("tr", { children: e.map((e) => /* @__PURE__ */ p("th", { children: J(e) }, e)) })
|
|
1114
|
+
});
|
|
1115
|
+
}
|
|
1116
|
+
//#endregion
|
|
1117
|
+
//#region src/components/calendar/index.tsx
|
|
1118
|
+
function ht(e) {
|
|
1119
|
+
let t = e.variant || "complete";
|
|
1120
|
+
return e.type === "range" ? /* @__PURE__ */ p(Ze, {
|
|
1121
|
+
value: e.value,
|
|
1122
|
+
viewValue: e.viewValue,
|
|
1123
|
+
defaultViewValue: e.defaultViewValue,
|
|
1124
|
+
defaultValue: e.defaultValue,
|
|
1125
|
+
calendarType: "range",
|
|
1126
|
+
onChange: e.onChange,
|
|
1127
|
+
onChangeView: e.onChangeView,
|
|
1128
|
+
children: /* @__PURE__ */ m(Qe, { children: [/* @__PURE__ */ p(ut, { basicMode: t.includes("basic") }), /* @__PURE__ */ m(pt, { children: [/* @__PURE__ */ p(mt, {}), /* @__PURE__ */ p(ft, {})] })] })
|
|
1129
|
+
}) : /* @__PURE__ */ p(Ze, {
|
|
1130
|
+
value: e.value,
|
|
1131
|
+
viewValue: e.viewValue,
|
|
1132
|
+
defaultViewValue: e.defaultViewValue,
|
|
1133
|
+
defaultValue: e.defaultValue,
|
|
1134
|
+
calendarType: "single",
|
|
1135
|
+
onChange: e.onChange,
|
|
1136
|
+
onChangeView: e.onChangeView,
|
|
1137
|
+
children: /* @__PURE__ */ m(Qe, { children: [/* @__PURE__ */ p(ut, { basicMode: t.includes("basic") }), /* @__PURE__ */ m(pt, { children: [/* @__PURE__ */ p(mt, {}), /* @__PURE__ */ p(ft, {})] })] })
|
|
1138
|
+
});
|
|
1139
|
+
}
|
|
1140
|
+
//#endregion
|
|
1141
|
+
//#region src/components/cardTab/cardTabContext.tsx
|
|
1142
|
+
var gt = n({});
|
|
1143
|
+
function _t() {
|
|
1144
|
+
return a(gt);
|
|
1145
|
+
}
|
|
1146
|
+
function vt(e) {
|
|
1147
|
+
let { disabled: t, currentTab: n, changeCurrentTab: r } = e, i = c(() => ({
|
|
1148
|
+
disabled: t,
|
|
1149
|
+
currentTab: n,
|
|
1150
|
+
changeCurrentTab: r
|
|
1151
|
+
}), [
|
|
1152
|
+
t,
|
|
1153
|
+
n,
|
|
1154
|
+
r
|
|
1155
|
+
]);
|
|
1156
|
+
return /* @__PURE__ */ p(gt.Provider, {
|
|
1157
|
+
value: i,
|
|
1158
|
+
children: e.children
|
|
1159
|
+
});
|
|
1160
|
+
}
|
|
1161
|
+
//#endregion
|
|
1162
|
+
//#region src/components/cardTab/cardTabButton/index.tsx
|
|
1163
|
+
function yt(e) {
|
|
1164
|
+
let { children: t, disabled: n = !1, className: r = "", onClick: i, value: a, ...o } = e, { disabled: s, currentTab: c, changeCurrentTab: l } = _t(), u = s || n, d = `arkynCardTabButton ${u ? "isDisabled" : ""} ${c === a && a ? "isActive" : ""} ${r}`;
|
|
1165
|
+
function f(e) {
|
|
1166
|
+
l(a), i?.(e);
|
|
1167
|
+
}
|
|
1168
|
+
return /* @__PURE__ */ p("button", {
|
|
1169
|
+
onClick: f,
|
|
1170
|
+
className: d.trim(),
|
|
1171
|
+
...o,
|
|
1172
|
+
disabled: u,
|
|
1173
|
+
type: "button",
|
|
1174
|
+
children: t
|
|
1175
|
+
});
|
|
1176
|
+
}
|
|
1177
|
+
//#endregion
|
|
1178
|
+
//#region src/components/cardTab/cardTabContainer/index.tsx
|
|
1179
|
+
function bt(e) {
|
|
1180
|
+
let { children: t, onChange: n, defaultValue: r, disabled: i = !1, className: a, ...o } = e, [s, c] = u(r || ""), l = `arkynCardTabContainer ${a || ""}`;
|
|
1181
|
+
function d(e) {
|
|
1182
|
+
c(e), n && n(e);
|
|
1183
|
+
}
|
|
1184
|
+
return /* @__PURE__ */ p(vt, {
|
|
1185
|
+
disabled: i,
|
|
1186
|
+
currentTab: s,
|
|
1187
|
+
changeCurrentTab: d,
|
|
1188
|
+
children: /* @__PURE__ */ p("nav", {
|
|
1189
|
+
className: l.trim(),
|
|
1190
|
+
...o,
|
|
1191
|
+
children: t
|
|
1192
|
+
})
|
|
1193
|
+
});
|
|
1194
|
+
}
|
|
1195
|
+
//#endregion
|
|
1196
|
+
//#region src/components/checkbox/index.tsx
|
|
1197
|
+
function xt(e) {
|
|
1198
|
+
let { id: t, name: n, className: r = "", size: i = "md", errorMessage: a, defaultChecked: o = !1, label: c, checked: d = null, onCheck: f, orientation: h = "horizontalReverse", showAsterisk: g, unShowFieldTemplate: _, value: v, ...y } = e, { fieldErrors: b } = X(), S = l(null), C = s(), w = t || C, T = a || b?.[n], E = !!T, [D, O] = u(o || !1), k = typeof d == "boolean" ? d : D, A = `arkynCheckbox ${i} ${E ? "errorTrue" : "errorFalse"} ${k ? "checkedTrue" : "checkedFalse"}`;
|
|
1199
|
+
function j() {
|
|
1200
|
+
let e = D;
|
|
1201
|
+
O(!e), f?.(e ? "" : v || "checked");
|
|
1202
|
+
}
|
|
1203
|
+
return /* @__PURE__ */ p(Q, {
|
|
1204
|
+
name: n,
|
|
1205
|
+
label: c,
|
|
1206
|
+
showAsterisk: g,
|
|
1207
|
+
className: r,
|
|
1208
|
+
errorMessage: T,
|
|
1209
|
+
unShowFieldTemplate: _,
|
|
1210
|
+
orientation: h,
|
|
1211
|
+
children: /* @__PURE__ */ m("button", {
|
|
1212
|
+
id: w,
|
|
1213
|
+
type: "button",
|
|
1214
|
+
className: A,
|
|
1215
|
+
onClick: j,
|
|
1216
|
+
...y,
|
|
1217
|
+
children: [/* @__PURE__ */ p("input", {
|
|
1218
|
+
type: "hidden",
|
|
1219
|
+
name: n,
|
|
1220
|
+
ref: S,
|
|
1221
|
+
value: k ? v || "checked" : ""
|
|
1222
|
+
}), /* @__PURE__ */ p(x, {})]
|
|
1223
|
+
})
|
|
1224
|
+
});
|
|
1225
|
+
}
|
|
1226
|
+
//#endregion
|
|
1227
|
+
//#region src/hooks/useHydrated.ts
|
|
1228
|
+
function St() {
|
|
1229
|
+
return () => {};
|
|
1230
|
+
}
|
|
1231
|
+
function Ct() {
|
|
1232
|
+
return d(St, () => !0, () => !1);
|
|
1233
|
+
}
|
|
1234
|
+
//#endregion
|
|
1235
|
+
//#region src/components/clientOnly.tsx
|
|
1236
|
+
function wt(e) {
|
|
1237
|
+
let { children: t, fallback: n = null } = e;
|
|
1238
|
+
return Ct() ? t() : n;
|
|
1239
|
+
}
|
|
1240
|
+
//#endregion
|
|
1241
|
+
//#region src/services/maskCurrencyValues.ts
|
|
1242
|
+
function Tt(e) {
|
|
1243
|
+
let t = e;
|
|
1244
|
+
return typeof e == "string" ? (t = +re(e), t % 1 != 0 && (t = t.toFixed(2))) : t = Number.isInteger(e) ? Number(e) * 10 ** 2 : e.toFixed(2), re(String(t)) / 10 ** 2;
|
|
1245
|
+
}
|
|
1246
|
+
function Et(e, t) {
|
|
1247
|
+
if (!e) return [0, te(0, t)];
|
|
1248
|
+
let n = Tt(e);
|
|
1249
|
+
return [n, te(n, t)];
|
|
1250
|
+
}
|
|
1251
|
+
//#endregion
|
|
1252
|
+
//#region src/components/currencyInput/index.tsx
|
|
1253
|
+
function Dt(e) {
|
|
1254
|
+
let { name: t, disabled: n, title: r, style: i, variant: a = "solid", label: c, className: d = "", value: f, defaultValue: h, max: g = 1e9, locale: _, onChange: v, prefix: y, suffix: b, isLoading: x = !1, leftIcon: S, readOnly: C, onFocus: w, onBlur: T, errorMessage: E, unShowFieldTemplate: D, orientation: O, showAsterisk: k, rightIcon: A, size: j = "md", id: M, ...N } = e, { fieldErrors: P } = X(), [F, I] = u(!1), [R, z] = u("0"), B = l(null), V = s(), H = M || V, U = E || P?.[t], W = !!U, G = n || x, K = {
|
|
1255
|
+
md: 20,
|
|
1256
|
+
lg: 20
|
|
1257
|
+
}[j], q = A ? "right" : "left", ee = q === "left" && x, J = q === "right" && x;
|
|
1258
|
+
function te() {
|
|
1259
|
+
G || !B?.current || (I(!0), B.current.focus());
|
|
1260
|
+
}
|
|
1261
|
+
function ne(e) {
|
|
1262
|
+
I(!0), w && w(e);
|
|
1263
|
+
}
|
|
1264
|
+
function re(e) {
|
|
1265
|
+
I(!1), T && T(e);
|
|
1266
|
+
}
|
|
1267
|
+
let ie = (e) => {
|
|
1268
|
+
let [t, n] = Et(e, _);
|
|
1269
|
+
return !g || t <= g ? (z(n), [t, n]) : Et(e, _);
|
|
1270
|
+
};
|
|
1271
|
+
return o(() => {
|
|
1272
|
+
function e() {
|
|
1273
|
+
if (typeof f == "number") return f;
|
|
1274
|
+
if (typeof h == "number") return h;
|
|
1275
|
+
}
|
|
1276
|
+
let [, t] = Et(e(), _);
|
|
1277
|
+
z(t);
|
|
1278
|
+
}, [
|
|
1279
|
+
_,
|
|
1280
|
+
h,
|
|
1281
|
+
f
|
|
1282
|
+
]), /* @__PURE__ */ p(Q, {
|
|
1283
|
+
name: t,
|
|
1284
|
+
label: c,
|
|
1285
|
+
showAsterisk: k,
|
|
1286
|
+
className: d,
|
|
1287
|
+
errorMessage: U,
|
|
1288
|
+
unShowFieldTemplate: D,
|
|
1289
|
+
orientation: O,
|
|
1290
|
+
children: /* @__PURE__ */ m("section", {
|
|
1291
|
+
title: r,
|
|
1292
|
+
style: i,
|
|
1293
|
+
className: `arkynCurrencyInput ${y ? "hasPrefix" : ""} ${b ? "hasSuffix" : ""} ${a} ${j} ${G || C || x ? "opacity" : ""} ${W ? "errored" : ""} ${F ? "focused" : ""}`,
|
|
1294
|
+
onClick: te,
|
|
1295
|
+
children: [
|
|
1296
|
+
/* @__PURE__ */ p(Z, {
|
|
1297
|
+
iconSize: K,
|
|
1298
|
+
icon: y,
|
|
1299
|
+
className: "prefix"
|
|
1300
|
+
}),
|
|
1301
|
+
/* @__PURE__ */ p(Z, {
|
|
1302
|
+
show: ee,
|
|
1303
|
+
iconSize: K,
|
|
1304
|
+
className: "spinner",
|
|
1305
|
+
icon: L
|
|
1306
|
+
}),
|
|
1307
|
+
/* @__PURE__ */ p(Z, {
|
|
1308
|
+
show: !x,
|
|
1309
|
+
icon: S,
|
|
1310
|
+
iconSize: K
|
|
1311
|
+
}),
|
|
1312
|
+
/* @__PURE__ */ p("input", {
|
|
1313
|
+
disabled: G,
|
|
1314
|
+
readOnly: C,
|
|
1315
|
+
ref: B,
|
|
1316
|
+
onFocus: ne,
|
|
1317
|
+
onBlur: re,
|
|
1318
|
+
onChange: (e) => {
|
|
1319
|
+
e.preventDefault();
|
|
1320
|
+
let [t, n] = ie(e.target.value);
|
|
1321
|
+
v?.(e, String(t), String(n));
|
|
1322
|
+
},
|
|
1323
|
+
id: H,
|
|
1324
|
+
placeholder: G ? R : void 0,
|
|
1325
|
+
value: G ? void 0 : R,
|
|
1326
|
+
...N
|
|
1327
|
+
}),
|
|
1328
|
+
/* @__PURE__ */ p("input", {
|
|
1329
|
+
type: "hidden",
|
|
1330
|
+
name: t,
|
|
1331
|
+
value: Tt(R),
|
|
1332
|
+
readOnly: !0
|
|
1333
|
+
}),
|
|
1334
|
+
/* @__PURE__ */ p(Z, {
|
|
1335
|
+
show: !x,
|
|
1336
|
+
icon: A,
|
|
1337
|
+
iconSize: K
|
|
1338
|
+
}),
|
|
1339
|
+
/* @__PURE__ */ p(Z, {
|
|
1340
|
+
show: J,
|
|
1341
|
+
iconSize: K,
|
|
1342
|
+
className: "spinner",
|
|
1343
|
+
icon: L
|
|
1344
|
+
}),
|
|
1345
|
+
/* @__PURE__ */ p(Z, {
|
|
1346
|
+
iconSize: K,
|
|
1347
|
+
icon: b,
|
|
1348
|
+
className: "suffix"
|
|
1349
|
+
})
|
|
1350
|
+
]
|
|
1351
|
+
})
|
|
1352
|
+
});
|
|
1353
|
+
}
|
|
1354
|
+
//#endregion
|
|
1355
|
+
//#region src/components/datePicker/datePickerCalendarContainer/index.tsx
|
|
1356
|
+
function Ot(e) {
|
|
1357
|
+
let { children: t, isFocused: n } = e, r = l(null), [i, a] = u("bottom");
|
|
1358
|
+
return it(n), o(() => {
|
|
1359
|
+
n && (() => {
|
|
1360
|
+
if (!r.current) return;
|
|
1361
|
+
let e = r.current.parentElement;
|
|
1362
|
+
if (!e) return;
|
|
1363
|
+
let t = e.getBoundingClientRect();
|
|
1364
|
+
window.innerHeight - t.bottom < 420 && t.top > 420 ? a("top") : a("bottom");
|
|
1365
|
+
})();
|
|
1366
|
+
}, [n]), n ? /* @__PURE__ */ p("div", {
|
|
1367
|
+
ref: r,
|
|
1368
|
+
className: `arkynDatePickerCalendarContainer ${i}`,
|
|
1369
|
+
children: t
|
|
1370
|
+
}) : null;
|
|
1371
|
+
}
|
|
1372
|
+
//#endregion
|
|
1373
|
+
//#region src/components/datePicker/datePickerChevron/index.tsx
|
|
1374
|
+
function kt(e) {
|
|
1375
|
+
let { iconSize: t, isLoading: n, disabled: r, readOnly: i, isFocused: a } = e;
|
|
1376
|
+
return n ? null : /* @__PURE__ */ p(C, {
|
|
1377
|
+
className: `arkynDatePickerChevron ${r || i ? "notAnimate" : ""} ${a ? "focused" : ""}`,
|
|
1378
|
+
strokeWidth: 2.5,
|
|
1379
|
+
style: {
|
|
1380
|
+
minWidth: t,
|
|
1381
|
+
minHeight: t,
|
|
1382
|
+
maxWidth: t,
|
|
1383
|
+
maxHeight: t
|
|
1384
|
+
}
|
|
1385
|
+
});
|
|
1386
|
+
}
|
|
1387
|
+
//#endregion
|
|
1388
|
+
//#region src/components/datePicker/datePickerContainer/index.tsx
|
|
1389
|
+
function At(e) {
|
|
1390
|
+
let { children: t, handleContainerFocus: n, disabled: r, isError: i, isLoading: a, isFocused: o, className: s, readOnly: c, variant: l, size: u, id: d, prefixExists: f } = e;
|
|
1391
|
+
return /* @__PURE__ */ p("section", {
|
|
1392
|
+
id: d,
|
|
1393
|
+
className: `arkynDatePickerContainer ${f ? "hasPrefix" : ""} ${l} ${u} ${r || c || a ? "opacity" : ""} ${i ? "errored" : ""} ${o ? "focused" : ""} ${s}`,
|
|
1394
|
+
onClick: n,
|
|
1395
|
+
children: t
|
|
1396
|
+
});
|
|
1397
|
+
}
|
|
1398
|
+
//#endregion
|
|
1399
|
+
//#region src/components/datePicker/datePickerContent/index.tsx
|
|
1400
|
+
function jt(e) {
|
|
1401
|
+
let { children: t, size: n } = e;
|
|
1402
|
+
return /* @__PURE__ */ p("div", {
|
|
1403
|
+
className: `arkynDatePickerContent ${n}`,
|
|
1404
|
+
children: t
|
|
1405
|
+
});
|
|
1406
|
+
}
|
|
1407
|
+
//#endregion
|
|
1408
|
+
//#region src/components/datePicker/datePickerOverlay/index.tsx
|
|
1409
|
+
function Mt(e) {
|
|
1410
|
+
let { isFocused: t, handleBlur: n } = e;
|
|
1411
|
+
return t ? /* @__PURE__ */ p("aside", {
|
|
1412
|
+
className: "arkynDatePickerOverlay",
|
|
1413
|
+
onClick: n
|
|
1414
|
+
}) : null;
|
|
1415
|
+
}
|
|
1416
|
+
//#endregion
|
|
1417
|
+
//#region src/components/datePicker/datePickerSpinner/index.tsx
|
|
1418
|
+
function Nt(e) {
|
|
1419
|
+
let { iconSize: t, isLoading: n } = e;
|
|
1420
|
+
return n ? /* @__PURE__ */ p(L, {
|
|
1421
|
+
className: "arkynDatePickerSpinner",
|
|
1422
|
+
size: t,
|
|
1423
|
+
strokeWidth: 2.5
|
|
1424
|
+
}) : null;
|
|
1425
|
+
}
|
|
1426
|
+
//#endregion
|
|
1427
|
+
//#region src/components/datePicker/index.tsx
|
|
1428
|
+
function Pt(e) {
|
|
1429
|
+
let t = (e) => String(e).padStart(2, "0");
|
|
1430
|
+
return `${e.getFullYear()}-${t(e.getMonth() + 1)}-${t(e.getDate())}`;
|
|
1431
|
+
}
|
|
1432
|
+
function Ft(e) {
|
|
1433
|
+
return e.toLocaleDateString("pt-BR");
|
|
1434
|
+
}
|
|
1435
|
+
function It(e) {
|
|
1436
|
+
let { name: t, className: n = "", placeholder: r = "Selecione uma data...", errorMessage: i, isLoading: a = !1, readOnly: o = !1, id: c, label: d, showAsterisk: f, leftIcon: h, onFocus: g, onBlur: _, disabled: v = !1, prefix: y, size: b = "md", value: x, variant: S = "solid", orientation: C = "vertical", unShowFieldTemplate: w = !1, calendarVariant: T = "complete" } = e, E = e.closeOnSelect ?? e.type === "single", { fieldErrors: D } = X(), O = l(null), k = s(), A = c || k, j = i || D?.[t], M = !!j, N = v || a || o, P = {
|
|
1437
|
+
md: 20,
|
|
1438
|
+
lg: 20
|
|
1439
|
+
}[b], [F, I] = u(!1), [L, R] = u(e.type === "single" ? e.defaultValue : void 0), [z, B] = u(e.type === "range" ? e.defaultValue : void 0);
|
|
1440
|
+
function V() {
|
|
1441
|
+
N || !O?.current || F || (I(!0), O.current.focus(), g?.());
|
|
1442
|
+
}
|
|
1443
|
+
function H() {
|
|
1444
|
+
I(!1), _ && O.current && O.current.blur();
|
|
1445
|
+
}
|
|
1446
|
+
function U(t) {
|
|
1447
|
+
x === void 0 && R(t), e.type === "single" && e.onChange?.(t), E && H();
|
|
1448
|
+
}
|
|
1449
|
+
function W(t) {
|
|
1450
|
+
x === void 0 && B(t), e.type === "range" && e.onChange?.(t), E && H();
|
|
1451
|
+
}
|
|
1452
|
+
if (e.type === "range") {
|
|
1453
|
+
let i = e.rangeSeparator ?? " até ", s = x === void 0 ? z : x, c = s ? JSON.stringify([Pt(s[0]), Pt(s[1])]) : "";
|
|
1454
|
+
return /* @__PURE__ */ p(Q, {
|
|
1455
|
+
name: t,
|
|
1456
|
+
label: d,
|
|
1457
|
+
showAsterisk: f,
|
|
1458
|
+
className: n,
|
|
1459
|
+
errorMessage: j,
|
|
1460
|
+
unShowFieldTemplate: w,
|
|
1461
|
+
orientation: C,
|
|
1462
|
+
children: /* @__PURE__ */ m(At, {
|
|
1463
|
+
handleContainerFocus: V,
|
|
1464
|
+
disabled: N,
|
|
1465
|
+
isError: M,
|
|
1466
|
+
isFocused: F,
|
|
1467
|
+
isLoading: a,
|
|
1468
|
+
readOnly: o,
|
|
1469
|
+
size: b,
|
|
1470
|
+
variant: S,
|
|
1471
|
+
prefixExists: !!y,
|
|
1472
|
+
id: A,
|
|
1473
|
+
children: [
|
|
1474
|
+
/* @__PURE__ */ p("input", {
|
|
1475
|
+
ref: O,
|
|
1476
|
+
name: t,
|
|
1477
|
+
value: c,
|
|
1478
|
+
type: "hidden"
|
|
1479
|
+
}),
|
|
1480
|
+
/* @__PURE__ */ p(Z, {
|
|
1481
|
+
iconSize: P,
|
|
1482
|
+
icon: y,
|
|
1483
|
+
className: "prefix"
|
|
1484
|
+
}),
|
|
1485
|
+
h && /* @__PURE__ */ p(h, {
|
|
1486
|
+
size: P,
|
|
1487
|
+
strokeWidth: 2.5
|
|
1488
|
+
}),
|
|
1489
|
+
/* @__PURE__ */ p(jt, {
|
|
1490
|
+
size: b,
|
|
1491
|
+
children: s ? /* @__PURE__ */ m("p", {
|
|
1492
|
+
className: "hasValue",
|
|
1493
|
+
children: [
|
|
1494
|
+
Ft(s[0]),
|
|
1495
|
+
i,
|
|
1496
|
+
Ft(s[1])
|
|
1497
|
+
]
|
|
1498
|
+
}) : /* @__PURE__ */ p("p", { children: r })
|
|
1499
|
+
}),
|
|
1500
|
+
/* @__PURE__ */ p(Ot, {
|
|
1501
|
+
isFocused: F,
|
|
1502
|
+
children: /* @__PURE__ */ p(ht, {
|
|
1503
|
+
type: "range",
|
|
1504
|
+
variant: T,
|
|
1505
|
+
value: s,
|
|
1506
|
+
onChange: W,
|
|
1507
|
+
viewValue: e.viewValue,
|
|
1508
|
+
defaultViewValue: e.defaultViewValue,
|
|
1509
|
+
onChangeView: e.onChangeView
|
|
1510
|
+
})
|
|
1511
|
+
}),
|
|
1512
|
+
/* @__PURE__ */ p(kt, {
|
|
1513
|
+
disabled: N,
|
|
1514
|
+
isFocused: F,
|
|
1515
|
+
readOnly: o,
|
|
1516
|
+
iconSize: P,
|
|
1517
|
+
isLoading: a
|
|
1518
|
+
}),
|
|
1519
|
+
/* @__PURE__ */ p(Nt, {
|
|
1520
|
+
iconSize: P,
|
|
1521
|
+
isLoading: a
|
|
1522
|
+
}),
|
|
1523
|
+
/* @__PURE__ */ p(Mt, {
|
|
1524
|
+
handleBlur: H,
|
|
1525
|
+
isFocused: F
|
|
1526
|
+
})
|
|
1527
|
+
]
|
|
1528
|
+
})
|
|
1529
|
+
});
|
|
1530
|
+
}
|
|
1531
|
+
let G = x === void 0 ? L : x, K = G ? Pt(G) : "";
|
|
1532
|
+
return /* @__PURE__ */ p(Q, {
|
|
1533
|
+
name: t,
|
|
1534
|
+
label: d,
|
|
1535
|
+
showAsterisk: f,
|
|
1536
|
+
className: n,
|
|
1537
|
+
errorMessage: j,
|
|
1538
|
+
unShowFieldTemplate: w,
|
|
1539
|
+
orientation: C,
|
|
1540
|
+
children: /* @__PURE__ */ m(At, {
|
|
1541
|
+
handleContainerFocus: V,
|
|
1542
|
+
disabled: N,
|
|
1543
|
+
isError: M,
|
|
1544
|
+
isFocused: F,
|
|
1545
|
+
isLoading: a,
|
|
1546
|
+
readOnly: o,
|
|
1547
|
+
size: b,
|
|
1548
|
+
variant: S,
|
|
1549
|
+
prefixExists: !!y,
|
|
1550
|
+
id: A,
|
|
1551
|
+
children: [
|
|
1552
|
+
/* @__PURE__ */ p("input", {
|
|
1553
|
+
ref: O,
|
|
1554
|
+
name: t,
|
|
1555
|
+
value: K,
|
|
1556
|
+
type: "hidden"
|
|
1557
|
+
}),
|
|
1558
|
+
/* @__PURE__ */ p(Z, {
|
|
1559
|
+
iconSize: P,
|
|
1560
|
+
icon: y,
|
|
1561
|
+
className: "prefix"
|
|
1562
|
+
}),
|
|
1563
|
+
h && /* @__PURE__ */ p(h, {
|
|
1564
|
+
size: P,
|
|
1565
|
+
strokeWidth: 2.5
|
|
1566
|
+
}),
|
|
1567
|
+
/* @__PURE__ */ p(jt, {
|
|
1568
|
+
size: b,
|
|
1569
|
+
children: G ? /* @__PURE__ */ p("p", {
|
|
1570
|
+
className: "hasValue",
|
|
1571
|
+
children: Ft(G)
|
|
1572
|
+
}) : /* @__PURE__ */ p("p", { children: r })
|
|
1573
|
+
}),
|
|
1574
|
+
/* @__PURE__ */ p(Ot, {
|
|
1575
|
+
isFocused: F,
|
|
1576
|
+
children: /* @__PURE__ */ p(ht, {
|
|
1577
|
+
type: "single",
|
|
1578
|
+
variant: T,
|
|
1579
|
+
value: G,
|
|
1580
|
+
onChange: U,
|
|
1581
|
+
viewValue: e.viewValue,
|
|
1582
|
+
defaultViewValue: e.defaultViewValue,
|
|
1583
|
+
onChangeView: e.onChangeView
|
|
1584
|
+
})
|
|
1585
|
+
}),
|
|
1586
|
+
/* @__PURE__ */ p(kt, {
|
|
1587
|
+
disabled: N,
|
|
1588
|
+
isFocused: F,
|
|
1589
|
+
readOnly: o,
|
|
1590
|
+
iconSize: P,
|
|
1591
|
+
isLoading: a
|
|
1592
|
+
}),
|
|
1593
|
+
/* @__PURE__ */ p(Nt, {
|
|
1594
|
+
iconSize: P,
|
|
1595
|
+
isLoading: a
|
|
1596
|
+
}),
|
|
1597
|
+
/* @__PURE__ */ p(Mt, {
|
|
1598
|
+
handleBlur: H,
|
|
1599
|
+
isFocused: F
|
|
1600
|
+
})
|
|
1601
|
+
]
|
|
1602
|
+
})
|
|
1603
|
+
});
|
|
1604
|
+
}
|
|
1605
|
+
//#endregion
|
|
1606
|
+
//#region src/components/drawer/drawerContext.tsx
|
|
1607
|
+
var Lt = n({});
|
|
1608
|
+
function Rt(e) {
|
|
1609
|
+
let t = c(() => ({ makeInvisible: e.makeInvisible }), [e.makeInvisible]);
|
|
1610
|
+
return /* @__PURE__ */ p(Lt.Provider, {
|
|
1611
|
+
value: t,
|
|
1612
|
+
children: e.children
|
|
1613
|
+
});
|
|
1614
|
+
}
|
|
1615
|
+
function zt() {
|
|
1616
|
+
return a(Lt);
|
|
1617
|
+
}
|
|
1618
|
+
//#endregion
|
|
1619
|
+
//#region src/components/drawer/drawerContainer/index.tsx
|
|
1620
|
+
function Bt(e) {
|
|
1621
|
+
let { isVisible: t, makeInvisible: n, orientation: r = "left", children: i, className: a, ...s } = e, [c, l] = u(t), [d, f] = u(!1);
|
|
1622
|
+
o(() => {
|
|
1623
|
+
t ? (l(!0), f(!1)) : c && f(!0);
|
|
1624
|
+
}, [t, c]), it(t);
|
|
1625
|
+
function h(e) {
|
|
1626
|
+
e.target === e.currentTarget && d && (f(!1), l(!1), n());
|
|
1627
|
+
}
|
|
1628
|
+
return c ? /* @__PURE__ */ p(Rt, {
|
|
1629
|
+
makeInvisible: () => f(!0),
|
|
1630
|
+
children: /* @__PURE__ */ m("aside", {
|
|
1631
|
+
className: [
|
|
1632
|
+
"arkynDrawerContainer",
|
|
1633
|
+
r,
|
|
1634
|
+
d ? "exiting" : "",
|
|
1635
|
+
a
|
|
1636
|
+
].filter(Boolean).join(" "),
|
|
1637
|
+
...s,
|
|
1638
|
+
children: [/* @__PURE__ */ p("div", {
|
|
1639
|
+
className: "arkynDrawerContainerOverlay",
|
|
1640
|
+
onClick: () => f(!0),
|
|
1641
|
+
onAnimationEnd: h
|
|
1642
|
+
}), /* @__PURE__ */ p("div", {
|
|
1643
|
+
className: "arkynDrawerContainerContent",
|
|
1644
|
+
children: i
|
|
1645
|
+
})]
|
|
1646
|
+
})
|
|
1647
|
+
}) : null;
|
|
1648
|
+
}
|
|
1649
|
+
//#endregion
|
|
1650
|
+
//#region src/components/drawer/drawerHeader/index.tsx
|
|
1651
|
+
function Vt(e) {
|
|
1652
|
+
let { showCloseButton: t = !0, className: n, children: r, ...i } = e, { makeInvisible: a } = zt();
|
|
1653
|
+
return /* @__PURE__ */ m("header", {
|
|
1654
|
+
className: `arkynDrawerHeader ${n}`.trim(),
|
|
1655
|
+
...i,
|
|
1656
|
+
children: [r, t && /* @__PURE__ */ p("button", {
|
|
1657
|
+
className: "arkynDrawerHeaderCloseButton",
|
|
1658
|
+
type: "button",
|
|
1659
|
+
onClick: a,
|
|
1660
|
+
"aria-label": "Close drawer",
|
|
1661
|
+
children: /* @__PURE__ */ p(K, { size: 24 })
|
|
1662
|
+
})]
|
|
1663
|
+
});
|
|
1664
|
+
}
|
|
1665
|
+
//#endregion
|
|
1666
|
+
//#region src/components/facebookPixel/pixel.ts
|
|
1667
|
+
var Ht = class {
|
|
1668
|
+
pixelId;
|
|
1669
|
+
autoConfig;
|
|
1670
|
+
initialized;
|
|
1671
|
+
constructor(e, t) {
|
|
1672
|
+
this.pixelId = e, this.autoConfig = t?.autoConfig || !0, this.initialized = !1;
|
|
1673
|
+
}
|
|
1674
|
+
loadFacebookPixel() {
|
|
1675
|
+
if (window.fbq) return;
|
|
1676
|
+
let e = ((...t) => {
|
|
1677
|
+
e.callMethod ? e.callMethod.apply(e, t) : e.queue.push(t);
|
|
1678
|
+
});
|
|
1679
|
+
window._fbq || (window._fbq = e), e.push = e, e.loaded = !0, e.version = "2.0", e.queue = [];
|
|
1680
|
+
let t = document.createElement("script");
|
|
1681
|
+
t.async = !0, t.src = "https://connect.facebook.net/en_US/fbevents.js";
|
|
1682
|
+
let n = document.getElementsByTagName("script")[0];
|
|
1683
|
+
if (!n.parentNode) throw Error("No script tag found in the document");
|
|
1684
|
+
n.parentNode.insertBefore(t, n), window.fbq = e;
|
|
1685
|
+
}
|
|
1686
|
+
init(e = {}) {
|
|
1687
|
+
if (this.initialized = typeof window < "u" && !!window.fbq, this.loadFacebookPixel(), !window.fbq) throw Error("window.fbq is not defined");
|
|
1688
|
+
this.autoConfig === !1 ? window.fbq("set", "autoConfig", !1, this.pixelId) : window.fbq("init", this.pixelId, e), this.initialized = !0;
|
|
1689
|
+
}
|
|
1690
|
+
pageView() {
|
|
1691
|
+
this.initialized && window.fbq && window.fbq("track", "PageView");
|
|
1692
|
+
}
|
|
1693
|
+
track(e, t) {
|
|
1694
|
+
this.initialized && window.fbq && window.fbq("track", e, t);
|
|
1695
|
+
}
|
|
1696
|
+
trackSingle(e, t, n) {
|
|
1697
|
+
this.initialized && window.fbq && window.fbq("trackSingle", e, t, n);
|
|
1698
|
+
}
|
|
1699
|
+
trackCustom(e, t) {
|
|
1700
|
+
this.initialized && window.fbq && window.fbq("trackCustom", e, t);
|
|
1701
|
+
}
|
|
1702
|
+
trackSingleCustom(e, t, n) {
|
|
1703
|
+
this.initialized && window.fbq && window.fbq("trackSingle", e, t, n);
|
|
1704
|
+
}
|
|
1705
|
+
grantConsent() {
|
|
1706
|
+
this.initialized && window.fbq && window.fbq("consent", "grant");
|
|
1707
|
+
}
|
|
1708
|
+
revokeConsent() {
|
|
1709
|
+
this.initialized && window.fbq && window.fbq("consent", "revoke");
|
|
1710
|
+
}
|
|
1711
|
+
};
|
|
1712
|
+
//#endregion
|
|
1713
|
+
//#region src/components/facebookPixel/facebookPixel.client.tsx
|
|
1714
|
+
function Ut(e) {
|
|
1715
|
+
let { pixelId: t, options: n, pageView: r, track: i, trackCustom: a, trackSingle: o, trackSingleCustom: s, grantConsent: c, revokeConsent: l } = e, u = new Ht(t, n);
|
|
1716
|
+
return u.init(), r && u.pageView(), c && u.grantConsent(), l && u.revokeConsent(), i && u.track(...i), a && u.trackCustom(...a), o && u.trackSingle(t, ...o), s && u.trackSingleCustom(t, ...s), null;
|
|
1717
|
+
}
|
|
1718
|
+
//#endregion
|
|
1719
|
+
//#region src/components/facebookPixel/index.tsx
|
|
1720
|
+
function Wt(e) {
|
|
1721
|
+
return process.env.NODE_ENV !== "production" && !e.showInDevMode ? null : /* @__PURE__ */ p(wt, { children: () => /* @__PURE__ */ p(Ut, { ...e }) });
|
|
1722
|
+
}
|
|
1723
|
+
//#endregion
|
|
1724
|
+
//#region src/components/fileUpload/hasFileContent/index.tsx
|
|
1725
|
+
function Gt(e) {
|
|
1726
|
+
let { disabled: t, file: n, isLoading: r, acceptFile: i, changeFileButtonText: a, handleSelectFile: o, reSendFile: s } = e;
|
|
1727
|
+
function c() {
|
|
1728
|
+
if (t) return;
|
|
1729
|
+
let e = document.createElement("input");
|
|
1730
|
+
e.type = "file", e.accept = i, e.onchange = (e) => {
|
|
1731
|
+
let t = e.target.files?.[0];
|
|
1732
|
+
t && o(t);
|
|
1733
|
+
}, e.click();
|
|
1734
|
+
}
|
|
1735
|
+
function l() {
|
|
1736
|
+
return n.type.startsWith("image/") ? /* @__PURE__ */ p(j, {}) : n.type.startsWith("audio/") ? /* @__PURE__ */ p(A, {}) : n.type.startsWith("application/zip") ? /* @__PURE__ */ p(k, {}) : /* @__PURE__ */ p(O, {});
|
|
1737
|
+
}
|
|
1738
|
+
return /* @__PURE__ */ m("div", {
|
|
1739
|
+
className: "arkynFileUploadHasFileContent",
|
|
1740
|
+
children: [
|
|
1741
|
+
/* @__PURE__ */ m("section", {
|
|
1742
|
+
className: "arkynFileUploadFileContainer",
|
|
1743
|
+
children: [/* @__PURE__ */ p(l, {}), /* @__PURE__ */ p("p", { children: n.name })]
|
|
1744
|
+
}),
|
|
1745
|
+
/* @__PURE__ */ p(Ve, {}),
|
|
1746
|
+
/* @__PURE__ */ m("div", {
|
|
1747
|
+
className: "arkynFileUploadButtonsContainer",
|
|
1748
|
+
children: [!!s && /* @__PURE__ */ p(Ue, {
|
|
1749
|
+
orientation: "bottom",
|
|
1750
|
+
text: "Reenviar arquivo",
|
|
1751
|
+
children: /* @__PURE__ */ p(He, {
|
|
1752
|
+
type: "button",
|
|
1753
|
+
"aria-label": "resend file",
|
|
1754
|
+
variant: "outline",
|
|
1755
|
+
scheme: "danger",
|
|
1756
|
+
size: "sm",
|
|
1757
|
+
isLoading: r,
|
|
1758
|
+
onClick: s,
|
|
1759
|
+
icon: H,
|
|
1760
|
+
disabled: t
|
|
1761
|
+
})
|
|
1762
|
+
}), /* @__PURE__ */ p(Be, {
|
|
1763
|
+
isLoading: r,
|
|
1764
|
+
onClick: c,
|
|
1765
|
+
variant: "outline",
|
|
1766
|
+
size: "sm",
|
|
1767
|
+
type: "button",
|
|
1768
|
+
disabled: t,
|
|
1769
|
+
children: a
|
|
1770
|
+
})]
|
|
1771
|
+
})
|
|
1772
|
+
]
|
|
1773
|
+
});
|
|
1774
|
+
}
|
|
1775
|
+
//#endregion
|
|
1776
|
+
//#region src/components/fileUpload/noFileContent/index.tsx
|
|
1777
|
+
function Kt(e) {
|
|
1778
|
+
let { dropFileText: t, isLoading: n, acceptFile: r, handleSelectFile: i, selectFileButtonText: a, disabled: o } = e;
|
|
1779
|
+
function s(e) {
|
|
1780
|
+
if (o) return;
|
|
1781
|
+
e.preventDefault();
|
|
1782
|
+
let t = e.dataTransfer.files[0];
|
|
1783
|
+
t && i(t);
|
|
1784
|
+
}
|
|
1785
|
+
function c() {
|
|
1786
|
+
if (o) return;
|
|
1787
|
+
let e = document.createElement("input");
|
|
1788
|
+
e.type = "file", e.accept = r, e.onchange = (e) => {
|
|
1789
|
+
let t = e.target.files?.[0];
|
|
1790
|
+
t && i(t);
|
|
1791
|
+
}, e.click();
|
|
1792
|
+
}
|
|
1793
|
+
return /* @__PURE__ */ m("div", {
|
|
1794
|
+
onDrop: s,
|
|
1795
|
+
className: "arkynFileUploadNoFileContent",
|
|
1796
|
+
children: [/* @__PURE__ */ p(Be, {
|
|
1797
|
+
isLoading: n,
|
|
1798
|
+
onClick: c,
|
|
1799
|
+
variant: "ghost",
|
|
1800
|
+
size: "sm",
|
|
1801
|
+
type: "button",
|
|
1802
|
+
disabled: o,
|
|
1803
|
+
children: a
|
|
1804
|
+
}), /* @__PURE__ */ p("p", { children: t })]
|
|
1805
|
+
});
|
|
1806
|
+
}
|
|
1807
|
+
//#endregion
|
|
1808
|
+
//#region src/components/fileUpload/index.tsx
|
|
1809
|
+
function qt(e) {
|
|
1810
|
+
let { name: t, label: n, showAsterisk: r = !1, action: i, fileName: a = "file", method: o = "POST", acceptFile: s = "*", fileResponseName: c = "url", changeFileButtonText: l = "Alterar arquivo", selectFileButtonText: d = "Selecionar arquivo", dropFileText: f = "Ou arraste e solte o arquivo aqui", onChange: h, disabled: g = !1 } = e, { fieldErrors: _ } = X(), v = _?.[t], [y, b] = u(""), [x, S] = u(""), [C, w] = u(null), [T, E] = u(!1);
|
|
1811
|
+
async function D(e) {
|
|
1812
|
+
if (g) return;
|
|
1813
|
+
E(!0), w(e), S("");
|
|
1814
|
+
let t = new FormData();
|
|
1815
|
+
t.append(a, e), await fetch(i, {
|
|
1816
|
+
method: o,
|
|
1817
|
+
body: t
|
|
1818
|
+
}).then(async (e) => await e.json()).then((e) => {
|
|
1819
|
+
e?.error ? S(e.error) : b(e?.[c]), h?.(e?.[c]);
|
|
1820
|
+
}).catch((e) => {
|
|
1821
|
+
console.error(e), S("Erro ao enviar o arquivo");
|
|
1822
|
+
}).finally(() => E(!1));
|
|
1823
|
+
}
|
|
1824
|
+
function O(e) {
|
|
1825
|
+
g || D(e);
|
|
1826
|
+
}
|
|
1827
|
+
let k = v || x;
|
|
1828
|
+
return /* @__PURE__ */ m(ze, { children: [
|
|
1829
|
+
n && /* @__PURE__ */ p(Re, {
|
|
1830
|
+
showAsterisk: r,
|
|
1831
|
+
children: n
|
|
1832
|
+
}),
|
|
1833
|
+
/* @__PURE__ */ m("div", {
|
|
1834
|
+
className: `arkynFileUpload ${k ? "hasError" : "noHasError"} ${C ? "hasFile" : "noHasFile"}`,
|
|
1835
|
+
children: [
|
|
1836
|
+
/* @__PURE__ */ p("input", {
|
|
1837
|
+
type: "hidden",
|
|
1838
|
+
name: t,
|
|
1839
|
+
value: y || ""
|
|
1840
|
+
}),
|
|
1841
|
+
!C && /* @__PURE__ */ p(Kt, {
|
|
1842
|
+
disabled: g,
|
|
1843
|
+
isLoading: T,
|
|
1844
|
+
acceptFile: s,
|
|
1845
|
+
dropFileText: f,
|
|
1846
|
+
handleSelectFile: O,
|
|
1847
|
+
selectFileButtonText: d
|
|
1848
|
+
}),
|
|
1849
|
+
C && /* @__PURE__ */ p(Gt, {
|
|
1850
|
+
disabled: g,
|
|
1851
|
+
isLoading: T,
|
|
1852
|
+
acceptFile: s,
|
|
1853
|
+
file: C,
|
|
1854
|
+
handleSelectFile: O,
|
|
1855
|
+
changeFileButtonText: l,
|
|
1856
|
+
reSendFile: k && C ? () => D(C) : void 0
|
|
1857
|
+
})
|
|
1858
|
+
]
|
|
1859
|
+
}),
|
|
1860
|
+
k && /* @__PURE__ */ p(Le, { children: k })
|
|
1861
|
+
] });
|
|
1862
|
+
}
|
|
1863
|
+
//#endregion
|
|
1864
|
+
//#region src/components/fullCalendar/_viewService.ts
|
|
1865
|
+
var Jt = class {
|
|
1866
|
+
capitalize(e) {
|
|
1867
|
+
return J(e);
|
|
1868
|
+
}
|
|
1869
|
+
listHours(e) {
|
|
1870
|
+
let [t, n] = e, r = [];
|
|
1871
|
+
for (let e = t * 60; e <= n * 60; e += 30) r.push(e);
|
|
1872
|
+
return r;
|
|
1873
|
+
}
|
|
1874
|
+
formatHourLabel(e) {
|
|
1875
|
+
let t = Math.floor(e / 60), n = e % 60;
|
|
1876
|
+
return `${String(t).padStart(2, "0")}:${String(n).padStart(2, "0")}`;
|
|
1877
|
+
}
|
|
1878
|
+
getStartOfWeek(e) {
|
|
1879
|
+
let t = new Date(e);
|
|
1880
|
+
return t.setHours(0, 0, 0, 0), t.setDate(t.getDate() - t.getDay()), t;
|
|
1881
|
+
}
|
|
1882
|
+
listWeek(e, t) {
|
|
1883
|
+
let n = [], r = this.getStartOfWeek(e);
|
|
1884
|
+
for (let e = 0; e < 7; e++) {
|
|
1885
|
+
let i = new Date(r);
|
|
1886
|
+
i.setDate(r.getDate() + e);
|
|
1887
|
+
let a = i.toLocaleDateString(t, { weekday: "short" });
|
|
1888
|
+
n.push(a);
|
|
1889
|
+
}
|
|
1890
|
+
return n;
|
|
1891
|
+
}
|
|
1892
|
+
listWeeklyMatrix(e, t) {
|
|
1893
|
+
let n = this.getStartOfWeek(e), r = e.getMonth();
|
|
1894
|
+
return t.map((t) => Array.from({ length: 7 }, (i, a) => {
|
|
1895
|
+
let o = new Date(n);
|
|
1896
|
+
o.setDate(n.getDate() + a);
|
|
1897
|
+
let s = "current";
|
|
1898
|
+
return (o.getMonth() < r || o.getFullYear() < e.getFullYear()) && (s = "previous"), (o.getMonth() > r || o.getFullYear() > e.getFullYear()) && (s = "next"), {
|
|
1899
|
+
day: o.getDate(),
|
|
1900
|
+
month: o.getMonth(),
|
|
1901
|
+
year: o.getFullYear(),
|
|
1902
|
+
dayOwner: s,
|
|
1903
|
+
timeInMinutes: t
|
|
1904
|
+
};
|
|
1905
|
+
}));
|
|
1906
|
+
}
|
|
1907
|
+
listMonthlyMatrix(e) {
|
|
1908
|
+
let t = e.getFullYear(), n = e.getMonth(), r = new Date(t, n, 1).getDay(), i = new Date(t, n + 1, 0).getDate(), a = new Date(t, n, 0).getDate(), o = Math.ceil((r + i) / 7) * 7, s = [], c = 1, l = 1;
|
|
1909
|
+
for (let e = 0; e < o; e++) {
|
|
1910
|
+
let o = Math.floor(e / 7);
|
|
1911
|
+
if (s[o] || (s[o] = []), e < r) {
|
|
1912
|
+
let i = a - (r - e - 1), c = n === 0 ? 11 : n - 1, l = n === 0 ? t - 1 : t;
|
|
1913
|
+
s[o].push({
|
|
1914
|
+
day: i,
|
|
1915
|
+
month: c,
|
|
1916
|
+
year: l,
|
|
1917
|
+
dayOwner: "previous"
|
|
1918
|
+
});
|
|
1919
|
+
} else if (c <= i) s[o].push({
|
|
1920
|
+
day: c,
|
|
1921
|
+
month: n,
|
|
1922
|
+
year: t,
|
|
1923
|
+
dayOwner: "current"
|
|
1924
|
+
}), c++;
|
|
1925
|
+
else {
|
|
1926
|
+
let e = n === 11 ? 0 : n + 1, r = n === 11 ? t + 1 : t;
|
|
1927
|
+
s[o].push({
|
|
1928
|
+
day: l,
|
|
1929
|
+
month: e,
|
|
1930
|
+
year: r,
|
|
1931
|
+
dayOwner: "next"
|
|
1932
|
+
}), l++;
|
|
1933
|
+
}
|
|
1934
|
+
}
|
|
1935
|
+
return s;
|
|
1936
|
+
}
|
|
1937
|
+
nextMonth(e, t) {
|
|
1938
|
+
let n = new Date(e);
|
|
1939
|
+
n.setMonth(n.getMonth() + 1), t(n);
|
|
1940
|
+
}
|
|
1941
|
+
nextWeek(e, t) {
|
|
1942
|
+
let n = new Date(e);
|
|
1943
|
+
n.setDate(n.getDate() + 7), t(n);
|
|
1944
|
+
}
|
|
1945
|
+
nextDay(e, t) {
|
|
1946
|
+
let n = new Date(e);
|
|
1947
|
+
n.setDate(n.getDate() + 1), t(n);
|
|
1948
|
+
}
|
|
1949
|
+
previousMonth(e, t) {
|
|
1950
|
+
let n = new Date(e);
|
|
1951
|
+
n.setMonth(n.getMonth() - 1), t(n);
|
|
1952
|
+
}
|
|
1953
|
+
previousWeek(e, t) {
|
|
1954
|
+
let n = new Date(e);
|
|
1955
|
+
n.setDate(n.getDate() - 7), t(n);
|
|
1956
|
+
}
|
|
1957
|
+
previousDay(e, t) {
|
|
1958
|
+
let n = new Date(e);
|
|
1959
|
+
n.setDate(n.getDate() - 1), t(n);
|
|
1960
|
+
}
|
|
1961
|
+
}, Yt = n({});
|
|
1962
|
+
function $() {
|
|
1963
|
+
return a(Yt);
|
|
1964
|
+
}
|
|
1965
|
+
function Xt(e) {
|
|
1966
|
+
let { blockedTimestamps: t, children: n, events: r, defaultViewValue: i = /* @__PURE__ */ new Date(), language: a = "pt-BR", onChangeView: o, onClickDate: s, viewValue: c } = e, l = new Jt(), d = l.listHours([8, 18]), [f, m] = u(i), h = c || f;
|
|
1967
|
+
function g(e) {
|
|
1968
|
+
o && o(e), m(e);
|
|
1969
|
+
}
|
|
1970
|
+
return /* @__PURE__ */ p(Yt.Provider, {
|
|
1971
|
+
value: {
|
|
1972
|
+
events: r,
|
|
1973
|
+
blockedTimestamps: t,
|
|
1974
|
+
viewDate: h,
|
|
1975
|
+
listHours: d,
|
|
1976
|
+
listWeek: l.listWeek(h, a),
|
|
1977
|
+
listMonthlyMatrix: l.listMonthlyMatrix(h),
|
|
1978
|
+
listWeeklyMatrix: l.listWeeklyMatrix(h, d),
|
|
1979
|
+
nextMonth: () => l.nextMonth(h, g),
|
|
1980
|
+
nextWeek: () => l.nextWeek(h, g),
|
|
1981
|
+
nextDay: () => l.nextDay(h, g),
|
|
1982
|
+
previousMonth: () => l.previousMonth(h, g),
|
|
1983
|
+
previousWeek: () => l.previousWeek(h, g),
|
|
1984
|
+
previousDay: () => l.previousDay(h, g),
|
|
1985
|
+
onClickDate: s
|
|
1986
|
+
},
|
|
1987
|
+
children: n
|
|
1988
|
+
});
|
|
1989
|
+
}
|
|
1990
|
+
//#endregion
|
|
1991
|
+
//#region src/components/fullCalendar/dayCalendar/dayCalendarContainer/index.tsx
|
|
1992
|
+
function Zt({ children: e }) {
|
|
1993
|
+
return /* @__PURE__ */ p("div", {
|
|
1994
|
+
className: "arkynDayCalendarContainer",
|
|
1995
|
+
children: e
|
|
1996
|
+
});
|
|
1997
|
+
}
|
|
1998
|
+
//#endregion
|
|
1999
|
+
//#region src/components/fullCalendar/dayCalendar/dayCalendarEvent/index.tsx
|
|
2000
|
+
var Qt = 30, $t = 205;
|
|
2001
|
+
function en(e) {
|
|
2002
|
+
let { events: t, viewDate: n } = $(), r = n.getDate(), i = n.getMonth(), a = n.getFullYear(), o = t.map((e, t) => ({
|
|
2003
|
+
event: e,
|
|
2004
|
+
sourceIndex: t
|
|
2005
|
+
})).filter(({ event: e }) => e.initialDate.getDate() === r && e.initialDate.getMonth() === i && e.initialDate.getFullYear() === a).sort((e, t) => {
|
|
2006
|
+
let n = e.event.initialDate.getTime(), r = t.event.initialDate.getTime();
|
|
2007
|
+
if (n !== r) return n - r;
|
|
2008
|
+
let i = e.event.endDate?.getTime() ?? n + Qt * 6e4, a = t.event.endDate?.getTime() ?? r + Qt * 6e4;
|
|
2009
|
+
return i === a ? e.sourceIndex - t.sourceIndex : i - a;
|
|
2010
|
+
}), s = new Map(o.map((e, t) => [e.sourceIndex, t])), c = o.filter(({ event: t }) => {
|
|
2011
|
+
let n = Math.floor(e.timeInMinutes / 60), o = e.timeInMinutes % 60;
|
|
2012
|
+
function s() {
|
|
2013
|
+
let e = t.initialDate.getHours(), r = t.initialDate.getMinutes();
|
|
2014
|
+
if (e !== n) return !1;
|
|
2015
|
+
if (o === 0) return r < 30 && r >= 0;
|
|
2016
|
+
if (o === 30) return r >= 30 && r < 60;
|
|
2017
|
+
}
|
|
2018
|
+
return s() && t.initialDate.getDate() === r && t.initialDate.getMonth() === i && t.initialDate.getFullYear() === a;
|
|
2019
|
+
});
|
|
2020
|
+
if (c.length === 0) return null;
|
|
2021
|
+
function l(e, t) {
|
|
2022
|
+
return `${r}-${i}-${a}-${t}-${e}`;
|
|
2023
|
+
}
|
|
2024
|
+
function u(e) {
|
|
2025
|
+
let t = e.getHours(), n = e.getMinutes();
|
|
2026
|
+
return n === 0 ? `${t}h` : `${t}h${n}`;
|
|
2027
|
+
}
|
|
2028
|
+
function d(e) {
|
|
2029
|
+
let t = e.initialDate.getHours() * 60 + e.initialDate.getMinutes(), n = e.endDate ? e.endDate.getHours() * 60 + e.endDate.getMinutes() : t + Qt;
|
|
2030
|
+
return {
|
|
2031
|
+
startMinutes: t,
|
|
2032
|
+
endMinutes: Math.max(n, t + 1)
|
|
2033
|
+
};
|
|
2034
|
+
}
|
|
2035
|
+
function f(e, t) {
|
|
2036
|
+
let n = d(e), r = s.get(t);
|
|
2037
|
+
return r == null ? 0 : o.reduce((e, t, i) => {
|
|
2038
|
+
if (i >= r) return e;
|
|
2039
|
+
let a = d(t.event);
|
|
2040
|
+
return a.startMinutes < n.endMinutes && a.endMinutes > n.startMinutes ? e + 1 : e;
|
|
2041
|
+
}, 0);
|
|
2042
|
+
}
|
|
2043
|
+
function h(t, n) {
|
|
2044
|
+
let { startMinutes: r, endMinutes: i } = d(t), a = r - e.timeInMinutes, o = Math.max(i - r, 1), s = a / Qt * 100, c = o / Qt * 100, l = f(t, n) * $t;
|
|
2045
|
+
return {
|
|
2046
|
+
top: `${s}%`,
|
|
2047
|
+
height: `${c}%`,
|
|
2048
|
+
left: `${l}px`
|
|
2049
|
+
};
|
|
2050
|
+
}
|
|
2051
|
+
function g(e, t) {
|
|
2052
|
+
e.stopPropagation(), t.onClick?.(t.data);
|
|
2053
|
+
}
|
|
2054
|
+
return c.map(({ event: e, sourceIndex: t }, n) => /* @__PURE__ */ m("div", {
|
|
2055
|
+
className: `arkynDayCalendarEvent ${e?.scheme || "primary"}`,
|
|
2056
|
+
style: h(e, t),
|
|
2057
|
+
onClick: (t) => g(t, e),
|
|
2058
|
+
children: [/* @__PURE__ */ m("strong", { children: [
|
|
2059
|
+
u(e.initialDate),
|
|
2060
|
+
" ",
|
|
2061
|
+
e?.endDate && `- ${u(e.endDate)}`
|
|
2062
|
+
] }), /* @__PURE__ */ p("p", { children: e.title })]
|
|
2063
|
+
}, l(n, t)));
|
|
2064
|
+
}
|
|
2065
|
+
//#endregion
|
|
2066
|
+
//#region src/components/fullCalendar/dayCalendar/dayCalendarRow/index.tsx
|
|
2067
|
+
function tn({ hour: e, timeInMinutes: t }) {
|
|
2068
|
+
let n = new Jt(), { blockedTimestamps: r, viewDate: i, onClickDate: a } = $();
|
|
2069
|
+
function o() {
|
|
2070
|
+
return r.some((e) => i >= e.initialDate && i <= e.endDate);
|
|
2071
|
+
}
|
|
2072
|
+
function s(e) {
|
|
2073
|
+
if (e.stopPropagation(), !o() && a) {
|
|
2074
|
+
let e = new Date(i);
|
|
2075
|
+
e.setHours(0, t, 0, 0), a(e);
|
|
2076
|
+
}
|
|
2077
|
+
}
|
|
2078
|
+
return /* @__PURE__ */ m("div", {
|
|
2079
|
+
className: `arkynDayCalendarRow ${o() ? "blocked" : ""}`,
|
|
2080
|
+
"data-time": t,
|
|
2081
|
+
onClick: s,
|
|
2082
|
+
children: [/* @__PURE__ */ p("p", { children: n.formatHourLabel(e) }), /* @__PURE__ */ p("div", {
|
|
2083
|
+
className: "arkynDayCalendarRowContent",
|
|
2084
|
+
children: /* @__PURE__ */ p(en, { timeInMinutes: t })
|
|
2085
|
+
})]
|
|
2086
|
+
});
|
|
2087
|
+
}
|
|
2088
|
+
//#endregion
|
|
2089
|
+
//#region src/components/fullCalendar/dayCalendar/index.tsx
|
|
2090
|
+
function nn() {
|
|
2091
|
+
let { listHours: e } = $();
|
|
2092
|
+
return /* @__PURE__ */ p(Zt, { children: e.map((e) => /* @__PURE__ */ p(tn, {
|
|
2093
|
+
hour: e,
|
|
2094
|
+
timeInMinutes: e
|
|
2095
|
+
}, e)) });
|
|
2096
|
+
}
|
|
2097
|
+
//#endregion
|
|
2098
|
+
//#region src/components/fullCalendar/fullCalendarContainer/index.tsx
|
|
2099
|
+
function rn({ children: e }) {
|
|
2100
|
+
return /* @__PURE__ */ p("div", {
|
|
2101
|
+
className: "arkynFullCalendarContainer",
|
|
2102
|
+
children: e
|
|
2103
|
+
});
|
|
2104
|
+
}
|
|
2105
|
+
//#endregion
|
|
2106
|
+
//#region src/components/fullCalendar/fullCalendarHeader/index.tsx
|
|
2107
|
+
function an(e) {
|
|
2108
|
+
let { setViewType: t, viewType: n } = e, r = $();
|
|
2109
|
+
function i() {
|
|
2110
|
+
switch (n) {
|
|
2111
|
+
case "day": return r.previousDay();
|
|
2112
|
+
case "week": return r.previousWeek();
|
|
2113
|
+
case "month": return r.previousMonth();
|
|
2114
|
+
}
|
|
2115
|
+
}
|
|
2116
|
+
function a() {
|
|
2117
|
+
switch (n) {
|
|
2118
|
+
case "day": return r.nextDay();
|
|
2119
|
+
case "week": return r.nextWeek();
|
|
2120
|
+
case "month": return r.nextMonth();
|
|
2121
|
+
}
|
|
2122
|
+
}
|
|
2123
|
+
return /* @__PURE__ */ m("div", {
|
|
2124
|
+
className: "arkynFullCalendarHeader",
|
|
2125
|
+
children: [/* @__PURE__ */ m(bt, {
|
|
2126
|
+
defaultValue: n,
|
|
2127
|
+
onChange: (e) => t(e),
|
|
2128
|
+
children: [
|
|
2129
|
+
/* @__PURE__ */ p(yt, {
|
|
2130
|
+
value: "day",
|
|
2131
|
+
children: "Dia"
|
|
2132
|
+
}),
|
|
2133
|
+
/* @__PURE__ */ p(yt, {
|
|
2134
|
+
value: "week",
|
|
2135
|
+
children: "Semana"
|
|
2136
|
+
}),
|
|
2137
|
+
/* @__PURE__ */ p(yt, {
|
|
2138
|
+
value: "month",
|
|
2139
|
+
children: "Mês"
|
|
2140
|
+
})
|
|
2141
|
+
]
|
|
2142
|
+
}), /* @__PURE__ */ m("div", {
|
|
2143
|
+
className: "arkynFullCalendarHeaderActions",
|
|
2144
|
+
children: [
|
|
2145
|
+
/* @__PURE__ */ p(He, {
|
|
2146
|
+
variant: "outline",
|
|
2147
|
+
icon: w,
|
|
2148
|
+
"aria-label": "Handle previous",
|
|
2149
|
+
onClick: () => i()
|
|
2150
|
+
}),
|
|
2151
|
+
/* @__PURE__ */ p("p", { children: r.viewDate.toLocaleDateString("pt-BR", {
|
|
2152
|
+
day: "2-digit",
|
|
2153
|
+
month: "long",
|
|
2154
|
+
year: "numeric"
|
|
2155
|
+
}) }),
|
|
2156
|
+
/* @__PURE__ */ p(He, {
|
|
2157
|
+
variant: "outline",
|
|
2158
|
+
icon: T,
|
|
2159
|
+
"aria-label": "Handle next",
|
|
2160
|
+
onClick: () => a()
|
|
2161
|
+
})
|
|
2162
|
+
]
|
|
2163
|
+
})]
|
|
2164
|
+
});
|
|
2165
|
+
}
|
|
2166
|
+
//#endregion
|
|
2167
|
+
//#region src/components/fullCalendar/monthlyCalendar/monthlyCalendarEvent/index.tsx
|
|
2168
|
+
function on(e) {
|
|
2169
|
+
let { events: t } = $(), n = t.filter((t) => t.initialDate.getDate() === e.day && t.initialDate.getMonth() === e.month && t.initialDate.getFullYear() === e.year);
|
|
2170
|
+
if (n.length === 0) return null;
|
|
2171
|
+
function r(t) {
|
|
2172
|
+
return `${e.day}-${e.month}-${e.year}-${t}`;
|
|
2173
|
+
}
|
|
2174
|
+
function i(e) {
|
|
2175
|
+
let t = e.getHours(), n = e.getMinutes();
|
|
2176
|
+
return n === 0 ? `${t}h` : `${t}h${n}`;
|
|
2177
|
+
}
|
|
2178
|
+
function a(e, t) {
|
|
2179
|
+
e.stopPropagation(), t.onClick?.(t.data);
|
|
2180
|
+
}
|
|
2181
|
+
return n.map((e, t) => /* @__PURE__ */ m("div", {
|
|
2182
|
+
className: `arkynMonthlyCalendarEvent ${e?.scheme || "primary"}`,
|
|
2183
|
+
onClick: (t) => a(t, e),
|
|
2184
|
+
children: [/* @__PURE__ */ m("strong", { children: [
|
|
2185
|
+
i(e.initialDate),
|
|
2186
|
+
" ",
|
|
2187
|
+
e?.endDate && `- ${i(e.endDate)}`
|
|
2188
|
+
] }), /* @__PURE__ */ p("p", { children: e.title })]
|
|
2189
|
+
}, r(t)));
|
|
2190
|
+
}
|
|
2191
|
+
//#endregion
|
|
2192
|
+
//#region src/components/fullCalendar/monthlyCalendar/monthlyCalendarTableTd/index.tsx
|
|
2193
|
+
function sn(e) {
|
|
2194
|
+
let { day: t, month: n, year: r, dayOwner: i } = e, { blockedTimestamps: a, onClickDate: o } = $();
|
|
2195
|
+
function s() {
|
|
2196
|
+
let e = /* @__PURE__ */ new Date();
|
|
2197
|
+
return t === e.getDate() && n === e.getMonth() && r === e.getFullYear();
|
|
2198
|
+
}
|
|
2199
|
+
function c() {
|
|
2200
|
+
let e = new Date(r, n, t);
|
|
2201
|
+
return a.some((t) => e >= t.initialDate && e <= t.endDate);
|
|
2202
|
+
}
|
|
2203
|
+
function l(e) {
|
|
2204
|
+
e.stopPropagation(), !c() && o && o(new Date(r, n, t));
|
|
2205
|
+
}
|
|
2206
|
+
return /* @__PURE__ */ m("td", {
|
|
2207
|
+
className: `arkynMonthlyCalendarTableTd ${i} ${c() ? "blocked" : ""}`,
|
|
2208
|
+
onClick: l,
|
|
2209
|
+
children: [/* @__PURE__ */ p("p", {
|
|
2210
|
+
className: s() ? "today" : "",
|
|
2211
|
+
children: t
|
|
2212
|
+
}), /* @__PURE__ */ p("div", {
|
|
2213
|
+
className: "arkynMonthlyCalendarEventContainer",
|
|
2214
|
+
children: /* @__PURE__ */ p(on, {
|
|
2215
|
+
day: t,
|
|
2216
|
+
month: n,
|
|
2217
|
+
year: r
|
|
2218
|
+
})
|
|
2219
|
+
})]
|
|
2220
|
+
});
|
|
2221
|
+
}
|
|
2222
|
+
//#endregion
|
|
2223
|
+
//#region src/components/fullCalendar/monthlyCalendar/monthlyCalendarTableBody/index.tsx
|
|
2224
|
+
function cn() {
|
|
2225
|
+
return /* @__PURE__ */ p("tbody", {
|
|
2226
|
+
className: "arkynMonthlyCalendarTableBody",
|
|
2227
|
+
children: $().listMonthlyMatrix.map((e, t) => /* @__PURE__ */ p("tr", { children: e.map((e, t) => /* @__PURE__ */ p(sn, { ...e }, t)) }, t))
|
|
2228
|
+
});
|
|
2229
|
+
}
|
|
2230
|
+
//#endregion
|
|
2231
|
+
//#region src/components/fullCalendar/monthlyCalendar/monthlyCalendarTableContainer/index.tsx
|
|
2232
|
+
function ln({ children: e }) {
|
|
2233
|
+
return /* @__PURE__ */ p("div", {
|
|
2234
|
+
className: "arkynMonthlyCalendarTableContainer",
|
|
2235
|
+
children: /* @__PURE__ */ p("table", { children: e })
|
|
2236
|
+
});
|
|
2237
|
+
}
|
|
2238
|
+
//#endregion
|
|
2239
|
+
//#region src/components/fullCalendar/monthlyCalendar/monthlyCalendarTableHeader/index.tsx
|
|
2240
|
+
function un() {
|
|
2241
|
+
let { listWeek: e } = $();
|
|
2242
|
+
return /* @__PURE__ */ p("thead", {
|
|
2243
|
+
className: "arkynMonthlyCalendarTableHeader",
|
|
2244
|
+
children: /* @__PURE__ */ p("tr", { children: e.map((e) => /* @__PURE__ */ p("th", { children: J(e) }, e)) })
|
|
2245
|
+
});
|
|
2246
|
+
}
|
|
2247
|
+
//#endregion
|
|
2248
|
+
//#region src/components/fullCalendar/monthlyCalendar/index.tsx
|
|
2249
|
+
function dn() {
|
|
2250
|
+
return /* @__PURE__ */ m(ln, { children: [/* @__PURE__ */ p(un, {}), /* @__PURE__ */ p(cn, {})] });
|
|
2251
|
+
}
|
|
2252
|
+
//#endregion
|
|
2253
|
+
//#region src/components/fullCalendar/weekCalendar/weekCalendarEvent/index.tsx
|
|
2254
|
+
var fn = 30, pn = 40;
|
|
2255
|
+
function mn(e) {
|
|
2256
|
+
let { events: t } = $(), n = t.map((e, t) => ({
|
|
2257
|
+
event: e,
|
|
2258
|
+
sourceIndex: t
|
|
2259
|
+
})).filter(({ event: t }) => t.initialDate.getDate() === e.day && t.initialDate.getMonth() === e.month && t.initialDate.getFullYear() === e.year).sort((e, t) => {
|
|
2260
|
+
let n = e.event.initialDate.getTime(), r = t.event.initialDate.getTime();
|
|
2261
|
+
if (n !== r) return n - r;
|
|
2262
|
+
let i = e.event.endDate?.getTime() ?? n + fn * 6e4, a = t.event.endDate?.getTime() ?? r + fn * 6e4;
|
|
2263
|
+
return i === a ? e.sourceIndex - t.sourceIndex : i - a;
|
|
2264
|
+
}), r = new Map(n.map((e, t) => [e.sourceIndex, t])), i = n.filter(({ event: t }) => {
|
|
2265
|
+
let n = Math.floor(e.timeInMinutes / 60), r = e.timeInMinutes % 60;
|
|
2266
|
+
function i() {
|
|
2267
|
+
let e = t.initialDate.getHours(), i = t.initialDate.getMinutes();
|
|
2268
|
+
if (e !== n) return !1;
|
|
2269
|
+
if (r === 0) return i < 30 && i >= 0;
|
|
2270
|
+
if (r === 30) return i >= 30 && i < 60;
|
|
2271
|
+
}
|
|
2272
|
+
return i() && t.initialDate.getDate() === e.day && t.initialDate.getMonth() === e.month && t.initialDate.getFullYear() === e.year;
|
|
2273
|
+
});
|
|
2274
|
+
if (i.length === 0) return null;
|
|
2275
|
+
function a(t, n) {
|
|
2276
|
+
return `${e.day}-${e.month}-${e.year}-${n}-${t}`;
|
|
2277
|
+
}
|
|
2278
|
+
function o(e) {
|
|
2279
|
+
let t = e.getHours(), n = e.getMinutes();
|
|
2280
|
+
return n === 0 ? `${t}h` : `${t}h${n}`;
|
|
2281
|
+
}
|
|
2282
|
+
function s(e) {
|
|
2283
|
+
let t = e.initialDate.getHours() * 60 + e.initialDate.getMinutes(), n = e.endDate ? e.endDate.getHours() * 60 + e.endDate.getMinutes() : t + fn;
|
|
2284
|
+
return {
|
|
2285
|
+
startMinutes: t,
|
|
2286
|
+
endMinutes: Math.max(n, t + 1)
|
|
2287
|
+
};
|
|
2288
|
+
}
|
|
2289
|
+
function c(e, t) {
|
|
2290
|
+
let i = s(e), a = r.get(t);
|
|
2291
|
+
return a == null ? 0 : n.reduce((e, t, n) => {
|
|
2292
|
+
if (n >= a) return e;
|
|
2293
|
+
let r = s(t.event);
|
|
2294
|
+
return r.startMinutes < i.endMinutes && r.endMinutes > i.startMinutes ? e + 1 : e;
|
|
2295
|
+
}, 0);
|
|
2296
|
+
}
|
|
2297
|
+
function l(t, n) {
|
|
2298
|
+
let { startMinutes: r, endMinutes: i } = s(t), a = r - e.timeInMinutes, o = Math.max(i - r, 1), l = a / fn * 100, u = o / fn * 100, d = c(t, n) * pn;
|
|
2299
|
+
return {
|
|
2300
|
+
top: `${l}%`,
|
|
2301
|
+
height: `${u}%`,
|
|
2302
|
+
left: `${d}px`
|
|
2303
|
+
};
|
|
2304
|
+
}
|
|
2305
|
+
function u(e, t) {
|
|
2306
|
+
e.stopPropagation(), t.onClick?.(t.data);
|
|
2307
|
+
}
|
|
2308
|
+
return i.map(({ event: e, sourceIndex: t }, n) => /* @__PURE__ */ m("div", {
|
|
2309
|
+
className: `arkynWeekCalendarEvent ${e?.scheme || "primary"}`,
|
|
2310
|
+
style: l(e, t),
|
|
2311
|
+
onClick: (t) => u(t, e),
|
|
2312
|
+
children: [/* @__PURE__ */ m("strong", { children: [
|
|
2313
|
+
o(e.initialDate),
|
|
2314
|
+
" ",
|
|
2315
|
+
e?.endDate && `- ${o(e.endDate)}`
|
|
2316
|
+
] }), /* @__PURE__ */ p("p", { children: e.title })]
|
|
2317
|
+
}, a(n, t)));
|
|
2318
|
+
}
|
|
2319
|
+
//#endregion
|
|
2320
|
+
//#region src/components/fullCalendar/weekCalendar/weekCalendarTableTd/index.tsx
|
|
2321
|
+
function hn(e) {
|
|
2322
|
+
let { day: t, month: n, year: r, dayOwner: i, timeInMinutes: a } = e, { blockedTimestamps: o, onClickDate: s } = $();
|
|
2323
|
+
function c() {
|
|
2324
|
+
let e = new Date(r, n, t);
|
|
2325
|
+
return o.some((t) => e >= t.initialDate && e <= t.endDate);
|
|
2326
|
+
}
|
|
2327
|
+
function l(e) {
|
|
2328
|
+
if (e.stopPropagation(), !c() && s) {
|
|
2329
|
+
let e = new Date(r, n, t);
|
|
2330
|
+
e.setHours(0, a, 0, 0), s(e);
|
|
2331
|
+
}
|
|
2332
|
+
}
|
|
2333
|
+
return /* @__PURE__ */ p("td", {
|
|
2334
|
+
className: `arkynWeekCalendarTableTd ${i} ${c() ? "blocked" : ""}`,
|
|
2335
|
+
"data-day": t,
|
|
2336
|
+
"data-time": a,
|
|
2337
|
+
onClick: l,
|
|
2338
|
+
children: /* @__PURE__ */ p("div", {
|
|
2339
|
+
className: "arkynWeekCalendarTableTdContent",
|
|
2340
|
+
children: /* @__PURE__ */ p(mn, {
|
|
2341
|
+
day: t,
|
|
2342
|
+
month: n,
|
|
2343
|
+
year: r,
|
|
2344
|
+
timeInMinutes: a
|
|
2345
|
+
})
|
|
2346
|
+
})
|
|
2347
|
+
});
|
|
2348
|
+
}
|
|
2349
|
+
//#endregion
|
|
2350
|
+
//#region src/components/fullCalendar/weekCalendar/weekCalendarTableBody/index.tsx
|
|
2351
|
+
function gn() {
|
|
2352
|
+
let e = $(), t = new Jt();
|
|
2353
|
+
return /* @__PURE__ */ p("tbody", {
|
|
2354
|
+
className: "arkynWeekCalendarTableBody",
|
|
2355
|
+
children: e.listWeeklyMatrix.map((e) => /* @__PURE__ */ m("tr", { children: [/* @__PURE__ */ p("td", {
|
|
2356
|
+
className: "hourTd",
|
|
2357
|
+
children: /* @__PURE__ */ p("p", { children: t.formatHourLabel(e[0].timeInMinutes) })
|
|
2358
|
+
}), e.map((e) => /* @__PURE__ */ p(hn, { ...e }, `${e.year}-${e.month}-${e.day}-${e.timeInMinutes}`))] }, e[0].timeInMinutes))
|
|
2359
|
+
});
|
|
2360
|
+
}
|
|
2361
|
+
//#endregion
|
|
2362
|
+
//#region src/components/fullCalendar/weekCalendar/weekCalendarTableContainer/index.tsx
|
|
2363
|
+
function _n({ children: e }) {
|
|
2364
|
+
return /* @__PURE__ */ p("div", {
|
|
2365
|
+
className: "arkynWeekCalendarTableContainer",
|
|
2366
|
+
children: /* @__PURE__ */ p("table", { children: e })
|
|
2367
|
+
});
|
|
2368
|
+
}
|
|
2369
|
+
//#endregion
|
|
2370
|
+
//#region src/components/fullCalendar/weekCalendar/weekCalendarTableHeader/index.tsx
|
|
2371
|
+
function vn() {
|
|
2372
|
+
let { listWeek: e, listWeeklyMatrix: t } = $(), n = t[0] || [];
|
|
2373
|
+
return /* @__PURE__ */ p("thead", {
|
|
2374
|
+
className: "arkynWeekCalendarTableHeader",
|
|
2375
|
+
children: /* @__PURE__ */ m("tr", { children: [/* @__PURE__ */ p("th", {}), e.map((e, t) => /* @__PURE__ */ p("th", { children: /* @__PURE__ */ m("div", {
|
|
2376
|
+
className: "arkynWeekCalendarTableHeaderContent",
|
|
2377
|
+
children: [/* @__PURE__ */ p("span", { children: J(e) }), /* @__PURE__ */ p("strong", { children: n[t]?.day })]
|
|
2378
|
+
}) }, e))] })
|
|
2379
|
+
});
|
|
2380
|
+
}
|
|
2381
|
+
//#endregion
|
|
2382
|
+
//#region src/components/fullCalendar/weekCalendar/index.tsx
|
|
2383
|
+
function yn() {
|
|
2384
|
+
return /* @__PURE__ */ m(_n, { children: [/* @__PURE__ */ p(vn, {}), /* @__PURE__ */ p(gn, {})] });
|
|
2385
|
+
}
|
|
2386
|
+
//#endregion
|
|
2387
|
+
//#region src/components/fullCalendar/index.tsx
|
|
2388
|
+
function bn(e) {
|
|
2389
|
+
let [t, n] = u("month");
|
|
2390
|
+
return /* @__PURE__ */ p(Xt, {
|
|
2391
|
+
events: e.events || [],
|
|
2392
|
+
viewValue: e.viewValue,
|
|
2393
|
+
defaultViewValue: e.defaultViewValue,
|
|
2394
|
+
onChangeView: e.onChangeView,
|
|
2395
|
+
blockedTimestamps: e.blockedTimestamps || [],
|
|
2396
|
+
onClickDate: e.onClickDate,
|
|
2397
|
+
children: /* @__PURE__ */ m(rn, { children: [
|
|
2398
|
+
/* @__PURE__ */ p(an, {
|
|
2399
|
+
viewType: t,
|
|
2400
|
+
setViewType: n
|
|
2401
|
+
}),
|
|
2402
|
+
t === "day" && /* @__PURE__ */ p(nn, {}),
|
|
2403
|
+
t === "month" && /* @__PURE__ */ p(dn, {}),
|
|
2404
|
+
t === "week" && /* @__PURE__ */ p(yn, {})
|
|
2405
|
+
] })
|
|
2406
|
+
});
|
|
2407
|
+
}
|
|
2408
|
+
//#endregion
|
|
2409
|
+
//#region src/components/googleAnalytics/snippets/generateGAElements.ts
|
|
2410
|
+
function xn(e) {
|
|
2411
|
+
let { measurementId: t } = e;
|
|
2412
|
+
return t || console.warn("Google Analytics Measurement ID is required"), {
|
|
2413
|
+
src: `https://www.googletagmanager.com/gtag/js?id=${t}`,
|
|
2414
|
+
script: `
|
|
2415
|
+
window.dataLayer = window.dataLayer || [];
|
|
2416
|
+
function gtag(){dataLayer.push(arguments);}
|
|
2417
|
+
gtag('js', new Date());
|
|
2418
|
+
gtag('config', '${t}');`
|
|
2419
|
+
};
|
|
2420
|
+
}
|
|
2421
|
+
//#endregion
|
|
2422
|
+
//#region src/components/googleAnalytics/googleAnalytics.tsx
|
|
2423
|
+
var Sn = class {
|
|
2424
|
+
initializeAsyncScript(e) {
|
|
2425
|
+
let t = document.createElement("script");
|
|
2426
|
+
return t.async = !0, t.src = e, t;
|
|
2427
|
+
}
|
|
2428
|
+
initializeInlineScript(e) {
|
|
2429
|
+
let t = document.createElement("script");
|
|
2430
|
+
return t.innerHTML = e, t;
|
|
2431
|
+
}
|
|
2432
|
+
initialize(e) {
|
|
2433
|
+
let { measurementId: t } = e, n = xn({ measurementId: t }), r = this.initializeAsyncScript(n.src), i = this.initializeInlineScript(n.script);
|
|
2434
|
+
document.head.appendChild(r), document.head.appendChild(i);
|
|
2435
|
+
}
|
|
2436
|
+
};
|
|
2437
|
+
//#endregion
|
|
2438
|
+
//#region src/components/googleAnalytics/googleAnalytics.client.tsx
|
|
2439
|
+
function Cn(e) {
|
|
2440
|
+
return new Sn().initialize(e), null;
|
|
2441
|
+
}
|
|
2442
|
+
//#endregion
|
|
2443
|
+
//#region src/components/googleAnalytics/index.tsx
|
|
2444
|
+
function wn(e) {
|
|
2445
|
+
let { measurementId: t, showInDevMode: n = !1 } = e;
|
|
2446
|
+
return process.env.NODE_ENV !== "production" && !n ? null : /* @__PURE__ */ p(wt, { children: () => /* @__PURE__ */ p(Cn, { measurementId: t }) });
|
|
2447
|
+
}
|
|
2448
|
+
//#endregion
|
|
2449
|
+
//#region src/components/googleTagManager/snippets/appendToDataLayer.ts
|
|
2450
|
+
function Tn(e) {
|
|
2451
|
+
let { dataLayer: t, dataLayerName: n } = e;
|
|
2452
|
+
return `
|
|
2453
|
+
window.${n} = window.${n} || [];
|
|
2454
|
+
window.${n}.push(${JSON.stringify(t)})`;
|
|
2455
|
+
}
|
|
2456
|
+
//#endregion
|
|
2457
|
+
//#region src/components/googleTagManager/snippets/generateGTMElements.ts
|
|
2458
|
+
function En(e) {
|
|
2459
|
+
let { id: t, events: n, dataLayer: r, dataLayerName: i, preview: a, auth: o } = e, s = `>m_auth=${o}`, c = `>m_preview=${a}`;
|
|
2460
|
+
return t || console.warn("GTM Id is required"), {
|
|
2461
|
+
iframe: `
|
|
2462
|
+
<iframe src="https://www.googletagmanager.com/ns.html?id=${t}${s}${c}>m_cookies_win=x"
|
|
2463
|
+
height="0" width="0" style="display:none;visibility:hidden" id="tag-manager"></iframe>`,
|
|
2464
|
+
script: `
|
|
2465
|
+
(function(w,d,s,l,i){w[l]=w[l]||[];
|
|
2466
|
+
w[l].push({'gtm.start': new Date().getTime(),event:'gtm.js', ${JSON.stringify(n).slice(1, -1)}});
|
|
2467
|
+
var f=d.getElementsByTagName(s)[0],j=d.createElement(s),dl=l!='dataLayer'?'&l='+l:'';
|
|
2468
|
+
j.async=true;j.src='https://www.googletagmanager.com/gtm.js?id='+i+dl+'${s}${c}>m_cookies_win=x';
|
|
2469
|
+
f.parentNode.insertBefore(j,f);
|
|
2470
|
+
})(window,document,'script','${i}','${t}');`,
|
|
2471
|
+
dataLayerVar: Tn({
|
|
2472
|
+
dataLayer: r,
|
|
2473
|
+
dataLayerName: i
|
|
2474
|
+
})
|
|
2475
|
+
};
|
|
2476
|
+
}
|
|
2477
|
+
//#endregion
|
|
2478
|
+
//#region src/components/googleTagManager/googleTagManager.tsx
|
|
2479
|
+
var Dn = class {
|
|
2480
|
+
initializeDataScript(e) {
|
|
2481
|
+
let t = document.createElement("script");
|
|
2482
|
+
return t.innerHTML = e, t;
|
|
2483
|
+
}
|
|
2484
|
+
initializeGTMElements(e) {
|
|
2485
|
+
let t = En(e);
|
|
2486
|
+
return {
|
|
2487
|
+
noScript: () => {
|
|
2488
|
+
let e = document.createElement("noscript");
|
|
2489
|
+
return e.innerHTML = t.iframe, e;
|
|
2490
|
+
},
|
|
2491
|
+
script: () => {
|
|
2492
|
+
let e = document.createElement("script");
|
|
2493
|
+
return e.innerHTML = t.script, e;
|
|
2494
|
+
},
|
|
2495
|
+
dataScript: this.initializeDataScript(t.dataLayerVar)
|
|
2496
|
+
};
|
|
2497
|
+
}
|
|
2498
|
+
initializeDataLayer(e) {
|
|
2499
|
+
let { dataLayer: t, dataLayerName: n } = e;
|
|
2500
|
+
if (window[n]) return window[n].push(t);
|
|
2501
|
+
let r = Tn({
|
|
2502
|
+
dataLayer: t,
|
|
2503
|
+
dataLayerName: n
|
|
2504
|
+
}), i = this.initializeDataScript(r);
|
|
2505
|
+
document.head.insertBefore(i, document.head.childNodes[0]);
|
|
2506
|
+
}
|
|
2507
|
+
initialize(e) {
|
|
2508
|
+
let { events: t, gtmId: n, dataLayer: r, auth: i = "", preview: a = "", dataLayerName: o = "dataLayer" } = e, s = this.initializeGTMElements({
|
|
2509
|
+
id: n,
|
|
2510
|
+
events: t,
|
|
2511
|
+
dataLayer: r || void 0,
|
|
2512
|
+
dataLayerName: o,
|
|
2513
|
+
auth: i,
|
|
2514
|
+
preview: a
|
|
2515
|
+
});
|
|
2516
|
+
r && document.head.appendChild(s.dataScript), document.head.insertBefore(s.script(), document.head.childNodes[0]), document.body.insertBefore(s.noScript(), document.body.childNodes[0]);
|
|
2517
|
+
}
|
|
2518
|
+
};
|
|
2519
|
+
//#endregion
|
|
2520
|
+
//#region src/components/googleTagManager/googleTagManager.client.tsx
|
|
2521
|
+
function On(e) {
|
|
2522
|
+
return new Dn().initialize(e), null;
|
|
2523
|
+
}
|
|
2524
|
+
//#endregion
|
|
2525
|
+
//#region src/components/googleTagManager/index.tsx
|
|
2526
|
+
function kn(e) {
|
|
2527
|
+
let { gtmId: t, auth: n = "", preview: r = "", dataLayerName: i = "dataLayer", events: a = {}, dataLayer: o = {}, showInDevMode: s = !1 } = e;
|
|
2528
|
+
return process.env.NODE_ENV !== "production" && !s ? null : /* @__PURE__ */ p(wt, { children: () => /* @__PURE__ */ p(On, {
|
|
2529
|
+
auth: n,
|
|
2530
|
+
dataLayer: o,
|
|
2531
|
+
dataLayerName: i,
|
|
2532
|
+
events: a,
|
|
2533
|
+
gtmId: t,
|
|
2534
|
+
preview: r
|
|
2535
|
+
}) });
|
|
2536
|
+
}
|
|
2537
|
+
//#endregion
|
|
2538
|
+
//#region src/components/imageUpload/hasFileContent/index.tsx
|
|
2539
|
+
function An(e) {
|
|
2540
|
+
let { disabled: t, filePath: n, isLoading: r, acceptImage: i, changeImageButtonText: a, handleSelectFile: o, reSendImage: s } = e;
|
|
2541
|
+
function c() {
|
|
2542
|
+
if (t) return;
|
|
2543
|
+
let e = document.createElement("input");
|
|
2544
|
+
e.type = "file", e.accept = i, e.onchange = (e) => {
|
|
2545
|
+
let t = e.target.files?.[0];
|
|
2546
|
+
t && o(t);
|
|
2547
|
+
}, e.click();
|
|
2548
|
+
}
|
|
2549
|
+
return /* @__PURE__ */ m("div", {
|
|
2550
|
+
className: "arkynImageUploadHasFileContent",
|
|
2551
|
+
style: { backgroundImage: `url("${n}")` },
|
|
2552
|
+
children: [s && /* @__PURE__ */ p(Ue, {
|
|
2553
|
+
orientation: "bottom",
|
|
2554
|
+
text: "Reenviar imagem",
|
|
2555
|
+
children: /* @__PURE__ */ p(He, {
|
|
2556
|
+
type: "button",
|
|
2557
|
+
"aria-label": "resend image",
|
|
2558
|
+
variant: "outline",
|
|
2559
|
+
scheme: "danger",
|
|
2560
|
+
size: "sm",
|
|
2561
|
+
isLoading: r,
|
|
2562
|
+
onClick: s,
|
|
2563
|
+
icon: H,
|
|
2564
|
+
disabled: t
|
|
2565
|
+
})
|
|
2566
|
+
}), /* @__PURE__ */ p(Be, {
|
|
2567
|
+
isLoading: r,
|
|
2568
|
+
onClick: c,
|
|
2569
|
+
variant: "outline",
|
|
2570
|
+
size: "sm",
|
|
2571
|
+
type: "button",
|
|
2572
|
+
disabled: t,
|
|
2573
|
+
children: a
|
|
2574
|
+
})]
|
|
2575
|
+
});
|
|
2576
|
+
}
|
|
2577
|
+
//#endregion
|
|
2578
|
+
//#region src/components/imageUpload/noFileContent/index.tsx
|
|
2579
|
+
function jn(e) {
|
|
2580
|
+
let { dropImageText: t, isLoading: n, acceptImage: r, handleSelectFile: i, selectImageButtonText: a, disabled: o } = e;
|
|
2581
|
+
function s(e) {
|
|
2582
|
+
if (o) return;
|
|
2583
|
+
e.preventDefault();
|
|
2584
|
+
let t = e.dataTransfer.files[0];
|
|
2585
|
+
t && i(t);
|
|
2586
|
+
}
|
|
2587
|
+
function c() {
|
|
2588
|
+
if (o) return;
|
|
2589
|
+
let e = document.createElement("input");
|
|
2590
|
+
e.type = "file", e.accept = r, e.onchange = (e) => {
|
|
2591
|
+
let t = e.target.files?.[0];
|
|
2592
|
+
t && i(t);
|
|
2593
|
+
}, e.click();
|
|
2594
|
+
}
|
|
2595
|
+
return /* @__PURE__ */ m("div", {
|
|
2596
|
+
onDrop: s,
|
|
2597
|
+
className: "arkynImageUploadNoFileContent",
|
|
2598
|
+
children: [/* @__PURE__ */ p(Be, {
|
|
2599
|
+
isLoading: n,
|
|
2600
|
+
onClick: c,
|
|
2601
|
+
variant: "ghost",
|
|
2602
|
+
size: "sm",
|
|
2603
|
+
type: "button",
|
|
2604
|
+
disabled: o,
|
|
2605
|
+
children: a
|
|
2606
|
+
}), /* @__PURE__ */ p("p", { children: t })]
|
|
2607
|
+
});
|
|
2608
|
+
}
|
|
2609
|
+
//#endregion
|
|
2610
|
+
//#region src/components/imageUpload/index.tsx
|
|
2611
|
+
function Mn(e) {
|
|
2612
|
+
let { name: t, defaultValue: n = "", label: r, showAsterisk: i = !1, action: a, fileName: o = "file", className: s = "", method: c = "POST", acceptImage: l = "image/*", fileResponseName: d = "url", changeImageButtonText: f = "Alterar imagem", selectImageButtonText: h = "Selecionar imagem", dropImageText: g = "Ou arraste e solte a imagem aqui", onChange: _, disabled: v = !1, unShowFieldTemplate: y = !1, orientation: b = "vertical" } = e, { fieldErrors: x } = X(), S = x?.[t], [C, w] = u(n), [T, E] = u(""), [D, O] = u(null), [k, A] = u(n), [j, M] = u(!1);
|
|
2613
|
+
async function N(e) {
|
|
2614
|
+
if (v) return;
|
|
2615
|
+
M(!0), O(e), E("");
|
|
2616
|
+
let t = new FormData();
|
|
2617
|
+
t.append(o, e), await fetch(a, {
|
|
2618
|
+
method: c,
|
|
2619
|
+
body: t
|
|
2620
|
+
}).then(async (e) => await e.json()).then((e) => {
|
|
2621
|
+
e?.error ? E(e.error) : w(e?.[d]), _?.(e?.[d]);
|
|
2622
|
+
}).catch((e) => {
|
|
2623
|
+
console.error(e), E("Erro ao enviar imagem");
|
|
2624
|
+
}).finally(() => M(!1));
|
|
2625
|
+
}
|
|
2626
|
+
function P(e) {
|
|
2627
|
+
v || (A(URL.createObjectURL(e)), N(e));
|
|
2628
|
+
}
|
|
2629
|
+
let F = S || T;
|
|
2630
|
+
return /* @__PURE__ */ p(Q, {
|
|
2631
|
+
name: t,
|
|
2632
|
+
label: r,
|
|
2633
|
+
showAsterisk: i,
|
|
2634
|
+
className: s,
|
|
2635
|
+
errorMessage: F,
|
|
2636
|
+
unShowFieldTemplate: y,
|
|
2637
|
+
orientation: b,
|
|
2638
|
+
children: /* @__PURE__ */ m("div", {
|
|
2639
|
+
className: `arkynImageUpload ${F ? "hasError" : "noHasError"} ${k ? "hasImage" : "noHasImage"}`,
|
|
2640
|
+
children: [
|
|
2641
|
+
/* @__PURE__ */ p("input", {
|
|
2642
|
+
type: "hidden",
|
|
2643
|
+
name: t,
|
|
2644
|
+
value: C || ""
|
|
2645
|
+
}),
|
|
2646
|
+
!k && /* @__PURE__ */ p(jn, {
|
|
2647
|
+
disabled: v,
|
|
2648
|
+
isLoading: j,
|
|
2649
|
+
acceptImage: l,
|
|
2650
|
+
dropImageText: g,
|
|
2651
|
+
handleSelectFile: P,
|
|
2652
|
+
selectImageButtonText: h
|
|
2653
|
+
}),
|
|
2654
|
+
k && /* @__PURE__ */ p(An, {
|
|
2655
|
+
disabled: v,
|
|
2656
|
+
isLoading: j,
|
|
2657
|
+
acceptImage: l,
|
|
2658
|
+
filePath: k,
|
|
2659
|
+
handleSelectFile: P,
|
|
2660
|
+
changeImageButtonText: f,
|
|
2661
|
+
reSendImage: F && D ? () => N(D) : void 0
|
|
2662
|
+
})
|
|
2663
|
+
]
|
|
2664
|
+
})
|
|
2665
|
+
});
|
|
2666
|
+
}
|
|
2667
|
+
//#endregion
|
|
2668
|
+
//#region src/components/mapView/mapView.client.tsx
|
|
2669
|
+
function Nn({ center: e, coordinates: t, onMarkerClick: n, accessToken: r, ...i }) {
|
|
2670
|
+
let a = l(null), s = l(null), c = e || t[0];
|
|
2671
|
+
return o(() => (ie.accessToken = r, a.current = new ie.Map({
|
|
2672
|
+
container: s.current,
|
|
2673
|
+
style: "mapbox://styles/mapbox/light-v11",
|
|
2674
|
+
center: [c.lng, c.lat],
|
|
2675
|
+
zoom: 13,
|
|
2676
|
+
language: "pt-BR"
|
|
2677
|
+
}), t.forEach((e) => {
|
|
2678
|
+
let { lat: t, lng: r, popUp: i } = e, o = document.createElement("img");
|
|
2679
|
+
o.className = "arkynMarker", o.src = "https://i.postimg.cc/mgKggjk7/Pin.png";
|
|
2680
|
+
let s = new ie.Marker(o).setLngLat([r, t]).addTo(a.current);
|
|
2681
|
+
if (i) {
|
|
2682
|
+
let e = document.createElement("div");
|
|
2683
|
+
ae(e).render(i);
|
|
2684
|
+
let t = new ie.Popup({
|
|
2685
|
+
offset: 25,
|
|
2686
|
+
closeButton: !1,
|
|
2687
|
+
className: "arkynMapViewPopup"
|
|
2688
|
+
}).setDOMContent(e);
|
|
2689
|
+
s.setPopup(t);
|
|
2690
|
+
}
|
|
2691
|
+
o.addEventListener("click", () => {
|
|
2692
|
+
n && n(e), a.current?.flyTo({
|
|
2693
|
+
center: [r, t],
|
|
2694
|
+
zoom: 15,
|
|
2695
|
+
duration: 1200
|
|
2696
|
+
}), s.togglePopup();
|
|
2697
|
+
});
|
|
2698
|
+
}), () => {
|
|
2699
|
+
a.current?.remove();
|
|
2700
|
+
}), [
|
|
2701
|
+
c.lat,
|
|
2702
|
+
n,
|
|
2703
|
+
t.forEach,
|
|
2704
|
+
c.lng,
|
|
2705
|
+
r
|
|
2706
|
+
]), /* @__PURE__ */ p("div", {
|
|
2707
|
+
id: "map-container",
|
|
2708
|
+
ref: s,
|
|
2709
|
+
style: {
|
|
2710
|
+
height: "100%",
|
|
2711
|
+
width: "100%",
|
|
2712
|
+
borderRadius: "8px"
|
|
2713
|
+
},
|
|
2714
|
+
...i
|
|
2715
|
+
});
|
|
2716
|
+
}
|
|
2717
|
+
//#endregion
|
|
2718
|
+
//#region src/components/mapView/index.tsx
|
|
2719
|
+
function Pn({ className: e }) {
|
|
2720
|
+
return /* @__PURE__ */ p("div", {
|
|
2721
|
+
className: `arkynMapViewPinnedEmpty ${e}`,
|
|
2722
|
+
children: /* @__PURE__ */ p(R, {})
|
|
2723
|
+
});
|
|
2724
|
+
}
|
|
2725
|
+
function Fn(e) {
|
|
2726
|
+
let { coordinates: t, zoom: n = 18, accessToken: r, className: i, onMarkerClick: a, ...o } = e;
|
|
2727
|
+
if (!t) return /* @__PURE__ */ p(Pn, { className: i });
|
|
2728
|
+
let s = Array.isArray(t) ? t : [t];
|
|
2729
|
+
return s.length === 0 ? /* @__PURE__ */ p(Pn, { className: i }) : /* @__PURE__ */ p(wt, {
|
|
2730
|
+
fallback: /* @__PURE__ */ p(Pn, { className: i }),
|
|
2731
|
+
children: () => /* @__PURE__ */ p(Nn, {
|
|
2732
|
+
accessToken: r,
|
|
2733
|
+
coordinates: s,
|
|
2734
|
+
center: s[0],
|
|
2735
|
+
onMarkerClick: a,
|
|
2736
|
+
...o
|
|
2737
|
+
})
|
|
2738
|
+
});
|
|
2739
|
+
}
|
|
2740
|
+
//#endregion
|
|
2741
|
+
//#region src/components/maskedInput/index.tsx
|
|
2742
|
+
var In = r((e, t) => /* @__PURE__ */ p("input", {
|
|
2743
|
+
ref: t,
|
|
2744
|
+
...e
|
|
2745
|
+
}));
|
|
2746
|
+
function Ln(e) {
|
|
2747
|
+
let { name: t, disabled: n, title: r, style: i, variant: a = "solid", separate: o, mask: c, showMask: d, replacement: f, label: h, className: g = "", prefix: _, suffix: v, isLoading: y = !1, leftIcon: b, readOnly: x, onFocus: S, onBlur: C, errorMessage: w, defaultValue: T, showAsterisk: E, rightIcon: D, size: O = "md", id: k, value: A, placeholder: j, ...M } = e, { fieldErrors: N } = X(), [P, F] = u(!1), I = l(null), R = s(), z = k || R, B = w || N?.[t], V = !!B, H = n || y, U = {
|
|
2748
|
+
md: 20,
|
|
2749
|
+
lg: 20
|
|
2750
|
+
}[O], W = D ? "right" : "left", G = W === "left" && y, K = W === "right" && y;
|
|
2751
|
+
function q() {
|
|
2752
|
+
H || !I?.current || (F(!0), I.current.focus());
|
|
2753
|
+
}
|
|
2754
|
+
function ee(e) {
|
|
2755
|
+
F(!0), S && S(e);
|
|
2756
|
+
}
|
|
2757
|
+
function J(e) {
|
|
2758
|
+
F(!1), C && C(e);
|
|
2759
|
+
}
|
|
2760
|
+
let te = `arkynMaskedInput ${_ ? "hasPrefix" : ""} ${v ? "hasSuffix" : ""} ${a} ${O} ${H || x || y ? "opacity" : ""} ${V ? "errored" : ""} ${P ? "focused" : ""}`;
|
|
2761
|
+
return /* @__PURE__ */ m(ze, {
|
|
2762
|
+
className: g,
|
|
2763
|
+
children: [
|
|
2764
|
+
h && /* @__PURE__ */ p(Re, {
|
|
2765
|
+
showAsterisk: E,
|
|
2766
|
+
htmlFor: z,
|
|
2767
|
+
children: h
|
|
2768
|
+
}),
|
|
2769
|
+
/* @__PURE__ */ m("section", {
|
|
2770
|
+
title: r,
|
|
2771
|
+
style: i,
|
|
2772
|
+
onClick: q,
|
|
2773
|
+
className: te,
|
|
2774
|
+
children: [
|
|
2775
|
+
/* @__PURE__ */ p(Z, {
|
|
2776
|
+
iconSize: U,
|
|
2777
|
+
icon: _,
|
|
2778
|
+
className: "prefix"
|
|
2779
|
+
}),
|
|
2780
|
+
/* @__PURE__ */ p(Z, {
|
|
2781
|
+
show: G,
|
|
2782
|
+
iconSize: U,
|
|
2783
|
+
className: "spinner",
|
|
2784
|
+
icon: L
|
|
2785
|
+
}),
|
|
2786
|
+
/* @__PURE__ */ p(Z, {
|
|
2787
|
+
show: !y,
|
|
2788
|
+
icon: b,
|
|
2789
|
+
iconSize: U
|
|
2790
|
+
}),
|
|
2791
|
+
/* @__PURE__ */ p(Y, {
|
|
2792
|
+
component: In,
|
|
2793
|
+
mask: c,
|
|
2794
|
+
replacement: f,
|
|
2795
|
+
separate: o,
|
|
2796
|
+
showMask: d,
|
|
2797
|
+
ref: I,
|
|
2798
|
+
onFocus: ee,
|
|
2799
|
+
onBlur: J,
|
|
2800
|
+
disabled: H,
|
|
2801
|
+
readOnly: x,
|
|
2802
|
+
id: z,
|
|
2803
|
+
name: t,
|
|
2804
|
+
defaultValue: T || void 0,
|
|
2805
|
+
placeholder: H && A || j,
|
|
2806
|
+
value: H ? void 0 : A,
|
|
2807
|
+
...M
|
|
2808
|
+
}),
|
|
2809
|
+
/* @__PURE__ */ p(Z, {
|
|
2810
|
+
show: !y,
|
|
2811
|
+
icon: D,
|
|
2812
|
+
iconSize: U
|
|
2813
|
+
}),
|
|
2814
|
+
/* @__PURE__ */ p(Z, {
|
|
2815
|
+
show: K,
|
|
2816
|
+
iconSize: U,
|
|
2817
|
+
className: "spinner",
|
|
2818
|
+
icon: L
|
|
2819
|
+
}),
|
|
2820
|
+
/* @__PURE__ */ p(Z, {
|
|
2821
|
+
iconSize: U,
|
|
2822
|
+
icon: v,
|
|
2823
|
+
className: "suffix"
|
|
2824
|
+
})
|
|
2825
|
+
]
|
|
2826
|
+
}),
|
|
2827
|
+
B && /* @__PURE__ */ p(Le, { children: B })
|
|
2828
|
+
]
|
|
2829
|
+
});
|
|
2830
|
+
}
|
|
2831
|
+
//#endregion
|
|
2832
|
+
//#region src/components/modal/modalContext.tsx
|
|
2833
|
+
var Rn = n({});
|
|
2834
|
+
function zn(e) {
|
|
2835
|
+
let t = c(() => ({ makeInvisible: e.makeInvisible }), [e.makeInvisible]);
|
|
2836
|
+
return /* @__PURE__ */ p(Rn.Provider, {
|
|
2837
|
+
value: t,
|
|
2838
|
+
children: e.children
|
|
2839
|
+
});
|
|
2840
|
+
}
|
|
2841
|
+
function Bn() {
|
|
2842
|
+
return a(Rn);
|
|
2843
|
+
}
|
|
2844
|
+
//#endregion
|
|
2845
|
+
//#region src/components/modal/modalContainer/index.tsx
|
|
2846
|
+
function Vn(e) {
|
|
2847
|
+
let { isVisible: t, makeInvisible: n, children: r, className: i = "", ...a } = e, [s, c] = u(t), [l, d] = u(!1);
|
|
2848
|
+
o(() => {
|
|
2849
|
+
t ? (c(!0), d(!1)) : s && d(!0);
|
|
2850
|
+
}, [t, s]), it(t);
|
|
2851
|
+
function f(e) {
|
|
2852
|
+
e.target === e.currentTarget && l && (d(!1), c(!1), n());
|
|
2853
|
+
}
|
|
2854
|
+
return s ? /* @__PURE__ */ p(zn, {
|
|
2855
|
+
makeInvisible: () => d(!0),
|
|
2856
|
+
children: /* @__PURE__ */ m("aside", {
|
|
2857
|
+
className: [
|
|
2858
|
+
"arkynModalContainer",
|
|
2859
|
+
l ? "exiting" : "",
|
|
2860
|
+
i
|
|
2861
|
+
].filter(Boolean).join(" ").trim(),
|
|
2862
|
+
...a,
|
|
2863
|
+
children: [/* @__PURE__ */ p("div", {
|
|
2864
|
+
className: "arkynModalContainerOverlay",
|
|
2865
|
+
onClick: () => d(!0),
|
|
2866
|
+
onAnimationEnd: f
|
|
2867
|
+
}), /* @__PURE__ */ p("div", {
|
|
2868
|
+
className: "arkynModalContainerContent",
|
|
2869
|
+
children: r
|
|
2870
|
+
})]
|
|
2871
|
+
})
|
|
2872
|
+
}) : null;
|
|
2873
|
+
}
|
|
2874
|
+
//#endregion
|
|
2875
|
+
//#region src/components/modal/modalFooter/index.tsx
|
|
2876
|
+
function Hn(e) {
|
|
2877
|
+
let { alignment: t = "right", className: n, ...r } = e;
|
|
2878
|
+
return /* @__PURE__ */ p("footer", {
|
|
2879
|
+
className: `arkynModalFooter ${t} ${n}`.trim(),
|
|
2880
|
+
...r
|
|
2881
|
+
});
|
|
2882
|
+
}
|
|
2883
|
+
//#endregion
|
|
2884
|
+
//#region src/components/modal/modalHeader/index.tsx
|
|
2885
|
+
function Un(e) {
|
|
2886
|
+
let { showCloseButton: t = !0, className: n, children: r, ...i } = e, { makeInvisible: a } = Bn();
|
|
2887
|
+
return /* @__PURE__ */ m("header", {
|
|
2888
|
+
className: `arkynModalHeader ${n}`.trim(),
|
|
2889
|
+
...i,
|
|
2890
|
+
children: [r, t && /* @__PURE__ */ p("button", {
|
|
2891
|
+
type: "button",
|
|
2892
|
+
onClick: a,
|
|
2893
|
+
"aria-label": "Close modal button",
|
|
2894
|
+
className: "arkynModalHeaderCloseButton",
|
|
2895
|
+
children: /* @__PURE__ */ p(K, { size: 24 })
|
|
2896
|
+
})]
|
|
2897
|
+
});
|
|
2898
|
+
}
|
|
2899
|
+
//#endregion
|
|
2900
|
+
//#region src/components/multiSelect/multiSelectChevron/index.tsx
|
|
2901
|
+
function Wn(e) {
|
|
2902
|
+
let { iconSize: t, isLoading: n, disabled: r, readOnly: i, isFocused: a } = e;
|
|
2903
|
+
return n ? null : /* @__PURE__ */ p(C, {
|
|
2904
|
+
className: `arkynMultiSelectChevron ${r || i ? "notAnimate" : ""} ${a ? "focused" : ""}`,
|
|
2905
|
+
strokeWidth: 2.5,
|
|
2906
|
+
style: {
|
|
2907
|
+
minWidth: t,
|
|
2908
|
+
minHeight: t,
|
|
2909
|
+
maxWidth: t,
|
|
2910
|
+
maxHeight: t
|
|
2911
|
+
}
|
|
2912
|
+
});
|
|
2913
|
+
}
|
|
2914
|
+
//#endregion
|
|
2915
|
+
//#region src/components/multiSelect/multiSelectContainer/index.tsx
|
|
2916
|
+
function Gn(e) {
|
|
2917
|
+
let { children: t, handleContainerFocus: n, disabled: r, isError: i, isLoading: a, isFocused: o, className: s, readOnly: c, variant: l, size: u, id: d, prefixExists: f } = e;
|
|
2918
|
+
return /* @__PURE__ */ p("section", {
|
|
2919
|
+
id: d,
|
|
2920
|
+
className: `arkynMultiSelectContainer ${f ? "hasPrefix" : ""} ${l} ${u} ${r || c || a ? "opacity" : ""} ${i ? "errored" : ""} ${o ? "focused" : ""} ${s}`,
|
|
2921
|
+
onClick: n,
|
|
2922
|
+
children: t
|
|
2923
|
+
});
|
|
2924
|
+
}
|
|
2925
|
+
//#endregion
|
|
2926
|
+
//#region src/components/multiSelect/multiSelectContent/index.tsx
|
|
2927
|
+
function Kn(e) {
|
|
2928
|
+
let { children: t, size: n } = e;
|
|
2929
|
+
return /* @__PURE__ */ p("div", {
|
|
2930
|
+
className: `arkynMultiSelectContent ${n}`,
|
|
2931
|
+
children: t
|
|
2932
|
+
});
|
|
2933
|
+
}
|
|
2934
|
+
//#endregion
|
|
2935
|
+
//#region src/components/multiSelect/multiSelectMark/index.tsx
|
|
2936
|
+
function qn(e) {
|
|
2937
|
+
let { label: t, value: n, disabled: r, handleChangeValue: i } = e;
|
|
2938
|
+
return /* @__PURE__ */ m("div", {
|
|
2939
|
+
className: "arkynMultiSelectMark",
|
|
2940
|
+
children: [t, /* @__PURE__ */ p("button", {
|
|
2941
|
+
disabled: r,
|
|
2942
|
+
type: "button",
|
|
2943
|
+
onClick: (e) => {
|
|
2944
|
+
e.stopPropagation(), i(n);
|
|
2945
|
+
},
|
|
2946
|
+
children: /* @__PURE__ */ p(K, {})
|
|
2947
|
+
})]
|
|
2948
|
+
});
|
|
2949
|
+
}
|
|
2950
|
+
//#endregion
|
|
2951
|
+
//#region src/components/multiSelect/multiSelectOption/index.tsx
|
|
2952
|
+
function Jn(e) {
|
|
2953
|
+
let { label: t, optionHasSelected: n, handleChangeValue: r, value: i, size: a } = e;
|
|
2954
|
+
return /* @__PURE__ */ m("div", {
|
|
2955
|
+
onClick: () => r(i),
|
|
2956
|
+
className: `arkynMultiSelectOption ${a} ${n(i) ? "active" : ""}`,
|
|
2957
|
+
children: [
|
|
2958
|
+
t,
|
|
2959
|
+
" ",
|
|
2960
|
+
/* @__PURE__ */ p(x, {})
|
|
2961
|
+
]
|
|
2962
|
+
});
|
|
2963
|
+
}
|
|
2964
|
+
//#endregion
|
|
2965
|
+
//#region src/components/multiSelect/multiSelectOptionsContainer/index.tsx
|
|
2966
|
+
function Yn(e) {
|
|
2967
|
+
let { children: t, isFocused: n, isSearchable: r, search: i, onSearch: a } = e, s = l(null), [c, d] = u("bottom");
|
|
2968
|
+
it(n), o(() => {
|
|
2969
|
+
n && (() => {
|
|
2970
|
+
if (!s.current) return;
|
|
2971
|
+
let e = s.current.parentElement;
|
|
2972
|
+
if (!e) return;
|
|
2973
|
+
let t = e.getBoundingClientRect();
|
|
2974
|
+
window.innerHeight - t.bottom < 300 && t.top > 300 ? d("top") : d("bottom");
|
|
2975
|
+
})();
|
|
2976
|
+
}, [n]);
|
|
2977
|
+
function f(e) {
|
|
2978
|
+
r && a(e.target.value);
|
|
2979
|
+
}
|
|
2980
|
+
return n ? /* @__PURE__ */ m("div", {
|
|
2981
|
+
ref: s,
|
|
2982
|
+
className: `arkynMultiSelectOptionsContainer ${c}`,
|
|
2983
|
+
children: [r && /* @__PURE__ */ p(at, {
|
|
2984
|
+
type: "search",
|
|
2985
|
+
name: "search-select",
|
|
2986
|
+
variant: "underline",
|
|
2987
|
+
leftIcon: U,
|
|
2988
|
+
value: i,
|
|
2989
|
+
onChange: f
|
|
2990
|
+
}), t]
|
|
2991
|
+
}) : null;
|
|
2992
|
+
}
|
|
2993
|
+
//#endregion
|
|
2994
|
+
//#region src/components/multiSelect/multiSelectOverlay/index.tsx
|
|
2995
|
+
function Xn(e) {
|
|
2996
|
+
let { isFocused: t, handleBlur: n } = e;
|
|
2997
|
+
return t ? /* @__PURE__ */ p("aside", {
|
|
2998
|
+
className: "arkynMultiSelectOverlay",
|
|
2999
|
+
onClick: n
|
|
3000
|
+
}) : null;
|
|
3001
|
+
}
|
|
3002
|
+
//#endregion
|
|
3003
|
+
//#region src/components/multiSelect/multiSelectSpinner/index.tsx
|
|
3004
|
+
function Zn(e) {
|
|
3005
|
+
let { iconSize: t, isLoading: n } = e;
|
|
3006
|
+
return n ? /* @__PURE__ */ p(L, {
|
|
3007
|
+
className: "arkynMultiSelectSpinner",
|
|
3008
|
+
size: t,
|
|
3009
|
+
strokeWidth: 2.5
|
|
3010
|
+
}) : null;
|
|
3011
|
+
}
|
|
3012
|
+
//#endregion
|
|
3013
|
+
//#region src/components/multiSelect/index.tsx
|
|
3014
|
+
function Qn(e) {
|
|
3015
|
+
let { name: t, options: n, className: r = "", placeholder: i = "Selecione...", closeOnSelect: a = !1, defaultValue: o = [], errorMessage: c, isLoading: d = !1, readOnly: f = !1, isSearchable: h = !1, id: g, label: _, showAsterisk: v, leftIcon: y, onSearch: b, onChange: x, onBlur: S, notFoundText: C = "Sem opções disponíveis", onFocus: w, disabled: T = !1, prefix: E, size: D = "md", value: O, variant: k = "solid", unShowFieldTemplate: A = !1, orientation: j = "vertical" } = e, { fieldErrors: M } = X(), N = l(null), P = s(), F = g || P, I = c || M?.[t], L = !!I, R = T || d || f, z = {
|
|
3016
|
+
md: 20,
|
|
3017
|
+
lg: 20
|
|
3018
|
+
}[D], [B, V] = u(""), [H, U] = u(!1), [W, G] = u(o), K = O || W;
|
|
3019
|
+
function q(e) {
|
|
3020
|
+
return K.includes(e);
|
|
3021
|
+
}
|
|
3022
|
+
function ee(e) {
|
|
3023
|
+
return n.find((t) => t.value === e)?.label || "";
|
|
3024
|
+
}
|
|
3025
|
+
function J() {
|
|
3026
|
+
R || !N?.current || H || (U(!0), N.current.focus(), w?.());
|
|
3027
|
+
}
|
|
3028
|
+
function te() {
|
|
3029
|
+
U(!1), S && N.current && N.current.blur();
|
|
3030
|
+
}
|
|
3031
|
+
function ne(e) {
|
|
3032
|
+
V(e), b && b(e);
|
|
3033
|
+
}
|
|
3034
|
+
function re(e) {
|
|
3035
|
+
q(e) ? (G(W.filter((t) => t !== e)), x && x(W.filter((t) => t !== e))) : (G([...W, e]), x && x([...W, e])), a && te();
|
|
3036
|
+
}
|
|
3037
|
+
let ie = n.filter((t) => !!(e.onSearch || !e.isSearchable || t.label.toLowerCase().includes(B.toLowerCase())));
|
|
3038
|
+
return /* @__PURE__ */ p(Q, {
|
|
3039
|
+
name: t,
|
|
3040
|
+
label: _,
|
|
3041
|
+
showAsterisk: v,
|
|
3042
|
+
className: r,
|
|
3043
|
+
errorMessage: I,
|
|
3044
|
+
unShowFieldTemplate: A,
|
|
3045
|
+
orientation: j,
|
|
3046
|
+
children: /* @__PURE__ */ m(Gn, {
|
|
3047
|
+
handleContainerFocus: J,
|
|
3048
|
+
disabled: R,
|
|
3049
|
+
isError: L,
|
|
3050
|
+
isFocused: H,
|
|
3051
|
+
isLoading: d,
|
|
3052
|
+
readOnly: f,
|
|
3053
|
+
size: D,
|
|
3054
|
+
variant: k,
|
|
3055
|
+
prefixExists: !!E,
|
|
3056
|
+
id: F,
|
|
3057
|
+
children: [
|
|
3058
|
+
/* @__PURE__ */ p("input", {
|
|
3059
|
+
ref: N,
|
|
3060
|
+
name: t,
|
|
3061
|
+
value: JSON.stringify(K),
|
|
3062
|
+
type: "hidden"
|
|
3063
|
+
}),
|
|
3064
|
+
/* @__PURE__ */ p(Z, {
|
|
3065
|
+
iconSize: z,
|
|
3066
|
+
icon: E,
|
|
3067
|
+
className: "prefix"
|
|
3068
|
+
}),
|
|
3069
|
+
y && /* @__PURE__ */ p(y, {
|
|
3070
|
+
size: z,
|
|
3071
|
+
strokeWidth: 2.5
|
|
3072
|
+
}),
|
|
3073
|
+
/* @__PURE__ */ m(Kn, {
|
|
3074
|
+
size: D,
|
|
3075
|
+
children: [K.map((e) => /* @__PURE__ */ p(qn, {
|
|
3076
|
+
label: ee(e),
|
|
3077
|
+
value: e,
|
|
3078
|
+
handleChangeValue: re,
|
|
3079
|
+
disabled: R
|
|
3080
|
+
}, e)), K.length <= 0 && /* @__PURE__ */ p("p", { children: i })]
|
|
3081
|
+
}),
|
|
3082
|
+
/* @__PURE__ */ m(Yn, {
|
|
3083
|
+
isFocused: H,
|
|
3084
|
+
isSearchable: h,
|
|
3085
|
+
search: B,
|
|
3086
|
+
onSearch: ne,
|
|
3087
|
+
children: [ie.map(({ label: e, value: t }) => /* @__PURE__ */ p(Jn, {
|
|
3088
|
+
label: e,
|
|
3089
|
+
value: t,
|
|
3090
|
+
size: D,
|
|
3091
|
+
handleChangeValue: re,
|
|
3092
|
+
optionHasSelected: q
|
|
3093
|
+
}, t)), ie.length <= 0 && /* @__PURE__ */ p("p", { children: C })]
|
|
3094
|
+
}),
|
|
3095
|
+
/* @__PURE__ */ p(Wn, {
|
|
3096
|
+
disabled: R,
|
|
3097
|
+
isFocused: H,
|
|
3098
|
+
readOnly: f,
|
|
3099
|
+
iconSize: z,
|
|
3100
|
+
isLoading: d
|
|
3101
|
+
}),
|
|
3102
|
+
/* @__PURE__ */ p(Zn, {
|
|
3103
|
+
iconSize: z,
|
|
3104
|
+
isLoading: d
|
|
3105
|
+
}),
|
|
3106
|
+
/* @__PURE__ */ p(Xn, {
|
|
3107
|
+
handleBlur: te,
|
|
3108
|
+
isFocused: H
|
|
3109
|
+
})
|
|
3110
|
+
]
|
|
3111
|
+
})
|
|
3112
|
+
});
|
|
3113
|
+
}
|
|
3114
|
+
//#endregion
|
|
3115
|
+
//#region src/components/pagination/chevronButton/index.tsx
|
|
3116
|
+
function $n(e) {
|
|
3117
|
+
let { orientation: t, handlePageChange: n, disabled: r } = e;
|
|
3118
|
+
return /* @__PURE__ */ p("button", {
|
|
3119
|
+
type: "button",
|
|
3120
|
+
className: "arkynChevronPageButton",
|
|
3121
|
+
disabled: r,
|
|
3122
|
+
onClick: n,
|
|
3123
|
+
children: {
|
|
3124
|
+
left: /* @__PURE__ */ p(w, {}),
|
|
3125
|
+
right: /* @__PURE__ */ p(T, {})
|
|
3126
|
+
}[t]
|
|
3127
|
+
});
|
|
3128
|
+
}
|
|
3129
|
+
//#endregion
|
|
3130
|
+
//#region src/components/pagination/currentButton/index.tsx
|
|
3131
|
+
function er({ currentPage: e }) {
|
|
3132
|
+
return /* @__PURE__ */ p("button", {
|
|
3133
|
+
type: "button",
|
|
3134
|
+
className: "arkynPaginationCurrentButton",
|
|
3135
|
+
disabled: !0,
|
|
3136
|
+
children: e
|
|
3137
|
+
});
|
|
3138
|
+
}
|
|
3139
|
+
//#endregion
|
|
3140
|
+
//#region src/components/pagination/pageButton/index.tsx
|
|
3141
|
+
function tr(e) {
|
|
3142
|
+
let { page: t, handlePageChange: n } = e;
|
|
3143
|
+
return /* @__PURE__ */ p("button", {
|
|
3144
|
+
type: "button",
|
|
3145
|
+
className: "arkynPaginationPageButton",
|
|
3146
|
+
onClick: n,
|
|
3147
|
+
children: t
|
|
3148
|
+
});
|
|
3149
|
+
}
|
|
3150
|
+
//#endregion
|
|
3151
|
+
//#region src/components/pagination/paginationService.ts
|
|
3152
|
+
var nr = class {
|
|
3153
|
+
currentPage;
|
|
3154
|
+
totalCountRegisters;
|
|
3155
|
+
registerPerPage;
|
|
3156
|
+
siblingsCount;
|
|
3157
|
+
lastPage;
|
|
3158
|
+
onChange;
|
|
3159
|
+
previousPages;
|
|
3160
|
+
nextPages;
|
|
3161
|
+
generatePagesArray(e, t) {
|
|
3162
|
+
return [...Array(t - e)].map((t, n) => e + n + 1).filter((e) => e > 0);
|
|
3163
|
+
}
|
|
3164
|
+
generatePreviousPages(e, t) {
|
|
3165
|
+
return e > 1 ? this.generatePagesArray(e - 1 - t, e - 1) : [];
|
|
3166
|
+
}
|
|
3167
|
+
generateNextPages(e, t) {
|
|
3168
|
+
return e < this.lastPage ? this.generatePagesArray(e, Math.min(e + t, this.lastPage)) : [];
|
|
3169
|
+
}
|
|
3170
|
+
constructor(e) {
|
|
3171
|
+
this.totalCountRegisters = e.totalCountRegisters, this.currentPage = e.currentPage, this.registerPerPage = e?.registerPerPage || 20, this.siblingsCount = e?.siblingsCount || 2, this.lastPage = Math.ceil(this.totalCountRegisters / this.registerPerPage), this.onChange = e?.onChange, this.previousPages = this.generatePreviousPages(this.currentPage, this.siblingsCount), this.nextPages = this.generateNextPages(this.currentPage, this.siblingsCount);
|
|
3172
|
+
}
|
|
3173
|
+
handlePageChange = (e) => {
|
|
3174
|
+
e < 1 || e > this.lastPage || this.onChange && (this.currentPage = e, this.onChange(this.currentPage));
|
|
3175
|
+
};
|
|
3176
|
+
handlePlusChange = () => {
|
|
3177
|
+
this.currentPage >= this.lastPage || this.onChange && (this.currentPage += 1, this.onChange(this.currentPage));
|
|
3178
|
+
};
|
|
3179
|
+
handleMinusChange = () => {
|
|
3180
|
+
this.currentPage <= 1 || this.onChange && (--this.currentPage, this.onChange(this.currentPage));
|
|
3181
|
+
};
|
|
3182
|
+
};
|
|
3183
|
+
//#endregion
|
|
3184
|
+
//#region src/components/pagination/spread/index.tsx
|
|
3185
|
+
function rr() {
|
|
3186
|
+
return /* @__PURE__ */ p("p", {
|
|
3187
|
+
className: "arkynPaginationSpread",
|
|
3188
|
+
children: /* @__PURE__ */ p(D, {})
|
|
3189
|
+
});
|
|
3190
|
+
}
|
|
3191
|
+
//#endregion
|
|
3192
|
+
//#region src/components/pagination/index.tsx
|
|
3193
|
+
function ir(e) {
|
|
3194
|
+
let { totalCountRegisters: t, siblingsCount: n, currentPage: r, registerPerPage: i, onChange: a, ...o } = e, { currentPage: s, siblingsCount: c, previousPages: l, nextPages: u, lastPage: d, handlePageChange: h, handleMinusChange: g, handlePlusChange: _ } = new nr({
|
|
3195
|
+
totalCountRegisters: t,
|
|
3196
|
+
currentPage: r,
|
|
3197
|
+
registerPerPage: i,
|
|
3198
|
+
siblingsCount: n,
|
|
3199
|
+
onChange: a
|
|
3200
|
+
});
|
|
3201
|
+
return /* @__PURE__ */ m("div", {
|
|
3202
|
+
className: "arkynPagination",
|
|
3203
|
+
...o,
|
|
3204
|
+
children: [
|
|
3205
|
+
/* @__PURE__ */ p($n, {
|
|
3206
|
+
orientation: "left",
|
|
3207
|
+
handlePageChange: g,
|
|
3208
|
+
disabled: s <= 1
|
|
3209
|
+
}),
|
|
3210
|
+
s > 1 + c && /* @__PURE__ */ m(f, { children: [/* @__PURE__ */ p(tr, {
|
|
3211
|
+
page: 1,
|
|
3212
|
+
handlePageChange: () => h(1)
|
|
3213
|
+
}), s > 2 + c && /* @__PURE__ */ p(rr, {})] }),
|
|
3214
|
+
l.map((e) => /* @__PURE__ */ p(tr, {
|
|
3215
|
+
page: e,
|
|
3216
|
+
handlePageChange: g
|
|
3217
|
+
}, e)),
|
|
3218
|
+
/* @__PURE__ */ p(er, { currentPage: s }),
|
|
3219
|
+
u.map((e) => /* @__PURE__ */ p(tr, {
|
|
3220
|
+
page: e,
|
|
3221
|
+
handlePageChange: _
|
|
3222
|
+
}, e)),
|
|
3223
|
+
s + c < d && /* @__PURE__ */ m(f, { children: [s + 1 + c < d && /* @__PURE__ */ p(rr, {}), /* @__PURE__ */ p(tr, {
|
|
3224
|
+
page: d,
|
|
3225
|
+
handlePageChange: () => h(d)
|
|
3226
|
+
})] }),
|
|
3227
|
+
/* @__PURE__ */ p($n, {
|
|
3228
|
+
orientation: "right",
|
|
3229
|
+
handlePageChange: _,
|
|
3230
|
+
disabled: s >= d
|
|
3231
|
+
})
|
|
3232
|
+
]
|
|
3233
|
+
});
|
|
3234
|
+
}
|
|
3235
|
+
//#endregion
|
|
3236
|
+
//#region src/utils/phoneInputUtilities.ts
|
|
3237
|
+
function ar(e) {
|
|
3238
|
+
return e?.replace(/[^0-9]/g, "");
|
|
3239
|
+
}
|
|
3240
|
+
var or = {
|
|
3241
|
+
EIGHT: "(99) 9999-9999",
|
|
3242
|
+
NINE: "(99) 99999-9999"
|
|
3243
|
+
};
|
|
3244
|
+
function sr(e, t, n = "9") {
|
|
3245
|
+
let r = "", i = 0;
|
|
3246
|
+
for (let a = 0; a < t.length; a++) if (t[a] === n) if (i < e.length) r += e[i], i++;
|
|
3247
|
+
else break;
|
|
3248
|
+
else if (i < e.length) r += t[a];
|
|
3249
|
+
else break;
|
|
3250
|
+
return r;
|
|
3251
|
+
}
|
|
3252
|
+
function cr(e) {
|
|
3253
|
+
return e.length > 10 ? "NINE" : "EIGHT";
|
|
3254
|
+
}
|
|
3255
|
+
var lr = ar(or.NINE).length;
|
|
3256
|
+
//#endregion
|
|
3257
|
+
//#region src/components/phoneInput/phoneInputContainer/index.tsx
|
|
3258
|
+
function ur(e) {
|
|
3259
|
+
let { children: t, onFocus: n, disabled: r, isError: i, isLoading: a, isFocused: o, className: s = "", readOnly: c, variant: l, size: u } = e;
|
|
3260
|
+
return /* @__PURE__ */ p("section", {
|
|
3261
|
+
className: `arkynPhoneInputContainer ${l} ${u} ${r || c || a ? "opacity" : ""} ${i ? "errored" : ""} ${o ? "focused" : ""} ${s}`.trim(),
|
|
3262
|
+
onClick: n,
|
|
3263
|
+
children: t
|
|
3264
|
+
});
|
|
3265
|
+
}
|
|
3266
|
+
//#endregion
|
|
3267
|
+
//#region src/components/phoneInput/phoneInputCountriesOverlay/index.tsx
|
|
3268
|
+
function dr(e) {
|
|
3269
|
+
let { isOpen: t, onClick: n } = e;
|
|
3270
|
+
return t ? /* @__PURE__ */ p("aside", {
|
|
3271
|
+
className: "arkynPhoneInputCountriesOverlay",
|
|
3272
|
+
onClick: n
|
|
3273
|
+
}) : null;
|
|
3274
|
+
}
|
|
3275
|
+
//#endregion
|
|
3276
|
+
//#region src/components/phoneInput/phoneInputCountryOption/index.tsx
|
|
3277
|
+
function fr(e) {
|
|
3278
|
+
let { country: t, isActive: n, handleChangeValue: r, size: i } = e;
|
|
3279
|
+
return /* @__PURE__ */ m("div", {
|
|
3280
|
+
onClick: () => r(t),
|
|
3281
|
+
className: `arkynPhoneInputCountryOption ${i} ${n ? "active" : ""}`,
|
|
3282
|
+
children: [
|
|
3283
|
+
/* @__PURE__ */ p("img", {
|
|
3284
|
+
src: t.flag,
|
|
3285
|
+
alt: t.name,
|
|
3286
|
+
className: "flag"
|
|
3287
|
+
}),
|
|
3288
|
+
t.name,
|
|
3289
|
+
" ",
|
|
3290
|
+
/* @__PURE__ */ p("span", { children: t.code }),
|
|
3291
|
+
/* @__PURE__ */ p(x, { className: "check" })
|
|
3292
|
+
]
|
|
3293
|
+
});
|
|
3294
|
+
}
|
|
3295
|
+
//#endregion
|
|
3296
|
+
//#region src/components/phoneInput/phoneInputCountryOptionsContainer/index.tsx
|
|
3297
|
+
function pr(e) {
|
|
3298
|
+
let { children: t, isOpen: n, onSearch: r, search: i, placeholder: a } = e, s = l(null), [c, d] = u("bottom");
|
|
3299
|
+
function f(e) {
|
|
3300
|
+
r(e.target.value);
|
|
3301
|
+
}
|
|
3302
|
+
return it(n), o(() => {
|
|
3303
|
+
n && (() => {
|
|
3304
|
+
if (!s.current) return;
|
|
3305
|
+
let e = s.current.parentElement;
|
|
3306
|
+
if (!e) return;
|
|
3307
|
+
let t = e.getBoundingClientRect();
|
|
3308
|
+
window.innerHeight - t.bottom < 300 && t.top > 300 ? d("top") : d("bottom");
|
|
3309
|
+
})();
|
|
3310
|
+
}, [n]), n ? /* @__PURE__ */ m("div", {
|
|
3311
|
+
className: `arkynPhoneInputCountryOptionsContainer ${c}`,
|
|
3312
|
+
ref: s,
|
|
3313
|
+
children: [/* @__PURE__ */ p("input", {
|
|
3314
|
+
type: "search",
|
|
3315
|
+
name: "search-select",
|
|
3316
|
+
className: "arkynPhoneInputCountryOptionsContainerSearchSelect",
|
|
3317
|
+
value: i,
|
|
3318
|
+
id: "input-search",
|
|
3319
|
+
placeholder: a,
|
|
3320
|
+
onChange: f
|
|
3321
|
+
}), t]
|
|
3322
|
+
}) : null;
|
|
3323
|
+
}
|
|
3324
|
+
//#endregion
|
|
3325
|
+
//#region src/components/phoneInput/phoneInputCountrySelector/index.tsx
|
|
3326
|
+
function mr(e) {
|
|
3327
|
+
let { currentCountry: t, onClick: n } = e;
|
|
3328
|
+
return /* @__PURE__ */ m("div", {
|
|
3329
|
+
className: "phoneInputSelectCountry",
|
|
3330
|
+
onClick: n,
|
|
3331
|
+
children: [
|
|
3332
|
+
/* @__PURE__ */ p("img", {
|
|
3333
|
+
className: "flag",
|
|
3334
|
+
src: t.flag,
|
|
3335
|
+
alt: t.name
|
|
3336
|
+
}),
|
|
3337
|
+
/* @__PURE__ */ p(C, {
|
|
3338
|
+
className: "chevronDown",
|
|
3339
|
+
strokeWidth: 2.5
|
|
3340
|
+
}),
|
|
3341
|
+
/* @__PURE__ */ p(Ve, { orientation: "vertical" })
|
|
3342
|
+
]
|
|
3343
|
+
});
|
|
3344
|
+
}
|
|
3345
|
+
//#endregion
|
|
3346
|
+
//#region src/components/phoneInput/phoneInputMask/index.tsx
|
|
3347
|
+
var hr = r((e, t) => /* @__PURE__ */ p("input", {
|
|
3348
|
+
ref: t,
|
|
3349
|
+
...e
|
|
3350
|
+
})), gr = r((e, t) => {
|
|
3351
|
+
let { onFocus: n, readonly: r, onBlur: i, size: a, onChange: s, value: c, currentCountry: u, disabled: d, id: f } = e, m = l(!0), h = l(s);
|
|
3352
|
+
h.current = s;
|
|
3353
|
+
let g = typeof u.mask == "string" ? u.mask : u.mask[0];
|
|
3354
|
+
o(() => {
|
|
3355
|
+
if (m.current) {
|
|
3356
|
+
m.current = !1;
|
|
3357
|
+
return;
|
|
3358
|
+
}
|
|
3359
|
+
h.current(g);
|
|
3360
|
+
}, [g]);
|
|
3361
|
+
let _ = `phoneInputMask ${a}`;
|
|
3362
|
+
function v(e) {
|
|
3363
|
+
let t = ar(e.target.value), n = cr(t);
|
|
3364
|
+
t.length > lr || (t = sr(t, or[n]), e.target.value = t, s(t));
|
|
3365
|
+
}
|
|
3366
|
+
return u.code === "+55" ? /* @__PURE__ */ p("input", {
|
|
3367
|
+
id: f,
|
|
3368
|
+
value: c,
|
|
3369
|
+
onChange: v,
|
|
3370
|
+
className: _,
|
|
3371
|
+
onFocus: n,
|
|
3372
|
+
onBlur: i,
|
|
3373
|
+
disabled: d,
|
|
3374
|
+
readOnly: r,
|
|
3375
|
+
ref: t
|
|
3376
|
+
}) : /* @__PURE__ */ p(Y, {
|
|
3377
|
+
id: f,
|
|
3378
|
+
value: c,
|
|
3379
|
+
readOnly: r,
|
|
3380
|
+
onChange: (e) => s(e.target.value),
|
|
3381
|
+
className: _,
|
|
3382
|
+
component: hr,
|
|
3383
|
+
onFocus: n,
|
|
3384
|
+
onBlur: i,
|
|
3385
|
+
disabled: d,
|
|
3386
|
+
mask: g,
|
|
3387
|
+
showMask: !0,
|
|
3388
|
+
replacement: { _: /\d/ },
|
|
3389
|
+
ref: t
|
|
3390
|
+
});
|
|
3391
|
+
});
|
|
3392
|
+
//#endregion
|
|
3393
|
+
//#region src/components/phoneInput/index.tsx
|
|
3394
|
+
function _r(e, t) {
|
|
3395
|
+
let n = re(e);
|
|
3396
|
+
return t.code === "+55" ? sr(n, or[cr(n)]) : sr(n, typeof t.mask == "string" ? t.mask : t.mask[0], "_");
|
|
3397
|
+
}
|
|
3398
|
+
function vr(e) {
|
|
3399
|
+
let { value: t, label: n, className: r = "", disabled: i = !1, errorMessage: a, isLoading: o = !1, readOnly: c = !1, size: d = "md", defaultValue: f = "", variant: h = "solid", showAsterisk: g, name: _, onChange: v, searchCountryPlaceholder: y = "Pesquisar país", notFoundCountryText: b = "Nenhum país encontrado", id: x, unShowFieldTemplate: S = !1, orientation: C = "vertical" } = e, w = oe.find((e) => e.iso === "BR"), T = f ? ne(f) : "", E = f ? ee(f)[1] : w, [D, O] = u(!1), [k, A] = u(""), [j, M] = u(!1), [N, P] = u(T), [F, I] = u(E), L = t === void 0 ? N : _r(t, F), { fieldErrors: R } = X(), z = l(null), B = s(), V = x || B, H = a || R?.[_], U = !!H, W = i || o, G = l(null);
|
|
3400
|
+
function K() {
|
|
3401
|
+
W || D || j || (O(!0), G.current && G.current.focus());
|
|
3402
|
+
}
|
|
3403
|
+
function q() {
|
|
3404
|
+
M(!0), O(!0);
|
|
3405
|
+
}
|
|
3406
|
+
function J() {
|
|
3407
|
+
M(!1), O(!1);
|
|
3408
|
+
}
|
|
3409
|
+
function te() {
|
|
3410
|
+
O(!0);
|
|
3411
|
+
}
|
|
3412
|
+
function ie() {
|
|
3413
|
+
O(!1);
|
|
3414
|
+
}
|
|
3415
|
+
function ae(e) {
|
|
3416
|
+
return e.name.toLowerCase().includes(k.toLowerCase());
|
|
3417
|
+
}
|
|
3418
|
+
function Y(e) {
|
|
3419
|
+
let t = F.code;
|
|
3420
|
+
return t += re(e || L), t;
|
|
3421
|
+
}
|
|
3422
|
+
return /* @__PURE__ */ p(Q, {
|
|
3423
|
+
name: _,
|
|
3424
|
+
label: n,
|
|
3425
|
+
showAsterisk: g,
|
|
3426
|
+
className: r,
|
|
3427
|
+
errorMessage: H,
|
|
3428
|
+
unShowFieldTemplate: S,
|
|
3429
|
+
orientation: C,
|
|
3430
|
+
children: /* @__PURE__ */ m(ur, {
|
|
3431
|
+
disabled: W,
|
|
3432
|
+
isError: U,
|
|
3433
|
+
isLoading: o,
|
|
3434
|
+
isFocused: D,
|
|
3435
|
+
readOnly: c,
|
|
3436
|
+
size: d,
|
|
3437
|
+
variant: h,
|
|
3438
|
+
onFocus: K,
|
|
3439
|
+
children: [
|
|
3440
|
+
/* @__PURE__ */ p(mr, {
|
|
3441
|
+
currentCountry: F,
|
|
3442
|
+
onClick: q,
|
|
3443
|
+
size: d
|
|
3444
|
+
}),
|
|
3445
|
+
/* @__PURE__ */ m(pr, {
|
|
3446
|
+
isOpen: W || c ? !1 : j,
|
|
3447
|
+
search: k,
|
|
3448
|
+
placeholder: y,
|
|
3449
|
+
onSearch: A,
|
|
3450
|
+
children: [oe.filter((e) => ae(e)).map((e) => /* @__PURE__ */ p(fr, {
|
|
3451
|
+
country: e,
|
|
3452
|
+
handleChangeValue: () => {
|
|
3453
|
+
I(e), M(!1), P("");
|
|
3454
|
+
},
|
|
3455
|
+
isActive: e.iso === F.iso,
|
|
3456
|
+
size: d
|
|
3457
|
+
}, e.iso)), oe.filter((e) => ae(e)).length === 0 && /* @__PURE__ */ p("p", { children: b })]
|
|
3458
|
+
}),
|
|
3459
|
+
/* @__PURE__ */ p(dr, {
|
|
3460
|
+
isOpen: W || c ? !1 : j,
|
|
3461
|
+
onClick: J
|
|
3462
|
+
}),
|
|
3463
|
+
/* @__PURE__ */ p(gr, {
|
|
3464
|
+
id: V,
|
|
3465
|
+
ref: G,
|
|
3466
|
+
readonly: c,
|
|
3467
|
+
currentCountry: F,
|
|
3468
|
+
value: L,
|
|
3469
|
+
disabled: W,
|
|
3470
|
+
onBlur: ie,
|
|
3471
|
+
onFocus: te,
|
|
3472
|
+
size: d,
|
|
3473
|
+
onChange: (e) => {
|
|
3474
|
+
P(e), v?.(Y(e));
|
|
3475
|
+
}
|
|
3476
|
+
}),
|
|
3477
|
+
/* @__PURE__ */ p("input", {
|
|
3478
|
+
ref: z,
|
|
3479
|
+
type: "hidden",
|
|
3480
|
+
name: _,
|
|
3481
|
+
value: Y()
|
|
3482
|
+
})
|
|
3483
|
+
]
|
|
3484
|
+
})
|
|
3485
|
+
});
|
|
3486
|
+
}
|
|
3487
|
+
//#endregion
|
|
3488
|
+
//#region src/components/popover/index.tsx
|
|
3489
|
+
function yr(e) {
|
|
3490
|
+
let { children: t, button: n, closeOnClick: r, className: i = "", orientation: a = "bottomLeft" } = e, [o, s] = u(!1), c = `arkynPopover ${a} ${o ? "visibleTrue" : "visibleFalse"} ${i}`;
|
|
3491
|
+
function l() {
|
|
3492
|
+
o || s(!0);
|
|
3493
|
+
}
|
|
3494
|
+
return it(o), /* @__PURE__ */ m("div", {
|
|
3495
|
+
className: c,
|
|
3496
|
+
onClick: l,
|
|
3497
|
+
children: [
|
|
3498
|
+
n,
|
|
3499
|
+
/* @__PURE__ */ p("div", {
|
|
3500
|
+
style: { visibility: o ? "visible" : "hidden" },
|
|
3501
|
+
onClick: () => r && s(!1),
|
|
3502
|
+
className: "arkynPopoverContent",
|
|
3503
|
+
children: t
|
|
3504
|
+
}),
|
|
3505
|
+
o && /* @__PURE__ */ p("div", {
|
|
3506
|
+
onClick: () => s(!1),
|
|
3507
|
+
className: "arkynPopoverOverlay"
|
|
3508
|
+
})
|
|
3509
|
+
]
|
|
3510
|
+
});
|
|
3511
|
+
}
|
|
3512
|
+
//#endregion
|
|
3513
|
+
//#region src/components/radio/radioContext.tsx
|
|
3514
|
+
var br = n({});
|
|
3515
|
+
function xr(e) {
|
|
3516
|
+
let { children: t, size: n, isError: r, handleChange: i, value: a, disabled: o } = e;
|
|
3517
|
+
return /* @__PURE__ */ p(br.Provider, {
|
|
3518
|
+
value: {
|
|
3519
|
+
handleChange: i,
|
|
3520
|
+
value: a,
|
|
3521
|
+
size: n,
|
|
3522
|
+
isError: r,
|
|
3523
|
+
disabled: o
|
|
3524
|
+
},
|
|
3525
|
+
children: t
|
|
3526
|
+
});
|
|
3527
|
+
}
|
|
3528
|
+
function Sr() {
|
|
3529
|
+
return a(br);
|
|
3530
|
+
}
|
|
3531
|
+
//#endregion
|
|
3532
|
+
//#region src/components/radio/radioBox/index.tsx
|
|
3533
|
+
function Cr(e) {
|
|
3534
|
+
let { value: t, size: n, disabled: r, children: i, className: a = "", onClick: o, onFocus: s, ...c } = e, { handleChange: l, size: u, value: d, isError: f, disabled: h } = Sr(), g = d === t, _ = n || u, v = r || h, y = `arkynRadioBox ${_} ${g ? "checkedTrue" : "checkedFalse"} ${f ? "errorTrue" : "errorFalse"} ${v ? "disabledTrue" : "disabledFalse"} ${a}`;
|
|
3535
|
+
function b(e) {
|
|
3536
|
+
o?.(e), l(t);
|
|
3537
|
+
}
|
|
3538
|
+
function x(e) {
|
|
3539
|
+
s?.(e), l(t);
|
|
3540
|
+
}
|
|
3541
|
+
return /* @__PURE__ */ m("label", {
|
|
3542
|
+
className: y.trim(),
|
|
3543
|
+
children: [/* @__PURE__ */ p("button", {
|
|
3544
|
+
type: "button",
|
|
3545
|
+
disabled: v,
|
|
3546
|
+
onClick: b,
|
|
3547
|
+
onFocus: x,
|
|
3548
|
+
...c
|
|
3549
|
+
}), i]
|
|
3550
|
+
});
|
|
3551
|
+
}
|
|
3552
|
+
//#endregion
|
|
3553
|
+
//#region src/components/radio/radioGroup/index.tsx
|
|
3554
|
+
function wr(e) {
|
|
3555
|
+
let { defaultValue: t = "", name: n, label: r, showAsterisk: i, errorMessage: a, value: o, onChange: s, size: c = "md", className: l = "", disabled: d = !1, unShowFieldTemplate: f = !1, orientation: h = "vertical", ...g } = e, [_, v] = u(t), { fieldErrors: y } = X();
|
|
3556
|
+
function b(e) {
|
|
3557
|
+
v(e), s && s(e);
|
|
3558
|
+
}
|
|
3559
|
+
let x = a || y?.[n], S = !!x, C = `arkynRadioGroup ${c}`;
|
|
3560
|
+
return /* @__PURE__ */ p(Q, {
|
|
3561
|
+
name: n,
|
|
3562
|
+
label: r,
|
|
3563
|
+
showAsterisk: i,
|
|
3564
|
+
className: l,
|
|
3565
|
+
errorMessage: x,
|
|
3566
|
+
unShowFieldTemplate: f,
|
|
3567
|
+
orientation: h,
|
|
3568
|
+
children: /* @__PURE__ */ m(xr, {
|
|
3569
|
+
isError: S,
|
|
3570
|
+
size: c,
|
|
3571
|
+
value: o || _,
|
|
3572
|
+
handleChange: b,
|
|
3573
|
+
disabled: d,
|
|
3574
|
+
children: [/* @__PURE__ */ p("input", {
|
|
3575
|
+
style: { display: "none" },
|
|
3576
|
+
type: "text",
|
|
3577
|
+
readOnly: !0,
|
|
3578
|
+
name: n,
|
|
3579
|
+
value: o || _
|
|
3580
|
+
}), /* @__PURE__ */ p("div", {
|
|
3581
|
+
className: C.trim(),
|
|
3582
|
+
...g
|
|
3583
|
+
})]
|
|
3584
|
+
})
|
|
3585
|
+
});
|
|
3586
|
+
}
|
|
3587
|
+
//#endregion
|
|
3588
|
+
//#region src/services/extractTextFromNode.ts
|
|
3589
|
+
function Tr(e) {
|
|
3590
|
+
return e.map((e) => ue.string(e)).join("");
|
|
3591
|
+
}
|
|
3592
|
+
//#endregion
|
|
3593
|
+
//#region src/services/isMarkActive.ts
|
|
3594
|
+
function Er(e, t) {
|
|
3595
|
+
let n = ce.marks(e);
|
|
3596
|
+
return n ? n[t] === !0 : !1;
|
|
3597
|
+
}
|
|
3598
|
+
//#endregion
|
|
3599
|
+
//#region src/services/toggleMark.ts
|
|
3600
|
+
function Dr(e, t) {
|
|
3601
|
+
Er(e, t) ? ce.removeMark(e, t) : ce.addMark(e, t, !0);
|
|
3602
|
+
}
|
|
3603
|
+
//#endregion
|
|
3604
|
+
//#region src/templates/richTextTemplates.ts
|
|
3605
|
+
var Or = {
|
|
3606
|
+
"mod+b": "bold",
|
|
3607
|
+
"mod+i": "italic",
|
|
3608
|
+
"mod+u": "underline",
|
|
3609
|
+
"mod+`": "code"
|
|
3610
|
+
}, kr = [{
|
|
3611
|
+
type: "paragraph",
|
|
3612
|
+
children: [{ text: "" }]
|
|
3613
|
+
}], Ar = ["listItem", "numberedList"], jr = [
|
|
3614
|
+
"left",
|
|
3615
|
+
"center",
|
|
3616
|
+
"right",
|
|
3617
|
+
"justify"
|
|
3618
|
+
];
|
|
3619
|
+
//#endregion
|
|
3620
|
+
//#region src/services/isBlockActive.ts
|
|
3621
|
+
function Mr(e, t, n = "type") {
|
|
3622
|
+
let { selection: r } = e;
|
|
3623
|
+
if (!r) return !1;
|
|
3624
|
+
let [i] = Array.from(ce.nodes(e, {
|
|
3625
|
+
at: ce.unhangRange(e, r),
|
|
3626
|
+
match: (e) => !ce.isEditor(e) && le.isElement(e) && e[n] === t
|
|
3627
|
+
}));
|
|
3628
|
+
return !!i;
|
|
3629
|
+
}
|
|
3630
|
+
//#endregion
|
|
3631
|
+
//#region src/services/toggleBlock.ts
|
|
3632
|
+
function Nr(e, t) {
|
|
3633
|
+
let n = Mr(e, t, jr.includes(t) ? "align" : "type"), r = Ar.includes(t);
|
|
3634
|
+
fe.unwrapNodes(e, {
|
|
3635
|
+
match: (e) => !ce.isEditor(e) && le.isElement(e) && Ar.includes(e.type) && !jr.includes(t),
|
|
3636
|
+
split: !0
|
|
3637
|
+
});
|
|
3638
|
+
let i;
|
|
3639
|
+
if (i = jr.includes(t) ? { align: n ? void 0 : t } : { type: n ? "paragraph" : r ? "listItem" : t }, fe.setNodes(e, i), !n && r) {
|
|
3640
|
+
let n = {
|
|
3641
|
+
type: t,
|
|
3642
|
+
children: []
|
|
3643
|
+
};
|
|
3644
|
+
fe.wrapNodes(e, n);
|
|
3645
|
+
}
|
|
3646
|
+
}
|
|
3647
|
+
//#endregion
|
|
3648
|
+
//#region src/components/richText/blockButton/index.tsx
|
|
3649
|
+
function Pr({ format: e, icon: t }) {
|
|
3650
|
+
let n = _e(), r = Mr(n, e, jr.includes(e) ? "align" : "type") ? "activeTrue" : "activeFalse";
|
|
3651
|
+
function i(t) {
|
|
3652
|
+
t.preventDefault(), Nr(n, e);
|
|
3653
|
+
}
|
|
3654
|
+
return /* @__PURE__ */ p("button", {
|
|
3655
|
+
type: "button",
|
|
3656
|
+
className: `arkynRichTextBlockButton ${r}`,
|
|
3657
|
+
onMouseDown: i,
|
|
3658
|
+
children: /* @__PURE__ */ p(t, {})
|
|
3659
|
+
});
|
|
3660
|
+
}
|
|
3661
|
+
//#endregion
|
|
3662
|
+
//#region src/components/richText/element/index.tsx
|
|
3663
|
+
function Fr({ attributes: e, children: t, element: n }) {
|
|
3664
|
+
let r = { textAlign: n.align };
|
|
3665
|
+
switch (n.type) {
|
|
3666
|
+
case "blockQuote": return /* @__PURE__ */ p("blockquote", {
|
|
3667
|
+
className: "arkynElementBlockquote",
|
|
3668
|
+
style: r,
|
|
3669
|
+
...e,
|
|
3670
|
+
children: t
|
|
3671
|
+
});
|
|
3672
|
+
case "bulletedList": return /* @__PURE__ */ p("ul", {
|
|
3673
|
+
className: "arkynElementBulletList",
|
|
3674
|
+
style: r,
|
|
3675
|
+
...e,
|
|
3676
|
+
children: t
|
|
3677
|
+
});
|
|
3678
|
+
case "headingOne": return /* @__PURE__ */ p("h1", {
|
|
3679
|
+
className: "arkynElementHeadingOne",
|
|
3680
|
+
style: r,
|
|
3681
|
+
...e,
|
|
3682
|
+
children: t
|
|
3683
|
+
});
|
|
3684
|
+
case "headingTwo": return /* @__PURE__ */ p("h2", {
|
|
3685
|
+
className: "arkynElementHeadingTwo",
|
|
3686
|
+
style: r,
|
|
3687
|
+
...e,
|
|
3688
|
+
children: t
|
|
3689
|
+
});
|
|
3690
|
+
case "listItem": return /* @__PURE__ */ p("li", {
|
|
3691
|
+
className: "arkynElementListItem",
|
|
3692
|
+
style: r,
|
|
3693
|
+
...e,
|
|
3694
|
+
children: t
|
|
3695
|
+
});
|
|
3696
|
+
case "numberedList": return /* @__PURE__ */ p("ol", {
|
|
3697
|
+
className: "arkynElementNumberedList",
|
|
3698
|
+
style: r,
|
|
3699
|
+
...e,
|
|
3700
|
+
children: t
|
|
3701
|
+
});
|
|
3702
|
+
case "image": return /* @__PURE__ */ m("div", {
|
|
3703
|
+
style: r,
|
|
3704
|
+
...e,
|
|
3705
|
+
children: [/* @__PURE__ */ p("img", {
|
|
3706
|
+
className: "arkynElementImage",
|
|
3707
|
+
alt: "arkynElementImage",
|
|
3708
|
+
src: n?.src || ""
|
|
3709
|
+
}), t]
|
|
3710
|
+
});
|
|
3711
|
+
case "video": return /* @__PURE__ */ m("div", {
|
|
3712
|
+
style: r,
|
|
3713
|
+
...e,
|
|
3714
|
+
children: [/* @__PURE__ */ p("iframe", {
|
|
3715
|
+
className: "arkynElementVideo",
|
|
3716
|
+
src: n?.src || "",
|
|
3717
|
+
title: "YouTube video player",
|
|
3718
|
+
allow: "accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture; web-share",
|
|
3719
|
+
referrerPolicy: "strict-origin-when-cross-origin",
|
|
3720
|
+
allowFullScreen: !0
|
|
3721
|
+
}), t]
|
|
3722
|
+
});
|
|
3723
|
+
default: return /* @__PURE__ */ p("p", {
|
|
3724
|
+
className: "arkynElementParagraph",
|
|
3725
|
+
style: r,
|
|
3726
|
+
...e,
|
|
3727
|
+
children: t
|
|
3728
|
+
});
|
|
3729
|
+
}
|
|
3730
|
+
}
|
|
3731
|
+
//#endregion
|
|
3732
|
+
//#region src/components/tab/tabContext.tsx
|
|
3733
|
+
var Ir = n({});
|
|
3734
|
+
function Lr() {
|
|
3735
|
+
return a(Ir);
|
|
3736
|
+
}
|
|
3737
|
+
function Rr(e) {
|
|
3738
|
+
let { disabled: t, currentTab: n, changeCurrentTab: r } = e, i = c(() => ({
|
|
3739
|
+
disabled: t,
|
|
3740
|
+
currentTab: n,
|
|
3741
|
+
changeCurrentTab: r
|
|
3742
|
+
}), [
|
|
3743
|
+
t,
|
|
3744
|
+
n,
|
|
3745
|
+
r
|
|
3746
|
+
]);
|
|
3747
|
+
return /* @__PURE__ */ p(Ir.Provider, {
|
|
3748
|
+
value: i,
|
|
3749
|
+
children: e.children
|
|
3750
|
+
});
|
|
3751
|
+
}
|
|
3752
|
+
//#endregion
|
|
3753
|
+
//#region src/components/tab/tabButton/index.tsx
|
|
3754
|
+
function zr(e) {
|
|
3755
|
+
let { children: t, disabled: n = !1, className: r = "", onClick: i, value: a, ...o } = e, { disabled: s, currentTab: c, changeCurrentTab: l } = Lr(), u = s || n, d = `arkynTabButton ${u ? "isDisabled" : ""} ${c === a && a ? "isActive" : ""} ${r}`;
|
|
3756
|
+
function f(e) {
|
|
3757
|
+
l(a), i?.(e);
|
|
3758
|
+
}
|
|
3759
|
+
return /* @__PURE__ */ p("button", {
|
|
3760
|
+
onClick: f,
|
|
3761
|
+
className: d.trim(),
|
|
3762
|
+
...o,
|
|
3763
|
+
disabled: u,
|
|
3764
|
+
type: "button",
|
|
3765
|
+
children: t
|
|
3766
|
+
});
|
|
3767
|
+
}
|
|
3768
|
+
//#endregion
|
|
3769
|
+
//#region src/components/tab/tabContainer/index.tsx
|
|
3770
|
+
function Br(e) {
|
|
3771
|
+
let { children: t, onChange: n, defaultValue: r, disabled: i = !1, className: a, ...o } = e, [s, c] = u(r || ""), l = `arkynTabContainer ${a || ""}`;
|
|
3772
|
+
function d(e) {
|
|
3773
|
+
c(e), n && n(e);
|
|
3774
|
+
}
|
|
3775
|
+
return /* @__PURE__ */ p(Rr, {
|
|
3776
|
+
disabled: i,
|
|
3777
|
+
currentTab: s,
|
|
3778
|
+
changeCurrentTab: d,
|
|
3779
|
+
children: /* @__PURE__ */ p("nav", {
|
|
3780
|
+
className: l.trim(),
|
|
3781
|
+
...o,
|
|
3782
|
+
children: t
|
|
3783
|
+
})
|
|
3784
|
+
});
|
|
3785
|
+
}
|
|
3786
|
+
//#endregion
|
|
3787
|
+
//#region src/components/richText/insertImage/index.tsx
|
|
3788
|
+
function Vr(e) {
|
|
3789
|
+
let { action: t, tabLabels: n = ["Adicionar URL", "Upload de arquivo"], modalCancelButton: r = "Cancelar", modalConfirmButton: i = "Confirmar", modalInputImageLabel: a = "Imagem:", modalInputUrlLabel: o = "URL da imagem:", modalTitle: s = "Inserir imagem" } = e, c = _e(), [l, d] = u(!1), [h, g] = u(""), [_, v] = u("url");
|
|
3790
|
+
function y(e) {
|
|
3791
|
+
e.preventDefault(), !(!h || h === "") && (c.insertNodes([
|
|
3792
|
+
{
|
|
3793
|
+
type: "paragraph",
|
|
3794
|
+
children: [{ text: "" }]
|
|
3795
|
+
},
|
|
3796
|
+
{
|
|
3797
|
+
type: "image",
|
|
3798
|
+
src: h,
|
|
3799
|
+
children: [{ text: "" }]
|
|
3800
|
+
},
|
|
3801
|
+
{
|
|
3802
|
+
type: "paragraph",
|
|
3803
|
+
children: [{ text: "" }]
|
|
3804
|
+
}
|
|
3805
|
+
]), d(!1));
|
|
3806
|
+
}
|
|
3807
|
+
return /* @__PURE__ */ m(f, { children: [/* @__PURE__ */ p("button", {
|
|
3808
|
+
type: "button",
|
|
3809
|
+
className: "arkynRichTextInsertImage",
|
|
3810
|
+
onMouseDown: () => d(!0),
|
|
3811
|
+
children: /* @__PURE__ */ p(P, {})
|
|
3812
|
+
}), /* @__PURE__ */ m(Vn, {
|
|
3813
|
+
isVisible: l,
|
|
3814
|
+
makeInvisible: () => d(!1),
|
|
3815
|
+
children: [
|
|
3816
|
+
/* @__PURE__ */ p(Un, { children: s }),
|
|
3817
|
+
/* @__PURE__ */ m("div", {
|
|
3818
|
+
className: "arkynRichTextInsertImageModalContent",
|
|
3819
|
+
children: [
|
|
3820
|
+
/* @__PURE__ */ m(Br, {
|
|
3821
|
+
defaultValue: _,
|
|
3822
|
+
onChange: v,
|
|
3823
|
+
children: [/* @__PURE__ */ p(zr, {
|
|
3824
|
+
value: "url",
|
|
3825
|
+
children: n[0]
|
|
3826
|
+
}), /* @__PURE__ */ p(zr, {
|
|
3827
|
+
value: "file",
|
|
3828
|
+
children: n[1]
|
|
3829
|
+
})]
|
|
3830
|
+
}),
|
|
3831
|
+
_ === "url" && /* @__PURE__ */ m(f, { children: [/* @__PURE__ */ p(at, {
|
|
3832
|
+
type: "text",
|
|
3833
|
+
name: "richTextImageURL",
|
|
3834
|
+
label: o,
|
|
3835
|
+
showAsterisk: !0,
|
|
3836
|
+
defaultValue: h,
|
|
3837
|
+
onChange: (e) => g(e.target.value)
|
|
3838
|
+
}), h && /* @__PURE__ */ p("img", {
|
|
3839
|
+
className: "arkynRichTextInsertImageModalPreviewImage",
|
|
3840
|
+
src: h,
|
|
3841
|
+
alt: "preview"
|
|
3842
|
+
})] }),
|
|
3843
|
+
_ === "file" && /* @__PURE__ */ p(Mn, {
|
|
3844
|
+
name: "richTextImageURL",
|
|
3845
|
+
action: t,
|
|
3846
|
+
label: a,
|
|
3847
|
+
showAsterisk: !0,
|
|
3848
|
+
defaultValue: h,
|
|
3849
|
+
onChange: (e) => g(e)
|
|
3850
|
+
})
|
|
3851
|
+
]
|
|
3852
|
+
}),
|
|
3853
|
+
/* @__PURE__ */ m(Hn, { children: [/* @__PURE__ */ p(Be, {
|
|
3854
|
+
type: "button",
|
|
3855
|
+
scheme: "danger",
|
|
3856
|
+
variant: "outline",
|
|
3857
|
+
onClick: () => d(!1),
|
|
3858
|
+
children: r
|
|
3859
|
+
}), /* @__PURE__ */ p(Be, {
|
|
3860
|
+
type: "button",
|
|
3861
|
+
onClick: y,
|
|
3862
|
+
children: i
|
|
3863
|
+
})] })
|
|
3864
|
+
]
|
|
3865
|
+
})] });
|
|
3866
|
+
}
|
|
3867
|
+
//#endregion
|
|
3868
|
+
//#region src/components/richText/insertVideo/index.tsx
|
|
3869
|
+
function Hr(e) {
|
|
3870
|
+
let { modalCancelButton: t = "Cancelar", modalConfirmButton: n = "Confirmar", modalInputUrlLabel: r = "URL do vídeo:", modalTitle: i = "Inserir vídeo", invalidUrlMessage: a = "URL inválida" } = e, s = _e(), [c, l] = u(!1), [d, h] = u(""), [g, _] = u(""), [v, y] = u("");
|
|
3871
|
+
function b(e) {
|
|
3872
|
+
if (e.preventDefault(), !d || d === "") return;
|
|
3873
|
+
let t = `https://www.youtube.com/embed/${d}`;
|
|
3874
|
+
s.insertNodes([
|
|
3875
|
+
{
|
|
3876
|
+
type: "paragraph",
|
|
3877
|
+
children: [{ text: "" }]
|
|
3878
|
+
},
|
|
3879
|
+
{
|
|
3880
|
+
type: "video",
|
|
3881
|
+
src: t,
|
|
3882
|
+
children: [{ text: "" }]
|
|
3883
|
+
},
|
|
3884
|
+
{
|
|
3885
|
+
type: "paragraph",
|
|
3886
|
+
children: [{ text: "" }]
|
|
3887
|
+
}
|
|
3888
|
+
]), l(!1);
|
|
3889
|
+
}
|
|
3890
|
+
return o(() => {
|
|
3891
|
+
if (!g || g === "") return;
|
|
3892
|
+
h(""), y("");
|
|
3893
|
+
let e = new URLSearchParams(g.split("?")[1]).get("v");
|
|
3894
|
+
e ? h(e) : y(a);
|
|
3895
|
+
}, [g, a]), o(() => {
|
|
3896
|
+
c || (h(""), _(""), y(""));
|
|
3897
|
+
}, [c]), /* @__PURE__ */ m(f, { children: [/* @__PURE__ */ p("button", {
|
|
3898
|
+
type: "button",
|
|
3899
|
+
className: "arkynRichTextInsertVideo",
|
|
3900
|
+
onMouseDown: () => l(!0),
|
|
3901
|
+
children: /* @__PURE__ */ p(G, {})
|
|
3902
|
+
}), /* @__PURE__ */ m(Vn, {
|
|
3903
|
+
isVisible: c,
|
|
3904
|
+
makeInvisible: () => l(!1),
|
|
3905
|
+
children: [
|
|
3906
|
+
/* @__PURE__ */ p(Un, { children: i }),
|
|
3907
|
+
/* @__PURE__ */ m("div", {
|
|
3908
|
+
className: "arkynRichTextInsertVideoModalContent",
|
|
3909
|
+
children: [/* @__PURE__ */ p(at, {
|
|
3910
|
+
type: "text",
|
|
3911
|
+
name: "richTextVideoURL",
|
|
3912
|
+
label: r,
|
|
3913
|
+
showAsterisk: !0,
|
|
3914
|
+
defaultValue: g,
|
|
3915
|
+
onChange: (e) => _(e.target.value),
|
|
3916
|
+
errorMessage: v
|
|
3917
|
+
}), d && /* @__PURE__ */ p("iframe", {
|
|
3918
|
+
width: "auto",
|
|
3919
|
+
height: "315",
|
|
3920
|
+
src: `https://www.youtube.com/embed/${d}`,
|
|
3921
|
+
title: "YouTube video player",
|
|
3922
|
+
allow: "accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture; web-share",
|
|
3923
|
+
referrerPolicy: "strict-origin-when-cross-origin",
|
|
3924
|
+
allowFullScreen: !0
|
|
3925
|
+
})]
|
|
3926
|
+
}),
|
|
3927
|
+
/* @__PURE__ */ m(Hn, { children: [/* @__PURE__ */ p(Be, {
|
|
3928
|
+
type: "button",
|
|
3929
|
+
scheme: "danger",
|
|
3930
|
+
variant: "outline",
|
|
3931
|
+
onClick: () => l(!1),
|
|
3932
|
+
children: t
|
|
3933
|
+
}), /* @__PURE__ */ p(Be, {
|
|
3934
|
+
disabled: !d,
|
|
3935
|
+
type: "button",
|
|
3936
|
+
onClick: b,
|
|
3937
|
+
children: n
|
|
3938
|
+
})] })
|
|
3939
|
+
]
|
|
3940
|
+
})] });
|
|
3941
|
+
}
|
|
3942
|
+
//#endregion
|
|
3943
|
+
//#region src/components/richText/leaf/index.tsx
|
|
3944
|
+
function Ur({ attributes: e, children: t, leaf: n }) {
|
|
3945
|
+
return n.bold && (t = /* @__PURE__ */ p("strong", { children: t })), n.code && (t = /* @__PURE__ */ p("code", { children: t })), n.italic && (t = /* @__PURE__ */ p("em", { children: t })), n.underline && (t = /* @__PURE__ */ p("u", { children: t })), /* @__PURE__ */ p("span", {
|
|
3946
|
+
...e,
|
|
3947
|
+
children: t
|
|
3948
|
+
});
|
|
3949
|
+
}
|
|
3950
|
+
//#endregion
|
|
3951
|
+
//#region src/components/richText/markButton/index.tsx
|
|
3952
|
+
function Wr({ format: e, icon: t }) {
|
|
3953
|
+
let n = _e(), r = Er(n, e) ? "activeTrue" : "activeFalse";
|
|
3954
|
+
function i(t) {
|
|
3955
|
+
t.preventDefault(), Dr(n, e);
|
|
3956
|
+
}
|
|
3957
|
+
return /* @__PURE__ */ p("button", {
|
|
3958
|
+
type: "button",
|
|
3959
|
+
className: `arkynRichTextMarkButton ${r}`,
|
|
3960
|
+
onMouseDown: i,
|
|
3961
|
+
children: /* @__PURE__ */ p(t, {})
|
|
3962
|
+
});
|
|
3963
|
+
}
|
|
3964
|
+
//#endregion
|
|
3965
|
+
//#region src/components/richText/toolbar/index.tsx
|
|
3966
|
+
function Gr({ children: e }) {
|
|
3967
|
+
return /* @__PURE__ */ p("div", {
|
|
3968
|
+
className: "arkynRichTextToolbar",
|
|
3969
|
+
children: e
|
|
3970
|
+
});
|
|
3971
|
+
}
|
|
3972
|
+
//#endregion
|
|
3973
|
+
//#region src/components/richText/index.tsx
|
|
3974
|
+
function Kr(e) {
|
|
3975
|
+
let { name: t, hiddenButtons: n, imageConfig: r, videoConfig: a, className: o = "", defaultValue: d = "[]", enforceCharacterLimit: f = !1, onChangeCharactersCount: h, baseErrorMessage: x, maxLimit: S = 1e4, onChange: C, isError: w, label: T, showAsterisk: D, id: O, orientation: k = "vertical", unShowFieldTemplate: A = !1 } = e, j = c(() => me(ve(pe())), []), { fieldErrors: P } = X(), F = c(() => {
|
|
3976
|
+
try {
|
|
3977
|
+
let e = JSON.parse(d);
|
|
3978
|
+
return !Array.isArray(e) || e.length === 0 ? structuredClone(kr) : e.every((e) => typeof e == "object" && !!e && "type" in e && "children" in e) ? e : structuredClone(kr);
|
|
3979
|
+
} catch {
|
|
3980
|
+
return structuredClone(kr);
|
|
3981
|
+
}
|
|
3982
|
+
}, [d]), [L, R] = u(Tr(F).length), [z, B] = u(JSON.stringify(F) || "[]"), [H, U] = u(!1), G = l(null), K = s(), q = O || K, ee = x || P?.[t], J = w || !!ee, te = i(Ur, []), ne = i(Fr, []);
|
|
3983
|
+
function re(e) {
|
|
3984
|
+
let t = Tr(e);
|
|
3985
|
+
R(t.length), h?.(t.length), !(f && t.length >= S) && (B(JSON.stringify(e)), C?.(e));
|
|
3986
|
+
}
|
|
3987
|
+
let ie = `arkynRichText ${J || S < L ? "errorTrue" : "errorFalse"} ${H ? "focusTrue" : "focusFalse"}`, ae = S - L;
|
|
3988
|
+
function Y(e) {
|
|
3989
|
+
return !n?.includes(e);
|
|
3990
|
+
}
|
|
3991
|
+
return /* @__PURE__ */ p(Q, {
|
|
3992
|
+
name: t,
|
|
3993
|
+
label: T,
|
|
3994
|
+
showAsterisk: D,
|
|
3995
|
+
className: o,
|
|
3996
|
+
errorMessage: ee,
|
|
3997
|
+
unShowFieldTemplate: A,
|
|
3998
|
+
orientation: k,
|
|
3999
|
+
children: /* @__PURE__ */ m(ge, {
|
|
4000
|
+
editor: j,
|
|
4001
|
+
initialValue: F,
|
|
4002
|
+
onChange: re,
|
|
4003
|
+
onValueChange: re,
|
|
4004
|
+
children: [
|
|
4005
|
+
/* @__PURE__ */ m("div", {
|
|
4006
|
+
className: ie,
|
|
4007
|
+
children: [
|
|
4008
|
+
/* @__PURE__ */ m(Gr, { children: [
|
|
4009
|
+
Y("headingOne") && /* @__PURE__ */ p(Pr, {
|
|
4010
|
+
format: "headingOne",
|
|
4011
|
+
icon: M
|
|
4012
|
+
}),
|
|
4013
|
+
Y("headingTwo") && /* @__PURE__ */ p(Pr, {
|
|
4014
|
+
format: "headingTwo",
|
|
4015
|
+
icon: N
|
|
4016
|
+
}),
|
|
4017
|
+
Y("blockQuote") && /* @__PURE__ */ p(Pr, {
|
|
4018
|
+
format: "blockQuote",
|
|
4019
|
+
icon: V
|
|
4020
|
+
}),
|
|
4021
|
+
Y("bold") && /* @__PURE__ */ p(Wr, {
|
|
4022
|
+
format: "bold",
|
|
4023
|
+
icon: b
|
|
4024
|
+
}),
|
|
4025
|
+
Y("italic") && /* @__PURE__ */ p(Wr, {
|
|
4026
|
+
format: "italic",
|
|
4027
|
+
icon: I
|
|
4028
|
+
}),
|
|
4029
|
+
Y("underline") && /* @__PURE__ */ p(Wr, {
|
|
4030
|
+
format: "underline",
|
|
4031
|
+
icon: W
|
|
4032
|
+
}),
|
|
4033
|
+
Y("code") && /* @__PURE__ */ p(Wr, {
|
|
4034
|
+
format: "code",
|
|
4035
|
+
icon: E
|
|
4036
|
+
}),
|
|
4037
|
+
Y("left") && /* @__PURE__ */ p(Pr, {
|
|
4038
|
+
format: "left",
|
|
4039
|
+
icon: v
|
|
4040
|
+
}),
|
|
4041
|
+
Y("right") && /* @__PURE__ */ p(Pr, {
|
|
4042
|
+
format: "right",
|
|
4043
|
+
icon: y
|
|
4044
|
+
}),
|
|
4045
|
+
Y("center") && /* @__PURE__ */ p(Pr, {
|
|
4046
|
+
format: "center",
|
|
4047
|
+
icon: g
|
|
4048
|
+
}),
|
|
4049
|
+
Y("justify") && /* @__PURE__ */ p(Pr, {
|
|
4050
|
+
format: "justify",
|
|
4051
|
+
icon: _
|
|
4052
|
+
}),
|
|
4053
|
+
r && Y("image") && /* @__PURE__ */ p(Vr, { ...r }),
|
|
4054
|
+
Y("video") && /* @__PURE__ */ p(Hr, { ...a })
|
|
4055
|
+
] }),
|
|
4056
|
+
/* @__PURE__ */ p(he, {
|
|
4057
|
+
className: "editorContainer",
|
|
4058
|
+
renderElement: ne,
|
|
4059
|
+
renderLeaf: te,
|
|
4060
|
+
spellCheck: !0,
|
|
4061
|
+
ref: G,
|
|
4062
|
+
id: q,
|
|
4063
|
+
onFocus: () => U(!0),
|
|
4064
|
+
onBlur: () => U(!1),
|
|
4065
|
+
onKeyDown: (e) => {
|
|
4066
|
+
for (let t in Or) if (se(t, e)) {
|
|
4067
|
+
e.preventDefault();
|
|
4068
|
+
let n = Or[t];
|
|
4069
|
+
Dr(j, n);
|
|
4070
|
+
}
|
|
4071
|
+
}
|
|
4072
|
+
}),
|
|
4073
|
+
ae < 0 && /* @__PURE__ */ p("div", {
|
|
4074
|
+
className: "restatesCharacters",
|
|
4075
|
+
children: ae
|
|
4076
|
+
})
|
|
4077
|
+
]
|
|
4078
|
+
}),
|
|
4079
|
+
/* @__PURE__ */ p("input", {
|
|
4080
|
+
type: "hidden",
|
|
4081
|
+
name: t,
|
|
4082
|
+
value: z.slice(0, S)
|
|
4083
|
+
}),
|
|
4084
|
+
/* @__PURE__ */ p("input", {
|
|
4085
|
+
type: "hidden",
|
|
4086
|
+
name: `${t}Count`,
|
|
4087
|
+
value: L
|
|
4088
|
+
})
|
|
4089
|
+
]
|
|
4090
|
+
})
|
|
4091
|
+
});
|
|
4092
|
+
}
|
|
4093
|
+
//#endregion
|
|
4094
|
+
//#region src/components/searchPlaces.tsx
|
|
4095
|
+
function qr(e) {
|
|
4096
|
+
let { onChange: t, onPlaceChanged: n, options: r, ...i } = e, [a, o] = u(null);
|
|
4097
|
+
return /* @__PURE__ */ p(ye, {
|
|
4098
|
+
onLoad: (e) => o(e),
|
|
4099
|
+
onPlacesChanged: () => {
|
|
4100
|
+
let e = a?.getPlaces(), t = e ? e[0] : null, r = t?.address_components;
|
|
4101
|
+
function i(e) {
|
|
4102
|
+
let t = r.find((t) => t.types[0] === e);
|
|
4103
|
+
return t ? t.long_name : "";
|
|
4104
|
+
}
|
|
4105
|
+
function o(e) {
|
|
4106
|
+
let t = r.find((t) => t.types[0] === e);
|
|
4107
|
+
return t ? t.short_name : "";
|
|
4108
|
+
}
|
|
4109
|
+
function s(e) {
|
|
4110
|
+
for (let t of e) {
|
|
4111
|
+
let e = r.find((e) => e.types.includes(t));
|
|
4112
|
+
if (e) return e.long_name;
|
|
4113
|
+
}
|
|
4114
|
+
return "";
|
|
4115
|
+
}
|
|
4116
|
+
if (t) {
|
|
4117
|
+
let e = i("route"), r = i("street_number"), a = s([
|
|
4118
|
+
"sublocality_level_1",
|
|
4119
|
+
"sublocality",
|
|
4120
|
+
"neighborhood"
|
|
4121
|
+
]), c = i("administrative_area_level_2"), l = i("administrative_area_level_1"), u = o("administrative_area_level_1"), d = {
|
|
4122
|
+
street: e,
|
|
4123
|
+
city: c,
|
|
4124
|
+
state: l,
|
|
4125
|
+
neighborhood: a,
|
|
4126
|
+
postalCode: s(["postal_code", "postal_code_prefix"]),
|
|
4127
|
+
streetNumber: r,
|
|
4128
|
+
stateShortName: u,
|
|
4129
|
+
coordinates: {
|
|
4130
|
+
lat: t.geometry?.location?.lat(),
|
|
4131
|
+
lng: t.geometry?.location?.lng()
|
|
4132
|
+
}
|
|
4133
|
+
};
|
|
4134
|
+
n?.(d);
|
|
4135
|
+
}
|
|
4136
|
+
},
|
|
4137
|
+
options: r,
|
|
4138
|
+
children: /* @__PURE__ */ p(at, {
|
|
4139
|
+
type: "text",
|
|
4140
|
+
autoComplete: "off",
|
|
4141
|
+
onChange: (e) => t?.(e.target.value),
|
|
4142
|
+
...i
|
|
4143
|
+
})
|
|
4144
|
+
});
|
|
4145
|
+
}
|
|
4146
|
+
//#endregion
|
|
4147
|
+
//#region src/components/switch/index.tsx
|
|
4148
|
+
function Jr(e) {
|
|
4149
|
+
let { label: t, size: n = "lg", defaultChecked: r = !1, checked: i = null, value: a, unCheckedValue: o = "", name: c, className: d = "", onCheck: f, id: m, orientation: h = "horizontalReverse", className: g = "", showAsterisk: _, errorMessage: v, unShowFieldTemplate: y = !1, ...b } = e, x = l(null), S = s(), C = m || S, [w, T] = u(r), E = typeof i == "boolean" ? i : w;
|
|
4150
|
+
function D() {
|
|
4151
|
+
T(!w), f?.(E ? o : a || "checked");
|
|
4152
|
+
}
|
|
4153
|
+
return /* @__PURE__ */ p(Q, {
|
|
4154
|
+
name: c,
|
|
4155
|
+
label: t,
|
|
4156
|
+
showAsterisk: _,
|
|
4157
|
+
className: g,
|
|
4158
|
+
errorMessage: v,
|
|
4159
|
+
unShowFieldTemplate: y,
|
|
4160
|
+
orientation: h,
|
|
4161
|
+
children: /* @__PURE__ */ p("button", {
|
|
4162
|
+
type: "button",
|
|
4163
|
+
onClick: D,
|
|
4164
|
+
className: `arkynSwitch ${E ? "checkedTrue" : "checkedFalse"} ${n} ${d}`,
|
|
4165
|
+
...b,
|
|
4166
|
+
children: /* @__PURE__ */ p("input", {
|
|
4167
|
+
id: C,
|
|
4168
|
+
type: "hidden",
|
|
4169
|
+
name: c,
|
|
4170
|
+
ref: x,
|
|
4171
|
+
onClick: D,
|
|
4172
|
+
value: E ? a || "checked" : o
|
|
4173
|
+
})
|
|
4174
|
+
})
|
|
4175
|
+
});
|
|
4176
|
+
}
|
|
4177
|
+
//#endregion
|
|
4178
|
+
//#region src/components/table/tableBody/index.tsx
|
|
4179
|
+
function Yr(t) {
|
|
4180
|
+
let { emptyMessage: n = "Nenhum dado adicionado.", className: r, children: i, ...a } = t, o = `arkynTableBody ${r}`, s = e.toArray(i).filter(Boolean), c = s.length === 0;
|
|
4181
|
+
return /* @__PURE__ */ p("tbody", {
|
|
4182
|
+
className: o.trim(),
|
|
4183
|
+
...a,
|
|
4184
|
+
children: c ? /* @__PURE__ */ p("tr", {
|
|
4185
|
+
className: "arkynTableBodyEmptyLine",
|
|
4186
|
+
children: /* @__PURE__ */ p("td", {
|
|
4187
|
+
colSpan: 100,
|
|
4188
|
+
children: /* @__PURE__ */ p("div", { children: n })
|
|
4189
|
+
})
|
|
4190
|
+
}) : s
|
|
4191
|
+
});
|
|
4192
|
+
}
|
|
4193
|
+
//#endregion
|
|
4194
|
+
//#region src/components/table/tableCaption/index.tsx
|
|
4195
|
+
function Xr(e) {
|
|
4196
|
+
let { className: t, children: n, ...r } = e;
|
|
4197
|
+
return /* @__PURE__ */ p("caption", {
|
|
4198
|
+
className: `arkynTableCaption ${t}`.trim(),
|
|
4199
|
+
...r,
|
|
4200
|
+
children: /* @__PURE__ */ p("div", {
|
|
4201
|
+
className: "arkynTableCaptionContent",
|
|
4202
|
+
children: n
|
|
4203
|
+
})
|
|
4204
|
+
});
|
|
4205
|
+
}
|
|
4206
|
+
//#endregion
|
|
4207
|
+
//#region src/components/table/tableContainer/index.tsx
|
|
4208
|
+
function Zr(e) {
|
|
4209
|
+
let { children: t, className: n, ...r } = e;
|
|
4210
|
+
return /* @__PURE__ */ p("div", {
|
|
4211
|
+
className: `arkynTableContainer ${n}`.trim(),
|
|
4212
|
+
...r,
|
|
4213
|
+
children: /* @__PURE__ */ p("table", { children: t })
|
|
4214
|
+
});
|
|
4215
|
+
}
|
|
4216
|
+
//#endregion
|
|
4217
|
+
//#region src/components/table/tableFooter/index.tsx
|
|
4218
|
+
function Qr(e) {
|
|
4219
|
+
let { className: t, children: n, ...r } = e;
|
|
4220
|
+
return /* @__PURE__ */ m("tfoot", {
|
|
4221
|
+
className: `arkynTableFooter ${t}`.trim(),
|
|
4222
|
+
...r,
|
|
4223
|
+
children: [/* @__PURE__ */ p("tr", { className: "spacingRow" }), /* @__PURE__ */ p("tr", { children: /* @__PURE__ */ p("th", {
|
|
4224
|
+
colSpan: 100,
|
|
4225
|
+
children: /* @__PURE__ */ p("div", {
|
|
4226
|
+
className: "arkynTableFooterContent",
|
|
4227
|
+
children: n
|
|
4228
|
+
})
|
|
4229
|
+
}) })]
|
|
4230
|
+
});
|
|
4231
|
+
}
|
|
4232
|
+
//#endregion
|
|
4233
|
+
//#region src/components/table/tableHeader/index.tsx
|
|
4234
|
+
function $r(e) {
|
|
4235
|
+
let { className: t, children: n, ...r } = e;
|
|
4236
|
+
return /* @__PURE__ */ m("thead", {
|
|
4237
|
+
className: `arkynTableHeader ${t}`.trim(),
|
|
4238
|
+
...r,
|
|
4239
|
+
children: [/* @__PURE__ */ p("tr", { children: n }), /* @__PURE__ */ p("tr", { className: "spacingRow" })]
|
|
4240
|
+
});
|
|
4241
|
+
}
|
|
4242
|
+
//#endregion
|
|
4243
|
+
//#region src/components/textarea/index.tsx
|
|
4244
|
+
function ei(e) {
|
|
4245
|
+
let { variant: t = "solid", size: n = "md", className: r, errorMessage: i, disabled: a = !1, readOnly: o = !1, label: c, showAsterisk: d, name: f, onFocus: h, onBlur: g, title: _, style: v, value: y, defaultValue: b, placeholder: x, id: S, ...C } = e, { fieldErrors: w } = X(), [T, E] = u(!1), D = l(null), O = s(), k = S || O, A = i || w?.[f], j = `arkynTextarea ${t} ${n} ${a || o ? "opacityTrue" : "opacityFalse"} ${A ? "errorTrue" : "errorFalse"} ${T ? "focusedTrue" : "focusedFalse"}`, M = a ? void 0 : y;
|
|
4246
|
+
function N() {
|
|
4247
|
+
a || !D?.current || (E(!0), D.current.focus());
|
|
4248
|
+
}
|
|
4249
|
+
function P(e) {
|
|
4250
|
+
E(!0), h && h(e);
|
|
4251
|
+
}
|
|
4252
|
+
function F(e) {
|
|
4253
|
+
E(!1), g && g(e);
|
|
4254
|
+
}
|
|
4255
|
+
return /* @__PURE__ */ m(ze, {
|
|
4256
|
+
className: r,
|
|
4257
|
+
children: [
|
|
4258
|
+
c && /* @__PURE__ */ p(Re, {
|
|
4259
|
+
htmlFor: k,
|
|
4260
|
+
showAsterisk: d,
|
|
4261
|
+
children: c
|
|
4262
|
+
}),
|
|
4263
|
+
/* @__PURE__ */ p("section", {
|
|
4264
|
+
title: _,
|
|
4265
|
+
style: v,
|
|
4266
|
+
onClick: N,
|
|
4267
|
+
className: j,
|
|
4268
|
+
children: /* @__PURE__ */ p("textarea", {
|
|
4269
|
+
id: k,
|
|
4270
|
+
disabled: a,
|
|
4271
|
+
readOnly: o,
|
|
4272
|
+
ref: D,
|
|
4273
|
+
name: f,
|
|
4274
|
+
onFocus: P,
|
|
4275
|
+
onBlur: F,
|
|
4276
|
+
defaultValue: M === void 0 ? b || "" : void 0,
|
|
4277
|
+
placeholder: a && y || x,
|
|
4278
|
+
value: M,
|
|
4279
|
+
...C
|
|
4280
|
+
})
|
|
4281
|
+
}),
|
|
4282
|
+
A && /* @__PURE__ */ p(Le, { children: A })
|
|
4283
|
+
]
|
|
4284
|
+
});
|
|
4285
|
+
}
|
|
4286
|
+
//#endregion
|
|
4287
|
+
//#region src/templates/badResponses.ts
|
|
4288
|
+
var ti = [
|
|
4289
|
+
"BadGateway",
|
|
4290
|
+
"BadRequest",
|
|
4291
|
+
"Conflict",
|
|
4292
|
+
"Forbidden",
|
|
4293
|
+
"NotFound",
|
|
4294
|
+
"NotImplemented",
|
|
4295
|
+
"ServerError",
|
|
4296
|
+
"Unauthorized",
|
|
4297
|
+
"UnprocessableEntity"
|
|
4298
|
+
], ni = [
|
|
4299
|
+
"Created",
|
|
4300
|
+
"Found",
|
|
4301
|
+
"Success",
|
|
4302
|
+
"Updated"
|
|
4303
|
+
], ri = n({});
|
|
4304
|
+
function ii(e) {
|
|
4305
|
+
let { children: t = !1 } = e, [n, r] = u([]), a = i((e) => n.some((t) => t.key === e), [n]), o = i((e) => n.find((t) => t.key === e)?.data, [n]), s = i((e, t) => {
|
|
4306
|
+
r((n) => [...n.filter((t) => t.key !== e), {
|
|
4307
|
+
key: e,
|
|
4308
|
+
data: t
|
|
4309
|
+
}]);
|
|
4310
|
+
}, []), l = i((e) => {
|
|
4311
|
+
r((t) => t.filter((t) => t.key !== e));
|
|
4312
|
+
}, []), d = i(() => {
|
|
4313
|
+
r([]);
|
|
4314
|
+
}, []), f = c(() => ({
|
|
4315
|
+
modalIsOpen: a,
|
|
4316
|
+
modalData: o,
|
|
4317
|
+
openModal: s,
|
|
4318
|
+
closeModal: l,
|
|
4319
|
+
closeAll: d
|
|
4320
|
+
}), [
|
|
4321
|
+
a,
|
|
4322
|
+
o,
|
|
4323
|
+
s,
|
|
4324
|
+
l,
|
|
4325
|
+
d
|
|
4326
|
+
]);
|
|
4327
|
+
return /* @__PURE__ */ p(ri.Provider, {
|
|
4328
|
+
value: f,
|
|
4329
|
+
children: t
|
|
4330
|
+
});
|
|
4331
|
+
}
|
|
4332
|
+
//#endregion
|
|
4333
|
+
//#region src/hooks/useModal.ts
|
|
4334
|
+
function ai(e) {
|
|
4335
|
+
let t = a(ri);
|
|
4336
|
+
if (Object.entries(t).length === 0) throw Error("useModal must be used within a Provider");
|
|
4337
|
+
if (e) {
|
|
4338
|
+
let { modalData: n, modalIsOpen: r, openModal: i, closeModal: a } = t;
|
|
4339
|
+
return {
|
|
4340
|
+
modalIsOpen: r(e),
|
|
4341
|
+
modalData: n(e),
|
|
4342
|
+
openModal: (t) => i(e, t),
|
|
4343
|
+
closeModal: () => a(e)
|
|
4344
|
+
};
|
|
4345
|
+
} else return t;
|
|
4346
|
+
}
|
|
4347
|
+
//#endregion
|
|
4348
|
+
//#region src/providers/toastProvider.tsx
|
|
4349
|
+
var oi = n({});
|
|
4350
|
+
function si(e) {
|
|
4351
|
+
switch (e.type) {
|
|
4352
|
+
case "success": return Se.success(e.message, {
|
|
4353
|
+
style: {
|
|
4354
|
+
background: "#10B981",
|
|
4355
|
+
color: "#ffffff",
|
|
4356
|
+
padding: "12px 16px",
|
|
4357
|
+
fontSize: "14px",
|
|
4358
|
+
fontWeight: 600
|
|
4359
|
+
},
|
|
4360
|
+
iconTheme: {
|
|
4361
|
+
primary: "#059669",
|
|
4362
|
+
secondary: "#ffffff"
|
|
4363
|
+
}
|
|
4364
|
+
});
|
|
4365
|
+
case "danger": return Se.error(e.message, {
|
|
4366
|
+
style: {
|
|
4367
|
+
background: "#E11D48",
|
|
4368
|
+
color: "#ffffff",
|
|
4369
|
+
padding: "12px 16px",
|
|
4370
|
+
fontSize: "14px",
|
|
4371
|
+
fontWeight: 600
|
|
4372
|
+
},
|
|
4373
|
+
iconTheme: {
|
|
4374
|
+
primary: "#BE123C",
|
|
4375
|
+
secondary: "#ffffff"
|
|
4376
|
+
}
|
|
4377
|
+
});
|
|
4378
|
+
}
|
|
4379
|
+
}
|
|
4380
|
+
function ci({ children: e }) {
|
|
4381
|
+
let t = c(() => ({ showToast: si }), []);
|
|
4382
|
+
return /* @__PURE__ */ m(oi.Provider, {
|
|
4383
|
+
value: t,
|
|
4384
|
+
children: [/* @__PURE__ */ p(Ce, {
|
|
4385
|
+
position: "top-right",
|
|
4386
|
+
containerStyle: { zIndex: 999999999999999 }
|
|
4387
|
+
}), e]
|
|
4388
|
+
});
|
|
4389
|
+
}
|
|
4390
|
+
//#endregion
|
|
4391
|
+
//#region src/hooks/useToast.ts
|
|
4392
|
+
function li() {
|
|
4393
|
+
let e = a(oi);
|
|
4394
|
+
if (Object.entries(e).length === 0) throw Error("useToast must be used within a Provider");
|
|
4395
|
+
return e;
|
|
4396
|
+
}
|
|
4397
|
+
//#endregion
|
|
4398
|
+
//#region src/hooks/useAutomation.ts
|
|
4399
|
+
function ui(e) {
|
|
4400
|
+
let { closeAll: t } = ai(), { showToast: n } = li(), r = e?.closeModal, a = e?.message, s = e?.name, c = e?.cause?.data?.scrollTo, l = e?.cause?.fieldErrors ? Object.values(e?.cause?.fieldErrors)[0] : null, u = i(() => {
|
|
4401
|
+
if (!(!a && !l)) {
|
|
4402
|
+
if (ni.includes(s)) return n({
|
|
4403
|
+
message: a,
|
|
4404
|
+
type: "success"
|
|
4405
|
+
});
|
|
4406
|
+
if (ti.includes(s)) {
|
|
4407
|
+
if (l) return n({
|
|
4408
|
+
message: l,
|
|
4409
|
+
type: "danger"
|
|
4410
|
+
});
|
|
4411
|
+
if (a !== "Unprocessable entity") return n({
|
|
4412
|
+
message: a,
|
|
4413
|
+
type: "danger"
|
|
4414
|
+
});
|
|
4415
|
+
}
|
|
4416
|
+
}
|
|
4417
|
+
}, [
|
|
4418
|
+
a,
|
|
4419
|
+
l,
|
|
4420
|
+
s,
|
|
4421
|
+
n
|
|
4422
|
+
]);
|
|
4423
|
+
o(() => {
|
|
4424
|
+
r && t(), c && xe.scrollTo(c, {
|
|
4425
|
+
smooth: !0,
|
|
4426
|
+
offset: 20
|
|
4427
|
+
}), u();
|
|
4428
|
+
}, [
|
|
4429
|
+
r,
|
|
4430
|
+
c,
|
|
4431
|
+
u,
|
|
4432
|
+
t
|
|
4433
|
+
]);
|
|
4434
|
+
}
|
|
4435
|
+
//#endregion
|
|
4436
|
+
//#region src/providers/drawerProvider.tsx
|
|
4437
|
+
var di = n({});
|
|
4438
|
+
function fi(e) {
|
|
4439
|
+
let { children: t = !1 } = e, [n, r] = u([]);
|
|
4440
|
+
function i(e) {
|
|
4441
|
+
return !!n.some((t) => t.key === e);
|
|
4442
|
+
}
|
|
4443
|
+
function a(e) {
|
|
4444
|
+
return n.find((t) => t.key === e)?.data;
|
|
4445
|
+
}
|
|
4446
|
+
function o(e, t) {
|
|
4447
|
+
i(e) ? r((n) => [...n.filter((t) => t.key !== e), {
|
|
4448
|
+
key: e,
|
|
4449
|
+
data: t
|
|
4450
|
+
}]) : r([...n, {
|
|
4451
|
+
key: e,
|
|
4452
|
+
data: t
|
|
4453
|
+
}]);
|
|
4454
|
+
}
|
|
4455
|
+
function s(e) {
|
|
4456
|
+
r(n.filter((t) => t.key !== e));
|
|
4457
|
+
}
|
|
4458
|
+
return /* @__PURE__ */ p(di.Provider, {
|
|
4459
|
+
value: {
|
|
4460
|
+
drawerIsOpen: i,
|
|
4461
|
+
drawerData: a,
|
|
4462
|
+
openDrawer: o,
|
|
4463
|
+
closeDrawer: s
|
|
4464
|
+
},
|
|
4465
|
+
children: t
|
|
4466
|
+
});
|
|
4467
|
+
}
|
|
4468
|
+
//#endregion
|
|
4469
|
+
//#region src/hooks/useDrawer.ts
|
|
4470
|
+
function pi(e) {
|
|
4471
|
+
let t = a(di);
|
|
4472
|
+
if (Object.entries(t).length === 0) throw Error("useDrawer must be used within a Provider");
|
|
4473
|
+
if (e) {
|
|
4474
|
+
let { drawerData: n, drawerIsOpen: r, openDrawer: i, closeDrawer: a } = t;
|
|
4475
|
+
return {
|
|
4476
|
+
drawerIsOpen: r(e),
|
|
4477
|
+
drawerData: n(e),
|
|
4478
|
+
openDrawer: (t) => i(e, t),
|
|
4479
|
+
closeDrawer: () => a(e)
|
|
4480
|
+
};
|
|
4481
|
+
} else return t;
|
|
4482
|
+
}
|
|
4483
|
+
//#endregion
|
|
4484
|
+
//#region src/hooks/useScopedParams.ts
|
|
4485
|
+
function mi(e, t = "") {
|
|
4486
|
+
let n = new URLSearchParams(e), r = t ? `${t}:` : "", i = (e) => {
|
|
4487
|
+
Object.entries(e).forEach(([e, t]) => {
|
|
4488
|
+
t === void 0 ? n.delete(`${r}${e}`) : n.set(`${r}${e}`, String(t));
|
|
4489
|
+
});
|
|
4490
|
+
};
|
|
4491
|
+
return {
|
|
4492
|
+
getParam: (e) => n.get(`${r}${e}`),
|
|
4493
|
+
getScopedSearch: (e) => {
|
|
4494
|
+
i(e);
|
|
4495
|
+
let t = n.toString();
|
|
4496
|
+
return t &&= `?${t}`, t;
|
|
4497
|
+
}
|
|
4498
|
+
};
|
|
4499
|
+
}
|
|
4500
|
+
//#endregion
|
|
4501
|
+
//#region src/hooks/useSearchAutomation.ts
|
|
4502
|
+
function hi(e, t = "") {
|
|
4503
|
+
let { closeAll: n } = ai(), { showToast: r } = li(), { getParam: i } = mi(e, t), a = i("closeModal") === "true", s = i("message"), c = i("name"), l = i("type");
|
|
4504
|
+
o(() => {
|
|
4505
|
+
a && n(), s && (l === "success" && r({
|
|
4506
|
+
message: s,
|
|
4507
|
+
type: "success"
|
|
4508
|
+
}), l === "danger" && r({
|
|
4509
|
+
message: s,
|
|
4510
|
+
type: "danger"
|
|
4511
|
+
}), c && ti.includes(c) && !ti.includes(s) && r({
|
|
4512
|
+
message: s,
|
|
4513
|
+
type: "danger"
|
|
4514
|
+
}), c && ni.includes(c) && !ni.includes(s) && r({
|
|
4515
|
+
message: s,
|
|
4516
|
+
type: "success"
|
|
4517
|
+
}));
|
|
4518
|
+
}, [
|
|
4519
|
+
a,
|
|
4520
|
+
s,
|
|
4521
|
+
c,
|
|
4522
|
+
l,
|
|
4523
|
+
r,
|
|
4524
|
+
n
|
|
4525
|
+
]);
|
|
4526
|
+
}
|
|
4527
|
+
//#endregion
|
|
4528
|
+
//#region src/providers/placesProvider.tsx
|
|
4529
|
+
var gi = [
|
|
4530
|
+
"places",
|
|
4531
|
+
"marker",
|
|
4532
|
+
"maps"
|
|
4533
|
+
];
|
|
4534
|
+
function _i(e) {
|
|
4535
|
+
let { apiKey: t, children: n, preventFontsLoading: r = !0 } = e, { isLoaded: i } = be({
|
|
4536
|
+
googleMapsApiKey: t,
|
|
4537
|
+
libraries: gi,
|
|
4538
|
+
preventGoogleFontsLoading: r
|
|
4539
|
+
});
|
|
4540
|
+
return /* @__PURE__ */ p(f, { children: n(i) });
|
|
4541
|
+
}
|
|
4542
|
+
//#endregion
|
|
4543
|
+
//#region src/utils/richTextUtilities.ts
|
|
4544
|
+
function vi(e) {
|
|
4545
|
+
if (de.isText(e)) {
|
|
4546
|
+
let t = e?.text;
|
|
4547
|
+
return e?.bold && (t = `<strong>${t}</strong>`), e?.code && (t = `<code>${t}</code>`), e?.italic && (t = `<em>${t}</em>`), e?.underline && (t = `<u>${t}</u>`), t;
|
|
4548
|
+
}
|
|
4549
|
+
if (le.isElement(e)) {
|
|
4550
|
+
let t = e.children?.map((e) => vi(e)).join(""), n = e.align || "left";
|
|
4551
|
+
switch (e.type) {
|
|
4552
|
+
case "video": return `<iframe src="${e.src}" class="align_${n}" />`;
|
|
4553
|
+
case "image": return `<img src="${e.src}" class="align_${n}" />`;
|
|
4554
|
+
case "paragraph": return `<p class="align_${n}">${t}</p>`;
|
|
4555
|
+
case "blockQuote": return `<blockquote class="align_${n}">${t}</blockquote>`;
|
|
4556
|
+
case "bulletedList": return `<ul class="align_${n}">${t}</ul>`;
|
|
4557
|
+
case "headingOne": return `<h1 class="align_${n}">${t}</h1>`;
|
|
4558
|
+
case "headingTwo": return `<h2 class="align_${n}">${t}</h2>`;
|
|
4559
|
+
case "listItem": return `<li class="align_${n}">${t}</li>`;
|
|
4560
|
+
case "numberedList": return `<ol class="align_${n}">${t}</ol>`;
|
|
4561
|
+
default: return "";
|
|
4562
|
+
}
|
|
4563
|
+
}
|
|
4564
|
+
return "";
|
|
4565
|
+
}
|
|
4566
|
+
function yi(e) {
|
|
4567
|
+
if (typeof e == "string") return { text: e };
|
|
4568
|
+
let t = Array.isArray(e.props.children) ? e.props.children.map((e) => yi(e)) : [{ text: e.props.children || "" }], n = e.props.className?.replace("align_", "");
|
|
4569
|
+
switch (e.type) {
|
|
4570
|
+
case "img": return {
|
|
4571
|
+
type: "image",
|
|
4572
|
+
align: n,
|
|
4573
|
+
src: e.props.src,
|
|
4574
|
+
children: [{ text: "" }]
|
|
4575
|
+
};
|
|
4576
|
+
case "p": return {
|
|
4577
|
+
type: "paragraph",
|
|
4578
|
+
align: n,
|
|
4579
|
+
children: t
|
|
4580
|
+
};
|
|
4581
|
+
case "blockquote": return {
|
|
4582
|
+
type: "blockQuote",
|
|
4583
|
+
align: n,
|
|
4584
|
+
children: t
|
|
4585
|
+
};
|
|
4586
|
+
case "ul": return {
|
|
4587
|
+
type: "bulletedList",
|
|
4588
|
+
align: n,
|
|
4589
|
+
children: t
|
|
4590
|
+
};
|
|
4591
|
+
case "ol": return {
|
|
4592
|
+
type: "numberedList",
|
|
4593
|
+
align: n,
|
|
4594
|
+
children: t
|
|
4595
|
+
};
|
|
4596
|
+
case "li": return {
|
|
4597
|
+
type: "listItem",
|
|
4598
|
+
align: n,
|
|
4599
|
+
children: t
|
|
4600
|
+
};
|
|
4601
|
+
case "h1": return {
|
|
4602
|
+
type: "headingOne",
|
|
4603
|
+
align: n,
|
|
4604
|
+
children: t
|
|
4605
|
+
};
|
|
4606
|
+
case "h2": return {
|
|
4607
|
+
type: "headingTwo",
|
|
4608
|
+
align: n,
|
|
4609
|
+
children: t
|
|
4610
|
+
};
|
|
4611
|
+
case "strong": return {
|
|
4612
|
+
text: e.props.children,
|
|
4613
|
+
bold: !0
|
|
4614
|
+
};
|
|
4615
|
+
case "code": return {
|
|
4616
|
+
text: e.props.children,
|
|
4617
|
+
code: !0
|
|
4618
|
+
};
|
|
4619
|
+
case "em": return {
|
|
4620
|
+
text: e.props.children,
|
|
4621
|
+
italic: !0
|
|
4622
|
+
};
|
|
4623
|
+
case "u": return {
|
|
4624
|
+
text: e.props.children,
|
|
4625
|
+
underline: !0
|
|
4626
|
+
};
|
|
4627
|
+
default: return { text: e.props.children || "" };
|
|
4628
|
+
}
|
|
4629
|
+
}
|
|
4630
|
+
//#endregion
|
|
4631
|
+
//#region src/services/toHtml.ts
|
|
4632
|
+
function bi(e) {
|
|
4633
|
+
return e.map((e) => vi(e)).join("");
|
|
4634
|
+
}
|
|
4635
|
+
//#endregion
|
|
4636
|
+
//#region src/services/toRichTextValue.ts
|
|
4637
|
+
function xi(e) {
|
|
4638
|
+
let t = we(e);
|
|
4639
|
+
return Array.isArray(t) ? t.map((e) => typeof e == "string" ? { text: e } : yi(e)) : typeof t == "string" ? [{ text: t }] : [yi(t)];
|
|
4640
|
+
}
|
|
4641
|
+
//#endregion
|
|
4642
|
+
export { Oe as AlertContainer, ke as AlertContent, Ae as AlertDescription, je as AlertIcon, Te as AlertTitle, Pe as AudioPlayer, Ke as AudioUpload, qe as Badge, Be as Button, ht as Calendar, yt as CardTabButton, bt as CardTabContainer, xt as Checkbox, wt as ClientOnly, Dt as CurrencyInput, It as DatePicker, Ve as Divider, Bt as DrawerContainer, Vt as DrawerHeader, fi as DrawerProvider, Wt as FacebookPixel, Le as FieldError, Re as FieldLabel, ze as FieldWrapper, qt as FileUpload, Ie as FormProvider, bn as FullCalendar, wn as GoogleAnalytics, kn as GoogleTagManager, He as IconButton, Mn as ImageUpload, at as Input, Fn as MapView, Ln as MaskedInput, Vn as ModalContainer, Hn as ModalFooter, Un as ModalHeader, ii as ModalProvider, Qn as MultiSelect, ir as Pagination, vr as PhoneInput, _i as PlacesProvider, yr as Popover, Cr as RadioBox, wr as RadioGroup, Kr as RichText, qr as SearchPlaces, lt as Select, Ne as Slider, Jr as Switch, zr as TabButton, Br as TabContainer, Yr as TableBody, Xr as TableCaption, Zr as TableContainer, Qr as TableFooter, $r as TableHeader, ei as Textarea, ci as ToastProvider, Ue as Tooltip, bi as toHtml, xi as toRichTextValue, ui as useAutomation, pi as useDrawer, X as useForm, Ct as useHydrated, ai as useModal, mi as useScopedParams, it as useScrollLock, hi as useSearchAutomation, Me as useSlider, li as useToast };
|
|
4643
|
+
|
|
4644
|
+
//# sourceMappingURL=index.js.map
|