@buoy-gg/shared-ui 7.0.39 → 7.0.41
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 +6 -0
- package/lib/commonjs/JsModal.js +13 -61
- package/lib/commonjs/JsModal.web.js +32 -95
- package/lib/commonjs/clipboard/autoDetectClipboard.js +1 -1
- package/lib/commonjs/clipboard/clipboard-impl.web.js +21 -0
- package/lib/commonjs/dataViewer/tree/TreeDiffViewer.js +4 -2
- package/lib/commonjs/hooks/index.js +1 -1
- package/lib/commonjs/hooks/safe-area-impl.js +1 -1
- package/lib/commonjs/hooks/usePersistedState.js +1 -1
- package/lib/commonjs/hooks/useSafeAreaInsets.web.js +41 -0
- package/lib/commonjs/icons/index.js +14 -0
- package/lib/commonjs/index.js +34 -0
- package/lib/commonjs/license/AccountSetup.js +4 -25
- package/lib/commonjs/license/AccountSetup.web.js +78 -64
- package/lib/commonjs/license/AccountSetupContent.js +482 -0
- package/lib/commonjs/license/FreeAccountPrompt.js +32 -178
- package/lib/commonjs/license/LicenseEntryModal.js +5 -12
- package/lib/commonjs/license/accountRuntime.js +8 -0
- package/lib/commonjs/license/accountRuntime.web.js +9 -0
- package/lib/commonjs/license/licenseModule.js +2 -0
- package/lib/commonjs/settings/components/BubbleSettingsSection.js +1 -1
- package/lib/commonjs/storage/definePersistedSetting.js +1 -1
- package/lib/commonjs/stores/ignoredPatternsCore.js +8 -1
- package/lib/commonjs/stores/ignoredPatternsStore.js +10 -199
- package/lib/commonjs/stores/ignoredPatternsStore.shared.js +205 -0
- package/lib/commonjs/stores/ignoredPatternsStore.web.js +10 -230
- package/lib/commonjs/ui/backgrounds/backgroundStore.js +1 -1
- package/lib/commonjs/ui/backgrounds/variants/wormhole.js +3 -0
- package/lib/commonjs/ui/components/CopyButton.js +1 -1
- package/lib/commonjs/ui/components/EventStepperFooter.js +1 -1
- package/lib/commonjs/ui/components/ToolFooter.js +1 -1
- package/lib/commonjs/ui/floating/FloatingTool.web.js +12 -2
- package/lib/commonjs/ui/night/primitives.js +10 -3
- package/lib/commonjs/ui/otto/OttoSprite.js +1 -1
- package/lib/commonjs/utils/browserAsyncStorage.js +157 -0
- package/lib/commonjs/utils/browserNavigation.js +116 -0
- package/lib/commonjs/utils/devServer.js +8 -4
- package/lib/commonjs/utils/devServer.web.js +10 -0
- package/lib/commonjs/utils/domRuntime.js +143 -0
- package/lib/commonjs/utils/expoRouterModule.js +51 -0
- package/lib/commonjs/utils/expoRouterModule.web.js +14 -0
- package/lib/commonjs/utils/getSafeAreaInsets.web.js +35 -0
- package/lib/commonjs/utils/index.js +111 -4
- package/lib/commonjs/utils/loadToolModule.js +46 -0
- package/lib/commonjs/utils/loadToolModule.web.js +12 -0
- package/lib/commonjs/utils/modalStorage.js +42 -0
- package/lib/commonjs/utils/nativeWeb.js +454 -0
- package/lib/commonjs/utils/persistentStorage.web.js +78 -0
- package/lib/commonjs/utils/reloadApp.js +18 -57
- package/lib/commonjs/utils/reloadPlatform.js +37 -0
- package/lib/commonjs/utils/reloadPlatform.web.js +17 -0
- package/lib/commonjs/utils/safeExpoRouter.js +3 -53
- package/lib/commonjs/utils/safeExpoRouter.web.js +48 -0
- package/lib/commonjs/utils/toolModules.js +25 -0
- package/lib/module/JsModal.js +11 -59
- package/lib/module/JsModal.web.js +28 -91
- package/lib/module/clipboard/autoDetectClipboard.js +2 -2
- package/lib/module/clipboard/clipboard-impl.web.js +14 -0
- package/lib/module/dataViewer/tree/TreeDiffViewer.js +4 -2
- package/lib/module/hooks/index.js +2 -2
- package/lib/module/hooks/safe-area-impl.js +1 -1
- package/lib/module/hooks/usePersistedState.js +1 -1
- package/lib/module/hooks/useSafeAreaInsets.web.js +30 -0
- package/lib/module/icons/index.js +2 -1
- package/lib/module/index.js +3 -0
- package/lib/module/license/AccountSetup.js +5 -26
- package/lib/module/license/AccountSetup.web.js +79 -65
- package/lib/module/license/AccountSetupContent.js +476 -0
- package/lib/module/license/FreeAccountPrompt.js +27 -176
- package/lib/module/license/LicenseEntryModal.js +6 -13
- package/lib/module/license/accountRuntime.js +3 -0
- package/lib/module/license/accountRuntime.web.js +4 -0
- package/lib/module/license/licenseModule.js +2 -0
- package/lib/module/settings/components/BubbleSettingsSection.js +1 -1
- package/lib/module/storage/definePersistedSetting.js +1 -1
- package/lib/module/stores/ignoredPatternsCore.js +8 -1
- package/lib/module/stores/ignoredPatternsStore.js +1 -187
- package/lib/module/stores/ignoredPatternsStore.shared.js +189 -0
- package/lib/module/stores/ignoredPatternsStore.web.js +1 -219
- package/lib/module/ui/backgrounds/backgroundStore.js +1 -1
- package/lib/module/ui/backgrounds/variants/wormhole.js +3 -0
- package/lib/module/ui/components/CopyButton.js +1 -1
- package/lib/module/ui/components/EventStepperFooter.js +1 -1
- package/lib/module/ui/components/ToolFooter.js +1 -1
- package/lib/module/ui/floating/FloatingTool.web.js +12 -2
- package/lib/module/ui/night/primitives.js +11 -4
- package/lib/module/ui/otto/OttoSprite.js +1 -1
- package/lib/module/utils/browserAsyncStorage.js +151 -0
- package/lib/module/utils/browserNavigation.js +108 -0
- package/lib/module/utils/devServer.js +8 -4
- package/lib/module/utils/devServer.web.js +6 -0
- package/lib/module/utils/domRuntime.js +134 -0
- package/lib/module/utils/expoRouterModule.js +46 -0
- package/lib/module/utils/expoRouterModule.web.js +9 -0
- package/lib/module/utils/getSafeAreaInsets.web.js +31 -0
- package/lib/module/utils/index.js +9 -4
- package/lib/module/utils/loadToolModule.js +42 -0
- package/lib/module/utils/loadToolModule.web.js +8 -0
- package/lib/module/utils/modalStorage.js +37 -0
- package/lib/module/utils/nativeWeb.js +107 -0
- package/lib/module/utils/persistentStorage.web.js +72 -0
- package/lib/module/utils/reloadApp.js +13 -51
- package/lib/module/utils/reloadPlatform.js +31 -0
- package/lib/module/utils/reloadPlatform.web.js +11 -0
- package/lib/module/utils/safeExpoRouter.js +3 -53
- package/lib/module/utils/safeExpoRouter.web.js +37 -0
- package/lib/module/utils/toolModules.js +19 -0
- package/lib/typescript/commonjs/JsModal.d.ts.map +1 -1
- package/lib/typescript/commonjs/JsModal.web.d.ts +7 -18
- package/lib/typescript/commonjs/JsModal.web.d.ts.map +1 -1
- package/lib/typescript/commonjs/clipboard/clipboard-impl.web.d.ts +5 -0
- package/lib/typescript/commonjs/clipboard/clipboard-impl.web.d.ts.map +1 -0
- package/lib/typescript/commonjs/dataViewer/tree/TreeDiffViewer.d.ts.map +1 -1
- package/lib/typescript/commonjs/hooks/safe-area-impl.d.ts +1 -1
- package/lib/typescript/commonjs/hooks/useSafeAreaInsets.web.d.ts +6 -0
- package/lib/typescript/commonjs/hooks/useSafeAreaInsets.web.d.ts.map +1 -0
- package/lib/typescript/commonjs/icons/index.d.ts +1 -0
- package/lib/typescript/commonjs/icons/index.d.ts.map +1 -1
- package/lib/typescript/commonjs/index.d.ts +2 -0
- package/lib/typescript/commonjs/index.d.ts.map +1 -1
- package/lib/typescript/commonjs/license/AccountSetup.d.ts.map +1 -1
- package/lib/typescript/commonjs/license/AccountSetup.web.d.ts +1 -1
- package/lib/typescript/commonjs/license/AccountSetup.web.d.ts.map +1 -1
- package/lib/typescript/commonjs/license/AccountSetupContent.d.ts +11 -0
- package/lib/typescript/commonjs/license/AccountSetupContent.d.ts.map +1 -0
- package/lib/typescript/commonjs/license/FreeAccountPrompt.d.ts +3 -15
- package/lib/typescript/commonjs/license/FreeAccountPrompt.d.ts.map +1 -1
- package/lib/typescript/commonjs/license/LicenseEntryModal.d.ts.map +1 -1
- package/lib/typescript/commonjs/license/accountRuntime.d.ts +2 -0
- package/lib/typescript/commonjs/license/accountRuntime.d.ts.map +1 -0
- package/lib/typescript/commonjs/license/accountRuntime.web.d.ts +2 -0
- package/lib/typescript/commonjs/license/accountRuntime.web.d.ts.map +1 -0
- package/lib/typescript/commonjs/license/licenseModule.d.ts +3 -1
- package/lib/typescript/commonjs/license/licenseModule.d.ts.map +1 -1
- package/lib/typescript/commonjs/stores/ignoredPatternsCore.d.ts +5 -1
- package/lib/typescript/commonjs/stores/ignoredPatternsCore.d.ts.map +1 -1
- package/lib/typescript/commonjs/stores/ignoredPatternsStore.d.ts +1 -59
- package/lib/typescript/commonjs/stores/ignoredPatternsStore.d.ts.map +1 -1
- package/lib/typescript/commonjs/stores/ignoredPatternsStore.shared.d.ts +60 -0
- package/lib/typescript/commonjs/stores/ignoredPatternsStore.shared.d.ts.map +1 -0
- package/lib/typescript/commonjs/stores/ignoredPatternsStore.web.d.ts +1 -71
- package/lib/typescript/commonjs/stores/ignoredPatternsStore.web.d.ts.map +1 -1
- package/lib/typescript/commonjs/ui/floating/FloatingTool.web.d.ts.map +1 -1
- package/lib/typescript/commonjs/ui/night/primitives.d.ts.map +1 -1
- package/lib/typescript/commonjs/ui/otto/ottoEngine.d.ts +1 -1
- package/lib/typescript/commonjs/utils/browserAsyncStorage.d.ts +25 -0
- package/lib/typescript/commonjs/utils/browserAsyncStorage.d.ts.map +1 -0
- package/lib/typescript/commonjs/utils/browserNavigation.d.ts +31 -0
- package/lib/typescript/commonjs/utils/browserNavigation.d.ts.map +1 -0
- package/lib/typescript/commonjs/utils/devServer.d.ts.map +1 -1
- package/lib/typescript/commonjs/utils/devServer.web.d.ts +2 -0
- package/lib/typescript/commonjs/utils/devServer.web.d.ts.map +1 -0
- package/lib/typescript/commonjs/utils/domRuntime.d.ts +27 -0
- package/lib/typescript/commonjs/utils/domRuntime.d.ts.map +1 -0
- package/lib/typescript/commonjs/utils/expoRouterModule.d.ts +3 -0
- package/lib/typescript/commonjs/utils/expoRouterModule.d.ts.map +1 -0
- package/lib/typescript/commonjs/utils/expoRouterModule.web.d.ts +3 -0
- package/lib/typescript/commonjs/utils/expoRouterModule.web.d.ts.map +1 -0
- package/lib/typescript/commonjs/utils/getSafeAreaInsets.web.d.ts +8 -0
- package/lib/typescript/commonjs/utils/getSafeAreaInsets.web.d.ts.map +1 -0
- package/lib/typescript/commonjs/utils/index.d.ts +5 -0
- package/lib/typescript/commonjs/utils/index.d.ts.map +1 -1
- package/lib/typescript/commonjs/utils/loadToolModule.d.ts +3 -0
- package/lib/typescript/commonjs/utils/loadToolModule.d.ts.map +1 -0
- package/lib/typescript/commonjs/utils/loadToolModule.web.d.ts +2 -0
- package/lib/typescript/commonjs/utils/loadToolModule.web.d.ts.map +1 -0
- package/lib/typescript/commonjs/utils/modalStorage.d.ts +21 -0
- package/lib/typescript/commonjs/utils/modalStorage.d.ts.map +1 -0
- package/lib/typescript/commonjs/utils/nativeWeb.d.ts +22 -0
- package/lib/typescript/commonjs/utils/nativeWeb.d.ts.map +1 -0
- package/lib/typescript/commonjs/utils/persistentStorage.web.d.ts +6 -0
- package/lib/typescript/commonjs/utils/persistentStorage.web.d.ts.map +1 -0
- package/lib/typescript/commonjs/utils/reloadApp.d.ts +7 -25
- package/lib/typescript/commonjs/utils/reloadApp.d.ts.map +1 -1
- package/lib/typescript/commonjs/utils/reloadPlatform.d.ts +8 -0
- package/lib/typescript/commonjs/utils/reloadPlatform.d.ts.map +1 -0
- package/lib/typescript/commonjs/utils/reloadPlatform.web.d.ts +4 -0
- package/lib/typescript/commonjs/utils/reloadPlatform.web.d.ts.map +1 -0
- package/lib/typescript/commonjs/utils/safeExpoRouter.d.ts.map +1 -1
- package/lib/typescript/commonjs/utils/safeExpoRouter.web.d.ts +43 -0
- package/lib/typescript/commonjs/utils/safeExpoRouter.web.d.ts.map +1 -0
- package/lib/typescript/commonjs/utils/toolModules.d.ts +5 -0
- package/lib/typescript/commonjs/utils/toolModules.d.ts.map +1 -0
- package/lib/typescript/module/JsModal.d.ts.map +1 -1
- package/lib/typescript/module/JsModal.web.d.ts +7 -18
- package/lib/typescript/module/JsModal.web.d.ts.map +1 -1
- package/lib/typescript/module/clipboard/clipboard-impl.web.d.ts +5 -0
- package/lib/typescript/module/clipboard/clipboard-impl.web.d.ts.map +1 -0
- package/lib/typescript/module/dataViewer/tree/TreeDiffViewer.d.ts.map +1 -1
- package/lib/typescript/module/hooks/safe-area-impl.d.ts +1 -1
- package/lib/typescript/module/hooks/useSafeAreaInsets.web.d.ts +6 -0
- package/lib/typescript/module/hooks/useSafeAreaInsets.web.d.ts.map +1 -0
- package/lib/typescript/module/icons/index.d.ts +1 -0
- package/lib/typescript/module/icons/index.d.ts.map +1 -1
- package/lib/typescript/module/index.d.ts +2 -0
- package/lib/typescript/module/index.d.ts.map +1 -1
- package/lib/typescript/module/license/AccountSetup.d.ts.map +1 -1
- package/lib/typescript/module/license/AccountSetup.web.d.ts +1 -1
- package/lib/typescript/module/license/AccountSetup.web.d.ts.map +1 -1
- package/lib/typescript/module/license/AccountSetupContent.d.ts +11 -0
- package/lib/typescript/module/license/AccountSetupContent.d.ts.map +1 -0
- package/lib/typescript/module/license/FreeAccountPrompt.d.ts +3 -15
- package/lib/typescript/module/license/FreeAccountPrompt.d.ts.map +1 -1
- package/lib/typescript/module/license/LicenseEntryModal.d.ts.map +1 -1
- package/lib/typescript/module/license/accountRuntime.d.ts +2 -0
- package/lib/typescript/module/license/accountRuntime.d.ts.map +1 -0
- package/lib/typescript/module/license/accountRuntime.web.d.ts +2 -0
- package/lib/typescript/module/license/accountRuntime.web.d.ts.map +1 -0
- package/lib/typescript/module/license/licenseModule.d.ts +3 -1
- package/lib/typescript/module/license/licenseModule.d.ts.map +1 -1
- package/lib/typescript/module/stores/ignoredPatternsCore.d.ts +5 -1
- package/lib/typescript/module/stores/ignoredPatternsCore.d.ts.map +1 -1
- package/lib/typescript/module/stores/ignoredPatternsStore.d.ts +1 -59
- package/lib/typescript/module/stores/ignoredPatternsStore.d.ts.map +1 -1
- package/lib/typescript/module/stores/ignoredPatternsStore.shared.d.ts +60 -0
- package/lib/typescript/module/stores/ignoredPatternsStore.shared.d.ts.map +1 -0
- package/lib/typescript/module/stores/ignoredPatternsStore.web.d.ts +1 -71
- package/lib/typescript/module/stores/ignoredPatternsStore.web.d.ts.map +1 -1
- package/lib/typescript/module/ui/floating/FloatingTool.web.d.ts.map +1 -1
- package/lib/typescript/module/ui/night/primitives.d.ts.map +1 -1
- package/lib/typescript/module/ui/otto/ottoEngine.d.ts +1 -1
- package/lib/typescript/module/utils/browserAsyncStorage.d.ts +25 -0
- package/lib/typescript/module/utils/browserAsyncStorage.d.ts.map +1 -0
- package/lib/typescript/module/utils/browserNavigation.d.ts +31 -0
- package/lib/typescript/module/utils/browserNavigation.d.ts.map +1 -0
- package/lib/typescript/module/utils/devServer.d.ts.map +1 -1
- package/lib/typescript/module/utils/devServer.web.d.ts +2 -0
- package/lib/typescript/module/utils/devServer.web.d.ts.map +1 -0
- package/lib/typescript/module/utils/domRuntime.d.ts +27 -0
- package/lib/typescript/module/utils/domRuntime.d.ts.map +1 -0
- package/lib/typescript/module/utils/expoRouterModule.d.ts +3 -0
- package/lib/typescript/module/utils/expoRouterModule.d.ts.map +1 -0
- package/lib/typescript/module/utils/expoRouterModule.web.d.ts +3 -0
- package/lib/typescript/module/utils/expoRouterModule.web.d.ts.map +1 -0
- package/lib/typescript/module/utils/getSafeAreaInsets.web.d.ts +8 -0
- package/lib/typescript/module/utils/getSafeAreaInsets.web.d.ts.map +1 -0
- package/lib/typescript/module/utils/index.d.ts +5 -0
- package/lib/typescript/module/utils/index.d.ts.map +1 -1
- package/lib/typescript/module/utils/loadToolModule.d.ts +3 -0
- package/lib/typescript/module/utils/loadToolModule.d.ts.map +1 -0
- package/lib/typescript/module/utils/loadToolModule.web.d.ts +2 -0
- package/lib/typescript/module/utils/loadToolModule.web.d.ts.map +1 -0
- package/lib/typescript/module/utils/modalStorage.d.ts +21 -0
- package/lib/typescript/module/utils/modalStorage.d.ts.map +1 -0
- package/lib/typescript/module/utils/nativeWeb.d.ts +22 -0
- package/lib/typescript/module/utils/nativeWeb.d.ts.map +1 -0
- package/lib/typescript/module/utils/persistentStorage.web.d.ts +6 -0
- package/lib/typescript/module/utils/persistentStorage.web.d.ts.map +1 -0
- package/lib/typescript/module/utils/reloadApp.d.ts +7 -25
- package/lib/typescript/module/utils/reloadApp.d.ts.map +1 -1
- package/lib/typescript/module/utils/reloadPlatform.d.ts +8 -0
- package/lib/typescript/module/utils/reloadPlatform.d.ts.map +1 -0
- package/lib/typescript/module/utils/reloadPlatform.web.d.ts +4 -0
- package/lib/typescript/module/utils/reloadPlatform.web.d.ts.map +1 -0
- package/lib/typescript/module/utils/safeExpoRouter.d.ts.map +1 -1
- package/lib/typescript/module/utils/safeExpoRouter.web.d.ts +43 -0
- package/lib/typescript/module/utils/safeExpoRouter.web.d.ts.map +1 -0
- package/lib/typescript/module/utils/toolModules.d.ts +5 -0
- package/lib/typescript/module/utils/toolModules.d.ts.map +1 -0
- package/lib/web/asyncStorage.mjs +2 -0
- package/lib/web/chunks/chunk-2MHKRRQW.mjs +8 -0
- package/lib/web/chunks/chunk-2Q3SDPH2.mjs +14 -0
- package/lib/web/chunks/chunk-34YQ42KI.mjs +2 -0
- package/lib/web/chunks/chunk-3NNNCQYP.mjs +14 -0
- package/lib/web/chunks/chunk-3UTMGIUG.mjs +2 -0
- package/lib/web/chunks/chunk-46CXXOQB.mjs +2 -0
- package/lib/web/chunks/chunk-475BSDCB.mjs +2 -0
- package/lib/web/chunks/chunk-53J2FMUD.mjs +2 -0
- package/lib/web/chunks/chunk-552W4COI.mjs +2 -0
- package/lib/web/chunks/chunk-56TTTMX4.mjs +6145 -0
- package/lib/web/chunks/chunk-5LOQZINQ.mjs +14 -0
- package/lib/web/chunks/chunk-5NOIO6ZM.mjs +16 -0
- package/lib/web/chunks/chunk-5NZOQR6Q.mjs +2 -0
- package/lib/web/chunks/chunk-6CCRCSA2.mjs +2 -0
- package/lib/web/chunks/chunk-6Q52HRBL.mjs +2 -0
- package/lib/web/chunks/chunk-6TEDFSNM.mjs +655 -0
- package/lib/web/chunks/chunk-7BMRSMHN.mjs +2 -0
- package/lib/web/chunks/chunk-A2SOFE47.mjs +24 -0
- package/lib/web/chunks/chunk-A7KJCK4R.mjs +14 -0
- package/lib/web/chunks/chunk-AEXGGXS7.mjs +2 -0
- package/lib/web/chunks/chunk-AGD7ZT6O.mjs +15 -0
- package/lib/web/chunks/chunk-AIEOQWNG.mjs +2 -0
- package/lib/web/chunks/chunk-ASTM35HG.mjs +16 -0
- package/lib/web/chunks/chunk-AZBMFPMX.mjs +1421 -0
- package/lib/web/chunks/chunk-B2V2UDCU.mjs +16 -0
- package/lib/web/chunks/chunk-BFGKGTAC.mjs +2 -0
- package/lib/web/chunks/chunk-BHW6AFO6.mjs +2 -0
- package/lib/web/chunks/chunk-BWRW3NJ2.mjs +16 -0
- package/lib/web/chunks/chunk-CBM2IZAK.mjs +2 -0
- package/lib/web/chunks/chunk-CDLCFF44.mjs +2 -0
- package/lib/web/chunks/chunk-CE5U3CSQ.mjs +2 -0
- package/lib/web/chunks/chunk-CI5CO7FQ.mjs +2 -0
- package/lib/web/chunks/chunk-CIB4U2YK.mjs +2 -0
- package/lib/web/chunks/chunk-CLLTZQGD.mjs +596 -0
- package/lib/web/chunks/chunk-D5HQLRFW.mjs +655 -0
- package/lib/web/chunks/chunk-DZDTNXXK.mjs +2 -0
- package/lib/web/chunks/chunk-FDOZ6YSS.mjs +2 -0
- package/lib/web/chunks/chunk-FMEWNGQO.mjs +2 -0
- package/lib/web/chunks/chunk-G4DH7GMT.mjs +2 -0
- package/lib/web/chunks/chunk-GBUZCZE4.mjs +2 -0
- package/lib/web/chunks/chunk-GF5C5DVX.mjs +2 -0
- package/lib/web/chunks/chunk-GLMS5ZLJ.mjs +445 -0
- package/lib/web/chunks/chunk-GNGMIA7V.mjs +2 -0
- package/lib/web/chunks/chunk-GTYIS7H7.mjs +15 -0
- package/lib/web/chunks/chunk-HJ36IONA.mjs +15 -0
- package/lib/web/chunks/chunk-HXPTZMAZ.mjs +2 -0
- package/lib/web/chunks/chunk-I27M4JCS.mjs +2 -0
- package/lib/web/chunks/chunk-IVCT27JB.mjs +2 -0
- package/lib/web/chunks/chunk-JG4QSK5B.mjs +2 -0
- package/lib/web/chunks/chunk-JR7BJW6B.mjs +389 -0
- package/lib/web/chunks/chunk-K46ZJUXJ.mjs +90 -0
- package/lib/web/chunks/chunk-K4LXMO4D.mjs +2 -0
- package/lib/web/chunks/chunk-K7CGIEFU.mjs +2 -0
- package/lib/web/chunks/chunk-KBTYK5YE.mjs +662 -0
- package/lib/web/chunks/chunk-KHP6CSSM.mjs +2 -0
- package/lib/web/chunks/chunk-KRDRIW7T.mjs +14 -0
- package/lib/web/chunks/chunk-L2DTKDER.mjs +2 -0
- package/lib/web/chunks/chunk-LFDFDGHY.mjs +655 -0
- package/lib/web/chunks/chunk-LZ7FZZ7R.mjs +2 -0
- package/lib/web/chunks/chunk-MAIUUK4E.mjs +2 -0
- package/lib/web/chunks/chunk-MKJKS3IG.mjs +275 -0
- package/lib/web/chunks/chunk-MRQKVLXG.mjs +2 -0
- package/lib/web/chunks/chunk-NK3OISOL.mjs +14 -0
- package/lib/web/chunks/chunk-NLJDDIXW.mjs +2 -0
- package/lib/web/chunks/chunk-OENR3XFI.mjs +11 -0
- package/lib/web/chunks/chunk-OZB3VKZE.mjs +2 -0
- package/lib/web/chunks/chunk-P64PFJT3.mjs +17618 -0
- package/lib/web/chunks/chunk-PACPGYH7.mjs +2 -0
- package/lib/web/chunks/chunk-PART6HOE.mjs +14 -0
- package/lib/web/chunks/chunk-PMRXUQRH.mjs +2 -0
- package/lib/web/chunks/chunk-PTK5FO6C.mjs +2 -0
- package/lib/web/chunks/chunk-PZ45TQ55.mjs +14 -0
- package/lib/web/chunks/chunk-Q5LN7GET.mjs +17624 -0
- package/lib/web/chunks/chunk-QCD6T6L4.mjs +297 -0
- package/lib/web/chunks/chunk-QD5EUANU.mjs +2 -0
- package/lib/web/chunks/chunk-QJTECJCO.mjs +2 -0
- package/lib/web/chunks/chunk-QPIZURPZ.mjs +2 -0
- package/lib/web/chunks/chunk-QPY45R5F.mjs +274 -0
- package/lib/web/chunks/chunk-R2SGZIG5.mjs +2 -0
- package/lib/web/chunks/chunk-S3GYQYVJ.mjs +16 -0
- package/lib/web/chunks/chunk-SCCXVTDM.mjs +2 -0
- package/lib/web/chunks/chunk-SHJHD646.mjs +2 -0
- package/lib/web/chunks/chunk-TCRVZ55E.mjs +2 -0
- package/lib/web/chunks/chunk-TJ6ZVV2L.mjs +15 -0
- package/lib/web/chunks/chunk-TPSY4RC3.mjs +14 -0
- package/lib/web/chunks/chunk-U5KNX5O6.mjs +17624 -0
- package/lib/web/chunks/chunk-UCKELQSM.mjs +2 -0
- package/lib/web/chunks/chunk-UGGCYHRH.mjs +15 -0
- package/lib/web/chunks/chunk-UNYQJZET.mjs +16 -0
- package/lib/web/chunks/chunk-VE72SWLV.mjs +15 -0
- package/lib/web/chunks/chunk-VKONO6MI.mjs +2 -0
- package/lib/web/chunks/chunk-W4BGMPJO.mjs +2 -0
- package/lib/web/chunks/chunk-WHNEEKLR.mjs +2 -0
- package/lib/web/chunks/chunk-WLGUP3KY.mjs +16 -0
- package/lib/web/chunks/chunk-WY7D4WBZ.mjs +2 -0
- package/lib/web/chunks/chunk-XRNB2MHO.mjs +107 -0
- package/lib/web/chunks/chunk-XXTIAXQY.mjs +2 -0
- package/lib/web/chunks/chunk-XYUAUO57.mjs +2 -0
- package/lib/web/chunks/chunk-YG6DIKQD.mjs +2 -0
- package/lib/web/chunks/chunk-YIZFMU66.mjs +2 -0
- package/lib/web/chunks/chunk-YOGAPOGC.mjs +2 -0
- package/lib/web/chunks/chunk-Z7373DS5.mjs +2 -0
- package/lib/web/chunks/chunk-Z76GRN66.mjs +17627 -0
- package/lib/web/chunks/persistentStorage.web-4FBAOYJ4.mjs +12 -0
- package/lib/web/chunks/persistentStorage.web-7W3Y6Q24.mjs +12 -0
- package/lib/web/chunks/persistentStorage.web-GOWNFMVT.mjs +2 -0
- package/lib/web/chunks/persistentStorage.web-RF47FXIK.mjs +12 -0
- package/lib/web/colors.mjs +2 -0
- package/lib/web/dataViewer.mjs +3 -0
- package/lib/web/floating.mjs +2 -0
- package/lib/web/history.mjs +2 -0
- package/lib/web/hooks.mjs +2 -0
- package/lib/web/index.mjs +15 -0
- package/lib/web/native.mjs +2 -0
- package/lib/web/ui.mjs +2 -0
- package/lib/web/utils.mjs +2 -0
- package/package.json +118 -36
|
@@ -0,0 +1,157 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports.default = void 0;
|
|
7
|
+
exports.getBrowserStorage = getBrowserStorage;
|
|
8
|
+
exports.subscribeToBrowserStorage = subscribeToBrowserStorage;
|
|
9
|
+
const listeners = new Set();
|
|
10
|
+
let detach;
|
|
11
|
+
function getBrowserStorage(area = 'localStorage') {
|
|
12
|
+
if (typeof window === 'undefined') throw new Error('Browser storage is unavailable during server rendering.');
|
|
13
|
+
return window[area];
|
|
14
|
+
}
|
|
15
|
+
function entries(storage) {
|
|
16
|
+
return Array.from({
|
|
17
|
+
length: storage.length
|
|
18
|
+
}, (_, index) => storage.key(index)).filter(key => key !== null).map(key => [key, storage.getItem(key)]);
|
|
19
|
+
}
|
|
20
|
+
function emit(change) {
|
|
21
|
+
for (const listener of [...listeners]) {
|
|
22
|
+
try {
|
|
23
|
+
listener(change);
|
|
24
|
+
} catch {/* Observers cannot change storage behavior. */}
|
|
25
|
+
}
|
|
26
|
+
}
|
|
27
|
+
function attach() {
|
|
28
|
+
if (typeof window === 'undefined' || typeof Storage === 'undefined') return;
|
|
29
|
+
const proto = Storage.prototype;
|
|
30
|
+
const set = proto.setItem;
|
|
31
|
+
const remove = proto.removeItem;
|
|
32
|
+
const clear = proto.clear;
|
|
33
|
+
const areaOf = storage => {
|
|
34
|
+
for (const area of ['localStorage', 'sessionStorage']) {
|
|
35
|
+
try {
|
|
36
|
+
if (storage === window[area]) return area;
|
|
37
|
+
} catch {/* Storage may be blocked. */}
|
|
38
|
+
}
|
|
39
|
+
return undefined;
|
|
40
|
+
};
|
|
41
|
+
const wrappedSet = function (key, value) {
|
|
42
|
+
const area = areaOf(this);
|
|
43
|
+
const name = String(key);
|
|
44
|
+
const text = String(value);
|
|
45
|
+
const prevValue = area ? this.getItem(name) : null;
|
|
46
|
+
Reflect.apply(set, this, [name, text]);
|
|
47
|
+
if (area) emit({
|
|
48
|
+
area,
|
|
49
|
+
action: 'setItem',
|
|
50
|
+
key: name,
|
|
51
|
+
value: text,
|
|
52
|
+
prevValue
|
|
53
|
+
});
|
|
54
|
+
};
|
|
55
|
+
const wrappedRemove = function (key) {
|
|
56
|
+
const area = areaOf(this);
|
|
57
|
+
const name = String(key);
|
|
58
|
+
const prevValue = area ? this.getItem(name) : null;
|
|
59
|
+
Reflect.apply(remove, this, [name]);
|
|
60
|
+
if (area) emit({
|
|
61
|
+
area,
|
|
62
|
+
action: 'removeItem',
|
|
63
|
+
key: name,
|
|
64
|
+
prevValue
|
|
65
|
+
});
|
|
66
|
+
};
|
|
67
|
+
const wrappedClear = function () {
|
|
68
|
+
const area = areaOf(this);
|
|
69
|
+
const prevPairs = area ? entries(this) : undefined;
|
|
70
|
+
Reflect.apply(clear, this, []);
|
|
71
|
+
if (area) emit({
|
|
72
|
+
area,
|
|
73
|
+
action: 'clear',
|
|
74
|
+
prevPairs
|
|
75
|
+
});
|
|
76
|
+
};
|
|
77
|
+
proto.setItem = wrappedSet;
|
|
78
|
+
proto.removeItem = wrappedRemove;
|
|
79
|
+
proto.clear = wrappedClear;
|
|
80
|
+
const crossDocument = event => {
|
|
81
|
+
const area = event.storageArea && areaOf(event.storageArea);
|
|
82
|
+
if (area) emit({
|
|
83
|
+
area,
|
|
84
|
+
action: event.key === null ? 'clear' : event.newValue === null ? 'removeItem' : 'setItem',
|
|
85
|
+
key: event.key ?? undefined,
|
|
86
|
+
value: event.newValue ?? undefined,
|
|
87
|
+
prevValue: event.oldValue
|
|
88
|
+
});
|
|
89
|
+
};
|
|
90
|
+
window.addEventListener('storage', crossDocument);
|
|
91
|
+
detach = () => {
|
|
92
|
+
if (proto.setItem === wrappedSet) proto.setItem = set;
|
|
93
|
+
if (proto.removeItem === wrappedRemove) proto.removeItem = remove;
|
|
94
|
+
if (proto.clear === wrappedClear) proto.clear = clear;
|
|
95
|
+
window.removeEventListener('storage', crossDocument);
|
|
96
|
+
detach = undefined;
|
|
97
|
+
};
|
|
98
|
+
}
|
|
99
|
+
function subscribeToBrowserStorage(listener) {
|
|
100
|
+
if (!listeners.size) attach();
|
|
101
|
+
listeners.add(listener);
|
|
102
|
+
return () => {
|
|
103
|
+
listeners.delete(listener);
|
|
104
|
+
if (!listeners.size) detach?.();
|
|
105
|
+
};
|
|
106
|
+
}
|
|
107
|
+
function merge(previous, next) {
|
|
108
|
+
if (!previous || !next || typeof previous !== 'object' || typeof next !== 'object' || Array.isArray(previous) || Array.isArray(next)) return next;
|
|
109
|
+
const result = {
|
|
110
|
+
...previous
|
|
111
|
+
};
|
|
112
|
+
for (const [key, value] of Object.entries(next)) {
|
|
113
|
+
Object.defineProperty(result, key, {
|
|
114
|
+
value: merge(result[key], value),
|
|
115
|
+
enumerable: true,
|
|
116
|
+
writable: true,
|
|
117
|
+
configurable: true
|
|
118
|
+
});
|
|
119
|
+
}
|
|
120
|
+
return result;
|
|
121
|
+
}
|
|
122
|
+
|
|
123
|
+
// The shared storage editor and snapshot providers use this asynchronous contract.
|
|
124
|
+
const browserAsyncStorage = {
|
|
125
|
+
async getItem(key) {
|
|
126
|
+
return getBrowserStorage().getItem(key);
|
|
127
|
+
},
|
|
128
|
+
async setItem(key, value) {
|
|
129
|
+
getBrowserStorage().setItem(key, value);
|
|
130
|
+
},
|
|
131
|
+
async removeItem(key) {
|
|
132
|
+
getBrowserStorage().removeItem(key);
|
|
133
|
+
},
|
|
134
|
+
async clear() {
|
|
135
|
+
getBrowserStorage().clear();
|
|
136
|
+
},
|
|
137
|
+
async getAllKeys() {
|
|
138
|
+
return entries(getBrowserStorage()).map(([key]) => key);
|
|
139
|
+
},
|
|
140
|
+
async multiGet(keys) {
|
|
141
|
+
return keys.map(key => [key, getBrowserStorage().getItem(key)]);
|
|
142
|
+
},
|
|
143
|
+
async multiSet(pairs) {
|
|
144
|
+
for (const [key, value] of pairs) getBrowserStorage().setItem(key, value);
|
|
145
|
+
},
|
|
146
|
+
async multiRemove(keys) {
|
|
147
|
+
for (const key of keys) getBrowserStorage().removeItem(key);
|
|
148
|
+
},
|
|
149
|
+
async mergeItem(key, value) {
|
|
150
|
+
const storage = getBrowserStorage();
|
|
151
|
+
storage.setItem(key, JSON.stringify(merge(JSON.parse(storage.getItem(key) ?? 'null'), JSON.parse(value))));
|
|
152
|
+
},
|
|
153
|
+
async multiMerge(pairs) {
|
|
154
|
+
for (const [key, value] of pairs) await browserAsyncStorage.mergeItem(key, value);
|
|
155
|
+
}
|
|
156
|
+
};
|
|
157
|
+
var _default = exports.default = browserAsyncStorage;
|
|
@@ -0,0 +1,116 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports.browserRouter = void 0;
|
|
7
|
+
exports.getBrowserHref = getBrowserHref;
|
|
8
|
+
exports.getBrowserRouteURL = getBrowserRouteURL;
|
|
9
|
+
exports.registerBrowserRouter = registerBrowserRouter;
|
|
10
|
+
exports.subscribeBrowserNavigation = subscribeBrowserNavigation;
|
|
11
|
+
let adapter;
|
|
12
|
+
const listeners = new Set();
|
|
13
|
+
let detach;
|
|
14
|
+
function registerBrowserRouter(router) {
|
|
15
|
+
adapter = router;
|
|
16
|
+
return () => {
|
|
17
|
+
if (adapter === router) adapter = undefined;
|
|
18
|
+
};
|
|
19
|
+
}
|
|
20
|
+
function getBrowserHref() {
|
|
21
|
+
return typeof location === 'undefined' ? '/' : location.href;
|
|
22
|
+
}
|
|
23
|
+
function getBrowserRouteURL(href = getBrowserHref()) {
|
|
24
|
+
const url = new URL(href, 'http://localhost');
|
|
25
|
+
return url.hash.startsWith('#/') ? new URL(url.hash.slice(1), url.origin) : url;
|
|
26
|
+
}
|
|
27
|
+
function subscribeBrowserNavigation(listener) {
|
|
28
|
+
if (!listeners.size && typeof window !== 'undefined') {
|
|
29
|
+
const history = window.history;
|
|
30
|
+
const push = history.pushState;
|
|
31
|
+
const replace = history.replaceState;
|
|
32
|
+
const emit = kind => {
|
|
33
|
+
for (const callback of [...listeners]) {
|
|
34
|
+
try {
|
|
35
|
+
callback({
|
|
36
|
+
href: getBrowserHref(),
|
|
37
|
+
kind
|
|
38
|
+
});
|
|
39
|
+
} catch {/* Keep host navigation intact. */}
|
|
40
|
+
}
|
|
41
|
+
};
|
|
42
|
+
const wrappedPush = function (...args) {
|
|
43
|
+
const result = Reflect.apply(push, this, args);
|
|
44
|
+
emit('push');
|
|
45
|
+
return result;
|
|
46
|
+
};
|
|
47
|
+
const wrappedReplace = function (...args) {
|
|
48
|
+
const result = Reflect.apply(replace, this, args);
|
|
49
|
+
emit('replace');
|
|
50
|
+
return result;
|
|
51
|
+
};
|
|
52
|
+
history.pushState = wrappedPush;
|
|
53
|
+
history.replaceState = wrappedReplace;
|
|
54
|
+
const pop = () => emit('pop');
|
|
55
|
+
window.addEventListener('popstate', pop);
|
|
56
|
+
window.addEventListener('hashchange', pop);
|
|
57
|
+
detach = () => {
|
|
58
|
+
if (history.pushState === wrappedPush) history.pushState = push;
|
|
59
|
+
if (history.replaceState === wrappedReplace) history.replaceState = replace;
|
|
60
|
+
window.removeEventListener('popstate', pop);
|
|
61
|
+
window.removeEventListener('hashchange', pop);
|
|
62
|
+
detach = undefined;
|
|
63
|
+
};
|
|
64
|
+
}
|
|
65
|
+
listeners.add(listener);
|
|
66
|
+
return () => {
|
|
67
|
+
listeners.delete(listener);
|
|
68
|
+
if (!listeners.size) detach?.();
|
|
69
|
+
};
|
|
70
|
+
}
|
|
71
|
+
function pathFor(path) {
|
|
72
|
+
const target = typeof path === 'string' ? path : path.pathname;
|
|
73
|
+
const url = new URL(target, getBrowserHref());
|
|
74
|
+
if (url.origin !== window.location.origin) throw new Error('Tool navigation must stay on the current origin.');
|
|
75
|
+
if (typeof path !== 'string') for (const [key, value] of Object.entries(path.params ?? {})) url.searchParams.set(key, String(value));
|
|
76
|
+
return `${url.pathname}${url.search}${url.hash}`;
|
|
77
|
+
}
|
|
78
|
+
const browserRouter = exports.browserRouter = {
|
|
79
|
+
push(path) {
|
|
80
|
+
const target = pathFor(path);
|
|
81
|
+
if (adapter) return adapter.push(target);
|
|
82
|
+
window.history.pushState(null, '', window.location.hash.startsWith('#/') ? `#${target}` : target);
|
|
83
|
+
window.dispatchEvent(new PopStateEvent('popstate', {
|
|
84
|
+
state: window.history.state
|
|
85
|
+
}));
|
|
86
|
+
},
|
|
87
|
+
replace(path) {
|
|
88
|
+
const target = pathFor(path);
|
|
89
|
+
if (adapter) return adapter.replace(target);
|
|
90
|
+
window.history.replaceState(window.history.state, '', window.location.hash.startsWith('#/') ? `#${target}` : target);
|
|
91
|
+
window.dispatchEvent(new PopStateEvent('popstate', {
|
|
92
|
+
state: window.history.state
|
|
93
|
+
}));
|
|
94
|
+
},
|
|
95
|
+
back() {
|
|
96
|
+
if (adapter) adapter.back();else window.history.back();
|
|
97
|
+
},
|
|
98
|
+
canGoBack() {
|
|
99
|
+
return adapter?.canGoBack?.() ?? (typeof window !== 'undefined' && window.history.length > 1);
|
|
100
|
+
},
|
|
101
|
+
navigate(path) {
|
|
102
|
+
browserRouter.push(path);
|
|
103
|
+
},
|
|
104
|
+
setParams(params) {
|
|
105
|
+
browserRouter.replace({
|
|
106
|
+
pathname: getBrowserHref(),
|
|
107
|
+
params
|
|
108
|
+
});
|
|
109
|
+
},
|
|
110
|
+
dismiss(count = 1) {
|
|
111
|
+
window.history.go(-count);
|
|
112
|
+
},
|
|
113
|
+
dismissAll() {
|
|
114
|
+
throw new Error('Use the captured browser history to select a destination.');
|
|
115
|
+
}
|
|
116
|
+
};
|
|
@@ -27,11 +27,15 @@ const ORIGIN_RE = /^(https?:\/\/[^/]+)/;
|
|
|
27
27
|
/** Bundle URL this JS realm was loaded from, or null off React Native. */
|
|
28
28
|
function scriptURL() {
|
|
29
29
|
try {
|
|
30
|
-
//
|
|
31
|
-
// react-native
|
|
32
|
-
|
|
30
|
+
// The public route to the SourceCode TurboModule that
|
|
31
|
+
// react-native/Libraries/NativeModules/specs/NativeSourceCode wraps. Deep
|
|
32
|
+
// imports warn on RN 0.80+; react-native-web has no registry and falls
|
|
33
|
+
// through to null.
|
|
33
34
|
// eslint-disable-next-line @typescript-eslint/no-var-requires
|
|
34
|
-
|
|
35
|
+
const {
|
|
36
|
+
TurboModuleRegistry
|
|
37
|
+
} = require("react-native");
|
|
38
|
+
const NativeSourceCode = TurboModuleRegistry?.get?.("SourceCode");
|
|
35
39
|
const url = NativeSourceCode?.getConstants?.().scriptURL;
|
|
36
40
|
if (url) return url;
|
|
37
41
|
} catch {
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports.getDevServerOrigin = getDevServerOrigin;
|
|
7
|
+
// A browser origin does not imply the presence of Metro's reload socket.
|
|
8
|
+
function getDevServerOrigin() {
|
|
9
|
+
return null;
|
|
10
|
+
}
|
|
@@ -0,0 +1,143 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports.getDOMControlProps = getDOMControlProps;
|
|
7
|
+
exports.getDOMFiber = getDOMFiber;
|
|
8
|
+
exports.getDOMNodeHandle = getDOMNodeHandle;
|
|
9
|
+
exports.getDOMPublicInstance = getDOMPublicInstance;
|
|
10
|
+
exports.isDOMElement = isDOMElement;
|
|
11
|
+
exports.resolveDOMEventEmitter = resolveDOMEventEmitter;
|
|
12
|
+
const handles = new WeakMap();
|
|
13
|
+
let nextHandle = 1;
|
|
14
|
+
function isDOMElement(value) {
|
|
15
|
+
return !!value && typeof value === 'object' && value.nodeType === 1 && typeof value.getBoundingClientRect === 'function';
|
|
16
|
+
}
|
|
17
|
+
function getDOMNodeHandle(value) {
|
|
18
|
+
if (!isDOMElement(value)) return null;
|
|
19
|
+
let handle = handles.get(value);
|
|
20
|
+
if (handle === undefined) {
|
|
21
|
+
handle = nextHandle++;
|
|
22
|
+
handles.set(value, handle);
|
|
23
|
+
}
|
|
24
|
+
return handle;
|
|
25
|
+
}
|
|
26
|
+
function getDOMFiber(value) {
|
|
27
|
+
if (!isDOMElement(value)) return null;
|
|
28
|
+
const key = Object.keys(value).find(name => name.startsWith('__reactFiber$'));
|
|
29
|
+
return key ? value[key] : null;
|
|
30
|
+
}
|
|
31
|
+
|
|
32
|
+
/** Map DOM controls onto the shared screen automation contract. */
|
|
33
|
+
function getDOMControlProps(value, props) {
|
|
34
|
+
if (!isDOMElement(value) || !props) return props;
|
|
35
|
+
const input = value;
|
|
36
|
+
const tag = value.tagName.toLowerCase();
|
|
37
|
+
const toggle = tag === 'input' && (input.type === 'checkbox' || input.type === 'radio');
|
|
38
|
+
const range = tag === 'input' && input.type === 'range';
|
|
39
|
+
const text = tag === 'textarea' || tag === 'select' || tag === 'input' && !toggle && !range && !['button', 'submit', 'reset', 'file', 'hidden'].includes(input.type);
|
|
40
|
+
const setValue = next => {
|
|
41
|
+
if (toggle) {
|
|
42
|
+
if (input.checked !== Boolean(next)) input.click();
|
|
43
|
+
return;
|
|
44
|
+
}
|
|
45
|
+
const setter = Object.getOwnPropertyDescriptor(Object.getPrototypeOf(input), 'value')?.set;
|
|
46
|
+
if (setter) setter.call(input, String(next));else input.value = String(next);
|
|
47
|
+
input.dispatchEvent(new Event('input', {
|
|
48
|
+
bubbles: true
|
|
49
|
+
}));
|
|
50
|
+
input.dispatchEvent(new Event('change', {
|
|
51
|
+
bubbles: true
|
|
52
|
+
}));
|
|
53
|
+
};
|
|
54
|
+
return {
|
|
55
|
+
...props,
|
|
56
|
+
__buoyDevToolsRoot: props.__buoyDevToolsRoot || props['data-buoy-root'] !== undefined,
|
|
57
|
+
testID: props.testID ?? props['data-testid'],
|
|
58
|
+
nativeID: props.nativeID ?? props.id,
|
|
59
|
+
accessibilityLabel: props.accessibilityLabel ?? props['aria-label'],
|
|
60
|
+
accessibilityRole: props.accessibilityRole ?? props.role ?? (tag === 'button' ? 'button' : tag === 'a' ? 'link' : toggle ? input.type : text ? 'textbox' : range ? 'slider' : undefined),
|
|
61
|
+
onPress: props.onPress ?? (typeof props.onClick === 'function' || tag === 'button' || tag === 'a' ? () => input.click() : undefined),
|
|
62
|
+
...(toggle || range ? {
|
|
63
|
+
onValueChange: setValue,
|
|
64
|
+
value: toggle ? input.checked : Number(input.value),
|
|
65
|
+
...(range ? {
|
|
66
|
+
minimumValue: Number(input.min || 0),
|
|
67
|
+
maximumValue: Number(input.max || 100)
|
|
68
|
+
} : {})
|
|
69
|
+
} : {}),
|
|
70
|
+
...(text ? {
|
|
71
|
+
onChangeText: setValue,
|
|
72
|
+
value: input.value
|
|
73
|
+
} : {})
|
|
74
|
+
};
|
|
75
|
+
}
|
|
76
|
+
function getDOMPublicInstance(value) {
|
|
77
|
+
if (!isDOMElement(value)) return null;
|
|
78
|
+
return {
|
|
79
|
+
__nativeTag: getDOMNodeHandle(value),
|
|
80
|
+
measure(callback) {
|
|
81
|
+
const rect = value.getBoundingClientRect();
|
|
82
|
+
callback(rect.x, rect.y, rect.width, rect.height, rect.x, rect.y);
|
|
83
|
+
},
|
|
84
|
+
measureInWindow(callback) {
|
|
85
|
+
const rect = value.getBoundingClientRect();
|
|
86
|
+
callback(rect.x, rect.y, rect.width, rect.height);
|
|
87
|
+
},
|
|
88
|
+
requestTVFocus() {
|
|
89
|
+
value.focus();
|
|
90
|
+
},
|
|
91
|
+
focus() {
|
|
92
|
+
value.focus();
|
|
93
|
+
}
|
|
94
|
+
};
|
|
95
|
+
}
|
|
96
|
+
const eventNames = {
|
|
97
|
+
topFocus: 'focus',
|
|
98
|
+
topBlur: 'blur',
|
|
99
|
+
topTouchStart: 'pointerdown',
|
|
100
|
+
topTouchMove: 'pointermove',
|
|
101
|
+
topTouchEnd: 'pointerup',
|
|
102
|
+
topTouchCancel: 'pointercancel',
|
|
103
|
+
topChange: 'input',
|
|
104
|
+
topValueChange: 'input',
|
|
105
|
+
topSlidingComplete: 'change'
|
|
106
|
+
};
|
|
107
|
+
function resolveDOMEventEmitter() {
|
|
108
|
+
if (typeof document === 'undefined') return {
|
|
109
|
+
emitter: null,
|
|
110
|
+
reason: 'DOM events are unavailable during server rendering.'
|
|
111
|
+
};
|
|
112
|
+
return {
|
|
113
|
+
reason: null,
|
|
114
|
+
emitter: {
|
|
115
|
+
addListener(name, listener) {
|
|
116
|
+
const type = eventNames[name];
|
|
117
|
+
if (!type) throw new Error(`Unsupported DOM event: ${name}`);
|
|
118
|
+
const callback = event => {
|
|
119
|
+
const element = event.composedPath()[0] ?? event.target;
|
|
120
|
+
if (!isDOMElement(element)) return;
|
|
121
|
+
const input = element;
|
|
122
|
+
const pointer = event;
|
|
123
|
+
const nativeEvent = {
|
|
124
|
+
target: getDOMNodeHandle(element),
|
|
125
|
+
pageX: pointer.clientX,
|
|
126
|
+
pageY: pointer.clientY
|
|
127
|
+
};
|
|
128
|
+
if (type === 'input' || type === 'change') {
|
|
129
|
+
if (input.type === 'checkbox' || input.type === 'radio') nativeEvent.value = input.checked;else if (input.type === 'range') nativeEvent.value = Number(input.value);else nativeEvent.text = input.value ?? element.textContent ?? '';
|
|
130
|
+
}
|
|
131
|
+
listener({
|
|
132
|
+
eventName: name,
|
|
133
|
+
nativeEvent
|
|
134
|
+
});
|
|
135
|
+
};
|
|
136
|
+
document.addEventListener(type, callback, true);
|
|
137
|
+
return {
|
|
138
|
+
remove: () => document.removeEventListener(type, callback, true)
|
|
139
|
+
};
|
|
140
|
+
}
|
|
141
|
+
}
|
|
142
|
+
};
|
|
143
|
+
}
|
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports.loadExpoRouter = loadExpoRouter;
|
|
7
|
+
exports.loadExpoRouterStore = loadExpoRouterStore;
|
|
8
|
+
var _reactNative = require("react-native");
|
|
9
|
+
function hasExpoNativeRuntime() {
|
|
10
|
+
// Modern Expo (SDK 50+, both Old and New Architecture): expo-modules-core
|
|
11
|
+
// installs a global `expo` object — the Expo Modules API runtime — via JSI
|
|
12
|
+
// when the native runtime is actually present. This is the most reliable
|
|
13
|
+
// signal and, crucially, the ONLY one of these checks that fires on SDK 54+ /
|
|
14
|
+
// New Architecture dev builds, where the legacy NativeModules entries below
|
|
15
|
+
// are no longer registered (ExpoLinking is gone, NativeUnimoduleProxy isn't
|
|
16
|
+
// on the bridge). It stays absent on bare RN CLI, so there's no false
|
|
17
|
+
// positive there. Without this, navigation-dependent tools (route sitemap,
|
|
18
|
+
// remote navigate, perf-monitor automation) silently no-op on modern builds.
|
|
19
|
+
const expoGlobal = globalThis.expo;
|
|
20
|
+
if (expoGlobal != null && (expoGlobal.modules != null || expoGlobal.EventEmitter != null || expoGlobal.NativeModule != null)) {
|
|
21
|
+
return true;
|
|
22
|
+
}
|
|
23
|
+
|
|
24
|
+
// Check legacy NativeModules bridge (Expo SDK < 54)
|
|
25
|
+
if (_reactNative.NativeModules.ExpoLinking) {
|
|
26
|
+
return true;
|
|
27
|
+
}
|
|
28
|
+
|
|
29
|
+
// Check for Expo Modules Core native bridge (older SDKs / Old Architecture)
|
|
30
|
+
if (_reactNative.NativeModules.NativeUnimoduleProxy || _reactNative.NativeModules.ExpoModulesCore) {
|
|
31
|
+
return true;
|
|
32
|
+
}
|
|
33
|
+
|
|
34
|
+
// Check for Expo Go app
|
|
35
|
+
if (_reactNative.NativeModules.ExpoGoModule || _reactNative.NativeModules.ExpoUpdates) {
|
|
36
|
+
return true;
|
|
37
|
+
}
|
|
38
|
+
|
|
39
|
+
// No Expo native runtime detected (e.g. bare RN CLI).
|
|
40
|
+
// NOTE: We intentionally do NOT try require("expo-modules-core") here because
|
|
41
|
+
// on RN CLI it may be bundled as a transitive dep but the native modules
|
|
42
|
+
// (requireOptionalNativeModule etc.) are undefined, causing crashes.
|
|
43
|
+
return false;
|
|
44
|
+
}
|
|
45
|
+
function loadExpoRouter() {
|
|
46
|
+
if (!hasExpoNativeRuntime()) return null;
|
|
47
|
+
return require("expo-router");
|
|
48
|
+
}
|
|
49
|
+
function loadExpoRouterStore() {
|
|
50
|
+
return require("expo-router/build/global-state/router-store")?.store ?? null;
|
|
51
|
+
}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports.loadExpoRouter = loadExpoRouter;
|
|
7
|
+
exports.loadExpoRouterStore = loadExpoRouterStore;
|
|
8
|
+
// Automatic Expo Router discovery is not supported by the browser entry.
|
|
9
|
+
function loadExpoRouter() {
|
|
10
|
+
return null;
|
|
11
|
+
}
|
|
12
|
+
function loadExpoRouterStore() {
|
|
13
|
+
return null;
|
|
14
|
+
}
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports.getSafeAreaInsets = getSafeAreaInsets;
|
|
7
|
+
function getSafeAreaInsets() {
|
|
8
|
+
const empty = {
|
|
9
|
+
top: 0,
|
|
10
|
+
bottom: 0,
|
|
11
|
+
left: 0,
|
|
12
|
+
right: 0,
|
|
13
|
+
hasNotch: false
|
|
14
|
+
};
|
|
15
|
+
if (typeof document === "undefined" || !document.body) return empty;
|
|
16
|
+
const probe = document.createElement("div");
|
|
17
|
+
probe.style.cssText = "position:fixed;visibility:hidden;pointer-events:none;padding-top:env(safe-area-inset-top);padding-bottom:env(safe-area-inset-bottom);padding-left:env(safe-area-inset-left);padding-right:env(safe-area-inset-right)";
|
|
18
|
+
document.body.appendChild(probe);
|
|
19
|
+
try {
|
|
20
|
+
const style = getComputedStyle(probe);
|
|
21
|
+
const top = parseFloat(style.paddingTop) || 0;
|
|
22
|
+
const bottom = parseFloat(style.paddingBottom) || 0;
|
|
23
|
+
const left = parseFloat(style.paddingLeft) || 0;
|
|
24
|
+
const right = parseFloat(style.paddingRight) || 0;
|
|
25
|
+
return {
|
|
26
|
+
top,
|
|
27
|
+
bottom,
|
|
28
|
+
left,
|
|
29
|
+
right,
|
|
30
|
+
hasNotch: top > 0 || bottom > 0 || left > 0 || right > 0
|
|
31
|
+
};
|
|
32
|
+
} finally {
|
|
33
|
+
probe.remove();
|
|
34
|
+
}
|
|
35
|
+
}
|