@procivis/one-react-native-components 0.1.63
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 +201 -0
- package/README.md +66 -0
- package/lib/commonjs/accessibility/accessibility.js +193 -0
- package/lib/commonjs/accessibility/accessibility.js.map +1 -0
- package/lib/commonjs/accessibility/accessibilityHistory.js +81 -0
- package/lib/commonjs/accessibility/accessibilityHistory.js.map +1 -0
- package/lib/commonjs/accessibility/accessibilityHistoryWrappers.js +49 -0
- package/lib/commonjs/accessibility/accessibilityHistoryWrappers.js.map +1 -0
- package/lib/commonjs/accessibility/accessibilityLanguage.js +63 -0
- package/lib/commonjs/accessibility/accessibilityLanguage.js.map +1 -0
- package/lib/commonjs/accessibility/index.js +129 -0
- package/lib/commonjs/accessibility/index.js.map +1 -0
- package/lib/commonjs/accessibility/locale/de.json +21 -0
- package/lib/commonjs/accessibility/locale/en.json +21 -0
- package/lib/commonjs/accessibility/locale/fr.json +21 -0
- package/lib/commonjs/accessibility/locale/index.js +21 -0
- package/lib/commonjs/accessibility/locale/index.js.map +1 -0
- package/lib/commonjs/accessibility/locale/it.json +21 -0
- package/lib/commonjs/accessibility/locale.test.js +15 -0
- package/lib/commonjs/accessibility/locale.test.js.map +1 -0
- package/lib/commonjs/action-modal/ActionModal.js +52 -0
- package/lib/commonjs/action-modal/ActionModal.js.map +1 -0
- package/lib/commonjs/action-modal/index.js +14 -0
- package/lib/commonjs/action-modal/index.js.map +1 -0
- package/lib/commonjs/activity-indicator/activity-indicator.js +34 -0
- package/lib/commonjs/activity-indicator/activity-indicator.js.map +1 -0
- package/lib/commonjs/activity-indicator/index.js +14 -0
- package/lib/commonjs/activity-indicator/index.js.map +1 -0
- package/lib/commonjs/blur/blur-view.js +76 -0
- package/lib/commonjs/blur/blur-view.js.map +1 -0
- package/lib/commonjs/blur/index.js +21 -0
- package/lib/commonjs/blur/index.js.map +1 -0
- package/lib/commonjs/buttons/back-button.js +37 -0
- package/lib/commonjs/buttons/back-button.js.map +1 -0
- package/lib/commonjs/buttons/button.js +153 -0
- package/lib/commonjs/buttons/button.js.map +1 -0
- package/lib/commonjs/buttons/connectivity-button.js +82 -0
- package/lib/commonjs/buttons/connectivity-button.js.map +1 -0
- package/lib/commonjs/buttons/filter-button.js +51 -0
- package/lib/commonjs/buttons/filter-button.js.map +1 -0
- package/lib/commonjs/buttons/ghost-button.js +62 -0
- package/lib/commonjs/buttons/ghost-button.js.map +1 -0
- package/lib/commonjs/buttons/index.js +104 -0
- package/lib/commonjs/buttons/index.js.map +1 -0
- package/lib/commonjs/buttons/scan-button.js +83 -0
- package/lib/commonjs/buttons/scan-button.js.map +1 -0
- package/lib/commonjs/camera/camera-overlay.js +61 -0
- package/lib/commonjs/camera/camera-overlay.js.map +1 -0
- package/lib/commonjs/camera/index.js +21 -0
- package/lib/commonjs/camera/index.js.map +1 -0
- package/lib/commonjs/camera/qr-code-scanner.js +50 -0
- package/lib/commonjs/camera/qr-code-scanner.js.map +1 -0
- package/lib/commonjs/control/checkbox.js +79 -0
- package/lib/commonjs/control/checkbox.js.map +1 -0
- package/lib/commonjs/control/index.js +32 -0
- package/lib/commonjs/control/index.js.map +1 -0
- package/lib/commonjs/control/switch.js +65 -0
- package/lib/commonjs/control/switch.js.map +1 -0
- package/lib/commonjs/credential/card/credential-card.js +189 -0
- package/lib/commonjs/credential/card/credential-card.js.map +1 -0
- package/lib/commonjs/credential/card/credential-details-card.js +201 -0
- package/lib/commonjs/credential/card/credential-details-card.js.map +1 -0
- package/lib/commonjs/credential/card/credential-details-list-item.js +84 -0
- package/lib/commonjs/credential/card/credential-details-list-item.js.map +1 -0
- package/lib/commonjs/credential/card/credential-header.js +172 -0
- package/lib/commonjs/credential/card/credential-header.js.map +1 -0
- package/lib/commonjs/credential/card/credential-image-carousel.js +124 -0
- package/lib/commonjs/credential/card/credential-image-carousel.js.map +1 -0
- package/lib/commonjs/credential/card/index.js +85 -0
- package/lib/commonjs/credential/card/index.js.map +1 -0
- package/lib/commonjs/credential/credential-attribute-item.js +289 -0
- package/lib/commonjs/credential/credential-attribute-item.js.map +1 -0
- package/lib/commonjs/credential/credential-carousel-images.js +98 -0
- package/lib/commonjs/credential/credential-carousel-images.js.map +1 -0
- package/lib/commonjs/credential/index.js +90 -0
- package/lib/commonjs/credential/index.js.map +1 -0
- package/lib/commonjs/credential/selector-status.js +17 -0
- package/lib/commonjs/credential/selector-status.js.map +1 -0
- package/lib/commonjs/credential/selector.js +79 -0
- package/lib/commonjs/credential/selector.js.map +1 -0
- package/lib/commonjs/detail/detail.js +84 -0
- package/lib/commonjs/detail/detail.js.map +1 -0
- package/lib/commonjs/detail/index.js +14 -0
- package/lib/commonjs/detail/index.js.map +1 -0
- package/lib/commonjs/entity/avatar.js +96 -0
- package/lib/commonjs/entity/avatar.js.map +1 -0
- package/lib/commonjs/entity/entity-cluster.js +66 -0
- package/lib/commonjs/entity/entity-cluster.js.map +1 -0
- package/lib/commonjs/entity/index.js +34 -0
- package/lib/commonjs/entity/index.js.map +1 -0
- package/lib/commonjs/header/focus-aware-status-bar.js +20 -0
- package/lib/commonjs/header/focus-aware-status-bar.js.map +1 -0
- package/lib/commonjs/header/foldable-header.js +89 -0
- package/lib/commonjs/header/foldable-header.js.map +1 -0
- package/lib/commonjs/header/header.js +105 -0
- package/lib/commonjs/header/header.js.map +1 -0
- package/lib/commonjs/header/index.js +55 -0
- package/lib/commonjs/header/index.js.map +1 -0
- package/lib/commonjs/header/navigation-header.js +148 -0
- package/lib/commonjs/header/navigation-header.js.map +1 -0
- package/lib/commonjs/history/data-item.js +70 -0
- package/lib/commonjs/history/data-item.js.map +1 -0
- package/lib/commonjs/history/history-list-item.js +90 -0
- package/lib/commonjs/history/history-list-item.js.map +1 -0
- package/lib/commonjs/history/history-section-header.js +49 -0
- package/lib/commonjs/history/history-section-header.js.map +1 -0
- package/lib/commonjs/history/history-section-list-item.js +47 -0
- package/lib/commonjs/history/history-section-list-item.js.map +1 -0
- package/lib/commonjs/history/index.js +55 -0
- package/lib/commonjs/history/index.js.map +1 -0
- package/lib/commonjs/icons/connectivity.js +139 -0
- package/lib/commonjs/icons/connectivity.js.map +1 -0
- package/lib/commonjs/icons/credential.js +162 -0
- package/lib/commonjs/icons/credential.js.map +1 -0
- package/lib/commonjs/icons/entity.js +34 -0
- package/lib/commonjs/icons/entity.js.map +1 -0
- package/lib/commonjs/icons/history.js +408 -0
- package/lib/commonjs/icons/history.js.map +1 -0
- package/lib/commonjs/icons/icons.js +250 -0
- package/lib/commonjs/icons/icons.js.map +1 -0
- package/lib/commonjs/icons/index.js +127 -0
- package/lib/commonjs/icons/index.js.map +1 -0
- package/lib/commonjs/icons/input.js +44 -0
- package/lib/commonjs/icons/input.js.map +1 -0
- package/lib/commonjs/icons/keypad.js +94 -0
- package/lib/commonjs/icons/keypad.js.map +1 -0
- package/lib/commonjs/icons/loader.js +180 -0
- package/lib/commonjs/icons/loader.js.map +1 -0
- package/lib/commonjs/icons/nerd-view.js +123 -0
- package/lib/commonjs/icons/nerd-view.js.map +1 -0
- package/lib/commonjs/icons/selector.js +56 -0
- package/lib/commonjs/icons/selector.js.map +1 -0
- package/lib/commonjs/icons/wallet.js +121 -0
- package/lib/commonjs/icons/wallet.js.map +1 -0
- package/lib/commonjs/image/image-or-component.js +80 -0
- package/lib/commonjs/image/image-or-component.js.map +1 -0
- package/lib/commonjs/image/index.js +21 -0
- package/lib/commonjs/image/index.js.map +1 -0
- package/lib/commonjs/index.js +292 -0
- package/lib/commonjs/index.js.map +1 -0
- package/lib/commonjs/input/index.js +65 -0
- package/lib/commonjs/input/index.js.map +1 -0
- package/lib/commonjs/input/radio-group.js +95 -0
- package/lib/commonjs/input/radio-group.js.map +1 -0
- package/lib/commonjs/input/selection-input.js +102 -0
- package/lib/commonjs/input/selection-input.js.map +1 -0
- package/lib/commonjs/input/text-input.js +195 -0
- package/lib/commonjs/input/text-input.js.map +1 -0
- package/lib/commonjs/list/index.js +34 -0
- package/lib/commonjs/list/index.js.map +1 -0
- package/lib/commonjs/list/list-section-header.js +36 -0
- package/lib/commonjs/list/list-section-header.js.map +1 -0
- package/lib/commonjs/list/list-title-header.js +35 -0
- package/lib/commonjs/list/list-title-header.js.map +1 -0
- package/lib/commonjs/loader/index.js +40 -0
- package/lib/commonjs/loader/index.js.map +1 -0
- package/lib/commonjs/loader/loader.js +140 -0
- package/lib/commonjs/loader/loader.js.map +1 -0
- package/lib/commonjs/loader/loading-result.js +92 -0
- package/lib/commonjs/loader/loading-result.js.map +1 -0
- package/lib/commonjs/nerd-view/index.js +27 -0
- package/lib/commonjs/nerd-view/index.js.map +1 -0
- package/lib/commonjs/nerd-view/nerd-mode-item.js +235 -0
- package/lib/commonjs/nerd-view/nerd-mode-item.js.map +1 -0
- package/lib/commonjs/normalize-color.d.js +2 -0
- package/lib/commonjs/normalize-color.d.js.map +1 -0
- package/lib/commonjs/pin/index.js +32 -0
- package/lib/commonjs/pin/index.js.map +1 -0
- package/lib/commonjs/pin/keypad.js +201 -0
- package/lib/commonjs/pin/keypad.js.map +1 -0
- package/lib/commonjs/pin/pin-code-screen.js +162 -0
- package/lib/commonjs/pin/pin-code-screen.js.map +1 -0
- package/lib/commonjs/pin/pins.js +54 -0
- package/lib/commonjs/pin/pins.js.map +1 -0
- package/lib/commonjs/screens/backup-screen.js +87 -0
- package/lib/commonjs/screens/backup-screen.js.map +1 -0
- package/lib/commonjs/screens/image-preview-screen.js +92 -0
- package/lib/commonjs/screens/image-preview-screen.js.map +1 -0
- package/lib/commonjs/screens/index.js +98 -0
- package/lib/commonjs/screens/index.js.map +1 -0
- package/lib/commonjs/screens/nerd-mode-screen.js +142 -0
- package/lib/commonjs/screens/nerd-mode-screen.js.map +1 -0
- package/lib/commonjs/screens/qr-code-scanner-screen.js +120 -0
- package/lib/commonjs/screens/qr-code-scanner-screen.js.map +1 -0
- package/lib/commonjs/screens/scroll-view-screen.js +94 -0
- package/lib/commonjs/screens/scroll-view-screen.js.map +1 -0
- package/lib/commonjs/screens/section-list-screen.js +67 -0
- package/lib/commonjs/screens/section-list-screen.js.map +1 -0
- package/lib/commonjs/searchbar/animated-search-bar.js +88 -0
- package/lib/commonjs/searchbar/animated-search-bar.js.map +1 -0
- package/lib/commonjs/searchbar/index.js +34 -0
- package/lib/commonjs/searchbar/index.js.map +1 -0
- package/lib/commonjs/searchbar/search-bar.js +99 -0
- package/lib/commonjs/searchbar/search-bar.js.map +1 -0
- package/lib/commonjs/settings/button-setting.js +67 -0
- package/lib/commonjs/settings/button-setting.js.map +1 -0
- package/lib/commonjs/settings/index.js +73 -0
- package/lib/commonjs/settings/index.js.map +1 -0
- package/lib/commonjs/settings/setting-item-separator.js +40 -0
- package/lib/commonjs/settings/setting-item-separator.js.map +1 -0
- package/lib/commonjs/settings/setting-item.js +79 -0
- package/lib/commonjs/settings/setting-item.js.map +1 -0
- package/lib/commonjs/settings/settings-button.js +35 -0
- package/lib/commonjs/settings/settings-button.js.map +1 -0
- package/lib/commonjs/settings/switch-setting.js +35 -0
- package/lib/commonjs/settings/switch-setting.js.map +1 -0
- package/lib/commonjs/state/error-screen.js +71 -0
- package/lib/commonjs/state/error-screen.js.map +1 -0
- package/lib/commonjs/state/index.js +27 -0
- package/lib/commonjs/state/index.js.map +1 -0
- package/lib/commonjs/text/base.js +40 -0
- package/lib/commonjs/text/base.js.map +1 -0
- package/lib/commonjs/text/font.js +64 -0
- package/lib/commonjs/text/font.js.map +1 -0
- package/lib/commonjs/text/index.js +21 -0
- package/lib/commonjs/text/index.js.map +1 -0
- package/lib/commonjs/text/typography.js +119 -0
- package/lib/commonjs/text/typography.js.map +1 -0
- package/lib/commonjs/theme/color-scheme-context.js +52 -0
- package/lib/commonjs/theme/color-scheme-context.js.map +1 -0
- package/lib/commonjs/theme/color-scheme.js +2 -0
- package/lib/commonjs/theme/color-scheme.js.map +1 -0
- package/lib/commonjs/theme/index.js +19 -0
- package/lib/commonjs/theme/index.js.map +1 -0
- package/lib/commonjs/utils/color.js +34 -0
- package/lib/commonjs/utils/color.js.map +1 -0
- package/lib/commonjs/utils/contrasting-status-bar.js +30 -0
- package/lib/commonjs/utils/contrasting-status-bar.js.map +1 -0
- package/lib/commonjs/utils/date.js +57 -0
- package/lib/commonjs/utils/date.js.map +1 -0
- package/lib/commonjs/utils/hooks/header/on-scroll-header-state.js +21 -0
- package/lib/commonjs/utils/hooks/header/on-scroll-header-state.js.map +1 -0
- package/lib/commonjs/utils/hooks/index.js +20 -0
- package/lib/commonjs/utils/hooks/index.js.map +1 -0
- package/lib/commonjs/utils/hooks/list/list-content-inset.js +31 -0
- package/lib/commonjs/utils/hooks/list/list-content-inset.js.map +1 -0
- package/lib/commonjs/utils/index.js +83 -0
- package/lib/commonjs/utils/index.js.map +1 -0
- package/lib/commonjs/utils/navigation.js +51 -0
- package/lib/commonjs/utils/navigation.js.map +1 -0
- package/lib/commonjs/utils/ref.js +42 -0
- package/lib/commonjs/utils/ref.js.map +1 -0
- package/lib/commonjs/utils/testID.js +18 -0
- package/lib/commonjs/utils/testID.js.map +1 -0
- package/lib/commonjs/utils/testID.test.js +21 -0
- package/lib/commonjs/utils/testID.test.js.map +1 -0
- package/lib/commonjs/utils/useMemoAsync.js +26 -0
- package/lib/commonjs/utils/useMemoAsync.js.map +1 -0
- package/lib/module/accessibility/accessibility.js +185 -0
- package/lib/module/accessibility/accessibility.js.map +1 -0
- package/lib/module/accessibility/accessibilityHistory.js +71 -0
- package/lib/module/accessibility/accessibilityHistory.js.map +1 -0
- package/lib/module/accessibility/accessibilityHistoryWrappers.js +38 -0
- package/lib/module/accessibility/accessibilityHistoryWrappers.js.map +1 -0
- package/lib/module/accessibility/accessibilityLanguage.js +53 -0
- package/lib/module/accessibility/accessibilityLanguage.js.map +1 -0
- package/lib/module/accessibility/index.js +8 -0
- package/lib/module/accessibility/index.js.map +1 -0
- package/lib/module/accessibility/locale/de.json +21 -0
- package/lib/module/accessibility/locale/en.json +21 -0
- package/lib/module/accessibility/locale/fr.json +21 -0
- package/lib/module/accessibility/locale/index.js +12 -0
- package/lib/module/accessibility/locale/index.js.map +1 -0
- package/lib/module/accessibility/locale/it.json +21 -0
- package/lib/module/accessibility/locale.test.js +13 -0
- package/lib/module/accessibility/locale.test.js.map +1 -0
- package/lib/module/action-modal/ActionModal.js +44 -0
- package/lib/module/action-modal/ActionModal.js.map +1 -0
- package/lib/module/action-modal/index.js +3 -0
- package/lib/module/action-modal/index.js.map +1 -0
- package/lib/module/activity-indicator/activity-indicator.js +24 -0
- package/lib/module/activity-indicator/activity-indicator.js.map +1 -0
- package/lib/module/activity-indicator/index.js +3 -0
- package/lib/module/activity-indicator/index.js.map +1 -0
- package/lib/module/blur/blur-view.js +67 -0
- package/lib/module/blur/blur-view.js.map +1 -0
- package/lib/module/blur/index.js +3 -0
- package/lib/module/blur/index.js.map +1 -0
- package/lib/module/buttons/back-button.js +28 -0
- package/lib/module/buttons/back-button.js.map +1 -0
- package/lib/module/buttons/button.js +143 -0
- package/lib/module/buttons/button.js.map +1 -0
- package/lib/module/buttons/connectivity-button.js +73 -0
- package/lib/module/buttons/connectivity-button.js.map +1 -0
- package/lib/module/buttons/filter-button.js +43 -0
- package/lib/module/buttons/filter-button.js.map +1 -0
- package/lib/module/buttons/ghost-button.js +53 -0
- package/lib/module/buttons/ghost-button.js.map +1 -0
- package/lib/module/buttons/index.js +8 -0
- package/lib/module/buttons/index.js.map +1 -0
- package/lib/module/buttons/scan-button.js +75 -0
- package/lib/module/buttons/scan-button.js.map +1 -0
- package/lib/module/camera/camera-overlay.js +51 -0
- package/lib/module/camera/camera-overlay.js.map +1 -0
- package/lib/module/camera/index.js +3 -0
- package/lib/module/camera/index.js.map +1 -0
- package/lib/module/camera/qr-code-scanner.js +40 -0
- package/lib/module/camera/qr-code-scanner.js.map +1 -0
- package/lib/module/control/checkbox.js +70 -0
- package/lib/module/control/checkbox.js.map +1 -0
- package/lib/module/control/index.js +4 -0
- package/lib/module/control/index.js.map +1 -0
- package/lib/module/control/switch.js +56 -0
- package/lib/module/control/switch.js.map +1 -0
- package/lib/module/credential/card/credential-card.js +177 -0
- package/lib/module/credential/card/credential-card.js.map +1 -0
- package/lib/module/credential/card/credential-details-card.js +191 -0
- package/lib/module/credential/card/credential-details-card.js.map +1 -0
- package/lib/module/credential/card/credential-details-list-item.js +74 -0
- package/lib/module/credential/card/credential-details-list-item.js.map +1 -0
- package/lib/module/credential/card/credential-header.js +162 -0
- package/lib/module/credential/card/credential-header.js.map +1 -0
- package/lib/module/credential/card/credential-image-carousel.js +113 -0
- package/lib/module/credential/card/credential-image-carousel.js.map +1 -0
- package/lib/module/credential/card/index.js +11 -0
- package/lib/module/credential/card/index.js.map +1 -0
- package/lib/module/credential/credential-attribute-item.js +279 -0
- package/lib/module/credential/credential-attribute-item.js.map +1 -0
- package/lib/module/credential/credential-carousel-images.js +86 -0
- package/lib/module/credential/credential-carousel-images.js.map +1 -0
- package/lib/module/credential/index.js +9 -0
- package/lib/module/credential/index.js.map +1 -0
- package/lib/module/credential/selector-status.js +10 -0
- package/lib/module/credential/selector-status.js.map +1 -0
- package/lib/module/credential/selector.js +70 -0
- package/lib/module/credential/selector.js.map +1 -0
- package/lib/module/detail/detail.js +75 -0
- package/lib/module/detail/detail.js.map +1 -0
- package/lib/module/detail/index.js +3 -0
- package/lib/module/detail/index.js.map +1 -0
- package/lib/module/entity/avatar.js +86 -0
- package/lib/module/entity/avatar.js.map +1 -0
- package/lib/module/entity/entity-cluster.js +56 -0
- package/lib/module/entity/entity-cluster.js.map +1 -0
- package/lib/module/entity/index.js +5 -0
- package/lib/module/entity/index.js.map +1 -0
- package/lib/module/header/focus-aware-status-bar.js +12 -0
- package/lib/module/header/focus-aware-status-bar.js.map +1 -0
- package/lib/module/header/foldable-header.js +79 -0
- package/lib/module/header/foldable-header.js.map +1 -0
- package/lib/module/header/header.js +97 -0
- package/lib/module/header/header.js.map +1 -0
- package/lib/module/header/index.js +9 -0
- package/lib/module/header/index.js.map +1 -0
- package/lib/module/header/navigation-header.js +138 -0
- package/lib/module/header/navigation-header.js.map +1 -0
- package/lib/module/history/data-item.js +60 -0
- package/lib/module/history/data-item.js.map +1 -0
- package/lib/module/history/history-list-item.js +80 -0
- package/lib/module/history/history-list-item.js.map +1 -0
- package/lib/module/history/history-section-header.js +42 -0
- package/lib/module/history/history-section-header.js.map +1 -0
- package/lib/module/history/history-section-list-item.js +43 -0
- package/lib/module/history/history-section-list-item.js.map +1 -0
- package/lib/module/history/index.js +9 -0
- package/lib/module/history/index.js.map +1 -0
- package/lib/module/icons/connectivity.js +125 -0
- package/lib/module/icons/connectivity.js.map +1 -0
- package/lib/module/icons/credential.js +147 -0
- package/lib/module/icons/credential.js.map +1 -0
- package/lib/module/icons/entity.js +25 -0
- package/lib/module/icons/entity.js.map +1 -0
- package/lib/module/icons/history.js +391 -0
- package/lib/module/icons/history.js.map +1 -0
- package/lib/module/icons/icons.js +231 -0
- package/lib/module/icons/icons.js.map +1 -0
- package/lib/module/icons/index.js +12 -0
- package/lib/module/icons/index.js.map +1 -0
- package/lib/module/icons/input.js +33 -0
- package/lib/module/icons/input.js.map +1 -0
- package/lib/module/icons/keypad.js +81 -0
- package/lib/module/icons/keypad.js.map +1 -0
- package/lib/module/icons/loader.js +168 -0
- package/lib/module/icons/loader.js.map +1 -0
- package/lib/module/icons/nerd-view.js +110 -0
- package/lib/module/icons/nerd-view.js.map +1 -0
- package/lib/module/icons/selector.js +45 -0
- package/lib/module/icons/selector.js.map +1 -0
- package/lib/module/icons/wallet.js +111 -0
- package/lib/module/icons/wallet.js.map +1 -0
- package/lib/module/image/image-or-component.js +71 -0
- package/lib/module/image/image-or-component.js.map +1 -0
- package/lib/module/image/index.js +3 -0
- package/lib/module/image/index.js.map +1 -0
- package/lib/module/index.js +27 -0
- package/lib/module/index.js.map +1 -0
- package/lib/module/input/index.js +7 -0
- package/lib/module/input/index.js.map +1 -0
- package/lib/module/input/radio-group.js +87 -0
- package/lib/module/input/radio-group.js.map +1 -0
- package/lib/module/input/selection-input.js +92 -0
- package/lib/module/input/selection-input.js.map +1 -0
- package/lib/module/input/text-input.js +185 -0
- package/lib/module/input/text-input.js.map +1 -0
- package/lib/module/list/index.js +5 -0
- package/lib/module/list/index.js.map +1 -0
- package/lib/module/list/list-section-header.js +28 -0
- package/lib/module/list/list-section-header.js.map +1 -0
- package/lib/module/list/list-title-header.js +27 -0
- package/lib/module/list/list-title-header.js.map +1 -0
- package/lib/module/loader/index.js +5 -0
- package/lib/module/loader/index.js.map +1 -0
- package/lib/module/loader/loader.js +130 -0
- package/lib/module/loader/loader.js.map +1 -0
- package/lib/module/loader/loading-result.js +84 -0
- package/lib/module/loader/loading-result.js.map +1 -0
- package/lib/module/nerd-view/index.js +3 -0
- package/lib/module/nerd-view/index.js.map +1 -0
- package/lib/module/nerd-view/nerd-mode-item.js +224 -0
- package/lib/module/nerd-view/nerd-mode-item.js.map +1 -0
- package/lib/module/normalize-color.d.js +2 -0
- package/lib/module/normalize-color.d.js.map +1 -0
- package/lib/module/pin/index.js +4 -0
- package/lib/module/pin/index.js.map +1 -0
- package/lib/module/pin/keypad.js +191 -0
- package/lib/module/pin/keypad.js.map +1 -0
- package/lib/module/pin/pin-code-screen.js +152 -0
- package/lib/module/pin/pin-code-screen.js.map +1 -0
- package/lib/module/pin/pins.js +46 -0
- package/lib/module/pin/pins.js.map +1 -0
- package/lib/module/screens/backup-screen.js +78 -0
- package/lib/module/screens/backup-screen.js.map +1 -0
- package/lib/module/screens/image-preview-screen.js +83 -0
- package/lib/module/screens/image-preview-screen.js.map +1 -0
- package/lib/module/screens/index.js +13 -0
- package/lib/module/screens/index.js.map +1 -0
- package/lib/module/screens/nerd-mode-screen.js +132 -0
- package/lib/module/screens/nerd-mode-screen.js.map +1 -0
- package/lib/module/screens/qr-code-scanner-screen.js +110 -0
- package/lib/module/screens/qr-code-scanner-screen.js.map +1 -0
- package/lib/module/screens/scroll-view-screen.js +86 -0
- package/lib/module/screens/scroll-view-screen.js.map +1 -0
- package/lib/module/screens/section-list-screen.js +59 -0
- package/lib/module/screens/section-list-screen.js.map +1 -0
- package/lib/module/searchbar/animated-search-bar.js +78 -0
- package/lib/module/searchbar/animated-search-bar.js.map +1 -0
- package/lib/module/searchbar/index.js +5 -0
- package/lib/module/searchbar/index.js.map +1 -0
- package/lib/module/searchbar/search-bar.js +89 -0
- package/lib/module/searchbar/search-bar.js.map +1 -0
- package/lib/module/settings/button-setting.js +57 -0
- package/lib/module/settings/button-setting.js.map +1 -0
- package/lib/module/settings/index.js +11 -0
- package/lib/module/settings/index.js.map +1 -0
- package/lib/module/settings/setting-item-separator.js +32 -0
- package/lib/module/settings/setting-item-separator.js.map +1 -0
- package/lib/module/settings/setting-item.js +69 -0
- package/lib/module/settings/setting-item.js.map +1 -0
- package/lib/module/settings/settings-button.js +27 -0
- package/lib/module/settings/settings-button.js.map +1 -0
- package/lib/module/settings/switch-setting.js +27 -0
- package/lib/module/settings/switch-setting.js.map +1 -0
- package/lib/module/state/error-screen.js +63 -0
- package/lib/module/state/error-screen.js.map +1 -0
- package/lib/module/state/index.js +3 -0
- package/lib/module/state/index.js.map +1 -0
- package/lib/module/text/base.js +31 -0
- package/lib/module/text/base.js.map +1 -0
- package/lib/module/text/font.js +56 -0
- package/lib/module/text/font.js.map +1 -0
- package/lib/module/text/index.js +3 -0
- package/lib/module/text/index.js.map +1 -0
- package/lib/module/text/typography.js +111 -0
- package/lib/module/text/typography.js.map +1 -0
- package/lib/module/theme/color-scheme-context.js +44 -0
- package/lib/module/theme/color-scheme-context.js.map +1 -0
- package/lib/module/theme/color-scheme.js +2 -0
- package/lib/module/theme/color-scheme.js.map +1 -0
- package/lib/module/theme/index.js +3 -0
- package/lib/module/theme/index.js.map +1 -0
- package/lib/module/utils/color.js +23 -0
- package/lib/module/utils/color.js.map +1 -0
- package/lib/module/utils/contrasting-status-bar.js +21 -0
- package/lib/module/utils/contrasting-status-bar.js.map +1 -0
- package/lib/module/utils/date.js +51 -0
- package/lib/module/utils/date.js.map +1 -0
- package/lib/module/utils/hooks/header/on-scroll-header-state.js +14 -0
- package/lib/module/utils/hooks/header/on-scroll-header-state.js.map +1 -0
- package/lib/module/utils/hooks/index.js +5 -0
- package/lib/module/utils/hooks/index.js.map +1 -0
- package/lib/module/utils/hooks/list/list-content-inset.js +24 -0
- package/lib/module/utils/hooks/list/list-content-inset.js.map +1 -0
- package/lib/module/utils/index.js +9 -0
- package/lib/module/utils/index.js.map +1 -0
- package/lib/module/utils/navigation.js +45 -0
- package/lib/module/utils/navigation.js.map +1 -0
- package/lib/module/utils/ref.js +35 -0
- package/lib/module/utils/ref.js.map +1 -0
- package/lib/module/utils/testID.js +12 -0
- package/lib/module/utils/testID.js.map +1 -0
- package/lib/module/utils/testID.test.js +19 -0
- package/lib/module/utils/testID.test.js.map +1 -0
- package/lib/module/utils/useMemoAsync.js +20 -0
- package/lib/module/utils/useMemoAsync.js.map +1 -0
- package/lib/typescript/accessibility/accessibility.d.ts +55 -0
- package/lib/typescript/accessibility/accessibilityHistory.d.ts +13 -0
- package/lib/typescript/accessibility/accessibilityHistoryWrappers.d.ts +18 -0
- package/lib/typescript/accessibility/accessibilityLanguage.d.ts +20 -0
- package/lib/typescript/accessibility/index.d.ts +6 -0
- package/lib/typescript/accessibility/locale/index.d.ts +90 -0
- package/lib/typescript/accessibility/locale.test.d.ts +1 -0
- package/lib/typescript/action-modal/ActionModal.d.ts +10 -0
- package/lib/typescript/action-modal/index.d.ts +2 -0
- package/lib/typescript/activity-indicator/activity-indicator.d.ts +7 -0
- package/lib/typescript/activity-indicator/index.d.ts +2 -0
- package/lib/typescript/blur/blur-view.d.ts +10 -0
- package/lib/typescript/blur/index.d.ts +2 -0
- package/lib/typescript/buttons/back-button.d.ts +9 -0
- package/lib/typescript/buttons/button.d.ts +22 -0
- package/lib/typescript/buttons/connectivity-button.d.ts +17 -0
- package/lib/typescript/buttons/filter-button.d.ts +7 -0
- package/lib/typescript/buttons/ghost-button.d.ts +11 -0
- package/lib/typescript/buttons/index.d.ts +7 -0
- package/lib/typescript/buttons/scan-button.d.ts +5 -0
- package/lib/typescript/camera/camera-overlay.d.ts +7 -0
- package/lib/typescript/camera/index.d.ts +2 -0
- package/lib/typescript/camera/qr-code-scanner.d.ts +11 -0
- package/lib/typescript/control/checkbox.d.ts +9 -0
- package/lib/typescript/control/index.d.ts +3 -0
- package/lib/typescript/control/switch.d.ts +7 -0
- package/lib/typescript/credential/card/credential-card.d.ts +22 -0
- package/lib/typescript/credential/card/credential-details-card.d.ts +16 -0
- package/lib/typescript/credential/card/credential-details-list-item.d.ts +9 -0
- package/lib/typescript/credential/card/credential-header.d.ts +20 -0
- package/lib/typescript/credential/card/credential-image-carousel.d.ts +23 -0
- package/lib/typescript/credential/card/index.d.ts +10 -0
- package/lib/typescript/credential/credential-attribute-item.d.ts +48 -0
- package/lib/typescript/credential/credential-carousel-images.d.ts +19 -0
- package/lib/typescript/credential/index.d.ts +8 -0
- package/lib/typescript/credential/selector-status.d.ts +8 -0
- package/lib/typescript/credential/selector.d.ts +15 -0
- package/lib/typescript/detail/detail.d.ts +18 -0
- package/lib/typescript/detail/index.d.ts +2 -0
- package/lib/typescript/entity/avatar.d.ts +10 -0
- package/lib/typescript/entity/entity-cluster.d.ts +12 -0
- package/lib/typescript/entity/index.d.ts +4 -0
- package/lib/typescript/header/focus-aware-status-bar.d.ts +4 -0
- package/lib/typescript/header/foldable-header.d.ts +11 -0
- package/lib/typescript/header/header.d.ts +17 -0
- package/lib/typescript/header/index.d.ts +8 -0
- package/lib/typescript/header/navigation-header.d.ts +15 -0
- package/lib/typescript/history/data-item.d.ts +12 -0
- package/lib/typescript/history/history-list-item.d.ts +14 -0
- package/lib/typescript/history/history-section-header.d.ts +7 -0
- package/lib/typescript/history/history-section-list-item.d.ts +7 -0
- package/lib/typescript/history/index.d.ts +8 -0
- package/lib/typescript/icons/connectivity.d.ts +12 -0
- package/lib/typescript/icons/credential.d.ts +9 -0
- package/lib/typescript/icons/entity.d.ts +3 -0
- package/lib/typescript/icons/history.d.ts +42 -0
- package/lib/typescript/icons/icons.d.ts +13 -0
- package/lib/typescript/icons/index.d.ts +11 -0
- package/lib/typescript/icons/input.d.ts +3 -0
- package/lib/typescript/icons/keypad.d.ts +6 -0
- package/lib/typescript/icons/loader.d.ts +6 -0
- package/lib/typescript/icons/nerd-view.d.ts +7 -0
- package/lib/typescript/icons/selector.d.ts +10 -0
- package/lib/typescript/icons/wallet.d.ts +4 -0
- package/lib/typescript/image/image-or-component.d.ts +16 -0
- package/lib/typescript/image/index.d.ts +2 -0
- package/lib/typescript/index.d.ts +26 -0
- package/lib/typescript/input/index.d.ts +6 -0
- package/lib/typescript/input/radio-group.d.ts +23 -0
- package/lib/typescript/input/selection-input.d.ts +32 -0
- package/lib/typescript/input/text-input.d.ts +31 -0
- package/lib/typescript/list/index.d.ts +4 -0
- package/lib/typescript/list/list-section-header.d.ts +7 -0
- package/lib/typescript/list/list-title-header.d.ts +7 -0
- package/lib/typescript/loader/index.d.ts +4 -0
- package/lib/typescript/loader/loader.d.ts +14 -0
- package/lib/typescript/loader/loading-result.d.ts +16 -0
- package/lib/typescript/nerd-view/index.d.ts +2 -0
- package/lib/typescript/nerd-view/nerd-mode-item.d.ts +31 -0
- package/lib/typescript/pin/index.d.ts +3 -0
- package/lib/typescript/pin/keypad.d.ts +16 -0
- package/lib/typescript/pin/pin-code-screen.d.ts +32 -0
- package/lib/typescript/pin/pins.d.ts +7 -0
- package/lib/typescript/screens/backup-screen.d.ts +16 -0
- package/lib/typescript/screens/image-preview-screen.d.ts +9 -0
- package/lib/typescript/screens/index.d.ts +12 -0
- package/lib/typescript/screens/nerd-mode-screen.d.ts +22 -0
- package/lib/typescript/screens/qr-code-scanner-screen.d.ts +14 -0
- package/lib/typescript/screens/scroll-view-screen.d.ts +13 -0
- package/lib/typescript/screens/section-list-screen.d.ts +12 -0
- package/lib/typescript/searchbar/animated-search-bar.d.ts +10 -0
- package/lib/typescript/searchbar/index.d.ts +4 -0
- package/lib/typescript/searchbar/search-bar.d.ts +10 -0
- package/lib/typescript/settings/button-setting.d.ts +13 -0
- package/lib/typescript/settings/index.d.ts +10 -0
- package/lib/typescript/settings/setting-item-separator.d.ts +8 -0
- package/lib/typescript/settings/setting-item.d.ts +9 -0
- package/lib/typescript/settings/settings-button.d.ts +5 -0
- package/lib/typescript/settings/switch-setting.d.ts +13 -0
- package/lib/typescript/state/error-screen.d.ts +15 -0
- package/lib/typescript/state/index.d.ts +2 -0
- package/lib/typescript/text/base.d.ts +20 -0
- package/lib/typescript/text/font.d.ts +26 -0
- package/lib/typescript/text/index.d.ts +2 -0
- package/lib/typescript/text/typography.d.ts +112 -0
- package/lib/typescript/theme/color-scheme-context.d.ts +10 -0
- package/lib/typescript/theme/color-scheme.d.ts +31 -0
- package/lib/typescript/theme/index.d.ts +3 -0
- package/lib/typescript/utils/color.d.ts +4 -0
- package/lib/typescript/utils/contrasting-status-bar.d.ts +10 -0
- package/lib/typescript/utils/date.d.ts +12 -0
- package/lib/typescript/utils/hooks/header/on-scroll-header-state.d.ts +5 -0
- package/lib/typescript/utils/hooks/index.d.ts +4 -0
- package/lib/typescript/utils/hooks/list/list-content-inset.d.ts +8 -0
- package/lib/typescript/utils/index.d.ts +8 -0
- package/lib/typescript/utils/navigation.d.ts +9 -0
- package/lib/typescript/utils/ref.d.ts +11 -0
- package/lib/typescript/utils/testID.d.ts +6 -0
- package/lib/typescript/utils/testID.test.d.ts +1 -0
- package/lib/typescript/utils/useMemoAsync.d.ts +21 -0
- package/package.json +240 -0
- package/src/accessibility/accessibility.ts +215 -0
- package/src/accessibility/accessibilityHistory.tsx +77 -0
- package/src/accessibility/accessibilityHistoryWrappers.tsx +80 -0
- package/src/accessibility/accessibilityLanguage.tsx +66 -0
- package/src/accessibility/index.ts +35 -0
- package/src/accessibility/locale/de.json +21 -0
- package/src/accessibility/locale/en.json +21 -0
- package/src/accessibility/locale/fr.json +21 -0
- package/src/accessibility/locale/index.ts +19 -0
- package/src/accessibility/locale/it.json +21 -0
- package/src/accessibility/locale.test.ts +16 -0
- package/src/action-modal/ActionModal.stories.tsx +35 -0
- package/src/action-modal/ActionModal.tsx +45 -0
- package/src/action-modal/index.ts +3 -0
- package/src/activity-indicator/activity-indicator.stories.tsx +21 -0
- package/src/activity-indicator/activity-indicator.tsx +25 -0
- package/src/activity-indicator/index.ts +3 -0
- package/src/blur/blur-view.tsx +82 -0
- package/src/blur/index.ts +3 -0
- package/src/buttons/back-button.stories.tsx +31 -0
- package/src/buttons/back-button.tsx +31 -0
- package/src/buttons/button.stories.tsx +29 -0
- package/src/buttons/button.tsx +169 -0
- package/src/buttons/connectivity-button.stories.tsx +34 -0
- package/src/buttons/connectivity-button.tsx +95 -0
- package/src/buttons/filter-button.tsx +38 -0
- package/src/buttons/ghost-button.stories.tsx +28 -0
- package/src/buttons/ghost-button.tsx +56 -0
- package/src/buttons/index.ts +24 -0
- package/src/buttons/scan-button.stories.tsx +26 -0
- package/src/buttons/scan-button.tsx +66 -0
- package/src/camera/camera-overlay.tsx +48 -0
- package/src/camera/index.tsx +3 -0
- package/src/camera/qr-code-scanner.tsx +52 -0
- package/src/control/checkbox.stories.tsx +27 -0
- package/src/control/checkbox.tsx +81 -0
- package/src/control/index.ts +4 -0
- package/src/control/switch.stories.tsx +29 -0
- package/src/control/switch.tsx +47 -0
- package/src/credential/card/credential-card.stories.tsx +52 -0
- package/src/credential/card/credential-card.tsx +195 -0
- package/src/credential/card/credential-details-card.stories.tsx +268 -0
- package/src/credential/card/credential-details-card.tsx +242 -0
- package/src/credential/card/credential-details-list-item.tsx +87 -0
- package/src/credential/card/credential-header.stories.tsx +50 -0
- package/src/credential/card/credential-header.tsx +195 -0
- package/src/credential/card/credential-image-carousel.tsx +113 -0
- package/src/credential/card/index.ts +11 -0
- package/src/credential/credential-attribute-item.tsx +372 -0
- package/src/credential/credential-carousel-images.tsx +90 -0
- package/src/credential/index.ts +13 -0
- package/src/credential/selector-status.ts +8 -0
- package/src/credential/selector.stories.tsx +37 -0
- package/src/credential/selector.tsx +64 -0
- package/src/detail/detail.stories.tsx +65 -0
- package/src/detail/detail.tsx +98 -0
- package/src/detail/index.tsx +3 -0
- package/src/entity/avatar.stories.tsx +39 -0
- package/src/entity/avatar.tsx +87 -0
- package/src/entity/entity-cluster.stories.tsx +42 -0
- package/src/entity/entity-cluster.tsx +72 -0
- package/src/entity/index.ts +5 -0
- package/src/header/focus-aware-status-bar.tsx +10 -0
- package/src/header/foldable-header.tsx +107 -0
- package/src/header/header.stories.tsx +59 -0
- package/src/header/header.tsx +105 -0
- package/src/header/index.ts +9 -0
- package/src/header/navigation-header.stories.tsx +56 -0
- package/src/header/navigation-header.tsx +147 -0
- package/src/history/data-item.tsx +79 -0
- package/src/history/history-list-item.tsx +102 -0
- package/src/history/history-section-header.tsx +44 -0
- package/src/history/history-section-list-item.tsx +41 -0
- package/src/history/index.ts +9 -0
- package/src/icons/connectivity.tsx +114 -0
- package/src/icons/credential.tsx +118 -0
- package/src/icons/entity.tsx +21 -0
- package/src/icons/history.tsx +378 -0
- package/src/icons/icons.tsx +134 -0
- package/src/icons/index.ts +11 -0
- package/src/icons/input.tsx +29 -0
- package/src/icons/keypad.tsx +40 -0
- package/src/icons/loader.tsx +117 -0
- package/src/icons/nerd-view.tsx +105 -0
- package/src/icons/selector.tsx +43 -0
- package/src/icons/wallet.tsx +73 -0
- package/src/image/image-or-component.tsx +92 -0
- package/src/image/index.tsx +3 -0
- package/src/index.ts +26 -0
- package/src/input/index.ts +7 -0
- package/src/input/radio-group.tsx +110 -0
- package/src/input/selection-input.stories.tsx +46 -0
- package/src/input/selection-input.tsx +112 -0
- package/src/input/text-input.tsx +253 -0
- package/src/list/index.ts +5 -0
- package/src/list/list-section-header.tsx +37 -0
- package/src/list/list-title-header.tsx +30 -0
- package/src/loader/index.ts +5 -0
- package/src/loader/loader.stories.tsx +31 -0
- package/src/loader/loader.tsx +169 -0
- package/src/loader/loading-result.stories.tsx +67 -0
- package/src/loader/loading-result.tsx +93 -0
- package/src/nerd-view/index.ts +3 -0
- package/src/nerd-view/nerd-mode-item.tsx +296 -0
- package/src/normalize-color.d.ts +1 -0
- package/src/pin/index.ts +4 -0
- package/src/pin/keypad.tsx +166 -0
- package/src/pin/pin-code-screen.stories.tsx +80 -0
- package/src/pin/pin-code-screen.tsx +195 -0
- package/src/pin/pins.tsx +48 -0
- package/src/screens/backup-screen.tsx +92 -0
- package/src/screens/image-preview-screen.stories.tsx +28 -0
- package/src/screens/image-preview-screen.tsx +82 -0
- package/src/screens/index.ts +13 -0
- package/src/screens/nerd-mode-screen.tsx +150 -0
- package/src/screens/qr-code-scanner-screen.stories.tsx +37 -0
- package/src/screens/qr-code-scanner-screen.tsx +124 -0
- package/src/screens/scroll-view-screen.tsx +91 -0
- package/src/screens/section-list-screen.tsx +61 -0
- package/src/searchbar/animated-search-bar.tsx +96 -0
- package/src/searchbar/index.ts +5 -0
- package/src/searchbar/search-bar.stories.tsx +31 -0
- package/src/searchbar/search-bar.tsx +94 -0
- package/src/settings/button-setting.tsx +72 -0
- package/src/settings/index.ts +11 -0
- package/src/settings/setting-item-separator.tsx +32 -0
- package/src/settings/setting-item.tsx +68 -0
- package/src/settings/settings-button.tsx +23 -0
- package/src/settings/switch-setting.tsx +33 -0
- package/src/state/error-screen.stories.tsx +22 -0
- package/src/state/error-screen.tsx +71 -0
- package/src/state/index.ts +3 -0
- package/src/text/base.tsx +53 -0
- package/src/text/font.ts +52 -0
- package/src/text/index.ts +3 -0
- package/src/text/typography.stories.tsx +70 -0
- package/src/text/typography.tsx +117 -0
- package/src/theme/color-scheme-context.tsx +48 -0
- package/src/theme/color-scheme.ts +31 -0
- package/src/theme/index.ts +4 -0
- package/src/utils/color.ts +34 -0
- package/src/utils/contrasting-status-bar.tsx +21 -0
- package/src/utils/date.ts +49 -0
- package/src/utils/hooks/header/on-scroll-header-state.tsx +16 -0
- package/src/utils/hooks/index.ts +5 -0
- package/src/utils/hooks/list/list-content-inset.ts +24 -0
- package/src/utils/index.ts +19 -0
- package/src/utils/navigation.ts +37 -0
- package/src/utils/ref.ts +39 -0
- package/src/utils/testID.test.ts +20 -0
- package/src/utils/testID.ts +9 -0
- package/src/utils/useMemoAsync.ts +50 -0
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["_react","_interopRequireDefault","require","obj","__esModule","default","defaultColorScheme","accent","accentText","background","backgroundScroll","black","codeAccent","credentialHeaderBackground","error","grayDark","linkText","success","successText","text","warning","white","darkMode","nerdView","attributeLabel","attributeValueBackground","attributeValueBorder","attributeSectionBackground","button","codeHighlightText","ColorSchemeContext","React","createContext","displayName","ColorSchemeProvider","props","createElement","Provider","value","colorScheme","children","useAppColorScheme","useContext"],"sources":["color-scheme-context.tsx"],"sourcesContent":["import React, { PropsWithChildren } from 'react';\n\nimport type { ColorScheme } from './color-scheme';\n\nconst defaultColorScheme: ColorScheme = {\n accent: '#0F151A',\n accentText: '#EBF2F4',\n background: '#F1F3F5',\n backgroundScroll: 'rgba(241, 243, 245, 0.7)',\n black: '#000000',\n codeAccent: '#CFD2E7',\n credentialHeaderBackground: 'rgba(255, 255, 255, 0.87)',\n error: '#D90D0D',\n grayDark: '#CDD4DA',\n linkText: '#3F7BA6',\n success: '#00D066',\n successText: '#006B34',\n text: '#0D0E10',\n warning: '#F7BF0B',\n white: '#FFFFFF',\n darkMode: false,\n nerdView: {\n background: 'rgba(2, 4, 21, 0.95)',\n attributeLabel: '#929497',\n attributeValueBackground: 'rgba(255, 255, 255, 0.02)',\n attributeValueBorder: 'rgba(255, 255, 255, 0.2)',\n attributeSectionBackground: 'rgba(2, 4, 21, 0.8)',\n button: 'rgba(255, 255, 255, 0.05)',\n codeHighlightText: 'rgba(232, 135, 114, 1)',\n },\n};\n\nconst ColorSchemeContext = React.createContext<ColorScheme>(defaultColorScheme);\nColorSchemeContext.displayName = 'ColorSchemeContext';\n\nexport function ColorSchemeProvider<Scheme extends ColorScheme = ColorScheme>(\n props: PropsWithChildren<{ colorScheme: Scheme }>,\n) {\n return <ColorSchemeContext.Provider value={props.colorScheme}>{props.children}</ColorSchemeContext.Provider>;\n}\n\n/**\n * A hook to gain access to the current `ColorScheme`\n * @note A custom superset of `ColorScheme` can be used (must also be passed to the `ColorSchemeProvider`)\n */\nexport function useAppColorScheme<Scheme extends ColorScheme = ColorScheme>(): Readonly<Scheme> {\n return React.useContext(ColorSchemeContext) as Scheme;\n}\n"],"mappings":";;;;;;;AAAA,IAAAA,MAAA,GAAAC,sBAAA,CAAAC,OAAA;AAAiD,SAAAD,uBAAAE,GAAA,WAAAA,GAAA,IAAAA,GAAA,CAAAC,UAAA,GAAAD,GAAA,KAAAE,OAAA,EAAAF,GAAA;AAIjD,MAAMG,kBAA+B,GAAG;EACtCC,MAAM,EAAE,SAAS;EACjBC,UAAU,EAAE,SAAS;EACrBC,UAAU,EAAE,SAAS;EACrBC,gBAAgB,EAAE,0BAA0B;EAC5CC,KAAK,EAAE,SAAS;EAChBC,UAAU,EAAE,SAAS;EACrBC,0BAA0B,EAAE,2BAA2B;EACvDC,KAAK,EAAE,SAAS;EAChBC,QAAQ,EAAE,SAAS;EACnBC,QAAQ,EAAE,SAAS;EACnBC,OAAO,EAAE,SAAS;EAClBC,WAAW,EAAE,SAAS;EACtBC,IAAI,EAAE,SAAS;EACfC,OAAO,EAAE,SAAS;EAClBC,KAAK,EAAE,SAAS;EAChBC,QAAQ,EAAE,KAAK;EACfC,QAAQ,EAAE;IACRd,UAAU,EAAE,sBAAsB;IAClCe,cAAc,EAAE,SAAS;IACzBC,wBAAwB,EAAE,2BAA2B;IACrDC,oBAAoB,EAAE,0BAA0B;IAChDC,0BAA0B,EAAE,qBAAqB;IACjDC,MAAM,EAAE,2BAA2B;IACnCC,iBAAiB,EAAE;EACrB;AACF,CAAC;AAED,MAAMC,kBAAkB,gBAAGC,cAAK,CAACC,aAAa,CAAc1B,kBAAkB,CAAC;AAC/EwB,kBAAkB,CAACG,WAAW,GAAG,oBAAoB;AAE9C,SAASC,mBAAmBA,CACjCC,KAAiD,EACjD;EACA,oBAAOnC,MAAA,CAAAK,OAAA,CAAA+B,aAAA,CAACN,kBAAkB,CAACO,QAAQ;IAACC,KAAK,EAAEH,KAAK,CAACI;EAAY,GAAEJ,KAAK,CAACK,QAAQ,CAA+B;AAC9G;;AAEA;AACA;AACA;AACA;AACO,SAASC,iBAAiBA,CAAA,EAA+D;EAC9F,OAAOV,cAAK,CAACW,UAAU,CAACZ,kBAAkB,CAAC;AAC7C"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":[],"sources":["color-scheme.ts"],"sourcesContent":["/**\n * Color flavour of the application\n * colors according to figma design: https://www.figma.com/file/52qDYWUMjXAGre1dcnz5bz/Procivis-One-Wallet?node-id=0-1\n */\nexport interface ColorScheme {\n accent: string;\n accentText: string;\n background: string;\n backgroundScroll: string;\n black: string;\n codeAccent: string;\n credentialHeaderBackground: string;\n error: string;\n grayDark: string;\n linkText: string;\n success: string;\n successText: string;\n text: string;\n warning: string;\n white: string;\n darkMode: boolean;\n nerdView: {\n background: string;\n attributeLabel: string;\n attributeSectionBackground: string;\n attributeValueBackground: string;\n attributeValueBorder: string;\n button: string;\n codeHighlightText: string;\n };\n}\n"],"mappings":""}
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
Object.defineProperty(exports, "ColorSchemeProvider", {
|
|
7
|
+
enumerable: true,
|
|
8
|
+
get: function () {
|
|
9
|
+
return _colorSchemeContext.ColorSchemeProvider;
|
|
10
|
+
}
|
|
11
|
+
});
|
|
12
|
+
Object.defineProperty(exports, "useAppColorScheme", {
|
|
13
|
+
enumerable: true,
|
|
14
|
+
get: function () {
|
|
15
|
+
return _colorSchemeContext.useAppColorScheme;
|
|
16
|
+
}
|
|
17
|
+
});
|
|
18
|
+
var _colorSchemeContext = require("./color-scheme-context");
|
|
19
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["_colorSchemeContext","require"],"sources":["index.ts"],"sourcesContent":["export type { ColorScheme } from './color-scheme';\nimport { ColorSchemeProvider, useAppColorScheme } from './color-scheme-context';\n\nexport { ColorSchemeProvider, useAppColorScheme };\n"],"mappings":";;;;;;;;;;;;;;;;;AACA,IAAAA,mBAAA,GAAAC,OAAA"}
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports.getBrightness = exports.colorWithAlphaComponent = exports.colorArray = void 0;
|
|
7
|
+
var _normalizeColor = _interopRequireDefault(require("@react-native/normalize-color"));
|
|
8
|
+
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
9
|
+
/* eslint-disable no-bitwise */
|
|
10
|
+
|
|
11
|
+
const colorArray = color => {
|
|
12
|
+
const normalized = (0, _normalizeColor.default)(color);
|
|
13
|
+
const r = normalized >> 24 & 0xff;
|
|
14
|
+
const g = normalized >> 16 & 0xff;
|
|
15
|
+
const b = normalized >> 8 & 0xff;
|
|
16
|
+
const a = normalized & 0xff;
|
|
17
|
+
return [r / 255, g / 255, b / 255, a / 255];
|
|
18
|
+
};
|
|
19
|
+
exports.colorArray = colorArray;
|
|
20
|
+
const colorWithAlphaComponent = (color, alpha) => {
|
|
21
|
+
alpha = Math.min(1, Math.max(0, alpha));
|
|
22
|
+
const colorValues = colorArray(color);
|
|
23
|
+
colorValues[3] = alpha;
|
|
24
|
+
const colorHexString = colorValues.map(value => Math.round(255 * value).toString(16).padStart(2, '0')).join('');
|
|
25
|
+
return `#${colorHexString}`;
|
|
26
|
+
};
|
|
27
|
+
exports.colorWithAlphaComponent = colorWithAlphaComponent;
|
|
28
|
+
const getBrightness = color => {
|
|
29
|
+
const rgb = colorArray(color);
|
|
30
|
+
// https://en.wikipedia.org/wiki/Relative_luminance
|
|
31
|
+
return 0.2126 * rgb[0] + 0.7152 * rgb[1] + 0.0722 * rgb[2];
|
|
32
|
+
};
|
|
33
|
+
exports.getBrightness = getBrightness;
|
|
34
|
+
//# sourceMappingURL=color.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["_normalizeColor","_interopRequireDefault","require","obj","__esModule","default","colorArray","color","normalized","normalizeColor","r","g","b","a","exports","colorWithAlphaComponent","alpha","Math","min","max","colorValues","colorHexString","map","value","round","toString","padStart","join","getBrightness","rgb"],"sources":["color.ts"],"sourcesContent":["/* eslint-disable no-bitwise */\nimport normalizeColor from '@react-native/normalize-color';\nimport type { ColorValue } from 'react-native';\n\nexport const colorArray = (color: ColorValue) => {\n const normalized = normalizeColor(color);\n\n const r = (normalized >> 24) & 0xff;\n const g = (normalized >> 16) & 0xff;\n const b = (normalized >> 8) & 0xff;\n const a = normalized & 0xff;\n\n return [r / 255, g / 255, b / 255, a / 255];\n};\n\nexport const colorWithAlphaComponent = (color: ColorValue, alpha: number): ColorValue => {\n alpha = Math.min(1, Math.max(0, alpha));\n const colorValues = colorArray(color);\n colorValues[3] = alpha;\n const colorHexString = colorValues\n .map((value) =>\n Math.round(255 * value)\n .toString(16)\n .padStart(2, '0'),\n )\n .join('');\n return `#${colorHexString}`;\n};\n\nexport const getBrightness = (color: ColorValue) => {\n const rgb = colorArray(color);\n // https://en.wikipedia.org/wiki/Relative_luminance\n return 0.2126 * rgb[0] + 0.7152 * rgb[1] + 0.0722 * rgb[2];\n};\n"],"mappings":";;;;;;AACA,IAAAA,eAAA,GAAAC,sBAAA,CAAAC,OAAA;AAA2D,SAAAD,uBAAAE,GAAA,WAAAA,GAAA,IAAAA,GAAA,CAAAC,UAAA,GAAAD,GAAA,KAAAE,OAAA,EAAAF,GAAA;AAD3D;;AAIO,MAAMG,UAAU,GAAIC,KAAiB,IAAK;EAC/C,MAAMC,UAAU,GAAG,IAAAC,uBAAc,EAACF,KAAK,CAAC;EAExC,MAAMG,CAAC,GAAIF,UAAU,IAAI,EAAE,GAAI,IAAI;EACnC,MAAMG,CAAC,GAAIH,UAAU,IAAI,EAAE,GAAI,IAAI;EACnC,MAAMI,CAAC,GAAIJ,UAAU,IAAI,CAAC,GAAI,IAAI;EAClC,MAAMK,CAAC,GAAGL,UAAU,GAAG,IAAI;EAE3B,OAAO,CAACE,CAAC,GAAG,GAAG,EAAEC,CAAC,GAAG,GAAG,EAAEC,CAAC,GAAG,GAAG,EAAEC,CAAC,GAAG,GAAG,CAAC;AAC7C,CAAC;AAACC,OAAA,CAAAR,UAAA,GAAAA,UAAA;AAEK,MAAMS,uBAAuB,GAAGA,CAACR,KAAiB,EAAES,KAAa,KAAiB;EACvFA,KAAK,GAAGC,IAAI,CAACC,GAAG,CAAC,CAAC,EAAED,IAAI,CAACE,GAAG,CAAC,CAAC,EAAEH,KAAK,CAAC,CAAC;EACvC,MAAMI,WAAW,GAAGd,UAAU,CAACC,KAAK,CAAC;EACrCa,WAAW,CAAC,CAAC,CAAC,GAAGJ,KAAK;EACtB,MAAMK,cAAc,GAAGD,WAAW,CAC/BE,GAAG,CAAEC,KAAK,IACTN,IAAI,CAACO,KAAK,CAAC,GAAG,GAAGD,KAAK,CAAC,CACpBE,QAAQ,CAAC,EAAE,CAAC,CACZC,QAAQ,CAAC,CAAC,EAAE,GAAG,CAAC,CACpB,CACAC,IAAI,CAAC,EAAE,CAAC;EACX,OAAQ,IAAGN,cAAe,EAAC;AAC7B,CAAC;AAACP,OAAA,CAAAC,uBAAA,GAAAA,uBAAA;AAEK,MAAMa,aAAa,GAAIrB,KAAiB,IAAK;EAClD,MAAMsB,GAAG,GAAGvB,UAAU,CAACC,KAAK,CAAC;EAC7B;EACA,OAAO,MAAM,GAAGsB,GAAG,CAAC,CAAC,CAAC,GAAG,MAAM,GAAGA,GAAG,CAAC,CAAC,CAAC,GAAG,MAAM,GAAGA,GAAG,CAAC,CAAC,CAAC;AAC5D,CAAC;AAACf,OAAA,CAAAc,aAAA,GAAAA,aAAA"}
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports.default = void 0;
|
|
7
|
+
var _react = _interopRequireWildcard(require("react"));
|
|
8
|
+
var _reactNative = require("react-native");
|
|
9
|
+
var _color = require("./color");
|
|
10
|
+
function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function (nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
|
|
11
|
+
function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || typeof obj !== "object" && typeof obj !== "function") { return { default: obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj.default = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
|
|
12
|
+
function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
|
|
13
|
+
/**
|
|
14
|
+
* Defines transparent status bar with content contrasting to the background
|
|
15
|
+
*/
|
|
16
|
+
const ContrastingStatusBar = _ref => {
|
|
17
|
+
let {
|
|
18
|
+
backgroundColor,
|
|
19
|
+
...props
|
|
20
|
+
} = _ref;
|
|
21
|
+
const barStyle = (0, _react.useMemo)(() => (0, _color.getBrightness)(backgroundColor) > 0.5 ? 'dark-content' : 'light-content', [backgroundColor]);
|
|
22
|
+
return /*#__PURE__*/_react.default.createElement(_reactNative.StatusBar, _extends({
|
|
23
|
+
translucent: true,
|
|
24
|
+
barStyle: barStyle,
|
|
25
|
+
backgroundColor: 'transparent'
|
|
26
|
+
}, props));
|
|
27
|
+
};
|
|
28
|
+
var _default = ContrastingStatusBar;
|
|
29
|
+
exports.default = _default;
|
|
30
|
+
//# sourceMappingURL=contrasting-status-bar.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["_react","_interopRequireWildcard","require","_reactNative","_color","_getRequireWildcardCache","nodeInterop","WeakMap","cacheBabelInterop","cacheNodeInterop","obj","__esModule","default","cache","has","get","newObj","hasPropertyDescriptor","Object","defineProperty","getOwnPropertyDescriptor","key","prototype","hasOwnProperty","call","desc","set","_extends","assign","bind","target","i","arguments","length","source","apply","ContrastingStatusBar","_ref","backgroundColor","props","barStyle","useMemo","getBrightness","createElement","StatusBar","translucent","_default","exports"],"sources":["contrasting-status-bar.tsx"],"sourcesContent":["import React, { FC, useMemo } from 'react';\nimport { ColorValue, StatusBar, StatusBarProps, StatusBarStyle } from 'react-native';\n\nimport { getBrightness } from './color';\n\ninterface ContrastingStatusBarProps extends Omit<StatusBarProps, 'barStyle'> {\n backgroundColor: ColorValue;\n}\n\n/**\n * Defines transparent status bar with content contrasting to the background\n */\nconst ContrastingStatusBar: FC<ContrastingStatusBarProps> = ({ backgroundColor, ...props }) => {\n const barStyle = useMemo<StatusBarStyle>(\n () => (getBrightness(backgroundColor) > 0.5 ? 'dark-content' : 'light-content'),\n [backgroundColor],\n );\n return <StatusBar translucent={true} barStyle={barStyle} backgroundColor={'transparent'} {...props} />;\n};\n\nexport default ContrastingStatusBar;\n"],"mappings":";;;;;;AAAA,IAAAA,MAAA,GAAAC,uBAAA,CAAAC,OAAA;AACA,IAAAC,YAAA,GAAAD,OAAA;AAEA,IAAAE,MAAA,GAAAF,OAAA;AAAwC,SAAAG,yBAAAC,WAAA,eAAAC,OAAA,kCAAAC,iBAAA,OAAAD,OAAA,QAAAE,gBAAA,OAAAF,OAAA,YAAAF,wBAAA,YAAAA,CAAAC,WAAA,WAAAA,WAAA,GAAAG,gBAAA,GAAAD,iBAAA,KAAAF,WAAA;AAAA,SAAAL,wBAAAS,GAAA,EAAAJ,WAAA,SAAAA,WAAA,IAAAI,GAAA,IAAAA,GAAA,CAAAC,UAAA,WAAAD,GAAA,QAAAA,GAAA,oBAAAA,GAAA,wBAAAA,GAAA,4BAAAE,OAAA,EAAAF,GAAA,UAAAG,KAAA,GAAAR,wBAAA,CAAAC,WAAA,OAAAO,KAAA,IAAAA,KAAA,CAAAC,GAAA,CAAAJ,GAAA,YAAAG,KAAA,CAAAE,GAAA,CAAAL,GAAA,SAAAM,MAAA,WAAAC,qBAAA,GAAAC,MAAA,CAAAC,cAAA,IAAAD,MAAA,CAAAE,wBAAA,WAAAC,GAAA,IAAAX,GAAA,QAAAW,GAAA,kBAAAH,MAAA,CAAAI,SAAA,CAAAC,cAAA,CAAAC,IAAA,CAAAd,GAAA,EAAAW,GAAA,SAAAI,IAAA,GAAAR,qBAAA,GAAAC,MAAA,CAAAE,wBAAA,CAAAV,GAAA,EAAAW,GAAA,cAAAI,IAAA,KAAAA,IAAA,CAAAV,GAAA,IAAAU,IAAA,CAAAC,GAAA,KAAAR,MAAA,CAAAC,cAAA,CAAAH,MAAA,EAAAK,GAAA,EAAAI,IAAA,YAAAT,MAAA,CAAAK,GAAA,IAAAX,GAAA,CAAAW,GAAA,SAAAL,MAAA,CAAAJ,OAAA,GAAAF,GAAA,MAAAG,KAAA,IAAAA,KAAA,CAAAa,GAAA,CAAAhB,GAAA,EAAAM,MAAA,YAAAA,MAAA;AAAA,SAAAW,SAAA,IAAAA,QAAA,GAAAT,MAAA,CAAAU,MAAA,GAAAV,MAAA,CAAAU,MAAA,CAAAC,IAAA,eAAAC,MAAA,aAAAC,CAAA,MAAAA,CAAA,GAAAC,SAAA,CAAAC,MAAA,EAAAF,CAAA,UAAAG,MAAA,GAAAF,SAAA,CAAAD,CAAA,YAAAV,GAAA,IAAAa,MAAA,QAAAhB,MAAA,CAAAI,SAAA,CAAAC,cAAA,CAAAC,IAAA,CAAAU,MAAA,EAAAb,GAAA,KAAAS,MAAA,CAAAT,GAAA,IAAAa,MAAA,CAAAb,GAAA,gBAAAS,MAAA,YAAAH,QAAA,CAAAQ,KAAA,OAAAH,SAAA;AAMxC;AACA;AACA;AACA,MAAMI,oBAAmD,GAAGC,IAAA,IAAmC;EAAA,IAAlC;IAAEC,eAAe;IAAE,GAAGC;EAAM,CAAC,GAAAF,IAAA;EACxF,MAAMG,QAAQ,GAAG,IAAAC,cAAO,EACtB,MAAO,IAAAC,oBAAa,EAACJ,eAAe,CAAC,GAAG,GAAG,GAAG,cAAc,GAAG,eAAgB,EAC/E,CAACA,eAAe,CAAC,CAClB;EACD,oBAAOtC,MAAA,CAAAY,OAAA,CAAA+B,aAAA,CAACxC,YAAA,CAAAyC,SAAS,EAAAjB,QAAA;IAACkB,WAAW,EAAE,IAAK;IAACL,QAAQ,EAAEA,QAAS;IAACF,eAAe,EAAE;EAAc,GAAKC,KAAK,EAAI;AACxG,CAAC;AAAC,IAAAO,QAAA,GAEaV,oBAAoB;AAAAW,OAAA,CAAAnC,OAAA,GAAAkC,QAAA"}
|
|
@@ -0,0 +1,57 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports.formatTime = exports.formatDateTime = exports.formatDate = void 0;
|
|
7
|
+
var _reactNative = require("react-native");
|
|
8
|
+
var _NativeModules$I18nMa, _NativeModules$I18nMa2;
|
|
9
|
+
// OS locale
|
|
10
|
+
const systemLocale = (_NativeModules$I18nMa = _reactNative.NativeModules.I18nManager) === null || _NativeModules$I18nMa === void 0 ? void 0 : (_NativeModules$I18nMa2 = _NativeModules$I18nMa.localeIdentifier) === null || _NativeModules$I18nMa2 === void 0 ? void 0 : _NativeModules$I18nMa2.replace(/_/g, '-').split('#')[0].replace(/-$/, '');
|
|
11
|
+
|
|
12
|
+
/**
|
|
13
|
+
* Date only format
|
|
14
|
+
*/
|
|
15
|
+
const formatDate = (date, locale, options) => {
|
|
16
|
+
try {
|
|
17
|
+
return date.toLocaleDateString(locale || systemLocale, options);
|
|
18
|
+
} catch {
|
|
19
|
+
return undefined;
|
|
20
|
+
}
|
|
21
|
+
};
|
|
22
|
+
|
|
23
|
+
/**
|
|
24
|
+
* Time only format
|
|
25
|
+
*/
|
|
26
|
+
exports.formatDate = formatDate;
|
|
27
|
+
const formatTime = (date, locale) => {
|
|
28
|
+
try {
|
|
29
|
+
return date.toLocaleTimeString(locale || systemLocale, {
|
|
30
|
+
hour: '2-digit',
|
|
31
|
+
minute: '2-digit'
|
|
32
|
+
});
|
|
33
|
+
} catch {
|
|
34
|
+
return undefined;
|
|
35
|
+
}
|
|
36
|
+
};
|
|
37
|
+
|
|
38
|
+
/**
|
|
39
|
+
* Date and time format
|
|
40
|
+
*/
|
|
41
|
+
exports.formatTime = formatTime;
|
|
42
|
+
const formatDateTime = (date, locale) => {
|
|
43
|
+
try {
|
|
44
|
+
return date.toLocaleString(locale || systemLocale, {
|
|
45
|
+
hour: '2-digit',
|
|
46
|
+
minute: '2-digit',
|
|
47
|
+
year: 'numeric',
|
|
48
|
+
month: 'numeric',
|
|
49
|
+
day: 'numeric',
|
|
50
|
+
hour12: locale === 'en-US'
|
|
51
|
+
});
|
|
52
|
+
} catch {
|
|
53
|
+
return undefined;
|
|
54
|
+
}
|
|
55
|
+
};
|
|
56
|
+
exports.formatDateTime = formatDateTime;
|
|
57
|
+
//# sourceMappingURL=date.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["_reactNative","require","_NativeModules$I18nMa","_NativeModules$I18nMa2","systemLocale","NativeModules","I18nManager","localeIdentifier","replace","split","formatDate","date","locale","options","toLocaleDateString","undefined","exports","formatTime","toLocaleTimeString","hour","minute","formatDateTime","toLocaleString","year","month","day","hour12"],"sources":["date.ts"],"sourcesContent":["// Date & Time formatted as specified in SW-610\n\nimport { NativeModules } from 'react-native';\n\n// OS locale\nconst systemLocale: string = NativeModules.I18nManager?.localeIdentifier\n ?.replace(/_/g, '-')\n .split('#')[0]\n .replace(/-$/, '');\n\n/**\n * Date only format\n */\nexport const formatDate = (date: Date, locale?: string, options?: Intl.DateTimeFormatOptions) => {\n try {\n return date.toLocaleDateString(locale || systemLocale, options);\n } catch {\n return undefined;\n }\n};\n\n/**\n * Time only format\n */\nexport const formatTime = (date: Date, locale?: string) => {\n try {\n return date.toLocaleTimeString(locale || systemLocale, { hour: '2-digit', minute: '2-digit' });\n } catch {\n return undefined;\n }\n};\n\n/**\n * Date and time format\n */\nexport const formatDateTime = (date: Date, locale?: string) => {\n try {\n return date.toLocaleString(locale || systemLocale, {\n hour: '2-digit',\n minute: '2-digit',\n year: 'numeric',\n month: 'numeric',\n day: 'numeric',\n hour12: locale === 'en-US',\n });\n } catch {\n return undefined;\n }\n};\n"],"mappings":";;;;;;AAEA,IAAAA,YAAA,GAAAC,OAAA;AAA6C,IAAAC,qBAAA,EAAAC,sBAAA;AAE7C;AACA,MAAMC,YAAoB,IAAAF,qBAAA,GAAGG,0BAAa,CAACC,WAAW,cAAAJ,qBAAA,wBAAAC,sBAAA,GAAzBD,qBAAA,CAA2BK,gBAAgB,cAAAJ,sBAAA,uBAA3CA,sBAAA,CACzBK,OAAO,CAAC,IAAI,EAAE,GAAG,CAAC,CACnBC,KAAK,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,CACbD,OAAO,CAAC,IAAI,EAAE,EAAE,CAAC;;AAEpB;AACA;AACA;AACO,MAAME,UAAU,GAAGA,CAACC,IAAU,EAAEC,MAAe,EAAEC,OAAoC,KAAK;EAC/F,IAAI;IACF,OAAOF,IAAI,CAACG,kBAAkB,CAACF,MAAM,IAAIR,YAAY,EAAES,OAAO,CAAC;EACjE,CAAC,CAAC,MAAM;IACN,OAAOE,SAAS;EAClB;AACF,CAAC;;AAED;AACA;AACA;AAFAC,OAAA,CAAAN,UAAA,GAAAA,UAAA;AAGO,MAAMO,UAAU,GAAGA,CAACN,IAAU,EAAEC,MAAe,KAAK;EACzD,IAAI;IACF,OAAOD,IAAI,CAACO,kBAAkB,CAACN,MAAM,IAAIR,YAAY,EAAE;MAAEe,IAAI,EAAE,SAAS;MAAEC,MAAM,EAAE;IAAU,CAAC,CAAC;EAChG,CAAC,CAAC,MAAM;IACN,OAAOL,SAAS;EAClB;AACF,CAAC;;AAED;AACA;AACA;AAFAC,OAAA,CAAAC,UAAA,GAAAA,UAAA;AAGO,MAAMI,cAAc,GAAGA,CAACV,IAAU,EAAEC,MAAe,KAAK;EAC7D,IAAI;IACF,OAAOD,IAAI,CAACW,cAAc,CAACV,MAAM,IAAIR,YAAY,EAAE;MACjDe,IAAI,EAAE,SAAS;MACfC,MAAM,EAAE,SAAS;MACjBG,IAAI,EAAE,SAAS;MACfC,KAAK,EAAE,SAAS;MAChBC,GAAG,EAAE,SAAS;MACdC,MAAM,EAAEd,MAAM,KAAK;IACrB,CAAC,CAAC;EACJ,CAAC,CAAC,MAAM;IACN,OAAOG,SAAS;EAClB;AACF,CAAC;AAACC,OAAA,CAAAK,cAAA,GAAAA,cAAA"}
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports.useOnScrollHeaderState = void 0;
|
|
7
|
+
var _react = require("react");
|
|
8
|
+
const useOnScrollHeaderState = function () {
|
|
9
|
+
let offset = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : 30;
|
|
10
|
+
const [titleVisible, setTitleVisible] = (0, _react.useState)(false);
|
|
11
|
+
const onScroll = (0, _react.useCallback)(event => {
|
|
12
|
+
const scrollOffset = event.nativeEvent.contentOffset.y;
|
|
13
|
+
setTitleVisible(scrollOffset > offset);
|
|
14
|
+
}, [offset]);
|
|
15
|
+
return {
|
|
16
|
+
onScroll,
|
|
17
|
+
titleVisible
|
|
18
|
+
};
|
|
19
|
+
};
|
|
20
|
+
exports.useOnScrollHeaderState = useOnScrollHeaderState;
|
|
21
|
+
//# sourceMappingURL=on-scroll-header-state.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["_react","require","useOnScrollHeaderState","offset","arguments","length","undefined","titleVisible","setTitleVisible","useState","onScroll","useCallback","event","scrollOffset","nativeEvent","contentOffset","y","exports"],"sources":["on-scroll-header-state.tsx"],"sourcesContent":["import { useCallback, useState } from 'react';\nimport { NativeScrollEvent, NativeSyntheticEvent } from 'react-native';\n\nexport const useOnScrollHeaderState = (offset = 30) => {\n const [titleVisible, setTitleVisible] = useState(false);\n\n const onScroll = useCallback(\n (event: NativeSyntheticEvent<NativeScrollEvent>) => {\n const scrollOffset = event.nativeEvent.contentOffset.y;\n setTitleVisible(scrollOffset > offset);\n },\n [offset],\n );\n\n return { onScroll, titleVisible };\n};\n"],"mappings":";;;;;;AAAA,IAAAA,MAAA,GAAAC,OAAA;AAGO,MAAMC,sBAAsB,GAAG,SAAAA,CAAA,EAAiB;EAAA,IAAhBC,MAAM,GAAAC,SAAA,CAAAC,MAAA,QAAAD,SAAA,QAAAE,SAAA,GAAAF,SAAA,MAAG,EAAE;EAChD,MAAM,CAACG,YAAY,EAAEC,eAAe,CAAC,GAAG,IAAAC,eAAQ,EAAC,KAAK,CAAC;EAEvD,MAAMC,QAAQ,GAAG,IAAAC,kBAAW,EACzBC,KAA8C,IAAK;IAClD,MAAMC,YAAY,GAAGD,KAAK,CAACE,WAAW,CAACC,aAAa,CAACC,CAAC;IACtDR,eAAe,CAACK,YAAY,GAAGV,MAAM,CAAC;EACxC,CAAC,EACD,CAACA,MAAM,CAAC,CACT;EAED,OAAO;IAAEO,QAAQ;IAAEH;EAAa,CAAC;AACnC,CAAC;AAACU,OAAA,CAAAf,sBAAA,GAAAA,sBAAA"}
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
Object.defineProperty(exports, "useListContentInset", {
|
|
7
|
+
enumerable: true,
|
|
8
|
+
get: function () {
|
|
9
|
+
return _listContentInset.useListContentInset;
|
|
10
|
+
}
|
|
11
|
+
});
|
|
12
|
+
Object.defineProperty(exports, "useOnScrollHeaderState", {
|
|
13
|
+
enumerable: true,
|
|
14
|
+
get: function () {
|
|
15
|
+
return _onScrollHeaderState.useOnScrollHeaderState;
|
|
16
|
+
}
|
|
17
|
+
});
|
|
18
|
+
var _onScrollHeaderState = require("./header/on-scroll-header-state");
|
|
19
|
+
var _listContentInset = require("./list/list-content-inset");
|
|
20
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["_onScrollHeaderState","require","_listContentInset"],"sources":["index.ts"],"sourcesContent":["import { useOnScrollHeaderState } from './header/on-scroll-header-state';\nimport { useListContentInset } from './list/list-content-inset';\n\nexport { useOnScrollHeaderState };\nexport { useListContentInset };\n"],"mappings":";;;;;;;;;;;;;;;;;AAAA,IAAAA,oBAAA,GAAAC,OAAA;AACA,IAAAC,iBAAA,GAAAD,OAAA"}
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports.useListContentInset = void 0;
|
|
7
|
+
var _reactNative = require("react-native");
|
|
8
|
+
var _reactNativeSafeAreaContext = require("react-native-safe-area-context");
|
|
9
|
+
const useListContentInset = function () {
|
|
10
|
+
let {
|
|
11
|
+
additionalBottomPadding = 54,
|
|
12
|
+
headerHeight = 48,
|
|
13
|
+
modalPresentation = false
|
|
14
|
+
} = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {
|
|
15
|
+
additionalBottomPadding: 54,
|
|
16
|
+
headerHeight: 48,
|
|
17
|
+
modalPresentation: false
|
|
18
|
+
};
|
|
19
|
+
const {
|
|
20
|
+
top,
|
|
21
|
+
bottom
|
|
22
|
+
} = (0, _reactNativeSafeAreaContext.useSafeAreaInsets)();
|
|
23
|
+
const topSafeAreaInset = !modalPresentation || _reactNative.Platform.OS === 'android' ? top : 0;
|
|
24
|
+
const contentInsetsStyle = {
|
|
25
|
+
paddingBottom: bottom + additionalBottomPadding,
|
|
26
|
+
paddingTop: topSafeAreaInset + headerHeight
|
|
27
|
+
};
|
|
28
|
+
return contentInsetsStyle;
|
|
29
|
+
};
|
|
30
|
+
exports.useListContentInset = useListContentInset;
|
|
31
|
+
//# sourceMappingURL=list-content-inset.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["_reactNative","require","_reactNativeSafeAreaContext","useListContentInset","additionalBottomPadding","headerHeight","modalPresentation","arguments","length","undefined","top","bottom","useSafeAreaInsets","topSafeAreaInset","Platform","OS","contentInsetsStyle","paddingBottom","paddingTop","exports"],"sources":["list-content-inset.ts"],"sourcesContent":["import { Platform, ViewStyle } from 'react-native';\nimport { useSafeAreaInsets } from 'react-native-safe-area-context';\n\ntype ListContentInsetProps = {\n additionalBottomPadding?: number;\n headerHeight?: number;\n modalPresentation?: boolean;\n};\n\nexport const useListContentInset = (\n { additionalBottomPadding = 54, headerHeight = 48, modalPresentation = false }: ListContentInsetProps = {\n additionalBottomPadding: 54,\n headerHeight: 48,\n modalPresentation: false,\n },\n) => {\n const { top, bottom } = useSafeAreaInsets();\n const topSafeAreaInset = !modalPresentation || Platform.OS === 'android' ? top : 0;\n const contentInsetsStyle: ViewStyle = {\n paddingBottom: bottom + additionalBottomPadding,\n paddingTop: topSafeAreaInset + headerHeight,\n };\n return contentInsetsStyle;\n};\n"],"mappings":";;;;;;AAAA,IAAAA,YAAA,GAAAC,OAAA;AACA,IAAAC,2BAAA,GAAAD,OAAA;AAQO,MAAME,mBAAmB,GAAG,SAAAA,CAAA,EAM9B;EAAA,IALH;IAAEC,uBAAuB,GAAG,EAAE;IAAEC,YAAY,GAAG,EAAE;IAAEC,iBAAiB,GAAG;EAA6B,CAAC,GAAAC,SAAA,CAAAC,MAAA,QAAAD,SAAA,QAAAE,SAAA,GAAAF,SAAA,MAAG;IACtGH,uBAAuB,EAAE,EAAE;IAC3BC,YAAY,EAAE,EAAE;IAChBC,iBAAiB,EAAE;EACrB,CAAC;EAED,MAAM;IAAEI,GAAG;IAAEC;EAAO,CAAC,GAAG,IAAAC,6CAAiB,GAAE;EAC3C,MAAMC,gBAAgB,GAAG,CAACP,iBAAiB,IAAIQ,qBAAQ,CAACC,EAAE,KAAK,SAAS,GAAGL,GAAG,GAAG,CAAC;EAClF,MAAMM,kBAA6B,GAAG;IACpCC,aAAa,EAAEN,MAAM,GAAGP,uBAAuB;IAC/Cc,UAAU,EAAEL,gBAAgB,GAAGR;EACjC,CAAC;EACD,OAAOW,kBAAkB;AAC3B,CAAC;AAACG,OAAA,CAAAhB,mBAAA,GAAAA,mBAAA"}
|
|
@@ -0,0 +1,83 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
var _exportNames = {
|
|
7
|
+
ContrastingStatusBar: true,
|
|
8
|
+
formatDate: true,
|
|
9
|
+
formatDateTime: true,
|
|
10
|
+
formatTime: true,
|
|
11
|
+
useBlockOSBackNavigation: true,
|
|
12
|
+
useForwardedRef: true,
|
|
13
|
+
concatTestID: true,
|
|
14
|
+
useMemoAsync: true
|
|
15
|
+
};
|
|
16
|
+
Object.defineProperty(exports, "ContrastingStatusBar", {
|
|
17
|
+
enumerable: true,
|
|
18
|
+
get: function () {
|
|
19
|
+
return _contrastingStatusBar.default;
|
|
20
|
+
}
|
|
21
|
+
});
|
|
22
|
+
Object.defineProperty(exports, "concatTestID", {
|
|
23
|
+
enumerable: true,
|
|
24
|
+
get: function () {
|
|
25
|
+
return _testID.concatTestID;
|
|
26
|
+
}
|
|
27
|
+
});
|
|
28
|
+
Object.defineProperty(exports, "formatDate", {
|
|
29
|
+
enumerable: true,
|
|
30
|
+
get: function () {
|
|
31
|
+
return _date.formatDate;
|
|
32
|
+
}
|
|
33
|
+
});
|
|
34
|
+
Object.defineProperty(exports, "formatDateTime", {
|
|
35
|
+
enumerable: true,
|
|
36
|
+
get: function () {
|
|
37
|
+
return _date.formatDateTime;
|
|
38
|
+
}
|
|
39
|
+
});
|
|
40
|
+
Object.defineProperty(exports, "formatTime", {
|
|
41
|
+
enumerable: true,
|
|
42
|
+
get: function () {
|
|
43
|
+
return _date.formatTime;
|
|
44
|
+
}
|
|
45
|
+
});
|
|
46
|
+
Object.defineProperty(exports, "useBlockOSBackNavigation", {
|
|
47
|
+
enumerable: true,
|
|
48
|
+
get: function () {
|
|
49
|
+
return _navigation.useBlockOSBackNavigation;
|
|
50
|
+
}
|
|
51
|
+
});
|
|
52
|
+
Object.defineProperty(exports, "useForwardedRef", {
|
|
53
|
+
enumerable: true,
|
|
54
|
+
get: function () {
|
|
55
|
+
return _ref.useForwardedRef;
|
|
56
|
+
}
|
|
57
|
+
});
|
|
58
|
+
Object.defineProperty(exports, "useMemoAsync", {
|
|
59
|
+
enumerable: true,
|
|
60
|
+
get: function () {
|
|
61
|
+
return _useMemoAsync.useMemoAsync;
|
|
62
|
+
}
|
|
63
|
+
});
|
|
64
|
+
var _contrastingStatusBar = _interopRequireDefault(require("./contrasting-status-bar"));
|
|
65
|
+
var _date = require("./date");
|
|
66
|
+
var _navigation = require("./navigation");
|
|
67
|
+
var _ref = require("./ref");
|
|
68
|
+
var _testID = require("./testID");
|
|
69
|
+
var _useMemoAsync = require("./useMemoAsync");
|
|
70
|
+
var _hooks = require("./hooks");
|
|
71
|
+
Object.keys(_hooks).forEach(function (key) {
|
|
72
|
+
if (key === "default" || key === "__esModule") return;
|
|
73
|
+
if (Object.prototype.hasOwnProperty.call(_exportNames, key)) return;
|
|
74
|
+
if (key in exports && exports[key] === _hooks[key]) return;
|
|
75
|
+
Object.defineProperty(exports, key, {
|
|
76
|
+
enumerable: true,
|
|
77
|
+
get: function () {
|
|
78
|
+
return _hooks[key];
|
|
79
|
+
}
|
|
80
|
+
});
|
|
81
|
+
});
|
|
82
|
+
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
83
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["_contrastingStatusBar","_interopRequireDefault","require","_date","_navigation","_ref","_testID","_useMemoAsync","_hooks","Object","keys","forEach","key","prototype","hasOwnProperty","call","_exportNames","exports","defineProperty","enumerable","get","obj","__esModule","default"],"sources":["index.ts"],"sourcesContent":["import ContrastingStatusBar from './contrasting-status-bar';\nimport { formatDate, formatDateTime, formatTime } from './date';\nimport { useBlockOSBackNavigation } from './navigation';\nimport { useForwardedRef } from './ref';\nimport { concatTestID } from './testID';\nimport { useMemoAsync } from './useMemoAsync';\n\nexport {\n concatTestID,\n ContrastingStatusBar,\n formatDate,\n formatDateTime,\n formatTime,\n useBlockOSBackNavigation,\n useForwardedRef,\n useMemoAsync,\n};\n\nexport * from './hooks';\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,IAAAA,qBAAA,GAAAC,sBAAA,CAAAC,OAAA;AACA,IAAAC,KAAA,GAAAD,OAAA;AACA,IAAAE,WAAA,GAAAF,OAAA;AACA,IAAAG,IAAA,GAAAH,OAAA;AACA,IAAAI,OAAA,GAAAJ,OAAA;AACA,IAAAK,aAAA,GAAAL,OAAA;AAaA,IAAAM,MAAA,GAAAN,OAAA;AAAAO,MAAA,CAAAC,IAAA,CAAAF,MAAA,EAAAG,OAAA,WAAAC,GAAA;EAAA,IAAAA,GAAA,kBAAAA,GAAA;EAAA,IAAAH,MAAA,CAAAI,SAAA,CAAAC,cAAA,CAAAC,IAAA,CAAAC,YAAA,EAAAJ,GAAA;EAAA,IAAAA,GAAA,IAAAK,OAAA,IAAAA,OAAA,CAAAL,GAAA,MAAAJ,MAAA,CAAAI,GAAA;EAAAH,MAAA,CAAAS,cAAA,CAAAD,OAAA,EAAAL,GAAA;IAAAO,UAAA;IAAAC,GAAA,WAAAA,CAAA;MAAA,OAAAZ,MAAA,CAAAI,GAAA;IAAA;EAAA;AAAA;AAAwB,SAAAX,uBAAAoB,GAAA,WAAAA,GAAA,IAAAA,GAAA,CAAAC,UAAA,GAAAD,GAAA,KAAAE,OAAA,EAAAF,GAAA"}
|
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports.useBlockOSBackNavigation = void 0;
|
|
7
|
+
var _native = require("@react-navigation/native");
|
|
8
|
+
var _react = require("react");
|
|
9
|
+
var _reactNative = require("react-native");
|
|
10
|
+
/**
|
|
11
|
+
* Prevent OS back navigation
|
|
12
|
+
* * iOS: block back swipe gesture
|
|
13
|
+
* * Android: block back button from system task bar
|
|
14
|
+
* @param block Whether to prevent the default behavior (default: true)
|
|
15
|
+
* @param onAndroidBack (Android only) Custom callback triggered when OS back button is pressed while blocked
|
|
16
|
+
* * return `false` to allow back navigation, return `true` to block back navigation
|
|
17
|
+
*/
|
|
18
|
+
const useBlockOSBackNavigation = function () {
|
|
19
|
+
let block = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : true;
|
|
20
|
+
let onAndroidBack = arguments.length > 1 ? arguments[1] : undefined;
|
|
21
|
+
const navigation = (0, _native.useNavigation)();
|
|
22
|
+
const isFocused = (0, _native.useIsFocused)();
|
|
23
|
+
|
|
24
|
+
// iOS: block back swipe (via screen options)
|
|
25
|
+
(0, _react.useEffect)(() => {
|
|
26
|
+
if (block) {
|
|
27
|
+
navigation.setOptions({
|
|
28
|
+
gestureEnabled: false
|
|
29
|
+
});
|
|
30
|
+
return () => navigation.setOptions({
|
|
31
|
+
gestureEnabled: true
|
|
32
|
+
});
|
|
33
|
+
}
|
|
34
|
+
return undefined;
|
|
35
|
+
}, [block, navigation]);
|
|
36
|
+
|
|
37
|
+
// Anroid: block system back button
|
|
38
|
+
(0, _react.useEffect)(() => {
|
|
39
|
+
if (block && isFocused) {
|
|
40
|
+
const handler = () => {
|
|
41
|
+
var _onAndroidBack;
|
|
42
|
+
return (_onAndroidBack = onAndroidBack === null || onAndroidBack === void 0 ? void 0 : onAndroidBack()) !== null && _onAndroidBack !== void 0 ? _onAndroidBack : true;
|
|
43
|
+
};
|
|
44
|
+
_reactNative.BackHandler.addEventListener('hardwareBackPress', handler);
|
|
45
|
+
return () => _reactNative.BackHandler.removeEventListener('hardwareBackPress', handler);
|
|
46
|
+
}
|
|
47
|
+
return undefined;
|
|
48
|
+
}, [block, isFocused, onAndroidBack]);
|
|
49
|
+
};
|
|
50
|
+
exports.useBlockOSBackNavigation = useBlockOSBackNavigation;
|
|
51
|
+
//# sourceMappingURL=navigation.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["_native","require","_react","_reactNative","useBlockOSBackNavigation","block","arguments","length","undefined","onAndroidBack","navigation","useNavigation","isFocused","useIsFocused","useEffect","setOptions","gestureEnabled","handler","_onAndroidBack","BackHandler","addEventListener","removeEventListener","exports"],"sources":["navigation.ts"],"sourcesContent":["import { NavigationProp, useIsFocused, useNavigation } from '@react-navigation/native';\nimport { useEffect } from 'react';\nimport { BackHandler } from 'react-native';\n\n/**\n * Prevent OS back navigation\n * * iOS: block back swipe gesture\n * * Android: block back button from system task bar\n * @param block Whether to prevent the default behavior (default: true)\n * @param onAndroidBack (Android only) Custom callback triggered when OS back button is pressed while blocked\n * * return `false` to allow back navigation, return `true` to block back navigation\n */\nexport const useBlockOSBackNavigation = (block: boolean = true, onAndroidBack?: () => boolean) => {\n const navigation = useNavigation<NavigationProp<{}>>();\n const isFocused = useIsFocused();\n\n // iOS: block back swipe (via screen options)\n useEffect(() => {\n if (block) {\n navigation.setOptions({ gestureEnabled: false });\n return () => navigation.setOptions({ gestureEnabled: true });\n }\n return undefined;\n }, [block, navigation]);\n\n // Anroid: block system back button\n useEffect(() => {\n if (block && isFocused) {\n const handler = () => {\n return onAndroidBack?.() ?? true;\n };\n BackHandler.addEventListener('hardwareBackPress', handler);\n return () => BackHandler.removeEventListener('hardwareBackPress', handler);\n }\n return undefined;\n }, [block, isFocused, onAndroidBack]);\n};\n"],"mappings":";;;;;;AAAA,IAAAA,OAAA,GAAAC,OAAA;AACA,IAAAC,MAAA,GAAAD,OAAA;AACA,IAAAE,YAAA,GAAAF,OAAA;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACO,MAAMG,wBAAwB,GAAG,SAAAA,CAAA,EAA0D;EAAA,IAAzDC,KAAc,GAAAC,SAAA,CAAAC,MAAA,QAAAD,SAAA,QAAAE,SAAA,GAAAF,SAAA,MAAG,IAAI;EAAA,IAAEG,aAA6B,GAAAH,SAAA,CAAAC,MAAA,OAAAD,SAAA,MAAAE,SAAA;EAC3F,MAAME,UAAU,GAAG,IAAAC,qBAAa,GAAsB;EACtD,MAAMC,SAAS,GAAG,IAAAC,oBAAY,GAAE;;EAEhC;EACA,IAAAC,gBAAS,EAAC,MAAM;IACd,IAAIT,KAAK,EAAE;MACTK,UAAU,CAACK,UAAU,CAAC;QAAEC,cAAc,EAAE;MAAM,CAAC,CAAC;MAChD,OAAO,MAAMN,UAAU,CAACK,UAAU,CAAC;QAAEC,cAAc,EAAE;MAAK,CAAC,CAAC;IAC9D;IACA,OAAOR,SAAS;EAClB,CAAC,EAAE,CAACH,KAAK,EAAEK,UAAU,CAAC,CAAC;;EAEvB;EACA,IAAAI,gBAAS,EAAC,MAAM;IACd,IAAIT,KAAK,IAAIO,SAAS,EAAE;MACtB,MAAMK,OAAO,GAAGA,CAAA,KAAM;QAAA,IAAAC,cAAA;QACpB,QAAAA,cAAA,GAAOT,aAAa,aAAbA,aAAa,uBAAbA,aAAa,EAAI,cAAAS,cAAA,cAAAA,cAAA,GAAI,IAAI;MAClC,CAAC;MACDC,wBAAW,CAACC,gBAAgB,CAAC,mBAAmB,EAAEH,OAAO,CAAC;MAC1D,OAAO,MAAME,wBAAW,CAACE,mBAAmB,CAAC,mBAAmB,EAAEJ,OAAO,CAAC;IAC5E;IACA,OAAOT,SAAS;EAClB,CAAC,EAAE,CAACH,KAAK,EAAEO,SAAS,EAAEH,aAAa,CAAC,CAAC;AACvC,CAAC;AAACa,OAAA,CAAAlB,wBAAA,GAAAA,wBAAA"}
|
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports.useForwardedRef = void 0;
|
|
7
|
+
var _react = require("react");
|
|
8
|
+
const isWritable = (obj, key) => {
|
|
9
|
+
const desc = Object.getOwnPropertyDescriptor(obj, key) || Object.getOwnPropertyDescriptor(Object.getPrototypeOf(obj), key) || {};
|
|
10
|
+
return Boolean(desc.writable);
|
|
11
|
+
};
|
|
12
|
+
|
|
13
|
+
/**
|
|
14
|
+
* Transforms a forwarded ref to a locally usable reference object
|
|
15
|
+
* @example
|
|
16
|
+
* const Component = forwardRef<RefComponent, Props>((props, ref) => {
|
|
17
|
+
* const [forwardedRef, refObject] = useForwardedRef(ref);
|
|
18
|
+
* const onAction = useCallback(() => doSomething(refObject.current), [refObject]);
|
|
19
|
+
* return <RefComponent ref={forwardedRef} {...props} />;
|
|
20
|
+
* }
|
|
21
|
+
*/
|
|
22
|
+
const useForwardedRef = passedRef => {
|
|
23
|
+
const localRef = (0, _react.useRef)(null);
|
|
24
|
+
return (0, _react.useMemo)(() => {
|
|
25
|
+
const ref = localRef;
|
|
26
|
+
const forwardedRef = instance => {
|
|
27
|
+
ref.current = instance;
|
|
28
|
+
if (passedRef) {
|
|
29
|
+
if (passedRef instanceof Function) {
|
|
30
|
+
passedRef(instance);
|
|
31
|
+
} else if (isWritable(passedRef, 'current')) {
|
|
32
|
+
try {
|
|
33
|
+
passedRef.current = instance;
|
|
34
|
+
} catch (e) {}
|
|
35
|
+
}
|
|
36
|
+
}
|
|
37
|
+
};
|
|
38
|
+
return [forwardedRef, ref];
|
|
39
|
+
}, [passedRef]);
|
|
40
|
+
};
|
|
41
|
+
exports.useForwardedRef = useForwardedRef;
|
|
42
|
+
//# sourceMappingURL=ref.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["_react","require","isWritable","obj","key","desc","Object","getOwnPropertyDescriptor","getPrototypeOf","Boolean","writable","useForwardedRef","passedRef","localRef","useRef","useMemo","ref","forwardedRef","instance","current","Function","e","exports"],"sources":["ref.ts"],"sourcesContent":["import React, { useMemo, useRef } from 'react';\n\nconst isWritable = <T extends Object>(obj: T, key: keyof T) => {\n const desc =\n Object.getOwnPropertyDescriptor(obj, key) || Object.getOwnPropertyDescriptor(Object.getPrototypeOf(obj), key) || {};\n return Boolean(desc.writable);\n};\n\n/**\n * Transforms a forwarded ref to a locally usable reference object\n * @example\n * const Component = forwardRef<RefComponent, Props>((props, ref) => {\n * const [forwardedRef, refObject] = useForwardedRef(ref);\n * const onAction = useCallback(() => doSomething(refObject.current), [refObject]);\n * return <RefComponent ref={forwardedRef} {...props} />;\n * }\n */\nexport const useForwardedRef = <Component extends React.Component<any> | React.ComponentClass<any>>(\n passedRef?: React.Ref<Component>,\n) => {\n const localRef = useRef<Component>(null);\n return useMemo<[React.Ref<Component>, React.RefObject<Component>]>(() => {\n const ref: React.MutableRefObject<Component | null> = localRef;\n const forwardedRef: React.Ref<Component> = (instance: Component | null) => {\n ref.current = instance;\n if (passedRef) {\n if (passedRef instanceof Function) {\n passedRef(instance);\n } else if (isWritable(passedRef, 'current')) {\n try {\n (passedRef as any).current = instance;\n } catch (e) {}\n }\n }\n };\n\n return [forwardedRef, ref as React.RefObject<Component>];\n }, [passedRef]);\n};\n"],"mappings":";;;;;;AAAA,IAAAA,MAAA,GAAAC,OAAA;AAEA,MAAMC,UAAU,GAAGA,CAAmBC,GAAM,EAAEC,GAAY,KAAK;EAC7D,MAAMC,IAAI,GACRC,MAAM,CAACC,wBAAwB,CAACJ,GAAG,EAAEC,GAAG,CAAC,IAAIE,MAAM,CAACC,wBAAwB,CAACD,MAAM,CAACE,cAAc,CAACL,GAAG,CAAC,EAAEC,GAAG,CAAC,IAAI,CAAC,CAAC;EACrH,OAAOK,OAAO,CAACJ,IAAI,CAACK,QAAQ,CAAC;AAC/B,CAAC;;AAED;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACO,MAAMC,eAAe,GAC1BC,SAAgC,IAC7B;EACH,MAAMC,QAAQ,GAAG,IAAAC,aAAM,EAAY,IAAI,CAAC;EACxC,OAAO,IAAAC,cAAO,EAAqD,MAAM;IACvE,MAAMC,GAA6C,GAAGH,QAAQ;IAC9D,MAAMI,YAAkC,GAAIC,QAA0B,IAAK;MACzEF,GAAG,CAACG,OAAO,GAAGD,QAAQ;MACtB,IAAIN,SAAS,EAAE;QACb,IAAIA,SAAS,YAAYQ,QAAQ,EAAE;UACjCR,SAAS,CAACM,QAAQ,CAAC;QACrB,CAAC,MAAM,IAAIhB,UAAU,CAACU,SAAS,EAAE,SAAS,CAAC,EAAE;UAC3C,IAAI;YACDA,SAAS,CAASO,OAAO,GAAGD,QAAQ;UACvC,CAAC,CAAC,OAAOG,CAAC,EAAE,CAAC;QACf;MACF;IACF,CAAC;IAED,OAAO,CAACJ,YAAY,EAAED,GAAG,CAA+B;EAC1D,CAAC,EAAE,CAACJ,SAAS,CAAC,CAAC;AACjB,CAAC;AAACU,OAAA,CAAAX,eAAA,GAAAA,eAAA"}
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports.concatTestID = concatTestID;
|
|
7
|
+
/**
|
|
8
|
+
* Create `testID` prop by concatenating parts
|
|
9
|
+
* @returns {string} concatenated identifier or undefined if one part is missing
|
|
10
|
+
*/
|
|
11
|
+
|
|
12
|
+
function concatTestID(part1) {
|
|
13
|
+
for (var _len = arguments.length, args = new Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) {
|
|
14
|
+
args[_key - 1] = arguments[_key];
|
|
15
|
+
}
|
|
16
|
+
return args.reduce((aggr, part) => aggr && part ? `${aggr}.${part}` : undefined, part1 || undefined);
|
|
17
|
+
}
|
|
18
|
+
//# sourceMappingURL=testID.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["concatTestID","part1","_len","arguments","length","args","Array","_key","reduce","aggr","part","undefined"],"sources":["testID.ts"],"sourcesContent":["/**\n * Create `testID` prop by concatenating parts\n * @returns {string} concatenated identifier or undefined if one part is missing\n */\nexport function concatTestID(part1: string, ...args: Array<string>): string;\nexport function concatTestID(part1: string | undefined, ...args: Array<string | undefined>): string | undefined;\nexport function concatTestID(part1: string | undefined, ...args: Array<string | undefined>): string | undefined {\n return args.reduce((aggr, part) => (aggr && part ? `${aggr}.${part}` : undefined), part1 || undefined);\n}\n"],"mappings":";;;;;;AAAA;AACA;AACA;AACA;;AAGO,SAASA,YAAYA,CAACC,KAAyB,EAA0D;EAAA,SAAAC,IAAA,GAAAC,SAAA,CAAAC,MAAA,EAArDC,IAAI,OAAAC,KAAA,CAAAJ,IAAA,OAAAA,IAAA,WAAAK,IAAA,MAAAA,IAAA,GAAAL,IAAA,EAAAK,IAAA;IAAJF,IAAI,CAAAE,IAAA,QAAAJ,SAAA,CAAAI,IAAA;EAAA;EAC7D,OAAOF,IAAI,CAACG,MAAM,CAAC,CAACC,IAAI,EAAEC,IAAI,KAAMD,IAAI,IAAIC,IAAI,GAAI,GAAED,IAAK,IAAGC,IAAK,EAAC,GAAGC,SAAU,EAAEV,KAAK,IAAIU,SAAS,CAAC;AACxG"}
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
var _testID = require("./testID");
|
|
4
|
+
describe('concatTestID', () => {
|
|
5
|
+
it('concatenates testID parts', () => {
|
|
6
|
+
expect((0, _testID.concatTestID)('A')).toBe('A');
|
|
7
|
+
expect((0, _testID.concatTestID)('A', 'B')).toBe('A.B');
|
|
8
|
+
expect((0, _testID.concatTestID)('A', 'B', 'C')).toBe('A.B.C');
|
|
9
|
+
});
|
|
10
|
+
it('recognizes missing parts', () => {
|
|
11
|
+
expect((0, _testID.concatTestID)('')).toBe(undefined);
|
|
12
|
+
expect((0, _testID.concatTestID)(undefined)).toBe(undefined);
|
|
13
|
+
expect((0, _testID.concatTestID)('', 'something')).toBe(undefined);
|
|
14
|
+
expect((0, _testID.concatTestID)(undefined, 'something')).toBe(undefined);
|
|
15
|
+
expect((0, _testID.concatTestID)('something', '')).toBe(undefined);
|
|
16
|
+
expect((0, _testID.concatTestID)('something', undefined)).toBe(undefined);
|
|
17
|
+
expect((0, _testID.concatTestID)('something', '', 'somethingElse')).toBe(undefined);
|
|
18
|
+
expect((0, _testID.concatTestID)('something', undefined, 'somethingElse')).toBe(undefined);
|
|
19
|
+
});
|
|
20
|
+
});
|
|
21
|
+
//# sourceMappingURL=testID.test.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["_testID","require","describe","it","expect","concatTestID","toBe","undefined"],"sources":["testID.test.ts"],"sourcesContent":["import { concatTestID } from './testID';\n\ndescribe('concatTestID', () => {\n it('concatenates testID parts', () => {\n expect(concatTestID('A')).toBe('A');\n expect(concatTestID('A', 'B')).toBe('A.B');\n expect(concatTestID('A', 'B', 'C')).toBe('A.B.C');\n });\n\n it('recognizes missing parts', () => {\n expect(concatTestID('')).toBe(undefined);\n expect(concatTestID(undefined)).toBe(undefined);\n expect(concatTestID('', 'something')).toBe(undefined);\n expect(concatTestID(undefined, 'something')).toBe(undefined);\n expect(concatTestID('something', '')).toBe(undefined);\n expect(concatTestID('something', undefined)).toBe(undefined);\n expect(concatTestID('something', '', 'somethingElse')).toBe(undefined);\n expect(concatTestID('something', undefined, 'somethingElse')).toBe(undefined);\n });\n});\n"],"mappings":";;AAAA,IAAAA,OAAA,GAAAC,OAAA;AAEAC,QAAQ,CAAC,cAAc,EAAE,MAAM;EAC7BC,EAAE,CAAC,2BAA2B,EAAE,MAAM;IACpCC,MAAM,CAAC,IAAAC,oBAAY,EAAC,GAAG,CAAC,CAAC,CAACC,IAAI,CAAC,GAAG,CAAC;IACnCF,MAAM,CAAC,IAAAC,oBAAY,EAAC,GAAG,EAAE,GAAG,CAAC,CAAC,CAACC,IAAI,CAAC,KAAK,CAAC;IAC1CF,MAAM,CAAC,IAAAC,oBAAY,EAAC,GAAG,EAAE,GAAG,EAAE,GAAG,CAAC,CAAC,CAACC,IAAI,CAAC,OAAO,CAAC;EACnD,CAAC,CAAC;EAEFH,EAAE,CAAC,0BAA0B,EAAE,MAAM;IACnCC,MAAM,CAAC,IAAAC,oBAAY,EAAC,EAAE,CAAC,CAAC,CAACC,IAAI,CAACC,SAAS,CAAC;IACxCH,MAAM,CAAC,IAAAC,oBAAY,EAACE,SAAS,CAAC,CAAC,CAACD,IAAI,CAACC,SAAS,CAAC;IAC/CH,MAAM,CAAC,IAAAC,oBAAY,EAAC,EAAE,EAAE,WAAW,CAAC,CAAC,CAACC,IAAI,CAACC,SAAS,CAAC;IACrDH,MAAM,CAAC,IAAAC,oBAAY,EAACE,SAAS,EAAE,WAAW,CAAC,CAAC,CAACD,IAAI,CAACC,SAAS,CAAC;IAC5DH,MAAM,CAAC,IAAAC,oBAAY,EAAC,WAAW,EAAE,EAAE,CAAC,CAAC,CAACC,IAAI,CAACC,SAAS,CAAC;IACrDH,MAAM,CAAC,IAAAC,oBAAY,EAAC,WAAW,EAAEE,SAAS,CAAC,CAAC,CAACD,IAAI,CAACC,SAAS,CAAC;IAC5DH,MAAM,CAAC,IAAAC,oBAAY,EAAC,WAAW,EAAE,EAAE,EAAE,eAAe,CAAC,CAAC,CAACC,IAAI,CAACC,SAAS,CAAC;IACtEH,MAAM,CAAC,IAAAC,oBAAY,EAAC,WAAW,EAAEE,SAAS,EAAE,eAAe,CAAC,CAAC,CAACD,IAAI,CAACC,SAAS,CAAC;EAC/E,CAAC,CAAC;AACJ,CAAC,CAAC"}
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports.useMemoAsync = useMemoAsync;
|
|
7
|
+
var _react = require("react");
|
|
8
|
+
function useMemoAsync(factory, deps, initialValue, fallbackValue) {
|
|
9
|
+
const [value, setValue] = (0, _react.useState)(initialValue);
|
|
10
|
+
(0, _react.useEffect)(() => {
|
|
11
|
+
const abortCtrl = new AbortController();
|
|
12
|
+
const update = async () => {
|
|
13
|
+
try {
|
|
14
|
+
const result = await factory(abortCtrl.signal);
|
|
15
|
+
if (!abortCtrl.signal.aborted) setValue(result);
|
|
16
|
+
} catch (e) {
|
|
17
|
+
if (!abortCtrl.signal.aborted) setValue(fallbackValue !== null && fallbackValue !== void 0 ? fallbackValue : initialValue);
|
|
18
|
+
}
|
|
19
|
+
};
|
|
20
|
+
update();
|
|
21
|
+
return () => abortCtrl.abort();
|
|
22
|
+
// eslint-disable-next-line react-hooks/exhaustive-deps
|
|
23
|
+
}, deps);
|
|
24
|
+
return value;
|
|
25
|
+
}
|
|
26
|
+
//# sourceMappingURL=useMemoAsync.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["_react","require","useMemoAsync","factory","deps","initialValue","fallbackValue","value","setValue","useState","useEffect","abortCtrl","AbortController","update","result","signal","aborted","e","abort"],"sources":["useMemoAsync.ts"],"sourcesContent":["import { DependencyList, useEffect, useState } from 'react';\n\ninterface FactoryFn<Value> {\n /**\n * Custom factory function\n * @param abortSignal Signaled when the deps change and the factory function need to be called again or when the parent component unmounts\n * @returns Result to be returned from the {@link useMemoAsync}\n */\n (abortSignal: AbortSignal): Value | Promise<Value>;\n}\n\n/**\n * Utility hook that can be used the same way as `useMemo` when the initializer needs to be async\n * @param factory Factory function to produce a value\n * @param deps Hook dependency list (to trigger an update)\n * @param initialValue Initial value before factory finishes producing a value (default = `undefined`)\n * @param fallbackValue Used when factory fails to produce a value (default = `initialValue`)\n * @returns Result from the {@link factory}, {@link initialValue} or {@link fallbackValue}\n */\nexport function useMemoAsync<Value, FallbackValue = Value | undefined>(\n factory: FactoryFn<Value>,\n deps: DependencyList,\n initialValue: FallbackValue,\n fallbackValue?: FallbackValue,\n): Value | FallbackValue;\nexport function useMemoAsync<Value>(factory: FactoryFn<Value>, deps: DependencyList): Value | undefined;\n\nexport function useMemoAsync<Value, FallbackValue = Value | undefined>(\n factory: FactoryFn<Value>,\n deps: DependencyList,\n initialValue?: FallbackValue,\n fallbackValue?: FallbackValue,\n): Value | FallbackValue | undefined {\n const [value, setValue] = useState<Value | FallbackValue | undefined>(initialValue);\n useEffect(() => {\n const abortCtrl = new AbortController();\n const update = async () => {\n try {\n const result = await factory(abortCtrl.signal);\n if (!abortCtrl.signal.aborted) setValue(result);\n } catch (e) {\n if (!abortCtrl.signal.aborted) setValue(fallbackValue ?? initialValue);\n }\n };\n update();\n return () => abortCtrl.abort();\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, deps);\n return value;\n}\n"],"mappings":";;;;;;AAAA,IAAAA,MAAA,GAAAC,OAAA;AA2BO,SAASC,YAAYA,CAC1BC,OAAyB,EACzBC,IAAoB,EACpBC,YAA4B,EAC5BC,aAA6B,EACM;EACnC,MAAM,CAACC,KAAK,EAAEC,QAAQ,CAAC,GAAG,IAAAC,eAAQ,EAAoCJ,YAAY,CAAC;EACnF,IAAAK,gBAAS,EAAC,MAAM;IACd,MAAMC,SAAS,GAAG,IAAIC,eAAe,EAAE;IACvC,MAAMC,MAAM,GAAG,MAAAA,CAAA,KAAY;MACzB,IAAI;QACF,MAAMC,MAAM,GAAG,MAAMX,OAAO,CAACQ,SAAS,CAACI,MAAM,CAAC;QAC9C,IAAI,CAACJ,SAAS,CAACI,MAAM,CAACC,OAAO,EAAER,QAAQ,CAACM,MAAM,CAAC;MACjD,CAAC,CAAC,OAAOG,CAAC,EAAE;QACV,IAAI,CAACN,SAAS,CAACI,MAAM,CAACC,OAAO,EAAER,QAAQ,CAACF,aAAa,aAAbA,aAAa,cAAbA,aAAa,GAAID,YAAY,CAAC;MACxE;IACF,CAAC;IACDQ,MAAM,EAAE;IACR,OAAO,MAAMF,SAAS,CAACO,KAAK,EAAE;IAC9B;EACF,CAAC,EAAEd,IAAI,CAAC;EACR,OAAOG,KAAK;AACd"}
|