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,118 +1,126 @@
1
1
  import { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from "react/jsx-runtime";
2
2
  import { Fragment, useEffect, useState } from "react";
3
- import { useViteRoutes } from "./useViteRoutes.native.js";
4
- import { RootErrorBoundary } from "./views/RootErrorBoundary.native.js";
3
+ import { useViteRoutes } from "./useViteRoutes";
4
+ import { RootErrorBoundary } from "./views/RootErrorBoundary";
5
5
  import { DarkTheme, DefaultTheme } from "@react-navigation/native";
6
6
  import { SafeAreaProviderCompat } from "@react-navigation/elements";
7
7
  import { useColorScheme } from "@vxrn/universal-color-scheme";
8
- import UpstreamNavigationContainer from "./fork/NavigationContainer.native.js";
9
- import { ServerLocationContext } from "./router/serverLocationContext.native.js";
10
- import { useInitializeOneRouter } from "./router/useInitializeOneRouter.native.js";
11
- import { PreloadLinks } from "./views/PreloadLinks.native.js";
12
- import { ScrollRestoration } from "./views/ScrollRestoration.native.js";
13
- import { rand } from "./utils/rand.native.js";
14
- typeof window < "u" && (window.__getReactRefreshIgnoredExports = function () {
15
- return ["feedCardQuery", "feedCardReplyQuery", "loader"];
8
+ import UpstreamNavigationContainer from "./fork/NavigationContainer";
9
+ import { ServerLocationContext } from "./router/serverLocationContext";
10
+ import { useInitializeOneRouter } from "./router/useInitializeOneRouter";
11
+ import { PreloadLinks } from "./views/PreloadLinks";
12
+ import { ScrollRestoration } from "./views/ScrollRestoration";
13
+ import { rand } from "./utils/rand";
14
+ typeof window < "u" && (window.__getReactRefreshIgnoredExports = function() {
15
+ return [
16
+ "feedCardQuery",
17
+ "feedCardReplyQuery",
18
+ "loader"
19
+ ];
16
20
  });
17
21
  function Root(props) {
18
- var _loaderData_constructor,
19
- _props_css,
20
- contents =
22
+ var _loaderData_constructor, _props_css, contents = (
21
23
  // <StrictMode>
22
- /* @__PURE__ */
23
- _jsxs(RootErrorBoundary, {
24
- children: [/* for some reason warning if no key here */
25
- /* @__PURE__ */_jsx(Contents, {
26
- ...props
27
- }, "contents"), /* @__PURE__ */_jsx(PreloadLinks, {}, "preload-links")]
28
- });
24
+ /* @__PURE__ */ _jsxs(RootErrorBoundary, {
25
+ children: [
26
+ /* for some reason warning if no key here */
27
+ /* @__PURE__ */ _jsx(Contents, {
28
+ ...props
29
+ }, "contents"),
30
+ /* @__PURE__ */ _jsx(PreloadLinks, {}, "preload-links")
31
+ ]
32
+ })
33
+ );
29
34
  if (props.isClient) {
30
35
  if (globalThis.__vxrnHydrateMode__ === "spa") {
31
36
  var [show, setShow] = useState(!1);
32
- return useEffect(function () {
37
+ return useEffect(function() {
33
38
  setShow(!0);
34
39
  }, []), show ? contents : null;
35
40
  }
36
41
  return contents;
37
42
  }
38
- var {
39
- loaderData
40
- } = props;
41
- return (loaderData == null || (_loaderData_constructor = loaderData.constructor) === null || _loaderData_constructor === void 0 ? void 0 : _loaderData_constructor.name) === "QueryImpl" && (loaderData = void 0), /* @__PURE__ */_jsxs("html", {
43
+ var { loaderData } = props;
44
+ return (loaderData == null || (_loaderData_constructor = loaderData.constructor) === null || _loaderData_constructor === void 0 ? void 0 : _loaderData_constructor.name) === "QueryImpl" && (loaderData = void 0), /* @__PURE__ */ _jsxs("html", {
42
45
  lang: "en-US",
43
- children: [/* @__PURE__ */_jsxs("head", {
44
- children: [process.env.NODE_ENV === "development" ? /* @__PURE__ */_jsx(DevHead, {}) : null, /* @__PURE__ */_jsx("script", {
46
+ children: [
47
+ /* @__PURE__ */ _jsxs("head", {
48
+ children: [
49
+ process.env.NODE_ENV === "development" ? /* @__PURE__ */ _jsx(DevHead, {}) : null,
50
+ /* @__PURE__ */ _jsx("script", {
51
+ dangerouslySetInnerHTML: {
52
+ __html: "globalThis['global'] = globalThis"
53
+ }
54
+ }),
55
+ (_props_css = props.css) === null || _props_css === void 0 ? void 0 : _props_css.map(function(file) {
56
+ return /* @__PURE__ */ _jsx("link", {
57
+ rel: "stylesheet",
58
+ href: file
59
+ }, file);
60
+ })
61
+ ]
62
+ }),
63
+ /* @__PURE__ */ _jsx("body", {
64
+ children: contents
65
+ }),
66
+ /* could this just be loaded via the same loader.js? as a preload? i think so... */
67
+ /* @__PURE__ */ _jsx("script", {
68
+ async: !0,
69
+ // @ts-ignore
70
+ href: "one-loader-data",
45
71
  dangerouslySetInnerHTML: {
46
- __html: "globalThis['global'] = globalThis"
47
- }
48
- }), (_props_css = props.css) === null || _props_css === void 0 ? void 0 : _props_css.map(function (file) {
49
- return /* @__PURE__ */_jsx("link", {
50
- rel: "stylesheet",
51
- href: file
52
- }, file);
53
- })]
54
- }), /* @__PURE__ */_jsx("body", {
55
- children: contents
56
- }), /* could this just be loaded via the same loader.js? as a preload? i think so... */
57
- /* @__PURE__ */_jsx("script", {
58
- async: !0,
59
- // @ts-ignore
60
- href: "one-loader-data",
61
- dangerouslySetInnerHTML: {
62
- __html: `
72
+ __html: `
63
73
  globalThis['__vxrnPostRenderData__'] = { __vxrn__: 'post-render' };
64
74
  globalThis['__vxrnLoaderData__'] = ${JSON.stringify(loaderData)};
65
75
  globalThis['__vxrnLoaderProps__'] = ${JSON.stringify(props.loaderProps)};
66
76
  globalThis['__vxrnHydrateMode__'] = ${JSON.stringify(props.mode)};
67
77
  `
68
- }
69
- })]
78
+ }
79
+ })
80
+ ]
70
81
  });
71
82
  }
72
83
  var ssrCSSID = `/@id/__x00__virtual:ssr-css.css?t=${rand()}`;
73
84
  function DevHead() {
74
- return /* @__PURE__ */_jsxs(_Fragment, {
75
- children: [/* @__PURE__ */_jsx("link", {
76
- rel: "preload",
77
- href: ssrCSSID,
78
- as: "style"
79
- }), /* @__PURE__ */_jsx("link", {
80
- rel: "stylesheet",
81
- href: ssrCSSID,
82
- "data-ssr-css": !0
83
- }), /* @__PURE__ */_jsx("script", {
84
- type: "module",
85
- dangerouslySetInnerHTML: {
86
- __html: `import { createHotContext } from "/@vite/client";
85
+ return /* @__PURE__ */ _jsxs(_Fragment, {
86
+ children: [
87
+ /* @__PURE__ */ _jsx("link", {
88
+ rel: "preload",
89
+ href: ssrCSSID,
90
+ as: "style"
91
+ }),
92
+ /* @__PURE__ */ _jsx("link", {
93
+ rel: "stylesheet",
94
+ href: ssrCSSID,
95
+ "data-ssr-css": !0
96
+ }),
97
+ /* @__PURE__ */ _jsx("script", {
98
+ type: "module",
99
+ dangerouslySetInnerHTML: {
100
+ __html: `import { createHotContext } from "/@vite/client";
87
101
  const hot = createHotContext("/__clear_ssr_css");
88
102
  hot.on("vite:afterUpdate", () => {
89
103
  document
90
104
  .querySelectorAll("[data-ssr-css]")
91
105
  .forEach(node => node.remove());
92
106
  });`
93
- }
94
- }), /* @__PURE__ */_jsx("script", {
95
- type: "module",
96
- dangerouslySetInnerHTML: {
97
- __html: `import { injectIntoGlobalHook } from "/@react-refresh";
107
+ }
108
+ }),
109
+ /* @__PURE__ */ _jsx("script", {
110
+ type: "module",
111
+ dangerouslySetInnerHTML: {
112
+ __html: `import { injectIntoGlobalHook } from "/@react-refresh";
98
113
  injectIntoGlobalHook(window);
99
114
  window.$RefreshReg$ = () => {};
100
115
  window.$RefreshSig$ = () => (type) => type;`
101
- }
102
- })]
116
+ }
117
+ })
118
+ ]
103
119
  });
104
120
  }
105
121
  function Contents(param) {
106
- var {
107
- routes,
108
- path,
109
- wrapper = Fragment,
110
- routeOptions,
111
- ...props
112
- } = param,
113
- context = useViteRoutes(routes, routeOptions, globalThis.__vxrnVersion),
114
- location = typeof window < "u" && window.location ? new URL(path || window.location.href || "/", window.location.href) : new URL(path || "/", "http://localhost");
115
- return /* @__PURE__ */_jsx(ContextNavigator, {
122
+ var { routes, path, wrapper = Fragment, routeOptions, ...props } = param, context = useViteRoutes(routes, routeOptions, globalThis.__vxrnVersion), location = typeof window < "u" && window.location ? new URL(path || window.location.href || "/", window.location.href) : new URL(path || "/", "http://localhost");
123
+ return /* @__PURE__ */ _jsx(ContextNavigator, {
116
124
  ...props,
117
125
  location,
118
126
  context,
@@ -120,26 +128,21 @@ function Contents(param) {
120
128
  });
121
129
  }
122
130
  function ContextNavigator(param) {
123
- var {
124
- wrapper: ParentWrapper = Fragment,
125
- context,
126
- location: initialLocation,
127
- navigationContainerProps
128
- } = param,
129
- store = useInitializeOneRouter(context, initialLocation),
130
- [colorScheme] = useColorScheme(),
131
- wrapper = function (children) {
132
- return /* @__PURE__ */_jsxs(ParentWrapper, {
133
- children: [/* default scroll restoration to on, but users can configure it by importing and using themselves */
134
- /* @__PURE__ */_jsx(ScrollRestoration, {}), /* <GestureHandlerRootView> */
135
- /* @__PURE__ */_jsx(SafeAreaProviderCompat, {
131
+ var { wrapper: ParentWrapper = Fragment, context, location: initialLocation, navigationContainerProps } = param, store = useInitializeOneRouter(context, initialLocation), [colorScheme] = useColorScheme(), wrapper = function(children) {
132
+ return /* @__PURE__ */ _jsxs(ParentWrapper, {
133
+ children: [
134
+ /* default scroll restoration to on, but users can configure it by importing and using themselves */
135
+ /* @__PURE__ */ _jsx(ScrollRestoration, {}),
136
+ /* <GestureHandlerRootView> */
137
+ /* @__PURE__ */ _jsx(SafeAreaProviderCompat, {
136
138
  children
137
- })]
138
- });
139
- },
140
- Component = store.rootComponent;
141
- if (!Component) throw new Error("No root component found");
142
- return /* @__PURE__ */_jsx(UpstreamNavigationContainer, {
139
+ })
140
+ ]
141
+ });
142
+ }, Component = store.rootComponent;
143
+ if (!Component)
144
+ throw new Error("No root component found");
145
+ return /* @__PURE__ */ _jsx(UpstreamNavigationContainer, {
143
146
  ref: store.navigationRef,
144
147
  initialState: store.initialState,
145
148
  linking: store.linking,
@@ -149,16 +152,15 @@ function ContextNavigator(param) {
149
152
  enabled: !1
150
153
  },
151
154
  ...navigationContainerProps,
152
- children: /* @__PURE__ */_jsx(ServerLocationContext.Provider, {
155
+ children: /* @__PURE__ */ _jsx(ServerLocationContext.Provider, {
153
156
  value: initialLocation,
154
- children: wrapper(/* @__PURE__ */_jsx(Component, {}))
157
+ children: wrapper(/* @__PURE__ */ _jsx(Component, {}))
155
158
  })
156
159
  });
157
160
  }
158
161
  var onUnhandledAction;
159
- process.env.NODE_ENV !== "production" ? onUnhandledAction = function (action) {
160
- var payload = action.payload,
161
- message = `The action '${action.type}'${payload ? ` with payload ${JSON.stringify(action.payload)}` : ""} was not handled by any navigator.`;
162
+ process.env.NODE_ENV !== "production" ? onUnhandledAction = function(action) {
163
+ var payload = action.payload, message = `The action '${action.type}'${payload ? ` with payload ${JSON.stringify(action.payload)}` : ""} was not handled by any navigator.`;
162
164
  switch (action.type) {
163
165
  case "NAVIGATE":
164
166
  case "PUSH":
@@ -187,8 +189,12 @@ Is your screen inside a Drawer navigator?`;
187
189
  }
188
190
  if (message += `
189
191
 
190
- This is a development-only warning and won't be shown in production.`, process.env.NODE_ENV === "test") throw new Error(message);
192
+ This is a development-only warning and won't be shown in production.`, process.env.NODE_ENV === "test")
193
+ throw new Error(message);
191
194
  console.error(message);
192
- } : onUnhandledAction = function () {};
193
- export { Root };
194
- //# sourceMappingURL=Root.native.js.map
195
+ } : onUnhandledAction = function() {
196
+ };
197
+ export {
198
+ Root
199
+ };
200
+ //# sourceMappingURL=Root.js.map
@@ -1 +1,6 @@
1
- {"version":3,"names":["jsx","_jsx","jsxs","_jsxs","Fragment","_Fragment","useEffect","useState","useViteRoutes","RootErrorBoundary","DarkTheme","DefaultTheme","SafeAreaProviderCompat","useColorScheme","UpstreamNavigationContainer","ServerLocationContext","useInitializeOneRouter","PreloadLinks","ScrollRestoration","rand","window","__getReactRefreshIgnoredExports","Root","props","_loaderData_constructor","_props_css","contents","children","Contents","isClient","globalThis","__vxrnHydrateMode__","show","setShow","loaderData","constructor","name","lang","process","env","NODE_ENV","DevHead","dangerouslySetInnerHTML","__html","css","map","file","rel","href","async","JSON","stringify","loaderProps","mode","ssrCSSID","as","type","param","routes","path","wrapper","routeOptions","context","__vxrnVersion","location","URL","ContextNavigator","ParentWrapper","initialLocation","navigationContainerProps","store","colorScheme","Component","rootComponent","Error","ref","navigationRef","initialState","linking","onUnhandledAction","theme","documentTitle","enabled","Provider","value","action","payload","message"],"sources":["../../src/Root.tsx"],"sourcesContent":[null],"mappings":"AAAA,SAASA,GAAA,IAAAC,IAAU,EAAAC,IAAA,IAAWC,KAAA,EAAAC,QAAA,IAAwDC,SAAA;AAEtF,SAASD,QAAA,EAAAE,SAAA,EAAqBC,QAAA;AAC9B,SAASC,aAAA,mCAAyB;AAElC,SAAAC,iBAAA;AAAA,SACEC,SAAA,EAAAC,YAAA;AAAA,SACAC,sBAAA;AAAA,SAGKC,cAAA;AACP,OAAAC,2BAAS,MAA8B;AACvC,SAASC,qBAAA,QAAsB;AAC/B,SAAOC,sBAAA,mDAAiC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A,iBAAW;;;AACX;EACJ;AAIA,MAFAA,WAAW;;uEAEPpD,QAAQC,IAAIC,aAAa;AAC3B,UAAM,IAAIqC,MAAMa,OAAAA;AAElBC,UAAQC,MAAMF,OAAAA;AAChB,IAEAR,oBAAoB,WAAA;AAAO;",
5
+ "names": ["Fragment", "useEffect", "useState", "useViteRoutes", "RootErrorBoundary", "DarkTheme", "DefaultTheme", "SafeAreaProviderCompat", "useColorScheme", "UpstreamNavigationContainer", "ServerLocationContext", "useInitializeOneRouter", "PreloadLinks", "ScrollRestoration", "rand", "window", "__getReactRefreshIgnoredExports", "Root", "props", "loaderData", "contents", "Contents", "isClient", "globalThis", "show", "setShow", "constructor", "name", "undefined", "html", "lang", "head", "process", "env", "NODE_ENV", "DevHead", "script", "dangerouslySetInnerHTML", "__html", "css", "map", "file", "link", "rel", "href", "body", "async", "JSON", "stringify", "loaderProps", "mode", "ssrCSSID", "as", "data-ssr-css", "type", "routes", "path", "wrapper", "routeOptions", "context", "location", "URL", "ContextNavigator", "ParentWrapper", "initialLocation", "navigationContainerProps", "store", "colorScheme", "children", "Component", "rootComponent", "Error", "ref", "navigationRef", "initialState", "linking", "onUnhandledAction", "theme", "documentTitle", "enabled", "Provider", "value", "action", "payload", "message", "console", "error"]
6
+ }
@@ -1,25 +1,27 @@
1
1
  import { jsx as _jsx } from "react/jsx-runtime";
2
2
  import React, { useContext } from "react";
3
- import { getContextKey } from "./matchers.native.js";
4
- var CurrentRouteContext = /* @__PURE__ */React.createContext(null);
3
+ import { getContextKey } from "./matchers";
4
+ var CurrentRouteContext = /* @__PURE__ */ React.createContext(null);
5
5
  process.env.NODE_ENV !== "production" && (CurrentRouteContext.displayName = "RouteNode");
6
6
  function useRouteNode() {
7
7
  return useContext(CurrentRouteContext);
8
8
  }
9
9
  function useContextKey() {
10
10
  var node = useRouteNode();
11
- if (node == null) throw new Error("No filename found. This is likely a bug in router.");
11
+ if (node == null)
12
+ throw new Error("No filename found. This is likely a bug in router.");
12
13
  return getContextKey(node.contextKey);
13
14
  }
14
15
  function Route(param) {
15
- var {
16
- children,
17
- node
18
- } = param;
19
- return /* @__PURE__ */_jsx(CurrentRouteContext.Provider, {
16
+ var { children, node } = param;
17
+ return /* @__PURE__ */ _jsx(CurrentRouteContext.Provider, {
20
18
  value: node,
21
19
  children
22
20
  });
23
21
  }
24
- export { Route, useContextKey, useRouteNode };
25
- //# sourceMappingURL=Route.native.js.map
22
+ export {
23
+ Route,
24
+ useContextKey,
25
+ useRouteNode
26
+ };
27
+ //# sourceMappingURL=Route.js.map
@@ -1 +1,6 @@
1
- {"version":3,"names":["jsx","_jsx","React","useContext","getContextKey","CurrentRouteContext","createContext","process","env","NODE_ENV","displayName","useRouteNode","useContextKey","node","Error","contextKey","Route","param","children","Provider"],"sources":["../../src/Route.tsx"],"sourcesContent":[null],"mappings":"AAAA,SAAOA,GAAA,IAASC,IAAA,2BAAkC;AAElD,OAAAC,KAAS,IAAAC,UAAA,QAAqB;AAiErB,SAAAC,aAAA;AArBT,IAAAC,mBAAM,kBAA4BH,KAAA,CAAgCI,aAAI;AAElEC,OAAA,CAAQC,GAAA,CAAIC,QAAA,KAAa,iBAC3BJ,mBAAA,CAAoBK,WAAA,GAAc;AAI7B,SAASC,aAAA,EAAiC;EAC/C,OAAOR,UAAA,CAAWE,mBAAmB;AACvC;AAEO,SAASO,cAAA,EAAwB;EACtC,IAAAC,IAAM,GAAAF,YAAO;EACb,IAAIE,IAAA,IAAQ,MACV,MAAM,IAAIC,KAAA,CAAM,oDAAoD;EAEtE,OAAOV,aAAA,CAAcS,IAAA,CAAKE,UAAU;AACtC;AAGO,SAASC,MAAMC,KAAE;EACtB;IAAAC,QAAO;IAAAL;EAAA,IAAAI,KAAC;EACV,sBAAAhB,IAAA,CAAAI,mBAAA,CAAAc,QAAA","ignoreList":[]}
1
+ {
2
+ "version": 3,
3
+ "sources": ["../../src/Users/n8/one/packages/one/src/Route.tsx"],
4
+ "mappings": ";AAAA,OAAOA,SAASC,kBAAkC;AAElD,SAASC,qBAAqB;AA4C9B,IAAMC,sBAAsBH,sBAAMI,cAAgC,IAAA;AAE9DC,QAAQC,IAAIC,aAAa,iBAC3BJ,oBAAoBK,cAAc;AAI7B,SAASC,eAAAA;AACd,SAAOR,WAAWE,mBAAAA;AACpB;AAEO,SAASO,gBAAAA;AACd,MAAMC,OAAOF,aAAAA;AACb,MAAIE,QAAQ;AACV,UAAM,IAAIC,MAAM,oDAAA;AAElB,SAAOV,cAAcS,KAAKE,UAAU;AACtC;AAGO,SAASC,MAAM,OAA4D;MAA5D,EAAEC,UAAUJ,KAAI,IAAhB;AACpB,SAAO,qBAACR,oBAAoBa,UAAQ;IAACC,OAAON;;;AAC9C;",
5
+ "names": ["React", "useContext", "getContextKey", "CurrentRouteContext", "createContext", "process", "env", "NODE_ENV", "displayName", "useRouteNode", "useContextKey", "node", "Error", "contextKey", "Route", "children", "Provider", "value"]
6
+ }
@@ -18,7 +18,7 @@ function getLoaderPath(currentPath, includeUrl = isNative) {
18
18
  return `${baseURL}${devPath}/assets/${cleanUrl(currentPathUrl.pathname.slice(1))}_vxrn_loader.js${getSearchParams(currentPathUrl.search)}`;
19
19
  }
20
20
  function getPathFromLoaderPath(loaderPath) {
21
- return loaderPath.replace("_vxrn_loader.js", "").replace(/^(\/_one)?\/assets/, "").replace("_", "/");
21
+ return loaderPath.replace("_vxrn_loader.js", "").replace(/^(\/_one)?\/assets/, "").replaceAll(/_/g, "/");
22
22
  }
23
23
  function getSearchParams(searchParams) {
24
24
  return searchParams ? `${searchParams}&${clientSideSearch.slice(1)}` : clientSideSearch;
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "version": 3,
3
3
  "sources": ["../../src/cleanUrl.ts"],
4
- "mappings": "AAAA,SAAS,gBAAgB;AACzB,SAAS,cAAc;AACvB,SAAS,iBAAiB;AAC1B,SAAS,oBAAoB;AAE7B,SAAS,SAAS,MAAc;AAC9B,SACE,aAAa,IAAI,EACd,WAAW,KAAK,GAAG,EAEnB,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,UAAU,aAAa,OAAO,IAAI,IAClC,UAAU,QAAQ,IAAI,aAAa,gBAAgB,UAAU,IAE7D,iBAAiB,IAAI;AAAA,IACzB;AAAA,IACA;AAAA;AAAA,EACF;AAEA,SAAO,GAAG,OAAO,GAAG,OAAO,WAAW,SAAS,eAAe,SAAS,MAAM,CAAC,CAAC,CAAC,kBAAkB,gBAAgB,eAAe,MAAM,CAAC;AAC1I;AAEO,SAAS,sBAAsB,YAAoB;AACxD,SAAO,WACJ,QAAQ,mBAAmB,EAAE,EAC7B,QAAQ,sBAAsB,EAAE,EAChC,WAAW,MAAM,GAAG;AACzB;AAEA,SAAS,gBAAgB,cAAc;AACrC,SAAK,eAIE,GAAG,YAAY,IAAI,iBAAiB,MAAM,CAAC,CAA8B,KAHvE;AAIX;",
5
5
  "names": []
6
6
  }
@@ -19,7 +19,7 @@ function getLoaderPath(currentPath, includeUrl = isNative) {
19
19
  return `${baseURL}${devPath}/assets/${cleanUrl(currentPathUrl.pathname.slice(1))}_vxrn_loader.js${getSearchParams(currentPathUrl.search)}`;
20
20
  }
21
21
  function getPathFromLoaderPath(loaderPath) {
22
- return loaderPath.replace("_vxrn_loader.js", "").replace(/^(\/_one)?\/assets/, "").replace("_", "/");
22
+ return loaderPath.replace("_vxrn_loader.js", "").replace(/^(\/_one)?\/assets/, "").replaceAll(/_/g, "/");
23
23
  }
24
24
  function getSearchParams(searchParams) {
25
25
  return searchParams ? `${searchParams}&${clientSideSearch.slice(1)}` : clientSideSearch;
@@ -1 +1 @@
1
- {"version":3,"names":["isNative","getURL","CACHE_KEY","removeSearch","cleanUrl","path","replaceAll","replace","isClient","window","clientSideSearch","clientSideURL","getPreloadPath","currentPath","slice","getLoaderPath","includeUrl","baseURL","devPath","process","env","NODE_ENV","currentPathUrl","URL","pathname","getSearchParams","search","getPathFromLoaderPath","loaderPath","searchParams"],"sources":["../../src/cleanUrl.ts"],"sourcesContent":[null],"mappings":"AAAA,SAASA,QAAA,QAAgB;AACzB,SAASC,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":[]}
1
+ {"version":3,"names":["isNative","getURL","CACHE_KEY","removeSearch","cleanUrl","path","replaceAll","replace","isClient","window","clientSideSearch","clientSideURL","getPreloadPath","currentPath","slice","getLoaderPath","includeUrl","baseURL","devPath","process","env","NODE_ENV","currentPathUrl","URL","pathname","getSearchParams","search","getPathFromLoaderPath","loaderPath","searchParams"],"sources":["../../src/cleanUrl.ts"],"sourcesContent":[null],"mappings":"AAAA,SAASA,QAAA,QAAgB;AACzB,SAASC,MAAA,QAAc;AACvB,SAASC,SAAA,QAAiB;AAC1B,SAASC,YAAA,QAAoB;AAE7B,SAASC,SAASC,IAAA,EAAc;EAC9B,OACEF,YAAA,CAAaE,IAAI,EACdC,UAAA,CAAW,KAAK,GAAG,EAEnBC,OAAA,CAAQ,MAAM,EAAE;AAEvB;AAEA,MAAMC,QAAA,GAAW,OAAOC,MAAA,GAAW;EAC7BC,gBAAA,GAAmBF,QAAA,GAAW,UAAUN,SAAS,KAAK;EACtDS,aAAA,GAAgBH,QAAA,GAAWP,MAAA,CAAO,IAAI;AAErC,SAASW,eAAeC,WAAA,EAAqB;EAClD,OAAO,GAAGF,aAAa,WAAWP,QAAA,CAASS,WAAA,CAAYC,KAAA,CAAM,CAAC,CAAC,CAAC,cAAcJ,gBAAgB;AAChG;AAEO,SAASK,cACdF,WAAA,EAEAG,UAAA,GAAahB,QAAA,EACb;EACA,MAAMiB,OAAA,GAAUD,UAAA,GAAaf,MAAA,CAAO,IAAI;IAClCiB,OAAA,GAAUC,OAAA,CAAQC,GAAA,CAAIC,QAAA,KAAa,gBAAgB,UAAU;IAE7DC,cAAA,GAAiB,IAAIC,GAAA,CACzBV,WAAA,EACA;IAAA,iDACF;EAEA,OAAO,GAAGI,OAAO,GAAGC,OAAO,WAAWd,QAAA,CAASkB,cAAA,CAAeE,QAAA,CAASV,KAAA,CAAM,CAAC,CAAC,CAAC,kBAAkBW,eAAA,CAAgBH,cAAA,CAAeI,MAAM,CAAC;AAC1I;AAEO,SAASC,sBAAsBC,UAAA,EAAoB;EACxD,OAAOA,UAAA,CACJrB,OAAA,CAAQ,mBAAmB,EAAE,EAC7BA,OAAA,CAAQ,sBAAsB,EAAE,EAChCD,UAAA,CAAW,MAAM,GAAG;AACzB;AAEA,SAASmB,gBAAgBI,YAAA,EAAc;EACrC,OAAKA,YAAA,GAIE,GAAGA,YAAY,IAAInB,gBAAA,CAAiBI,KAAA,CAAM,CAAC,CAA8B,KAHvEJ,gBAAA;AAIX","ignoreList":[]}
@@ -1,28 +1,27 @@
1
- import { isNative } from "./constants.native.js";
2
- import { getURL } from "./getURL.native.js";
3
- import { CACHE_KEY } from "./router/constants.native.js";
4
- import { removeSearch } from "./utils/removeSearch.native.js";
1
+ import { isNative } from "./constants";
2
+ import { getURL } from "./getURL";
3
+ import { CACHE_KEY } from "./router/constants";
4
+ import { removeSearch } from "./utils/removeSearch";
5
5
  function cleanUrl(path) {
6
6
  return removeSearch(path).replaceAll("/", "_").replace(/_$/, "");
7
7
  }
8
- var isClient = typeof window < "u",
9
- clientSideSearch = isClient ? `?cache=${CACHE_KEY}` : "",
10
- clientSideURL = isClient ? getURL() : "";
8
+ var isClient = typeof window < "u", clientSideSearch = isClient ? `?cache=${CACHE_KEY}` : "", clientSideURL = isClient ? getURL() : "";
11
9
  function getPreloadPath(currentPath) {
12
10
  return `${clientSideURL}/assets/${cleanUrl(currentPath.slice(1))}_preload.js${clientSideSearch}`;
13
11
  }
14
12
  function getLoaderPath(currentPath) {
15
- var includeUrl = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : isNative,
16
- baseURL = includeUrl ? getURL() : "",
17
- devPath = process.env.NODE_ENV === "development" ? "/_one" : "",
18
- currentPathUrl = new URL(currentPath, "http://example.com");
13
+ var includeUrl = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : isNative, baseURL = includeUrl ? getURL() : "", devPath = process.env.NODE_ENV === "development" ? "/_one" : "", currentPathUrl = new URL(currentPath, "http://example.com");
19
14
  return `${baseURL}${devPath}/assets/${cleanUrl(currentPathUrl.pathname.slice(1))}_vxrn_loader.js${getSearchParams(currentPathUrl.search)}`;
20
15
  }
21
16
  function getPathFromLoaderPath(loaderPath) {
22
- return loaderPath.replace("_vxrn_loader.js", "").replace(/^(\/_one)?\/assets/, "").replace("_", "/");
17
+ return loaderPath.replace("_vxrn_loader.js", "").replace(/^(\/_one)?\/assets/, "").replaceAll(/_/g, "/");
23
18
  }
24
19
  function getSearchParams(searchParams) {
25
20
  return searchParams ? `${searchParams}&${clientSideSearch.slice(1)}` : clientSideSearch;
26
21
  }
27
- export { getLoaderPath, getPathFromLoaderPath, getPreloadPath };
28
- //# sourceMappingURL=cleanUrl.native.js.map
22
+ export {
23
+ getLoaderPath,
24
+ getPathFromLoaderPath,
25
+ getPreloadPath
26
+ };
27
+ //# sourceMappingURL=cleanUrl.js.map
@@ -1 +1,6 @@
1
- {"version":3,"names":["isNative","getURL","CACHE_KEY","removeSearch","cleanUrl","path","replaceAll","replace","isClient","window","clientSideSearch","clientSideURL","getPreloadPath","currentPath","slice","getLoaderPath","includeUrl","arguments","length","baseURL","devPath","process","env","NODE_ENV","currentPathUrl","URL","pathname","getSearchParams","search","getPathFromLoaderPath","loaderPath","searchParams"],"sources":["../../src/cleanUrl.ts"],"sourcesContent":[null],"mappings":"AAAA,SAASA,QAAA,QAAgB;AACzB,SAASC,MAAA,QAAc;AACvB,SAASC,SAAA,QAAiB;AAC1B,SAASC,YAAA,QAAoB;AAE7B,SAASC,SAASC,IAAA,EAAc;EAC9B,OACEF,YAAA,CAAaE,IAAI,EACdC,UAAA,CAAW,KAAK,GAAG,EAEnBC,OAAA,CAAQ,MAAM,EAAE;AAEvB;AAEA,IAAAC,QAAM,UAAWC,MAAO,MAAW;EAAAC,gBAC7B,GAAAF,QAAmB,aAAWN,SAAU,EAAS,KAAK;EAAAS,aACtD,GAAAH,QAAgB,GAAAP,MAAW,KAAO,EAAI;AAErC,SAASW,eAAeC,WAAA,EAAqB;EAClD,OAAO,GAAG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P,SAASS,YAAYC,MAAM,CAAA,CAAA,CAAA,cAAiBJ,gBAAAA;AAChF;AAEO,SAASK,cACdF,aAAmB;MAEnBG,aAAAA,UAAAA,SAAAA,KAAAA,UAAAA,CAAAA,MAAAA,SAAAA,UAAAA,CAAAA,IAAahB,UAEPiB,UAAUD,aAAaf,OAAAA,IAAW,IAClCiB,UAAUC,QAAQC,IAAIC,aAAa,gBAAgB,UAAU,IAE7DC,iBAAiB,IAAIC,IACzBV,aACA,oBAAA;AAGF,SAAO,GAAGI,OAAAA,GAAUC,OAAAA,WAAkBd,SAASkB,eAAeE,SAASV,MAAM,CAAA,CAAA,CAAA,kBAAqBW,gBAAgBH,eAAeI,MAAM,CAAA;AACzI;AAEO,SAASC,sBAAsBC,YAAkB;AACtD,SAAOA,WACJrB,QAAQ,mBAAmB,EAAA,EAC3BA,QAAQ,sBAAsB,EAAA,EAC9BD,WAAW,MAAM,GAAA;AACtB;AAEA,SAASmB,gBAAgBI,cAAY;AACnC,SAAKA,eAIE,GAAGA,YAAAA,IAAgBnB,iBAAiBI,MAAM,CAAA,CAAA,KAHxCJ;AAIX;",
5
+ "names": ["isNative", "getURL", "CACHE_KEY", "removeSearch", "cleanUrl", "path", "replaceAll", "replace", "isClient", "window", "clientSideSearch", "clientSideURL", "getPreloadPath", "currentPath", "slice", "getLoaderPath", "includeUrl", "baseURL", "devPath", "process", "env", "NODE_ENV", "currentPathUrl", "URL", "pathname", "getSearchParams", "search", "getPathFromLoaderPath", "loaderPath", "searchParams"]
6
+ }
@@ -1,8 +1,9 @@
1
1
  import { homedir } from "node:os";
2
2
  function labelProcess(title) {
3
- var home = homedir(),
4
- cwd = process.cwd();
3
+ var home = homedir(), cwd = process.cwd();
5
4
  process.title = `Onejs:${title} > ${cwd.replace(home, "~")}`;
6
5
  }
7
- export { labelProcess };
8
- //# sourceMappingURL=label-process.native.js.map
6
+ export {
7
+ labelProcess
8
+ };
9
+ //# sourceMappingURL=label-process.js.map
@@ -1 +1,6 @@
1
- {"version":3,"names":["homedir","labelProcess","title","home","cwd","process","replace"],"sources":["../../../src/cli/label-process.ts"],"sourcesContent":[null],"mappings":"AAAA,SAASA,OAAA,QAAe;AAEjB,SAASC,aAAaC,KAAA,EAAe;EAC1C,IAAAC,IAAM,GAAAH,OAAO;IAAQI,GACf,GAAAC,OAAM,CAAAD,GAAQ;EACpBC,OAAA,CAAQH,KAAA,GAAQ,SAASA,KAAK,MAAME,GAAA,CAAIE,OAAA,CAAQH,IAAA,EAAM,GAAG,CAAC;AAC5D","ignoreList":[]}
1
+ {
2
+ "version": 3,
3
+ "sources": ["../../../src/cli/Users/n8/one/packages/one/src/cli/label-process.ts"],
4
+ "mappings": "AAAA,SAASA,eAAe;AAEjB,SAASC,aAAaC,OAAa;AACxC,MAAMC,OAAOH,QAAAA,GACPI,MAAMC,QAAQD,IAAG;AACvBC,UAAQH,QAAQ,SAASA,KAAAA,MAAWE,IAAIE,QAAQH,MAAM,GAAA,CAAA;AACxD;",
5
+ "names": ["homedir", "labelProcess", "title", "home", "cwd", "process", "replace"]
6
+ }
@@ -1,15 +1,10 @@
1
1
  import { existsSync } from "node:fs";
2
2
  import { createRequire } from "node:module";
3
- import { run } from "./run.native.js";
3
+ import { run } from "./run";
4
4
  async function getLatestVersion(packageName) {
5
- var require2 = createRequire(import.meta.url),
6
- _confuseDepCheck = require2,
7
- packageJson = _confuseDepCheck("one/package.json"),
8
- currentVersion = packageJson.version;
5
+ var require2 = createRequire(import.meta.url), _confuseDepCheck = require2, packageJson = _confuseDepCheck("one/package.json"), currentVersion = packageJson.version;
9
6
  try {
10
- var response = await fetch(`https://registry.npmjs.org/${packageName}`),
11
- data = await response.json(),
12
- latest = data["dist-tags"].latest;
7
+ var response = await fetch(`https://registry.npmjs.org/${packageName}`), data = await response.json(), latest = data["dist-tags"].latest;
13
8
  latest && currentVersion !== latest && (console.info(`
14
9
  \u2776 Update available: ${currentVersion} \u2192 ${latest}`), console.info(`Run "npx one@latest" or "npm install -g one@latest" to update globally.
15
10
  `));
@@ -20,10 +15,10 @@ async function getLatestVersion(packageName) {
20
15
  async function cliMain() {
21
16
  var args = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : {};
22
17
  getLatestVersion("one"), existsSync("vite.config.ts") && (await run(args), process.exit(0));
23
- var {
24
- create
25
- } = await import("create-vxrn/create");
18
+ var { create } = await import("create-vxrn/create");
26
19
  await create({});
27
20
  }
28
- export { cliMain };
29
- //# sourceMappingURL=main.native.js.map
21
+ export {
22
+ cliMain
23
+ };
24
+ //# sourceMappingURL=main.js.map
@@ -1 +1,6 @@
1
- {"version":3,"names":["existsSync","createRequire","run","getLatestVersion","packageName","require2","import","meta","url","_confuseDepCheck","packageJson","currentVersion","version","response","fetch","data","json","latest","console","info","error","cliMain","args","arguments","length","process","exit","create"],"sources":["../../../src/cli/main.ts"],"sourcesContent":[null],"mappings":"AAAA,SAASA,UAAA,QAAkB;AAC3B,SAASC,aAAA,QAAqB;AAC9B,SAASC,GAAA,QAAW;AAEpB,eAAeC,iBAAiBC,WAAA,EAAqB;EAInD,IAAAC,QAAM,GAAAJ,aAHU,CAAAK,MAAA,CAAAC,IAAc,CAAAC,GAAA;IAAAC,gBAEO,GAAAJ,QACF;IAAAK,WAAA,GAAAD,gBAAA;IAAAE,cAAA,GAAAD,WAAA,CAAAE,OAAA;EAEnC,IAAI;IAGF,IAAAC,QAAM,SADOC,KADI,+BAAYV,WAA8B;MAAAW,IAAW,GAAE,MACvCF,QACb,CAAAG,IAAA,CAAW;MAAEC,MAAA,GAAAF,IAAA,cAAAE,MAAA;IAE7BA,MAAA,IAAUN,cAAA,KAAmBM,MAAA,KAE/BC,OAAA,CAAQC,IAAA,CAAK;AAAA,2BAAyBR,cAAc,WAAMM,MAAM,EAAE,GAClEC,OAAA,CAAQC,IAAA,CAAK;AAAA,CAA2E;EAE5F,SAASC,KAAA,EAAO;IACdF,OAAA,CAAQE,KAAA,CAAM,uCAAuCA,KAAK;EAC5D;AACF;AAEA,eAAsBC,QAAA,EAAQ;EAEvB,IAAAC,IAAA,GAAAC,SAAiB,CAAAC,MAElB,QAAAD,SAAW,QAAgB,MAE7B,GAAAA,SAAU,EAAI,IACd;EAGFpB,gBAAe,MAAI,GAAMH,UAAO,iBAAoB,YAAAE,GAAA,CAAAoB,IAAA,GAAAG,OAAA,CAAAC,IAAA;EACpD;IAAMC;EAAO,CAAC,GAAC;EACjB,MAAAA,MAAA","ignoreList":[]}
1
+ {
2
+ "version": 3,
3
+ "sources": ["../../../src/cli/Users/n8/one/packages/one/src/cli/main.ts"],
4
+ "mappings": "AAAA,SAASA,kBAAkB;AAC3B,SAASC,qBAAqB;AAC9B,SAASC,WAAW;AAEpB,eAAeC,iBAAiBC,aAAmB;AACjD,MAAMC,WAAUJ,cAAc,YAAYK,GAAG,GACvCC,mBAAmBF,UACnBG,cAAcD,iBAAiB,kBAAA,GAC/BE,iBAAiBD,YAAYE;AAEnC,MAAI;AACF,QAAMC,WAAW,MAAMC,MAAM,8BAA8BR,WAAAA,EAAa,GAClES,OAAO,MAAMF,SAASG,KAAI,GAC1BC,SAASF,KAAK,WAAA,EAAaE;AAEjC,IAAIA,UAAUN,mBAAmBM,WAE/BC,QAAQC,KAAK;2BAAyBR,cAAAA,WAAoBM,MAAAA,EAAQ,GAClEC,QAAQC,KAAK;CAAA;EAEjB,SAASC,OAAO;AACdF,YAAQE,MAAM,uCAAuCA,KAAAA;EACvD;AACF;AAEA,eAAsBC,UAAAA;MAAQC,OAAAA,UAAAA,SAAAA,KAAAA,UAAAA,CAAAA,MAAAA,SAAAA,UAAAA,CAAAA,IAAO,CAAC;AAEpC,EAAKjB,iBAAiB,KAAA,GAElBH,WAAW,gBAAA,MAEb,MAAME,IAAIkB,IAAAA,GACVC,QAAQC,KAAK,CAAA;AAGf,MAAM,EAAEC,OAAM,IAAK,MAAM,OAAO,oBAAA;AAChC,QAAMA,OAAO,CAAC,CAAA;AAChB;",
5
+ "names": ["existsSync", "createRequire", "run", "getLatestVersion", "packageName", "require", "url", "_confuseDepCheck", "packageJson", "currentVersion", "version", "response", "fetch", "data", "json", "latest", "console", "info", "error", "cliMain", "args", "process", "exit", "create"]
6
+ }
@@ -1,10 +1,10 @@
1
1
  async function run(args) {
2
- var {
3
- prebuild
4
- } = await import("vxrn");
2
+ var { prebuild } = await import("vxrn");
5
3
  await prebuild({
6
4
  root: process.cwd()
7
5
  });
8
6
  }
9
- export { run };
10
- //# sourceMappingURL=prebuild.native.js.map
7
+ export {
8
+ run
9
+ };
10
+ //# sourceMappingURL=prebuild.js.map
@@ -1 +1,6 @@
1
- {"version":3,"names":["run","args","prebuild","root","process","cwd"],"sources":["../../../src/cli/prebuild.ts"],"sourcesContent":[null],"mappings":"AAAA,eAAsBA,IAAIC,IAAA,EAAU;EAClC;IAAMC;EAAE,IAAS,MAAI,MAAM,OAAO;EAClC,MAAMA,QAAA,CAAS;IACbC,IAAA,EAAMC,OAAA,CAAQC,GAAA,CAAI;EACpB,CAAC;AACH","ignoreList":[]}
1
+ {
2
+ "version": 3,
3
+ "sources": ["../../../src/cli/Users/n8/one/packages/one/src/cli/prebuild.ts"],
4
+ "mappings": "AAAA,eAAsBA,IAAIC,MAAQ;AAChC,MAAM,EAAEC,SAAQ,IAAK,MAAM,OAAO,MAAA;AAClC,QAAMA,SAAS;IACbC,MAAMC,QAAQC,IAAG;EACnB,CAAA;AACF;",
5
+ "names": ["run", "args", "prebuild", "root", "process", "cwd"]
6
+ }
@@ -1,35 +1,28 @@
1
- import { virtualEntryIdNative } from "../vite/virtualEntryPlugin.native.js";
2
- import { labelProcess } from "./label-process.native.js";
1
+ import { virtualEntryIdNative } from "../vite/virtualEntryPlugin";
2
+ import { labelProcess } from "./label-process";
3
3
  async function run(args) {
4
4
  labelProcess("dev");
5
- var {
6
- dev
7
- } = await import("vxrn"),
8
- {
9
- start,
10
- stop
11
- } = await dev({
12
- clean: args.clean,
13
- root: process.cwd(),
14
- server: {
15
- https: args.https,
16
- host: args.host,
17
- port: args.port ? +args.port : void 0
18
- },
19
- entries: {
20
- native: virtualEntryIdNative
21
- }
22
- }),
23
- {
24
- closePromise
25
- } = await start();
26
- process.on("beforeExit", function () {
5
+ var { dev } = await import("vxrn"), { start, stop } = await dev({
6
+ clean: args.clean,
7
+ root: process.cwd(),
8
+ server: {
9
+ https: args.https,
10
+ host: args.host,
11
+ port: args.port ? +args.port : void 0
12
+ },
13
+ entries: {
14
+ native: virtualEntryIdNative
15
+ }
16
+ }), { closePromise } = await start();
17
+ process.on("beforeExit", function() {
27
18
  stop();
28
- }), process.on("SIGINT", function () {
19
+ }), process.on("SIGINT", function() {
29
20
  stop();
30
- }), process.on("uncaughtException", function (err) {
21
+ }), process.on("uncaughtException", function(err) {
31
22
  console.error(err?.message || err);
32
23
  }), await closePromise;
33
24
  }
34
- export { run };
35
- //# sourceMappingURL=run.native.js.map
25
+ export {
26
+ run
27
+ };
28
+ //# sourceMappingURL=run.js.map