@lunora/studio 1.0.0-alpha.13 → 1.0.0-alpha.131

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 (329) hide show
  1. package/LICENSE.md +6 -0
  2. package/dist/index.d.ts +881 -786
  3. package/dist/index.js +1 -41
  4. package/dist/mount.d.ts +10 -10
  5. package/dist/mount.js +1 -26
  6. package/dist/packem_chunks/AdvisorHealthPanel.js +1 -0
  7. package/dist/packem_chunks/ApiTab.js +1 -0
  8. package/dist/packem_chunks/AuditPanel.js +1 -0
  9. package/dist/packem_chunks/DeploymentHealthPanel.js +1 -0
  10. package/dist/packem_chunks/ExportImportPanel.js +3 -0
  11. package/dist/packem_chunks/FileBrowser.js +4 -0
  12. package/dist/packem_chunks/FunctionRunner.js +1 -0
  13. package/dist/packem_chunks/FunctionStatsPanel.js +1 -0
  14. package/dist/packem_chunks/HealthPanel.js +1 -0
  15. package/dist/packem_chunks/InsightsPanel.js +1 -0
  16. package/dist/packem_chunks/LogsPanel.js +1 -0
  17. package/dist/packem_chunks/MailPanel.js +2 -0
  18. package/dist/packem_chunks/MetricsPanel.js +1 -0
  19. package/dist/packem_chunks/NotificationsPanel.js +1 -0
  20. package/dist/packem_chunks/PitrPanel.js +1 -0
  21. package/dist/packem_chunks/SchemaViewer.js +1 -0
  22. package/dist/packem_chunks/SecurityAdvisorPanel.js +1 -0
  23. package/dist/packem_chunks/SettingsPanel.js +1 -0
  24. package/dist/packem_chunks/SqlEditorPanel.js +9 -0
  25. package/dist/packem_chunks/TableEditor.js +1 -0
  26. package/dist/packem_chunks/agents-panel.js +1 -0
  27. package/dist/packem_chunks/analytics-panel.js +1 -0
  28. package/dist/packem_chunks/auth-audit-panel.js +1 -0
  29. package/dist/packem_chunks/auth-config-panel.js +1 -0
  30. package/dist/packem_chunks/auth-sessions-panel.js +1 -0
  31. package/dist/packem_chunks/containers-panel.js +1 -0
  32. package/dist/packem_chunks/dashboards-panel.js +1 -0
  33. package/dist/packem_chunks/evals-panel.js +1 -0
  34. package/dist/packem_chunks/fanout-panel.js +1 -0
  35. package/dist/packem_chunks/flags-panel.js +1 -0
  36. package/dist/packem_chunks/issues-panel.js +1 -0
  37. package/dist/packem_chunks/kv-browser.js +1 -0
  38. package/dist/packem_chunks/log-drains-panel.js +4 -0
  39. package/dist/packem_chunks/migrations-route.js +1 -0
  40. package/dist/packem_chunks/organizations-panel.js +1 -0
  41. package/dist/packem_chunks/payments-panel.js +1 -0
  42. package/dist/packem_chunks/permissions-panel.js +1 -0
  43. package/dist/packem_chunks/queues-panel.js +1 -0
  44. package/dist/packem_chunks/reactors-panel.js +1 -0
  45. package/dist/packem_chunks/rls-panel.js +1 -0
  46. package/dist/packem_chunks/schedule-panel.js +1 -0
  47. package/dist/packem_chunks/sparkline.js +1 -0
  48. package/dist/packem_chunks/storage-rules-panel.js +1 -0
  49. package/dist/packem_chunks/subscriptions-panel.js +1 -0
  50. package/dist/packem_chunks/sync-client-panel.js +1 -0
  51. package/dist/packem_chunks/traces-panel.js +1 -0
  52. package/dist/packem_chunks/users-panel.js +1 -0
  53. package/dist/packem_chunks/vector-browser.js +1 -0
  54. package/dist/packem_chunks/workflows-panel.js +1 -0
  55. package/dist/packem_shared/ADMIN_FUNCTIONS-B6z7VLYt.js +1 -0
  56. package/dist/packem_shared/ApiDocsPanel-Du1L7Ysj.js +2 -0
  57. package/dist/packem_shared/ApiReferencePanel-uGgGOBYj.js +1 -0
  58. package/dist/packem_shared/CommandPalette-HqiXrWIm.js +1 -0
  59. package/dist/packem_shared/ConfirmButton-Cj2SOapE.js +1 -0
  60. package/dist/packem_shared/ConnectionBadge-Bh16X9-u.js +1 -0
  61. package/dist/packem_shared/DEFAULT_AUTO_REFRESH_MS-DuULO4XM.js +1 -0
  62. package/dist/packem_shared/DEFAULT_INSIGHT_THRESHOLDS-1Lrg55IV.js +1 -0
  63. package/dist/packem_shared/DEFAULT_LOCALE-A1Yg5ORA.js +1 -0
  64. package/dist/packem_shared/DataBrowser-W5TxvLB8.js +4 -0
  65. package/dist/packem_shared/DataFilters-3nbW0uax.js +1 -0
  66. package/dist/packem_shared/ErrorBoundary-BWNF98VF.js +1 -0
  67. package/dist/packem_shared/GlobalDataBrowser-LFznuyGe.js +1 -0
  68. package/dist/packem_shared/HomePanel-DmB0EKjl.js +1 -0
  69. package/dist/packem_shared/MigrationsPanel-BDNt136v.js +1 -0
  70. package/dist/packem_shared/OpenRpcReferencePanel-DgrpASYD.js +1 -0
  71. package/dist/packem_shared/STUDIO_ROOT_CLASS-C6MccdVk.js +1 -0
  72. package/dist/packem_shared/ScheduledJobs-CiO3eXgI.js +1 -0
  73. package/dist/packem_shared/ShardInput-CdawpUiS.js +1 -0
  74. package/dist/packem_shared/Studio-CkNE_tEy.js +1 -0
  75. package/dist/packem_shared/StudioApp-BZP_0E2n.js +1 -0
  76. package/dist/packem_shared/StudioI18nProvider-Bl547evf.js +1 -0
  77. package/dist/packem_shared/advisor-view-C1KFTXSH.js +1 -0
  78. package/dist/packem_shared/aggregateMetrics-A-Y7OH6R.js +1 -0
  79. package/dist/packem_shared/alert-C2SEhYS9.js +1 -0
  80. package/dist/packem_shared/app.d-D1bPR8FO.d.ts +252 -0
  81. package/dist/packem_shared/badge-cAk9Di1Q.js +1 -0
  82. package/dist/packem_shared/bar-chart-B6gzp_f9.js +6 -0
  83. package/dist/packem_shared/browser-storage-BH1MxLZs.js +1 -0
  84. package/dist/packem_shared/button-BOPLD1un.js +1 -0
  85. package/dist/packem_shared/card-BGlQzQY-.js +1 -0
  86. package/dist/packem_shared/cf-links-CBJ5SywP.js +1 -0
  87. package/dist/packem_shared/checkbox-C5w53W-E.js +1 -0
  88. package/dist/packem_shared/control-button-BOZ5K-FC.js +1 -0
  89. package/dist/packem_shared/data-grid-BFTQnkXq.js +1 -0
  90. package/dist/packem_shared/data-view-params-qoSTqjAj.js +1 -0
  91. package/dist/packem_shared/dropdown-menu-U7Tjg1Nb.js +2 -0
  92. package/dist/packem_shared/empty-state-B939z6K2.js +1 -0
  93. package/dist/packem_shared/error-alert-TYdKetJd.js +1 -0
  94. package/dist/packem_shared/grid-features-jBzZGauv.js +6 -0
  95. package/dist/packem_shared/home-panel-DHOa3sxt.js +3 -0
  96. package/dist/packem_shared/input-CY5W3wzv.js +1 -0
  97. package/dist/packem_shared/internal-CwaF9YNk.js +2 -0
  98. package/dist/packem_shared/label-BOUo-DP0.js +1 -0
  99. package/dist/packem_shared/live-status-Bf7rR8o8.js +1 -0
  100. package/dist/packem_shared/log-fields-SBxKyBug.js +1 -0
  101. package/dist/packem_shared/log-line-UnE93Ovi.js +1 -0
  102. package/dist/packem_shared/modal-shell-wGW4CKEW.js +1 -0
  103. package/dist/packem_shared/operation-console-provider-DoloEvon.js +1 -0
  104. package/dist/packem_shared/quote-identifier-CGiYFBvY.js +1 -0
  105. package/dist/packem_shared/recording-client-CKn4-vUx.js +1 -0
  106. package/dist/packem_shared/reference-view-BU2dNK9Z.js +13 -0
  107. package/dist/packem_shared/schema-diagram-DOaIh1y6.js +2 -0
  108. package/dist/packem_shared/scroll-area-DSJftwu_.js +2 -0
  109. package/dist/packem_shared/select-BPISLTcv.js +2 -0
  110. package/dist/packem_shared/shard-history-DU5b3QDI.js +1 -0
  111. package/dist/packem_shared/shortcuts-lH4Vaqjc.js +1 -0
  112. package/dist/packem_shared/skeleton-DFBBaJU6.js +1 -0
  113. package/dist/packem_shared/sparkline-CYbJzfA1.js +1 -0
  114. package/dist/packem_shared/sql-result-table-CqlZo2QN.js +1 -0
  115. package/dist/packem_shared/stat-card-B9uIvAHg.js +1 -0
  116. package/dist/packem_shared/storage-tier-C2mKwYRj.js +1 -0
  117. package/dist/packem_shared/studio-CXai1O2K.js +2 -0
  118. package/dist/packem_shared/table-BMsuYFhk.js +2 -0
  119. package/dist/packem_shared/table-list-sidebar-BWq_-gtu.js +1 -0
  120. package/dist/packem_shared/textarea-DpO3i-Qo.js +1 -0
  121. package/dist/packem_shared/trace-handoff-z9sy89Ci.js +1 -0
  122. package/dist/packem_shared/use-admin-query-P0RJrjsD.js +1 -0
  123. package/dist/packem_shared/use-async-submit-DdLd0MdK.js +1 -0
  124. package/dist/packem_shared/use-auth-config-z3KRWAqD.js +1 -0
  125. package/dist/packem_shared/use-open-trace-4mqqFWrn.js +1 -0
  126. package/dist/packem_shared/use-shard-key-BsP3o5wT.js +1 -0
  127. package/dist/packem_shared/use-sql-assistant-D1K2LqpO.js +1 -0
  128. package/dist/packem_shared/useDebounced-DVeQ5-oW.js +1 -0
  129. package/dist/packem_shared/utils-bhneXptQ.js +1 -0
  130. package/dist/packem_shared/virtual-rect-D_j7aLxX.js +1 -0
  131. package/dist/packem_shared/wire-codec-Dl3VeNrd.js +1 -0
  132. package/dist/standalone/chunk-26VREVWU.js +1 -0
  133. package/dist/standalone/chunk-2SFSTQS4.js +1 -0
  134. package/dist/standalone/chunk-2VGV6RPS.js +1 -0
  135. package/dist/standalone/chunk-2XOGZAF4.js +3 -0
  136. package/dist/standalone/chunk-333WFRWG.js +1 -0
  137. package/dist/standalone/chunk-362AVHNC.js +1 -0
  138. package/dist/standalone/chunk-3NXFFXQ2.js +1 -0
  139. package/dist/standalone/chunk-3S4VZ2ZM.js +1 -0
  140. package/dist/standalone/chunk-443UDYWL.js +6 -0
  141. package/dist/standalone/chunk-4PZEPCO7.js +1 -0
  142. package/dist/standalone/chunk-4YTSKL4R.js +1 -0
  143. package/dist/standalone/chunk-4ZCENYC3.js +1 -0
  144. package/dist/standalone/chunk-57VX76PR.js +1 -0
  145. package/dist/standalone/chunk-5EW733RQ.js +1 -0
  146. package/dist/standalone/chunk-5JLIP2HH.js +1 -0
  147. package/dist/standalone/chunk-6CBLYGXJ.js +1 -0
  148. package/dist/standalone/chunk-6UPO6ELN.js +1 -0
  149. package/dist/standalone/chunk-6ZPTNC34.js +19 -0
  150. package/dist/standalone/chunk-74ASA4WU.js +1 -0
  151. package/dist/standalone/chunk-76YLMHR3.js +1 -0
  152. package/dist/standalone/chunk-77JLGJ7V.js +1 -0
  153. package/dist/standalone/chunk-7PIHTTND.js +1 -0
  154. package/dist/standalone/chunk-7SROZWKL.js +1 -0
  155. package/dist/standalone/chunk-AFKLFS74.js +1 -0
  156. package/dist/standalone/chunk-AOAJGSYZ.js +2 -0
  157. package/dist/standalone/chunk-AXXNMZQ4.js +1 -0
  158. package/dist/standalone/chunk-BFCUKERU.js +8 -0
  159. package/dist/standalone/chunk-BQK2C2Z4.js +1 -0
  160. package/dist/standalone/chunk-BUIAZFSC.js +1 -0
  161. package/dist/standalone/chunk-BWEXJENB.js +1 -0
  162. package/dist/standalone/chunk-CA5ILAW2.js +14 -0
  163. package/dist/standalone/chunk-CAOUXOL7.js +1 -0
  164. package/dist/standalone/chunk-CKTKI4IY.js +1 -0
  165. package/dist/standalone/chunk-CL76PTLM.js +2 -0
  166. package/dist/standalone/chunk-CN2AINNY.js +1 -0
  167. package/dist/standalone/chunk-CP4ZFBVW.js +1 -0
  168. package/dist/standalone/chunk-CSYDKCNQ.js +1 -0
  169. package/dist/standalone/chunk-CYX3OHJ3.js +1 -0
  170. package/dist/standalone/chunk-DKSLOJDQ.js +1 -0
  171. package/dist/standalone/chunk-DPNEFSEC.js +1 -0
  172. package/dist/standalone/chunk-DUDQV6XJ.js +1 -0
  173. package/dist/standalone/chunk-DZGOHOOE.js +1 -0
  174. package/dist/standalone/chunk-EBI7CCQQ.js +1 -0
  175. package/dist/standalone/chunk-EDHW2EEG.js +1 -0
  176. package/dist/standalone/chunk-EE63P4VX.js +1 -0
  177. package/dist/standalone/chunk-ELO3V35K.js +1 -0
  178. package/dist/standalone/chunk-EVQ6LHI6.js +1 -0
  179. package/dist/standalone/chunk-EYGF6TQS.js +1 -0
  180. package/dist/standalone/chunk-F7JOSNAT.js +1 -0
  181. package/dist/standalone/chunk-FB5DOMZF.js +4 -0
  182. package/dist/standalone/chunk-FDLSPDIC.js +15 -0
  183. package/dist/standalone/chunk-FJ6G6FNE.js +1 -0
  184. package/dist/standalone/chunk-GIQDEWC4.js +1 -0
  185. package/dist/standalone/chunk-GSQURGCT.js +1 -0
  186. package/dist/standalone/chunk-H3BH6X3G.js +1 -0
  187. package/dist/standalone/chunk-H7YVFLA5.js +7 -0
  188. package/dist/standalone/chunk-HAIBZTXF.js +1 -0
  189. package/dist/standalone/chunk-HRD2DVIW.js +1 -0
  190. package/dist/standalone/chunk-IE5S3JMD.js +1 -0
  191. package/dist/standalone/chunk-INQICZYC.js +1 -0
  192. package/dist/standalone/chunk-IYWVSMAY.js +1 -0
  193. package/dist/standalone/chunk-IZXGBTPE.js +1 -0
  194. package/dist/standalone/chunk-JHXEEPRG.js +1 -0
  195. package/dist/standalone/chunk-JURAVSE7.js +1 -0
  196. package/dist/standalone/chunk-JUWOEHDD.js +1 -0
  197. package/dist/standalone/chunk-JV7KTJPY.js +1 -0
  198. package/dist/standalone/chunk-KTXD2N6F.js +1 -0
  199. package/dist/standalone/chunk-KVSQKUWD.js +1 -0
  200. package/dist/standalone/chunk-L4EZAHCD.js +1 -0
  201. package/dist/standalone/chunk-M3NNNOD5.js +1 -0
  202. package/dist/standalone/chunk-MCLM2QJI.js +1 -0
  203. package/dist/standalone/chunk-METRMDIQ.js +1 -0
  204. package/dist/standalone/chunk-MPYVZLYP.js +1 -0
  205. package/dist/standalone/chunk-MSCK3V6U.js +1 -0
  206. package/dist/standalone/chunk-MVZARXDR.js +1 -0
  207. package/dist/standalone/chunk-MYFFCV2R.js +1 -0
  208. package/dist/standalone/chunk-NIX2QSSN.js +1 -0
  209. package/dist/standalone/chunk-NNLNQKT7.js +59 -0
  210. package/dist/standalone/chunk-NSOLPNU7.js +1 -0
  211. package/dist/standalone/chunk-NXXGISFB.js +1 -0
  212. package/dist/standalone/chunk-O5MAFDY2.js +1 -0
  213. package/dist/standalone/chunk-OE4KGVJW.js +4 -0
  214. package/dist/standalone/chunk-OEGE3YDK.js +11 -0
  215. package/dist/standalone/chunk-OG57FC7W.js +1 -0
  216. package/dist/standalone/chunk-PQICDSPP.js +1 -0
  217. package/dist/standalone/chunk-PSPJORP6.js +1 -0
  218. package/dist/standalone/chunk-PZ4QDWTI.js +1 -0
  219. package/dist/standalone/chunk-QHQTOESO.js +1 -0
  220. package/dist/standalone/chunk-QO4SZ4WH.js +1 -0
  221. package/dist/standalone/chunk-R5ZTCHCE.js +1 -0
  222. package/dist/standalone/chunk-RCZTUWG3.js +1 -0
  223. package/dist/standalone/chunk-RJINX3H6.js +1 -0
  224. package/dist/standalone/chunk-RLRTQOFQ.js +1 -0
  225. package/dist/standalone/chunk-RPCMQE4A.js +1 -0
  226. package/dist/standalone/chunk-SJ4CA7QG.js +1 -0
  227. package/dist/standalone/chunk-SPDZUX4P.js +1 -0
  228. package/dist/standalone/chunk-SQMJUXBA.js +1 -0
  229. package/dist/standalone/chunk-SRQP7SLQ.js +1 -0
  230. package/dist/standalone/chunk-TB5N24CM.js +1 -0
  231. package/dist/standalone/chunk-TFMQSCGC.js +1 -0
  232. package/dist/standalone/chunk-TIANWRSD.js +1 -0
  233. package/dist/standalone/chunk-TNKECJW4.js +1 -0
  234. package/dist/standalone/chunk-TPAZM36C.js +1 -0
  235. package/dist/standalone/chunk-TV2M3PHL.js +1 -0
  236. package/dist/standalone/chunk-TVGQ7K5I.js +1 -0
  237. package/dist/standalone/chunk-U7LNRJHZ.js +1 -0
  238. package/dist/standalone/chunk-UANVABQG.js +1 -0
  239. package/dist/standalone/chunk-V6QPVFDL.js +1 -0
  240. package/dist/standalone/chunk-VHXQGKA7.js +1 -0
  241. package/dist/standalone/chunk-VLW547U6.js +1 -0
  242. package/dist/standalone/chunk-VR3UJA7B.js +1 -0
  243. package/dist/standalone/chunk-VZCS5GXZ.js +1 -0
  244. package/dist/standalone/chunk-W2FXNIVC.js +1 -0
  245. package/dist/standalone/chunk-W2JBKQNU.js +1 -0
  246. package/dist/standalone/chunk-WUW4ZHRL.js +1 -0
  247. package/dist/standalone/chunk-WXBTOI6T.js +1 -0
  248. package/dist/standalone/chunk-WY33QRLH.js +9 -0
  249. package/dist/standalone/chunk-XJSWM47N.js +1 -0
  250. package/dist/standalone/chunk-XNBAJ6XA.js +1 -0
  251. package/dist/standalone/chunk-XQS7KSHL.js +1 -0
  252. package/dist/standalone/chunk-Y2YQITGI.js +1 -0
  253. package/dist/standalone/chunk-Z6SECRFO.js +3 -0
  254. package/dist/standalone/chunk-ZHPDAJBM.js +1 -0
  255. package/dist/standalone/chunk-ZPGNTTQ3.js +1 -0
  256. package/dist/standalone/chunk-ZSOLGJFC.js +1 -0
  257. package/dist/standalone/studio.js +9 -378
  258. package/dist/styles.css +2 -2
  259. package/package.json +16 -15
  260. package/dist/packem_shared/ADMIN_FUNCTIONS-CZJCZ4c7.js +0 -47
  261. package/dist/packem_shared/ApiDocsPanel-yEz0fiof.js +0 -842
  262. package/dist/packem_shared/ApiReferencePanel-1vubqG5s.js +0 -229
  263. package/dist/packem_shared/ApiTab-DdubReQI.js +0 -251
  264. package/dist/packem_shared/AuditPanel-CE5ofjCc.js +0 -200
  265. package/dist/packem_shared/CommandPalette-BtgkBzZI.js +0 -373
  266. package/dist/packem_shared/ConfirmButton-C2eVi2Qv.js +0 -59
  267. package/dist/packem_shared/ConnectionBadge-B2DDM2Tn.js +0 -111
  268. package/dist/packem_shared/DEFAULT_AUTO_REFRESH_MS-Vxwaxx51.js +0 -50
  269. package/dist/packem_shared/DEFAULT_INSIGHT_THRESHOLDS-DjF0h-gA.js +0 -89
  270. package/dist/packem_shared/DEFAULT_LOCALE-CiX4W7Kr.js +0 -27
  271. package/dist/packem_shared/DataBrowser-DpL8U-Nf.js +0 -4475
  272. package/dist/packem_shared/DataFilters-FNquMaiu.js +0 -249
  273. package/dist/packem_shared/ErrorBoundary-BzAApI7J.js +0 -66
  274. package/dist/packem_shared/ExportImportPanel-ChsSUCYZ.js +0 -197
  275. package/dist/packem_shared/FileBrowser-DsRBnVhZ.js +0 -2932
  276. package/dist/packem_shared/FunctionRunner-D4cZ6fuA.js +0 -343
  277. package/dist/packem_shared/FunctionStatsPanel-BVelWgNv.js +0 -375
  278. package/dist/packem_shared/GlobalDataBrowser-3X9uRfdO.js +0 -289
  279. package/dist/packem_shared/HealthPanel-CxUVKfvo.js +0 -648
  280. package/dist/packem_shared/HomePanel-tfqpZxuu.js +0 -1334
  281. package/dist/packem_shared/InsightsPanel-DNg3K9XN.js +0 -461
  282. package/dist/packem_shared/LogsPanel-B4LoSRj0.js +0 -827
  283. package/dist/packem_shared/MailPanel-CcpdyWYs.js +0 -440
  284. package/dist/packem_shared/MetricsPanel-CxoyWbNb.js +0 -1611
  285. package/dist/packem_shared/MigrationsPanel-DGwJGWDA.js +0 -239
  286. package/dist/packem_shared/OpenRpcReferencePanel-vbcYbv3V.js +0 -191
  287. package/dist/packem_shared/PitrPanel-CKUzyyHi.js +0 -252
  288. package/dist/packem_shared/STUDIO_ROOT_CLASS-D12gX2dV.js +0 -3
  289. package/dist/packem_shared/ScheduledJobs-BWNwIN3I.js +0 -262
  290. package/dist/packem_shared/SchemaViewer-RclXFo9Q.js +0 -2512
  291. package/dist/packem_shared/SecurityAdvisorPanel-Dqql1Z5O.js +0 -92
  292. package/dist/packem_shared/SettingsPanel-D5iTY0YE.js +0 -390
  293. package/dist/packem_shared/ShardInput-gx_DZXXn.js +0 -107
  294. package/dist/packem_shared/SqlEditorPanel-Dj-In-B3.js +0 -13
  295. package/dist/packem_shared/Studio-VWvKNOw4.js +0 -33
  296. package/dist/packem_shared/StudioApp-BhQ6T2pn.js +0 -657
  297. package/dist/packem_shared/StudioI18nProvider-B-tDCZIi.js +0 -48
  298. package/dist/packem_shared/TableEditor-BY8bTpCl.js +0 -11
  299. package/dist/packem_shared/advisor-view-CGcfMiPq.js +0 -159
  300. package/dist/packem_shared/aggregateMetrics-D4nUHEKU.js +0 -108
  301. package/dist/packem_shared/app.d-BVJFkXyj.d.ts +0 -300
  302. package/dist/packem_shared/badge-B2PKA1-5.js +0 -49
  303. package/dist/packem_shared/bar-chart-CzJAgqkp.js +0 -3245
  304. package/dist/packem_shared/button-BhsN2uZH.js +0 -49
  305. package/dist/packem_shared/card-DURq3ElK.js +0 -175
  306. package/dist/packem_shared/cf-links-2cktDedA.js +0 -8
  307. package/dist/packem_shared/checkbox-UNkzAxl-.js +0 -63
  308. package/dist/packem_shared/data-grid-B5CaV3wS.js +0 -183
  309. package/dist/packem_shared/dropdown-menu-WY4B_eJO.js +0 -280
  310. package/dist/packem_shared/empty-state-DY_oe0k6.js +0 -98
  311. package/dist/packem_shared/grid-features-CzUfqgsM.js +0 -840
  312. package/dist/packem_shared/input-XH4r1Pt1.js +0 -53
  313. package/dist/packem_shared/internal-rXJEAhXS.js +0 -68
  314. package/dist/packem_shared/label-D8ykjn5J.js +0 -46
  315. package/dist/packem_shared/live-status-FZ0psC1z.js +0 -44
  316. package/dist/packem_shared/reference-view-B4E49Lip.js +0 -2180
  317. package/dist/packem_shared/shard-history-DyebH1R5.js +0 -38
  318. package/dist/packem_shared/sparkline-10dG-_f0.js +0 -93
  319. package/dist/packem_shared/sql-editor-panel-CMdxstu5.js +0 -2562
  320. package/dist/packem_shared/storage-tier-CL98eOvn.js +0 -85
  321. package/dist/packem_shared/studio-D8ry3tJR.js +0 -11043
  322. package/dist/packem_shared/table-_RzNvy3R.js +0 -246
  323. package/dist/packem_shared/table-editor-CWx68ZCg.js +0 -407
  324. package/dist/packem_shared/table-list-sidebar-Bg7uzbvC.js +0 -832
  325. package/dist/packem_shared/textarea-D3gaCU_-.js +0 -46
  326. package/dist/packem_shared/use-admin-query-BkbdNFNz.js +0 -105
  327. package/dist/packem_shared/useDebounced-Dxncpg6z.js +0 -32
  328. package/dist/packem_shared/utils-B05Dmz_H.js +0 -8
  329. package/dist/packem_shared/virtual-rect-CVMUskSm.js +0 -10
@@ -1,375 +0,0 @@
1
- import { c } from 'react/compiler-runtime';
2
- import { useState } from 'react';
3
- import { L as LiveError } from './live-status-FZ0psC1z.js';
4
- import { ShardInput } from './ShardInput-gx_DZXXn.js';
5
- import { B as Badge } from './badge-B2PKA1-5.js';
6
- import { B as Button } from './button-BhsN2uZH.js';
7
- import { C as Card, a as CardContent } from './card-DURq3ElK.js';
8
- import { E as EmptyState } from './empty-state-DY_oe0k6.js';
9
- import { T as Table, a as TableHeader, b as TableRow, c as TableHead, d as TableBody, e as TableCell } from './table-_RzNvy3R.js';
10
- import { u as useAdminQuery } from './use-admin-query-BkbdNFNz.js';
11
- import useDebounced from './useDebounced-Dxncpg6z.js';
12
- import { useT } from './DEFAULT_LOCALE-CiX4W7Kr.js';
13
- import { ADMIN_FUNCTIONS } from './ADMIN_FUNCTIONS-CZJCZ4c7.js';
14
- import { b as formatTimestamp } from './internal-rXJEAhXS.js';
15
- import { c as cn } from './utils-B05Dmz_H.js';
16
- import { jsxDEV } from 'react/jsx-dev-runtime';
17
-
18
- const KIND_VARIANT = {
19
- action: "outline",
20
- mutation: "default",
21
- query: "secondary"
22
- };
23
- const formatMs = (ms) => {
24
- if (ms < 1e3) {
25
- return `${ms < 10 ? ms.toFixed(1) : Math.round(ms).toString()}ms`;
26
- }
27
- return `${(ms / 1e3).toFixed(2)}s`;
28
- };
29
- const errorCell = (stat) => {
30
- if (stat.calls === 0) {
31
- return "—";
32
- }
33
- if (stat.errors === 0) {
34
- return "0";
35
- }
36
- return `${stat.errors.toString()} (${(stat.errors / stat.calls * 100).toFixed(1)}%)`;
37
- };
38
- const conflictCell = (stat) => {
39
- const conflicts = stat.conflicts ?? 0;
40
- if (stat.calls === 0) {
41
- return "—";
42
- }
43
- if (conflicts === 0) {
44
- return "0";
45
- }
46
- return `${conflicts.toString()} (${(conflicts / stat.calls * 100).toFixed(1)}%)`;
47
- };
48
- const SORTERS = {
49
- calls: (a, b) => b.calls - a.calls,
50
- recent: (a, b) => b.lastCalledAt - a.lastCalledAt,
51
- slowest: (a, b) => b.maxDurationMs - a.maxDurationMs
52
- };
53
- const FunctionStatsPanel = (t0) => {
54
- const $ = c(45);
55
- const {
56
- functions,
57
- initialShardKey
58
- } = t0;
59
- const t = useT();
60
- const [shardKey, setShardKey] = useState(initialShardKey ?? "");
61
- const [sortKey, setSortKey] = useState("recent");
62
- let t1;
63
- if ($[0] !== shardKey) {
64
- t1 = shardKey.trim();
65
- $[0] = shardKey;
66
- $[1] = t1;
67
- } else {
68
- t1 = $[1];
69
- }
70
- const debouncedShard = useDebounced(t1, 400);
71
- let t2;
72
- if ($[2] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel")) {
73
- t2 = {};
74
- $[2] = t2;
75
- } else {
76
- t2 = $[2];
77
- }
78
- let t3;
79
- if ($[3] !== debouncedShard) {
80
- t3 = {
81
- live: true,
82
- shardKey: debouncedShard
83
- };
84
- $[3] = debouncedShard;
85
- $[4] = t3;
86
- } else {
87
- t3 = $[4];
88
- }
89
- const {
90
- data,
91
- error,
92
- liveError
93
- } = useAdminQuery(ADMIN_FUNCTIONS.getFunctionStats, t2, t3);
94
- const stats = data?.functions ?? null;
95
- let t4;
96
- if ($[5] !== functions) {
97
- t4 = new Map((functions ?? []).map(_temp));
98
- $[5] = functions;
99
- $[6] = t4;
100
- } else {
101
- t4 = $[6];
102
- }
103
- const kindByPath = t4;
104
- let t5;
105
- if ($[7] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel")) {
106
- t5 = (event) => {
107
- setSortKey(event.currentTarget.dataset.sort);
108
- };
109
- $[7] = t5;
110
- } else {
111
- t5 = $[7];
112
- }
113
- const selectSort = t5;
114
- let t6;
115
- if ($[8] !== error || $[9] !== kindByPath || $[10] !== liveError || $[11] !== shardKey || $[12] !== sortKey || $[13] !== stats || $[14] !== t) {
116
- const sorted = stats === null ? [] : stats.toSorted(SORTERS[sortKey]);
117
- let t7;
118
- if ($[16] !== t) {
119
- t7 = t("Recent");
120
- $[16] = t;
121
- $[17] = t7;
122
- } else {
123
- t7 = $[17];
124
- }
125
- let t8;
126
- if ($[18] !== t7) {
127
- t8 = {
128
- key: "recent",
129
- label: t7
130
- };
131
- $[18] = t7;
132
- $[19] = t8;
133
- } else {
134
- t8 = $[19];
135
- }
136
- let t9;
137
- if ($[20] !== t) {
138
- t9 = t("Most called");
139
- $[20] = t;
140
- $[21] = t9;
141
- } else {
142
- t9 = $[21];
143
- }
144
- let t10;
145
- if ($[22] !== t9) {
146
- t10 = {
147
- key: "calls",
148
- label: t9
149
- };
150
- $[22] = t9;
151
- $[23] = t10;
152
- } else {
153
- t10 = $[23];
154
- }
155
- let t11;
156
- if ($[24] !== t) {
157
- t11 = t("Slowest");
158
- $[24] = t;
159
- $[25] = t11;
160
- } else {
161
- t11 = $[25];
162
- }
163
- let t12;
164
- if ($[26] !== t11) {
165
- t12 = {
166
- key: "slowest",
167
- label: t11
168
- };
169
- $[26] = t11;
170
- $[27] = t12;
171
- } else {
172
- t12 = $[27];
173
- }
174
- let t13;
175
- if ($[28] !== t10 || $[29] !== t12 || $[30] !== t8) {
176
- t13 = [t8, t10, t12];
177
- $[28] = t10;
178
- $[29] = t12;
179
- $[30] = t8;
180
- $[31] = t13;
181
- } else {
182
- t13 = $[31];
183
- }
184
- const sortButtons = t13;
185
- let t14;
186
- if ($[32] !== shardKey) {
187
- t14 = /* @__PURE__ */ jsxDEV(ShardInput, {
188
- onChange: setShardKey,
189
- testId: "fs-shard-input",
190
- value: shardKey
191
- }, void 0, false);
192
- $[32] = shardKey;
193
- $[33] = t14;
194
- } else {
195
- t14 = $[33];
196
- }
197
- let t15;
198
- if ($[34] !== liveError) {
199
- t15 = /* @__PURE__ */ jsxDEV(LiveError, {
200
- message: liveError,
201
- prefix: "fs"
202
- }, void 0, false);
203
- $[34] = liveError;
204
- $[35] = t15;
205
- } else {
206
- t15 = $[35];
207
- }
208
- let t16;
209
- if ($[36] !== sortButtons || $[37] !== sortKey) {
210
- t16 = /* @__PURE__ */ jsxDEV("div", {
211
- className: "ml-auto flex items-center gap-1",
212
- role: "group",
213
- children: sortButtons.map((option) => /* @__PURE__ */ jsxDEV(Button, {
214
- "data-sort": option.key,
215
- "data-testid": `fs-sort-${option.key}`,
216
- onClick: selectSort,
217
- size: "sm",
218
- type: "button",
219
- variant: sortKey === option.key ? "secondary" : "ghost",
220
- children: option.label
221
- }, option.key, false))
222
- }, void 0, false);
223
- $[36] = sortButtons;
224
- $[37] = sortKey;
225
- $[38] = t16;
226
- } else {
227
- t16 = $[38];
228
- }
229
- let t17;
230
- if ($[39] !== t14 || $[40] !== t15 || $[41] !== t16) {
231
- t17 = /* @__PURE__ */ jsxDEV("div", {
232
- className: "flex flex-wrap items-center gap-2",
233
- children: [t14, t15, t16]
234
- }, void 0, true);
235
- $[39] = t14;
236
- $[40] = t15;
237
- $[41] = t16;
238
- $[42] = t17;
239
- } else {
240
- t17 = $[42];
241
- }
242
- let t18;
243
- if ($[43] !== error) {
244
- t18 = error !== null && /* @__PURE__ */ jsxDEV("p", {
245
- className: "text-sm text-destructive",
246
- "data-testid": "fs-error",
247
- role: "alert",
248
- children: error
249
- }, void 0, false);
250
- $[43] = error;
251
- $[44] = t18;
252
- } else {
253
- t18 = $[44];
254
- }
255
- t6 = /* @__PURE__ */ jsxDEV("div", {
256
- className: "flex flex-col gap-4",
257
- "data-testid": "lunora-function-stats",
258
- children: [t17, t18, stats !== null && sorted.length === 0 && error === null && /* @__PURE__ */ jsxDEV(EmptyState, {
259
- description: t("Per-function call counts, error rates, and latency land here after your first request."),
260
- icon: /* @__PURE__ */ jsxDEV("svg", {
261
- "aria-hidden": "true",
262
- fill: "none",
263
- stroke: "currentColor",
264
- strokeLinecap: "round",
265
- strokeLinejoin: "round",
266
- strokeWidth: 1.6,
267
- viewBox: "0 0 24 24",
268
- children: [/* @__PURE__ */ jsxDEV("path", {
269
- d: "M3 3v18h18"
270
- }, void 0, false), /* @__PURE__ */ jsxDEV("path", {
271
- d: "M7 14l4-4 3 3 5-6"
272
- }, void 0, false)]
273
- }, void 0, true),
274
- testId: "fs-empty",
275
- title: t("No functions have run on this shard yet.")
276
- }, void 0, false), sorted.length > 0 && /* @__PURE__ */ jsxDEV(Card, {
277
- className: "overflow-hidden py-0",
278
- children: /* @__PURE__ */ jsxDEV(CardContent, {
279
- className: "px-0",
280
- children: /* @__PURE__ */ jsxDEV(Table, {
281
- "data-testid": "fs-table",
282
- children: [/* @__PURE__ */ jsxDEV(TableHeader, {
283
- children: /* @__PURE__ */ jsxDEV(TableRow, {
284
- children: [/* @__PURE__ */ jsxDEV(TableHead, {
285
- children: t("function")
286
- }, void 0, false), /* @__PURE__ */ jsxDEV(TableHead, {
287
- children: t("kind")
288
- }, void 0, false), /* @__PURE__ */ jsxDEV(TableHead, {
289
- className: "text-right",
290
- children: t("calls")
291
- }, void 0, false), /* @__PURE__ */ jsxDEV(TableHead, {
292
- className: "text-right",
293
- children: t("errors")
294
- }, void 0, false), /* @__PURE__ */ jsxDEV(TableHead, {
295
- className: "text-right",
296
- children: t("conflicts")
297
- }, void 0, false), /* @__PURE__ */ jsxDEV(TableHead, {
298
- className: "text-right",
299
- children: t("avg")
300
- }, void 0, false), /* @__PURE__ */ jsxDEV(TableHead, {
301
- className: "text-right",
302
- children: t("max")
303
- }, void 0, false), /* @__PURE__ */ jsxDEV(TableHead, {
304
- children: t("last run")
305
- }, void 0, false), /* @__PURE__ */ jsxDEV(TableHead, {
306
- children: t("last error")
307
- }, void 0, false)]
308
- }, void 0, true)
309
- }, void 0, false), /* @__PURE__ */ jsxDEV(TableBody, {
310
- children: sorted.map((stat) => {
311
- const kind = kindByPath.get(stat.path);
312
- return /* @__PURE__ */ jsxDEV(TableRow, {
313
- "data-testid": `fs-row-${stat.path}`,
314
- children: [/* @__PURE__ */ jsxDEV(TableCell, {
315
- className: "font-medium",
316
- children: stat.path
317
- }, void 0, false), /* @__PURE__ */ jsxDEV(TableCell, {
318
- children: kind === void 0 ? /* @__PURE__ */ jsxDEV("span", {
319
- className: "text-muted-foreground",
320
- children: "—"
321
- }, void 0, false) : /* @__PURE__ */ jsxDEV(Badge, {
322
- variant: KIND_VARIANT[kind],
323
- children: kind
324
- }, void 0, false)
325
- }, void 0, false), /* @__PURE__ */ jsxDEV(TableCell, {
326
- className: "text-right tabular-nums",
327
- children: stat.calls
328
- }, void 0, false), /* @__PURE__ */ jsxDEV(TableCell, {
329
- className: cn("text-right tabular-nums", stat.errors > 0 && "text-destructive"),
330
- children: errorCell(stat)
331
- }, void 0, false), /* @__PURE__ */ jsxDEV(TableCell, {
332
- className: cn("text-right tabular-nums", (stat.conflicts ?? 0) > 0 && "text-warning"),
333
- children: conflictCell(stat)
334
- }, void 0, false), /* @__PURE__ */ jsxDEV(TableCell, {
335
- className: "text-right tabular-nums",
336
- children: stat.calls === 0 ? "—" : formatMs(stat.totalDurationMs / stat.calls)
337
- }, void 0, false), /* @__PURE__ */ jsxDEV(TableCell, {
338
- className: "text-right tabular-nums",
339
- children: stat.calls === 0 ? "—" : formatMs(stat.maxDurationMs)
340
- }, void 0, false), /* @__PURE__ */ jsxDEV(TableCell, {
341
- className: "text-muted-foreground",
342
- children: formatTimestamp(stat.lastCalledAt, "—")
343
- }, void 0, false), /* @__PURE__ */ jsxDEV(TableCell, {
344
- className: "max-w-[24ch] truncate text-destructive",
345
- title: stat.lastErrorMessage ?? void 0,
346
- children: stat.lastErrorMessage ?? /* @__PURE__ */ jsxDEV("span", {
347
- className: "text-muted-foreground",
348
- children: "—"
349
- }, void 0, false)
350
- }, void 0, false)]
351
- }, stat.path, true);
352
- })
353
- }, void 0, false)]
354
- }, void 0, true)
355
- }, void 0, false)
356
- }, void 0, false)]
357
- }, void 0, true);
358
- $[8] = error;
359
- $[9] = kindByPath;
360
- $[10] = liveError;
361
- $[11] = shardKey;
362
- $[12] = sortKey;
363
- $[13] = stats;
364
- $[14] = t;
365
- $[15] = t6;
366
- } else {
367
- t6 = $[15];
368
- }
369
- return t6;
370
- };
371
- function _temp(descriptor) {
372
- return [descriptor.path, descriptor.kind];
373
- }
374
-
375
- export { FunctionStatsPanel };
@@ -1,289 +0,0 @@
1
- import { useLunora } from '@lunora/react';
2
- import { useState, useRef, useCallback, useEffect } from 'react';
3
- import { E as EmptyState } from './empty-state-DY_oe0k6.js';
4
- import { T as Table, a as TableHeader, b as TableRow, c as TableHead, d as TableBody, e as TableCell } from './table-_RzNvy3R.js';
5
- import { b as useClientQuery } from './use-admin-query-BkbdNFNz.js';
6
- import { useAutoRefresh } from './DEFAULT_AUTO_REFRESH_MS-Vxwaxx51.js';
7
- import { useT } from './DEFAULT_LOCALE-CiX4W7Kr.js';
8
- import { b as CLOUDFLARE_D1_URL } from './cf-links-2cktDedA.js';
9
- import { u as useFacets, T as TableListSidebar, G as GridPagination, D as DataFacets } from './table-list-sidebar-Bg7uzbvC.js';
10
- import { G as GridContainer, C as CellValue } from './data-grid-B5CaV3wS.js';
11
- import { jsxDEV } from 'react/jsx-dev-runtime';
12
-
13
- const DEFAULT_PAGE_SIZE = 50;
14
- const NO_TABLES = [];
15
- const NO_COLUMNS = [];
16
- const rowKey = (row, index) => {
17
- const id = row["_id"];
18
- return typeof id === "string" || typeof id === "number" ? String(id) : `row-${index.toString()}`;
19
- };
20
- const chipValue = (value) => {
21
- if (value === null || value === void 0) {
22
- return "∅";
23
- }
24
- if (value === "") {
25
- return "(empty)";
26
- }
27
- if (typeof value === "object") {
28
- return JSON.stringify(value);
29
- }
30
- return String(value);
31
- };
32
- const GlobalDataBrowser = ({
33
- initialTable,
34
- onSelectTable,
35
- pageSize: initialPageSize = DEFAULT_PAGE_SIZE,
36
- schemaSwitch
37
- } = {}) => {
38
- const client = useLunora();
39
- const t = useT();
40
- const [selectedTable, setSelectedTable] = useState(initialTable ?? null);
41
- const [offset, setOffset] = useState(0);
42
- const [pageSize, setPageSize] = useState(initialPageSize);
43
- const [filters, setFilters] = useState([]);
44
- const filtersRef = useRef(filters);
45
- filtersRef.current = filters;
46
- const {
47
- clearFacets,
48
- facets,
49
- refetchFacets: refetchFacetsViaHook,
50
- toggleFacet
51
- } = useFacets();
52
- const tablesQuery = useClientQuery(["lunora-global-tables"], () => client.listGlobalTables());
53
- const tables = tablesQuery.data ?? null;
54
- const tablesError = tablesQuery.error;
55
- const pageQuery = useClientQuery(["lunora-global-page", selectedTable ?? "", offset, pageSize, JSON.stringify(filters)], () => client.readGlobalTablePage({
56
- filters,
57
- limit: pageSize,
58
- offset,
59
- table: selectedTable ?? ""
60
- }), {
61
- enabled: selectedTable !== null,
62
- keepPreviousData: false
63
- });
64
- const page = pageQuery.data ?? null;
65
- const pageError = pageQuery.error;
66
- const facetFetcher = (table, activeFilters) => (column) => client.facetGlobalColumn({
67
- column,
68
- filters: activeFilters,
69
- table
70
- });
71
- const refetchFacets = (table_0, activeFilters_0) => {
72
- refetchFacetsViaHook(facetFetcher(table_0, activeFilters_0));
73
- };
74
- useAutoRefresh(() => {
75
- tablesQuery.refetch();
76
- if (selectedTable !== null) {
77
- pageQuery.refetch();
78
- refetchFacets(selectedTable, filtersRef.current);
79
- }
80
- }, true);
81
- const appliedInitialTable = useRef(void 0);
82
- const selectTable = useCallback((table_1) => {
83
- setSelectedTable(table_1);
84
- appliedInitialTable.current = table_1;
85
- setFilters([]);
86
- filtersRef.current = [];
87
- clearFacets();
88
- setOffset(0);
89
- onSelectTable?.(table_1);
90
- }, [clearFacets, onSelectTable]);
91
- const onToggleFacet = (column_0) => {
92
- toggleFacet(column_0, selectedTable === null ? null : facetFetcher(selectedTable, filtersRef.current));
93
- };
94
- const applyFilters = (next) => {
95
- setFilters(next);
96
- filtersRef.current = next;
97
- setOffset(0);
98
- if (selectedTable !== null) {
99
- refetchFacets(selectedTable, next);
100
- }
101
- };
102
- const onFacetFilter = (column_1, value) => {
103
- applyFilters([...filtersRef.current.filter((clause) => clause.column !== column_1), {
104
- column: column_1,
105
- value
106
- }]);
107
- };
108
- const removeFilter = (event) => {
109
- const index = Number(event.currentTarget.dataset["index"]);
110
- applyFilters(filtersRef.current.filter((_, position) => position !== index));
111
- };
112
- useEffect(() => {
113
- if (initialTable === void 0 || initialTable === "" || appliedInitialTable.current === initialTable) {
114
- return;
115
- }
116
- appliedInitialTable.current = initialTable;
117
- const target = initialTable;
118
- queueMicrotask(() => {
119
- selectTable(target);
120
- });
121
- }, [initialTable, selectTable]);
122
- const goToPage = (nextOffset) => {
123
- if (selectedTable === null) {
124
- return;
125
- }
126
- setOffset(Math.max(0, nextOffset));
127
- };
128
- const total = page?.total ?? 0;
129
- const hasPrevious = offset > 0;
130
- const hasNext = page !== null && offset + page.rows.length < total;
131
- const rangeStart = page === null || page.rows.length === 0 ? 0 : offset + 1;
132
- const rangeEnd = page === null ? 0 : offset + page.rows.length;
133
- const reloadTables = () => {
134
- tablesQuery.refetch();
135
- };
136
- const goPrevious = () => {
137
- goToPage(offset - pageSize);
138
- };
139
- const goNext = () => {
140
- goToPage(offset + pageSize);
141
- };
142
- const jumpToPage = (targetPage) => {
143
- goToPage(Math.max(0, (targetPage - 1) * pageSize));
144
- };
145
- const changePageSize = (size) => {
146
- setPageSize(size);
147
- setOffset(0);
148
- };
149
- return /* @__PURE__ */ jsxDEV("div", {
150
- className: "flex h-full min-w-0",
151
- "data-testid": "lunora-global-data-browser",
152
- children: [/* @__PURE__ */ jsxDEV(TableListSidebar, {
153
- header: /* @__PURE__ */ jsxDEV("div", {
154
- className: "flex shrink-0 flex-col items-stretch gap-2 border-b border-border p-3",
155
- children: [schemaSwitch, /* @__PURE__ */ jsxDEV("a", {
156
- className: "text-sm text-primary underline-offset-4 hover:underline",
157
- "data-testid": "gdb-cf-link",
158
- href: CLOUDFLARE_D1_URL,
159
- rel: "noreferrer",
160
- target: "_blank",
161
- children: t("Open in Cloudflare")
162
- }, void 0, false)]
163
- }, void 0, true),
164
- onReload: reloadTables,
165
- onSelect: selectTable,
166
- prefix: "gdb",
167
- selected: selectedTable,
168
- tables: tables ?? NO_TABLES
169
- }, void 0, false), /* @__PURE__ */ jsxDEV("div", {
170
- className: "flex min-w-0 flex-1 flex-col overflow-hidden",
171
- children: [tablesError !== null && /* @__PURE__ */ jsxDEV("p", {
172
- className: "shrink-0 border-b border-border px-4 py-2 text-sm text-destructive",
173
- "data-testid": "gdb-tables-error",
174
- role: "alert",
175
- children: tablesError
176
- }, void 0, false), tables !== null && tables.length === 0 && /* @__PURE__ */ jsxDEV("div", {
177
- className: "flex flex-1 items-center justify-center p-6",
178
- children: /* @__PURE__ */ jsxDEV(EmptyState, {
179
- description: t("Tables marked .global() (D1-backed, region-replicated) will appear here."),
180
- icon: /* @__PURE__ */ jsxDEV("svg", {
181
- "aria-hidden": "true",
182
- fill: "none",
183
- stroke: "currentColor",
184
- strokeLinecap: "round",
185
- strokeLinejoin: "round",
186
- strokeWidth: 1.6,
187
- viewBox: "0 0 24 24",
188
- children: [/* @__PURE__ */ jsxDEV("circle", {
189
- cx: "12",
190
- cy: "12",
191
- r: "9"
192
- }, void 0, false), /* @__PURE__ */ jsxDEV("path", {
193
- d: "M3 12h18M12 3a14 14 0 0 1 0 18 14 14 0 0 1 0-18Z"
194
- }, void 0, false)]
195
- }, void 0, true),
196
- testId: "gdb-empty",
197
- title: t("No global tables.")
198
- }, void 0, false)
199
- }, void 0, false), pageError !== null && /* @__PURE__ */ jsxDEV("p", {
200
- className: "shrink-0 border-b border-border px-4 py-2 text-sm text-destructive",
201
- "data-testid": "gdb-page-error",
202
- role: "alert",
203
- children: pageError
204
- }, void 0, false), tables !== null && tables.length > 0 && page === null && pageError === null && /* @__PURE__ */ jsxDEV("div", {
205
- className: "flex flex-1 items-center justify-center p-6",
206
- children: /* @__PURE__ */ jsxDEV("p", {
207
- className: "text-sm text-muted-foreground",
208
- children: t("Select a table to browse its rows.")
209
- }, void 0, false)
210
- }, void 0, false), page !== null && /* @__PURE__ */ jsxDEV("div", {
211
- className: "flex min-h-0 flex-1 flex-col",
212
- "data-testid": "gdb-page",
213
- children: [filters.length > 0 && /* @__PURE__ */ jsxDEV("div", {
214
- className: "flex shrink-0 flex-wrap items-center gap-1.5 border-b border-border px-4 py-2 text-xs",
215
- "data-testid": "gdb-filters",
216
- children: filters.map((filter, index_0) => /* @__PURE__ */ jsxDEV("span", {
217
- className: "inline-flex items-center gap-1 rounded border border-border bg-muted px-1.5 py-0.5",
218
- "data-testid": "gdb-filter-chip",
219
- children: [/* @__PURE__ */ jsxDEV("span", {
220
- className: "font-medium text-foreground",
221
- children: filter.column
222
- }, void 0, false), /* @__PURE__ */ jsxDEV("span", {
223
- className: "text-muted-foreground",
224
- children: "="
225
- }, void 0, false), /* @__PURE__ */ jsxDEV("span", {
226
- className: "font-mono text-foreground",
227
- children: chipValue(filter.value)
228
- }, void 0, false), /* @__PURE__ */ jsxDEV("button", {
229
- "aria-label": t("Remove filter"),
230
- className: "ml-0.5 text-muted-foreground hover:text-foreground",
231
- "data-index": index_0,
232
- "data-testid": "gdb-filter-remove",
233
- onClick: removeFilter,
234
- type: "button",
235
- children: "✕"
236
- }, void 0, false)]
237
- }, `${filter.column}:${chipValue(filter.value)}`, true))
238
- }, void 0, false), /* @__PURE__ */ jsxDEV(GridContainer, {
239
- layout: "fill",
240
- children: /* @__PURE__ */ jsxDEV("div", {
241
- className: "min-h-0 flex-1 overflow-auto",
242
- children: /* @__PURE__ */ jsxDEV(Table, {
243
- "data-testid": "gdb-rows",
244
- children: [/* @__PURE__ */ jsxDEV(TableHeader, {
245
- children: /* @__PURE__ */ jsxDEV(TableRow, {
246
- children: page.columns.map((column_2) => /* @__PURE__ */ jsxDEV(TableHead, {
247
- children: column_2
248
- }, column_2, false))
249
- }, void 0, false)
250
- }, void 0, false), /* @__PURE__ */ jsxDEV(TableBody, {
251
- children: page.rows.map((row, rowIndex) => /* @__PURE__ */ jsxDEV(TableRow, {
252
- "data-testid": "gdb-row",
253
- children: page.columns.map((column_3) => /* @__PURE__ */ jsxDEV(TableCell, {
254
- className: "max-w-xs truncate font-mono text-xs",
255
- children: /* @__PURE__ */ jsxDEV(CellValue, {
256
- value: row[column_3]
257
- }, void 0, false)
258
- }, column_3, false))
259
- }, rowKey(row, rowIndex), false))
260
- }, void 0, false)]
261
- }, void 0, true)
262
- }, void 0, false)
263
- }, void 0, false), /* @__PURE__ */ jsxDEV("div", {
264
- className: "flex shrink-0 items-center border-t border-border px-4 py-2",
265
- children: /* @__PURE__ */ jsxDEV(GridPagination, {
266
- hasNext,
267
- hasPrevious,
268
- onJumpToPage: jumpToPage,
269
- onNext: goNext,
270
- onPageSizeChange: changePageSize,
271
- onPrevious: goPrevious,
272
- pageSize,
273
- prefix: "gdb",
274
- rangeEnd,
275
- rangeStart,
276
- total
277
- }, void 0, false)
278
- }, void 0, false)]
279
- }, void 0, true)]
280
- }, void 0, true), /* @__PURE__ */ jsxDEV(DataFacets, {
281
- columns: page?.columns ?? NO_COLUMNS,
282
- facets,
283
- onFacetFilter,
284
- onToggleFacet
285
- }, void 0, false)]
286
- }, void 0, true);
287
- };
288
-
289
- export { GlobalDataBrowser };