@hot-updater/console 1.0.0-rc.5 → 1.0.0-rc.7

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 (153) hide show
  1. package/.output/nitro.json +1 -1
  2. package/.output/public/assets/HashValueDisplay-CY2Cai48.js +1 -0
  3. package/.output/public/assets/InsightsPageHeader-DC2eEst8.js +1 -0
  4. package/.output/public/assets/api-CdUyUqzR.js +42 -0
  5. package/.output/public/assets/api-keys-CWfHO6DY.js +1 -0
  6. package/.output/public/assets/api-keys-api-BeaJnvY5.js +1 -0
  7. package/.output/public/assets/arrow-left-04Rh8Zgp.js +1 -0
  8. package/.output/public/assets/card-CYHs5FZv.js +1 -0
  9. package/.output/public/assets/{chart-no-axes-combined-Bv9jjbPt.js → chart-no-axes-combined-DwyMsVFW.js} +1 -1
  10. package/.output/public/assets/{createServerFn-Uk1tYGbn.js → createServerFn-DU71xucx.js} +1 -1
  11. package/.output/public/assets/dialog-Dbuw0R4e.js +1 -0
  12. package/.output/public/assets/{dist-CvNT2u7Y.js → dist--1mhr9Bo.js} +1 -1
  13. package/.output/public/assets/{field-DLL1Lnpm.js → field-B3CYDpjg.js} +1 -1
  14. package/.output/public/assets/index-DtyGtumE.js +10 -0
  15. package/.output/public/assets/info-C3y9HNoU.js +1 -0
  16. package/.output/public/assets/input-group-nLZylhWF.js +1 -0
  17. package/.output/public/assets/insights-B1jNm97C.js +1 -0
  18. package/.output/public/assets/insights-C_2j568D.js +2 -0
  19. package/.output/public/assets/insights-search-Byj3g3Mp.js +1 -0
  20. package/.output/public/assets/insights-usage-rpc-BXtlz1S0.js +1 -0
  21. package/.output/public/assets/insights_.distribution-BwKYrVUv.js +1 -0
  22. package/.output/public/assets/insights_.distribution-ByJobL9p.js +2 -0
  23. package/.output/public/assets/installations-CGObvuL8.js +1 -0
  24. package/.output/public/assets/installations-fhsURlc2.js +2 -0
  25. package/.output/public/assets/lazyRouteComponent-BapzjYnb.js +1 -0
  26. package/.output/public/assets/list-Dqt53fWZ.js +1 -0
  27. package/.output/public/assets/loader-circle-CUKfUqow.js +1 -0
  28. package/.output/public/assets/{refresh-cw-B6rCZ8s9.js → refresh-cw-CNE_2PnD.js} +1 -1
  29. package/.output/public/assets/{routes-X_UMzFr3.js → routes-BKnnJLD3.js} +2 -2
  30. package/.output/public/assets/routes-BZVv_cIP.js +1 -0
  31. package/.output/public/assets/shield-check-BFcJ46kz.js +1 -0
  32. package/.output/public/assets/signing-BgspC-xP.js +1 -0
  33. package/.output/public/assets/styles-DnrWuBwd.css +2 -0
  34. package/.output/public/assets/{table-BtqGYQM-.js → table-BuWQgxJJ.js} +1 -1
  35. package/.output/public/assets/useMutation-CSV9NCUl.js +1 -0
  36. package/.output/public/assets/useOpenInteractionType-r8C6rVqm.js +1 -0
  37. package/.output/public/assets/valueToPercent-eWmbHiZg.js +1 -0
  38. package/.output/server/{__23tanstack-start-server-fn-resolver-CX8b6Ieu.mjs → __23tanstack-start-server-fn-resolver-Dg6mvjrg.mjs} +38 -34
  39. package/.output/server/_libs/@base-ui/react+[...].mjs +6025 -2498
  40. package/.output/server/_libs/@tanstack/react-router+[...].mjs +1 -1
  41. package/.output/server/_libs/@tanstack/react-router-ssr-query+[...].mjs +1 -1
  42. package/.output/server/_libs/lucide-react.mjs +2 -24
  43. package/.output/server/_libs/next-themes.mjs +1 -1
  44. package/.output/server/_libs/react-redux+[...].mjs +1 -1
  45. package/.output/server/_libs/recharts+[...].mjs +1 -1
  46. package/.output/server/_libs/sonner.mjs +1 -1
  47. package/.output/server/_libs/tanstack__react-query.mjs +1 -1
  48. package/.output/server/_ssr/HashValueDisplay-DyyzNuzZ.mjs +55 -0
  49. package/.output/server/_ssr/InsightsPageHeader-B3fWWegB.mjs +64 -0
  50. package/.output/server/_ssr/api-BZ-OvJCh.mjs +332 -0
  51. package/.output/server/_ssr/{api-keys-BOVatw-r.mjs → api-keys-DQo0lq3_.mjs} +9 -10
  52. package/.output/server/_ssr/{api-keys-api-DG6xyoPF.mjs → api-keys-api-TEyo6WfP.mjs} +2 -2
  53. package/.output/server/_ssr/{api-keys-rpc-DWI6bPQ-.mjs → api-keys-rpc-CmTC7jBa.mjs} +3 -3
  54. package/.output/server/_ssr/{api-rpc-DSIN4PPT.mjs → api-rpc-BKjnp3TJ.mjs} +25 -25
  55. package/.output/server/_ssr/{auth-rpc-BPqnsCDM.mjs → auth-rpc-UCf_vmlp.mjs} +4 -4
  56. package/.output/server/_ssr/{auth.server-DF_shCeq.mjs → auth.server-CmicHh0J.mjs} +1 -1
  57. package/.output/server/_ssr/{bundle-signing-rpc-Ddwc4bsv.mjs → bundle-signing-rpc-iSr-Ngwt.mjs} +2 -2
  58. package/.output/server/_ssr/{bundle-signing.server-Co_zHdJx.mjs → bundle-signing.server-Uqt1OF49.mjs} +1 -1
  59. package/.output/server/_ssr/{bundleActivity-D3_fIda2.mjs → bundleActivity-pBrPSG01.mjs} +3 -2
  60. package/.output/server/_ssr/{card-B79JYsvR.mjs → card-B_gzKhRe.mjs} +26 -11
  61. package/.output/server/_ssr/{config.server-D0JkB6U4.mjs → config.server-BkYL6fW9.mjs} +6 -6
  62. package/.output/server/_ssr/{createSsrRpc-3r1y0Bmq.mjs → createSsrRpc-C34Dal5W.mjs} +3 -4
  63. package/.output/server/_ssr/{deleteBundle-BAq3JuGr.mjs → deleteBundle-8X-jq7Z7.mjs} +1 -1
  64. package/.output/server/_ssr/{dialog-DgJ2kAaK.mjs → dialog-Ds_i5bv-.mjs} +2 -2
  65. package/.output/server/_ssr/{downloadBundle-B3ert-pY.mjs → downloadBundle-CI7JUKvC.mjs} +1 -1
  66. package/.output/server/_ssr/{field-BMaE6S3_.mjs → field-ld8e_WUj.mjs} +3 -3
  67. package/.output/server/_ssr/{getBundleChildren-COMt16m_.mjs → getBundleChildren-DoL8l_AS.mjs} +1 -1
  68. package/.output/server/_ssr/{input-group-BURIlvNd.mjs → input-group-DULLqCud.mjs} +3 -52
  69. package/.output/server/_ssr/insights-CYvWpnAZ.mjs +935 -0
  70. package/.output/server/_ssr/insights-jLos2FOi.mjs +10 -0
  71. package/.output/server/_ssr/insights-recovery-Cv6RSyeR.mjs +21 -0
  72. package/.output/server/_ssr/{insights-recovery-rpc-Bp3EQFDD.mjs → insights-recovery-rpc-BYbyVb92.mjs} +4 -4
  73. package/.output/server/_ssr/{insights-rpc-BZeGMuMR.mjs → insights-rpc-DS_BoE-v.mjs} +2 -2
  74. package/.output/server/_ssr/insights-search-1czJMZgk.mjs +21 -0
  75. package/.output/server/_ssr/insights-usage-rpc-BWExUEjD.mjs +24 -0
  76. package/.output/server/_ssr/insights-usage-rpc-CJCoqMOF.mjs +184 -0
  77. package/.output/server/_ssr/{insightsContract-fjJDBeEE.mjs → insightsContract-B09K_Px1.mjs} +5 -5
  78. package/.output/server/_ssr/insightsHistory-Ci4rYAgl.mjs +41 -0
  79. package/.output/server/_ssr/{insightsRecovery-CqcosG7B.mjs → insightsRecovery-CaghWL2t.mjs} +15 -51
  80. package/.output/server/_ssr/insightsUsage-DNIj6jxF.mjs +71 -0
  81. package/.output/server/_ssr/insights_.distribution-DiTfPsb7.mjs +10 -0
  82. package/.output/server/_ssr/insights_.distribution-ixF84W1_.mjs +319 -0
  83. package/.output/server/_ssr/{installations-B4AN-_gL.mjs → installations-CLtFq-gD.mjs} +2 -2
  84. package/.output/server/_ssr/{installations-BNSWpbtl.mjs → installations-CUrqA6LX.mjs} +100 -30
  85. package/.output/server/_ssr/{router-BYuF-H6C.mjs → router-DckMSIPJ.mjs} +36 -31
  86. package/.output/server/_ssr/{routes-CJq12AZ1.mjs → routes-BBb0K8Sd.mjs} +39 -298
  87. package/.output/server/_ssr/{routes-_aFllfGW.mjs → routes-IZNP7l0O.mjs} +2 -2
  88. package/.output/server/_ssr/{runtime.server-jmZOKIQM.mjs → runtime.server-CsiKFp_Z.mjs} +9 -11
  89. package/.output/server/_ssr/select-VIcRoXiO.mjs +107 -0
  90. package/.output/server/_ssr/{server-DmoJpdLc.mjs → server-4_Ats6nF.mjs} +4 -4
  91. package/.output/server/_ssr/{signing-gz6cUqZ0.mjs → signing-DuuE3pAM.mjs} +5 -6
  92. package/.output/server/_ssr/ssr.mjs +1 -1
  93. package/.output/server/_ssr/{table-CQ_LGNmg.mjs → table-CnGb5bTm.mjs} +2 -2
  94. package/.output/server/_tanstack-start-manifest_v-BRzxTsLK.mjs +125 -0
  95. package/.output/server/index.mjs +222 -166
  96. package/package.json +5 -5
  97. package/src/components/AppSidebar.tsx +3 -1
  98. package/src/components/features/bundles/BundleActivityChart.tsx +3 -2
  99. package/src/components/features/bundles/BundleInsightsSummary.tsx +14 -9
  100. package/src/components/features/insights/AppUsage.tsx +339 -0
  101. package/src/components/features/insights/EventDetails.tsx +29 -32
  102. package/src/components/features/insights/EventHistoryCard.tsx +2 -2
  103. package/src/components/features/insights/EventHistoryList.tsx +2 -2
  104. package/src/components/features/insights/InsightsControls.tsx +163 -98
  105. package/src/components/features/insights/InsightsInfo.tsx +48 -0
  106. package/src/components/features/insights/InsightsOverview.tsx +306 -291
  107. package/src/components/features/insights/InsightsPageHeader.tsx +7 -3
  108. package/src/components/features/insights/InsightsPeriodSelector.tsx +34 -0
  109. package/src/components/features/insights/InstallationHistoryCard.tsx +2 -2
  110. package/src/components/features/insights/ReportingDevicesSummary.tsx +38 -52
  111. package/src/components/ui/button.tsx +0 -1
  112. package/src/components/ui/card.tsx +1 -1
  113. package/src/components/ui/scroll-area.tsx +52 -0
  114. package/src/components/ui/tabs.tsx +81 -0
  115. package/src/components/ui/toggle.tsx +0 -2
  116. package/src/lib/insights-recovery.ts +11 -4
  117. package/src/lib/insights-search.ts +47 -0
  118. package/src/lib/insights-usage-rpc.ts +23 -0
  119. package/src/lib/insights-usage.ts +38 -0
  120. package/src/lib/insights-view.ts +1 -1
  121. package/src/lib/server/insightsRecovery.ts +18 -17
  122. package/src/lib/server/insightsUsage.ts +124 -0
  123. package/src/routeTree.gen.ts +21 -0
  124. package/src/routes/insights.tsx +68 -23
  125. package/src/routes/insights_.distribution.tsx +381 -0
  126. package/.output/public/assets/api-keys-DcYdfdNG.js +0 -1
  127. package/.output/public/assets/api-keys-api-kDN7V4OY.js +0 -1
  128. package/.output/public/assets/badge-L4cOWy6Z.js +0 -1
  129. package/.output/public/assets/card-DnfeBwhR.js +0 -1
  130. package/.output/public/assets/composite-oU5XktWd.js +0 -1
  131. package/.output/public/assets/dialog-CwLHSTeT.js +0 -1
  132. package/.output/public/assets/index-COxCg0Y6.js +0 -10
  133. package/.output/public/assets/input-group-BilojNf7.js +0 -1
  134. package/.output/public/assets/insights-_ysml0BN.js +0 -1
  135. package/.output/public/assets/insights-api-UvxnIGfB.js +0 -1
  136. package/.output/public/assets/installations-S0oPNAna.js +0 -2
  137. package/.output/public/assets/installations-_zEIKyff.js +0 -1
  138. package/.output/public/assets/lazyRouteComponent-YPHAw-9b.js +0 -1
  139. package/.output/public/assets/link-CcxgswtU.js +0 -1
  140. package/.output/public/assets/list-BzdfVfE1.js +0 -1
  141. package/.output/public/assets/loader-circle-DXAjNvli.js +0 -1
  142. package/.output/public/assets/routes-B1W045iN.js +0 -1
  143. package/.output/public/assets/shield-check-D-b8UDFG.js +0 -1
  144. package/.output/public/assets/signing-Jf8EkG_w.js +0 -1
  145. package/.output/public/assets/styles-B64HNSdQ.css +0 -2
  146. package/.output/public/assets/useCompositeListItem-BjYzBZLa.js +0 -42
  147. package/.output/server/_ssr/badge-BQdBTXtR.mjs +0 -28
  148. package/.output/server/_ssr/chart-DMAci6y0.mjs +0 -162
  149. package/.output/server/_ssr/insights-B8TmDBE_.mjs +0 -579
  150. package/.output/server/_ssr/insights-api-DYWKemuA.mjs +0 -135
  151. package/.output/server/_ssr/insights-recovery-DSFM-YTL.mjs +0 -21
  152. package/.output/server/_tanstack-start-manifest_v-B8cw7ow_.mjs +0 -102
  153. /package/.output/public/assets/{preload-helper-B_l5jfgx.js → preload-helper-ClBMtM1g.js} +0 -0
@@ -0,0 +1 @@
1
+ import{En as e,On as t,Rr as n,Vr as r,cr as i,kn as a,m as o,nr as s,tr as c}from"./createServerFn-DU71xucx.js";import{a as l,i as u,n as d,r as f,s as p,t as m}from"./field-B3CYDpjg.js";import{a as h,i as ee,o as g,r as _}from"./api-keys-api-BeaJnvY5.js";import{t as v}from"./loader-circle-CUKfUqow.js";import{T as te,_ as y,a as b,d as x,f as ne,g as re,h as S,i as C,l as w,m as T,n as E,o as D,p as O,r as k,t as A,u as j,v as M}from"./dialog-Dbuw0R4e.js";import{t as N}from"./refresh-cw-CNE_2PnD.js";import{a as P,i as F,n as I,o as L,r as R,t as z}from"./table-BuWQgxJJ.js";import{n as B}from"./dist--1mhr9Bo.js";import{a as V,c as H,d as U,l as W,n as G,o as K,s as q,t as J,u as Y}from"./card-CYHs5FZv.js";var X=s(`clipboard`,[[`rect`,{width:`8`,height:`4`,x:`8`,y:`2`,rx:`1`,ry:`1`,key:`tgr4d6`}],[`path`,{d:`M16 4h2a2 2 0 0 1 2 2v14a2 2 0 0 1-2 2H6a2 2 0 0 1-2-2V6a2 2 0 0 1 2-2h2`,key:`116196`}]]),Z=s(`shield-off`,[[`path`,{d:`m2 2 20 20`,key:`1ooewy`}],[`path`,{d:`M5 5a1 1 0 0 0-1 1v7c0 5 3.5 7.5 7.67 8.94a1 1 0 0 0 .67.01c2.35-.82 4.48-1.97 5.9-3.71`,key:`1jlk70`}],[`path`,{d:`M9.309 3.652A12.252 12.252 0 0 0 11.24 2.28a1.17 1.17 0 0 1 1.52 0C14.51 3.81 17 5 19 5a1 1 0 0 1 1 1v7a9.784 9.784 0 0 1-.08 1.264`,key:`18rp1v`}]]),Q=r(n(),1),$=i(),ie=e=>new Date(e).toISOString().slice(0,10);function ae(){let[e,n]=(0,Q.useState)(!1),[r,i]=(0,Q.useState)(``),[o,s]=(0,Q.useState)(null),c=ee(),h=r.trim(),_=h.length>64?`Name must be 64 characters or fewer.`:null,y=()=>{i(``),s(null),c.reset()},x=e=>{n(e),e||y()};return(0,$.jsxs)($.Fragment,{children:[(0,$.jsxs)(a,{onClick:()=>n(!0),children:[(0,$.jsx)(te,{"data-icon":`inline-start`}),`Create API key`]}),(0,$.jsx)(A,{open:e,onOpenChange:x,children:(0,$.jsxs)(E,{showCloseButton:o===null,children:[(0,$.jsxs)(b,{children:[(0,$.jsx)(D,{children:o===null?`Create API key`:`Save your API key`}),(0,$.jsx)(k,{children:o===null?`Name the app or environment that will use this key.`:`This key is shown once. Store it securely before closing.`})]}),o===null?(0,$.jsxs)(`form`,{onSubmit:async e=>{if(e.preventDefault(),!(h.length===0||_!==null))try{s((await c.mutateAsync(h)).apiKey),B.success(`API key created`)}catch(e){B.error(e instanceof Error?e.message:`Unable to create API key`)}},children:[(0,$.jsx)(u,{children:(0,$.jsxs)(m,{"data-invalid":_!==null||void 0,children:[(0,$.jsx)(l,{htmlFor:`api-key-name`,children:`Name`}),(0,$.jsx)(t,{id:`api-key-name`,autoComplete:`off`,maxLength:65,onChange:e=>i(e.target.value),placeholder:`Production app`,value:r}),(0,$.jsx)(d,{children:`Use a name you can identify before revoking the key.`}),(0,$.jsx)(f,{children:_})]})}),(0,$.jsx)(C,{className:`mt-4`,children:(0,$.jsxs)(a,{disabled:c.isPending||h.length===0||_!==null,type:`submit`,children:[c.isPending?(0,$.jsx)(v,{"data-icon":`inline-start`,className:`animate-spin`}):(0,$.jsx)(g,{"data-icon":`inline-start`}),`Create API key`]})})]}):(0,$.jsxs)(u,{children:[(0,$.jsxs)(m,{children:[(0,$.jsx)(l,{htmlFor:`created-api-key`,children:`API key`}),(0,$.jsxs)(`div`,{className:`flex gap-2`,children:[(0,$.jsx)(t,{id:`created-api-key`,className:`font-mono`,readOnly:!0,value:o}),(0,$.jsxs)(a,{onClick:async()=>{if(o!==null)try{await navigator.clipboard.writeText(o),B.success(`API key copied`)}catch{B.error(`Unable to copy API key`)}},type:`button`,variant:`outline`,children:[(0,$.jsx)(X,{"data-icon":`inline-start`}),`Copy`]})]})]}),(0,$.jsx)(C,{children:(0,$.jsxs)(a,{onClick:()=>x(!1),children:[(0,$.jsx)(p,{"data-icon":`inline-start`}),`Done`]})})]})]})})]})}function oe({record:e}){let[t,n]=(0,Q.useState)(!1),r=h(),i=async t=>{t.preventDefault();try{await r.mutateAsync(e.id),n(!1),B.success(`API key revoked`)}catch(e){B.error(e instanceof Error?e.message:`Unable to revoke API key`)}};return(0,$.jsxs)(w,{open:t,onOpenChange:e=>{r.isPending||n(e)},children:[(0,$.jsxs)(M,{render:(0,$.jsx)(a,{size:`sm`,variant:`ghost`}),children:[(0,$.jsx)(Z,{"data-icon":`inline-start`}),`Revoke`]}),(0,$.jsxs)(ne,{children:[(0,$.jsxs)(S,{children:[(0,$.jsx)(re,{children:(0,$.jsx)(Z,{})}),(0,$.jsxs)(y,{children:[`Revoke `,e.name,`?`]}),(0,$.jsxs)(O,{children:[`Apps using `,e.prefix,`… will immediately lose OTA update and insights access. This action cannot be undone.`]})]}),(0,$.jsxs)(T,{children:[(0,$.jsx)(x,{disabled:r.isPending,children:`Cancel`}),(0,$.jsx)(j,{disabled:r.isPending,onClick:e=>void i(e),variant:`destructive`,children:`Revoke API key`})]})]})]})}function se(){let t=_();return(0,$.jsxs)(J,{className:`overflow-hidden shadow-sm`,children:[(0,$.jsxs)(V,{className:`flex-row items-center justify-between space-y-0 border-b px-4 py-3`,children:[(0,$.jsx)(K,{className:`text-sm`,children:(0,$.jsx)(`h2`,{children:`API keys`})}),(0,$.jsx)(ae,{})]}),(0,$.jsx)(G,{className:`p-0`,children:t.isError?(0,$.jsx)(`div`,{className:`p-4`,children:(0,$.jsxs)(H,{variant:`destructive`,children:[(0,$.jsx)(c,{}),(0,$.jsx)(U,{children:`API keys couldn't be loaded`}),(0,$.jsx)(Y,{children:`Check your connection and try again.`}),(0,$.jsx)(W,{children:(0,$.jsxs)(a,{onClick:()=>void t.refetch(),size:`xs`,variant:`outline`,children:[(0,$.jsx)(N,{"data-icon":`inline-start`}),`Retry`]})})]})}):(0,$.jsxs)(z,{"aria-label":`API keys`,className:`table-fixed`,children:[(0,$.jsx)(P,{children:(0,$.jsxs)(L,{children:[(0,$.jsx)(F,{children:`Key`}),(0,$.jsx)(F,{className:`w-32`,children:`Created`}),(0,$.jsx)(F,{className:`w-24 text-right`,children:(0,$.jsx)(`span`,{className:`sr-only`,children:`Actions`})})]})}),(0,$.jsx)(I,{children:t.isLoading?Array.from({length:3},(t,n)=>(0,$.jsxs)(L,{children:[(0,$.jsxs)(R,{className:`space-y-2 py-3`,children:[n===0?(0,$.jsx)(`span`,{className:`sr-only`,children:`Loading API keys`}):null,(0,$.jsx)(e,{className:`h-3.5 w-32`}),(0,$.jsx)(e,{className:`h-3 w-20`})]}),(0,$.jsx)(R,{children:(0,$.jsx)(e,{className:`h-3.5 w-20`})}),(0,$.jsx)(R,{children:(0,$.jsx)(e,{className:`ml-auto h-6 w-16`})})]},n)):t.data?.length===0?(0,$.jsx)(L,{children:(0,$.jsx)(R,{colSpan:3,className:`h-40 text-center text-muted-foreground`,children:(0,$.jsxs)(`div`,{className:`mx-auto flex max-w-xs flex-col items-center gap-2`,children:[(0,$.jsx)(g,{className:`size-5`}),(0,$.jsx)(`p`,{className:`font-medium text-foreground`,children:`No API keys`}),(0,$.jsx)(`p`,{children:`Create an API key to connect an app.`})]})})}):t.data?.map(e=>(0,$.jsxs)(L,{className:e.revoked_at_ms===null?void 0:`text-muted-foreground`,children:[(0,$.jsx)(R,{className:`whitespace-normal py-3`,children:(0,$.jsxs)(`div`,{className:`min-w-0 space-y-1`,children:[(0,$.jsx)(`p`,{className:`break-words font-medium text-foreground`,children:e.name}),(0,$.jsxs)(`p`,{className:`font-mono text-xs text-muted-foreground`,children:[e.prefix,`…`]})]})}),(0,$.jsx)(R,{className:`text-xs text-muted-foreground`,children:(0,$.jsx)(`time`,{dateTime:new Date(e.created_at_ms).toISOString(),children:ie(e.created_at_ms)})}),(0,$.jsx)(R,{className:`text-right`,children:e.revoked_at_ms===null?(0,$.jsx)(oe,{record:e}):(0,$.jsx)(q,{variant:`outline`,children:`Revoked`})})]},e.id))})]})})]})}function ce(){return(0,$.jsxs)(`div`,{className:`flex h-svh min-h-0 flex-col`,children:[(0,$.jsxs)(`header`,{className:`sticky top-0 z-10 flex shrink-0 flex-wrap items-center gap-x-3 gap-y-1 border-b bg-background px-3 py-3 sm:min-h-12 sm:flex-nowrap sm:bg-card/70 sm:px-4 sm:backdrop-blur-sm`,children:[(0,$.jsx)(o,{className:`-ml-1`}),(0,$.jsxs)(`div`,{className:`flex items-center gap-1.5`,children:[(0,$.jsx)(g,{"aria-hidden":`true`,className:`size-3.5 text-muted-foreground`}),(0,$.jsx)(`h1`,{className:`text-sm font-medium`,children:`API keys`})]}),(0,$.jsx)(`p`,{className:`basis-full pl-9 text-xs text-muted-foreground sm:basis-auto sm:pl-0`,children:`API keys can download OTA updates and submit insights only.`})]}),(0,$.jsx)(`div`,{className:`min-h-0 min-w-0 flex-1 overflow-y-auto bg-muted/5 p-3 sm:p-6`,children:(0,$.jsx)(`div`,{className:`mx-auto w-full max-w-5xl`,children:(0,$.jsx)(se,{})})})]})}export{ce as component};
@@ -0,0 +1 @@
1
+ import{Or as e,ar as t,jr as n,nr as r,sr as i,t as a}from"./createServerFn-DU71xucx.js";import{t as o}from"./useMutation-CSV9NCUl.js";var s=r(`key-round`,[[`path`,{d:`M2.586 17.414A2 2 0 0 0 2 18.828V21a1 1 0 0 0 1 1h3a1 1 0 0 0 1-1v-1a1 1 0 0 1 1-1h1a1 1 0 0 0 1-1v-1a1 1 0 0 1 1-1h.172a2 2 0 0 0 1.414-.586l.814-.814a6.5 6.5 0 1 0-4-4z`,key:`1s6t7t`}],[`circle`,{cx:`16.5`,cy:`7.5`,r:`.5`,fill:`currentColor`,key:`w0ekpg`}]]),c=a({method:`GET`}).handler(e(`29665ce3a33cde2eb2ee082694288db269438f62f3a4d0a005dec3256e0f15c1`)),l=a({method:`GET`}).handler(e(`2c7f3cdb9bd3cab2c026a48abdc84c362db0362924a08679052a325640aec56b`)),u=a({method:`POST`}).handler(e(`68a2d94ee016be64936401f5eba60ab08a47ff373e1cf9de48e4413336e6034b`)),d=a({method:`POST`}).handler(e(`a1cb80b19ca72a64fb631ca28ebb9b6941db245983de082d5dd3203ec2eef795`)),f={capability:[`api-keys`,`capability`],list:[`api-keys`,`list`]},p=()=>({queryKey:f.capability,queryFn:()=>c(),staleTime:1/0}),m=()=>t(p()),h=async e=>{if(!(await e.ensureQueryData(p())).apiKeys)throw n({to:`/`,search:{},replace:!0})},g=()=>t({queryKey:f.list,queryFn:()=>l()}),_=()=>{let e=i();return o({mutationFn:e=>u({data:{name:e}}),onSuccess:async()=>{await e.invalidateQueries({queryKey:f.list})}})},v=()=>{let e=i();return o({mutationFn:e=>d({data:{id:e}}),onSuccess:async()=>{await e.invalidateQueries({queryKey:f.list})}})};export{v as a,_ as i,m as n,s as o,g as r,h as t};
@@ -0,0 +1 @@
1
+ import{nr as e}from"./createServerFn-DU71xucx.js";var t=e(`arrow-left`,[[`path`,{d:`m12 19-7-7 7-7`,key:`1l729n`}],[`path`,{d:`M19 12H5`,key:`x3x0zl`}]]);export{t};
@@ -0,0 +1 @@
1
+ import{Gn as e,Rr as t,Un as n,cr as r,er as i,jn as a}from"./createServerFn-DU71xucx.js";t();var o=r(),s=n(`group/alert relative grid w-full gap-0.5 rounded-lg border px-2 py-1.5 text-left text-xs/relaxed has-data-[slot=alert-action]:relative has-data-[slot=alert-action]:pr-18 has-[>svg]:grid-cols-[auto_1fr] has-[>svg]:gap-x-1.5 *:[svg]:row-span-2 *:[svg]:translate-y-0.5 *:[svg]:text-current *:[svg:not([class*='size-'])]:size-3.5`,{variants:{variant:{default:`bg-card text-card-foreground`,destructive:`bg-card text-destructive *:data-[slot=alert-description]:text-destructive/90 *:[svg]:text-current`}},defaultVariants:{variant:`default`}});function c({className:e,variant:t,...n}){return(0,o.jsx)(`div`,{"data-slot":`alert`,role:`alert`,className:a(s({variant:t}),e),...n})}function l({className:e,...t}){return(0,o.jsx)(`div`,{"data-slot":`alert-title`,className:a(`font-medium group-has-[>svg]/alert:col-start-2 [&_a]:underline [&_a]:underline-offset-3 [&_a]:hover:text-foreground`,e),...t})}function u({className:e,...t}){return(0,o.jsx)(`div`,{"data-slot":`alert-description`,className:a(`text-xs/relaxed text-balance text-muted-foreground md:text-pretty [&_a]:underline [&_a]:underline-offset-3 [&_a]:hover:text-foreground [&_p:not(:last-child)]:mb-4`,e),...t})}function d({className:e,...t}){return(0,o.jsx)(`div`,{"data-slot":`alert-action`,className:a(`absolute top-1.5 right-2`,e),...t})}var f=n(`inline-flex items-center rounded-md border px-2.5 py-0.5 text-xs font-semibold transition-colors focus:outline-none focus:ring-2 focus:ring-ring focus:ring-offset-2`,{variants:{variant:{default:`border-transparent bg-primary text-primary-foreground shadow hover:bg-primary/80`,secondary:`border-transparent bg-secondary text-secondary-foreground hover:bg-secondary/80`,success:`border-success/20 bg-success/10 text-success`,warning:`border-warning/20 bg-warning/10 text-warning`,destructive:`border-transparent bg-destructive text-destructive-foreground shadow hover:bg-destructive/80`,outline:`text-foreground`}},defaultVariants:{variant:`default`}});function p({className:t,variant:n=`default`,render:r,...o}){return e({defaultTagName:`span`,props:i({className:a(f({variant:n}),t)},o),render:r,state:{slot:`badge`,variant:n}})}function m({className:e,...t}){return(0,o.jsx)(`div`,{"data-slot":`card`,className:a(`rounded-xl border bg-card text-card-foreground shadow`,e),...t})}function h({className:e,...t}){return(0,o.jsx)(`div`,{"data-slot":`card-header`,className:a(`flex flex-col gap-1.5 p-6`,e),...t})}function g({className:e,...t}){return(0,o.jsx)(`div`,{"data-slot":`card-title`,className:a(`font-semibold leading-none tracking-tight`,e),...t})}function _({className:e,...t}){return(0,o.jsx)(`div`,{"data-slot":`card-description`,className:a(`text-sm text-muted-foreground`,e),...t})}function v({className:e,...t}){return(0,o.jsx)(`div`,{"data-slot":`card-content`,className:a(`p-6 pt-0`,e),...t})}function y({className:e,...t}){return(0,o.jsx)(`div`,{"data-slot":`card-footer`,className:a(`flex items-center p-6 pt-0`,e),...t})}export{h as a,c,l as d,y as i,d as l,v as n,g as o,_ as r,p as s,m as t,u};
@@ -1 +1 @@
1
- import{Kn as e}from"./createServerFn-Uk1tYGbn.js";var t=e(`chart-no-axes-combined`,[[`path`,{d:`M12 16v5`,key:`zza2cw`}],[`path`,{d:`M16 14v7`,key:`1g90b9`}],[`path`,{d:`M20 10v11`,key:`1iqoj0`}],[`path`,{d:`m22 3-8.646 8.646a.5.5 0 0 1-.708 0L9.354 8.354a.5.5 0 0 0-.707 0L2 15`,key:`1fw8x9`}],[`path`,{d:`M4 18v3`,key:`1yp0dc`}],[`path`,{d:`M8 14v7`,key:`n3cwzv`}]]);export{t};
1
+ import{nr as e}from"./createServerFn-DU71xucx.js";var t=e(`chart-no-axes-combined`,[[`path`,{d:`M12 16v5`,key:`zza2cw`}],[`path`,{d:`M16 14v7`,key:`1g90b9`}],[`path`,{d:`M20 10v11`,key:`1iqoj0`}],[`path`,{d:`m22 3-8.646 8.646a.5.5 0 0 1-.708 0L9.354 8.354a.5.5 0 0 0-.707 0L2 15`,key:`1fw8x9`}],[`path`,{d:`M4 18v3`,key:`1yp0dc`}],[`path`,{d:`M8 14v7`,key:`n3cwzv`}]]);export{t};