ncore-ui-kit 1.0.0-pre-alpha.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +20 -0
- package/README.md +2 -0
- package/lib/module/assets/fonts/Geist-Black.ttf +0 -0
- package/lib/module/assets/fonts/Geist-Bold.ttf +0 -0
- package/lib/module/assets/fonts/Geist-ExtraBold.ttf +0 -0
- package/lib/module/assets/fonts/Geist-ExtraLight.ttf +0 -0
- package/lib/module/assets/fonts/Geist-Light.ttf +0 -0
- package/lib/module/assets/fonts/Geist-Medium.ttf +0 -0
- package/lib/module/assets/fonts/Geist-Regular.ttf +0 -0
- package/lib/module/assets/fonts/Geist-SemiBold.ttf +0 -0
- package/lib/module/assets/fonts/Geist-Thin.ttf +0 -0
- package/lib/module/assets/svg/badgeAlertIcon/index.js +33 -0
- package/lib/module/assets/svg/badgeAlertIcon/index.js.map +1 -0
- package/lib/module/assets/svg/badgeDangerIcon/index.js +32 -0
- package/lib/module/assets/svg/badgeDangerIcon/index.js.map +1 -0
- package/lib/module/assets/svg/badgeInfoIcon/index.js +32 -0
- package/lib/module/assets/svg/badgeInfoIcon/index.js.map +1 -0
- package/lib/module/assets/svg/badgeQuestionMarkIcon/index.js +40 -0
- package/lib/module/assets/svg/badgeQuestionMarkIcon/index.js.map +1 -0
- package/lib/module/assets/svg/badgeRightIcon/index.js +32 -0
- package/lib/module/assets/svg/badgeRightIcon/index.js.map +1 -0
- package/lib/module/assets/svg/badgeSuccessIcon/index.js +40 -0
- package/lib/module/assets/svg/badgeSuccessIcon/index.js.map +1 -0
- package/lib/module/assets/svg/chevronRightIcon/index.js +32 -0
- package/lib/module/assets/svg/chevronRightIcon/index.js.map +1 -0
- package/lib/module/assets/svg/cleanIcon/index.js +32 -0
- package/lib/module/assets/svg/cleanIcon/index.js.map +1 -0
- package/lib/module/assets/svg/eyeClosedIcon/index.js +40 -0
- package/lib/module/assets/svg/eyeClosedIcon/index.js.map +1 -0
- package/lib/module/assets/svg/eyeOpenedIcon/index.js +40 -0
- package/lib/module/assets/svg/eyeOpenedIcon/index.js.map +1 -0
- package/lib/module/assets/svg/index.js +13 -0
- package/lib/module/assets/svg/index.js.map +1 -0
- package/lib/module/assets/svg/loadingIcon/index.js +65 -0
- package/lib/module/assets/svg/loadingIcon/index.js.map +1 -0
- package/lib/module/components/bottomSheet/index.js +915 -0
- package/lib/module/components/bottomSheet/index.js.map +1 -0
- package/lib/module/components/bottomSheet/stylesheet.js +26 -0
- package/lib/module/components/bottomSheet/stylesheet.js.map +1 -0
- package/lib/module/components/bottomSheet/type.js +4 -0
- package/lib/module/components/bottomSheet/type.js.map +1 -0
- package/lib/module/components/button/index.js +143 -0
- package/lib/module/components/button/index.js.map +1 -0
- package/lib/module/components/button/stylesheet.js +231 -0
- package/lib/module/components/button/stylesheet.js.map +1 -0
- package/lib/module/components/button/type.js +4 -0
- package/lib/module/components/button/type.js.map +1 -0
- package/lib/module/components/checkBox/index.js +186 -0
- package/lib/module/components/checkBox/index.js.map +1 -0
- package/lib/module/components/checkBox/stylesheet.js +182 -0
- package/lib/module/components/checkBox/stylesheet.js.map +1 -0
- package/lib/module/components/checkBox/type.js +4 -0
- package/lib/module/components/checkBox/type.js.map +1 -0
- package/lib/module/components/chip/index.js +131 -0
- package/lib/module/components/chip/index.js.map +1 -0
- package/lib/module/components/chip/stylesheet.js +134 -0
- package/lib/module/components/chip/stylesheet.js.map +1 -0
- package/lib/module/components/chip/type.js +4 -0
- package/lib/module/components/chip/type.js.map +1 -0
- package/lib/module/components/dateSelector/index.js +293 -0
- package/lib/module/components/dateSelector/index.js.map +1 -0
- package/lib/module/components/dateSelector/stylesheet.js +82 -0
- package/lib/module/components/dateSelector/stylesheet.js.map +1 -0
- package/lib/module/components/dateSelector/type.js +7 -0
- package/lib/module/components/dateSelector/type.js.map +1 -0
- package/lib/module/components/dateSelector/util.js +17 -0
- package/lib/module/components/dateSelector/util.js.map +1 -0
- package/lib/module/components/dateTimePicker/index.js +704 -0
- package/lib/module/components/dateTimePicker/index.js.map +1 -0
- package/lib/module/components/dateTimePicker/stylesheet.js +213 -0
- package/lib/module/components/dateTimePicker/stylesheet.js.map +1 -0
- package/lib/module/components/dateTimePicker/type.js +5 -0
- package/lib/module/components/dateTimePicker/type.js.map +1 -0
- package/lib/module/components/dateTimeSheet/index.js +313 -0
- package/lib/module/components/dateTimeSheet/index.js.map +1 -0
- package/lib/module/components/dateTimeSheet/stylesheet.js +88 -0
- package/lib/module/components/dateTimeSheet/stylesheet.js.map +1 -0
- package/lib/module/components/dateTimeSheet/type.js +5 -0
- package/lib/module/components/dateTimeSheet/type.js.map +1 -0
- package/lib/module/components/dialog/index.js +228 -0
- package/lib/module/components/dialog/index.js.map +1 -0
- package/lib/module/components/dialog/stylesheet.js +99 -0
- package/lib/module/components/dialog/stylesheet.js.map +1 -0
- package/lib/module/components/dialog/type.js +5 -0
- package/lib/module/components/dialog/type.js.map +1 -0
- package/lib/module/components/index.js +32 -0
- package/lib/module/components/index.js.map +1 -0
- package/lib/module/components/loading/index.js +22 -0
- package/lib/module/components/loading/index.js.map +1 -0
- package/lib/module/components/loading/stylesheet.js +10 -0
- package/lib/module/components/loading/stylesheet.js.map +1 -0
- package/lib/module/components/loading/type.js +4 -0
- package/lib/module/components/loading/type.js.map +1 -0
- package/lib/module/components/markdownViewer/constant.js +18 -0
- package/lib/module/components/markdownViewer/constant.js.map +1 -0
- package/lib/module/components/markdownViewer/index.js +368 -0
- package/lib/module/components/markdownViewer/index.js.map +1 -0
- package/lib/module/components/markdownViewer/stylesheet.js +66 -0
- package/lib/module/components/markdownViewer/stylesheet.js.map +1 -0
- package/lib/module/components/markdownViewer/type.js +5 -0
- package/lib/module/components/markdownViewer/type.js.map +1 -0
- package/lib/module/components/markdownViewer/util.js +344 -0
- package/lib/module/components/markdownViewer/util.js.map +1 -0
- package/lib/module/components/modal/index.js +170 -0
- package/lib/module/components/modal/index.js.map +1 -0
- package/lib/module/components/modal/stylesheet.js +36 -0
- package/lib/module/components/modal/stylesheet.js.map +1 -0
- package/lib/module/components/modal/type.js +5 -0
- package/lib/module/components/modal/type.js.map +1 -0
- package/lib/module/components/monthSelector/index.js +284 -0
- package/lib/module/components/monthSelector/index.js.map +1 -0
- package/lib/module/components/monthSelector/stylesheet.js +80 -0
- package/lib/module/components/monthSelector/stylesheet.js.map +1 -0
- package/lib/module/components/monthSelector/type.js +7 -0
- package/lib/module/components/monthSelector/type.js.map +1 -0
- package/lib/module/components/monthSelector/util.js +17 -0
- package/lib/module/components/monthSelector/util.js.map +1 -0
- package/lib/module/components/notificationIndicator/index.js +121 -0
- package/lib/module/components/notificationIndicator/index.js.map +1 -0
- package/lib/module/components/notificationIndicator/stylesheet.js +119 -0
- package/lib/module/components/notificationIndicator/stylesheet.js.map +1 -0
- package/lib/module/components/notificationIndicator/type.js +4 -0
- package/lib/module/components/notificationIndicator/type.js.map +1 -0
- package/lib/module/components/numericInput/index.js +409 -0
- package/lib/module/components/numericInput/index.js.map +1 -0
- package/lib/module/components/numericInput/stylesheet.js +245 -0
- package/lib/module/components/numericInput/stylesheet.js.map +1 -0
- package/lib/module/components/numericInput/type.js +5 -0
- package/lib/module/components/numericInput/type.js.map +1 -0
- package/lib/module/components/pageContainer/index.js +81 -0
- package/lib/module/components/pageContainer/index.js.map +1 -0
- package/lib/module/components/pageContainer/stylesheet.js +13 -0
- package/lib/module/components/pageContainer/stylesheet.js.map +1 -0
- package/lib/module/components/pageContainer/type.js +4 -0
- package/lib/module/components/pageContainer/type.js.map +1 -0
- package/lib/module/components/radioButton/index.js +179 -0
- package/lib/module/components/radioButton/index.js.map +1 -0
- package/lib/module/components/radioButton/stylesheet.js +192 -0
- package/lib/module/components/radioButton/stylesheet.js.map +1 -0
- package/lib/module/components/radioButton/type.js +4 -0
- package/lib/module/components/radioButton/type.js.map +1 -0
- package/lib/module/components/rowCard/index.js +153 -0
- package/lib/module/components/rowCard/index.js.map +1 -0
- package/lib/module/components/rowCard/stylesheet.js +78 -0
- package/lib/module/components/rowCard/stylesheet.js.map +1 -0
- package/lib/module/components/rowCard/type.js +4 -0
- package/lib/module/components/rowCard/type.js.map +1 -0
- package/lib/module/components/selectBox/index.js +612 -0
- package/lib/module/components/selectBox/index.js.map +1 -0
- package/lib/module/components/selectBox/stylesheet.js +216 -0
- package/lib/module/components/selectBox/stylesheet.js.map +1 -0
- package/lib/module/components/selectBox/type.js +5 -0
- package/lib/module/components/selectBox/type.js.map +1 -0
- package/lib/module/components/selectSheet/index.js +285 -0
- package/lib/module/components/selectSheet/index.js.map +1 -0
- package/lib/module/components/selectSheet/stylesheet.js +90 -0
- package/lib/module/components/selectSheet/stylesheet.js.map +1 -0
- package/lib/module/components/selectSheet/type.js +5 -0
- package/lib/module/components/selectSheet/type.js.map +1 -0
- package/lib/module/components/snackBar/index.js +314 -0
- package/lib/module/components/snackBar/index.js.map +1 -0
- package/lib/module/components/snackBar/stylesheet.js +131 -0
- package/lib/module/components/snackBar/stylesheet.js.map +1 -0
- package/lib/module/components/snackBar/type.js +5 -0
- package/lib/module/components/snackBar/type.js.map +1 -0
- package/lib/module/components/stateCard/index.js +101 -0
- package/lib/module/components/stateCard/index.js.map +1 -0
- package/lib/module/components/stateCard/stylesheet.js +96 -0
- package/lib/module/components/stateCard/stylesheet.js.map +1 -0
- package/lib/module/components/stateCard/type.js +4 -0
- package/lib/module/components/stateCard/type.js.map +1 -0
- package/lib/module/components/sticker/index.js +85 -0
- package/lib/module/components/sticker/index.js.map +1 -0
- package/lib/module/components/sticker/stylesheet.js +95 -0
- package/lib/module/components/sticker/stylesheet.js.map +1 -0
- package/lib/module/components/sticker/type.js +4 -0
- package/lib/module/components/sticker/type.js.map +1 -0
- package/lib/module/components/switch/index.js +192 -0
- package/lib/module/components/switch/index.js.map +1 -0
- package/lib/module/components/switch/stylesheet.js +174 -0
- package/lib/module/components/switch/stylesheet.js.map +1 -0
- package/lib/module/components/switch/type.js +4 -0
- package/lib/module/components/switch/type.js.map +1 -0
- package/lib/module/components/text/index.js +29 -0
- package/lib/module/components/text/index.js.map +1 -0
- package/lib/module/components/text/type.js +4 -0
- package/lib/module/components/text/type.js.map +1 -0
- package/lib/module/components/textAreaInput/index.js +367 -0
- package/lib/module/components/textAreaInput/index.js.map +1 -0
- package/lib/module/components/textAreaInput/stylesheet.js +256 -0
- package/lib/module/components/textAreaInput/stylesheet.js.map +1 -0
- package/lib/module/components/textAreaInput/type.js +5 -0
- package/lib/module/components/textAreaInput/type.js.map +1 -0
- package/lib/module/components/textInput/index.js +362 -0
- package/lib/module/components/textInput/index.js.map +1 -0
- package/lib/module/components/textInput/stylesheet.js +245 -0
- package/lib/module/components/textInput/stylesheet.js.map +1 -0
- package/lib/module/components/textInput/type.js +5 -0
- package/lib/module/components/textInput/type.js.map +1 -0
- package/lib/module/components/timeSelector/components/timeInput/index.js +135 -0
- package/lib/module/components/timeSelector/components/timeInput/index.js.map +1 -0
- package/lib/module/components/timeSelector/components/timeInput/stylesheet.js +27 -0
- package/lib/module/components/timeSelector/components/timeInput/stylesheet.js.map +1 -0
- package/lib/module/components/timeSelector/components/timeInput/type.js +5 -0
- package/lib/module/components/timeSelector/components/timeInput/type.js.map +1 -0
- package/lib/module/components/timeSelector/index.js +329 -0
- package/lib/module/components/timeSelector/index.js.map +1 -0
- package/lib/module/components/timeSelector/stylesheet.js +44 -0
- package/lib/module/components/timeSelector/stylesheet.js.map +1 -0
- package/lib/module/components/timeSelector/type.js +5 -0
- package/lib/module/components/timeSelector/type.js.map +1 -0
- package/lib/module/components/toast/index.js +199 -0
- package/lib/module/components/toast/index.js.map +1 -0
- package/lib/module/components/toast/stylesheet.js +124 -0
- package/lib/module/components/toast/stylesheet.js.map +1 -0
- package/lib/module/components/toast/type.js +5 -0
- package/lib/module/components/toast/type.js.map +1 -0
- package/lib/module/components/yearSelector/index.js +278 -0
- package/lib/module/components/yearSelector/index.js.map +1 -0
- package/lib/module/components/yearSelector/stylesheet.js +80 -0
- package/lib/module/components/yearSelector/stylesheet.js.map +1 -0
- package/lib/module/components/yearSelector/type.js +7 -0
- package/lib/module/components/yearSelector/type.js.map +1 -0
- package/lib/module/components/yearSelector/util.js +17 -0
- package/lib/module/components/yearSelector/util.js.map +1 -0
- package/lib/module/context/bottomSheet.js +86 -0
- package/lib/module/context/bottomSheet.js.map +1 -0
- package/lib/module/context/dialog.js +85 -0
- package/lib/module/context/dialog.js.map +1 -0
- package/lib/module/context/index.js +92 -0
- package/lib/module/context/index.js.map +1 -0
- package/lib/module/context/localize.js +143 -0
- package/lib/module/context/localize.js.map +1 -0
- package/lib/module/context/modal.js +82 -0
- package/lib/module/context/modal.js.map +1 -0
- package/lib/module/context/snackBar.js +79 -0
- package/lib/module/context/snackBar.js.map +1 -0
- package/lib/module/context/theme.js +142 -0
- package/lib/module/context/theme.js.map +1 -0
- package/lib/module/context/toast.js +79 -0
- package/lib/module/context/toast.js.map +1 -0
- package/lib/module/core/hooks.js +19 -0
- package/lib/module/core/hooks.js.map +1 -0
- package/lib/module/core/index.js +91 -0
- package/lib/module/core/index.js.map +1 -0
- package/lib/module/helpers/index.js +7 -0
- package/lib/module/helpers/index.js.map +1 -0
- package/lib/module/helpers/locale/index.js +23 -0
- package/lib/module/helpers/locale/index.js.map +1 -0
- package/lib/module/helpers/portalize/Consumer.js +33 -0
- package/lib/module/helpers/portalize/Consumer.js.map +1 -0
- package/lib/module/helpers/portalize/Host.js +73 -0
- package/lib/module/helpers/portalize/Host.js.map +1 -0
- package/lib/module/helpers/portalize/Manager.js +36 -0
- package/lib/module/helpers/portalize/Manager.js.map +1 -0
- package/lib/module/helpers/portalize/Portal.js +18 -0
- package/lib/module/helpers/portalize/Portal.js.map +1 -0
- package/lib/module/helpers/portalize/context/index.js +33 -0
- package/lib/module/helpers/portalize/context/index.js.map +1 -0
- package/lib/module/helpers/portalize/hooks/useKey.js +34 -0
- package/lib/module/helpers/portalize/hooks/useKey.js.map +1 -0
- package/lib/module/helpers/portalize/index.js +7 -0
- package/lib/module/helpers/portalize/index.js.map +1 -0
- package/lib/module/helpers/theme/palette.js +61 -0
- package/lib/module/helpers/theme/palette.js.map +1 -0
- package/lib/module/helpers/theme/shapes.js +79 -0
- package/lib/module/helpers/theme/shapes.js.map +1 -0
- package/lib/module/helpers/theme/typography.js +33 -0
- package/lib/module/helpers/theme/typography.js.map +1 -0
- package/lib/module/index.js +10 -0
- package/lib/module/index.js.map +1 -0
- package/lib/module/package.json +4 -0
- package/lib/module/types/bottomSheet.js +4 -0
- package/lib/module/types/bottomSheet.js.map +1 -0
- package/lib/module/types/dialog.js +4 -0
- package/lib/module/types/dialog.js.map +1 -0
- package/lib/module/types/icon.js +4 -0
- package/lib/module/types/icon.js.map +1 -0
- package/lib/module/types/index.js +7 -0
- package/lib/module/types/index.js.map +1 -0
- package/lib/module/types/locale.js +4 -0
- package/lib/module/types/locale.js.map +1 -0
- package/lib/module/types/modal.js +4 -0
- package/lib/module/types/modal.js.map +1 -0
- package/lib/module/types/portalize.js +2 -0
- package/lib/module/types/portalize.js.map +1 -0
- package/lib/module/types/snackBar.js +4 -0
- package/lib/module/types/snackBar.js.map +1 -0
- package/lib/module/types/theme.js +2 -0
- package/lib/module/types/theme.js.map +1 -0
- package/lib/module/types/toast.js +4 -0
- package/lib/module/types/toast.js.map +1 -0
- package/lib/module/utils/index.js +54 -0
- package/lib/module/utils/index.js.map +1 -0
- package/lib/module/variants/locales/default.json +208 -0
- package/lib/module/variants/themes/default.json +669 -0
- package/lib/package.json +4 -0
- package/lib/src/assets/svg/badgeAlertIcon/index.js +11 -0
- package/lib/src/assets/svg/badgeDangerIcon/index.js +10 -0
- package/lib/src/assets/svg/badgeInfoIcon/index.js +10 -0
- package/lib/src/assets/svg/badgeQuestionMarkIcon/index.js +11 -0
- package/lib/src/assets/svg/badgeRightIcon/index.js +10 -0
- package/lib/src/assets/svg/badgeSuccessIcon/index.js +11 -0
- package/lib/src/assets/svg/chevronRightIcon/index.js +10 -0
- package/lib/src/assets/svg/cleanIcon/index.js +10 -0
- package/lib/src/assets/svg/eyeClosedIcon/index.js +11 -0
- package/lib/src/assets/svg/eyeOpenedIcon/index.js +11 -0
- package/lib/src/assets/svg/index.js +10 -0
- package/lib/src/assets/svg/loadingIcon/index.js +41 -0
- package/lib/src/components/bottomSheet/index.js +897 -0
- package/lib/src/components/bottomSheet/stylesheet.js +23 -0
- package/lib/src/components/bottomSheet/type.js +1 -0
- package/lib/src/components/button/index.js +107 -0
- package/lib/src/components/button/stylesheet.js +209 -0
- package/lib/src/components/button/type.js +2 -0
- package/lib/src/components/checkBox/index.js +133 -0
- package/lib/src/components/checkBox/stylesheet.js +166 -0
- package/lib/src/components/checkBox/type.js +1 -0
- package/lib/src/components/chip/index.js +84 -0
- package/lib/src/components/chip/stylesheet.js +117 -0
- package/lib/src/components/chip/type.js +1 -0
- package/lib/src/components/dateSelector/index.js +251 -0
- package/lib/src/components/dateSelector/stylesheet.js +74 -0
- package/lib/src/components/dateSelector/type.js +4 -0
- package/lib/src/components/dateSelector/util.js +12 -0
- package/lib/src/components/dateTimePicker/index.js +591 -0
- package/lib/src/components/dateTimePicker/stylesheet.js +198 -0
- package/lib/src/components/dateTimePicker/type.js +3 -0
- package/lib/src/components/dateTimeSheet/index.js +154 -0
- package/lib/src/components/dateTimeSheet/stylesheet.js +81 -0
- package/lib/src/components/dateTimeSheet/type.js +2 -0
- package/lib/src/components/dialog/index.js +166 -0
- package/lib/src/components/dialog/stylesheet.js +90 -0
- package/lib/src/components/dialog/type.js +3 -0
- package/lib/src/components/index.js +29 -0
- package/lib/src/components/loading/index.js +11 -0
- package/lib/src/components/loading/stylesheet.js +7 -0
- package/lib/src/components/loading/type.js +2 -0
- package/lib/src/components/markdownViewer/constant.js +15 -0
- package/lib/src/components/markdownViewer/index.js +237 -0
- package/lib/src/components/markdownViewer/stylesheet.js +59 -0
- package/lib/src/components/markdownViewer/type.js +2 -0
- package/lib/src/components/markdownViewer/util.js +316 -0
- package/lib/src/components/modal/index.js +140 -0
- package/lib/src/components/modal/stylesheet.js +33 -0
- package/lib/src/components/modal/type.js +3 -0
- package/lib/src/components/monthSelector/index.js +271 -0
- package/lib/src/components/monthSelector/stylesheet.js +72 -0
- package/lib/src/components/monthSelector/type.js +4 -0
- package/lib/src/components/monthSelector/util.js +12 -0
- package/lib/src/components/notificationIndicator/index.js +91 -0
- package/lib/src/components/notificationIndicator/stylesheet.js +105 -0
- package/lib/src/components/notificationIndicator/type.js +1 -0
- package/lib/src/components/numericInput/index.js +319 -0
- package/lib/src/components/numericInput/stylesheet.js +230 -0
- package/lib/src/components/numericInput/type.js +3 -0
- package/lib/src/components/pageContainer/index.js +62 -0
- package/lib/src/components/pageContainer/stylesheet.js +10 -0
- package/lib/src/components/pageContainer/type.js +1 -0
- package/lib/src/components/radioButton/index.js +135 -0
- package/lib/src/components/radioButton/stylesheet.js +175 -0
- package/lib/src/components/radioButton/type.js +1 -0
- package/lib/src/components/rowCard/index.js +99 -0
- package/lib/src/components/rowCard/stylesheet.js +71 -0
- package/lib/src/components/rowCard/type.js +1 -0
- package/lib/src/components/selectBox/index.js +501 -0
- package/lib/src/components/selectBox/stylesheet.js +201 -0
- package/lib/src/components/selectBox/type.js +3 -0
- package/lib/src/components/selectSheet/index.js +179 -0
- package/lib/src/components/selectSheet/stylesheet.js +83 -0
- package/lib/src/components/selectSheet/type.js +2 -0
- package/lib/src/components/snackBar/index.js +249 -0
- package/lib/src/components/snackBar/stylesheet.js +118 -0
- package/lib/src/components/snackBar/type.js +3 -0
- package/lib/src/components/stateCard/index.js +69 -0
- package/lib/src/components/stateCard/stylesheet.js +90 -0
- package/lib/src/components/stateCard/type.js +1 -0
- package/lib/src/components/sticker/index.js +54 -0
- package/lib/src/components/sticker/stylesheet.js +83 -0
- package/lib/src/components/sticker/type.js +1 -0
- package/lib/src/components/switch/index.js +149 -0
- package/lib/src/components/switch/stylesheet.js +158 -0
- package/lib/src/components/switch/type.js +1 -0
- package/lib/src/components/text/index.js +15 -0
- package/lib/src/components/text/type.js +2 -0
- package/lib/src/components/textAreaInput/index.js +279 -0
- package/lib/src/components/textAreaInput/stylesheet.js +240 -0
- package/lib/src/components/textAreaInput/type.js +3 -0
- package/lib/src/components/textInput/index.js +273 -0
- package/lib/src/components/textInput/stylesheet.js +230 -0
- package/lib/src/components/textInput/type.js +3 -0
- package/lib/src/components/timeSelector/components/timeInput/index.js +112 -0
- package/lib/src/components/timeSelector/components/timeInput/stylesheet.js +21 -0
- package/lib/src/components/timeSelector/components/timeInput/type.js +2 -0
- package/lib/src/components/timeSelector/index.js +141 -0
- package/lib/src/components/timeSelector/stylesheet.js +37 -0
- package/lib/src/components/timeSelector/type.js +2 -0
- package/lib/src/components/toast/index.js +143 -0
- package/lib/src/components/toast/stylesheet.js +112 -0
- package/lib/src/components/toast/type.js +3 -0
- package/lib/src/components/yearSelector/index.js +269 -0
- package/lib/src/components/yearSelector/stylesheet.js +72 -0
- package/lib/src/components/yearSelector/type.js +4 -0
- package/lib/src/components/yearSelector/util.js +12 -0
- package/lib/src/context/bottomSheet.js +72 -0
- package/lib/src/context/dialog.js +72 -0
- package/lib/src/context/index.js +60 -0
- package/lib/src/context/localize.js +135 -0
- package/lib/src/context/modal.js +70 -0
- package/lib/src/context/snackBar.js +67 -0
- package/lib/src/context/theme.js +127 -0
- package/lib/src/context/toast.js +67 -0
- package/lib/src/core/hooks.js +16 -0
- package/lib/src/core/index.js +85 -0
- package/lib/src/helpers/index.js +4 -0
- package/lib/src/helpers/locale/index.js +20 -0
- package/lib/src/helpers/portalize/Consumer.js +31 -0
- package/lib/src/helpers/portalize/Host.js +55 -0
- package/lib/src/helpers/portalize/Manager.js +25 -0
- package/lib/src/helpers/portalize/Portal.js +7 -0
- package/lib/src/helpers/portalize/context/index.js +33 -0
- package/lib/src/helpers/portalize/hooks/useKey.js +33 -0
- package/lib/src/helpers/portalize/index.js +4 -0
- package/lib/src/helpers/theme/palette.js +63 -0
- package/lib/src/helpers/theme/shapes.js +75 -0
- package/lib/src/helpers/theme/typography.js +28 -0
- package/lib/src/index.js +7 -0
- package/lib/src/types/bottomSheet.js +1 -0
- package/lib/src/types/dialog.js +1 -0
- package/lib/src/types/icon.js +2 -0
- package/lib/src/types/index.js +11 -0
- package/lib/src/types/locale.js +1 -0
- package/lib/src/types/modal.js +1 -0
- package/lib/src/types/portalize.js +1 -0
- package/lib/src/types/snackBar.js +1 -0
- package/lib/src/types/theme.js +1 -0
- package/lib/src/types/toast.js +1 -0
- package/lib/src/utils/index.js +55 -0
- package/lib/src/variants/locales/default.json +208 -0
- package/lib/src/variants/themes/default.json +669 -0
- package/lib/tsconfig.build.tsbuildinfo +1 -0
- package/lib/typescript/package.json +4 -0
- package/lib/typescript/src/assets/svg/badgeAlertIcon/index.d.ts +4 -0
- package/lib/typescript/src/assets/svg/badgeAlertIcon/index.d.ts.map +1 -0
- package/lib/typescript/src/assets/svg/badgeDangerIcon/index.d.ts +4 -0
- package/lib/typescript/src/assets/svg/badgeDangerIcon/index.d.ts.map +1 -0
- package/lib/typescript/src/assets/svg/badgeInfoIcon/index.d.ts +4 -0
- package/lib/typescript/src/assets/svg/badgeInfoIcon/index.d.ts.map +1 -0
- package/lib/typescript/src/assets/svg/badgeQuestionMarkIcon/index.d.ts +4 -0
- package/lib/typescript/src/assets/svg/badgeQuestionMarkIcon/index.d.ts.map +1 -0
- package/lib/typescript/src/assets/svg/badgeRightIcon/index.d.ts +4 -0
- package/lib/typescript/src/assets/svg/badgeRightIcon/index.d.ts.map +1 -0
- package/lib/typescript/src/assets/svg/badgeSuccessIcon/index.d.ts +4 -0
- package/lib/typescript/src/assets/svg/badgeSuccessIcon/index.d.ts.map +1 -0
- package/lib/typescript/src/assets/svg/chevronRightIcon/index.d.ts +4 -0
- package/lib/typescript/src/assets/svg/chevronRightIcon/index.d.ts.map +1 -0
- package/lib/typescript/src/assets/svg/cleanIcon/index.d.ts +4 -0
- package/lib/typescript/src/assets/svg/cleanIcon/index.d.ts.map +1 -0
- package/lib/typescript/src/assets/svg/eyeClosedIcon/index.d.ts +4 -0
- package/lib/typescript/src/assets/svg/eyeClosedIcon/index.d.ts.map +1 -0
- package/lib/typescript/src/assets/svg/eyeOpenedIcon/index.d.ts +4 -0
- package/lib/typescript/src/assets/svg/eyeOpenedIcon/index.d.ts.map +1 -0
- package/lib/typescript/src/assets/svg/index.d.ts +11 -0
- package/lib/typescript/src/assets/svg/index.d.ts.map +1 -0
- package/lib/typescript/src/assets/svg/loadingIcon/index.d.ts +4 -0
- package/lib/typescript/src/assets/svg/loadingIcon/index.d.ts.map +1 -0
- package/lib/typescript/src/components/bottomSheet/index.d.ts +5 -0
- package/lib/typescript/src/components/bottomSheet/index.d.ts.map +1 -0
- package/lib/typescript/src/components/bottomSheet/stylesheet.d.ts +22 -0
- package/lib/typescript/src/components/bottomSheet/stylesheet.d.ts.map +1 -0
- package/lib/typescript/src/components/bottomSheet/type.d.ts +59 -0
- package/lib/typescript/src/components/bottomSheet/type.d.ts.map +1 -0
- package/lib/typescript/src/components/button/index.d.ts +10 -0
- package/lib/typescript/src/components/button/index.d.ts.map +1 -0
- package/lib/typescript/src/components/button/stylesheet.d.ts +51 -0
- package/lib/typescript/src/components/button/stylesheet.d.ts.map +1 -0
- package/lib/typescript/src/components/button/type.d.ts +84 -0
- package/lib/typescript/src/components/button/type.d.ts.map +1 -0
- package/lib/typescript/src/components/checkBox/index.d.ts +5 -0
- package/lib/typescript/src/components/checkBox/index.d.ts.map +1 -0
- package/lib/typescript/src/components/checkBox/stylesheet.d.ts +63 -0
- package/lib/typescript/src/components/checkBox/stylesheet.d.ts.map +1 -0
- package/lib/typescript/src/components/checkBox/type.d.ts +57 -0
- package/lib/typescript/src/components/checkBox/type.d.ts.map +1 -0
- package/lib/typescript/src/components/chip/index.d.ts +5 -0
- package/lib/typescript/src/components/chip/index.d.ts.map +1 -0
- package/lib/typescript/src/components/chip/stylesheet.d.ts +48 -0
- package/lib/typescript/src/components/chip/stylesheet.d.ts.map +1 -0
- package/lib/typescript/src/components/chip/type.d.ts +53 -0
- package/lib/typescript/src/components/chip/type.d.ts.map +1 -0
- package/lib/typescript/src/components/dateSelector/index.d.ts +5 -0
- package/lib/typescript/src/components/dateSelector/index.d.ts.map +1 -0
- package/lib/typescript/src/components/dateSelector/stylesheet.d.ts +49 -0
- package/lib/typescript/src/components/dateSelector/stylesheet.d.ts.map +1 -0
- package/lib/typescript/src/components/dateSelector/type.d.ts +46 -0
- package/lib/typescript/src/components/dateSelector/type.d.ts.map +1 -0
- package/lib/typescript/src/components/dateSelector/util.d.ts +3 -0
- package/lib/typescript/src/components/dateSelector/util.d.ts.map +1 -0
- package/lib/typescript/src/components/dateTimePicker/index.d.ts +5 -0
- package/lib/typescript/src/components/dateTimePicker/index.d.ts.map +1 -0
- package/lib/typescript/src/components/dateTimePicker/stylesheet.d.ts +85 -0
- package/lib/typescript/src/components/dateTimePicker/stylesheet.d.ts.map +1 -0
- package/lib/typescript/src/components/dateTimePicker/type.d.ts +173 -0
- package/lib/typescript/src/components/dateTimePicker/type.d.ts.map +1 -0
- package/lib/typescript/src/components/dateTimeSheet/index.d.ts +4 -0
- package/lib/typescript/src/components/dateTimeSheet/index.d.ts.map +1 -0
- package/lib/typescript/src/components/dateTimeSheet/stylesheet.d.ts +54 -0
- package/lib/typescript/src/components/dateTimeSheet/stylesheet.d.ts.map +1 -0
- package/lib/typescript/src/components/dateTimeSheet/type.d.ts +67 -0
- package/lib/typescript/src/components/dateTimeSheet/type.d.ts.map +1 -0
- package/lib/typescript/src/components/dialog/index.d.ts +5 -0
- package/lib/typescript/src/components/dialog/index.d.ts.map +1 -0
- package/lib/typescript/src/components/dialog/stylesheet.d.ts +48 -0
- package/lib/typescript/src/components/dialog/stylesheet.d.ts.map +1 -0
- package/lib/typescript/src/components/dialog/type.d.ts +62 -0
- package/lib/typescript/src/components/dialog/type.d.ts.map +1 -0
- package/lib/typescript/src/components/index.d.ts +38 -0
- package/lib/typescript/src/components/index.d.ts.map +1 -0
- package/lib/typescript/src/components/loading/index.d.ts +5 -0
- package/lib/typescript/src/components/loading/index.d.ts.map +1 -0
- package/lib/typescript/src/components/loading/stylesheet.d.ts +7 -0
- package/lib/typescript/src/components/loading/stylesheet.d.ts.map +1 -0
- package/lib/typescript/src/components/loading/type.d.ts +12 -0
- package/lib/typescript/src/components/loading/type.d.ts.map +1 -0
- package/lib/typescript/src/components/markdownViewer/constant.d.ts +3 -0
- package/lib/typescript/src/components/markdownViewer/constant.d.ts.map +1 -0
- package/lib/typescript/src/components/markdownViewer/index.d.ts +5 -0
- package/lib/typescript/src/components/markdownViewer/index.d.ts.map +1 -0
- package/lib/typescript/src/components/markdownViewer/stylesheet.d.ts +57 -0
- package/lib/typescript/src/components/markdownViewer/stylesheet.d.ts.map +1 -0
- package/lib/typescript/src/components/markdownViewer/type.d.ts +57 -0
- package/lib/typescript/src/components/markdownViewer/type.d.ts.map +1 -0
- package/lib/typescript/src/components/markdownViewer/util.d.ts +53 -0
- package/lib/typescript/src/components/markdownViewer/util.d.ts.map +1 -0
- package/lib/typescript/src/components/modal/index.d.ts +5 -0
- package/lib/typescript/src/components/modal/index.d.ts.map +1 -0
- package/lib/typescript/src/components/modal/stylesheet.d.ts +33 -0
- package/lib/typescript/src/components/modal/stylesheet.d.ts.map +1 -0
- package/lib/typescript/src/components/modal/type.d.ts +45 -0
- package/lib/typescript/src/components/modal/type.d.ts.map +1 -0
- package/lib/typescript/src/components/monthSelector/index.d.ts +5 -0
- package/lib/typescript/src/components/monthSelector/index.d.ts.map +1 -0
- package/lib/typescript/src/components/monthSelector/stylesheet.d.ts +49 -0
- package/lib/typescript/src/components/monthSelector/stylesheet.d.ts.map +1 -0
- package/lib/typescript/src/components/monthSelector/type.d.ts +46 -0
- package/lib/typescript/src/components/monthSelector/type.d.ts.map +1 -0
- package/lib/typescript/src/components/monthSelector/util.d.ts +3 -0
- package/lib/typescript/src/components/monthSelector/util.d.ts.map +1 -0
- package/lib/typescript/src/components/notificationIndicator/index.d.ts +5 -0
- package/lib/typescript/src/components/notificationIndicator/index.d.ts.map +1 -0
- package/lib/typescript/src/components/notificationIndicator/stylesheet.d.ts +46 -0
- package/lib/typescript/src/components/notificationIndicator/stylesheet.d.ts.map +1 -0
- package/lib/typescript/src/components/notificationIndicator/type.d.ts +52 -0
- package/lib/typescript/src/components/notificationIndicator/type.d.ts.map +1 -0
- package/lib/typescript/src/components/numericInput/index.d.ts +5 -0
- package/lib/typescript/src/components/numericInput/index.d.ts.map +1 -0
- package/lib/typescript/src/components/numericInput/stylesheet.d.ts +103 -0
- package/lib/typescript/src/components/numericInput/stylesheet.d.ts.map +1 -0
- package/lib/typescript/src/components/numericInput/type.d.ts +87 -0
- package/lib/typescript/src/components/numericInput/type.d.ts.map +1 -0
- package/lib/typescript/src/components/pageContainer/index.d.ts +5 -0
- package/lib/typescript/src/components/pageContainer/index.d.ts.map +1 -0
- package/lib/typescript/src/components/pageContainer/stylesheet.d.ts +10 -0
- package/lib/typescript/src/components/pageContainer/stylesheet.d.ts.map +1 -0
- package/lib/typescript/src/components/pageContainer/type.d.ts +22 -0
- package/lib/typescript/src/components/pageContainer/type.d.ts.map +1 -0
- package/lib/typescript/src/components/radioButton/index.d.ts +5 -0
- package/lib/typescript/src/components/radioButton/index.d.ts.map +1 -0
- package/lib/typescript/src/components/radioButton/stylesheet.d.ts +67 -0
- package/lib/typescript/src/components/radioButton/stylesheet.d.ts.map +1 -0
- package/lib/typescript/src/components/radioButton/type.d.ts +58 -0
- package/lib/typescript/src/components/radioButton/type.d.ts.map +1 -0
- package/lib/typescript/src/components/rowCard/index.d.ts +5 -0
- package/lib/typescript/src/components/rowCard/index.d.ts.map +1 -0
- package/lib/typescript/src/components/rowCard/stylesheet.d.ts +45 -0
- package/lib/typescript/src/components/rowCard/stylesheet.d.ts.map +1 -0
- package/lib/typescript/src/components/rowCard/type.d.ts +49 -0
- package/lib/typescript/src/components/rowCard/type.d.ts.map +1 -0
- package/lib/typescript/src/components/selectBox/index.d.ts +4 -0
- package/lib/typescript/src/components/selectBox/index.d.ts.map +1 -0
- package/lib/typescript/src/components/selectBox/stylesheet.d.ts +86 -0
- package/lib/typescript/src/components/selectBox/stylesheet.d.ts.map +1 -0
- package/lib/typescript/src/components/selectBox/type.d.ts +151 -0
- package/lib/typescript/src/components/selectBox/type.d.ts.map +1 -0
- package/lib/typescript/src/components/selectSheet/index.d.ts +4 -0
- package/lib/typescript/src/components/selectSheet/index.d.ts.map +1 -0
- package/lib/typescript/src/components/selectSheet/stylesheet.d.ts +54 -0
- package/lib/typescript/src/components/selectSheet/stylesheet.d.ts.map +1 -0
- package/lib/typescript/src/components/selectSheet/type.d.ts +80 -0
- package/lib/typescript/src/components/selectSheet/type.d.ts.map +1 -0
- package/lib/typescript/src/components/snackBar/index.d.ts +5 -0
- package/lib/typescript/src/components/snackBar/index.d.ts.map +1 -0
- package/lib/typescript/src/components/snackBar/stylesheet.d.ts +50 -0
- package/lib/typescript/src/components/snackBar/stylesheet.d.ts.map +1 -0
- package/lib/typescript/src/components/snackBar/type.d.ts +70 -0
- package/lib/typescript/src/components/snackBar/type.d.ts.map +1 -0
- package/lib/typescript/src/components/stateCard/index.d.ts +5 -0
- package/lib/typescript/src/components/stateCard/index.d.ts.map +1 -0
- package/lib/typescript/src/components/stateCard/stylesheet.d.ts +43 -0
- package/lib/typescript/src/components/stateCard/stylesheet.d.ts.map +1 -0
- package/lib/typescript/src/components/stateCard/type.d.ts +35 -0
- package/lib/typescript/src/components/stateCard/type.d.ts.map +1 -0
- package/lib/typescript/src/components/sticker/index.d.ts +5 -0
- package/lib/typescript/src/components/sticker/index.d.ts.map +1 -0
- package/lib/typescript/src/components/sticker/stylesheet.d.ts +34 -0
- package/lib/typescript/src/components/sticker/stylesheet.d.ts.map +1 -0
- package/lib/typescript/src/components/sticker/type.d.ts +45 -0
- package/lib/typescript/src/components/sticker/type.d.ts.map +1 -0
- package/lib/typescript/src/components/switch/index.d.ts +5 -0
- package/lib/typescript/src/components/switch/index.d.ts.map +1 -0
- package/lib/typescript/src/components/switch/stylesheet.d.ts +64 -0
- package/lib/typescript/src/components/switch/stylesheet.d.ts.map +1 -0
- package/lib/typescript/src/components/switch/type.d.ts +56 -0
- package/lib/typescript/src/components/switch/type.d.ts.map +1 -0
- package/lib/typescript/src/components/text/index.d.ts +5 -0
- package/lib/typescript/src/components/text/index.d.ts.map +1 -0
- package/lib/typescript/src/components/text/type.d.ts +17 -0
- package/lib/typescript/src/components/text/type.d.ts.map +1 -0
- package/lib/typescript/src/components/textAreaInput/index.d.ts +5 -0
- package/lib/typescript/src/components/textAreaInput/index.d.ts.map +1 -0
- package/lib/typescript/src/components/textAreaInput/stylesheet.d.ts +113 -0
- package/lib/typescript/src/components/textAreaInput/stylesheet.d.ts.map +1 -0
- package/lib/typescript/src/components/textAreaInput/type.d.ts +86 -0
- package/lib/typescript/src/components/textAreaInput/type.d.ts.map +1 -0
- package/lib/typescript/src/components/textInput/index.d.ts +5 -0
- package/lib/typescript/src/components/textInput/index.d.ts.map +1 -0
- package/lib/typescript/src/components/textInput/stylesheet.d.ts +104 -0
- package/lib/typescript/src/components/textInput/stylesheet.d.ts.map +1 -0
- package/lib/typescript/src/components/textInput/type.d.ts +86 -0
- package/lib/typescript/src/components/textInput/type.d.ts.map +1 -0
- package/lib/typescript/src/components/timeSelector/components/timeInput/index.d.ts +5 -0
- package/lib/typescript/src/components/timeSelector/components/timeInput/index.d.ts.map +1 -0
- package/lib/typescript/src/components/timeSelector/components/timeInput/stylesheet.d.ts +17 -0
- package/lib/typescript/src/components/timeSelector/components/timeInput/stylesheet.d.ts.map +1 -0
- package/lib/typescript/src/components/timeSelector/components/timeInput/type.d.ts +32 -0
- package/lib/typescript/src/components/timeSelector/components/timeInput/type.d.ts.map +1 -0
- package/lib/typescript/src/components/timeSelector/index.d.ts +4 -0
- package/lib/typescript/src/components/timeSelector/index.d.ts.map +1 -0
- package/lib/typescript/src/components/timeSelector/stylesheet.d.ts +27 -0
- package/lib/typescript/src/components/timeSelector/stylesheet.d.ts.map +1 -0
- package/lib/typescript/src/components/timeSelector/type.d.ts +36 -0
- package/lib/typescript/src/components/timeSelector/type.d.ts.map +1 -0
- package/lib/typescript/src/components/toast/index.d.ts +5 -0
- package/lib/typescript/src/components/toast/index.d.ts.map +1 -0
- package/lib/typescript/src/components/toast/stylesheet.d.ts +49 -0
- package/lib/typescript/src/components/toast/stylesheet.d.ts.map +1 -0
- package/lib/typescript/src/components/toast/type.d.ts +64 -0
- package/lib/typescript/src/components/toast/type.d.ts.map +1 -0
- package/lib/typescript/src/components/yearSelector/index.d.ts +5 -0
- package/lib/typescript/src/components/yearSelector/index.d.ts.map +1 -0
- package/lib/typescript/src/components/yearSelector/stylesheet.d.ts +49 -0
- package/lib/typescript/src/components/yearSelector/stylesheet.d.ts.map +1 -0
- package/lib/typescript/src/components/yearSelector/type.d.ts +43 -0
- package/lib/typescript/src/components/yearSelector/type.d.ts.map +1 -0
- package/lib/typescript/src/components/yearSelector/util.d.ts +3 -0
- package/lib/typescript/src/components/yearSelector/util.d.ts.map +1 -0
- package/lib/typescript/src/context/bottomSheet.d.ts +18 -0
- package/lib/typescript/src/context/bottomSheet.d.ts.map +1 -0
- package/lib/typescript/src/context/dialog.d.ts +18 -0
- package/lib/typescript/src/context/dialog.d.ts.map +1 -0
- package/lib/typescript/src/context/index.d.ts +24 -0
- package/lib/typescript/src/context/index.d.ts.map +1 -0
- package/lib/typescript/src/context/localize.d.ts +24 -0
- package/lib/typescript/src/context/localize.d.ts.map +1 -0
- package/lib/typescript/src/context/modal.d.ts +18 -0
- package/lib/typescript/src/context/modal.d.ts.map +1 -0
- package/lib/typescript/src/context/snackBar.d.ts +18 -0
- package/lib/typescript/src/context/snackBar.d.ts.map +1 -0
- package/lib/typescript/src/context/theme.d.ts +32 -0
- package/lib/typescript/src/context/theme.d.ts.map +1 -0
- package/lib/typescript/src/context/toast.d.ts +18 -0
- package/lib/typescript/src/context/toast.d.ts.map +1 -0
- package/lib/typescript/src/core/hooks.d.ts +18 -0
- package/lib/typescript/src/core/hooks.d.ts.map +1 -0
- package/lib/typescript/src/core/index.d.ts +13 -0
- package/lib/typescript/src/core/index.d.ts.map +1 -0
- package/lib/typescript/src/helpers/index.d.ts +5 -0
- package/lib/typescript/src/helpers/index.d.ts.map +1 -0
- package/lib/typescript/src/helpers/locale/index.d.ts +8 -0
- package/lib/typescript/src/helpers/locale/index.d.ts.map +1 -0
- package/lib/typescript/src/helpers/portalize/Consumer.d.ts +10 -0
- package/lib/typescript/src/helpers/portalize/Consumer.d.ts.map +1 -0
- package/lib/typescript/src/helpers/portalize/Host.d.ts +17 -0
- package/lib/typescript/src/helpers/portalize/Host.d.ts.map +1 -0
- package/lib/typescript/src/helpers/portalize/Manager.d.ts +10 -0
- package/lib/typescript/src/helpers/portalize/Manager.d.ts.map +1 -0
- package/lib/typescript/src/helpers/portalize/Portal.d.ts +8 -0
- package/lib/typescript/src/helpers/portalize/Portal.d.ts.map +1 -0
- package/lib/typescript/src/helpers/portalize/context/index.d.ts +14 -0
- package/lib/typescript/src/helpers/portalize/context/index.d.ts.map +1 -0
- package/lib/typescript/src/helpers/portalize/hooks/useKey.d.ts +7 -0
- package/lib/typescript/src/helpers/portalize/hooks/useKey.d.ts.map +1 -0
- package/lib/typescript/src/helpers/portalize/index.d.ts +5 -0
- package/lib/typescript/src/helpers/portalize/index.d.ts.map +1 -0
- package/lib/typescript/src/helpers/theme/palette.d.ts +3 -0
- package/lib/typescript/src/helpers/theme/palette.d.ts.map +1 -0
- package/lib/typescript/src/helpers/theme/shapes.d.ts +33 -0
- package/lib/typescript/src/helpers/theme/shapes.d.ts.map +1 -0
- package/lib/typescript/src/helpers/theme/typography.d.ts +22 -0
- package/lib/typescript/src/helpers/theme/typography.d.ts.map +1 -0
- package/lib/typescript/src/index.d.ts +10 -0
- package/lib/typescript/src/index.d.ts.map +1 -0
- package/lib/typescript/src/types/bottomSheet.d.ts +20 -0
- package/lib/typescript/src/types/bottomSheet.d.ts.map +1 -0
- package/lib/typescript/src/types/dialog.d.ts +20 -0
- package/lib/typescript/src/types/dialog.d.ts.map +1 -0
- package/lib/typescript/src/types/icon.d.ts +14 -0
- package/lib/typescript/src/types/icon.d.ts.map +1 -0
- package/lib/typescript/src/types/index.d.ts +134 -0
- package/lib/typescript/src/types/index.d.ts.map +1 -0
- package/lib/typescript/src/types/locale.d.ts +17 -0
- package/lib/typescript/src/types/locale.d.ts.map +1 -0
- package/lib/typescript/src/types/modal.d.ts +20 -0
- package/lib/typescript/src/types/modal.d.ts.map +1 -0
- package/lib/typescript/src/types/portalize.d.ts +4 -0
- package/lib/typescript/src/types/portalize.d.ts.map +1 -0
- package/lib/typescript/src/types/snackBar.d.ts +19 -0
- package/lib/typescript/src/types/snackBar.d.ts.map +1 -0
- package/lib/typescript/src/types/theme.d.ts +25 -0
- package/lib/typescript/src/types/theme.d.ts.map +1 -0
- package/lib/typescript/src/types/toast.d.ts +19 -0
- package/lib/typescript/src/types/toast.d.ts.map +1 -0
- package/lib/typescript/src/utils/index.d.ts +5 -0
- package/lib/typescript/src/utils/index.d.ts.map +1 -0
- package/lib/typescript/src/variants/locales/default.json +208 -0
- package/lib/typescript/src/variants/themes/default.json +669 -0
- package/package.json +213 -0
- package/react-native.config.js +5 -0
- package/src/assets/fonts/Geist-Black.ttf +0 -0
- package/src/assets/fonts/Geist-Bold.ttf +0 -0
- package/src/assets/fonts/Geist-ExtraBold.ttf +0 -0
- package/src/assets/fonts/Geist-ExtraLight.ttf +0 -0
- package/src/assets/fonts/Geist-Light.ttf +0 -0
- package/src/assets/fonts/Geist-Medium.ttf +0 -0
- package/src/assets/fonts/Geist-Regular.ttf +0 -0
- package/src/assets/fonts/Geist-SemiBold.ttf +0 -0
- package/src/assets/fonts/Geist-Thin.ttf +0 -0
- package/src/assets/svg/badgeAlertIcon/index.tsx +42 -0
- package/src/assets/svg/badgeDangerIcon/index.tsx +40 -0
- package/src/assets/svg/badgeInfoIcon/index.tsx +40 -0
- package/src/assets/svg/badgeQuestionMarkIcon/index.tsx +50 -0
- package/src/assets/svg/badgeRightIcon/index.tsx +40 -0
- package/src/assets/svg/badgeSuccessIcon/index.tsx +50 -0
- package/src/assets/svg/chevronRightIcon/index.tsx +40 -0
- package/src/assets/svg/cleanIcon/index.tsx +40 -0
- package/src/assets/svg/eyeClosedIcon/index.tsx +50 -0
- package/src/assets/svg/eyeOpenedIcon/index.tsx +50 -0
- package/src/assets/svg/index.ts +39 -0
- package/src/assets/svg/loadingIcon/index.tsx +95 -0
- package/src/components/bottomSheet/index.tsx +1218 -0
- package/src/components/bottomSheet/stylesheet.ts +28 -0
- package/src/components/bottomSheet/type.ts +68 -0
- package/src/components/button/index.tsx +191 -0
- package/src/components/button/stylesheet.ts +294 -0
- package/src/components/button/type.ts +108 -0
- package/src/components/checkBox/index.tsx +274 -0
- package/src/components/checkBox/stylesheet.ts +223 -0
- package/src/components/checkBox/type.ts +69 -0
- package/src/components/chip/index.tsx +183 -0
- package/src/components/chip/stylesheet.ts +172 -0
- package/src/components/chip/type.ts +68 -0
- package/src/components/dateSelector/index.tsx +434 -0
- package/src/components/dateSelector/stylesheet.ts +92 -0
- package/src/components/dateSelector/type.ts +59 -0
- package/src/components/dateSelector/util.ts +20 -0
- package/src/components/dateTimePicker/index.tsx +977 -0
- package/src/components/dateTimePicker/stylesheet.ts +252 -0
- package/src/components/dateTimePicker/type.ts +214 -0
- package/src/components/dateTimeSheet/index.tsx +418 -0
- package/src/components/dateTimeSheet/stylesheet.ts +99 -0
- package/src/components/dateTimeSheet/type.ts +98 -0
- package/src/components/dialog/index.tsx +336 -0
- package/src/components/dialog/stylesheet.ts +129 -0
- package/src/components/dialog/type.ts +79 -0
- package/src/components/index.ts +163 -0
- package/src/components/loading/index.tsx +26 -0
- package/src/components/loading/stylesheet.ts +10 -0
- package/src/components/loading/type.ts +18 -0
- package/src/components/markdownViewer/constant.ts +19 -0
- package/src/components/markdownViewer/index.tsx +503 -0
- package/src/components/markdownViewer/stylesheet.ts +72 -0
- package/src/components/markdownViewer/type.ts +87 -0
- package/src/components/markdownViewer/util.ts +453 -0
- package/src/components/modal/index.tsx +234 -0
- package/src/components/modal/stylesheet.ts +36 -0
- package/src/components/modal/type.ts +58 -0
- package/src/components/monthSelector/index.tsx +447 -0
- package/src/components/monthSelector/stylesheet.ts +89 -0
- package/src/components/monthSelector/type.ts +59 -0
- package/src/components/monthSelector/util.ts +20 -0
- package/src/components/notificationIndicator/index.tsx +172 -0
- package/src/components/notificationIndicator/stylesheet.ts +154 -0
- package/src/components/notificationIndicator/type.ts +65 -0
- package/src/components/numericInput/index.tsx +617 -0
- package/src/components/numericInput/stylesheet.ts +278 -0
- package/src/components/numericInput/type.ts +109 -0
- package/src/components/pageContainer/index.tsx +119 -0
- package/src/components/pageContainer/stylesheet.ts +13 -0
- package/src/components/pageContainer/type.ts +30 -0
- package/src/components/radioButton/index.tsx +269 -0
- package/src/components/radioButton/stylesheet.ts +233 -0
- package/src/components/radioButton/type.ts +70 -0
- package/src/components/rowCard/index.tsx +231 -0
- package/src/components/rowCard/stylesheet.ts +95 -0
- package/src/components/rowCard/type.ts +59 -0
- package/src/components/selectBox/index.tsx +867 -0
- package/src/components/selectBox/stylesheet.ts +250 -0
- package/src/components/selectBox/type.ts +193 -0
- package/src/components/selectSheet/index.tsx +372 -0
- package/src/components/selectSheet/stylesheet.ts +102 -0
- package/src/components/selectSheet/type.ts +103 -0
- package/src/components/snackBar/index.tsx +430 -0
- package/src/components/snackBar/stylesheet.ts +164 -0
- package/src/components/snackBar/type.ts +85 -0
- package/src/components/stateCard/index.tsx +152 -0
- package/src/components/stateCard/stylesheet.ts +121 -0
- package/src/components/stateCard/type.ts +47 -0
- package/src/components/sticker/index.tsx +123 -0
- package/src/components/sticker/stylesheet.ts +124 -0
- package/src/components/sticker/type.ts +60 -0
- package/src/components/switch/index.tsx +284 -0
- package/src/components/switch/stylesheet.ts +214 -0
- package/src/components/switch/type.ts +68 -0
- package/src/components/text/index.tsx +42 -0
- package/src/components/text/type.ts +25 -0
- package/src/components/textAreaInput/index.tsx +551 -0
- package/src/components/textAreaInput/stylesheet.ts +294 -0
- package/src/components/textAreaInput/type.ts +104 -0
- package/src/components/textInput/index.tsx +555 -0
- package/src/components/textInput/stylesheet.ts +279 -0
- package/src/components/textInput/type.ts +105 -0
- package/src/components/timeSelector/components/timeInput/index.tsx +172 -0
- package/src/components/timeSelector/components/timeInput/stylesheet.ts +38 -0
- package/src/components/timeSelector/components/timeInput/type.ts +47 -0
- package/src/components/timeSelector/index.tsx +433 -0
- package/src/components/timeSelector/stylesheet.ts +59 -0
- package/src/components/timeSelector/type.ts +48 -0
- package/src/components/toast/index.tsx +272 -0
- package/src/components/toast/stylesheet.ts +156 -0
- package/src/components/toast/type.ts +79 -0
- package/src/components/yearSelector/index.tsx +444 -0
- package/src/components/yearSelector/stylesheet.ts +89 -0
- package/src/components/yearSelector/type.ts +55 -0
- package/src/components/yearSelector/util.ts +20 -0
- package/src/context/bottomSheet.tsx +121 -0
- package/src/context/dialog.tsx +120 -0
- package/src/context/index.tsx +110 -0
- package/src/context/localize.tsx +202 -0
- package/src/context/modal.tsx +116 -0
- package/src/context/snackBar.tsx +114 -0
- package/src/context/theme.tsx +217 -0
- package/src/context/toast.tsx +114 -0
- package/src/core/hooks.ts +33 -0
- package/src/core/index.tsx +126 -0
- package/src/helpers/index.ts +20 -0
- package/src/helpers/locale/index.ts +28 -0
- package/src/helpers/portalize/Consumer.tsx +53 -0
- package/src/helpers/portalize/Host.tsx +122 -0
- package/src/helpers/portalize/Manager.tsx +75 -0
- package/src/helpers/portalize/Portal.tsx +30 -0
- package/src/helpers/portalize/context/index.ts +49 -0
- package/src/helpers/portalize/hooks/useKey.ts +49 -0
- package/src/helpers/portalize/index.tsx +15 -0
- package/src/helpers/theme/palette.ts +90 -0
- package/src/helpers/theme/shapes.ts +106 -0
- package/src/helpers/theme/typography.ts +46 -0
- package/src/index.tsx +117 -0
- package/src/types/bottomSheet.ts +23 -0
- package/src/types/dialog.ts +23 -0
- package/src/types/icon.ts +20 -0
- package/src/types/index.ts +217 -0
- package/src/types/locale.ts +30 -0
- package/src/types/modal.ts +25 -0
- package/src/types/portalize.ts +3 -0
- package/src/types/snackBar.ts +24 -0
- package/src/types/theme.ts +30 -0
- package/src/types/toast.ts +24 -0
- package/src/utils/index.ts +65 -0
- package/src/variants/locales/default.json +208 -0
- package/src/variants/themes/default.json +669 -0
|
@@ -0,0 +1,314 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
import { useEffect, useState, useRef } from "react";
|
|
4
|
+
import { TouchableWithoutFeedback, PanResponder, Platform, Animated, Easing, View } from "react-native";
|
|
5
|
+
import stylesheet, { getSnackBarType, useStyles } from "./stylesheet.js";
|
|
6
|
+
import { NCoreUIKitTheme } from "../../core/hooks.js";
|
|
7
|
+
import { useSafeAreaInsets } from "react-native-safe-area-context";
|
|
8
|
+
import { safeGlobal } from "../../types/index.js";
|
|
9
|
+
import { X as XIcon } from "lucide-react-native";
|
|
10
|
+
import { Portal } from "../../helpers/portalize/index.js";
|
|
11
|
+
import { windowHeight } from "../../utils/index.js";
|
|
12
|
+
import Button from "../button/index.js";
|
|
13
|
+
import Text from "../text/index.js";
|
|
14
|
+
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
15
|
+
const SnackBar = ({
|
|
16
|
+
isCloseOnPressActionButton = true,
|
|
17
|
+
closeAnimationDelay = 350,
|
|
18
|
+
openAnimationDelay = 200,
|
|
19
|
+
contentContainerStyle,
|
|
20
|
+
autoCloseDelay = 5000,
|
|
21
|
+
isCloseOnPress = true,
|
|
22
|
+
isShowAction = true,
|
|
23
|
+
isFullWidth = false,
|
|
24
|
+
isInlineSafeArea,
|
|
25
|
+
icon: CustomIcon,
|
|
26
|
+
type = "neutral",
|
|
27
|
+
customTheme,
|
|
28
|
+
onClosed,
|
|
29
|
+
subTitle,
|
|
30
|
+
children,
|
|
31
|
+
onPress,
|
|
32
|
+
action,
|
|
33
|
+
style,
|
|
34
|
+
title,
|
|
35
|
+
id
|
|
36
|
+
}) => {
|
|
37
|
+
const {
|
|
38
|
+
radiuses,
|
|
39
|
+
colors,
|
|
40
|
+
spaces
|
|
41
|
+
} = NCoreUIKitTheme.useContext(customTheme);
|
|
42
|
+
const {
|
|
43
|
+
top
|
|
44
|
+
} = useSafeAreaInsets();
|
|
45
|
+
const [isMeasured, setIsMeasured] = useState(false);
|
|
46
|
+
const contentHeight = useRef(windowHeight);
|
|
47
|
+
const transformAnim = useRef(new Animated.Value(-contentHeight.current + -top + -spaces.spacingSm)).current;
|
|
48
|
+
const opacityAnim = useRef(new Animated.Value(0)).current;
|
|
49
|
+
const currentType = getSnackBarType({
|
|
50
|
+
type
|
|
51
|
+
});
|
|
52
|
+
const {
|
|
53
|
+
contentContainer: contentContainerDynamicStyle,
|
|
54
|
+
containerObject: containerObjectDynamicStyle,
|
|
55
|
+
iconContainer: iconContainerDynamicStyle,
|
|
56
|
+
container: containerDynamicStyle,
|
|
57
|
+
subTitle: subTitleDynamicStyle,
|
|
58
|
+
action: actionDynamicStyle,
|
|
59
|
+
title: titleDynamicStyle
|
|
60
|
+
} = useStyles({
|
|
61
|
+
isInlineSafeArea,
|
|
62
|
+
safeAreaTop: top,
|
|
63
|
+
isFullWidth,
|
|
64
|
+
currentType,
|
|
65
|
+
radiuses,
|
|
66
|
+
spaces,
|
|
67
|
+
colors,
|
|
68
|
+
type
|
|
69
|
+
});
|
|
70
|
+
useEffect(() => {
|
|
71
|
+
if (isMeasured) {
|
|
72
|
+
transformAnim.setValue(-contentHeight.current + -top + -spaces.spacingSm);
|
|
73
|
+
Animated.parallel([Animated.timing(opacityAnim, {
|
|
74
|
+
duration: openAnimationDelay,
|
|
75
|
+
useNativeDriver: true,
|
|
76
|
+
easing: Easing.linear,
|
|
77
|
+
toValue: 1
|
|
78
|
+
}), Animated.timing(transformAnim, {
|
|
79
|
+
duration: openAnimationDelay,
|
|
80
|
+
useNativeDriver: true,
|
|
81
|
+
easing: Easing.linear,
|
|
82
|
+
toValue: 0
|
|
83
|
+
})]).start();
|
|
84
|
+
setTimeout(() => {
|
|
85
|
+
closeAnimation();
|
|
86
|
+
}, autoCloseDelay);
|
|
87
|
+
}
|
|
88
|
+
}, [isMeasured]);
|
|
89
|
+
const panResponder = useRef(PanResponder.create({
|
|
90
|
+
onStartShouldSetPanResponder: () => false,
|
|
91
|
+
onMoveShouldSetPanResponderCapture: (_, gestureState) => {
|
|
92
|
+
const {
|
|
93
|
+
dy
|
|
94
|
+
} = gestureState;
|
|
95
|
+
if (Math.abs(dy) < 20) {
|
|
96
|
+
return false;
|
|
97
|
+
}
|
|
98
|
+
return true;
|
|
99
|
+
},
|
|
100
|
+
onPanResponderMove: (_, gestureState) => {
|
|
101
|
+
const {
|
|
102
|
+
moveY,
|
|
103
|
+
y0,
|
|
104
|
+
dy
|
|
105
|
+
} = gestureState;
|
|
106
|
+
if (moveY > y0) {
|
|
107
|
+
return;
|
|
108
|
+
}
|
|
109
|
+
const op = moveY / y0;
|
|
110
|
+
opacityAnim.setValue(op);
|
|
111
|
+
transformAnim.setValue(dy);
|
|
112
|
+
},
|
|
113
|
+
onPanResponderEnd: (_, gestureState) => {
|
|
114
|
+
const {
|
|
115
|
+
moveY,
|
|
116
|
+
y0,
|
|
117
|
+
vy
|
|
118
|
+
} = gestureState;
|
|
119
|
+
if (vy < -1) {
|
|
120
|
+
closeAnimation();
|
|
121
|
+
return;
|
|
122
|
+
}
|
|
123
|
+
if (y0 - moveY > 25) {
|
|
124
|
+
closeAnimation();
|
|
125
|
+
return;
|
|
126
|
+
}
|
|
127
|
+
Animated.parallel([Animated.timing(opacityAnim, {
|
|
128
|
+
duration: openAnimationDelay,
|
|
129
|
+
useNativeDriver: true,
|
|
130
|
+
easing: Easing.linear,
|
|
131
|
+
toValue: 1
|
|
132
|
+
}), Animated.timing(transformAnim, {
|
|
133
|
+
duration: openAnimationDelay,
|
|
134
|
+
useNativeDriver: true,
|
|
135
|
+
easing: Easing.linear,
|
|
136
|
+
toValue: 0
|
|
137
|
+
})]).start();
|
|
138
|
+
},
|
|
139
|
+
onPanResponderTerminationRequest: () => false,
|
|
140
|
+
onShouldBlockNativeResponder: () => true
|
|
141
|
+
})).current;
|
|
142
|
+
const closeAnimation = _onClosed => {
|
|
143
|
+
Animated.parallel([Animated.timing(transformAnim, {
|
|
144
|
+
toValue: -contentHeight.current + -top + -spaces.spacingSm,
|
|
145
|
+
duration: closeAnimationDelay,
|
|
146
|
+
useNativeDriver: true,
|
|
147
|
+
easing: Easing.linear
|
|
148
|
+
}), Animated.timing(opacityAnim, {
|
|
149
|
+
duration: closeAnimationDelay,
|
|
150
|
+
useNativeDriver: true,
|
|
151
|
+
easing: Easing.linear,
|
|
152
|
+
toValue: 0
|
|
153
|
+
})]).start(({
|
|
154
|
+
finished
|
|
155
|
+
}) => {
|
|
156
|
+
if (finished) {
|
|
157
|
+
if (onClosed) onClosed({
|
|
158
|
+
id
|
|
159
|
+
});
|
|
160
|
+
if (_onClosed) _onClosed({
|
|
161
|
+
id
|
|
162
|
+
});
|
|
163
|
+
}
|
|
164
|
+
});
|
|
165
|
+
};
|
|
166
|
+
const renderIcon = () => {
|
|
167
|
+
if (!CustomIcon) {
|
|
168
|
+
return null;
|
|
169
|
+
}
|
|
170
|
+
return /*#__PURE__*/_jsx(View, {
|
|
171
|
+
style: [stylesheet.iconContainer, iconContainerDynamicStyle],
|
|
172
|
+
children: /*#__PURE__*/_jsx(CustomIcon, {
|
|
173
|
+
color: "default",
|
|
174
|
+
size: 18
|
|
175
|
+
})
|
|
176
|
+
});
|
|
177
|
+
};
|
|
178
|
+
const renderContent = () => {
|
|
179
|
+
return /*#__PURE__*/_jsxs(View, {
|
|
180
|
+
style: [contentContainerStyle, stylesheet.contentContainer, contentContainerDynamicStyle],
|
|
181
|
+
children: [/*#__PURE__*/_jsx(Text, {
|
|
182
|
+
numberOfLines: 3,
|
|
183
|
+
style: {
|
|
184
|
+
...stylesheet.title,
|
|
185
|
+
...titleDynamicStyle
|
|
186
|
+
},
|
|
187
|
+
children: title
|
|
188
|
+
}), subTitle ? /*#__PURE__*/_jsx(Text, {
|
|
189
|
+
variant: "labelSmallSize",
|
|
190
|
+
numberOfLines: 2,
|
|
191
|
+
color: "low",
|
|
192
|
+
style: {
|
|
193
|
+
...stylesheet.subTitle,
|
|
194
|
+
...subTitleDynamicStyle
|
|
195
|
+
},
|
|
196
|
+
children: subTitle
|
|
197
|
+
}) : null]
|
|
198
|
+
});
|
|
199
|
+
};
|
|
200
|
+
const renderAction = () => {
|
|
201
|
+
if (!isShowAction) {
|
|
202
|
+
return null;
|
|
203
|
+
}
|
|
204
|
+
return /*#__PURE__*/_jsx(Button, {
|
|
205
|
+
title: action && action.title ? action.title : undefined,
|
|
206
|
+
isCustomPadding: true,
|
|
207
|
+
spreadBehaviour: "free",
|
|
208
|
+
onPress: () => {
|
|
209
|
+
if (isCloseOnPressActionButton) closeAnimation();
|
|
210
|
+
if (action && action.onPress) action.onPress({
|
|
211
|
+
closeAnimation: ({
|
|
212
|
+
onClosed: _onClosed
|
|
213
|
+
}) => closeAnimation(_onClosed)
|
|
214
|
+
});
|
|
215
|
+
},
|
|
216
|
+
icon: ({
|
|
217
|
+
color
|
|
218
|
+
}) => {
|
|
219
|
+
if (action?.title) {
|
|
220
|
+
return null;
|
|
221
|
+
}
|
|
222
|
+
return /*#__PURE__*/_jsx(XIcon, {
|
|
223
|
+
color: colors.content.icon[color ? color : "default"],
|
|
224
|
+
size: 18
|
|
225
|
+
});
|
|
226
|
+
},
|
|
227
|
+
style: {
|
|
228
|
+
...action?.style,
|
|
229
|
+
...actionDynamicStyle
|
|
230
|
+
},
|
|
231
|
+
variant: "ghost",
|
|
232
|
+
type: "neutral",
|
|
233
|
+
size: "small"
|
|
234
|
+
});
|
|
235
|
+
};
|
|
236
|
+
const renderContainer = () => {
|
|
237
|
+
return /*#__PURE__*/_jsxs(View, {
|
|
238
|
+
style: [stylesheet.containerObject, containerObjectDynamicStyle],
|
|
239
|
+
children: [renderIcon(), renderContent(), renderAction()]
|
|
240
|
+
});
|
|
241
|
+
};
|
|
242
|
+
return /*#__PURE__*/_jsx(Portal, {
|
|
243
|
+
name: "snack-bar-system",
|
|
244
|
+
children: /*#__PURE__*/_jsx(Animated.View, {
|
|
245
|
+
...(Platform.OS === "web" ? {} : panResponder.panHandlers),
|
|
246
|
+
onLayout: event => {
|
|
247
|
+
const _contentHeight = event.nativeEvent.layout.height;
|
|
248
|
+
contentHeight.current = _contentHeight;
|
|
249
|
+
setIsMeasured(true);
|
|
250
|
+
},
|
|
251
|
+
onPointerDown: Platform.OS === "web" ? evt => {
|
|
252
|
+
const nativeEvt = evt;
|
|
253
|
+
const startY = nativeEvt.clientY;
|
|
254
|
+
let lastY = startY;
|
|
255
|
+
let lastTime = Date.now();
|
|
256
|
+
let velocityY = 0;
|
|
257
|
+
const handlePointerMove = moveEvt => {
|
|
258
|
+
const dy = moveEvt.clientY - startY;
|
|
259
|
+
if (dy > 0) return; // sadece yukarı swipe
|
|
260
|
+
|
|
261
|
+
const now = Date.now();
|
|
262
|
+
const dt = now - lastTime;
|
|
263
|
+
if (dt > 0) velocityY = (moveEvt.clientY - lastY) / dt;
|
|
264
|
+
lastY = moveEvt.clientY;
|
|
265
|
+
lastTime = now;
|
|
266
|
+
const op = Math.max(0, 1 + dy / contentHeight.current);
|
|
267
|
+
opacityAnim.setValue(op);
|
|
268
|
+
transformAnim.setValue(dy);
|
|
269
|
+
};
|
|
270
|
+
const handlePointerUp = () => {
|
|
271
|
+
safeGlobal.removeEventListener("pointermove", handlePointerMove);
|
|
272
|
+
safeGlobal.removeEventListener("pointerup", handlePointerUp);
|
|
273
|
+
const dy = lastY - startY;
|
|
274
|
+
if (velocityY < -0.5 || dy < -25) {
|
|
275
|
+
closeAnimation();
|
|
276
|
+
return;
|
|
277
|
+
}
|
|
278
|
+
Animated.parallel([Animated.timing(opacityAnim, {
|
|
279
|
+
duration: openAnimationDelay,
|
|
280
|
+
useNativeDriver: true,
|
|
281
|
+
easing: Easing.linear,
|
|
282
|
+
toValue: 1
|
|
283
|
+
}), Animated.timing(transformAnim, {
|
|
284
|
+
duration: openAnimationDelay,
|
|
285
|
+
useNativeDriver: true,
|
|
286
|
+
easing: Easing.linear,
|
|
287
|
+
toValue: 0
|
|
288
|
+
})]).start();
|
|
289
|
+
};
|
|
290
|
+
safeGlobal.addEventListener("pointermove", handlePointerMove);
|
|
291
|
+
safeGlobal.addEventListener("pointerup", handlePointerUp);
|
|
292
|
+
} : undefined,
|
|
293
|
+
style: [style, stylesheet.container, containerDynamicStyle, {
|
|
294
|
+
opacity: opacityAnim,
|
|
295
|
+
transform: [{
|
|
296
|
+
translateY: transformAnim
|
|
297
|
+
}]
|
|
298
|
+
}],
|
|
299
|
+
children: /*#__PURE__*/_jsx(TouchableWithoutFeedback, {
|
|
300
|
+
onPress: () => {
|
|
301
|
+
if (onPress) onPress({
|
|
302
|
+
id
|
|
303
|
+
});
|
|
304
|
+
if (isCloseOnPress) {
|
|
305
|
+
closeAnimation();
|
|
306
|
+
}
|
|
307
|
+
},
|
|
308
|
+
children: children ? children : renderContainer()
|
|
309
|
+
})
|
|
310
|
+
})
|
|
311
|
+
});
|
|
312
|
+
};
|
|
313
|
+
export default SnackBar;
|
|
314
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["useEffect","useState","useRef","TouchableWithoutFeedback","PanResponder","Platform","Animated","Easing","View","stylesheet","getSnackBarType","useStyles","NCoreUIKitTheme","useSafeAreaInsets","safeGlobal","X","XIcon","Portal","windowHeight","Button","Text","jsx","_jsx","jsxs","_jsxs","SnackBar","isCloseOnPressActionButton","closeAnimationDelay","openAnimationDelay","contentContainerStyle","autoCloseDelay","isCloseOnPress","isShowAction","isFullWidth","isInlineSafeArea","icon","CustomIcon","type","customTheme","onClosed","subTitle","children","onPress","action","style","title","id","radiuses","colors","spaces","useContext","top","isMeasured","setIsMeasured","contentHeight","transformAnim","Value","current","spacingSm","opacityAnim","currentType","contentContainer","contentContainerDynamicStyle","containerObject","containerObjectDynamicStyle","iconContainer","iconContainerDynamicStyle","container","containerDynamicStyle","subTitleDynamicStyle","actionDynamicStyle","titleDynamicStyle","safeAreaTop","setValue","parallel","timing","duration","useNativeDriver","easing","linear","toValue","start","setTimeout","closeAnimation","panResponder","create","onStartShouldSetPanResponder","onMoveShouldSetPanResponderCapture","_","gestureState","dy","Math","abs","onPanResponderMove","moveY","y0","op","onPanResponderEnd","vy","onPanResponderTerminationRequest","onShouldBlockNativeResponder","_onClosed","finished","renderIcon","color","size","renderContent","numberOfLines","variant","renderAction","undefined","isCustomPadding","spreadBehaviour","content","renderContainer","name","OS","panHandlers","onLayout","event","_contentHeight","nativeEvent","layout","height","onPointerDown","evt","nativeEvt","startY","clientY","lastY","lastTime","Date","now","velocityY","handlePointerMove","moveEvt","dt","max","handlePointerUp","removeEventListener","addEventListener","opacity","transform","translateY"],"sourceRoot":"..\\..\\..\\..\\src","sources":["components/snackBar/index.tsx"],"mappings":";;AAAA,SAEIA,SAAS,EACTC,QAAQ,EAERC,MAAM,QACH,OAAO;AACd,SACIC,wBAAwB,EACxBC,YAAY,EACZC,QAAQ,EACRC,QAAQ,EACRC,MAAM,EACNC,IAAI,QACD,cAAc;AAErB,OAAOC,UAAU,IACbC,eAAe,EACfC,SAAS,QACN,iBAAc;AACrB,SACIC,eAAe,QACZ,qBAAkB;AACzB,SACIC,iBAAiB,QACd,gCAAgC;AACvC,SACIC,UAAU,QAEP,sBAAa;AACpB,SACIC,CAAC,IAAIC,KAAK,QACP,qBAAqB;AAC5B,SACIC,MAAM,QACH,kCAAyB;AAChC,SACIC,YAAY,QACT,sBAAa;AACpB,OAAOC,MAAM,MAAM,oBAAW;AAC9B,OAAOC,IAAI,MAAM,kBAAS;AAAC,SAAAC,GAAA,IAAAC,IAAA,EAAAC,IAAA,IAAAC,KAAA;AAE3B,MAAMC,QAA4B,GAAGA,CAAC;EAClCC,0BAA0B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EvE,MAAM,CAACwE,MAAM;YACrBC,OAAO,EAAE;UACb,CAAC,CAAC,CACL,CAAC,CAACC,KAAK,CAAC,CAAC;QACd,CAAC;QAEDnE,UAAU,CAAC8H,gBAAgB,CAAC,aAAa,EAAEN,iBAAiB,CAAC;QAC7DxH,UAAU,CAAC8H,gBAAgB,CAAC,WAAW,EAAEF,eAAe,CAAC;MAC7D,CAAC,GAAG5B,SAAU;MACdlE,KAAK,EAAE,CACHA,KAAK,EACLnC,UAAU,CAAC0D,SAAS,EACpBC,qBAAqB,EACrB;QACIyE,OAAO,EAAElF,WAAW;QACpBmF,SAAS,EAAE,CAAC;UACRC,UAAU,EAAExF;QAChB,CAAC;MACL,CAAC,CACH;MAAAd,QAAA,eAEFnB,IAAA,CAACnB,wBAAwB;QACrBuC,OAAO,EAAEA,CAAA,KAAM;UACX,IAAGA,OAAO,EAAEA,OAAO,CAAC;YAChBI;UACJ,CAAC,CAAC;UAEF,IAAGf,cAAc,EAAE;YACfoD,cAAc,CAAC,CAAC;UACpB;QACJ,CAAE;QAAA1C,QAAA,EAEDA,QAAQ,GAAGA,QAAQ,GAAGyE,eAAe,CAAC;MAAC,CAClB;IAAC,CAChB;EAAC,CACZ,CAAC;AACb,CAAC;AACD,eAAezF,QAAQ","ignoreList":[]}
|
|
@@ -0,0 +1,131 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
import { StyleSheet } from "react-native";
|
|
4
|
+
import { windowWidth } from "../../utils/index.js";
|
|
5
|
+
export const SNACK_BAR_TYPE_STYLES = {
|
|
6
|
+
primary: {
|
|
7
|
+
actionColor: "onPrimary",
|
|
8
|
+
iconColor: "emphasized",
|
|
9
|
+
containerColor: "mid",
|
|
10
|
+
subTitleColor: "low",
|
|
11
|
+
titleColor: "mid"
|
|
12
|
+
},
|
|
13
|
+
danger: {
|
|
14
|
+
subTitleColor: "dangerLow",
|
|
15
|
+
containerColor: "danger",
|
|
16
|
+
actionColor: "danger",
|
|
17
|
+
titleColor: "danger",
|
|
18
|
+
iconColor: "danger"
|
|
19
|
+
},
|
|
20
|
+
success: {
|
|
21
|
+
subTitleColor: "successLow",
|
|
22
|
+
containerColor: "success",
|
|
23
|
+
actionColor: "success",
|
|
24
|
+
titleColor: "success",
|
|
25
|
+
iconColor: "success"
|
|
26
|
+
},
|
|
27
|
+
warning: {
|
|
28
|
+
subTitleColor: "warningLow",
|
|
29
|
+
containerColor: "warning",
|
|
30
|
+
actionColor: "warning",
|
|
31
|
+
titleColor: "warning",
|
|
32
|
+
iconColor: "warning"
|
|
33
|
+
},
|
|
34
|
+
info: {
|
|
35
|
+
subTitleColor: "infoLow",
|
|
36
|
+
containerColor: "info",
|
|
37
|
+
actionColor: "info",
|
|
38
|
+
titleColor: "info",
|
|
39
|
+
iconColor: "info"
|
|
40
|
+
},
|
|
41
|
+
neutral: {
|
|
42
|
+
containerColor: "mid",
|
|
43
|
+
subTitleColor: "low",
|
|
44
|
+
actionColor: "mid",
|
|
45
|
+
titleColor: "mid",
|
|
46
|
+
iconColor: "mid"
|
|
47
|
+
}
|
|
48
|
+
};
|
|
49
|
+
export const getSnackBarType = ({
|
|
50
|
+
type
|
|
51
|
+
}) => {
|
|
52
|
+
const currentType = SNACK_BAR_TYPE_STYLES[type];
|
|
53
|
+
return currentType;
|
|
54
|
+
};
|
|
55
|
+
const stylesheet = StyleSheet.create({
|
|
56
|
+
container: {
|
|
57
|
+
position: "absolute",
|
|
58
|
+
alignSelf: "center",
|
|
59
|
+
zIndex: 99998
|
|
60
|
+
},
|
|
61
|
+
containerObject: {
|
|
62
|
+
flexDirection: "row",
|
|
63
|
+
alignItems: "center"
|
|
64
|
+
},
|
|
65
|
+
contentContainer: {
|
|
66
|
+
justifyContent: "center",
|
|
67
|
+
alignItems: "flex-start",
|
|
68
|
+
flexDirection: "column",
|
|
69
|
+
flexShrink: 1,
|
|
70
|
+
flex: 1
|
|
71
|
+
},
|
|
72
|
+
iconContainer: {
|
|
73
|
+
justifyContent: "center",
|
|
74
|
+
alignItems: "center"
|
|
75
|
+
},
|
|
76
|
+
title: {
|
|
77
|
+
textAlign: "left"
|
|
78
|
+
},
|
|
79
|
+
subTitle: {
|
|
80
|
+
textAlign: "left"
|
|
81
|
+
}
|
|
82
|
+
});
|
|
83
|
+
export const useStyles = ({
|
|
84
|
+
isInlineSafeArea,
|
|
85
|
+
isFullWidth,
|
|
86
|
+
safeAreaTop,
|
|
87
|
+
currentType,
|
|
88
|
+
radiuses,
|
|
89
|
+
colors,
|
|
90
|
+
spaces
|
|
91
|
+
}) => {
|
|
92
|
+
const styles = {
|
|
93
|
+
container: {
|
|
94
|
+
backgroundColor: colors.content.container[currentType.containerColor],
|
|
95
|
+
width: windowWidth - spaces.spacingMd * 2,
|
|
96
|
+
top: safeAreaTop + spaces.spacingSm,
|
|
97
|
+
borderRadius: radiuses.lg
|
|
98
|
+
},
|
|
99
|
+
containerObject: {
|
|
100
|
+
paddingHorizontal: spaces.spacingLg,
|
|
101
|
+
paddingVertical: spaces.spacingMd
|
|
102
|
+
},
|
|
103
|
+
contentContainer: {},
|
|
104
|
+
title: {},
|
|
105
|
+
subTitle: {
|
|
106
|
+
marginTop: spaces.spacingXs
|
|
107
|
+
},
|
|
108
|
+
iconContainer: {
|
|
109
|
+
paddingRight: spaces.spacingSm,
|
|
110
|
+
marginRight: spaces.spacingSm
|
|
111
|
+
},
|
|
112
|
+
action: {
|
|
113
|
+
paddingBottom: spaces.spacingSm,
|
|
114
|
+
paddingRight: spaces.spacingSm,
|
|
115
|
+
paddingLeft: spaces.spacingMd,
|
|
116
|
+
paddingTop: spaces.spacingSm,
|
|
117
|
+
marginLeft: spaces.spacingMd
|
|
118
|
+
}
|
|
119
|
+
};
|
|
120
|
+
if (isFullWidth) {
|
|
121
|
+
styles.container.width = windowWidth;
|
|
122
|
+
styles.container.borderRadius = 0;
|
|
123
|
+
}
|
|
124
|
+
if (isInlineSafeArea) {
|
|
125
|
+
styles.container.paddingTop = safeAreaTop;
|
|
126
|
+
styles.container.top = 0;
|
|
127
|
+
}
|
|
128
|
+
return styles;
|
|
129
|
+
};
|
|
130
|
+
export default stylesheet;
|
|
131
|
+
//# sourceMappingURL=stylesheet.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["StyleSheet","windowWidth","SNACK_BAR_TYPE_STYLES","primary","actionColor","iconColor","containerColor","subTitleColor","titleColor","danger","success","warning","info","neutral","getSnackBarType","type","currentType","stylesheet","create","container","position","alignSelf","zIndex","containerObject","flexDirection","alignItems","contentContainer","justifyContent","flexShrink","flex","iconContainer","title","textAlign","subTitle","useStyles","isInlineSafeArea","isFullWidth","safeAreaTop","radiuses","colors","spaces","styles","backgroundColor","content","width","spacingMd","top","spacingSm","borderRadius","lg","paddingHorizontal","spacingLg","paddingVertical","marginTop","spacingXs","paddingRight","marginRight","action","paddingBottom","paddingLeft","paddingTop","marginLeft"],"sourceRoot":"..\\..\\..\\..\\src","sources":["components/snackBar/stylesheet.ts"],"mappings":";;AAAA,SAGIA,UAAU,QACP,cAAc;AAUrB,SACIC,WAAW,QACR,sBAAa;AAEpB,OAAO,MAAMC,qBASZ,GAAG;EACAC,OAAO,EAAE;IACLC,WAAW,EAAE,WAAW;IACxBC,SAAS,EAAE,YAAY;IACvBC,cAAc,EAAE,KAAK;IACrBC,aAAa,EAAE,KAAK;IACpBC,UAAU,EAAE;EAChB,CAAC;EACDC,MAAM,EAAE;IACJF,aAAa,EAAE,WAAW;IAC1BD,cAAc,EAAE,QAAQ;IACxBF,WAAW,EAAE,QAAQ;IACrBI,UAAU,EAAE,QAAQ;IACpBH,SAAS,EAAE;EACf,CAAC;EACDK,OAAO,EAAE;IACLH,aAAa,EAAE,YAAY;IAC3BD,cAAc,EAAE,SAAS;IACzBF,WAAW,EAAE,SAAS;IACtBI,UAAU,EAAE,SAAS;IACrBH,SAAS,EAAE;EACf,CAAC;EACDM,OAAO,EAAE;IACLJ,aAAa,EAAE,YAAY;IAC3BD,cAAc,EAAE,SAA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@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":[],"sourceRoot":"..\\..\\..\\..\\src","sources":["components/snackBar/type.ts"],"mappings":";;AAgFC;AAAC","ignoreList":[]}
|
|
@@ -0,0 +1,101 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
import { View } from "react-native";
|
|
4
|
+
import stylesheet, { getStateCardType, useStyles } from "./stylesheet.js";
|
|
5
|
+
import { NCoreUIKitTheme } from "../../core/hooks.js";
|
|
6
|
+
import Text from "../text/index.js";
|
|
7
|
+
import Button from "../button/index.js";
|
|
8
|
+
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
9
|
+
const StateCard = ({
|
|
10
|
+
type = "neutral",
|
|
11
|
+
icon: IconProp,
|
|
12
|
+
subTitleStyle,
|
|
13
|
+
customTheme,
|
|
14
|
+
titleStyle,
|
|
15
|
+
subTitle,
|
|
16
|
+
iconSize,
|
|
17
|
+
action,
|
|
18
|
+
title,
|
|
19
|
+
style,
|
|
20
|
+
...props
|
|
21
|
+
}) => {
|
|
22
|
+
const {
|
|
23
|
+
spaces
|
|
24
|
+
} = NCoreUIKitTheme.useContext(customTheme);
|
|
25
|
+
const currentType = getStateCardType({
|
|
26
|
+
type
|
|
27
|
+
});
|
|
28
|
+
const {
|
|
29
|
+
titleContainer: titleContainerDynamicStyle,
|
|
30
|
+
actionButton: actionButtonDynamicStyle,
|
|
31
|
+
container: containerDynamicStyle,
|
|
32
|
+
subTitle: subTitleDynamicStyle,
|
|
33
|
+
title: titleDynamicStyle,
|
|
34
|
+
icon: iconDynamicStyle
|
|
35
|
+
} = useStyles({
|
|
36
|
+
spaces
|
|
37
|
+
});
|
|
38
|
+
const iconProps = {
|
|
39
|
+
color: currentType.iconColor
|
|
40
|
+
};
|
|
41
|
+
const titleProps = {
|
|
42
|
+
color: currentType.titleColor
|
|
43
|
+
};
|
|
44
|
+
const subTitleProps = {
|
|
45
|
+
color: currentType.subTitleColor
|
|
46
|
+
};
|
|
47
|
+
const renderIcon = () => {
|
|
48
|
+
if (!IconProp) {
|
|
49
|
+
return null;
|
|
50
|
+
}
|
|
51
|
+
return /*#__PURE__*/_jsx(IconProp, {
|
|
52
|
+
color: iconProps.color,
|
|
53
|
+
size: iconSize ? iconSize : 75,
|
|
54
|
+
style: iconDynamicStyle
|
|
55
|
+
});
|
|
56
|
+
};
|
|
57
|
+
const renderTitle = () => {
|
|
58
|
+
if (!title) {
|
|
59
|
+
return null;
|
|
60
|
+
}
|
|
61
|
+
return /*#__PURE__*/_jsx(View, {
|
|
62
|
+
style: [stylesheet.titleContainer, titleContainerDynamicStyle],
|
|
63
|
+
children: /*#__PURE__*/_jsx(Text, {
|
|
64
|
+
variant: "headlineSmallSize",
|
|
65
|
+
style: [titleStyle, stylesheet.title, titleDynamicStyle],
|
|
66
|
+
...titleProps,
|
|
67
|
+
children: title
|
|
68
|
+
})
|
|
69
|
+
});
|
|
70
|
+
};
|
|
71
|
+
const renderSubtitle = () => {
|
|
72
|
+
if (!subTitle) {
|
|
73
|
+
return null;
|
|
74
|
+
}
|
|
75
|
+
return /*#__PURE__*/_jsx(Text, {
|
|
76
|
+
...subTitleProps,
|
|
77
|
+
variant: "bodyMediumSize",
|
|
78
|
+
style: [subTitleStyle, stylesheet.subTitle, subTitleDynamicStyle],
|
|
79
|
+
children: subTitle
|
|
80
|
+
});
|
|
81
|
+
};
|
|
82
|
+
const renderAction = () => {
|
|
83
|
+
if (!action) {
|
|
84
|
+
return null;
|
|
85
|
+
}
|
|
86
|
+
return /*#__PURE__*/_jsx(Button, {
|
|
87
|
+
size: "small",
|
|
88
|
+
...action,
|
|
89
|
+
spreadBehaviour: "free",
|
|
90
|
+
type: type,
|
|
91
|
+
style: [action.style, actionButtonDynamicStyle]
|
|
92
|
+
});
|
|
93
|
+
};
|
|
94
|
+
return /*#__PURE__*/_jsxs(View, {
|
|
95
|
+
...props,
|
|
96
|
+
style: [style, stylesheet.container, containerDynamicStyle],
|
|
97
|
+
children: [renderIcon(), renderTitle(), renderSubtitle(), renderAction()]
|
|
98
|
+
});
|
|
99
|
+
};
|
|
100
|
+
export default StateCard;
|
|
101
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["View","stylesheet","getStateCardType","useStyles","NCoreUIKitTheme","Text","Button","jsx","_jsx","jsxs","_jsxs","StateCard","type","icon","IconProp","subTitleStyle","customTheme","titleStyle","subTitle","iconSize","action","title","style","props","spaces","useContext","currentType","titleContainer","titleContainerDynamicStyle","actionButton","actionButtonDynamicStyle","container","containerDynamicStyle","subTitleDynamicStyle","titleDynamicStyle","iconDynamicStyle","iconProps","color","iconColor","titleProps","titleColor","subTitleProps","subTitleColor","renderIcon","size","renderTitle","children","variant","renderSubtitle","renderAction","spreadBehaviour"],"sourceRoot":"..\\..\\..\\..\\src","sources":["components/stateCard/index.tsx"],"mappings":";;AAGA,SACIA,IAAI,QACD,cAAc;AAErB,OAAOC,UAAU,IACbC,gBAAgB,EAChBC,SAAS,QACN,iBAAc;AACrB,SACIC,eAAe,QACZ,qBAAkB;AAKzB,OAAOC,IAAI,MAAM,kBAAS;AAC1B,OAAOC,MAAM,MAAM,oBAAW;AAAC,SAAAC,GAAA,IAAAC,IAAA,EAAAC,IAAA,IAAAC,KAAA;AAE/B,MAAMC,SAA8B,GAAGA,CAAC;EACpCC,IAAI,GAAG,SAAS;EAChBC,IAAI,EAAEC,QAAQ;EACdC,aAAa;EACbC,WAAW;EACXC,UAAU;EACVC,QAAQ;EACRC,QAAQ;EACRC,MAAM;EACNC,KAAK;EACLC,KAAK;EACL,GAAGC;AACP,CAAC,KAAK;EACF,MAAM;IACFC;EACJ,CAAC,GAAGpB,eAAe,CAACqB,UAAU,CAACT,WAAW,CAAC;EAE3C,MAAMU,WAAW,GAAGxB,gBAAgB,CAAC;IACjCU;EACJ,CAAC,CAAC;EAEF,MAAM;IACFe,cAAc,EAAEC,0BAA0B;IAC1CC,YAAY,EAA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aAAa;MACjBM,OAAO,EAAC,gBAAgB;MACxBzB,KAAK,EAAE,CACHP,aAAa,EACbd,UAAU,CAACiB,QAAQ,EACnBe,oBAAoB,CACtB;MAAAa,QAAA,EAED5B;IAAQ,CACP,CAAC;EACX,CAAC;EAED,MAAM+B,YAAY,GAAGA,CAAA,KAAM;IACvB,IAAG,CAAC7B,MAAM,EAAE;MACR,OAAO,IAAI;IACf;IAEA,oBAAOZ,IAAA,CAACF,MAAM;MACVsC,IAAI,EAAC,OAAO;MAAA,GACRxB,MAAM;MACV8B,eAAe,EAAC,MAAM;MACtBtC,IAAI,EAAEA,IAAK;MACXU,KAAK,EAAE,CACHF,MAAM,CAACE,KAAK,EACZQ,wBAAwB;IAC1B,CACL,CAAC;EACN,CAAC;EAED,oBAAOpB,KAAA,CAACV,IAAI;IAAA,GACJuB,KAAK;IACTD,KAAK,EAAE,CACHA,KAAK,EACLrB,UAAU,CAAC8B,SAAS,EACpBC,qBAAqB,CACvB;IAAAc,QAAA,GAEDH,UAAU,CAAC,CAAC,EACZE,WAAW,CAAC,CAAC,EACbG,cAAc,CAAC,CAAC,EAChBC,YAAY,CAAC,CAAC;EAAA,CACb,CAAC;AACX,CAAC;AACD,eAAetC,SAAS","ignoreList":[]}
|
|
@@ -0,0 +1,96 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
import { StyleSheet } from "react-native";
|
|
4
|
+
export const CHECK_BOX_TYPE_STYLES = {
|
|
5
|
+
primary: {
|
|
6
|
+
iconColor: "emphasized",
|
|
7
|
+
containerColor: "mid",
|
|
8
|
+
subTitleColor: "low",
|
|
9
|
+
titleColor: "mid"
|
|
10
|
+
},
|
|
11
|
+
danger: {
|
|
12
|
+
subTitleColor: "dangerLow",
|
|
13
|
+
containerColor: "danger",
|
|
14
|
+
titleColor: "danger",
|
|
15
|
+
iconColor: "danger"
|
|
16
|
+
},
|
|
17
|
+
success: {
|
|
18
|
+
subTitleColor: "successLow",
|
|
19
|
+
containerColor: "success",
|
|
20
|
+
titleColor: "success",
|
|
21
|
+
iconColor: "success"
|
|
22
|
+
},
|
|
23
|
+
warning: {
|
|
24
|
+
subTitleColor: "warningLow",
|
|
25
|
+
containerColor: "warning",
|
|
26
|
+
titleColor: "warning",
|
|
27
|
+
iconColor: "warning"
|
|
28
|
+
},
|
|
29
|
+
info: {
|
|
30
|
+
subTitleColor: "infoLow",
|
|
31
|
+
containerColor: "info",
|
|
32
|
+
titleColor: "info",
|
|
33
|
+
iconColor: "info"
|
|
34
|
+
},
|
|
35
|
+
neutral: {
|
|
36
|
+
iconColor: "emphasized",
|
|
37
|
+
containerColor: "mid",
|
|
38
|
+
subTitleColor: "low",
|
|
39
|
+
titleColor: "mid"
|
|
40
|
+
}
|
|
41
|
+
};
|
|
42
|
+
export const getStateCardType = ({
|
|
43
|
+
type
|
|
44
|
+
}) => {
|
|
45
|
+
const currentType = CHECK_BOX_TYPE_STYLES[type];
|
|
46
|
+
return currentType;
|
|
47
|
+
};
|
|
48
|
+
const stylesheet = StyleSheet.create({
|
|
49
|
+
container: {
|
|
50
|
+
backgroundColor: "transparent",
|
|
51
|
+
justifyContent: "center",
|
|
52
|
+
flexDirection: "column",
|
|
53
|
+
alignItems: "center"
|
|
54
|
+
},
|
|
55
|
+
titleContainer: {
|
|
56
|
+
justifyContent: "flex-start",
|
|
57
|
+
flexDirection: "row",
|
|
58
|
+
alignItems: "center"
|
|
59
|
+
},
|
|
60
|
+
title: {
|
|
61
|
+
textAlign: "center",
|
|
62
|
+
margin: 0
|
|
63
|
+
},
|
|
64
|
+
subTitle: {
|
|
65
|
+
textAlign: "center"
|
|
66
|
+
}
|
|
67
|
+
});
|
|
68
|
+
export const useStyles = ({
|
|
69
|
+
spaces
|
|
70
|
+
}) => {
|
|
71
|
+
const styles = {
|
|
72
|
+
container: {
|
|
73
|
+
padding: spaces.spacingSm
|
|
74
|
+
},
|
|
75
|
+
titleContainer: {},
|
|
76
|
+
icon: {
|
|
77
|
+
marginBottom: spaces.spacingXs,
|
|
78
|
+
marginTop: spaces.spacingXs
|
|
79
|
+
},
|
|
80
|
+
title: {
|
|
81
|
+
marginBottom: spaces.spacingXs,
|
|
82
|
+
marginTop: spaces.spacingXs
|
|
83
|
+
},
|
|
84
|
+
subTitle: {
|
|
85
|
+
marginBottom: spaces.spacingXs,
|
|
86
|
+
marginTop: spaces.spacingXs
|
|
87
|
+
},
|
|
88
|
+
actionButton: {
|
|
89
|
+
marginBottom: spaces.spacingXs,
|
|
90
|
+
marginTop: spaces.spacingXs
|
|
91
|
+
}
|
|
92
|
+
};
|
|
93
|
+
return styles;
|
|
94
|
+
};
|
|
95
|
+
export default stylesheet;
|
|
96
|
+
//# sourceMappingURL=stylesheet.js.map
|