one 1.1.298 → 1.1.300

Sign up to get free protection for your applications and to get access to all the features.
Files changed (343) hide show
  1. package/dist/cjs/cleanUrl.js +1 -1
  2. package/dist/cjs/cleanUrl.js.map +1 -1
  3. package/dist/cjs/cleanUrl.native.js +1 -1
  4. package/dist/cjs/cleanUrl.native.js.map +1 -1
  5. package/dist/cjs/cli/runAndroid.js +34 -0
  6. package/dist/cjs/cli/runAndroid.js.map +6 -0
  7. package/dist/cjs/cli/runAndroid.native.js +39 -0
  8. package/dist/cjs/cli/runAndroid.native.js.map +6 -0
  9. package/dist/cjs/cli/runIos.js +34 -0
  10. package/dist/cjs/cli/runIos.js.map +6 -0
  11. package/dist/cjs/cli/runIos.native.js +39 -0
  12. package/dist/cjs/cli/runIos.native.js.map +6 -0
  13. package/dist/cjs/cli.js +23 -1
  14. package/dist/cjs/cli.js.map +1 -1
  15. package/dist/cjs/cli.native.js +25 -1
  16. package/dist/cjs/cli.native.js.map +2 -2
  17. package/dist/cjs/createHandleRequest.js +2 -2
  18. package/dist/cjs/createHandleRequest.js.map +1 -1
  19. package/dist/cjs/createHandleRequest.native.js +2 -2
  20. package/dist/cjs/createHandleRequest.native.js.map +2 -2
  21. package/dist/cjs/vite/createFileSystemRouter.js +1 -1
  22. package/dist/cjs/vite/createFileSystemRouter.js.map +1 -1
  23. package/dist/cjs/vite/createFileSystemRouter.native.js +1 -1
  24. package/dist/cjs/vite/createFileSystemRouter.native.js.map +1 -1
  25. package/dist/cjs/vite/replaceLoader.js +7 -1
  26. package/dist/cjs/vite/replaceLoader.js.map +1 -1
  27. package/dist/cjs/vite/replaceLoader.native.js +7 -1
  28. package/dist/cjs/vite/replaceLoader.native.js.map +1 -1
  29. package/dist/esm/Root.native.js +110 -104
  30. package/dist/esm/Root.native.js.map +6 -1
  31. package/dist/esm/Route.native.js +12 -10
  32. package/dist/esm/Route.native.js.map +6 -1
  33. package/dist/esm/cleanUrl.js +1 -1
  34. package/dist/esm/cleanUrl.js.map +1 -1
  35. package/dist/esm/cleanUrl.mjs +1 -1
  36. package/dist/esm/cleanUrl.mjs.map +1 -1
  37. package/dist/esm/cleanUrl.native.js +13 -14
  38. package/dist/esm/cleanUrl.native.js.map +6 -1
  39. package/dist/esm/cli/label-process.native.js +5 -4
  40. package/dist/esm/cli/label-process.native.js.map +6 -1
  41. package/dist/esm/cli/main.native.js +8 -13
  42. package/dist/esm/cli/main.native.js.map +6 -1
  43. package/dist/esm/cli/prebuild.native.js +5 -5
  44. package/dist/esm/cli/prebuild.native.js.map +6 -1
  45. package/dist/esm/cli/run.native.js +21 -28
  46. package/dist/esm/cli/run.native.js.map +6 -1
  47. package/dist/esm/cli/runAndroid.js +10 -0
  48. package/dist/esm/cli/runAndroid.js.map +6 -0
  49. package/dist/esm/cli/runAndroid.mjs +10 -0
  50. package/dist/esm/cli/runAndroid.mjs.map +1 -0
  51. package/dist/esm/cli/runAndroid.native.js +10 -0
  52. package/dist/esm/cli/runAndroid.native.js.map +6 -0
  53. package/dist/esm/cli/runIos.js +10 -0
  54. package/dist/esm/cli/runIos.js.map +6 -0
  55. package/dist/esm/cli/runIos.mjs +10 -0
  56. package/dist/esm/cli/runIos.mjs.map +1 -0
  57. package/dist/esm/cli/runIos.native.js +10 -0
  58. package/dist/esm/cli/runIos.native.js.map +6 -0
  59. package/dist/esm/cli.js +23 -1
  60. package/dist/esm/cli.js.map +1 -1
  61. package/dist/esm/cli.mjs +33 -1
  62. package/dist/esm/cli.mjs.map +1 -1
  63. package/dist/esm/cli.native.js +143 -148
  64. package/dist/esm/cli.native.js.map +6 -1
  65. package/dist/esm/clientLoaderResolver.native.js +9 -6
  66. package/dist/esm/clientLoaderResolver.native.js.map +6 -1
  67. package/dist/esm/config.native.js +12 -11
  68. package/dist/esm/config.native.js.map +6 -1
  69. package/dist/esm/constants.native.js +7 -5
  70. package/dist/esm/constants.native.js.map +6 -1
  71. package/dist/esm/createApp.native.js +13 -9
  72. package/dist/esm/createApp.native.js.map +6 -1
  73. package/dist/esm/createHandleRequest.js +2 -2
  74. package/dist/esm/createHandleRequest.js.map +1 -1
  75. package/dist/esm/createHandleRequest.mjs +2 -2
  76. package/dist/esm/createHandleRequest.mjs.map +1 -1
  77. package/dist/esm/createHandleRequest.native.js +57 -66
  78. package/dist/esm/createHandleRequest.native.js.map +6 -1
  79. package/dist/esm/createRoute.native.js +16 -16
  80. package/dist/esm/createRoute.native.js.map +6 -1
  81. package/dist/esm/fallbackViews/Sitemap.native.js +6 -3
  82. package/dist/esm/fallbackViews/Sitemap.native.js.map +6 -1
  83. package/dist/esm/fallbackViews/Unmatched.native.js +5 -3
  84. package/dist/esm/fallbackViews/Unmatched.native.js.map +6 -1
  85. package/dist/esm/fork/NavigationContainer.native.js +24 -31
  86. package/dist/esm/fork/NavigationContainer.native.js.map +6 -1
  87. package/dist/esm/fork/createMemoryHistory.native.js +99 -115
  88. package/dist/esm/fork/createMemoryHistory.native.js.map +6 -1
  89. package/dist/esm/fork/extractPathFromURL.native.js +16 -15
  90. package/dist/esm/fork/extractPathFromURL.native.js.map +6 -1
  91. package/dist/esm/fork/findFocusedRoute.native.js +6 -5
  92. package/dist/esm/fork/findFocusedRoute.native.js.map +6 -1
  93. package/dist/esm/fork/getPathFromState.native.js +127 -140
  94. package/dist/esm/fork/getPathFromState.native.js.map +6 -1
  95. package/dist/esm/fork/getStateFromPath.native.js +292 -288
  96. package/dist/esm/fork/getStateFromPath.native.js.map +6 -1
  97. package/dist/esm/fork/useLinking.native.js +70 -61
  98. package/dist/esm/fork/useLinking.native.js.map +6 -1
  99. package/dist/esm/fork/validatePathConfig.native.js +15 -9
  100. package/dist/esm/fork/validatePathConfig.native.js.map +6 -1
  101. package/dist/esm/getLinkingConfig.native.js +11 -6
  102. package/dist/esm/getLinkingConfig.native.js.map +6 -1
  103. package/dist/esm/getReactNavigationConfig.native.js +28 -20
  104. package/dist/esm/getReactNavigationConfig.native.js.map +6 -1
  105. package/dist/esm/getRoutes.native.js +249 -229
  106. package/dist/esm/getRoutes.native.js.map +6 -1
  107. package/dist/esm/getURL.native.js +4 -4
  108. package/dist/esm/getURL.native.js.map +6 -1
  109. package/dist/esm/head/Head.android.js +5 -3
  110. package/dist/esm/head/Head.android.js.map +6 -1
  111. package/dist/esm/head/Head.ios.js +144 -132
  112. package/dist/esm/head/Head.ios.js.map +6 -1
  113. package/dist/esm/head/Head.native.js +7 -7
  114. package/dist/esm/head/Head.native.js.map +6 -1
  115. package/dist/esm/head/HeadModule.native.js +6 -6
  116. package/dist/esm/head/HeadModule.native.js.map +6 -1
  117. package/dist/esm/head/index.native.js +2 -2
  118. package/dist/esm/head/index.native.js.map +6 -1
  119. package/dist/esm/head/types.native.js +1 -2
  120. package/dist/esm/head/types.native.js.map +6 -1
  121. package/dist/esm/head/url.native.js +10 -8
  122. package/dist/esm/head/url.native.js.map +6 -1
  123. package/dist/esm/hooks.native.js +53 -34
  124. package/dist/esm/hooks.native.js.map +6 -1
  125. package/dist/esm/imperative-api.native.js +9 -6
  126. package/dist/esm/imperative-api.native.js.map +6 -1
  127. package/dist/esm/import-mode/index.android.js +4 -3
  128. package/dist/esm/import-mode/index.android.js.map +6 -1
  129. package/dist/esm/import-mode/index.ios.js +4 -3
  130. package/dist/esm/import-mode/index.ios.js.map +6 -1
  131. package/dist/esm/import-mode/index.native.js +3 -1
  132. package/dist/esm/import-mode/index.native.js.map +6 -1
  133. package/dist/esm/index.native.js +65 -27
  134. package/dist/esm/index.native.js.map +6 -1
  135. package/dist/esm/interfaces/router.native.js +4 -2
  136. package/dist/esm/interfaces/router.native.js.map +6 -1
  137. package/dist/esm/layouts/Drawer.native.js +7 -6
  138. package/dist/esm/layouts/Drawer.native.js.map +6 -1
  139. package/dist/esm/layouts/Stack.native.js +7 -6
  140. package/dist/esm/layouts/Stack.native.js.map +6 -1
  141. package/dist/esm/layouts/Tabs.native.js +42 -39
  142. package/dist/esm/layouts/Tabs.native.js.map +6 -1
  143. package/dist/esm/layouts/withLayoutContext.native.js +51 -48
  144. package/dist/esm/layouts/withLayoutContext.native.js.map +6 -1
  145. package/dist/esm/link/Link.native.js +62 -53
  146. package/dist/esm/link/Link.native.js.map +6 -1
  147. package/dist/esm/link/Redirect.native.js +8 -9
  148. package/dist/esm/link/Redirect.native.js.map +6 -1
  149. package/dist/esm/link/href.native.js +28 -27
  150. package/dist/esm/link/href.native.js.map +6 -1
  151. package/dist/esm/link/linking.native.js +51 -40
  152. package/dist/esm/link/linking.native.js.map +6 -1
  153. package/dist/esm/link/path.native.js +28 -19
  154. package/dist/esm/link/path.native.js.map +6 -1
  155. package/dist/esm/link/useLinkTo.native.js +22 -20
  156. package/dist/esm/link/useLinkTo.native.js.map +6 -1
  157. package/dist/esm/link/useLoadedNavigation.native.js +30 -23
  158. package/dist/esm/link/useLoadedNavigation.native.js.map +6 -1
  159. package/dist/esm/matchers.native.js +16 -3
  160. package/dist/esm/matchers.native.js.map +6 -1
  161. package/dist/esm/platform.native.js +4 -2
  162. package/dist/esm/platform.native.js.map +6 -1
  163. package/dist/esm/polyfills-mobile.native.js +4 -5
  164. package/dist/esm/polyfills-mobile.native.js.map +6 -1
  165. package/dist/esm/polyfills-server.native.js +1 -1
  166. package/dist/esm/polyfills-server.native.js.map +6 -1
  167. package/dist/esm/render.native.js +3 -1
  168. package/dist/esm/render.native.js.map +6 -1
  169. package/dist/esm/router/RouterStore.native.js +1 -2
  170. package/dist/esm/router/RouterStore.native.js.map +6 -1
  171. package/dist/esm/router/constants.native.js +4 -2
  172. package/dist/esm/router/constants.native.js.map +6 -1
  173. package/dist/esm/router/getNormalizedStatePath.native.js +18 -17
  174. package/dist/esm/router/getNormalizedStatePath.native.js.map +6 -1
  175. package/dist/esm/router/lastAction.native.js +10 -9
  176. package/dist/esm/router/lastAction.native.js.map +6 -1
  177. package/dist/esm/router/router.native.js +135 -114
  178. package/dist/esm/router/router.native.js.map +6 -1
  179. package/dist/esm/router/serverLocationContext.native.js +4 -2
  180. package/dist/esm/router/serverLocationContext.native.js.map +6 -1
  181. package/dist/esm/router/useInitializeOneRouter.native.js +8 -5
  182. package/dist/esm/router/useInitializeOneRouter.native.js.map +6 -1
  183. package/dist/esm/serve.native.js +77 -104
  184. package/dist/esm/serve.native.js.map +6 -1
  185. package/dist/esm/server/createRoutesManifest.native.js +14 -11
  186. package/dist/esm/server/createRoutesManifest.native.js.map +6 -1
  187. package/dist/esm/server/getServerManifest.native.js +61 -67
  188. package/dist/esm/server/getServerManifest.native.js.map +6 -1
  189. package/dist/esm/server-render.native.js +9 -10
  190. package/dist/esm/server-render.native.js.map +6 -1
  191. package/dist/esm/sortRoutes.native.js +27 -17
  192. package/dist/esm/sortRoutes.native.js.map +6 -1
  193. package/dist/esm/typed-routes/generateRouteTypes.native.js +10 -11
  194. package/dist/esm/typed-routes/generateRouteTypes.native.js.map +6 -1
  195. package/dist/esm/typed-routes/getTypedRoutesDeclarationFile.native.js +38 -37
  196. package/dist/esm/typed-routes/getTypedRoutesDeclarationFile.native.js.map +6 -1
  197. package/dist/esm/types.native.js +1 -2
  198. package/dist/esm/types.native.js.map +6 -1
  199. package/dist/esm/useFocusEffect.native.js +25 -22
  200. package/dist/esm/useFocusEffect.native.js.map +6 -1
  201. package/dist/esm/useLoader.native.js +50 -50
  202. package/dist/esm/useLoader.native.js.map +6 -1
  203. package/dist/esm/useNavigation.native.js +23 -19
  204. package/dist/esm/useNavigation.native.js.map +6 -1
  205. package/dist/esm/useScreens.native.js +143 -160
  206. package/dist/esm/useScreens.native.js.map +6 -1
  207. package/dist/esm/useViteRoutes.native.js +25 -28
  208. package/dist/esm/useViteRoutes.native.js.map +6 -1
  209. package/dist/esm/utils/assertIsReady.native.js +6 -3
  210. package/dist/esm/utils/assertIsReady.native.js.map +6 -1
  211. package/dist/esm/utils/dynamicImport.native.js +5 -3
  212. package/dist/esm/utils/dynamicImport.native.js.map +6 -1
  213. package/dist/esm/utils/existsAsync.native.js +6 -4
  214. package/dist/esm/utils/existsAsync.native.js.map +6 -1
  215. package/dist/esm/utils/getPageExport.native.js +12 -11
  216. package/dist/esm/utils/getPageExport.native.js.map +6 -1
  217. package/dist/esm/utils/globDir.native.js +5 -3
  218. package/dist/esm/utils/globDir.native.js.map +6 -1
  219. package/dist/esm/utils/hashString.native.js +4 -2
  220. package/dist/esm/utils/hashString.native.js.map +6 -1
  221. package/dist/esm/utils/isResponse.native.js +4 -2
  222. package/dist/esm/utils/isResponse.native.js.map +6 -1
  223. package/dist/esm/utils/isStatus.native.js +4 -2
  224. package/dist/esm/utils/isStatus.native.js.map +6 -1
  225. package/dist/esm/utils/promiseWithResolvers.native.js +7 -7
  226. package/dist/esm/utils/promiseWithResolvers.native.js.map +6 -1
  227. package/dist/esm/utils/rand.native.js +5 -3
  228. package/dist/esm/utils/rand.native.js.map +6 -1
  229. package/dist/esm/utils/redirect.native.js +7 -5
  230. package/dist/esm/utils/redirect.native.js.map +6 -1
  231. package/dist/esm/utils/removeSearch.native.js +4 -2
  232. package/dist/esm/utils/removeSearch.native.js.map +6 -1
  233. package/dist/esm/utils/removeUndefined.native.js +6 -3
  234. package/dist/esm/utils/removeUndefined.native.js.map +6 -1
  235. package/dist/esm/utils/requireResolve.native.js +4 -2
  236. package/dist/esm/utils/requireResolve.native.js.map +6 -1
  237. package/dist/esm/utils/url.native.js +6 -2
  238. package/dist/esm/utils/url.native.js.map +6 -1
  239. package/dist/esm/utils/weakKey.native.js +11 -10
  240. package/dist/esm/utils/weakKey.native.js.map +6 -1
  241. package/dist/esm/utils/weakMemo.native.js +8 -8
  242. package/dist/esm/utils/weakMemo.native.js.map +6 -1
  243. package/dist/esm/views/EmptyRoute.native.js +5 -3
  244. package/dist/esm/views/EmptyRoute.native.js.map +6 -1
  245. package/dist/esm/views/ErrorBoundary.native.js +5 -8
  246. package/dist/esm/views/ErrorBoundary.native.js.map +6 -1
  247. package/dist/esm/views/LoadProgressBar.native.js +58 -57
  248. package/dist/esm/views/LoadProgressBar.native.js.map +6 -1
  249. package/dist/esm/views/Navigator.native.js +54 -71
  250. package/dist/esm/views/Navigator.native.js.map +6 -1
  251. package/dist/esm/views/PreloadLinks.native.js +3 -1
  252. package/dist/esm/views/PreloadLinks.native.js.map +6 -1
  253. package/dist/esm/views/RootErrorBoundary.native.js +39 -29
  254. package/dist/esm/views/RootErrorBoundary.native.js.map +6 -1
  255. package/dist/esm/views/Screen.native.js +12 -12
  256. package/dist/esm/views/Screen.native.js.map +6 -1
  257. package/dist/esm/views/ScrollRestoration.native.js +27 -27
  258. package/dist/esm/views/ScrollRestoration.native.js.map +6 -1
  259. package/dist/esm/views/Try.native.js +40 -37
  260. package/dist/esm/views/Try.native.js.map +6 -1
  261. package/dist/esm/vite/build.native.js +260 -295
  262. package/dist/esm/vite/build.native.js.map +6 -1
  263. package/dist/esm/vite/clientTreeShakePlugin.native.js +34 -33
  264. package/dist/esm/vite/clientTreeShakePlugin.native.js.map +6 -1
  265. package/dist/esm/vite/constants.native.js +6 -4
  266. package/dist/esm/vite/constants.native.js.map +6 -1
  267. package/dist/esm/vite/createFileSystemRouter.js +1 -1
  268. package/dist/esm/vite/createFileSystemRouter.js.map +1 -1
  269. package/dist/esm/vite/createFileSystemRouter.mjs +1 -1
  270. package/dist/esm/vite/createFileSystemRouter.mjs.map +1 -1
  271. package/dist/esm/vite/createFileSystemRouter.native.js +100 -131
  272. package/dist/esm/vite/createFileSystemRouter.native.js.map +6 -1
  273. package/dist/esm/vite/customNodeExternals.native.js +9 -10
  274. package/dist/esm/vite/customNodeExternals.native.js.map +6 -1
  275. package/dist/esm/vite/ensureTsConfig.native.js +7 -5
  276. package/dist/esm/vite/ensureTsConfig.native.js.map +6 -1
  277. package/dist/esm/vite/findDepsToOptimize.native.js +27 -19
  278. package/dist/esm/vite/findDepsToOptimize.native.js.map +6 -1
  279. package/dist/esm/vite/fixDependenciesPlugin.native.js +5 -3
  280. package/dist/esm/vite/fixDependenciesPlugin.native.js.map +6 -1
  281. package/dist/esm/vite/generateTypesForRoutes.native.js +9 -9
  282. package/dist/esm/vite/generateTypesForRoutes.native.js.map +6 -1
  283. package/dist/esm/vite/getManifest.native.js +6 -4
  284. package/dist/esm/vite/getManifest.native.js.map +6 -1
  285. package/dist/esm/vite/headers.native.js +11 -5
  286. package/dist/esm/vite/headers.native.js.map +6 -1
  287. package/dist/esm/vite/loadEnv.native.js +7 -6
  288. package/dist/esm/vite/loadEnv.native.js.map +6 -1
  289. package/dist/esm/vite/makePluginWebOnly.native.js +9 -5
  290. package/dist/esm/vite/makePluginWebOnly.native.js.map +6 -1
  291. package/dist/esm/vite/one.native.js +142 -127
  292. package/dist/esm/vite/one.native.js.map +6 -1
  293. package/dist/esm/vite/removeReactNativeWebAnimatedPlugin.native.js +14 -11
  294. package/dist/esm/vite/removeReactNativeWebAnimatedPlugin.native.js.map +6 -1
  295. package/dist/esm/vite/replaceLoader.js +7 -1
  296. package/dist/esm/vite/replaceLoader.js.map +1 -1
  297. package/dist/esm/vite/replaceLoader.mjs +5 -1
  298. package/dist/esm/vite/replaceLoader.mjs.map +1 -1
  299. package/dist/esm/vite/replaceLoader.native.js +13 -10
  300. package/dist/esm/vite/replaceLoader.native.js.map +6 -1
  301. package/dist/esm/vite/resolveAPIRequest.native.js +44 -47
  302. package/dist/esm/vite/resolveAPIRequest.native.js.map +6 -1
  303. package/dist/esm/vite/server.native.js +5 -4
  304. package/dist/esm/vite/server.native.js.map +6 -1
  305. package/dist/esm/vite/types.native.js +1 -2
  306. package/dist/esm/vite/types.native.js.map +6 -1
  307. package/dist/esm/vite/virtualEntryPlugin.native.js +21 -16
  308. package/dist/esm/vite/virtualEntryPlugin.native.js.map +6 -1
  309. package/dist/esm/vite/vitePluginSsrCss.native.js +61 -50
  310. package/dist/esm/vite/vitePluginSsrCss.native.js.map +6 -1
  311. package/dist/esm/vite.native.js +19 -10
  312. package/dist/esm/vite.native.js.map +6 -1
  313. package/dist/esm/zero/getQueryKey.native.js +5 -3
  314. package/dist/esm/zero/getQueryKey.native.js.map +6 -1
  315. package/dist/esm/zero/isZeroQuery.native.js +4 -2
  316. package/dist/esm/zero/isZeroQuery.native.js.map +6 -1
  317. package/dist/esm/zero/resolveQuery.native.js +9 -8
  318. package/dist/esm/zero/resolveQuery.native.js.map +6 -1
  319. package/dist/esm/zero/subscribeToQuery.native.js +5 -3
  320. package/dist/esm/zero/subscribeToQuery.native.js.map +6 -1
  321. package/dist/esm/zero/types.native.js +1 -2
  322. package/dist/esm/zero/types.native.js.map +6 -1
  323. package/dist/esm/zero/useQuery.native.js +12 -12
  324. package/dist/esm/zero/useQuery.native.js.map +6 -1
  325. package/dist/esm/zero/useQueryZero.native.js +24 -20
  326. package/dist/esm/zero/useQueryZero.native.js.map +6 -1
  327. package/dist/esm/zero.native.js +9 -5
  328. package/dist/esm/zero.native.js.map +6 -1
  329. package/package.json +7 -7
  330. package/src/cleanUrl.ts +1 -1
  331. package/src/cli/runAndroid.ts +6 -0
  332. package/src/cli/runIos.ts +6 -0
  333. package/src/cli.ts +27 -1
  334. package/src/createHandleRequest.ts +7 -0
  335. package/src/vite/createFileSystemRouter.tsx +1 -2
  336. package/src/vite/replaceLoader.ts +7 -1
  337. package/types/cli/runAndroid.d.ts +2 -0
  338. package/types/cli/runAndroid.d.ts.map +1 -0
  339. package/types/cli/runIos.d.ts +2 -0
  340. package/types/cli/runIos.d.ts.map +1 -0
  341. package/types/createHandleRequest.d.ts.map +1 -1
  342. package/types/vite/createFileSystemRouter.d.ts.map +1 -1
  343. package/types/vite/replaceLoader.d.ts.map +1 -1
@@ -1 +1,6 @@
1
- {"version":3,"names":["assertPath","path","TypeError","JSON","stringify","normalizeStringPosix","allowAboveRoot","res","lastSegmentLength","lastSlash","dots","code","i","length","charCodeAt","lastSlashIndex","lastIndexOf","slice","resolve","_len","arguments","segments","Array","_key","resolvedPath","resolvedAbsolute"],"sources":["../../../src/link/path.ts"],"sourcesContent":[null],"mappings":"AAuBA,SAASA,WAAWC,IAAA,EAAc;EAChC,IAAI,OAAOA,IAAA,IAAS,UAClB,MAAM,IAAIC,SAAA,CAAU,qCAAqCC,IAAA,C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IACtDL,MAAMN,KAAKgB,MAAMR,YAAY,GAAGG,CAAAA,GACrCJ,oBAAoBI,IAAIH,YAAY;AAEtCA,kBAAYG,GACZF,OAAO;IACT,MAAO,CAAIC,SAAS;IAAYD,SAAS,KACvC,EAAEA,OAEFA,OAAO;EAEX;AACA,SAAOH;AACT;AAGO,SAASW,UAAAA;AAAQ,WAAA,OAAA,UAAA,QAAGC,WAAH,IAAA,MAAA,IAAA,GAAA,OAAA,GAAA,OAAA,MAAA;AAAGA,aAAH,IAAA,IAAA,UAAA,IAAA;AAItB,WAHIC,eAAe,IACfC,mBAAmB,IAEdT,IAAIO,SAASN,SAAS,GAAGD,KAAK,MAAM,CAACS,kBAAkBT,KAAK;AACnE,QAAIX,OAAAA;AAUJ,IATIW,KAAK,IACPX,OAAOkB,SAASP,CAAAA,IAEhBX,OAAO,KAGTD,WAAWC,IAAAA,GAGPA,KAAKY,WAAW,MAIpBO,eAAenB,OAAO,MAAMmB,cAC5BC,mBAAmBpB,KAAKa,WAAW,CAAA,MAAO;EAC5C;AAQA,SAFAM,eAAef,qBAAqBe,cAAc,CAACC,gBAAAA,GAE/CA,mBACED,aAAaP,SAAS,IACjB,MAAMO,eAER,MAELA,aAAaP,SAAS,IACjBO,eAEF;AACT;",
5
+ "names": ["assertPath", "path", "TypeError", "JSON", "stringify", "normalizeStringPosix", "allowAboveRoot", "res", "lastSegmentLength", "lastSlash", "dots", "code", "i", "length", "charCodeAt", "lastSlashIndex", "lastIndexOf", "slice", "resolve", "segments", "resolvedPath", "resolvedAbsolute"]
6
+ }
@@ -1,25 +1,25 @@
1
1
  import { Platform } from "react-native";
2
- import { appendBaseUrl } from "../fork/getPathFromState.native.js";
3
- import { useOneRouter } from "../router/router.native.js";
4
- import { stripGroupSegmentsFromPath } from "../matchers.native.js";
2
+ import { appendBaseUrl } from "../fork/getPathFromState";
3
+ import { useOneRouter } from "../router/router";
4
+ import { stripGroupSegmentsFromPath } from "../matchers";
5
5
  function eventShouldPreventDefault(e) {
6
- return e?.defaultPrevented ? !1 :
7
- // Only check MouseEvents
8
- !!("button" in e &&
9
- // ignore clicks with modifier keys
10
- !e.metaKey && !e.altKey && !e.ctrlKey && !e.shiftKey && (e.button == null || e.button === 0) &&
11
- // Only accept left clicks
12
- [void 0, null, "", "self"].includes(e.currentTarget.target));
6
+ return e?.defaultPrevented ? !1 : (
7
+ // Only check MouseEvents
8
+ !!("button" in e && // ignore clicks with modifier keys
9
+ !e.metaKey && !e.altKey && !e.ctrlKey && !e.shiftKey && (e.button == null || e.button === 0) && // Only accept left clicks
10
+ [
11
+ void 0,
12
+ null,
13
+ "",
14
+ "self"
15
+ ].includes(e.currentTarget.target))
16
+ );
13
17
  }
14
18
  function useLinkTo(props) {
15
- var {
16
- linkTo
17
- } = useOneRouter(),
18
- onPress = function (e) {
19
- var event = props.replace ? "REPLACE" : "PUSH",
20
- shouldHandle = !1;
21
- Platform.OS !== "web" || !e ? shouldHandle = e ? !e.defaultPrevented : !0 : eventShouldPreventDefault(e) && (e.preventDefault(), shouldHandle = !0), shouldHandle && linkTo(props.href, event);
22
- };
19
+ var { linkTo } = useOneRouter(), onPress = function(e) {
20
+ var event = props.replace ? "REPLACE" : "PUSH", shouldHandle = !1;
21
+ Platform.OS !== "web" || !e ? shouldHandle = e ? !e.defaultPrevented : !0 : eventShouldPreventDefault(e) && (e.preventDefault(), shouldHandle = !0), shouldHandle && linkTo(props.href, event);
22
+ };
23
23
  return {
24
24
  // Ensure there's always a value for href. Manually append the baseUrl to the href prop that shows in the static HTML.
25
25
  href: appendBaseUrl(stripGroupSegmentsFromPath(props.href) || "/"),
@@ -27,5 +27,7 @@ function useLinkTo(props) {
27
27
  onPress
28
28
  };
29
29
  }
30
- export { useLinkTo };
31
- //# sourceMappingURL=useLinkTo.native.js.map
30
+ export {
31
+ useLinkTo
32
+ };
33
+ //# sourceMappingURL=useLinkTo.js.map
@@ -1 +1,6 @@
1
- {"version":3,"names":["Platform","appendBaseUrl","useOneRouter","stripGroupSegmentsFromPath","eventShouldPreventDefault","e","defaultPrevented","metaKey","altKey","ctrlKey","shiftKey","button","includes","currentTarget","target","useLinkTo","props","linkTo","onPress","event","replace","shouldHandle","OS","preventDefault","href"],"sources":["../../../src/link/useLinkTo.tsx"],"sourcesContent":[null],"mappings":"AACA,SAASA,QAAA,QAA4C;AAErD,SAASC,aAAA,QAAqB;AAC9B,SAASC,YAAA,QAAoB;AAC7B,SAASC,0BAAA,QAAkC;AAE3C,SAASC,0BACPC,CAAA,EACS;EACT,OAAIA,CAAA,EAAGC,gBAAA,GACE;EAAA;EAKP,eAAYD,CAAA;EAAA;EAEZ,CAACA,CAAA,CAAEE,OAAA,IACH,CAACF,CAAA,CAAEG,MAAA,IACH,CAACH,CAAA,CAAEI,OAAA,IACH,CAACJ,CAAA,CAAEK,QAAA,KACFL,CAAA,CAAEM,MAAA,IAAU,QAAQN,CAAA,CAAEM,MAAA,KAAW;EAAA;EAClC,CAA6D,QAMjE,MAEO,IACL,MAAQ,CAGN,CAAAC,QAAM,CAAAP,CAAA,CAAAQ,aAAc,CAAAC,MAAU,EAC9B;AAEA;AAQ0B,SAE5BC,UAAAC,KAAA;EAEA;MAAAC;IAAO,IAAAf,YAAA;IAAAgB,OAAA,YAAAA,CAAAb,CAAA;MAAA,IAAAc,KAAA,GAAAH,KAAA,CAAAI,OAAA;QAAAC,YAAA;MAELrB,QAAM,CAAAsB,EAAA,UAAc,KAAAjB,CAAA,GAAAgB,YAAA,GAAAhB,CAAA,GAA2B,CAAAA,CAAA,CAAAC,gBAAkB,QAAAF,yBAAA,CAAAC,CAAA,MAAAA,CAAA,CAAAkB,cAAA,IAAAF,YAAA,QAAAA,YAAA,IAAAJ,MAAA,CAAAD,KAAA,CAAAQ,IAAA,EAAAL,KAAA;IAAA;EAC3D,OACN;IACF;IACFK,IAAA,EAAAvB,aAAA,CAAAE,0BAAA,CAAAa,KAAA,CAAAQ,IAAA","ignoreList":[]}
1
+ {
2
+ "version": 3,
3
+ "sources": ["../../../src/link/Users/n8/one/packages/one/src/link/useLinkTo.tsx"],
4
+ "mappings": "AACA,SAASA,gBAA4C;AAErD,SAASC,qBAAqB;AAC9B,SAASC,oBAAoB;AAC7B,SAASC,kCAAkC;AAE3C,SAASC,0BACPC,GAA0E;AAE1E,SAAIA,GAAGC,mBACE;;IAKP,eAAYD;IAEZ,CAACA,EAAEE,WACH,CAACF,EAAEG,UACH,CAACH,EAAEI,WACH,CAACJ,EAAEK,aACFL,EAAEM,UAAU,QAAQN,EAAEM,WAAW;IAClC;MAACC;MAAW;MAAM;MAAI;MAAQC,SAASR,EAAES,cAAcC,MAAM;;AAMjE;AAEO,SAASC,UAAUC,OAA0C;AAClE,MAAM,EAAEC,OAAM,IAAKhB,aAAAA,GAEbiB,UAAU,SAACd,GAAAA;AACf,QAAMe,QAAQH,MAAMI,UAAU,YAAY,QACtCC,eAAe;AAEnB,IAAItB,SAASuB,OAAO,SAAS,CAAClB,IAC5BiB,eAAejB,IAAI,CAACA,EAAEC,mBAAmB,KAChCF,0BAA0BC,CAAAA,MACnCA,EAAEmB,eAAc,GAChBF,eAAe,KAGbA,gBACFJ,OAAOD,MAAMQ,MAAML,KAAAA;EAEvB;AAEA,SAAO;;IAELK,MAAMxB,cAAcE,2BAA2Bc,MAAMQ,IAAI,KAAK,GAAA;IAC9DC,MAAM;IACNP;EACF;AACF;",
5
+ "names": ["Platform", "appendBaseUrl", "useOneRouter", "stripGroupSegmentsFromPath", "eventShouldPreventDefault", "e", "defaultPrevented", "metaKey", "altKey", "ctrlKey", "shiftKey", "button", "undefined", "includes", "currentTarget", "target", "useLinkTo", "props", "linkTo", "onPress", "event", "replace", "shouldHandle", "OS", "preventDefault", "href", "role"]
6
+ }
@@ -1,42 +1,49 @@
1
1
  import { useNavigation } from "@react-navigation/native";
2
2
  import { useCallback, useEffect, useRef, useState } from "react";
3
- import { useOneRouter } from "../router/router.native.js";
3
+ import { useOneRouter } from "../router/router";
4
4
  function useLoadedNavigation() {
5
- var {
6
- navigationRef
7
- } = useOneRouter(),
8
- navigation = useNavigation(),
9
- isMounted = useRef(!0),
10
- pending = useRef([]);
11
- useEffect(function () {
12
- return isMounted.current = !0, function () {
5
+ var { navigationRef } = useOneRouter(), navigation = useNavigation(), isMounted = useRef(!0), pending = useRef([]);
6
+ useEffect(function() {
7
+ return isMounted.current = !0, function() {
13
8
  isMounted.current = !1;
14
9
  };
15
10
  }, []);
16
- var flush = useCallback(function () {
11
+ var flush = useCallback(function() {
17
12
  if (isMounted.current) {
18
13
  var pendingCallbacks = pending.current;
19
- pending.current = [], pendingCallbacks.forEach(function (callback) {
14
+ pending.current = [], pendingCallbacks.forEach(function(callback) {
20
15
  callback(navigation);
21
16
  });
22
17
  }
23
- }, [navigation]);
24
- useEffect(function () {
18
+ }, [
19
+ navigation
20
+ ]);
21
+ useEffect(function() {
25
22
  navigationRef.current && flush();
26
- }, [flush, navigationRef]);
27
- var push = useCallback(function (fn) {
23
+ }, [
24
+ flush,
25
+ navigationRef
26
+ ]);
27
+ var push = useCallback(function(fn) {
28
28
  pending.current.push(fn), navigationRef.current && flush();
29
- }, [flush, navigationRef]);
29
+ }, [
30
+ flush,
31
+ navigationRef
32
+ ]);
30
33
  return push;
31
34
  }
32
35
  function useOptionalNavigation() {
33
- var [navigation, setNavigation] = useState(null),
34
- loadNavigation = useLoadedNavigation();
35
- return useEffect(function () {
36
- loadNavigation(function (nav) {
36
+ var [navigation, setNavigation] = useState(null), loadNavigation = useLoadedNavigation();
37
+ return useEffect(function() {
38
+ loadNavigation(function(nav) {
37
39
  return setNavigation(nav);
38
40
  });
39
- }, [loadNavigation]), navigation;
41
+ }, [
42
+ loadNavigation
43
+ ]), navigation;
40
44
  }
41
- export { useLoadedNavigation, useOptionalNavigation };
42
- //# sourceMappingURL=useLoadedNavigation.native.js.map
45
+ export {
46
+ useLoadedNavigation,
47
+ useOptionalNavigation
48
+ };
49
+ //# sourceMappingURL=useLoadedNavigation.js.map
@@ -1 +1,6 @@
1
- {"version":3,"names":["useNavigation","useCallback","useEffect","useRef","useState","useOneRouter","useLoadedNavigation","navigationRef","navigation","isMounted","pending","current","flush","pendingCallbacks","forEach","callback","push","fn"],"sources":["../../../src/link/useLoadedNavigation.ts"],"sourcesContent":[null],"mappings":"AAAA,SAASA,aAAA,QAAgE;AACzE,SAASC,WAAA,EAAaC,SAAA,EAAWC,MAAA,EAAQC,QAAA,QAAgB;AAEzD,SAASC,YAAA,QAAoB;AAOtB,SAASC,oBAAA,EAAsB;EACpC;MAAMC;IAAE,IAAcF,YAAI;IAAaG,UACjC,GAAAR,aAAa;IAAcS,SAC3B,GAAAN,MAAY,GAAO;IAAIO,OACvB,GAAAP,MAAU,GAAoD,CAAC;EAErED,SAAA,CAAU,YACR;IAEE,OAAAO,SAAU,CAAAE,OAAU;MAErBF,SAAE,CAAAE,OAAA;IAEL;EACE,MAAI;EACF,IAAAC,KAAA,GAAMX,WAAA,aAAmB;IACzB,IAAAQ,SAAQ,CAAAE,OAAW;MAEjB,IAAAE,gBAAS,GAA+BH,OAAA,CAAAC,OAAA;MAC1CD,OAAC,CAAAC,OAAA,OAAAE,gBAAA,CAAAC,OAAA,WAAAC,QAAA;QACHA,QAAA,CAAAP,UAAA;MACE;IAEJ;EACE,GAAI,CAGNA,UAAW,CAEE,CACX;EACEN,SAAA,aAAgB;IAIlBK,aAAA,CAAAI,OAAA,IAAAC,KAAA;EAAA,GACC,CACHA,KAAA,EAGFL,aAAA,CAEO;EACL,IAAAS,IAAO,GAAAf,WAAY,WAAagB,EAAA,EAAI;IAGpCP,OAAA,CAAAC,OAAU,CAAAK,IAAA,CAAMC,EAAA,GAAAV,aAAA,CAAAI,OAAA,IAAAC,KAAA;EACd,IACFA,KAAI,EAGNL,aAAA,C","ignoreList":[]}
1
+ {
2
+ "version": 3,
3
+ "sources": ["../../../src/link/Users/n8/one/packages/one/src/link/useLoadedNavigation.ts"],
4
+ "mappings": "AAAA,SAASA,qBAAgE;AACzE,SAASC,aAAaC,WAAWC,QAAQC,gBAAgB;AAEzD,SAASC,oBAAoB;AAOtB,SAASC,sBAAAA;AACd,MAAM,EAAEC,cAAa,IAAKF,aAAAA,GACpBG,aAAaR,cAAAA,GACbS,YAAYN,OAAO,EAAA,GACnBO,UAAUP,OAAoD,CAAA,CAAE;AAEtED,YAAU,WAAA;AACRO,qBAAUE,UAAU,IACb,WAAA;AACLF,gBAAUE,UAAU;IACtB;EACF,GAAG,CAAA,CAAE;AAEL,MAAMC,QAAQX,YAAY,WAAA;AACxB,QAAIQ,UAAUE,SAAS;AACrB,UAAME,mBAAmBH,QAAQC;AACjCD,cAAQC,UAAU,CAAA,GAClBE,iBAAiBC,QAAQ,SAACC,UAAAA;AACxBA,iBAASP,UAAAA;MACX,CAAA;IACF;EACF,GAAG;IAACA;GAAW;AAEfN,YAAU,WAAA;AACR,IAAIK,cAAcI,WAChBC,MAAAA;EAEJ,GAAG;IAACA;IAAOL;GAAc;AAEzB,MAAMS,OAAOf,YACX,SAACgB,IAAAA;AACCP,YAAQC,QAAQK,KAAKC,EAAAA,GACjBV,cAAcI,WAChBC,MAAAA;EAEJ,GACA;IAACA;IAAOL;GAAc;AAGxB,SAAOS;AACT;AAEO,SAASE,wBAAAA;AACd,MAAM,CAACV,YAAYW,aAAAA,IAAiBf,SAAmC,IAAA,GACjEgB,iBAAiBd,oBAAAA;AAEvBJ,mBAAU,WAAA;AACRkB,mBAAe,SAACC,KAAAA;aAAQF,cAAcE,GAAAA;;EACxC,GAAG;IAACD;GAAe,GAEZZ;AACT;",
5
+ "names": ["useNavigation", "useCallback", "useEffect", "useRef", "useState", "useOneRouter", "useLoadedNavigation", "navigationRef", "navigation", "isMounted", "pending", "current", "flush", "pendingCallbacks", "forEach", "callback", "push", "fn", "useOptionalNavigation", "setNavigation", "loadNavigation", "nav"]
6
+ }
@@ -31,7 +31,7 @@ function removeFileSystemDots(filePath) {
31
31
  return filePath.replace(/^(?:\.\.?\/)+/g, "");
32
32
  }
33
33
  function stripGroupSegmentsFromPath(path) {
34
- return path.split("/").reduce(function (acc, v) {
34
+ return path.split("/").reduce(function(acc, v) {
35
35
  return matchGroupName(v) == null && acc.push(v), acc;
36
36
  }, []).join("/");
37
37
  }
@@ -41,5 +41,18 @@ function stripInvisibleSegmentsFromPath(path) {
41
41
  function isTypedRoute(name) {
42
42
  return !name.startsWith("+") && name.match(/(_layout|[^/]*?\+[^/]*?)\.[tj]sx?$/) === null;
43
43
  }
44
- export { getContextKey, getNameFromFilePath, isTypedRoute, matchArrayGroupName, matchDeepDynamicRouteName, matchDynamicName, matchGroupName, removeFileSystemDots, removeSupportedExtensions, stripGroupSegmentsFromPath, stripInvisibleSegmentsFromPath, testNotFound };
45
- //# sourceMappingURL=matchers.native.js.map
44
+ export {
45
+ getContextKey,
46
+ getNameFromFilePath,
47
+ isTypedRoute,
48
+ matchArrayGroupName,
49
+ matchDeepDynamicRouteName,
50
+ matchDynamicName,
51
+ matchGroupName,
52
+ removeFileSystemDots,
53
+ removeSupportedExtensions,
54
+ stripGroupSegmentsFromPath,
55
+ stripInvisibleSegmentsFromPath,
56
+ testNotFound
57
+ };
58
+ //# sourceMappingURL=matchers.js.map
@@ -1 +1,6 @@
1
- {"version":3,"names":["matchDynamicName","name","_name_match","match","matchDeepDynamicRouteName","testNotFound","test","matchGroupName","matchArrayGroupName","getNameFromFilePath","removeSupportedExtensions","removeFileSystemDots","getContextKey","normal","endsWith","replace","filePath","stripGroupSegmentsFromPath","path","split","reduce","acc","v","push","join"],"sources":["../../src/matchers.ts"],"sourcesContent":[null],"mappings":"AACO,SAASA,iBAAiBC,IAAA,EAAkC;EAGjE,IAAAC,WAAY;EACd,QAAAA,WAAA,GAAAD,IAAA,CAAAE,KAAA,4CAAAD,WAAA,uBAAAA,WAAA;AAGO;AACL,SAAOE,yBAAWA,CAAAH,IAAA;EACpB,IAAAC,WAAA;EAGO,OAAS,CAAAA,WAAA,GAAaD,IAAuB,CAAAE,KAAA,sCAAAD,WAAA,uBAAAA,WAAA;AAClD;AACF,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", "name", "match", "matchDeepDynamicRouteName", "testNotFound", "test", "matchGroupName", "matchArrayGroupName", "getNameFromFilePath", "removeSupportedExtensions", "removeFileSystemDots", "getContextKey", "normal", "endsWith", "replace", "filePath", "stripGroupSegmentsFromPath", "path", "split", "reduce", "acc", "v", "push", "join", "stripInvisibleSegmentsFromPath", "isTypedRoute", "startsWith"]
6
+ }
@@ -1,3 +1,5 @@
1
1
  var isWeb = typeof window < "u" && typeof navigator < "u" && typeof document < "u";
2
- export { isWeb };
3
- //# sourceMappingURL=platform.native.js.map
2
+ export {
3
+ isWeb
4
+ };
5
+ //# sourceMappingURL=platform.js.map
@@ -1 +1,6 @@
1
- {"version":3,"names":["isWeb","window","navigator","document"],"sources":["../../src/platform.ts"],"sourcesContent":[null],"mappings":"AACO,IAAAA,KAAM,UACXC,MAAO,MAAW,WAClBC,SAAO,MAAc,WACrBC,QAAO,MAAa","ignoreList":[]}
1
+ {
2
+ "version": 3,
3
+ "sources": ["../../src/Users/n8/one/packages/one/src/platform.ts"],
4
+ "mappings": "AACO,IAAMA,QACX,OAAOC,SAAW,OAClB,OAAOC,YAAc,OACrB,OAAOC,WAAa;",
5
+ "names": ["isWeb", "window", "navigator", "document"]
6
+ }
@@ -2,12 +2,11 @@ import structuredClone from "@ungap/structured-clone";
2
2
  import "@azure/core-asynciterator-polyfill";
3
3
  import "core-js/actual/url";
4
4
  import "core-js/actual/url-search-params";
5
- import { promiseWithResolvers } from "./utils/promiseWithResolvers.native.js";
5
+ import { promiseWithResolvers } from "./utils/promiseWithResolvers";
6
6
  var _globalThis, _structuredClone, _globalThis1, _requestAnimationFrame;
7
7
  globalThis.global = globalThis;
8
8
  (_globalThis = globalThis)[_structuredClone = "structuredClone"] || (_globalThis[_structuredClone] = structuredClone);
9
9
  (_globalThis1 = globalThis)[_requestAnimationFrame = "requestAnimationFrame"] || (_globalThis1[_requestAnimationFrame] = setTimeout);
10
- Promise.withResolvers || (
11
- // @ts-ignore
12
- Promise.withResolvers = promiseWithResolvers);
13
- //# sourceMappingURL=polyfills-mobile.native.js.map
10
+ Promise.withResolvers || // @ts-ignore
11
+ (Promise.withResolvers = promiseWithResolvers);
12
+ //# sourceMappingURL=polyfills-mobile.js.map
@@ -1 +1,6 @@
1
- {"version":3,"names":["structuredClone","promiseWithResolvers","_globalThis","_structuredClone","_globalThis1","_requestAnimationFrame","globalThis","global","setTimeout","Promise","withResolvers"],"sources":["../../src/polyfills-mobile.ts"],"sourcesContent":[null],"mappings":"AAOA,OAAOA,eAAA,MAAqB;AAS5B,OAAO;AAIP,OAAO;AACP,OAAO;AAWP,SAASC,oBAAA,QAA4B;AA7BrC,IAAAC,WAAW,EAAAC,gBAAY,EAAAC,YAAA,EAAAC,sBAAA;AAKvBC,UAAA,CAAWC,MAAA,GAAAD,UAAA;AAIX,CAAAJ,WAAW,GAAAI,UAAA,EAAAH,gBAA6B,0BAAAD,WAAA,CAAAC,gBAAA,IAAAH,eAAA;AAqBxC,CAAAI,YAAQ,GAAAE,UAAA,EAAAD,sBAAA,gCAAAD,YAAA,CAAAC,sBAAA,IAAAG,UAAA;AAAAC,OAEL,CAAAC,aAAQ;AAAgB","ignoreList":[]}
1
+ {
2
+ "version": 3,
3
+ "sources": ["../../src/Users/n8/one/packages/one/src/polyfills-mobile.ts"],
4
+ "mappings": "AAOA,OAAOA,qBAAqB;AAS5B,OAAO;AAIP,OAAO;AACP,OAAO;AAWP,SAASC,4BAA4B;IAxBrCC,aAAW,kBAIXA,cAAW;AATXA,WAAW,SAAYA;CAKvBA,cAAAA,YAAW,mBAAA,iBAAA,MAAXA,YAAW,gBAAA,IAAuBF;CAIlCE,eAAAA,YAAW,yBAAA,uBAAA,MAAXA,aAAW,sBAAA,IAA6BC;AAqBxCC,QAAQC;CAELD,QAAQC,gBAAgBJ;",
5
+ "names": ["structuredClone", "promiseWithResolvers", "globalThis", "setTimeout", "Promise", "withResolvers"]
6
+ }
@@ -2,4 +2,4 @@ import WebSocket from "ws";
2
2
  var _globalThis, _WebSocket;
3
3
  (_globalThis = globalThis)[_WebSocket = "WebSocket"] || (_globalThis[_WebSocket] = WebSocket);
4
4
  globalThis.requestAnimationFrame = setTimeout;
5
- //# sourceMappingURL=polyfills-server.native.js.map
5
+ //# sourceMappingURL=polyfills-server.js.map
@@ -1 +1,6 @@
1
- {"version":3,"names":["WebSocket","_globalThis","_WebSocket","globalThis"],"sources":["../../src/polyfills-server.ts"],"sourcesContent":[null],"mappings":"AAAA,OAAOA,SAAA,MAAe;AAGtB,IAAAC,WAAW,EAAAC,UAAiB;AAE5B,CAAAD,WAAW,GAAAE,UAAA,EAAAD,UAA2B,oBAAAD,WAAA,CAAAC,UAAA,IAAAF,SAAA","ignoreList":[]}
1
+ {
2
+ "version": 3,
3
+ "sources": ["../../src/Users/n8/one/packages/one/src/polyfills-server.ts"],
4
+ "mappings": "AAAA,OAAOA,eAAe;IAGtBC,aAAW;CAAXA,cAAAA,YAAW,aAAA,WAAA,MAAXA,YAAW,UAAA,IAAiBD;AAE5BC,WAAW,wBAA2BC;",
5
+ "names": ["WebSocket", "globalThis", "setTimeout"]
6
+ }
@@ -1,5 +1,7 @@
1
1
  function render(element) {
2
2
  console.warn("empty");
3
3
  }
4
- export { render };
4
+ export {
5
+ render
6
+ };
5
7
  //# sourceMappingURL=render.native.js.map
@@ -1 +1,6 @@
1
- {"version":3,"names":["render","element","console","warn"],"sources":["../../src/Users/n8/one/packages/one/src/render.native.tsx"],"sourcesContent":[null],"mappings":"AAAO,SAASA,OAAOC,OAAA,EAAwB;EAC7CC,OAAA,CAAQC,IAAA,CAAK,OAAO;AACtB","ignoreList":[]}
1
+ {
2
+ "version": 3,
3
+ "sources": ["../../src/Users/n8/one/packages/one/src/render.native.tsx"],
4
+ "mappings": "AAAO,SAASA,OAAOC,SAAwB;AAC7CC,UAAQC,KAAK,OAAO;AACtB;",
5
+ "names": ["render", "element", "console", "warn"]
6
+ }
@@ -1,2 +1 @@
1
-
2
- //# sourceMappingURL=RouterStore.native.js.map
1
+ //# sourceMappingURL=RouterStore.js.map
@@ -1 +1,6 @@
1
- {"version":3,"names":[],"sources":[],"sourcesContent":[],"mappings":"","ignoreList":[]}
1
+ {
2
+ "version": 3,
3
+ "sources": [],
4
+ "mappings": "",
5
+ "names": []
6
+ }
@@ -1,3 +1,5 @@
1
1
  var CACHE_KEY = `${Math.random()}`.slice(3);
2
- export { CACHE_KEY };
3
- //# sourceMappingURL=constants.native.js.map
2
+ export {
3
+ CACHE_KEY
4
+ };
5
+ //# sourceMappingURL=constants.js.map
@@ -1 +1,6 @@
1
- {"version":3,"names":["CACHE_KEY","Math","random","slice"],"sources":["../../../src/router/constants.ts"],"sourcesContent":[null],"mappings":"AAGO,IAAAA,SAAM,MAAYC,IAAG,CAAAC,MAAK,IAAQ,CAAAC,KAAG,GAAM","ignoreList":[]}
1
+ {
2
+ "version": 3,
3
+ "sources": ["../../../src/router/Users/n8/one/packages/one/src/router/constants.ts"],
4
+ "mappings": "AAGO,IAAMA,YAAY,GAAGC,KAAKC,OAAM,CAAA,GAAKC,MAAM,CAAA;",
5
+ "names": ["CACHE_KEY", "Math", "random", "slice"]
6
+ }
@@ -1,31 +1,32 @@
1
- import { stripBaseUrl } from "../fork/getStateFromPath.native.js";
1
+ import { stripBaseUrl } from "../fork/getStateFromPath";
2
2
  function getNormalizedStatePath(param, baseUrl) {
3
- var {
4
- path: statePath,
5
- params
6
- } = param,
7
- [pathname] = statePath.split("?");
3
+ var { path: statePath, params } = param, [pathname] = statePath.split("?");
8
4
  return {
9
5
  // Strip empty path at the start
10
6
  segments: stripBaseUrl(pathname, baseUrl).split("/").filter(Boolean).map(decodeURIComponent),
11
7
  // TODO: This is not efficient, we should generate based on the state instead
12
8
  // of converting to string then back to object
13
- params: Object.entries(params).reduce(function (prev, param2) {
9
+ params: Object.entries(params).reduce(function(prev, param2) {
14
10
  var [key, value] = param2;
15
- if (Array.isArray(value)) prev[key] = value.map(function (v) {
11
+ if (Array.isArray(value))
12
+ prev[key] = value.map(function(v) {
13
+ try {
14
+ return decodeURIComponent(v);
15
+ } catch {
16
+ return v;
17
+ }
18
+ });
19
+ else
16
20
  try {
17
- return decodeURIComponent(v);
21
+ prev[key] = decodeURIComponent(value);
18
22
  } catch {
19
- return v;
23
+ prev[key] = value;
20
24
  }
21
- });else try {
22
- prev[key] = decodeURIComponent(value);
23
- } catch {
24
- prev[key] = value;
25
- }
26
25
  return prev;
27
26
  }, {})
28
27
  };
29
28
  }
30
- export { getNormalizedStatePath };
31
- //# sourceMappingURL=getNormalizedStatePath.native.js.map
29
+ export {
30
+ getNormalizedStatePath
31
+ };
32
+ //# sourceMappingURL=getNormalizedStatePath.js.map
@@ -1 +1,6 @@
1
- {"version":3,"names":["stripBaseUrl","getNormalizedStatePath","param","baseUrl","path","statePath","params","pathname","split","segments","filter","Boolean","map","decodeURIComponent","Object","entries","reduce","prev","param2","key","value","Array","isArray","v"],"sources":["../../../src/router/getNormalizedStatePath.tsx"],"sourcesContent":[null],"mappings":"AAAA,SAASA,YAAA,QAAoB;AAatB,SAASC,uBACdC,KAAA,EAAAC,OAAA;EACE;MAAMC,IAAA,EAAAC,SAAA;MAAAC;IAAA,IAAAJ,KAAA;IAAA,CAAAK,QAAA,IAAAF,SAAA,CAAAG,KAAA;EACN;IAKF;IAEAC,QAAO,EAAAT,YAAY,CAAAO,QAAU,EAAMJ,OAAG,EAAAK,KAAA,MAAAE,MAAA,CAAAC,OAAA,EAAAC,GAAA,CAAAC,kBAAA;IACtC;IAAO;IAELP,MAAA,EAAAQ,MAAU,CAAAC,OAAA,CAAaT,MAAA,EAAAU,MAAU,WAASC,IAAS,EAAEC,MAAA,EAAO;MAA+B,KAAAC,GAAA,EAAAC,KAAA,IAAAF,MAAA;MAAA,IAAAG,KAAA,CAAAC,OAAA,CAAAF,KAAA,GAG3FH,IAAQ,CAAAE,GAAA,IAAOC,KAAA,CAAAR,GAAQ,WAAQW,CAAA,EAAO;QAChC;UACF,OAAQV,kBAA6B,CAAAU,CAAA;QACnC,QAAI;UACF,OAAOA,CAAA;QACT;MACE,QAEJ,IAAC;QAAAN,IAAA,CAAAE,GAAA,IAAAN,kBAAA,CAAAO,KAAA;MAED,QAAI;QACFH,IAAA,CAAKE,GAAG,IAAIC,KAAA;MACd;MACE,OAAAH,IAAK;IAAO,IACd;EAEF;AAAO;AACY,SAEzBhB,sBAAA","ignoreList":[]}
1
+ {
2
+ "version": 3,
3
+ "sources": ["../../../src/router/Users/n8/one/packages/one/src/router/getNormalizedStatePath.tsx"],
4
+ "mappings": "AAAA,SAASA,oBAAoB;AAatB,SAASC,uBACd,OAOAC,SAAgB;MAPhB,EACEC,MAAMC,WACNC,OAAM,IAFR,OASM,CAACC,QAAAA,IAAYF,UAAUG,MAAM,GAAA;AACnC,SAAO;;IAELC,UAAUR,aAAaM,UAAUJ,OAAAA,EAASK,MAAM,GAAA,EAAKE,OAAOC,OAAAA,EAASC,IAAIC,kBAAAA;;;IAGzEP,QAAQQ,OAAOC,QAAQT,MAAAA,EAAQU,OAAO,SAACC,MAAAA,QAAAA;UAAM,CAACC,KAAKC,KAAAA,IAAMC;AACvD,UAAIC,MAAMC,QAAQH,KAAAA;AAChBF,aAAKC,GAAAA,IAAOC,MAAMP,IAAI,SAACW,GAAAA;AACrB,cAAI;AACF,mBAAOV,mBAAmBU,CAAAA;UAC5B,QAAQ;AACN,mBAAOA;UACT;QACF,CAAA;;AAEA,YAAI;AACFN,eAAKC,GAAAA,IAAOL,mBAAmBM,KAAAA;QACjC,QAAQ;AACNF,eAAKC,GAAAA,IAAOC;QACd;AAEF,aAAOF;IACT,GAAG,CAAC,CAAA;EACN;AACF;",
5
+ "names": ["stripBaseUrl", "getNormalizedStatePath", "baseUrl", "path", "statePath", "params", "pathname", "split", "segments", "filter", "Boolean", "map", "decodeURIComponent", "Object", "entries", "reduce", "prev", "key", "value", "param", "Array", "isArray", "v"]
6
+ }
@@ -1,9 +1,10 @@
1
- var lastUserRouteAction = Date.now(),
2
- getLastAction = function () {
3
- return lastUserRouteAction;
4
- },
5
- setLastAction = function () {
6
- lastUserRouteAction = Date.now();
7
- };
8
- export { getLastAction, setLastAction };
9
- //# sourceMappingURL=lastAction.native.js.map
1
+ var lastUserRouteAction = Date.now(), getLastAction = function() {
2
+ return lastUserRouteAction;
3
+ }, setLastAction = function() {
4
+ lastUserRouteAction = Date.now();
5
+ };
6
+ export {
7
+ getLastAction,
8
+ setLastAction
9
+ };
10
+ //# sourceMappingURL=lastAction.js.map
@@ -1 +1,6 @@
1
- {"version":3,"names":["lastUserRouteAction","Date","now","getLastAction","setLastAction"],"sources":["../../../src/router/lastAction.ts"],"sourcesContent":[null],"mappings":"AAAA,IAAIA,mBAAA,GAAsBC,IAAA,CAAKC,GAAA,CAAI;EAAAC,aAAA,YAAAA,CAAA;IAE5B,OAAMH,mBAAsB;EAEjC;EAAAI,aAAA,YAAAA,CAAA,EAA2B;IAC7BJ,mBAAA,GAAAC,IAAA,CAAAC,GAAA","ignoreList":[]}
1
+ {
2
+ "version": 3,
3
+ "sources": ["../../../src/router/Users/n8/one/packages/one/src/router/lastAction.ts"],
4
+ "mappings": "AAAA,IAAIA,sBAAsBC,KAAKC,IAAG,GAErBC,gBAAgB,WAAA;SAAMH;GACtBI,gBAAgB,WAAA;AAC3BJ,wBAAsBC,KAAKC,IAAG;AAChC;",
5
+ "names": ["lastUserRouteAction", "Date", "now", "getLastAction", "setLastAction"]
6
+ }