akanjs 2.2.4 → 2.2.6

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (609) hide show
  1. package/CHANGELOG.md +9 -0
  2. package/base/base.ts +1 -1
  3. package/base/primitiveRegistry.ts +6 -10
  4. package/base/types.ts +1 -4
  5. package/capacitor.base.config.ts +1 -1
  6. package/client/capacitor.ts +1 -1
  7. package/client/cookie.ts +2 -4
  8. package/client/createFont.ts +2 -2
  9. package/client/csrTypes.ts +2 -8
  10. package/client/makePageProto.tsx +4 -10
  11. package/client/router.ts +3 -8
  12. package/client/translator.ts +4 -12
  13. package/common/Logger.ts +1 -4
  14. package/common/formatNumber.ts +2 -5
  15. package/common/hmrPhase.ts +1 -1
  16. package/common/isValidDate.ts +0 -3
  17. package/constant/fieldInfo.ts +3 -3
  18. package/constant/purify.ts +1 -2
  19. package/constant/types.ts +0 -4
  20. package/constant/via.ts +6 -12
  21. package/document/databaseRegistry.ts +0 -8
  22. package/document/into.ts +0 -1
  23. package/fetch/client/fetchClient.ts +1 -6
  24. package/fetch/client/httpClient.ts +1 -2
  25. package/fetch/fetchType/appliedReturn.type.ts +0 -1
  26. package/fetch/fetchType/endpointFetch.type.ts +0 -3
  27. package/fetch/fetchType/sliceFetch.type.ts +0 -8
  28. package/fetch/requestStorage.ts +2 -10
  29. package/package.json +67 -24
  30. package/server/akanApp.ts +2 -5
  31. package/server/akanLib.ts +0 -1
  32. package/server/akanServer.ts +3 -4
  33. package/server/artifact/builderRpc.ts +2 -2
  34. package/server/artifact/ipcTypes.ts +0 -4
  35. package/server/decorators.ts +1 -1
  36. package/server/di/diLifecycle.ts +3 -6
  37. package/server/hmr/clientScript.ts +2 -20
  38. package/server/hmr/devHmrController.ts +0 -4
  39. package/server/processMetricsCollector.ts +1 -1
  40. package/server/resolver/database.resolver.ts +2 -2
  41. package/server/resolver/resolver.contract.fixture.ts +0 -1
  42. package/server/resolver/signal.resolver.ts +2 -10
  43. package/server/routing/apiRouter.ts +2 -4
  44. package/server/rscClient.tsx +1 -7
  45. package/server/rscWorkerHost.ts +11 -33
  46. package/server/ssrFromRscRenderer.tsx +3 -35
  47. package/server/types/react-server-dom-webpack.d.ts +1 -7
  48. package/server/vendor/react-dom-client.ts +1 -1
  49. package/server/vendor/react-dom.ts +2 -3
  50. package/server/vendor/react-jsx-dev-runtime.ts +1 -1
  51. package/server/vendor/react-jsx-runtime.ts +1 -1
  52. package/server/vendor/react-refresh-runtime.ts +2 -2
  53. package/server/vendor/react-server-dom-webpack-client-browser.ts +1 -1
  54. package/server/vendor/react.ts +2 -9
  55. package/server/vendor/scheduler.ts +2 -3
  56. package/server/webRouter.ts +2 -3
  57. package/service/adapt.ts +1 -5
  58. package/service/predefinedAdaptor/cache.adaptor.ts +1 -2
  59. package/service/predefinedAdaptor/database.adaptor.ts +2 -2
  60. package/service/predefinedAdaptor/solidSqlite.ts +1 -2
  61. package/service/predefinedAdaptor/websocket.adaptor.ts +3 -15
  62. package/service/serve.ts +3 -7
  63. package/signal/base.signal.ts +0 -1
  64. package/signal/endpointInfo.ts +0 -7
  65. package/signal/intercept.ts +0 -2
  66. package/signal/middleware.ts +1 -2
  67. package/signal/serverSignal.ts +1 -15
  68. package/signal/signalContext.ts +1 -1
  69. package/signal/signalRegistry.ts +0 -5
  70. package/signal/sliceInfo.ts +0 -3
  71. package/signal/trace.ts +0 -11
  72. package/signal/types.ts +2 -11
  73. package/store/action.ts +3 -5
  74. package/store/stateBuilder.ts +0 -2
  75. package/store/stateInfo.ts +1 -2
  76. package/store/types.ts +1 -1
  77. package/test/playwright.config.base.ts +5 -28
  78. package/test/playwright.pageAgent.ts +1 -1
  79. package/test/sampleOf.ts +1 -1
  80. package/test/testServer.ts +1 -1
  81. package/types/base/base.d.ts +53 -0
  82. package/types/base/baseEnv.d.ts +68 -0
  83. package/types/base/index.d.ts +6 -0
  84. package/types/base/primitiveRegistry.d.ts +134 -0
  85. package/types/base/symbols.d.ts +11 -0
  86. package/types/base/types.d.ts +68 -0
  87. package/types/base/utils.d.ts +4 -0
  88. package/types/base.d.ts +1 -0
  89. package/types/capacitor.base.config.d.ts +3 -0
  90. package/types/client/capacitor.d.ts +233 -0
  91. package/types/client/clientRuntime.d.ts +63 -0
  92. package/types/client/cookie.d.ts +33 -0
  93. package/types/client/createFont.d.ts +6 -0
  94. package/types/client/csrTypes.d.ts +262 -0
  95. package/types/client/decorators.d.ts +7 -0
  96. package/types/client/device.d.ts +41 -0
  97. package/types/client/fetch.d.ts +1 -0
  98. package/types/client/index.d.ts +14 -0
  99. package/types/client/locale.d.ts +5 -0
  100. package/types/client/makePageProto.d.ts +17002 -0
  101. package/types/client/router.d.ts +66 -0
  102. package/types/client/rscNavigation.d.ts +19 -0
  103. package/types/client/storage.d.ts +5 -0
  104. package/types/client/translator.d.ts +18 -0
  105. package/types/client/types.d.ts +145 -0
  106. package/types/client/useClient.d.ts +1 -0
  107. package/types/client.d.ts +1 -0
  108. package/types/common/Logger.d.ts +41 -0
  109. package/types/common/applyMixins.d.ts +3 -0
  110. package/types/common/capitalize.d.ts +2 -0
  111. package/types/common/deepObjectify.d.ts +4 -0
  112. package/types/common/fileUpload.d.ts +28 -0
  113. package/types/common/formatNumber.d.ts +1 -0
  114. package/types/common/formatPhone.d.ts +2 -0
  115. package/types/common/getAllPropertyDescriptors.d.ts +5 -0
  116. package/types/common/hmrPhase.d.ts +6 -0
  117. package/types/common/httpClient.d.ts +20 -0
  118. package/types/common/index.d.ts +29 -0
  119. package/types/common/isDayjs.d.ts +2 -0
  120. package/types/common/isEmail.d.ts +2 -0
  121. package/types/common/isPhoneNumber.d.ts +2 -0
  122. package/types/common/isQueryEqual.d.ts +1 -0
  123. package/types/common/isValidDate.d.ts +2 -0
  124. package/types/common/jwtDecode.d.ts +2 -0
  125. package/types/common/localeConfig.d.ts +11 -0
  126. package/types/common/lowerlize.d.ts +2 -0
  127. package/types/common/mergeVersion.d.ts +10 -0
  128. package/types/common/objectify.d.ts +1 -0
  129. package/types/common/pathGet.d.ts +1 -0
  130. package/types/common/pathSet.d.ts +3 -0
  131. package/types/common/randomPick.d.ts +1 -0
  132. package/types/common/randomPicks.d.ts +1 -0
  133. package/types/common/routeConvention.d.ts +35 -0
  134. package/types/common/sleep.d.ts +2 -0
  135. package/types/common/splitVersion.d.ts +11 -0
  136. package/types/common/subRoute.d.ts +7 -0
  137. package/types/common/types.d.ts +14 -0
  138. package/types/common.d.ts +1 -0
  139. package/types/constant/constantRegistry.d.ts +89 -0
  140. package/types/constant/crystalize.d.ts +4 -0
  141. package/types/constant/deserialize.d.ts +7 -0
  142. package/types/constant/fieldInfo.d.ts +153 -0
  143. package/types/constant/getDefault.d.ts +3 -0
  144. package/types/constant/immerify.d.ts +2 -0
  145. package/types/constant/index.d.ts +10 -0
  146. package/types/constant/purify.d.ts +12 -0
  147. package/types/constant/serialize.d.ts +11 -0
  148. package/types/constant/types.d.ts +77 -0
  149. package/types/constant/via.d.ts +52 -0
  150. package/types/constant.d.ts +1 -0
  151. package/types/dictionary/base.dictionary.d.ts +1 -0
  152. package/types/dictionary/dictInfo.d.ts +206 -0
  153. package/types/dictionary/dictionary.d.ts +11 -0
  154. package/types/dictionary/index.d.ts +4 -0
  155. package/types/dictionary/locale.d.ts +128 -0
  156. package/types/dictionary/trans.d.ts +82 -0
  157. package/types/dictionary.d.ts +1 -0
  158. package/types/document/by.d.ts +20 -0
  159. package/types/document/dataLoader.d.ts +36 -0
  160. package/types/document/database.d.ts +96 -0
  161. package/types/document/databaseRegistry.d.ts +36 -0
  162. package/types/document/documentQuery.d.ts +105 -0
  163. package/types/document/documentSchema.d.ts +33 -0
  164. package/types/document/filterMeta.d.ts +84 -0
  165. package/types/document/index.d.ts +11 -0
  166. package/types/document/into.d.ts +65 -0
  167. package/types/document/loaderInfo.d.ts +35 -0
  168. package/types/document/schema.d.ts +5 -0
  169. package/types/document/types.d.ts +36 -0
  170. package/types/document.d.ts +1 -0
  171. package/types/fetch/client/fetchClient.d.ts +78 -0
  172. package/types/fetch/client/httpClient.d.ts +39 -0
  173. package/types/fetch/client/index.d.ts +3 -0
  174. package/types/fetch/client/wsClient.d.ts +37 -0
  175. package/types/fetch/client.d.ts +1 -0
  176. package/types/fetch/fetchType/appliedReturn.type.d.ts +67 -0
  177. package/types/fetch/fetchType/buildFetch.type.d.ts +11 -0
  178. package/types/fetch/fetchType/clientSignal.type.d.ts +16 -0
  179. package/types/fetch/fetchType/endpointFetch.type.d.ts +29 -0
  180. package/types/fetch/fetchType/index.d.ts +5 -0
  181. package/types/fetch/fetchType/sliceFetch.type.d.ts +76 -0
  182. package/types/fetch/fetchType.d.ts +1 -0
  183. package/types/fetch/index.d.ts +4 -0
  184. package/types/fetch/requestStorage.d.ts +29 -0
  185. package/types/fetch/serializer/fetch.serializer.d.ts +14 -0
  186. package/types/fetch/serializer/index.d.ts +1 -0
  187. package/types/fetch/serializer.d.ts +1 -0
  188. package/types/fetch/types.d.ts +19 -0
  189. package/types/fetch.d.ts +1 -0
  190. package/types/index.d.ts +213 -0
  191. package/types/server/akanApp.d.ts +17 -0
  192. package/types/server/akanAppHeaders.d.ts +1 -0
  193. package/types/server/akanLib.d.ts +33 -0
  194. package/types/server/akanOption.d.ts +15 -0
  195. package/types/server/akanServer.d.ts +47 -0
  196. package/types/server/artifact/builderRpc.d.ts +42 -0
  197. package/types/server/artifact/index.d.ts +6 -0
  198. package/types/server/artifact/ipcTypes.d.ts +73 -0
  199. package/types/server/artifact/manifestTypes.d.ts +16 -0
  200. package/types/server/artifact/routeClientCache.d.ts +45 -0
  201. package/types/server/artifact/routeSeedIndexStore.d.ts +43 -0
  202. package/types/server/artifact/routesManifestStore.d.ts +16 -0
  203. package/types/server/artifact.d.ts +1 -0
  204. package/types/server/decorators.d.ts +6 -0
  205. package/types/server/di/diLifecycle.d.ts +45 -0
  206. package/types/server/di/index.d.ts +4 -0
  207. package/types/server/di/predefinedAdaptor.d.ts +33 -0
  208. package/types/server/di/resolveAdaptorHierarchy.d.ts +21 -0
  209. package/types/server/di/resolveHierarchy.d.ts +11 -0
  210. package/types/server/di/resolveServiceHierarchy.d.ts +13 -0
  211. package/types/server/di/utils.d.ts +14 -0
  212. package/types/server/di.d.ts +1 -0
  213. package/types/server/hmr/changeBatch.d.ts +13 -0
  214. package/types/server/hmr/clientScript.d.ts +1 -0
  215. package/types/server/hmr/devHmrController.d.ts +24 -0
  216. package/types/server/hmr/index.d.ts +4 -0
  217. package/types/server/hmr/wsHub.d.ts +45 -0
  218. package/types/server/hmr.d.ts +1 -0
  219. package/types/server/imageOptimizer.d.ts +12 -0
  220. package/types/server/imageOptimizerError.d.ts +4 -0
  221. package/types/server/index.d.ts +14 -0
  222. package/types/server/lifecycle/shutdownManager.d.ts +13 -0
  223. package/types/server/logging/rotatingLogWriter.d.ts +20 -0
  224. package/types/server/processMetricsCollector.d.ts +10 -0
  225. package/types/server/proxy/akanResponse.d.ts +7 -0
  226. package/types/server/proxy/bunRequestFields.d.ts +1 -0
  227. package/types/server/proxy/hostBasePathWebProxy.d.ts +6 -0
  228. package/types/server/proxy/index.d.ts +6 -0
  229. package/types/server/proxy/localeWebProxy.d.ts +5 -0
  230. package/types/server/proxy/types.d.ts +37 -0
  231. package/types/server/proxy/webProxyRunner.d.ts +7 -0
  232. package/types/server/proxy.d.ts +1 -0
  233. package/types/server/resolver/database.resolver.d.ts +6 -0
  234. package/types/server/resolver/index.d.ts +3 -0
  235. package/types/server/resolver/service.resolver.d.ts +7 -0
  236. package/types/server/resolver/signal.resolver.d.ts +29 -0
  237. package/types/server/resolver.d.ts +1 -0
  238. package/types/server/robots.d.ts +1 -0
  239. package/types/server/routeElementComposer.d.ts +41 -0
  240. package/types/server/routeTreeBuilder.d.ts +28 -0
  241. package/types/server/routing/apiRouter.d.ts +61 -0
  242. package/types/server/rscClient.d.ts +15 -0
  243. package/types/server/rscWorker.d.ts +3 -0
  244. package/types/server/rscWorkerHost.d.ts +83 -0
  245. package/types/server/sitemap.d.ts +13 -0
  246. package/types/server/ssrFromRscRenderer.d.ts +6 -0
  247. package/types/server/ssrTypes.d.ts +47 -0
  248. package/types/server/systemPages.d.ts +27 -0
  249. package/types/server/types/react-server-dom-webpack.d.ts +91 -0
  250. package/types/server/types.d.ts +67 -0
  251. package/types/server/vendor/akanjs-base.d.ts +1 -0
  252. package/types/server/vendor/akanjs-common.d.ts +1 -0
  253. package/types/server/vendor/akanjs-constant.d.ts +1 -0
  254. package/types/server/vendor/akanjs-store.d.ts +1 -0
  255. package/types/server/vendor/react-dom-client.d.ts +3 -0
  256. package/types/server/vendor/react-dom.d.ts +3 -0
  257. package/types/server/vendor/react-jsx-dev-runtime.d.ts +3 -0
  258. package/types/server/vendor/react-jsx-runtime.d.ts +3 -0
  259. package/types/server/vendor/react-refresh-runtime.d.ts +3 -0
  260. package/types/server/vendor/react-server-dom-webpack-client-browser.d.ts +3 -0
  261. package/types/server/vendor/react.d.ts +11 -0
  262. package/types/server/vendor/scheduler.d.ts +3 -0
  263. package/types/server/webRouter.d.ts +44 -0
  264. package/types/server.d.ts +1 -0
  265. package/types/service/adapt.d.ts +15 -0
  266. package/types/service/base.service.d.ts +18 -0
  267. package/types/service/index.d.ts +10 -0
  268. package/types/service/injectInfo.d.ts +102 -0
  269. package/types/service/ipcTypes.d.ts +194 -0
  270. package/types/service/predefinedAdaptor/cache.adaptor.d.ts +46 -0
  271. package/types/service/predefinedAdaptor/compress.adaptor.d.ts +22 -0
  272. package/types/service/predefinedAdaptor/database.adaptor.d.ts +329 -0
  273. package/types/service/predefinedAdaptor/index.d.ts +13 -0
  274. package/types/service/predefinedAdaptor/logging.adaptor.d.ts +20 -0
  275. package/types/service/predefinedAdaptor/queue.adaptor.d.ts +22 -0
  276. package/types/service/predefinedAdaptor/role.adaptor.d.ts +17 -0
  277. package/types/service/predefinedAdaptor/schedule.adaptor.d.ts +60 -0
  278. package/types/service/predefinedAdaptor/solidCache.adaptor.d.ts +25 -0
  279. package/types/service/predefinedAdaptor/solidPubsub.adaptor.d.ts +20 -0
  280. package/types/service/predefinedAdaptor/solidQueue.adaptor.d.ts +19 -0
  281. package/types/service/predefinedAdaptor/solidSqlite.d.ts +24 -0
  282. package/types/service/predefinedAdaptor/sqlitePath.d.ts +9 -0
  283. package/types/service/predefinedAdaptor/storage.adaptor.d.ts +80 -0
  284. package/types/service/predefinedAdaptor/websocket.adaptor.d.ts +49 -0
  285. package/types/service/predefinedAdaptor.d.ts +1 -0
  286. package/types/service/serve.d.ts +31 -0
  287. package/types/service/serviceModule.d.ts +50 -0
  288. package/types/service/serviceRegistry.d.ts +9 -0
  289. package/types/service/types.d.ts +55 -0
  290. package/types/service.d.ts +1 -0
  291. package/types/signal/base.signal.d.ts +41 -0
  292. package/types/signal/endpoint.d.ts +28 -0
  293. package/types/signal/endpointInfo.d.ts +77 -0
  294. package/types/signal/exception.d.ts +54786 -0
  295. package/types/signal/guard.d.ts +10 -0
  296. package/types/signal/guards.d.ts +10 -0
  297. package/types/signal/index.d.ts +19 -0
  298. package/types/signal/intercept.d.ts +17 -0
  299. package/types/signal/internal.d.ts +18 -0
  300. package/types/signal/internalArg.d.ts +31 -0
  301. package/types/signal/internalInfo.d.ts +45 -0
  302. package/types/signal/middleware.d.ts +51 -0
  303. package/types/signal/serializer/fetch.serializer.d.ts +14 -0
  304. package/types/signal/serializer/index.d.ts +1 -0
  305. package/types/signal/serializer.d.ts +1 -0
  306. package/types/signal/serverSignal.d.ts +36 -0
  307. package/types/signal/signalContext.d.ts +96 -0
  308. package/types/signal/signalRegistry.d.ts +49 -0
  309. package/types/signal/slice.d.ts +42 -0
  310. package/types/signal/sliceInfo.d.ts +51 -0
  311. package/types/signal/trace.d.ts +97 -0
  312. package/types/signal/types.d.ts +142 -0
  313. package/types/signal.d.ts +1 -0
  314. package/types/store/action.d.ts +145 -0
  315. package/types/store/baseSt.d.ts +412 -0
  316. package/types/store/hooks.d.ts +1 -0
  317. package/types/store/index.d.ts +8 -0
  318. package/types/store/rootStore.d.ts +22 -0
  319. package/types/store/state.d.ts +91 -0
  320. package/types/store/stateBuilder.d.ts +141 -0
  321. package/types/store/stateInfo.d.ts +23 -0
  322. package/types/store/store.d.ts +36 -0
  323. package/types/store/storeInstance.d.ts +38 -0
  324. package/types/store/storeRegistry.d.ts +13 -0
  325. package/types/store/types.d.ts +42 -0
  326. package/types/store/withSelector.d.ts +42 -0
  327. package/types/store.d.ts +1 -0
  328. package/types/test/index.d.ts +4 -0
  329. package/types/test/playwright.config.base.d.ts +9 -0
  330. package/types/test/playwright.pageAgent.d.ts +12 -0
  331. package/types/test/sample.d.ts +15 -0
  332. package/types/test/sampleOf.d.ts +5 -0
  333. package/types/test/signalTest.preload.d.ts +1 -0
  334. package/types/test/signalTestRuntime.d.ts +29 -0
  335. package/types/test/testServer.d.ts +26 -0
  336. package/types/test.d.ts +1 -0
  337. package/types/ui/BottomSheet.d.ts +13 -0
  338. package/types/ui/Button.d.ts +11 -0
  339. package/types/ui/ClientSide.d.ts +8 -0
  340. package/types/ui/Clipboard.d.ts +7 -0
  341. package/types/ui/Constant/Doc.d.ts +29 -0
  342. package/types/ui/Constant/Mermaid.d.ts +8 -0
  343. package/types/ui/Constant/index.d.ts +6 -0
  344. package/types/ui/Constant/schemaDoc.d.ts +84 -0
  345. package/types/ui/Constant.d.ts +1 -0
  346. package/types/ui/Copy.d.ts +10 -0
  347. package/types/ui/CsrImage.d.ts +18 -0
  348. package/types/ui/Data/CardList.d.ts +36 -0
  349. package/types/ui/Data/Dashboard.d.ts +11 -0
  350. package/types/ui/Data/Insight.d.ts +9 -0
  351. package/types/ui/Data/Item.d.ts +75 -0
  352. package/types/ui/Data/ListContainer.d.ts +49 -0
  353. package/types/ui/Data/Pagination.d.ts +9 -0
  354. package/types/ui/Data/QueryMaker.d.ts +8 -0
  355. package/types/ui/Data/TableList.d.ts +26 -0
  356. package/types/ui/Data/index.d.ts +9 -0
  357. package/types/ui/Data/index_.d.ts +8 -0
  358. package/types/ui/Data.d.ts +1 -0
  359. package/types/ui/DatePicker.d.ts +36 -0
  360. package/types/ui/Dialog/Action.d.ts +5 -0
  361. package/types/ui/Dialog/Close.d.ts +6 -0
  362. package/types/ui/Dialog/Content.d.ts +6 -0
  363. package/types/ui/Dialog/Modal.d.ts +9 -0
  364. package/types/ui/Dialog/Provider.d.ts +11 -0
  365. package/types/ui/Dialog/Title.d.ts +5 -0
  366. package/types/ui/Dialog/Trigger.d.ts +6 -0
  367. package/types/ui/Dialog/context.d.ts +10 -0
  368. package/types/ui/Dialog/index.d.ts +9 -0
  369. package/types/ui/Dialog.d.ts +1 -0
  370. package/types/ui/DragAction.d.ts +24 -0
  371. package/types/ui/DraggableList.d.ts +31 -0
  372. package/types/ui/Dropdown.d.ts +14 -0
  373. package/types/ui/Empty.d.ts +12 -0
  374. package/types/ui/Field.d.ts +411 -0
  375. package/types/ui/FontFace.d.ts +6 -0
  376. package/types/ui/Image.d.ts +49 -0
  377. package/types/ui/InfiniteScroll.d.ts +10 -0
  378. package/types/ui/Input.d.ts +95 -0
  379. package/types/ui/KeyboardAvoiding.d.ts +8 -0
  380. package/types/ui/Layout/BottomAction.d.ts +6 -0
  381. package/types/ui/Layout/BottomInset.d.ts +7 -0
  382. package/types/ui/Layout/BottomTab.d.ts +14 -0
  383. package/types/ui/Layout/Header.d.ts +8 -0
  384. package/types/ui/Layout/LeftSider.d.ts +9 -0
  385. package/types/ui/Layout/Navbar.d.ts +11 -0
  386. package/types/ui/Layout/RightSider.d.ts +10 -0
  387. package/types/ui/Layout/Sider.d.ts +7 -0
  388. package/types/ui/Layout/Template.d.ts +7 -0
  389. package/types/ui/Layout/TopLeftAction.d.ts +6 -0
  390. package/types/ui/Layout/Unit.d.ts +9 -0
  391. package/types/ui/Layout/View.d.ts +8 -0
  392. package/types/ui/Layout/Zone.d.ts +6 -0
  393. package/types/ui/Layout/index.d.ts +14 -0
  394. package/types/ui/Layout.d.ts +1 -0
  395. package/types/ui/Link/Back.d.ts +7 -0
  396. package/types/ui/Link/Close.d.ts +7 -0
  397. package/types/ui/Link/CsrLink.d.ts +2 -0
  398. package/types/ui/Link/Lang.d.ts +8 -0
  399. package/types/ui/Link/SsrLink.d.ts +2 -0
  400. package/types/ui/Link/index.d.ts +10 -0
  401. package/types/ui/Link/types.d.ts +42 -0
  402. package/types/ui/Link.d.ts +1 -0
  403. package/types/ui/Load/Edit.d.ts +4 -0
  404. package/types/ui/Load/Edit_Client.d.ts +27 -0
  405. package/types/ui/Load/Page.d.ts +15 -0
  406. package/types/ui/Load/PageCSR.d.ts +3 -0
  407. package/types/ui/Load/Pagination.d.ts +8 -0
  408. package/types/ui/Load/Units.d.ts +30 -0
  409. package/types/ui/Load/View.d.ts +22 -0
  410. package/types/ui/Load/index.d.ts +8 -0
  411. package/types/ui/Load/index_.d.ts +3 -0
  412. package/types/ui/Load.d.ts +1 -0
  413. package/types/ui/Loading/Area.d.ts +1 -0
  414. package/types/ui/Loading/Button.d.ts +7 -0
  415. package/types/ui/Loading/Input.d.ts +7 -0
  416. package/types/ui/Loading/ProgressBar.d.ts +6 -0
  417. package/types/ui/Loading/Skeleton.d.ts +7 -0
  418. package/types/ui/Loading/Spin.d.ts +7 -0
  419. package/types/ui/Loading/index.d.ts +8 -0
  420. package/types/ui/Loading.d.ts +1 -0
  421. package/types/ui/Menu.d.ts +26 -0
  422. package/types/ui/Modal.d.ts +19 -0
  423. package/types/ui/Model/AdminPanel.d.ts +31 -0
  424. package/types/ui/Model/Edit.d.ts +16 -0
  425. package/types/ui/Model/EditModal.d.ts +52 -0
  426. package/types/ui/Model/EditWrapper.d.ts +13 -0
  427. package/types/ui/Model/LoadInit.d.ts +10 -0
  428. package/types/ui/Model/New.d.ts +16 -0
  429. package/types/ui/Model/NewWrapper.d.ts +13 -0
  430. package/types/ui/Model/NewWrapper_Client.d.ts +13 -0
  431. package/types/ui/Model/Remove.d.ts +13 -0
  432. package/types/ui/Model/RemoveWrapper.d.ts +12 -0
  433. package/types/ui/Model/SureToRemove.d.ts +11 -0
  434. package/types/ui/Model/View.d.ts +19 -0
  435. package/types/ui/Model/ViewEditModal.d.ts +12 -0
  436. package/types/ui/Model/ViewModal.d.ts +14 -0
  437. package/types/ui/Model/ViewWrapper.d.ts +12 -0
  438. package/types/ui/Model/index.d.ts +16 -0
  439. package/types/ui/Model/index_.d.ts +14 -0
  440. package/types/ui/Model.d.ts +1 -0
  441. package/types/ui/More.d.ts +12 -0
  442. package/types/ui/ObjectId.d.ts +5 -0
  443. package/types/ui/Pagination.d.ts +20 -0
  444. package/types/ui/Popconfirm.d.ts +28 -0
  445. package/types/ui/Portal.d.ts +6 -0
  446. package/types/ui/Radio.d.ts +19 -0
  447. package/types/ui/RecentTime.d.ts +12 -0
  448. package/types/ui/Refresh.d.ts +7 -0
  449. package/types/ui/ScreenNavigator.d.ts +18 -0
  450. package/types/ui/Select.d.ts +43 -0
  451. package/types/ui/Signal/Arg.d.ts +78 -0
  452. package/types/ui/Signal/Doc.d.ts +33 -0
  453. package/types/ui/Signal/Listener.d.ts +9 -0
  454. package/types/ui/Signal/Message.d.ts +23 -0
  455. package/types/ui/Signal/Object.d.ts +20 -0
  456. package/types/ui/Signal/PubSub.d.ts +24 -0
  457. package/types/ui/Signal/Request.d.ts +8 -0
  458. package/types/ui/Signal/Response.d.ts +14 -0
  459. package/types/ui/Signal/RestApi.d.ts +40 -0
  460. package/types/ui/Signal/WebSocket.d.ts +11 -0
  461. package/types/ui/Signal/index.d.ts +18 -0
  462. package/types/ui/Signal/makeExample.d.ts +4 -0
  463. package/types/ui/Signal/style.d.ts +15 -0
  464. package/types/ui/Signal.d.ts +1 -0
  465. package/types/ui/System/CSR.d.ts +32 -0
  466. package/types/ui/System/Client.d.ts +47 -0
  467. package/types/ui/System/Common.d.ts +47 -0
  468. package/types/ui/System/DevModeToggle.d.ts +1 -0
  469. package/types/ui/System/Gtag.d.ts +4 -0
  470. package/types/ui/System/Messages.d.ts +1 -0
  471. package/types/ui/System/Reconnect.d.ts +1 -0
  472. package/types/ui/System/Root.d.ts +6 -0
  473. package/types/ui/System/SSR.d.ts +24 -0
  474. package/types/ui/System/SelectLanguage.d.ts +5 -0
  475. package/types/ui/System/ThemeToggle.d.ts +4 -0
  476. package/types/ui/System/index.d.ts +12 -0
  477. package/types/ui/System.d.ts +1 -0
  478. package/types/ui/Tab/Menu.d.ts +12 -0
  479. package/types/ui/Tab/Menus.d.ts +6 -0
  480. package/types/ui/Tab/Panel.d.ts +8 -0
  481. package/types/ui/Tab/Provider.d.ts +10 -0
  482. package/types/ui/Tab/context.d.ts +9 -0
  483. package/types/ui/Tab/index.d.ts +7 -0
  484. package/types/ui/Tab.d.ts +1 -0
  485. package/types/ui/Table.d.ts +41 -0
  486. package/types/ui/ToggleSelect.d.ts +33 -0
  487. package/types/ui/Unauthorized.d.ts +9 -0
  488. package/types/ui/animated.d.ts +5 -0
  489. package/types/ui/fontCss.d.ts +11 -0
  490. package/types/ui/index.d.ts +44 -0
  491. package/types/ui.d.ts +1 -0
  492. package/types/webkit/bootCsr.d.ts +16 -0
  493. package/types/webkit/createRobotPage.d.ts +15 -0
  494. package/types/webkit/createSitemapPage.d.ts +4 -0
  495. package/types/webkit/index.d.ts +17 -0
  496. package/types/webkit/lazy.d.ts +11 -0
  497. package/types/webkit/types.d.ts +7 -0
  498. package/types/webkit/useCamera.d.ts +19 -0
  499. package/types/webkit/useCodepush.d.ts +16 -0
  500. package/types/webkit/useContact.d.ts +11 -0
  501. package/types/webkit/useCsrValues.d.ts +30 -0
  502. package/types/webkit/useDebounce.d.ts +2 -0
  503. package/types/webkit/useFetch.d.ts +18 -0
  504. package/types/webkit/useGeoLocation.d.ts +8 -0
  505. package/types/webkit/useHistory.d.ts +23 -0
  506. package/types/webkit/useInterval.d.ts +2 -0
  507. package/types/webkit/useLocation.d.ts +8 -0
  508. package/types/webkit/usePurchase.d.ts +19 -0
  509. package/types/webkit/usePushNoti.d.ts +7 -0
  510. package/types/webkit/useThrottle.d.ts +2 -0
  511. package/types/webkit.d.ts +1 -0
  512. package/ui/BottomSheet.tsx +1 -1
  513. package/ui/Clipboard.tsx +1 -1
  514. package/ui/CsrImage.tsx +3 -14
  515. package/ui/Data/ListContainer.tsx +1 -1
  516. package/ui/Data/Pagination.tsx +1 -1
  517. package/ui/Data/QueryMaker.tsx +0 -339
  518. package/ui/Data/index.ts +0 -1
  519. package/ui/DatePicker.tsx +1 -95
  520. package/ui/Dialog/Modal.tsx +1 -1
  521. package/ui/DraggableList.tsx +5 -5
  522. package/ui/Field.tsx +2 -3
  523. package/ui/Image.tsx +2 -3
  524. package/ui/InfiniteScroll.tsx +0 -1
  525. package/ui/Input.tsx +1 -8
  526. package/ui/Layout/BottomTab.tsx +2 -2
  527. package/ui/Link/SsrLink.tsx +1 -2
  528. package/ui/Load/Page.tsx +1 -1
  529. package/ui/Load/PageCSR.tsx +0 -1
  530. package/ui/Load/Units.tsx +1 -2
  531. package/ui/Load/View.tsx +1 -2
  532. package/ui/Menu.tsx +5 -8
  533. package/ui/Model/EditModal.tsx +2 -5
  534. package/ui/Popconfirm.tsx +2 -4
  535. package/ui/ScreenNavigator.tsx +2 -3
  536. package/ui/Signal/Message.tsx +2 -3
  537. package/ui/Signal/PubSub.tsx +0 -2
  538. package/ui/Signal/Response.tsx +1 -1
  539. package/ui/Signal/WebSocket.tsx +2 -11
  540. package/ui/System/Client.tsx +7 -41
  541. package/ui/System/Gtag.tsx +2 -5
  542. package/ui/System/Messages.tsx +2 -2
  543. package/ui/System/Reconnect.tsx +5 -6
  544. package/ui/System/Root.tsx +0 -1
  545. package/ui/System/SSR.tsx +1 -7
  546. package/ui/ToggleSelect.tsx +3 -8
  547. package/ui/Unauthorized.tsx +1 -1
  548. package/webkit/bootCsr.tsx +3 -6
  549. package/webkit/lazy.tsx +1 -8
  550. package/webkit/useCamera.tsx +0 -1
  551. package/webkit/useCodepush.tsx +4 -9
  552. package/webkit/useContact.tsx +0 -1
  553. package/webkit/useCsrValues.ts +6 -10
  554. package/webkit/useDebounce.ts +2 -2
  555. package/webkit/usePurchase.tsx +5 -9
  556. package/webkit/usePushNoti.tsx +0 -1
  557. package/base/base.test.ts +0 -135
  558. package/base/baseEnv.test.ts +0 -146
  559. package/base/primitiveRegistry.test.ts +0 -127
  560. package/base/symbols.test.ts +0 -29
  561. package/base/utils.test.ts +0 -30
  562. package/build.ts +0 -318
  563. package/capacitor.base.config.test.ts +0 -83
  564. package/client/client.auth-storage.test.ts +0 -210
  565. package/client/client.decorators.test.ts +0 -74
  566. package/client/client.device.test.ts +0 -181
  567. package/client/client.page.test.tsx +0 -175
  568. package/client/client.pure.test.ts +0 -146
  569. package/client/client.router.test.ts +0 -290
  570. package/common/Logger.test.ts +0 -45
  571. package/common/formatAndValidation.test.ts +0 -61
  572. package/common/httpClient.test.ts +0 -91
  573. package/common/objectPath.test.ts +0 -108
  574. package/common/routeConvention.test.ts +0 -132
  575. package/common/runtimeConfig.test.ts +0 -84
  576. package/constant/constant.test.ts +0 -374
  577. package/dictionary/dictionary.test.ts +0 -352
  578. package/document/document.test.ts +0 -698
  579. package/fetch/fetch.test.ts +0 -838
  580. package/server/akanApp.test.ts +0 -130
  581. package/server/akanServer.test.ts +0 -157
  582. package/server/artifact/routeClientCache.test.ts +0 -265
  583. package/server/artifact/routeSeedIndex.test.ts +0 -56
  584. package/server/artifact/routesManifest.test.ts +0 -64
  585. package/server/di/diLifecycle.contract.test.ts +0 -168
  586. package/server/logging/rotatingLogWriter.test.ts +0 -119
  587. package/server/processMetrics.test.ts +0 -24
  588. package/server/proxy/webProxyRunner.test.ts +0 -66
  589. package/server/resolver/resolver.contract.test.ts +0 -594
  590. package/server/robots.test.ts +0 -16
  591. package/server/routeTree.test.tsx +0 -198
  592. package/server/routing/apiRouter.test.ts +0 -136
  593. package/server/sitemap.test.ts +0 -61
  594. package/server/systemPages.test.tsx +0 -93
  595. package/server/webRouter.test.ts +0 -49
  596. package/service/predefinedAdaptor/compress.adaptor.test.ts +0 -184
  597. package/service/predefinedAdaptor/solidCache.adaptor.test.ts +0 -107
  598. package/service/predefinedAdaptor/solidSqlite.test.ts +0 -457
  599. package/service/service.test.ts +0 -732
  600. package/signal/signal.test.ts +0 -892
  601. package/store/stateBuilder.test.ts +0 -168
  602. package/store/store.test.ts +0 -427
  603. package/tsconfig.json +0 -5
  604. package/ui/Constant/schemaDoc.test.ts +0 -113
  605. package/ui/InfiniteScroll.test.tsx +0 -155
  606. package/ui/System/Common.test.ts +0 -37
  607. package/webkit/bootCsr.test.tsx +0 -153
  608. package/webkit/native.test.tsx +0 -341
  609. package/webkit/webkit.test.tsx +0 -531
@@ -0,0 +1,23 @@
1
+ import type { EnumInstance, PrimitiveScalar } from "akanjs/base";
2
+ import type { ConstantFieldTypeInput, PlainTypeToFieldType } from "akanjs/constant";
3
+ export type StateType = "normal" | "storage" | "cookie" | "param" | "searchParam";
4
+ export interface StateProps<FieldValue = any, MapValue = any, Nullable extends boolean = false> {
5
+ nullable: Nullable;
6
+ default?: FieldValue | ((doc: {
7
+ id: string;
8
+ }) => FieldValue);
9
+ enum?: EnumInstance;
10
+ of?: MapValue;
11
+ }
12
+ export declare class StateInfo<Type extends StateType = StateType, Value extends ConstantFieldTypeInput = any, MapValue = Value extends MapConstructor ? typeof PrimitiveScalar : never, Nullable extends boolean = boolean> {
13
+ readonly type: Type;
14
+ readonly value: Value;
15
+ readonly option: StateProps<Value, MapValue, Nullable>;
16
+ constructor(type: Type, value: Value, option?: StateProps<Value, MapValue, Nullable>);
17
+ }
18
+ export declare const buildState: {
19
+ storage: <ExplicitType, Value extends ConstantFieldTypeInput = PlainTypeToFieldType<ExplicitType>, MapValue = Value extends MapConstructor ? typeof PrimitiveScalar : never, Nullable extends boolean = false>(value: Value, option?: StateProps<Value, MapValue, Nullable>) => StateInfo<"storage", Value, MapValue, Nullable>;
20
+ cookie: <ExplicitType, Value extends ConstantFieldTypeInput = PlainTypeToFieldType<ExplicitType>, MapValue = Value extends MapConstructor ? typeof PrimitiveScalar : never, Nullable extends boolean = false>(value: Value, option?: StateProps<Value, MapValue, Nullable>) => StateInfo<"cookie", Value, MapValue, Nullable>;
21
+ param: <ExplicitType, Value extends ConstantFieldTypeInput = PlainTypeToFieldType<ExplicitType>, MapValue = Value extends MapConstructor ? typeof PrimitiveScalar : never, Nullable extends boolean = false>(value: Value, option?: StateProps<Value, MapValue, Nullable>) => StateInfo<"param", Value, MapValue, Nullable>;
22
+ searchParam: <ExplicitType, Value extends ConstantFieldTypeInput = PlainTypeToFieldType<ExplicitType>, MapValue = Value extends MapConstructor ? typeof PrimitiveScalar : never, Nullable extends boolean = false>(value: Value, option?: StateProps<Value, MapValue, Nullable>) => StateInfo<"searchParam", Value, MapValue, Nullable>;
23
+ };
@@ -0,0 +1,36 @@
1
+ import { ACTION_META, type Cls, type MergeAllActionTypes, type MergeAllKeyOfObjects, type SLICE_META, STATE_DERIVED_META, STATE_INIT_META, STATE_META } from "akanjs/base";
2
+ import type { FilterInstance } from "akanjs/document";
3
+ import type { ClientSignal } from "akanjs/fetch";
4
+ import type { SerializedSlice, SliceCls } from "akanjs/signal";
5
+ import { type DefaultAction } from "./action.d.ts";
6
+ import { type DefaultState } from "./state.d.ts";
7
+ import { type DerivedStateBuilder, type DerivedStateOf, type StateDerivedMeta, type StateInitializerMap, type WritableStateBuilder, type WritableStateOf } from "./stateBuilder.d.ts";
8
+ import type { InternalSlice, SetGet, SetGetWritable } from "./types.d.ts";
9
+ export type StoreCls<RefName extends string = string, WritableState = any, Action = unknown, SlceCls extends SliceCls = any, DerivedState = unknown, State = WritableState & DerivedState, _Input = SlceCls["srv"]["cnst"]["_Input"], _Full = SlceCls["srv"]["cnst"]["_Full"], _Light extends {
10
+ id: string;
11
+ } = SlceCls["srv"]["cnst"]["_Light"], _Insight = SlceCls["srv"]["cnst"]["_Insight"], _Filter extends FilterInstance = SlceCls["srv"]["db"]["_Filter"], _CapitalizedRefName extends string = Capitalize<RefName>, _Default = SlceCls["srv"]["cnst"]["_Default"], _Sort = SlceCls["srv"]["db"]["_Sort"]> = Cls<SetGetWritable<WritableState, State> & Action & {
12
+ slice: {
13
+ [Suffix in keyof SlceCls[typeof SLICE_META] as Suffix extends string ? `${RefName}${Capitalize<Suffix>}` : never]: InternalSlice<SlceCls[typeof SLICE_META][Suffix], RefName, Suffix & string, _Input, _Full, _Light, _Insight, _Filter, _CapitalizedRefName, _Default, _Sort>;
14
+ };
15
+ }, {
16
+ readonly type: "module";
17
+ readonly refName: RefName;
18
+ [STATE_META]: State;
19
+ [STATE_INIT_META]: StateInitializerMap;
20
+ [STATE_DERIVED_META]: StateDerivedMeta;
21
+ [ACTION_META]: {
22
+ [key: string]: (...args: any[]) => any;
23
+ };
24
+ slice: {
25
+ [key: string]: SerializedSlice;
26
+ };
27
+ _slice: SlceCls[typeof SLICE_META];
28
+ }>;
29
+ export type ModelStore<Sig extends ClientSignal<any, any, any> | string, WritableState, Action, DerivedState = unknown> = Sig extends string ? StoreCls<Sig, WritableState, Action, any, DerivedState> : Sig extends ClientSignal<any, any, any> ? StoreCls<Sig["refName"], WritableState & DefaultState<Sig["_slice"]>, Action & DefaultAction<Sig["_slice"]>, Sig["_slice"], DerivedState> : never;
30
+ export type StoreReturn<Sig extends ClientSignal<any, any, any> | string, WritableState, LibStores extends StoreCls[], // TODO: Change Type for LibStores' state and action
31
+ DerivedState = unknown, _LibState = MergeAllKeyOfObjects<LibStores, typeof STATE_META>, _LibAction = MergeAllActionTypes<LibStores, keyof SetGet | "slice">> = ModelStore<Sig, WritableState & _LibState, _LibAction, DerivedState>;
32
+ type StateFactory<State> = (builder: WritableStateBuilder) => State;
33
+ type DerivedStateFactory<WritableState, DerivedState> = (builder: DerivedStateBuilder<WritableState>) => DerivedState;
34
+ export declare function store<Sig extends ClientSignal<any, any, any> | string, State, LibStores extends StoreCls[]>(sigRefOrRefName: Sig, state: StateFactory<State>, ...libStores: LibStores): StoreReturn<Sig, WritableStateOf<State>, LibStores>;
35
+ export declare function store<Sig extends ClientSignal<any, any, any> | string, State, DerivedState, LibStores extends StoreCls[]>(sigRefOrRefName: Sig, state: StateFactory<State>, derivedState: DerivedStateFactory<WritableStateOf<State>, DerivedState>, ...libStores: LibStores): StoreReturn<Sig, WritableStateOf<State>, LibStores, DerivedStateOf<DerivedState>>;
36
+ export {};
@@ -0,0 +1,38 @@
1
+ import type { RefObject } from "react";
2
+ import type { RootStoreCls } from "./rootStore.d.ts";
3
+ type StoreStateRecord = Record<string, unknown>;
4
+ type StoreAction = (...args: unknown[]) => unknown;
5
+ export type ReactAPI = {
6
+ useSyncExternalStore: <T>(subscribe: (onStoreChange: () => void) => () => void, getSnapshot: () => T, getServerSnapshot?: () => T) => T;
7
+ useRef: <T>(initialValue: T) => {
8
+ current: T;
9
+ };
10
+ useEffect: (effect: () => (() => void) | void, deps?: any[]) => void;
11
+ };
12
+ export declare class StoreInstance {
13
+ #private;
14
+ get: () => StoreStateRecord;
15
+ set: (stateOrUpdater: StoreStateRecord | ((state: StoreStateRecord) => void)) => void;
16
+ subscribe: (listener: () => void) => () => void;
17
+ sub: {
18
+ (listener: (state: StoreStateRecord, prev: StoreStateRecord) => void): () => void;
19
+ <U>(selector: (state: StoreStateRecord) => U, listener: (state: U, prev: U) => void, options?: {
20
+ equalityFn?: (a: U, b: U) => boolean;
21
+ fireImmediately?: boolean;
22
+ }): () => void;
23
+ };
24
+ sel: <U>(selector: (state: StoreStateRecord) => U, equals?: (a: U, b: U) => boolean) => U;
25
+ ref: <U>(selector: (state: StoreStateRecord) => U) => RefObject<U>;
26
+ use: {
27
+ [key: string]: () => unknown;
28
+ };
29
+ do: {
30
+ [key: string]: StoreAction;
31
+ };
32
+ slice: {
33
+ [key: string]: unknown;
34
+ };
35
+ constructor(store?: RootStoreCls);
36
+ addStore(store: RootStoreCls): this;
37
+ }
38
+ export {};
@@ -0,0 +1,13 @@
1
+ import { type MergeAllKeyOfObjects, type MergeAllKeyOfTypes, type MergeAllTypes, STATE_META } from "akanjs/base";
2
+ import type { RootStoreCls } from "./rootStore.d.ts";
3
+ import type { StoreCls } from "./store.d.ts";
4
+ export type { ReactAPI } from "./storeInstance.d.ts";
5
+ import type { SetGet } from "./types.d.ts";
6
+ import type { WithSelectors } from "./withSelector.d.ts";
7
+ export declare class StoreRegistry {
8
+ #private;
9
+ static register<StrCls extends StoreCls>(store: StrCls): StrCls;
10
+ static get(refName: string): StoreCls | undefined;
11
+ static merge<RefName extends string, StoreClses extends (StoreCls | RootStoreCls)[]>(refName: RefName, ...stores: StoreClses): RootStoreCls<RefName, MergeAllKeyOfObjects<StoreClses, typeof STATE_META>, MergeAllTypes<StoreClses, keyof SetGet | "slice">, MergeAllKeyOfTypes<StoreClses, "slice">, MergeAllKeyOfObjects<StoreClses, "_slice">>;
12
+ static build<RtStoreCls extends RootStoreCls>(store: RtStoreCls): WithSelectors<RtStoreCls>;
13
+ }
@@ -0,0 +1,42 @@
1
+ import type { DefaultOf } from "akanjs/constant";
2
+ import type { ExtractSort, FilterInstance } from "akanjs/document";
3
+ import type { SliceInfo } from "akanjs/signal";
4
+ import type { SliceAction } from "./action.d.ts";
5
+ import type { SliceState } from "./state.d.ts";
6
+ export interface Submit {
7
+ disabled: boolean;
8
+ loading: boolean;
9
+ times: number;
10
+ }
11
+ type IsAny<T> = 0 extends 1 & T ? true : false;
12
+ type PickFunc<State, F extends keyof State = IsAny<State> extends true ? any : keyof State extends never ? any : keyof State> = (...fields: F[]) => {
13
+ [K in (typeof fields)[number]]: Exclude<State[K], null | undefined | "loading">;
14
+ };
15
+ export interface SetGet<State = any> {
16
+ set: (setState: Partial<State> | ((state: State) => void)) => void;
17
+ get: () => State;
18
+ pick: PickFunc<State>;
19
+ }
20
+ export interface SetGetWritable<WritableState = any, State = WritableState> {
21
+ set: (setState: Partial<WritableState> | ((state: WritableState) => void)) => void;
22
+ get: () => State;
23
+ pick: PickFunc<State>;
24
+ }
25
+ export interface SetPick<State = any> {
26
+ set: (setState: Partial<State> | ((state: State) => void)) => void;
27
+ pick: PickFunc<State>;
28
+ }
29
+ export type Get<State, Actions> = {
30
+ get: () => State & Actions;
31
+ };
32
+ export type SliceStateAction<RefName extends string = string, Suffix extends string = "", SliceName extends string = `${RefName}${Capitalize<Suffix>}`, State = any, Action = any> = Action & {
33
+ refName: RefName;
34
+ suffix: Suffix;
35
+ sliceName: SliceName;
36
+ get: () => State;
37
+ set: (setState: Partial<State> | ((state: State) => void)) => void;
38
+ };
39
+ export type InternalSlice<SlceInfo extends SliceInfo = any, RefName extends string = any, Suffix extends string = any, Input = any, Full = any, Light extends {
40
+ id: string;
41
+ } = any, Insight = any, Filter extends FilterInstance = any, _CapitalizedRefName extends string = Capitalize<RefName>, _Default = DefaultOf<Full>, _Sort = ExtractSort<Filter>, _Args extends any[] = SlceInfo extends SliceInfo<any, any, any, any, any, any, any, any, infer Args, any, any> ? Args : never, _SliceState = SliceState<RefName, "", Full, Light, _Args, Insight, Filter, _CapitalizedRefName, "", _Default, _Sort>, _SliceAction = SliceAction<RefName, "", Input, Light, _Args, Filter, _CapitalizedRefName, "", _Sort>> = SliceStateAction<RefName, Suffix, `${RefName}${Capitalize<Suffix>}`, _SliceState, _SliceAction>;
42
+ export {};
@@ -0,0 +1,42 @@
1
+ import type { Prettify } from "akanjs/base";
2
+ import type { FieldState } from "akanjs/constant";
3
+ import type { RefObject } from "react";
4
+ import type { RootStoreCls } from "./rootStore.d.ts";
5
+ import type { SliceStateAction } from "./types.d.ts";
6
+ type SetKey<Key extends string> = `set${Capitalize<Key>}`;
7
+ export type WithSelectors<RtStoreCls extends RootStoreCls> = RtStoreCls extends RootStoreCls<any, infer WritableState, infer Action, infer InternalSliceObj, any, any, infer State> ? WithSelectorsOf<State, WritableState, Action, InternalSliceObj> : never;
8
+ type WithSelectorsOf<State, WritableState, Action, InternalSliceObj> = {
9
+ sub: {
10
+ (listener: (state: State, prev: State) => void): () => void;
11
+ <U>(selector: (state: State) => U, listener: (state: U, prev: U) => void, options?: {
12
+ equalityFn?: (a: U, b: U) => boolean;
13
+ fireImmediately?: boolean;
14
+ }): () => void;
15
+ };
16
+ ref: <U>(selector: (state: State) => U) => RefObject<U>;
17
+ sel: <U>(selector: (state: State) => U, equals?: (a: U, b: U) => boolean) => U;
18
+ use: {
19
+ [K in keyof State]: () => State[K];
20
+ };
21
+ do: Action & {
22
+ [K in keyof WritableState as K extends string ? SetKey<K> : never]: (value: FieldState<WritableState[K]>) => void;
23
+ };
24
+ get: () => State;
25
+ set: (state: Partial<WritableState> | ((state: WritableState) => any)) => void;
26
+ slice: {
27
+ [K in keyof InternalSliceObj]: InternalSliceObj[K] extends SliceStateAction<infer RefName, infer Suffix, infer SliceName, infer State, infer Action> ? SliceSelectors<RefName, State, Action> : never;
28
+ };
29
+ };
30
+ export interface SliceSelectors<RefName extends string, State, Action> {
31
+ refName: RefName;
32
+ use: {
33
+ [K in keyof State]: () => State[K];
34
+ };
35
+ do: Prettify<{
36
+ [K in keyof Action]: Action[K];
37
+ } & {
38
+ [K in keyof State as K extends string ? SetKey<K> : never]: (value: FieldState<State[K]>) => void;
39
+ }>;
40
+ get: () => State;
41
+ }
42
+ export {};
@@ -0,0 +1 @@
1
+ export * from "./store/index.d.ts";
@@ -0,0 +1,4 @@
1
+ export { sample } from "./sample.d.ts";
2
+ export { sampleOf } from "./sampleOf.d.ts";
3
+ export { configureSignalTest, getOrSetupSignalTestContext, getOrSetupSignalTestFetch, getSignalTestContext, getSignalTestFetch, hasSignalTestContext, type SignalTestContext, type SignalTestOptions, type SignalTestTarget, setupSignalTestTarget, terminateSignalTestContext, } from "./signalTestRuntime.d.ts";
4
+ export { TestServer, type TestServerOptions } from "./testServer.d.ts";
@@ -0,0 +1,9 @@
1
+ import { type PlaywrightTestConfig } from "@playwright/test";
2
+ /**
3
+ * Read environment variables from file.
4
+ * https://github.com/motdotla/dotenv
5
+ */
6
+ /**
7
+ * See https://playwright.dev/docs/test-configuration.
8
+ */
9
+ export declare const withBase: (filename: string, config?: PlaywrightTestConfig) => PlaywrightTestConfig<{}, {}>;
@@ -0,0 +1,12 @@
1
+ import { type Page, test } from "@playwright/test";
2
+ export { expect } from "@playwright/test";
3
+ export { test };
4
+ export declare class PageAgent {
5
+ #private;
6
+ readonly page: Page;
7
+ constructor(page: Page);
8
+ goto(path: string): Promise<void>;
9
+ waitForPathChange(path?: string): Promise<unknown>;
10
+ wait(ms?: number): Promise<void>;
11
+ url(): string;
12
+ }
@@ -0,0 +1,15 @@
1
+ import { type Dayjs } from "akanjs/base";
2
+ import Chance from "chance";
3
+ export declare const sample: Chance.Chance & {
4
+ dayjs: (opt?: {
5
+ string?: boolean | undefined;
6
+ american?: boolean | undefined;
7
+ year?: number | undefined;
8
+ month?: number | undefined;
9
+ day?: number | undefined;
10
+ min?: Dayjs | undefined;
11
+ max?: Dayjs | undefined;
12
+ }) => Dayjs;
13
+ pick: <T = unknown>(arr: T[] | readonly T[]) => T;
14
+ picks: <T>(arr: T[] | readonly T[], count?: number, allowDuplicate?: boolean) => T[];
15
+ };
@@ -0,0 +1,5 @@
1
+ import type { BaseObject, ConstantCls, DocumentModel } from "akanjs/constant";
2
+ export type SampleOf<Model> = DocumentModel<{
3
+ [K in keyof Model as Model[K] extends BaseObject ? never : K]: NonNullable<Model[K]>;
4
+ }>;
5
+ export declare const sampleOf: <Model>(modelRef: ConstantCls<Model>) => DocumentModel<{ [K in keyof Model as Model[K] extends BaseObject ? never : K]: NonNullable<Model[K]>; }>;
@@ -0,0 +1 @@
1
+ export {};
@@ -0,0 +1,29 @@
1
+ import type { BackendEnv } from "akanjs/base";
2
+ import type { FetchProxy } from "akanjs/fetch";
3
+ import type { AkanLib } from "akanjs/server";
4
+ import { type TestServerOptions } from "./testServer.d.ts";
5
+ export interface SignalTestTarget {
6
+ type: "app" | "lib";
7
+ name: string;
8
+ env: BackendEnv;
9
+ fetch: FetchProxy;
10
+ libs: AkanLib[];
11
+ }
12
+ export interface SignalTestContext<Fetch = FetchProxy> {
13
+ fetch: Fetch;
14
+ target: SignalTestTarget;
15
+ terminate: () => Promise<void>;
16
+ }
17
+ export type SignalTestOptions = Pick<TestServerOptions, "databaseMode" | "workerId" | "port" | "serverMode">;
18
+ export declare const hasSignalTestContext: () => boolean;
19
+ export declare const getSignalTestContext: <Fetch = FetchProxy>() => SignalTestContext<Fetch>;
20
+ export declare const getSignalTestFetch: <Fetch = FetchProxy>() => Fetch;
21
+ export declare const getOrSetupSignalTestContext: <Fetch = FetchProxy>() => Promise<SignalTestContext<Fetch>>;
22
+ export declare const getOrSetupSignalTestFetch: <Fetch = FetchProxy>() => Promise<Fetch>;
23
+ export declare const configureSignalTest: (options: SignalTestOptions) => void;
24
+ export declare const terminateSignalTestContext: () => Promise<void>;
25
+ export declare const setupSignalTestTarget: <Fetch = FetchProxy>({ type, name, libNames, }?: {
26
+ type?: "app" | "lib";
27
+ name?: string;
28
+ libNames?: string[];
29
+ }, options?: SignalTestOptions) => Promise<SignalTestContext<Fetch>>;
@@ -0,0 +1,26 @@
1
+ import type { BackendEnv } from "akanjs/base";
2
+ import { type AkanLib } from "akanjs/server";
3
+ type TestDatabaseMode = "memory" | "tempFile";
4
+ export interface TestServerOptions {
5
+ workerId?: number;
6
+ port?: number;
7
+ databaseMode?: TestDatabaseMode;
8
+ serverMode?: "federation" | "batch" | "all";
9
+ listen?: boolean;
10
+ web?: boolean;
11
+ }
12
+ export declare class TestServer {
13
+ #private;
14
+ workerId: number;
15
+ static initClient(env: BackendEnv, workerId?: number): void;
16
+ static applyProcessEnv(env: BackendEnv, { workerId, port, serverMode, }?: {
17
+ workerId?: number;
18
+ port?: number;
19
+ serverMode?: "federation" | "batch" | "all";
20
+ }): void;
21
+ constructor(env: BackendEnv, libs: AkanLib | AkanLib[], options?: TestServerOptions);
22
+ init(): Promise<void>;
23
+ cleanup(): Promise<void>;
24
+ terminate(): Promise<void>;
25
+ }
26
+ export {};
@@ -0,0 +1 @@
1
+ export * from "./test/index.d.ts";
@@ -0,0 +1,13 @@
1
+ import { type ReactNode } from "react";
2
+ interface BottomSheetProps {
3
+ open: boolean;
4
+ onCancel: () => void;
5
+ children: ReactNode;
6
+ type: "full" | "half";
7
+ }
8
+ export interface BottomSheetRef {
9
+ open: () => void;
10
+ close: () => void;
11
+ }
12
+ export declare const BottomSheet: import("react").ForwardRefExoticComponent<BottomSheetProps & import("react").RefAttributes<BottomSheetRef>>;
13
+ export {};
@@ -0,0 +1,11 @@
1
+ import type React from "react";
2
+ import { type ButtonHTMLAttributes } from "react";
3
+ export type ButtonProps<Result> = Omit<ButtonHTMLAttributes<HTMLButtonElement>, "onClick"> & {
4
+ /** Async-aware click handler. Call onError to show the localized error state without throwing. */
5
+ onClick: (e: React.MouseEvent<HTMLButtonElement>, { onError }: {
6
+ onError: (error: string) => void;
7
+ }) => Promise<Result> | Result;
8
+ /** Called after the button briefly enters success state. */
9
+ onSuccess?: (result: Result) => void;
10
+ };
11
+ export declare const Button: <Result = unknown>({ className, children, onClick, onSuccess, ...rest }: ButtonProps<Result>) => import("react/jsx-runtime").JSX.Element;
@@ -0,0 +1,8 @@
1
+ import { type ReactNode } from "react";
2
+ export interface ClientSideProps {
3
+ /** Content that should render inside a React Suspense boundary on the client. */
4
+ children: ReactNode;
5
+ /** Optional Suspense fallback. */
6
+ loading?: ReactNode;
7
+ }
8
+ export declare const ClientSide: ({ children, loading }: ClientSideProps) => import("react/jsx-runtime").JSX.Element;
@@ -0,0 +1,7 @@
1
+ import { type ReactElement } from "react";
2
+ export interface ClipboardProps {
3
+ text?: string;
4
+ clipboardMessage?: string;
5
+ className?: string;
6
+ }
7
+ export declare const Clipboard: ({ text, className }: ClipboardProps) => ReactElement;
@@ -0,0 +1,29 @@
1
+ import { type DatabaseSchema, getConstantSchemaDoc, type ScalarSchema } from "./schemaDoc.d.ts";
2
+ declare function Doc(): import("react/jsx-runtime").JSX.Element;
3
+ declare namespace Doc {
4
+ var Zone: ({ models, scalars, enums, openAll }: ZoneProps) => import("react/jsx-runtime").JSX.Element;
5
+ var Print: ({ models, scalars, enums }: ZoneProps) => import("react/jsx-runtime").JSX.Element;
6
+ var Model: ({ refName, database: databaseProp, openAll }: ModelProps) => import("react/jsx-runtime").JSX.Element | null;
7
+ var Scalar: ({ refName, scalar: scalarProp, openAll }: ScalarProps) => import("react/jsx-runtime").JSX.Element | null;
8
+ var Enum: ({ enums }: EnumProps) => import("react/jsx-runtime").JSX.Element;
9
+ }
10
+ export default Doc;
11
+ interface ZoneProps {
12
+ models?: string[];
13
+ scalars?: string[];
14
+ enums?: string[];
15
+ openAll?: boolean;
16
+ }
17
+ interface ModelProps {
18
+ refName?: string;
19
+ database?: DatabaseSchema;
20
+ openAll?: boolean;
21
+ }
22
+ interface ScalarProps {
23
+ refName?: string;
24
+ scalar?: ScalarSchema;
25
+ openAll?: boolean;
26
+ }
27
+ interface EnumProps {
28
+ enums?: ReturnType<typeof getConstantSchemaDoc>["enums"];
29
+ }
@@ -0,0 +1,8 @@
1
+ export interface MermaidProps {
2
+ chart: string;
3
+ title?: string;
4
+ className?: string;
5
+ highlightNodes?: string[];
6
+ onSelectNode?: (nodeId: string) => void;
7
+ }
8
+ export declare const Mermaid: ({ chart, title, className, highlightNodes, onSelectNode }: MermaidProps) => import("react/jsx-runtime").JSX.Element;
@@ -0,0 +1,6 @@
1
+ import Doc from "./Doc.d.ts";
2
+ export * from "./schemaDoc.d.ts";
3
+ export declare const Constant: {
4
+ Doc: typeof Doc;
5
+ Mermaid: ({ chart, title, className, highlightNodes, onSelectNode }: import("./Mermaid.d.ts").MermaidProps) => import("react/jsx-runtime").JSX.Element;
6
+ };
@@ -0,0 +1,84 @@
1
+ import { type EnumInstance } from "akanjs/base";
2
+ import { type ConstantCls, type ConstantField } from "akanjs/constant";
3
+ export declare const databaseModelVariants: readonly ["input", "object", "full", "light", "insight"];
4
+ export type DatabaseModelVariant = (typeof databaseModelVariants)[number];
5
+ export interface ConstantSchemaOptions {
6
+ models?: string[];
7
+ scalars?: string[];
8
+ enums?: string[];
9
+ }
10
+ export interface ConstantSchemaDoc {
11
+ databases: DatabaseSchema[];
12
+ scalars: ScalarSchema[];
13
+ enums: EnumSchema[];
14
+ relations: RelationSchema[];
15
+ }
16
+ export interface DatabaseSchema {
17
+ kind: "database";
18
+ refName: string;
19
+ modelName: string;
20
+ variants: Record<DatabaseModelVariant, ModelVariantSchema>;
21
+ }
22
+ export interface ScalarSchema {
23
+ kind: "scalar";
24
+ refName: string;
25
+ modelName: string;
26
+ modelRef: ConstantCls;
27
+ fields: FieldSchema[];
28
+ }
29
+ export interface ModelVariantSchema {
30
+ refName: string;
31
+ variant: DatabaseModelVariant | "scalar";
32
+ modelName: string;
33
+ modelRef: ConstantCls;
34
+ fields: FieldSchema[];
35
+ }
36
+ export interface EnumSchema {
37
+ key: string;
38
+ refName: string;
39
+ typeName: string;
40
+ values: (string | number)[];
41
+ enumRef: EnumInstance;
42
+ usedBy: EnumUsage[];
43
+ }
44
+ export interface EnumUsage {
45
+ refName: string;
46
+ variant: DatabaseModelVariant | "scalar";
47
+ fieldKey: string;
48
+ }
49
+ export interface RelationSchema {
50
+ sourceRefName: string;
51
+ sourceVariant: DatabaseModelVariant | "scalar";
52
+ targetRefName: string;
53
+ targetKind: "database" | "scalar";
54
+ fieldKey: string;
55
+ relationType: string;
56
+ external: boolean;
57
+ }
58
+ export interface FieldSchema {
59
+ key: string;
60
+ typeLabel: string;
61
+ typeRefName?: string;
62
+ typeKind: "primitive" | "database" | "scalar" | "map" | "unknown";
63
+ required: boolean;
64
+ nullable: boolean;
65
+ arrDepth: number;
66
+ fieldType: "property" | "hidden" | "resolve";
67
+ select: boolean;
68
+ immutable: boolean;
69
+ ref?: string;
70
+ refPath?: string;
71
+ refType?: "child" | "parent" | "relation";
72
+ relationLabel?: string;
73
+ enumRefName?: string;
74
+ enumValues?: (string | number)[];
75
+ defaultLabel?: string;
76
+ exampleLabel?: string;
77
+ constraints: string[];
78
+ text?: "search" | "filter";
79
+ meta: Record<string, unknown>;
80
+ raw: ConstantField;
81
+ }
82
+ export declare const getConstantSchemaDoc: (options?: ConstantSchemaOptions) => ConstantSchemaDoc;
83
+ export declare const getDefaultVariant: (database: DatabaseSchema) => ModelVariantSchema;
84
+ export declare const getVariantTitle: (variant: DatabaseModelVariant | "scalar") => string;
@@ -0,0 +1 @@
1
+ export * from "./Constant/index.d.ts";
@@ -0,0 +1,10 @@
1
+ import { type ReactNode } from "react";
2
+ export interface CopyProps {
3
+ /** Text copied to the clipboard. Defaults to an empty string. */
4
+ text?: string;
5
+ /** Success message shown through the global store message helper. */
6
+ copyMessage?: string;
7
+ /** Copy trigger element. */
8
+ children: ReactNode;
9
+ }
10
+ export declare const Copy: ({ text, copyMessage, children }: CopyProps) => import("react/jsx-runtime").JSX.Element;
@@ -0,0 +1,18 @@
1
+ import type { ProtoFile } from "akanjs/constant";
2
+ import type { ImgHTMLAttributes } from "react";
3
+ type CsrImageProps = Omit<ImgHTMLAttributes<HTMLImageElement>, "alt" | "src"> & {
4
+ src?: string;
5
+ file?: ProtoFile | {
6
+ url: string;
7
+ imageSize: [number, number];
8
+ abstractData?: string | null;
9
+ } | null;
10
+ abstractData?: string;
11
+ priority?: boolean;
12
+ preload?: boolean;
13
+ quality?: number;
14
+ unoptimized?: boolean;
15
+ fill?: boolean;
16
+ };
17
+ export declare const CsrImage: ({ src, file, className, abstractData, ...props }: CsrImageProps) => import("react/jsx-runtime").JSX.Element;
18
+ export {};
@@ -0,0 +1,36 @@
1
+ import { type DataAction, type DataColumn } from "akanjs/client";
2
+ import type { FilterInstance } from "akanjs/document";
3
+ import type { FetchInitForm, SliceMeta } from "akanjs/fetch";
4
+ import { type ReactNode } from "react";
5
+ type DataItemProps<T extends string, M extends {
6
+ id: string;
7
+ }, L extends {
8
+ id: string;
9
+ }> = {
10
+ [key in T]: L;
11
+ } & {
12
+ slice: SliceMeta;
13
+ };
14
+ interface CardListProps<T extends string, Input, Full extends {
15
+ id: string;
16
+ }, Light extends {
17
+ id: string;
18
+ }, Filter extends FilterInstance> {
19
+ className?: string;
20
+ cardListClassName?: string;
21
+ init?: FetchInitForm<Input, Filter>;
22
+ slice: SliceMeta;
23
+ columns: DataColumn<any>[];
24
+ actions?: DataAction[] | ((item: Light, idx: number) => DataAction[]);
25
+ renderItem: (args: DataItemProps<T, Full, Light>) => ReactNode;
26
+ renderLoading?: () => ReactNode;
27
+ renderTemplate?: (props: any) => ReactNode | null;
28
+ renderView?: (model: Full) => ReactNode | null;
29
+ renderTitle?: (model: Full) => string | ReactNode;
30
+ }
31
+ export default function CardList<T extends string, Input, Full extends {
32
+ id: string;
33
+ }, Light extends {
34
+ id: string;
35
+ }, Filter extends FilterInstance>({ className, cardListClassName, init, slice, actions, columns, renderItem, renderLoading, renderTemplate, renderView, renderTitle, }: CardListProps<T, Input, Full, Light, Filter>): import("react/jsx-runtime").JSX.Element;
36
+ export {};
@@ -0,0 +1,11 @@
1
+ import type { SliceMeta } from "akanjs/fetch";
2
+ export interface DashboardProps<T extends string, State> {
3
+ className?: string;
4
+ summary: Record<string, unknown>;
5
+ slice: SliceMeta;
6
+ queryMap: Record<string, unknown>;
7
+ columns?: string[];
8
+ presents?: string[];
9
+ hidePresents?: boolean;
10
+ }
11
+ export default function Dashboard<T extends string, State>({ className, summary, slice, queryMap, columns, presents, hidePresents, }: DashboardProps<T, State>): import("react/jsx-runtime").JSX.Element;
@@ -0,0 +1,9 @@
1
+ import type { SliceMeta } from "akanjs/fetch";
2
+ interface InsightProps<T extends string, Insight> {
3
+ className?: string;
4
+ insight: Insight;
5
+ slice: SliceMeta;
6
+ columns?: (keyof Insight)[];
7
+ }
8
+ export default function Insight<T extends string, Insight>({ className, insight, slice, columns, }: InsightProps<T, Insight>): import("react/jsx-runtime").JSX.Element;
9
+ export {};