@webority-technologies/mobile 0.0.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +399 -0
- package/lib/commonjs/api/publicClient.js +73 -0
- package/lib/commonjs/api/userClient.js +290 -0
- package/lib/commonjs/auth/authStore.js +107 -0
- package/lib/commonjs/auth/index.js +44 -0
- package/lib/commonjs/auth/jwt.js +84 -0
- package/lib/commonjs/components/Accordion/Accordion.js +257 -0
- package/lib/commonjs/components/Accordion/index.js +26 -0
- package/lib/commonjs/components/Avatar/Avatar.js +283 -0
- package/lib/commonjs/components/Avatar/index.js +26 -0
- package/lib/commonjs/components/Badge/Badge.js +212 -0
- package/lib/commonjs/components/Badge/index.js +20 -0
- package/lib/commonjs/components/Banner/Banner.js +276 -0
- package/lib/commonjs/components/Banner/index.js +20 -0
- package/lib/commonjs/components/BottomNavigation/BottomNavigation.js +288 -0
- package/lib/commonjs/components/BottomNavigation/index.js +20 -0
- package/lib/commonjs/components/BottomSheet/BottomSheet.js +367 -0
- package/lib/commonjs/components/BottomSheet/index.js +20 -0
- package/lib/commonjs/components/Button/Button.js +281 -0
- package/lib/commonjs/components/Button/index.js +20 -0
- package/lib/commonjs/components/Card/Card.js +194 -0
- package/lib/commonjs/components/Card/index.js +20 -0
- package/lib/commonjs/components/Carousel/Carousel.js +475 -0
- package/lib/commonjs/components/Carousel/index.js +20 -0
- package/lib/commonjs/components/Checkbox/Checkbox.js +165 -0
- package/lib/commonjs/components/Checkbox/index.js +20 -0
- package/lib/commonjs/components/Chip/Chip.js +272 -0
- package/lib/commonjs/components/Chip/index.js +20 -0
- package/lib/commonjs/components/DatePicker/DatePicker.js +813 -0
- package/lib/commonjs/components/DatePicker/index.js +20 -0
- package/lib/commonjs/components/DateRangePicker/DateRangePicker.js +622 -0
- package/lib/commonjs/components/DateRangePicker/index.js +20 -0
- package/lib/commonjs/components/Dialog/Dialog.js +215 -0
- package/lib/commonjs/components/Dialog/index.js +20 -0
- package/lib/commonjs/components/Divider/Divider.js +118 -0
- package/lib/commonjs/components/Divider/index.js +20 -0
- package/lib/commonjs/components/Drawer/Drawer.js +344 -0
- package/lib/commonjs/components/Drawer/index.js +20 -0
- package/lib/commonjs/components/EmptyState/EmptyState.js +201 -0
- package/lib/commonjs/components/EmptyState/index.js +20 -0
- package/lib/commonjs/components/FAB/FAB.js +457 -0
- package/lib/commonjs/components/FAB/index.js +26 -0
- package/lib/commonjs/components/Field/Field.js +127 -0
- package/lib/commonjs/components/Field/index.js +20 -0
- package/lib/commonjs/components/ForceUpdateDialog/ForceUpdateDialog.js +81 -0
- package/lib/commonjs/components/ForceUpdateDialog/index.js +20 -0
- package/lib/commonjs/components/Header/Header.js +339 -0
- package/lib/commonjs/components/Header/index.js +20 -0
- package/lib/commonjs/components/Icon/Icon.js +120 -0
- package/lib/commonjs/components/Icon/index.js +20 -0
- package/lib/commonjs/components/ImageGallery/ImageGallery.js +463 -0
- package/lib/commonjs/components/ImageGallery/index.js +20 -0
- package/lib/commonjs/components/Input/Input.js +390 -0
- package/lib/commonjs/components/Input/index.js +20 -0
- package/lib/commonjs/components/ListItem/ListItem.js +241 -0
- package/lib/commonjs/components/ListItem/index.js +20 -0
- package/lib/commonjs/components/LoadingSpinner/LoadingSpinner.js +183 -0
- package/lib/commonjs/components/LoadingSpinner/index.js +20 -0
- package/lib/commonjs/components/Modal/Modal.js +239 -0
- package/lib/commonjs/components/Modal/index.js +20 -0
- package/lib/commonjs/components/NumberInput/NumberInput.js +392 -0
- package/lib/commonjs/components/NumberInput/index.js +20 -0
- package/lib/commonjs/components/OTPInput/OTPInput.js +375 -0
- package/lib/commonjs/components/OTPInput/index.js +20 -0
- package/lib/commonjs/components/ProgressBar/ProgressBar.js +149 -0
- package/lib/commonjs/components/ProgressBar/index.js +20 -0
- package/lib/commonjs/components/Radio/Radio.js +160 -0
- package/lib/commonjs/components/Radio/RadioGroup.js +43 -0
- package/lib/commonjs/components/Radio/index.js +39 -0
- package/lib/commonjs/components/Rating/Rating.js +236 -0
- package/lib/commonjs/components/Rating/index.js +20 -0
- package/lib/commonjs/components/SearchBar/SearchBar.js +274 -0
- package/lib/commonjs/components/SearchBar/index.js +20 -0
- package/lib/commonjs/components/SegmentedControl/SegmentedControl.js +184 -0
- package/lib/commonjs/components/SegmentedControl/index.js +20 -0
- package/lib/commonjs/components/Select/Select.js +540 -0
- package/lib/commonjs/components/Select/index.js +20 -0
- package/lib/commonjs/components/SkeletonLoader/SkeletonContent.js +191 -0
- package/lib/commonjs/components/SkeletonLoader/SkeletonLoader.js +311 -0
- package/lib/commonjs/components/SkeletonLoader/index.js +57 -0
- package/lib/commonjs/components/Slider/Slider.js +443 -0
- package/lib/commonjs/components/Slider/index.js +20 -0
- package/lib/commonjs/components/Stepper/Stepper.js +403 -0
- package/lib/commonjs/components/Stepper/index.js +20 -0
- package/lib/commonjs/components/Swipeable/Swipeable.js +349 -0
- package/lib/commonjs/components/Swipeable/index.js +20 -0
- package/lib/commonjs/components/Switch/Switch.js +173 -0
- package/lib/commonjs/components/Switch/index.js +20 -0
- package/lib/commonjs/components/Tabs/Tabs.js +204 -0
- package/lib/commonjs/components/Tabs/index.js +20 -0
- package/lib/commonjs/components/TimePicker/TimePicker.js +551 -0
- package/lib/commonjs/components/TimePicker/index.js +20 -0
- package/lib/commonjs/components/Toast/Toast.js +273 -0
- package/lib/commonjs/components/Toast/ToastProvider.js +195 -0
- package/lib/commonjs/components/Toast/index.js +39 -0
- package/lib/commonjs/components/Tooltip/Tooltip.js +363 -0
- package/lib/commonjs/components/Tooltip/index.js +20 -0
- package/lib/commonjs/components/index.js +392 -0
- package/lib/commonjs/config/index.js +63 -0
- package/lib/commonjs/formatters/currency.js +61 -0
- package/lib/commonjs/formatters/date.js +156 -0
- package/lib/commonjs/formatters/index.js +77 -0
- package/lib/commonjs/formatters/initials.js +28 -0
- package/lib/commonjs/formatters/number.js +76 -0
- package/lib/commonjs/formatters/phone.js +59 -0
- package/lib/commonjs/hooks/index.js +27 -0
- package/lib/commonjs/hooks/useDebounce.js +17 -0
- package/lib/commonjs/hooks/usePressAnimation.js +44 -0
- package/lib/commonjs/hooks/useToggle.js +22 -0
- package/lib/commonjs/index.js +628 -0
- package/lib/commonjs/initSDK.js +47 -0
- package/lib/commonjs/initUI.js +24 -0
- package/lib/commonjs/initUserAuth.js +40 -0
- package/lib/commonjs/logger/index.js +127 -0
- package/lib/commonjs/network/NetworkStatusBanner.js +89 -0
- package/lib/commonjs/network/index.js +32 -0
- package/lib/commonjs/network/networkStatus.js +88 -0
- package/lib/commonjs/package.json +1 -0
- package/lib/commonjs/permissions/index.js +180 -0
- package/lib/commonjs/storage/index.js +187 -0
- package/lib/commonjs/theme/ThemeContext.js +73 -0
- package/lib/commonjs/theme/index.js +93 -0
- package/lib/commonjs/theme/merge.js +30 -0
- package/lib/commonjs/theme/tokens.js +319 -0
- package/lib/commonjs/theme/types.js +6 -0
- package/lib/commonjs/types/vector-icons.d.js +2 -0
- package/lib/commonjs/utils/dimensions.js +31 -0
- package/lib/commonjs/utils/hapticUtils.js +57 -0
- package/lib/commonjs/utils/imageCompression.js +51 -0
- package/lib/commonjs/utils/index.js +83 -0
- package/lib/commonjs/utils/responsive.js +48 -0
- package/lib/commonjs/utils/shadows.js +12 -0
- package/lib/commonjs/utils/spacing.js +86 -0
- package/lib/commonjs/validators/index.js +165 -0
- package/lib/commonjs/versionCheck/index.js +338 -0
- package/lib/module/api/publicClient.js +69 -0
- package/lib/module/api/userClient.js +283 -0
- package/lib/module/auth/authStore.js +100 -0
- package/lib/module/auth/index.js +5 -0
- package/lib/module/auth/jwt.js +78 -0
- package/lib/module/components/Accordion/Accordion.js +251 -0
- package/lib/module/components/Accordion/index.js +4 -0
- package/lib/module/components/Avatar/Avatar.js +278 -0
- package/lib/module/components/Avatar/index.js +4 -0
- package/lib/module/components/Badge/Badge.js +208 -0
- package/lib/module/components/Badge/index.js +4 -0
- package/lib/module/components/Banner/Banner.js +272 -0
- package/lib/module/components/Banner/index.js +4 -0
- package/lib/module/components/BottomNavigation/BottomNavigation.js +284 -0
- package/lib/module/components/BottomNavigation/index.js +4 -0
- package/lib/module/components/BottomSheet/BottomSheet.js +363 -0
- package/lib/module/components/BottomSheet/index.js +4 -0
- package/lib/module/components/Button/Button.js +277 -0
- package/lib/module/components/Button/index.js +4 -0
- package/lib/module/components/Card/Card.js +190 -0
- package/lib/module/components/Card/index.js +4 -0
- package/lib/module/components/Carousel/Carousel.js +471 -0
- package/lib/module/components/Carousel/index.js +4 -0
- package/lib/module/components/Checkbox/Checkbox.js +161 -0
- package/lib/module/components/Checkbox/index.js +4 -0
- package/lib/module/components/Chip/Chip.js +268 -0
- package/lib/module/components/Chip/index.js +4 -0
- package/lib/module/components/DatePicker/DatePicker.js +808 -0
- package/lib/module/components/DatePicker/index.js +4 -0
- package/lib/module/components/DateRangePicker/DateRangePicker.js +618 -0
- package/lib/module/components/DateRangePicker/index.js +4 -0
- package/lib/module/components/Dialog/Dialog.js +210 -0
- package/lib/module/components/Dialog/index.js +4 -0
- package/lib/module/components/Divider/Divider.js +114 -0
- package/lib/module/components/Divider/index.js +4 -0
- package/lib/module/components/Drawer/Drawer.js +340 -0
- package/lib/module/components/Drawer/index.js +4 -0
- package/lib/module/components/EmptyState/EmptyState.js +197 -0
- package/lib/module/components/EmptyState/index.js +4 -0
- package/lib/module/components/FAB/FAB.js +452 -0
- package/lib/module/components/FAB/index.js +4 -0
- package/lib/module/components/Field/Field.js +123 -0
- package/lib/module/components/Field/index.js +4 -0
- package/lib/module/components/ForceUpdateDialog/ForceUpdateDialog.js +75 -0
- package/lib/module/components/ForceUpdateDialog/index.js +4 -0
- package/lib/module/components/Header/Header.js +335 -0
- package/lib/module/components/Header/index.js +4 -0
- package/lib/module/components/Icon/Icon.js +111 -0
- package/lib/module/components/Icon/index.js +4 -0
- package/lib/module/components/ImageGallery/ImageGallery.js +458 -0
- package/lib/module/components/ImageGallery/index.js +4 -0
- package/lib/module/components/Input/Input.js +384 -0
- package/lib/module/components/Input/index.js +4 -0
- package/lib/module/components/ListItem/ListItem.js +237 -0
- package/lib/module/components/ListItem/index.js +4 -0
- package/lib/module/components/LoadingSpinner/LoadingSpinner.js +179 -0
- package/lib/module/components/LoadingSpinner/index.js +4 -0
- package/lib/module/components/Modal/Modal.js +235 -0
- package/lib/module/components/Modal/index.js +4 -0
- package/lib/module/components/NumberInput/NumberInput.js +388 -0
- package/lib/module/components/NumberInput/index.js +4 -0
- package/lib/module/components/OTPInput/OTPInput.js +371 -0
- package/lib/module/components/OTPInput/index.js +4 -0
- package/lib/module/components/ProgressBar/ProgressBar.js +145 -0
- package/lib/module/components/ProgressBar/index.js +4 -0
- package/lib/module/components/Radio/Radio.js +155 -0
- package/lib/module/components/Radio/RadioGroup.js +38 -0
- package/lib/module/components/Radio/index.js +5 -0
- package/lib/module/components/Rating/Rating.js +232 -0
- package/lib/module/components/Rating/index.js +4 -0
- package/lib/module/components/SearchBar/SearchBar.js +270 -0
- package/lib/module/components/SearchBar/index.js +4 -0
- package/lib/module/components/SegmentedControl/SegmentedControl.js +180 -0
- package/lib/module/components/SegmentedControl/index.js +4 -0
- package/lib/module/components/Select/Select.js +536 -0
- package/lib/module/components/Select/index.js +4 -0
- package/lib/module/components/SkeletonLoader/SkeletonContent.js +186 -0
- package/lib/module/components/SkeletonLoader/SkeletonLoader.js +301 -0
- package/lib/module/components/SkeletonLoader/index.js +5 -0
- package/lib/module/components/Slider/Slider.js +439 -0
- package/lib/module/components/Slider/index.js +4 -0
- package/lib/module/components/Stepper/Stepper.js +399 -0
- package/lib/module/components/Stepper/index.js +4 -0
- package/lib/module/components/Swipeable/Swipeable.js +344 -0
- package/lib/module/components/Swipeable/index.js +4 -0
- package/lib/module/components/Switch/Switch.js +169 -0
- package/lib/module/components/Switch/index.js +4 -0
- package/lib/module/components/Tabs/Tabs.js +200 -0
- package/lib/module/components/Tabs/index.js +4 -0
- package/lib/module/components/TimePicker/TimePicker.js +545 -0
- package/lib/module/components/TimePicker/index.js +4 -0
- package/lib/module/components/Toast/Toast.js +268 -0
- package/lib/module/components/Toast/ToastProvider.js +187 -0
- package/lib/module/components/Toast/index.js +5 -0
- package/lib/module/components/Tooltip/Tooltip.js +358 -0
- package/lib/module/components/Tooltip/index.js +4 -0
- package/lib/module/components/index.js +47 -0
- package/lib/module/config/index.js +55 -0
- package/lib/module/formatters/currency.js +56 -0
- package/lib/module/formatters/date.js +148 -0
- package/lib/module/formatters/index.js +8 -0
- package/lib/module/formatters/initials.js +23 -0
- package/lib/module/formatters/number.js +69 -0
- package/lib/module/formatters/phone.js +53 -0
- package/lib/module/hooks/index.js +6 -0
- package/lib/module/hooks/useDebounce.js +12 -0
- package/lib/module/hooks/usePressAnimation.js +39 -0
- package/lib/module/hooks/useToggle.js +17 -0
- package/lib/module/index.js +37 -0
- package/lib/module/initSDK.js +42 -0
- package/lib/module/initUI.js +19 -0
- package/lib/module/initUserAuth.js +36 -0
- package/lib/module/logger/index.js +123 -0
- package/lib/module/network/NetworkStatusBanner.js +83 -0
- package/lib/module/network/index.js +5 -0
- package/lib/module/network/networkStatus.js +81 -0
- package/lib/module/package.json +1 -0
- package/lib/module/permissions/index.js +177 -0
- package/lib/module/storage/index.js +183 -0
- package/lib/module/theme/ThemeContext.js +65 -0
- package/lib/module/theme/index.js +48 -0
- package/lib/module/theme/merge.js +25 -0
- package/lib/module/theme/tokens.js +315 -0
- package/lib/module/theme/types.js +4 -0
- package/lib/module/types/vector-icons.d.js +2 -0
- package/lib/module/utils/dimensions.js +4 -0
- package/lib/module/utils/hapticUtils.js +51 -0
- package/lib/module/utils/imageCompression.js +46 -0
- package/lib/module/utils/index.js +8 -0
- package/lib/module/utils/responsive.js +42 -0
- package/lib/module/utils/shadows.js +7 -0
- package/lib/module/utils/spacing.js +82 -0
- package/lib/module/validators/index.js +143 -0
- package/lib/module/versionCheck/index.js +334 -0
- package/lib/typescript/commonjs/api/publicClient.d.ts +11 -0
- package/lib/typescript/commonjs/api/userClient.d.ts +18 -0
- package/lib/typescript/commonjs/auth/authStore.d.ts +20 -0
- package/lib/typescript/commonjs/auth/index.d.ts +5 -0
- package/lib/typescript/commonjs/auth/jwt.d.ts +31 -0
- package/lib/typescript/commonjs/components/Accordion/Accordion.d.ts +33 -0
- package/lib/typescript/commonjs/components/Accordion/index.d.ts +3 -0
- package/lib/typescript/commonjs/components/Avatar/Avatar.d.ts +42 -0
- package/lib/typescript/commonjs/components/Avatar/index.d.ts +3 -0
- package/lib/typescript/commonjs/components/Badge/Badge.d.ts +27 -0
- package/lib/typescript/commonjs/components/Badge/index.d.ts +3 -0
- package/lib/typescript/commonjs/components/Banner/Banner.d.ts +27 -0
- package/lib/typescript/commonjs/components/Banner/index.d.ts +3 -0
- package/lib/typescript/commonjs/components/BottomNavigation/BottomNavigation.d.ts +34 -0
- package/lib/typescript/commonjs/components/BottomNavigation/index.d.ts +3 -0
- package/lib/typescript/commonjs/components/BottomSheet/BottomSheet.d.ts +45 -0
- package/lib/typescript/commonjs/components/BottomSheet/index.d.ts +3 -0
- package/lib/typescript/commonjs/components/Button/Button.d.ts +29 -0
- package/lib/typescript/commonjs/components/Button/index.d.ts +3 -0
- package/lib/typescript/commonjs/components/Card/Card.d.ts +29 -0
- package/lib/typescript/commonjs/components/Card/index.d.ts +3 -0
- package/lib/typescript/commonjs/components/Carousel/Carousel.d.ts +66 -0
- package/lib/typescript/commonjs/components/Carousel/index.d.ts +3 -0
- package/lib/typescript/commonjs/components/Checkbox/Checkbox.d.ts +24 -0
- package/lib/typescript/commonjs/components/Checkbox/index.d.ts +3 -0
- package/lib/typescript/commonjs/components/Chip/Chip.d.ts +25 -0
- package/lib/typescript/commonjs/components/Chip/index.d.ts +3 -0
- package/lib/typescript/commonjs/components/DatePicker/DatePicker.d.ts +25 -0
- package/lib/typescript/commonjs/components/DatePicker/index.d.ts +3 -0
- package/lib/typescript/commonjs/components/DateRangePicker/DateRangePicker.d.ts +32 -0
- package/lib/typescript/commonjs/components/DateRangePicker/index.d.ts +3 -0
- package/lib/typescript/commonjs/components/Dialog/Dialog.d.ts +25 -0
- package/lib/typescript/commonjs/components/Dialog/index.d.ts +3 -0
- package/lib/typescript/commonjs/components/Divider/Divider.d.ts +21 -0
- package/lib/typescript/commonjs/components/Divider/index.d.ts +3 -0
- package/lib/typescript/commonjs/components/Drawer/Drawer.d.ts +53 -0
- package/lib/typescript/commonjs/components/Drawer/index.d.ts +3 -0
- package/lib/typescript/commonjs/components/EmptyState/EmptyState.d.ts +25 -0
- package/lib/typescript/commonjs/components/EmptyState/index.d.ts +3 -0
- package/lib/typescript/commonjs/components/FAB/FAB.d.ts +53 -0
- package/lib/typescript/commonjs/components/FAB/index.d.ts +3 -0
- package/lib/typescript/commonjs/components/Field/Field.d.ts +28 -0
- package/lib/typescript/commonjs/components/Field/index.d.ts +3 -0
- package/lib/typescript/commonjs/components/ForceUpdateDialog/ForceUpdateDialog.d.ts +39 -0
- package/lib/typescript/commonjs/components/ForceUpdateDialog/index.d.ts +3 -0
- package/lib/typescript/commonjs/components/Header/Header.d.ts +36 -0
- package/lib/typescript/commonjs/components/Header/index.d.ts +3 -0
- package/lib/typescript/commonjs/components/Icon/Icon.d.ts +20 -0
- package/lib/typescript/commonjs/components/Icon/index.d.ts +3 -0
- package/lib/typescript/commonjs/components/ImageGallery/ImageGallery.d.ts +41 -0
- package/lib/typescript/commonjs/components/ImageGallery/index.d.ts +3 -0
- package/lib/typescript/commonjs/components/Input/Input.d.ts +34 -0
- package/lib/typescript/commonjs/components/Input/index.d.ts +3 -0
- package/lib/typescript/commonjs/components/ListItem/ListItem.d.ts +30 -0
- package/lib/typescript/commonjs/components/ListItem/index.d.ts +4 -0
- package/lib/typescript/commonjs/components/LoadingSpinner/LoadingSpinner.d.ts +20 -0
- package/lib/typescript/commonjs/components/LoadingSpinner/index.d.ts +3 -0
- package/lib/typescript/commonjs/components/Modal/Modal.d.ts +29 -0
- package/lib/typescript/commonjs/components/Modal/index.d.ts +3 -0
- package/lib/typescript/commonjs/components/NumberInput/NumberInput.d.ts +35 -0
- package/lib/typescript/commonjs/components/NumberInput/index.d.ts +3 -0
- package/lib/typescript/commonjs/components/OTPInput/OTPInput.d.ts +29 -0
- package/lib/typescript/commonjs/components/OTPInput/index.d.ts +3 -0
- package/lib/typescript/commonjs/components/ProgressBar/ProgressBar.d.ts +21 -0
- package/lib/typescript/commonjs/components/ProgressBar/index.d.ts +3 -0
- package/lib/typescript/commonjs/components/Radio/Radio.d.ts +32 -0
- package/lib/typescript/commonjs/components/Radio/RadioGroup.d.ts +16 -0
- package/lib/typescript/commonjs/components/Radio/index.d.ts +5 -0
- package/lib/typescript/commonjs/components/Rating/Rating.d.ts +22 -0
- package/lib/typescript/commonjs/components/Rating/index.d.ts +3 -0
- package/lib/typescript/commonjs/components/SearchBar/SearchBar.d.ts +28 -0
- package/lib/typescript/commonjs/components/SearchBar/index.d.ts +3 -0
- package/lib/typescript/commonjs/components/SegmentedControl/SegmentedControl.d.ts +36 -0
- package/lib/typescript/commonjs/components/SegmentedControl/index.d.ts +3 -0
- package/lib/typescript/commonjs/components/Select/Select.d.ts +48 -0
- package/lib/typescript/commonjs/components/Select/index.d.ts +3 -0
- package/lib/typescript/commonjs/components/SkeletonLoader/SkeletonContent.d.ts +29 -0
- package/lib/typescript/commonjs/components/SkeletonLoader/SkeletonLoader.d.ts +42 -0
- package/lib/typescript/commonjs/components/SkeletonLoader/index.d.ts +5 -0
- package/lib/typescript/commonjs/components/Slider/Slider.d.ts +33 -0
- package/lib/typescript/commonjs/components/Slider/index.d.ts +3 -0
- package/lib/typescript/commonjs/components/Stepper/Stepper.d.ts +25 -0
- package/lib/typescript/commonjs/components/Stepper/index.d.ts +3 -0
- package/lib/typescript/commonjs/components/Swipeable/Swipeable.d.ts +45 -0
- package/lib/typescript/commonjs/components/Swipeable/index.d.ts +3 -0
- package/lib/typescript/commonjs/components/Switch/Switch.d.ts +24 -0
- package/lib/typescript/commonjs/components/Switch/index.d.ts +3 -0
- package/lib/typescript/commonjs/components/Tabs/Tabs.d.ts +37 -0
- package/lib/typescript/commonjs/components/Tabs/index.d.ts +3 -0
- package/lib/typescript/commonjs/components/TimePicker/TimePicker.d.ts +26 -0
- package/lib/typescript/commonjs/components/TimePicker/index.d.ts +3 -0
- package/lib/typescript/commonjs/components/Toast/Toast.d.ts +30 -0
- package/lib/typescript/commonjs/components/Toast/ToastProvider.d.ts +26 -0
- package/lib/typescript/commonjs/components/Toast/index.d.ts +5 -0
- package/lib/typescript/commonjs/components/Tooltip/Tooltip.d.ts +22 -0
- package/lib/typescript/commonjs/components/Tooltip/index.d.ts +3 -0
- package/lib/typescript/commonjs/components/index.d.ts +89 -0
- package/lib/typescript/commonjs/config/index.d.ts +40 -0
- package/lib/typescript/commonjs/formatters/currency.d.ts +24 -0
- package/lib/typescript/commonjs/formatters/date.d.ts +22 -0
- package/lib/typescript/commonjs/formatters/index.d.ts +8 -0
- package/lib/typescript/commonjs/formatters/initials.d.ts +11 -0
- package/lib/typescript/commonjs/formatters/number.d.ts +15 -0
- package/lib/typescript/commonjs/formatters/phone.d.ts +13 -0
- package/lib/typescript/commonjs/hooks/index.d.ts +6 -0
- package/lib/typescript/commonjs/hooks/useDebounce.d.ts +2 -0
- package/lib/typescript/commonjs/hooks/usePressAnimation.d.ts +14 -0
- package/lib/typescript/commonjs/hooks/useToggle.d.ts +9 -0
- package/lib/typescript/commonjs/index.d.ts +37 -0
- package/lib/typescript/commonjs/initSDK.d.ts +40 -0
- package/lib/typescript/commonjs/initUI.d.ts +12 -0
- package/lib/typescript/commonjs/initUserAuth.d.ts +22 -0
- package/lib/typescript/commonjs/logger/index.d.ts +42 -0
- package/lib/typescript/commonjs/network/NetworkStatusBanner.d.ts +19 -0
- package/lib/typescript/commonjs/network/index.d.ts +5 -0
- package/lib/typescript/commonjs/network/networkStatus.d.ts +27 -0
- package/lib/typescript/commonjs/package.json +1 -0
- package/lib/typescript/commonjs/permissions/index.d.ts +20 -0
- package/lib/typescript/commonjs/storage/index.d.ts +42 -0
- package/lib/typescript/commonjs/theme/ThemeContext.d.ts +18 -0
- package/lib/typescript/commonjs/theme/index.d.ts +13 -0
- package/lib/typescript/commonjs/theme/merge.d.ts +3 -0
- package/lib/typescript/commonjs/theme/tokens.d.ts +4 -0
- package/lib/typescript/commonjs/theme/types.d.ts +161 -0
- package/lib/typescript/commonjs/utils/dimensions.d.ts +3 -0
- package/lib/typescript/commonjs/utils/hapticUtils.d.ts +4 -0
- package/lib/typescript/commonjs/utils/imageCompression.d.ts +15 -0
- package/lib/typescript/commonjs/utils/index.d.ts +10 -0
- package/lib/typescript/commonjs/utils/responsive.d.ts +23 -0
- package/lib/typescript/commonjs/utils/shadows.d.ts +4 -0
- package/lib/typescript/commonjs/utils/spacing.d.ts +61 -0
- package/lib/typescript/commonjs/validators/index.d.ts +46 -0
- package/lib/typescript/commonjs/versionCheck/index.d.ts +59 -0
- package/lib/typescript/module/api/publicClient.d.ts +11 -0
- package/lib/typescript/module/api/userClient.d.ts +18 -0
- package/lib/typescript/module/auth/authStore.d.ts +20 -0
- package/lib/typescript/module/auth/index.d.ts +5 -0
- package/lib/typescript/module/auth/jwt.d.ts +31 -0
- package/lib/typescript/module/components/Accordion/Accordion.d.ts +33 -0
- package/lib/typescript/module/components/Accordion/index.d.ts +3 -0
- package/lib/typescript/module/components/Avatar/Avatar.d.ts +42 -0
- package/lib/typescript/module/components/Avatar/index.d.ts +3 -0
- package/lib/typescript/module/components/Badge/Badge.d.ts +27 -0
- package/lib/typescript/module/components/Badge/index.d.ts +3 -0
- package/lib/typescript/module/components/Banner/Banner.d.ts +27 -0
- package/lib/typescript/module/components/Banner/index.d.ts +3 -0
- package/lib/typescript/module/components/BottomNavigation/BottomNavigation.d.ts +34 -0
- package/lib/typescript/module/components/BottomNavigation/index.d.ts +3 -0
- package/lib/typescript/module/components/BottomSheet/BottomSheet.d.ts +45 -0
- package/lib/typescript/module/components/BottomSheet/index.d.ts +3 -0
- package/lib/typescript/module/components/Button/Button.d.ts +29 -0
- package/lib/typescript/module/components/Button/index.d.ts +3 -0
- package/lib/typescript/module/components/Card/Card.d.ts +29 -0
- package/lib/typescript/module/components/Card/index.d.ts +3 -0
- package/lib/typescript/module/components/Carousel/Carousel.d.ts +66 -0
- package/lib/typescript/module/components/Carousel/index.d.ts +3 -0
- package/lib/typescript/module/components/Checkbox/Checkbox.d.ts +24 -0
- package/lib/typescript/module/components/Checkbox/index.d.ts +3 -0
- package/lib/typescript/module/components/Chip/Chip.d.ts +25 -0
- package/lib/typescript/module/components/Chip/index.d.ts +3 -0
- package/lib/typescript/module/components/DatePicker/DatePicker.d.ts +25 -0
- package/lib/typescript/module/components/DatePicker/index.d.ts +3 -0
- package/lib/typescript/module/components/DateRangePicker/DateRangePicker.d.ts +32 -0
- package/lib/typescript/module/components/DateRangePicker/index.d.ts +3 -0
- package/lib/typescript/module/components/Dialog/Dialog.d.ts +25 -0
- package/lib/typescript/module/components/Dialog/index.d.ts +3 -0
- package/lib/typescript/module/components/Divider/Divider.d.ts +21 -0
- package/lib/typescript/module/components/Divider/index.d.ts +3 -0
- package/lib/typescript/module/components/Drawer/Drawer.d.ts +53 -0
- package/lib/typescript/module/components/Drawer/index.d.ts +3 -0
- package/lib/typescript/module/components/EmptyState/EmptyState.d.ts +25 -0
- package/lib/typescript/module/components/EmptyState/index.d.ts +3 -0
- package/lib/typescript/module/components/FAB/FAB.d.ts +53 -0
- package/lib/typescript/module/components/FAB/index.d.ts +3 -0
- package/lib/typescript/module/components/Field/Field.d.ts +28 -0
- package/lib/typescript/module/components/Field/index.d.ts +3 -0
- package/lib/typescript/module/components/ForceUpdateDialog/ForceUpdateDialog.d.ts +39 -0
- package/lib/typescript/module/components/ForceUpdateDialog/index.d.ts +3 -0
- package/lib/typescript/module/components/Header/Header.d.ts +36 -0
- package/lib/typescript/module/components/Header/index.d.ts +3 -0
- package/lib/typescript/module/components/Icon/Icon.d.ts +20 -0
- package/lib/typescript/module/components/Icon/index.d.ts +3 -0
- package/lib/typescript/module/components/ImageGallery/ImageGallery.d.ts +41 -0
- package/lib/typescript/module/components/ImageGallery/index.d.ts +3 -0
- package/lib/typescript/module/components/Input/Input.d.ts +34 -0
- package/lib/typescript/module/components/Input/index.d.ts +3 -0
- package/lib/typescript/module/components/ListItem/ListItem.d.ts +30 -0
- package/lib/typescript/module/components/ListItem/index.d.ts +4 -0
- package/lib/typescript/module/components/LoadingSpinner/LoadingSpinner.d.ts +20 -0
- package/lib/typescript/module/components/LoadingSpinner/index.d.ts +3 -0
- package/lib/typescript/module/components/Modal/Modal.d.ts +29 -0
- package/lib/typescript/module/components/Modal/index.d.ts +3 -0
- package/lib/typescript/module/components/NumberInput/NumberInput.d.ts +35 -0
- package/lib/typescript/module/components/NumberInput/index.d.ts +3 -0
- package/lib/typescript/module/components/OTPInput/OTPInput.d.ts +29 -0
- package/lib/typescript/module/components/OTPInput/index.d.ts +3 -0
- package/lib/typescript/module/components/ProgressBar/ProgressBar.d.ts +21 -0
- package/lib/typescript/module/components/ProgressBar/index.d.ts +3 -0
- package/lib/typescript/module/components/Radio/Radio.d.ts +32 -0
- package/lib/typescript/module/components/Radio/RadioGroup.d.ts +16 -0
- package/lib/typescript/module/components/Radio/index.d.ts +5 -0
- package/lib/typescript/module/components/Rating/Rating.d.ts +22 -0
- package/lib/typescript/module/components/Rating/index.d.ts +3 -0
- package/lib/typescript/module/components/SearchBar/SearchBar.d.ts +28 -0
- package/lib/typescript/module/components/SearchBar/index.d.ts +3 -0
- package/lib/typescript/module/components/SegmentedControl/SegmentedControl.d.ts +36 -0
- package/lib/typescript/module/components/SegmentedControl/index.d.ts +3 -0
- package/lib/typescript/module/components/Select/Select.d.ts +48 -0
- package/lib/typescript/module/components/Select/index.d.ts +3 -0
- package/lib/typescript/module/components/SkeletonLoader/SkeletonContent.d.ts +29 -0
- package/lib/typescript/module/components/SkeletonLoader/SkeletonLoader.d.ts +42 -0
- package/lib/typescript/module/components/SkeletonLoader/index.d.ts +5 -0
- package/lib/typescript/module/components/Slider/Slider.d.ts +33 -0
- package/lib/typescript/module/components/Slider/index.d.ts +3 -0
- package/lib/typescript/module/components/Stepper/Stepper.d.ts +25 -0
- package/lib/typescript/module/components/Stepper/index.d.ts +3 -0
- package/lib/typescript/module/components/Swipeable/Swipeable.d.ts +45 -0
- package/lib/typescript/module/components/Swipeable/index.d.ts +3 -0
- package/lib/typescript/module/components/Switch/Switch.d.ts +24 -0
- package/lib/typescript/module/components/Switch/index.d.ts +3 -0
- package/lib/typescript/module/components/Tabs/Tabs.d.ts +37 -0
- package/lib/typescript/module/components/Tabs/index.d.ts +3 -0
- package/lib/typescript/module/components/TimePicker/TimePicker.d.ts +26 -0
- package/lib/typescript/module/components/TimePicker/index.d.ts +3 -0
- package/lib/typescript/module/components/Toast/Toast.d.ts +30 -0
- package/lib/typescript/module/components/Toast/ToastProvider.d.ts +26 -0
- package/lib/typescript/module/components/Toast/index.d.ts +5 -0
- package/lib/typescript/module/components/Tooltip/Tooltip.d.ts +22 -0
- package/lib/typescript/module/components/Tooltip/index.d.ts +3 -0
- package/lib/typescript/module/components/index.d.ts +89 -0
- package/lib/typescript/module/config/index.d.ts +40 -0
- package/lib/typescript/module/formatters/currency.d.ts +24 -0
- package/lib/typescript/module/formatters/date.d.ts +22 -0
- package/lib/typescript/module/formatters/index.d.ts +8 -0
- package/lib/typescript/module/formatters/initials.d.ts +11 -0
- package/lib/typescript/module/formatters/number.d.ts +15 -0
- package/lib/typescript/module/formatters/phone.d.ts +13 -0
- package/lib/typescript/module/hooks/index.d.ts +6 -0
- package/lib/typescript/module/hooks/useDebounce.d.ts +2 -0
- package/lib/typescript/module/hooks/usePressAnimation.d.ts +14 -0
- package/lib/typescript/module/hooks/useToggle.d.ts +9 -0
- package/lib/typescript/module/index.d.ts +37 -0
- package/lib/typescript/module/initSDK.d.ts +40 -0
- package/lib/typescript/module/initUI.d.ts +12 -0
- package/lib/typescript/module/initUserAuth.d.ts +22 -0
- package/lib/typescript/module/logger/index.d.ts +42 -0
- package/lib/typescript/module/network/NetworkStatusBanner.d.ts +19 -0
- package/lib/typescript/module/network/index.d.ts +5 -0
- package/lib/typescript/module/network/networkStatus.d.ts +27 -0
- package/lib/typescript/module/package.json +1 -0
- package/lib/typescript/module/permissions/index.d.ts +20 -0
- package/lib/typescript/module/storage/index.d.ts +42 -0
- package/lib/typescript/module/theme/ThemeContext.d.ts +18 -0
- package/lib/typescript/module/theme/index.d.ts +13 -0
- package/lib/typescript/module/theme/merge.d.ts +3 -0
- package/lib/typescript/module/theme/tokens.d.ts +4 -0
- package/lib/typescript/module/theme/types.d.ts +161 -0
- package/lib/typescript/module/utils/dimensions.d.ts +3 -0
- package/lib/typescript/module/utils/hapticUtils.d.ts +4 -0
- package/lib/typescript/module/utils/imageCompression.d.ts +15 -0
- package/lib/typescript/module/utils/index.d.ts +10 -0
- package/lib/typescript/module/utils/responsive.d.ts +23 -0
- package/lib/typescript/module/utils/shadows.d.ts +4 -0
- package/lib/typescript/module/utils/spacing.d.ts +61 -0
- package/lib/typescript/module/validators/index.d.ts +46 -0
- package/lib/typescript/module/versionCheck/index.d.ts +59 -0
- package/package.json +137 -0
|
@@ -0,0 +1,363 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
/**
|
|
4
|
+
* BottomSheet — Reanimated 3 + Gesture Handler 2 implementation.
|
|
5
|
+
*
|
|
6
|
+
* A polished, theme-aware bottom sheet with multi-snap-point support,
|
|
7
|
+
* UI-thread driven pan gestures, and native-driver spring animations.
|
|
8
|
+
*
|
|
9
|
+
* USAGE:
|
|
10
|
+
*
|
|
11
|
+
* const ref = useRef<BottomSheetRef>(null);
|
|
12
|
+
* <BottomSheet ref={ref} snapPoints={[200, '50%', '90%']}>
|
|
13
|
+
* <YourContent />
|
|
14
|
+
* </BottomSheet>
|
|
15
|
+
*
|
|
16
|
+
* ref.current?.expand(); // open at first snap point (or `index` prop)
|
|
17
|
+
* ref.current?.expand(2); // open at specific index
|
|
18
|
+
* ref.current?.collapse(); // animate to smallest snap point
|
|
19
|
+
* ref.current?.close(); // dismiss
|
|
20
|
+
*/
|
|
21
|
+
|
|
22
|
+
import React, { forwardRef, useCallback, useEffect, useImperativeHandle, useMemo, useRef, useState } from 'react';
|
|
23
|
+
import { Dimensions, Pressable, StyleSheet, View } from 'react-native';
|
|
24
|
+
import { Gesture, GestureDetector } from 'react-native-gesture-handler';
|
|
25
|
+
import Animated, { Extrapolation, interpolate, runOnJS, useAnimatedStyle, useSharedValue, withSpring, withTiming } from 'react-native-reanimated';
|
|
26
|
+
import { useSafeAreaInsets } from 'react-native-safe-area-context';
|
|
27
|
+
import { useTheme } from "../../theme/index.js";
|
|
28
|
+
import { triggerHaptic } from "../../utils/index.js";
|
|
29
|
+
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
30
|
+
const SPRING_CONFIG = {
|
|
31
|
+
damping: 20,
|
|
32
|
+
stiffness: 240,
|
|
33
|
+
mass: 1
|
|
34
|
+
};
|
|
35
|
+
const CLOSE_VELOCITY_THRESHOLD = 1000;
|
|
36
|
+
const DRAG_ACTIVATION_OFFSET = 10;
|
|
37
|
+
const BottomSheet = /*#__PURE__*/forwardRef((props, ref) => {
|
|
38
|
+
const {
|
|
39
|
+
snapPoints,
|
|
40
|
+
index: controlledIndex,
|
|
41
|
+
onChange,
|
|
42
|
+
onAnimate,
|
|
43
|
+
enablePanDownToClose = true,
|
|
44
|
+
enableBackdropPress = true,
|
|
45
|
+
backdropOpacity = 0.5,
|
|
46
|
+
handleIndicatorStyle,
|
|
47
|
+
containerStyle,
|
|
48
|
+
children,
|
|
49
|
+
accessibilityLabel,
|
|
50
|
+
accessibilityViewIsModal,
|
|
51
|
+
testID
|
|
52
|
+
} = props;
|
|
53
|
+
const theme = useTheme();
|
|
54
|
+
const insets = useSafeAreaInsets();
|
|
55
|
+
const [screenHeight, setScreenHeight] = useState(() => Dimensions.get('window').height);
|
|
56
|
+
|
|
57
|
+
// Resolve snap points (px values), sorted ascending so larger height = smaller translateY.
|
|
58
|
+
const resolvedSnapPoints = useMemo(() => resolveSnapPoints(snapPoints, screenHeight), [snapPoints, screenHeight]);
|
|
59
|
+
|
|
60
|
+
// Listen for orientation / window changes so % snap points stay accurate.
|
|
61
|
+
useEffect(() => {
|
|
62
|
+
const sub = Dimensions.addEventListener('change', ({
|
|
63
|
+
window
|
|
64
|
+
}) => {
|
|
65
|
+
setScreenHeight(window.height);
|
|
66
|
+
});
|
|
67
|
+
return () => sub.remove();
|
|
68
|
+
}, []);
|
|
69
|
+
const closedY = screenHeight; // fully off-screen
|
|
70
|
+
const minSnapPoint = resolvedSnapPoints[0] ?? 0;
|
|
71
|
+
const maxSnapPoint = resolvedSnapPoints[resolvedSnapPoints.length - 1] ?? 0;
|
|
72
|
+
|
|
73
|
+
// translateY: 0 = top of screen, screenHeight = fully closed.
|
|
74
|
+
const translateY = useSharedValue(closedY);
|
|
75
|
+
// Captures the translateY at gesture start so onUpdate can be additive.
|
|
76
|
+
const dragStartY = useSharedValue(closedY);
|
|
77
|
+
// Tracks current snap index on the JS thread (mirrored to a shared value for worklets).
|
|
78
|
+
const currentIndexShared = useSharedValue(-1);
|
|
79
|
+
const [currentIndex, setCurrentIndex] = useState(-1);
|
|
80
|
+
const isAnimatingRef = useRef(false);
|
|
81
|
+
|
|
82
|
+
// Convert a snap-point index → translateY position. -1 = closed.
|
|
83
|
+
const yForIndex = useCallback(idx => {
|
|
84
|
+
if (idx < 0 || idx >= resolvedSnapPoints.length) return closedY;
|
|
85
|
+
const sheetHeight = resolvedSnapPoints[idx];
|
|
86
|
+
return screenHeight - sheetHeight;
|
|
87
|
+
}, [resolvedSnapPoints, screenHeight, closedY]);
|
|
88
|
+
const setIndexJS = useCallback(next => {
|
|
89
|
+
const previous = currentIndex;
|
|
90
|
+
if (previous === next) return;
|
|
91
|
+
setCurrentIndex(next);
|
|
92
|
+
currentIndexShared.value = next;
|
|
93
|
+
onChange?.(next);
|
|
94
|
+
}, [currentIndex, currentIndexShared, onChange]);
|
|
95
|
+
const animateTo = useCallback((to, fromIndex, toIndex) => {
|
|
96
|
+
isAnimatingRef.current = true;
|
|
97
|
+
onAnimate?.(fromIndex, toIndex);
|
|
98
|
+
translateY.value = withSpring(to, SPRING_CONFIG, finished => {
|
|
99
|
+
'worklet';
|
|
100
|
+
|
|
101
|
+
if (finished) {
|
|
102
|
+
runOnJS(markAnimationDone)();
|
|
103
|
+
}
|
|
104
|
+
});
|
|
105
|
+
}, [onAnimate, translateY]);
|
|
106
|
+
const markAnimationDone = useCallback(() => {
|
|
107
|
+
isAnimatingRef.current = false;
|
|
108
|
+
}, []);
|
|
109
|
+
const expand = useCallback(idx => {
|
|
110
|
+
const target = typeof idx === 'number' ? clamp(idx, 0, resolvedSnapPoints.length - 1) : currentIndex >= 0 ? currentIndex : 0;
|
|
111
|
+
const fromIndex = currentIndexShared.value;
|
|
112
|
+
const to = yForIndex(target);
|
|
113
|
+
setIndexJS(target);
|
|
114
|
+
animateTo(to, fromIndex, target);
|
|
115
|
+
}, [animateTo, currentIndex, currentIndexShared, resolvedSnapPoints.length, setIndexJS, yForIndex]);
|
|
116
|
+
const collapse = useCallback(() => {
|
|
117
|
+
if (resolvedSnapPoints.length === 0) return;
|
|
118
|
+
const fromIndex = currentIndexShared.value;
|
|
119
|
+
const to = yForIndex(0);
|
|
120
|
+
setIndexJS(0);
|
|
121
|
+
animateTo(to, fromIndex, 0);
|
|
122
|
+
}, [animateTo, currentIndexShared, resolvedSnapPoints.length, setIndexJS, yForIndex]);
|
|
123
|
+
const close = useCallback(() => {
|
|
124
|
+
const fromIndex = currentIndexShared.value;
|
|
125
|
+
setIndexJS(-1);
|
|
126
|
+
isAnimatingRef.current = true;
|
|
127
|
+
onAnimate?.(fromIndex, -1);
|
|
128
|
+
translateY.value = withTiming(closedY, {
|
|
129
|
+
duration: 220
|
|
130
|
+
}, finished => {
|
|
131
|
+
'worklet';
|
|
132
|
+
|
|
133
|
+
if (finished) {
|
|
134
|
+
runOnJS(markAnimationDone)();
|
|
135
|
+
}
|
|
136
|
+
});
|
|
137
|
+
}, [closedY, currentIndexShared, markAnimationDone, onAnimate, setIndexJS, translateY]);
|
|
138
|
+
useImperativeHandle(ref, () => ({
|
|
139
|
+
expand,
|
|
140
|
+
collapse,
|
|
141
|
+
close
|
|
142
|
+
}), [expand, collapse, close]);
|
|
143
|
+
|
|
144
|
+
// Drive the controlled `index` prop.
|
|
145
|
+
useEffect(() => {
|
|
146
|
+
if (typeof controlledIndex !== 'number') return;
|
|
147
|
+
if (controlledIndex === currentIndex) return;
|
|
148
|
+
if (controlledIndex === -1) {
|
|
149
|
+
close();
|
|
150
|
+
} else {
|
|
151
|
+
expand(controlledIndex);
|
|
152
|
+
}
|
|
153
|
+
// eslint-disable-next-line react-hooks/exhaustive-deps
|
|
154
|
+
}, [controlledIndex]);
|
|
155
|
+
|
|
156
|
+
// ───────── Gesture (UI thread) ─────────
|
|
157
|
+
// Worklet helpers must be declared inline so they capture shared values correctly.
|
|
158
|
+
const minTopY = screenHeight - maxSnapPoint; // smallest translateY (sheet fully expanded)
|
|
159
|
+
const snapTargets = useMemo(() => resolvedSnapPoints.map(h => screenHeight - h), [resolvedSnapPoints, screenHeight]);
|
|
160
|
+
const handleSnapEnd = useCallback((toIndex, toY) => {
|
|
161
|
+
const fromIndex = currentIndexShared.value;
|
|
162
|
+
if (toIndex === -1) {
|
|
163
|
+
triggerHaptic('selection');
|
|
164
|
+
setIndexJS(-1);
|
|
165
|
+
isAnimatingRef.current = true;
|
|
166
|
+
onAnimate?.(fromIndex, -1);
|
|
167
|
+
translateY.value = withTiming(closedY, {
|
|
168
|
+
duration: 220
|
|
169
|
+
}, finished => {
|
|
170
|
+
'worklet';
|
|
171
|
+
|
|
172
|
+
if (finished) {
|
|
173
|
+
runOnJS(markAnimationDone)();
|
|
174
|
+
}
|
|
175
|
+
});
|
|
176
|
+
return;
|
|
177
|
+
}
|
|
178
|
+
setIndexJS(toIndex);
|
|
179
|
+
animateTo(toY, fromIndex, toIndex);
|
|
180
|
+
}, [animateTo, closedY, currentIndexShared, markAnimationDone, onAnimate, setIndexJS, translateY]);
|
|
181
|
+
const panGesture = useMemo(() => {
|
|
182
|
+
const targets = snapTargets;
|
|
183
|
+
const closed = closedY;
|
|
184
|
+
const top = minTopY;
|
|
185
|
+
const canPanDownToClose = enablePanDownToClose;
|
|
186
|
+
return Gesture.Pan().activeOffsetY([-DRAG_ACTIVATION_OFFSET, DRAG_ACTIVATION_OFFSET]).failOffsetX([-15, 15]).onStart(() => {
|
|
187
|
+
'worklet';
|
|
188
|
+
|
|
189
|
+
dragStartY.value = translateY.value;
|
|
190
|
+
}).onUpdate(event => {
|
|
191
|
+
'worklet';
|
|
192
|
+
|
|
193
|
+
const next = dragStartY.value + event.translationY;
|
|
194
|
+
// Clamp at the top (most-expanded) snap point with a touch of rubber-banding.
|
|
195
|
+
if (next < top) {
|
|
196
|
+
translateY.value = top + (next - top) * 0.25;
|
|
197
|
+
} else {
|
|
198
|
+
translateY.value = next;
|
|
199
|
+
}
|
|
200
|
+
}).onEnd(event => {
|
|
201
|
+
'worklet';
|
|
202
|
+
|
|
203
|
+
const releaseY = translateY.value;
|
|
204
|
+
const velocity = event.velocityY;
|
|
205
|
+
|
|
206
|
+
// Fast downward swipe → close (if allowed) or snap to smallest.
|
|
207
|
+
if (velocity > CLOSE_VELOCITY_THRESHOLD) {
|
|
208
|
+
if (canPanDownToClose) {
|
|
209
|
+
runOnJS(handleSnapEnd)(-1, closed);
|
|
210
|
+
return;
|
|
211
|
+
}
|
|
212
|
+
runOnJS(handleSnapEnd)(0, targets[0]);
|
|
213
|
+
return;
|
|
214
|
+
}
|
|
215
|
+
|
|
216
|
+
// Find nearest snap target by distance.
|
|
217
|
+
let nearestIdx = 0;
|
|
218
|
+
let nearestDist = Math.abs(releaseY - targets[0]);
|
|
219
|
+
for (let i = 1; i < targets.length; i++) {
|
|
220
|
+
const d = Math.abs(releaseY - targets[i]);
|
|
221
|
+
if (d < nearestDist) {
|
|
222
|
+
nearestDist = d;
|
|
223
|
+
nearestIdx = i;
|
|
224
|
+
}
|
|
225
|
+
}
|
|
226
|
+
|
|
227
|
+
// If user dragged below smallest snap point past threshold and pan-to-close is on, dismiss.
|
|
228
|
+
const smallest = targets[0];
|
|
229
|
+
const overshoot = releaseY - smallest;
|
|
230
|
+
if (canPanDownToClose && overshoot > 80) {
|
|
231
|
+
runOnJS(handleSnapEnd)(-1, closed);
|
|
232
|
+
return;
|
|
233
|
+
}
|
|
234
|
+
runOnJS(handleSnapEnd)(nearestIdx, targets[nearestIdx]);
|
|
235
|
+
});
|
|
236
|
+
}, [closedY, dragStartY, enablePanDownToClose, handleSnapEnd, minTopY, snapTargets, translateY]);
|
|
237
|
+
|
|
238
|
+
// ───────── Animated styles ─────────
|
|
239
|
+
const sheetStyle = useAnimatedStyle(() => ({
|
|
240
|
+
transform: [{
|
|
241
|
+
translateY: translateY.value
|
|
242
|
+
}]
|
|
243
|
+
}));
|
|
244
|
+
const backdropStyle = useAnimatedStyle(() => {
|
|
245
|
+
// 0 opacity when sheet is closed, full backdropOpacity at minSnap height (and above).
|
|
246
|
+
const closedAt = screenHeight;
|
|
247
|
+
const openAt = screenHeight - minSnapPoint;
|
|
248
|
+
const opacity = interpolate(translateY.value, [closedAt, openAt], [0, backdropOpacity], Extrapolation.CLAMP);
|
|
249
|
+
return {
|
|
250
|
+
opacity,
|
|
251
|
+
// Disable hit-test entirely when fully closed so it doesn't swallow taps.
|
|
252
|
+
pointerEvents: translateY.value >= closedAt - 0.5 ? 'none' : 'auto'
|
|
253
|
+
};
|
|
254
|
+
}, [backdropOpacity, minSnapPoint, screenHeight]);
|
|
255
|
+
const isExpanded = currentIndex >= 0;
|
|
256
|
+
const styles = useMemo(() => buildStyles(theme), [theme]);
|
|
257
|
+
const handleBackdropPress = useCallback(() => {
|
|
258
|
+
if (!enableBackdropPress) return;
|
|
259
|
+
triggerHaptic('selection');
|
|
260
|
+
close();
|
|
261
|
+
}, [enableBackdropPress, close]);
|
|
262
|
+
|
|
263
|
+
// Don't render the heavy gesture tree at all when nothing's been opened yet.
|
|
264
|
+
// We still mount once `currentIndex` ≥ 0 OR an animation has started.
|
|
265
|
+
// For controlled `index`, we treat any value ≠ -1 as "opened".
|
|
266
|
+
const everOpenedRef = useRef(false);
|
|
267
|
+
if (isExpanded || controlledIndex !== undefined) {
|
|
268
|
+
everOpenedRef.current = true;
|
|
269
|
+
}
|
|
270
|
+
if (!everOpenedRef.current) {
|
|
271
|
+
return null;
|
|
272
|
+
}
|
|
273
|
+
return /*#__PURE__*/_jsxs(View, {
|
|
274
|
+
style: StyleSheet.absoluteFill,
|
|
275
|
+
pointerEvents: "box-none",
|
|
276
|
+
testID: testID,
|
|
277
|
+
accessibilityViewIsModal: accessibilityViewIsModal ?? isExpanded,
|
|
278
|
+
children: [/*#__PURE__*/_jsx(Animated.View, {
|
|
279
|
+
style: [styles.backdrop, {
|
|
280
|
+
backgroundColor: theme.colors.background.overlay
|
|
281
|
+
}, backdropStyle],
|
|
282
|
+
children: /*#__PURE__*/_jsx(Pressable, {
|
|
283
|
+
style: StyleSheet.absoluteFill,
|
|
284
|
+
onPress: handleBackdropPress,
|
|
285
|
+
accessibilityRole: "button",
|
|
286
|
+
accessibilityLabel: "Close bottom sheet",
|
|
287
|
+
disabled: !enableBackdropPress || !isExpanded
|
|
288
|
+
})
|
|
289
|
+
}), /*#__PURE__*/_jsx(GestureDetector, {
|
|
290
|
+
gesture: panGesture,
|
|
291
|
+
children: /*#__PURE__*/_jsxs(Animated.View, {
|
|
292
|
+
// 'dialog' is a valid platform role on web/iOS; RN's typings list it as a string union
|
|
293
|
+
// that varies by platform — cast keeps strict-mode happy.
|
|
294
|
+
accessibilityRole: 'dialog',
|
|
295
|
+
accessibilityLabel: accessibilityLabel,
|
|
296
|
+
accessibilityViewIsModal: accessibilityViewIsModal ?? isExpanded,
|
|
297
|
+
style: [styles.sheet, {
|
|
298
|
+
height: maxSnapPoint,
|
|
299
|
+
backgroundColor: theme.colors.background.elevated,
|
|
300
|
+
borderTopLeftRadius: theme.radius['2xl'],
|
|
301
|
+
borderTopRightRadius: theme.radius['2xl'],
|
|
302
|
+
paddingBottom: insets.bottom,
|
|
303
|
+
...theme.shadows.xl
|
|
304
|
+
}, containerStyle, sheetStyle],
|
|
305
|
+
children: [/*#__PURE__*/_jsx(View, {
|
|
306
|
+
style: styles.handleRow,
|
|
307
|
+
pointerEvents: "box-none",
|
|
308
|
+
children: /*#__PURE__*/_jsx(View, {
|
|
309
|
+
style: [styles.handle, {
|
|
310
|
+
backgroundColor: theme.colors.border.primary
|
|
311
|
+
}, handleIndicatorStyle]
|
|
312
|
+
})
|
|
313
|
+
}), /*#__PURE__*/_jsx(View, {
|
|
314
|
+
style: styles.content,
|
|
315
|
+
children: children
|
|
316
|
+
})]
|
|
317
|
+
})
|
|
318
|
+
})]
|
|
319
|
+
});
|
|
320
|
+
});
|
|
321
|
+
BottomSheet.displayName = 'BottomSheet';
|
|
322
|
+
|
|
323
|
+
// ───────── Helpers ─────────
|
|
324
|
+
|
|
325
|
+
const resolveSnapPoints = (points, screenH) => {
|
|
326
|
+
const resolved = points.map(p => {
|
|
327
|
+
if (typeof p === 'number') return p;
|
|
328
|
+
const pct = parseFloat(p);
|
|
329
|
+
if (Number.isNaN(pct)) return 0;
|
|
330
|
+
return pct / 100 * screenH;
|
|
331
|
+
});
|
|
332
|
+
return [...resolved].sort((a, b) => a - b);
|
|
333
|
+
};
|
|
334
|
+
const clamp = (value, min, max) => Math.min(Math.max(value, min), max);
|
|
335
|
+
const buildStyles = _theme => StyleSheet.create({
|
|
336
|
+
backdrop: {
|
|
337
|
+
...StyleSheet.absoluteFillObject
|
|
338
|
+
},
|
|
339
|
+
sheet: {
|
|
340
|
+
position: 'absolute',
|
|
341
|
+
left: 0,
|
|
342
|
+
right: 0,
|
|
343
|
+
top: 0,
|
|
344
|
+
overflow: 'hidden'
|
|
345
|
+
},
|
|
346
|
+
handleRow: {
|
|
347
|
+
alignItems: 'center',
|
|
348
|
+
justifyContent: 'center',
|
|
349
|
+
paddingTop: 10,
|
|
350
|
+
paddingBottom: 8
|
|
351
|
+
},
|
|
352
|
+
handle: {
|
|
353
|
+
width: 36,
|
|
354
|
+
height: 4,
|
|
355
|
+
borderRadius: 2
|
|
356
|
+
},
|
|
357
|
+
content: {
|
|
358
|
+
flex: 1
|
|
359
|
+
}
|
|
360
|
+
});
|
|
361
|
+
export { BottomSheet };
|
|
362
|
+
export default BottomSheet;
|
|
363
|
+
//# sourceMappingURL=BottomSheet.js.map
|
|
@@ -0,0 +1,277 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
import React, { forwardRef, useMemo } from 'react';
|
|
4
|
+
import { ActivityIndicator, Animated, Pressable, StyleSheet, Text, View } from 'react-native';
|
|
5
|
+
import { useTheme } from "../../theme/index.js";
|
|
6
|
+
import { usePressAnimation } from "../../hooks/usePressAnimation.js";
|
|
7
|
+
import { triggerHaptic } from "../../utils/hapticUtils.js";
|
|
8
|
+
import { jsx as _jsx, Fragment as _Fragment, jsxs as _jsxs } from "react/jsx-runtime";
|
|
9
|
+
const Button = /*#__PURE__*/forwardRef((props, ref) => {
|
|
10
|
+
const {
|
|
11
|
+
title,
|
|
12
|
+
children,
|
|
13
|
+
variant = 'solid',
|
|
14
|
+
tone = 'primary',
|
|
15
|
+
size = 'md',
|
|
16
|
+
loading = false,
|
|
17
|
+
disabled = false,
|
|
18
|
+
fullWidth = false,
|
|
19
|
+
leftIcon,
|
|
20
|
+
rightIcon,
|
|
21
|
+
haptic = 'selection',
|
|
22
|
+
rounded = false,
|
|
23
|
+
style,
|
|
24
|
+
textStyle,
|
|
25
|
+
pressAnimation = true,
|
|
26
|
+
onPress,
|
|
27
|
+
accessibilityLabel,
|
|
28
|
+
accessibilityHint,
|
|
29
|
+
testID,
|
|
30
|
+
...rest
|
|
31
|
+
} = props;
|
|
32
|
+
const theme = useTheme();
|
|
33
|
+
const isInteractive = !disabled && !loading;
|
|
34
|
+
const {
|
|
35
|
+
scale,
|
|
36
|
+
pressIn,
|
|
37
|
+
pressOut
|
|
38
|
+
} = usePressAnimation({
|
|
39
|
+
enabled: pressAnimation && isInteractive
|
|
40
|
+
});
|
|
41
|
+
const styles = useMemo(() => buildStyles(theme), [theme]);
|
|
42
|
+
const sizeStyles = sizeMap[size];
|
|
43
|
+
const toneColors = useMemo(() => toneFor(theme, tone), [theme, tone]);
|
|
44
|
+
const variantStyles = useMemo(() => variantFor(theme, variant, toneColors, disabled), [theme, variant, toneColors, disabled]);
|
|
45
|
+
const handlePress = event => {
|
|
46
|
+
if (!isInteractive) return;
|
|
47
|
+
if (haptic !== false) triggerHaptic(haptic);
|
|
48
|
+
onPress?.(event);
|
|
49
|
+
};
|
|
50
|
+
const accessibleLabel = accessibilityLabel ?? title;
|
|
51
|
+
const content = /*#__PURE__*/_jsx(View, {
|
|
52
|
+
style: styles.contentRow,
|
|
53
|
+
children: loading ? /*#__PURE__*/_jsx(ActivityIndicator, {
|
|
54
|
+
color: variantStyles.textColor,
|
|
55
|
+
size: size === 'xs' || size === 'sm' ? 'small' : 'small'
|
|
56
|
+
}) : /*#__PURE__*/_jsxs(_Fragment, {
|
|
57
|
+
children: [leftIcon ? /*#__PURE__*/_jsx(View, {
|
|
58
|
+
style: styles.iconLeft,
|
|
59
|
+
children: leftIcon
|
|
60
|
+
}) : null, title ? /*#__PURE__*/_jsx(Text, {
|
|
61
|
+
style: [styles.label, {
|
|
62
|
+
color: variantStyles.textColor,
|
|
63
|
+
fontSize: sizeStyles.fontSize,
|
|
64
|
+
fontWeight: theme.typography.fontWeight.semibold
|
|
65
|
+
}, textStyle],
|
|
66
|
+
numberOfLines: 1,
|
|
67
|
+
children: title
|
|
68
|
+
}) : children, rightIcon ? /*#__PURE__*/_jsx(View, {
|
|
69
|
+
style: styles.iconRight,
|
|
70
|
+
children: rightIcon
|
|
71
|
+
}) : null]
|
|
72
|
+
})
|
|
73
|
+
});
|
|
74
|
+
return /*#__PURE__*/_jsx(Animated.View, {
|
|
75
|
+
style: [{
|
|
76
|
+
transform: [{
|
|
77
|
+
scale
|
|
78
|
+
}]
|
|
79
|
+
}, fullWidth ? styles.fullWidth : null],
|
|
80
|
+
children: /*#__PURE__*/_jsx(Pressable, {
|
|
81
|
+
ref: ref,
|
|
82
|
+
onPress: handlePress,
|
|
83
|
+
onPressIn: pressIn,
|
|
84
|
+
onPressOut: pressOut,
|
|
85
|
+
disabled: !isInteractive,
|
|
86
|
+
android_ripple: variant === 'solid' ? {
|
|
87
|
+
color: theme.colors.surface.pressed,
|
|
88
|
+
borderless: false
|
|
89
|
+
} : {
|
|
90
|
+
color: theme.colors.surface.hovered,
|
|
91
|
+
borderless: false
|
|
92
|
+
},
|
|
93
|
+
accessibilityRole: "button",
|
|
94
|
+
accessibilityLabel: accessibleLabel,
|
|
95
|
+
accessibilityHint: accessibilityHint,
|
|
96
|
+
accessibilityState: {
|
|
97
|
+
disabled: !isInteractive,
|
|
98
|
+
busy: loading
|
|
99
|
+
},
|
|
100
|
+
testID: testID,
|
|
101
|
+
style: ({
|
|
102
|
+
pressed
|
|
103
|
+
}) => [styles.base, {
|
|
104
|
+
paddingHorizontal: sizeStyles.paddingHorizontal,
|
|
105
|
+
paddingVertical: sizeStyles.paddingVertical,
|
|
106
|
+
minHeight: sizeStyles.minHeight,
|
|
107
|
+
borderRadius: rounded ? theme.radius.full : sizeStyles.borderRadius,
|
|
108
|
+
backgroundColor: variantStyles.backgroundColor,
|
|
109
|
+
borderWidth: variantStyles.borderWidth,
|
|
110
|
+
borderColor: variantStyles.borderColor,
|
|
111
|
+
opacity: !isInteractive ? 0.55 : 1
|
|
112
|
+
}, pressed && variant !== 'solid' ? {
|
|
113
|
+
backgroundColor: theme.colors.surface.pressed
|
|
114
|
+
} : null, fullWidth ? styles.fullWidth : null, style],
|
|
115
|
+
...rest,
|
|
116
|
+
children: content
|
|
117
|
+
})
|
|
118
|
+
});
|
|
119
|
+
});
|
|
120
|
+
Button.displayName = 'Button';
|
|
121
|
+
const sizeMap = {
|
|
122
|
+
xs: {
|
|
123
|
+
paddingHorizontal: 10,
|
|
124
|
+
paddingVertical: 4,
|
|
125
|
+
minHeight: 28,
|
|
126
|
+
fontSize: 12,
|
|
127
|
+
borderRadius: 8
|
|
128
|
+
},
|
|
129
|
+
sm: {
|
|
130
|
+
paddingHorizontal: 12,
|
|
131
|
+
paddingVertical: 6,
|
|
132
|
+
minHeight: 34,
|
|
133
|
+
fontSize: 13,
|
|
134
|
+
borderRadius: 10
|
|
135
|
+
},
|
|
136
|
+
md: {
|
|
137
|
+
paddingHorizontal: 16,
|
|
138
|
+
paddingVertical: 9,
|
|
139
|
+
minHeight: 42,
|
|
140
|
+
fontSize: 15,
|
|
141
|
+
borderRadius: 12
|
|
142
|
+
},
|
|
143
|
+
lg: {
|
|
144
|
+
paddingHorizontal: 20,
|
|
145
|
+
paddingVertical: 12,
|
|
146
|
+
minHeight: 50,
|
|
147
|
+
fontSize: 16,
|
|
148
|
+
borderRadius: 14
|
|
149
|
+
},
|
|
150
|
+
xl: {
|
|
151
|
+
paddingHorizontal: 24,
|
|
152
|
+
paddingVertical: 14,
|
|
153
|
+
minHeight: 58,
|
|
154
|
+
fontSize: 17,
|
|
155
|
+
borderRadius: 16
|
|
156
|
+
}
|
|
157
|
+
};
|
|
158
|
+
const toneFor = (theme, tone) => {
|
|
159
|
+
switch (tone) {
|
|
160
|
+
case 'primary':
|
|
161
|
+
return {
|
|
162
|
+
base: theme.colors.primary,
|
|
163
|
+
hover: theme.colors.primaryHover,
|
|
164
|
+
pressed: theme.colors.primaryPressed,
|
|
165
|
+
on: theme.colors.text.inverse,
|
|
166
|
+
muted: theme.colors.primaryMuted
|
|
167
|
+
};
|
|
168
|
+
case 'secondary':
|
|
169
|
+
return {
|
|
170
|
+
base: theme.colors.secondary,
|
|
171
|
+
hover: theme.colors.secondaryHover,
|
|
172
|
+
pressed: theme.colors.secondaryHover,
|
|
173
|
+
on: theme.colors.text.primary,
|
|
174
|
+
muted: theme.colors.secondary
|
|
175
|
+
};
|
|
176
|
+
case 'success':
|
|
177
|
+
return {
|
|
178
|
+
base: theme.colors.success,
|
|
179
|
+
hover: theme.colors.success,
|
|
180
|
+
pressed: theme.colors.success,
|
|
181
|
+
on: theme.colors.text.inverse,
|
|
182
|
+
muted: theme.colors.background.secondary
|
|
183
|
+
};
|
|
184
|
+
case 'warning':
|
|
185
|
+
return {
|
|
186
|
+
base: theme.colors.warning,
|
|
187
|
+
hover: theme.colors.warning,
|
|
188
|
+
pressed: theme.colors.warning,
|
|
189
|
+
on: theme.colors.text.inverse,
|
|
190
|
+
muted: theme.colors.background.secondary
|
|
191
|
+
};
|
|
192
|
+
case 'danger':
|
|
193
|
+
return {
|
|
194
|
+
base: theme.colors.error,
|
|
195
|
+
hover: theme.colors.error,
|
|
196
|
+
pressed: theme.colors.error,
|
|
197
|
+
on: theme.colors.text.inverse,
|
|
198
|
+
muted: theme.colors.background.secondary
|
|
199
|
+
};
|
|
200
|
+
case 'neutral':
|
|
201
|
+
default:
|
|
202
|
+
return {
|
|
203
|
+
base: theme.colors.background.tertiary,
|
|
204
|
+
hover: theme.colors.surface.hovered,
|
|
205
|
+
pressed: theme.colors.surface.pressed,
|
|
206
|
+
on: theme.colors.text.primary,
|
|
207
|
+
muted: theme.colors.background.secondary
|
|
208
|
+
};
|
|
209
|
+
}
|
|
210
|
+
};
|
|
211
|
+
const variantFor = (theme, variant, toneSet, disabled) => {
|
|
212
|
+
switch (variant) {
|
|
213
|
+
case 'solid':
|
|
214
|
+
return {
|
|
215
|
+
backgroundColor: disabled ? theme.colors.surface.disabled : toneSet.base,
|
|
216
|
+
borderColor: 'transparent',
|
|
217
|
+
borderWidth: 0,
|
|
218
|
+
textColor: disabled ? theme.colors.text.disabled : toneSet.on
|
|
219
|
+
};
|
|
220
|
+
case 'outline':
|
|
221
|
+
return {
|
|
222
|
+
backgroundColor: 'transparent',
|
|
223
|
+
borderColor: disabled ? theme.colors.border.primary : toneSet.base,
|
|
224
|
+
borderWidth: 1,
|
|
225
|
+
textColor: disabled ? theme.colors.text.disabled : toneSet.base
|
|
226
|
+
};
|
|
227
|
+
case 'ghost':
|
|
228
|
+
return {
|
|
229
|
+
backgroundColor: 'transparent',
|
|
230
|
+
borderColor: 'transparent',
|
|
231
|
+
borderWidth: 0,
|
|
232
|
+
textColor: disabled ? theme.colors.text.disabled : toneSet.base
|
|
233
|
+
};
|
|
234
|
+
case 'link':
|
|
235
|
+
return {
|
|
236
|
+
backgroundColor: 'transparent',
|
|
237
|
+
borderColor: 'transparent',
|
|
238
|
+
borderWidth: 0,
|
|
239
|
+
textColor: disabled ? theme.colors.text.disabled : theme.colors.text.link
|
|
240
|
+
};
|
|
241
|
+
default:
|
|
242
|
+
return {
|
|
243
|
+
backgroundColor: toneSet.base,
|
|
244
|
+
borderColor: 'transparent',
|
|
245
|
+
borderWidth: 0,
|
|
246
|
+
textColor: toneSet.on
|
|
247
|
+
};
|
|
248
|
+
}
|
|
249
|
+
};
|
|
250
|
+
const buildStyles = _theme => StyleSheet.create({
|
|
251
|
+
base: {
|
|
252
|
+
alignItems: 'center',
|
|
253
|
+
justifyContent: 'center',
|
|
254
|
+
flexDirection: 'row',
|
|
255
|
+
overflow: 'hidden'
|
|
256
|
+
},
|
|
257
|
+
contentRow: {
|
|
258
|
+
flexDirection: 'row',
|
|
259
|
+
alignItems: 'center',
|
|
260
|
+
justifyContent: 'center'
|
|
261
|
+
},
|
|
262
|
+
label: {
|
|
263
|
+
textAlign: 'center'
|
|
264
|
+
},
|
|
265
|
+
iconLeft: {
|
|
266
|
+
marginRight: 8
|
|
267
|
+
},
|
|
268
|
+
iconRight: {
|
|
269
|
+
marginLeft: 8
|
|
270
|
+
},
|
|
271
|
+
fullWidth: {
|
|
272
|
+
alignSelf: 'stretch'
|
|
273
|
+
}
|
|
274
|
+
});
|
|
275
|
+
export { Button };
|
|
276
|
+
export default Button;
|
|
277
|
+
//# sourceMappingURL=Button.js.map
|