@hot-updater/console 1.0.0-rc.2 → 1.0.0-rc.20
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.
- package/.output/nitro.json +1 -1
- package/.output/public/assets/ConsoleFeatureUnavailable-B9VYGA3N.js +1 -0
- package/.output/public/assets/HashValueDisplay-D880zntR.js +1 -0
- package/.output/public/assets/InsightsInfo-By_sPjTE.js +1 -0
- package/.output/public/assets/InsightsPageHeader-9_kx_LL7.js +1 -0
- package/.output/public/assets/NotFoundPage-Dys8C0cW.js +1 -0
- package/.output/public/assets/api-CtarlV0l.js +1 -0
- package/.output/public/assets/api-keys-DFF_QqtN.js +1 -0
- package/.output/public/assets/api-keys-evfsQ4sN.js +1 -0
- package/.output/public/assets/arrow-left-BP9D-ta_.js +1 -0
- package/.output/public/assets/arrow-up-right-CDP9Tevw.js +1 -0
- package/.output/public/assets/card-DzCPSRsh.js +1 -0
- package/.output/public/assets/console-features-api-yv7rm3DX.js +1 -0
- package/.output/public/assets/dialog-BDvCy_QO.js +1 -0
- package/.output/public/assets/dist-Clb6cQ9l.js +1 -0
- package/.output/public/assets/empty-C5x9mn_s.js +1 -0
- package/.output/public/assets/field-Bou7shoO.js +1 -0
- package/.output/public/assets/index-0eg3l8aC.js +10 -0
- package/.output/public/assets/input-group-DVtWFUUF.js +1 -0
- package/.output/public/assets/insights-2MbdiSNv.js +1 -0
- package/.output/public/assets/insights-C6tmCZHk.js +2 -0
- package/.output/public/assets/insights-CadS_aIA.js +42 -0
- package/.output/public/assets/insights-recovery-rpc-wvdyM4LD.js +1 -0
- package/.output/public/assets/insights-search-KIF7mRtB.js +1 -0
- package/.output/public/assets/insights-usage-rpc-qUkNtrWr.js +1 -0
- package/.output/public/assets/insights_.distribution-BhBs6PNA.js +1 -0
- package/.output/public/assets/insights_.distribution-CItZw3-8.js +1 -0
- package/.output/public/assets/insights_.distribution-CJUH_wAS.js +2 -0
- package/.output/public/assets/installations-CH2H7JQt.js +2 -0
- package/.output/public/assets/installations-DMeMuwsW.js +1 -0
- package/.output/public/assets/installations-DnvxI9Dt.js +1 -0
- package/.output/public/assets/loader-circle-Ca7C9YY1.js +1 -0
- package/.output/public/assets/mutation-x9L28_CD.js +1 -0
- package/.output/public/assets/preload-helper-BN-UkjOE.js +1 -0
- package/.output/public/assets/refresh-cw-CVGqvy8Z.js +1 -0
- package/.output/public/assets/routes-BhK8DuZA.js +1 -0
- package/.output/public/assets/routes-veKtDW39.js +2 -0
- package/.output/public/assets/sidebar-B45aMqRm.js +3 -0
- package/.output/public/assets/styles-Dn0pK1EX.css +2 -0
- package/.output/public/assets/table-CwLnN6KX.js +1 -0
- package/.output/public/assets/useCompositeListItem-CF7vsfcA.js +1 -0
- package/.output/public/assets/useMutation-CN1ygYEr.js +1 -0
- package/.output/public/assets/useOpenInteractionType-AnAMWYIY.js +1 -0
- package/.output/public/assets/valueToPercent-C-t8FT0y.js +1 -0
- package/.output/server/{__23tanstack-start-server-fn-resolver-B7ioJhtE.mjs → __23tanstack-start-server-fn-resolver-CUQLz7hs.mjs} +52 -40
- package/.output/server/_libs/@base-ui/react+[...].mjs +7044 -3622
- package/.output/server/_libs/@reduxjs/toolkit+[...].mjs +1554 -0
- package/.output/server/_libs/@tanstack/react-router+[...].mjs +49 -3
- package/.output/server/_libs/@tanstack/react-router-ssr-query+[...].mjs +4 -4
- package/.output/server/_libs/d3-array.mjs +231 -0
- package/.output/server/_libs/d3-color.mjs +330 -0
- package/.output/server/_libs/d3-format.mjs +252 -0
- package/.output/server/_libs/d3-interpolate.mjs +207 -0
- package/.output/server/_libs/d3-path.mjs +77 -0
- package/.output/server/_libs/d3-scale+[...].mjs +1907 -0
- package/.output/server/_libs/d3-shape.mjs +818 -0
- package/.output/server/_libs/decimal.js-light.mjs +884 -0
- package/.output/server/_libs/es-toolkit.mjs +1159 -0
- package/.output/server/_libs/eventemitter3.mjs +236 -0
- package/.output/server/_libs/immer.mjs +532 -0
- package/.output/server/_libs/lucide-react.mjs +46 -32
- package/.output/server/_libs/next-themes.mjs +2 -2
- package/.output/server/_libs/react-redux+[...].mjs +205 -0
- package/.output/server/_libs/recharts+[...].mjs +14350 -0
- package/.output/server/_libs/sonner.mjs +2 -2
- package/.output/server/_libs/tanstack__react-query.mjs +8 -3
- package/.output/server/_libs/verkit.mjs +99 -1
- package/.output/server/_runtime.mjs +10 -1
- package/.output/server/_ssr/ConsoleFeatureUnavailable-DoxET2AT.mjs +58 -0
- package/.output/server/_ssr/{HashValueDisplay-DwpGLfrl.mjs → HashValueDisplay-BplboHEb.mjs} +3 -3
- package/.output/server/_ssr/InsightsInfo-o2YPd5Qc.mjs +37 -0
- package/.output/server/_ssr/InsightsPageHeader-NExCJL1I.mjs +154 -0
- package/.output/server/_ssr/NotFoundPage-Cd-A8ock.mjs +37 -0
- package/.output/server/_ssr/api-B1Ro0uys.mjs +202 -0
- package/.output/server/_ssr/api-C0G9MTMI.mjs +4205 -0
- package/.output/server/_ssr/{api-keys-CZeTPQys.mjs → api-keys-CT3HG7KT.mjs} +49 -9
- package/.output/server/_ssr/api-keys-Dvvy1sem.mjs +5 -0
- package/.output/server/_ssr/api-keys-rpc-b1qTTFfG.mjs +52 -0
- package/.output/server/_ssr/api-rpc-Cbns2MGx.mjs +338 -0
- package/.output/server/_ssr/{auth-rpc-DUaeOWKK.mjs → auth-rpc-DChS7m9y.mjs} +6 -6
- package/.output/server/_ssr/auth.server-Ccqz2iVv.mjs +37 -0
- package/.output/server/_ssr/bundleActivity-D17Pb_h5.mjs +19 -0
- package/.output/server/_ssr/card-DMbcvlPz.mjs +49 -0
- package/.output/server/_ssr/config-DMEJdhoW.mjs +13 -0
- package/.output/server/_ssr/config.server-DyypN6cQ.mjs +60 -0
- package/.output/server/_ssr/console-access-KpPv5lin.mjs +17 -0
- package/.output/server/_ssr/console-features-CsbyHYfK.mjs +55 -0
- package/.output/server/_ssr/console-features-api-B-KVuo4p.mjs +43 -0
- package/.output/server/_ssr/console-features-rpc-Djyo5740.mjs +19 -0
- package/.output/server/_ssr/{createServerFn-B2hcXoPM.mjs → createMiddleware-B_I3Ll4M.mjs} +28 -2
- package/.output/server/_ssr/{createServerRpc-DB29C_5p.mjs → createServerRpc-DuNm5mmo.mjs} +2 -2
- package/.output/server/_ssr/databaseRows-CXxf_VIB.mjs +132 -0
- package/.output/server/_ssr/{deleteBundle-BTGwBgzx.mjs → deleteBundle-Dcc21Lbd.mjs} +9 -19
- package/.output/server/_ssr/{dialog-DS-nw-pA.mjs → dialog-cOmLTUV2.mjs} +2 -2
- package/.output/server/_ssr/{dist-CyzPaI5v.mjs → dist-B-r4u3Lg.mjs} +28 -5
- package/.output/server/_ssr/{downloadBundle-CNnYxYO2.mjs → downloadBundle-CexOFoZ4.mjs} +6 -7
- package/.output/server/_ssr/empty-BHoY_5jt.mjs +49 -0
- package/.output/server/_ssr/{table-CnZmon_Z.mjs → field-mjhcNEXD.mjs} +63 -51
- package/.output/server/_ssr/getBundleChildren-DbDXe9wB.mjs +22 -0
- package/.output/server/_ssr/{input-group-BpsnmvZw.mjs → input-group-96H30HWC.mjs} +2 -2
- package/.output/server/_ssr/insights-D25VDVaz.mjs +5 -0
- package/.output/server/_ssr/insights-D359GJFL.mjs +14 -0
- package/.output/server/_ssr/insights-DgFv1NsO.mjs +1238 -0
- package/.output/server/_ssr/insights-api-ChAKrbhG.mjs +105 -0
- package/.output/server/_ssr/insights-failures-WQ-ttjOx.mjs +44 -0
- package/.output/server/_ssr/insights-failures-rpc-BFsqlltN.mjs +21 -0
- package/.output/server/_ssr/insights-recovery-DkL6bxMW.mjs +28 -0
- package/.output/server/_ssr/insights-recovery-rpc-2P5m8F62.mjs +46 -0
- package/.output/server/_ssr/insights-recovery-rpc-Tj8vNC19.mjs +20 -0
- package/.output/server/_ssr/{insights-rpc-38DujK0G.mjs → insights-rpc-DrkVmV9o.mjs} +22 -14
- package/.output/server/_ssr/insights-search-BsalnNw-.mjs +25 -0
- package/.output/server/_ssr/insights-usage-1nVTQrLy.mjs +29 -0
- package/.output/server/_ssr/insights-usage-rpc-Ct_4xHhZ.mjs +29 -0
- package/.output/server/_ssr/insights-usage-rpc-DaYIRtFK.mjs +41 -0
- package/.output/server/_ssr/insightsRecovery-CpGucWN1.mjs +45 -0
- package/.output/server/_ssr/insightsUsage-JYpKZAF7.mjs +56 -0
- package/.output/server/_ssr/insights_.distribution-Bcu6uYs_.mjs +5 -0
- package/.output/server/_ssr/insights_.distribution-D3Csuyjw.mjs +14 -0
- package/.output/server/_ssr/insights_.distribution-jQZEF07J.mjs +335 -0
- package/.output/server/_ssr/installations-B8Vh54lH.mjs +69 -0
- package/.output/server/_ssr/installations-BI5kelHv.mjs +5 -0
- package/.output/server/_ssr/{installations-DiVKEF5T.mjs → installations-Cxikllmx.mjs} +517 -54
- package/.output/server/_ssr/listReleases-DqU9t1l3.mjs +79 -0
- package/.output/server/_ssr/releaseManagement-B3e7I8J9.mjs +11 -0
- package/.output/server/_ssr/{router-B9wG_9f8.mjs → router-CRkm-wHD.mjs} +117 -124
- package/.output/server/_ssr/routes-B3IJo_jL.mjs +292 -0
- package/.output/server/_ssr/{routes-D7Yh_jfj.mjs → routes-CNAi0Mmv.mjs} +176 -455
- package/.output/server/_ssr/runtime.server-NucbYjc7.mjs +1372 -0
- package/.output/server/_ssr/select-BkPAJFL7.mjs +107 -0
- package/.output/server/_ssr/{server-D_C2rMzf.mjs → server-DKJYsaCP.mjs} +6 -32
- package/.output/server/_ssr/{createSsrRpc-DjWNJ0uc.mjs → sidebar-Cw1VuC7d.mjs} +117 -63
- package/.output/server/_ssr/ssr.mjs +1 -1
- package/.output/server/_ssr/table-q0P9wz7x.mjs +53 -0
- package/.output/server/_ssr/updateFailures-DMU9f0pK.mjs +24 -0
- package/.output/server/_ssr/{uuidv7-D0QFkPL_.mjs → uuidv7-BzSO-fr-.mjs} +2 -2
- package/.output/server/_tanstack-start-manifest_v-Bb0gKDbb.mjs +124 -0
- package/.output/server/index.mjs +273 -168
- package/README.md +71 -65
- package/lib/index.d.mts +13 -11
- package/lib/vite-internal.mjs +6 -3
- package/package.json +8 -8
- package/src/components/AppSidebar.tsx +91 -71
- package/src/components/ConsoleAccessPage.tsx +5 -1
- package/src/components/ConsoleFeatureUnavailable.tsx +82 -0
- package/src/components/NotFoundPage.tsx +7 -7
- package/src/components/features/FeatureSlots.tsx +99 -0
- package/src/components/features/api-keys/apiKeysFeatureUi.tsx +15 -0
- package/src/components/features/bundles/BundleMetadata.tsx +7 -4
- package/src/components/features/channels/ChannelManagementDialog.tsx +2 -5
- package/src/components/features/insights/AppUsage.tsx +370 -0
- package/src/components/features/insights/EstimatedCount.tsx +18 -0
- package/src/components/features/insights/EventDetails.tsx +117 -37
- package/src/components/features/insights/EventHistoryCard.tsx +112 -26
- package/src/components/features/insights/EventHistoryList.tsx +2 -2
- package/src/components/features/insights/InsightsControls.tsx +265 -102
- package/src/components/features/insights/InsightsErrorAlert.tsx +14 -1
- package/src/components/features/insights/InsightsInfo.tsx +48 -0
- package/src/components/features/insights/InsightsOverview.tsx +176 -173
- package/src/components/features/insights/InsightsPageHeader.tsx +35 -20
- package/src/components/features/insights/InsightsPeriodSelector.tsx +89 -0
- package/src/components/features/insights/InstallationHistoryCard.tsx +52 -10
- package/src/components/features/insights/InstallationMatchesCard.tsx +1 -1
- package/src/components/features/insights/ReleaseActivity.tsx +188 -0
- package/src/components/features/insights/ReportingDevicesSummary.tsx +65 -0
- package/src/components/features/insights/UpdateFailures.tsx +319 -0
- package/src/components/features/insights/insightsFeatureUi.tsx +35 -0
- package/src/components/features/releases/ReleaseEditorSheet.tsx +24 -1
- package/src/components/ui/card.tsx +1 -1
- package/src/components/ui/empty.tsx +101 -0
- package/src/components/ui/scroll-area.tsx +52 -0
- package/src/components/ui/sidebar.tsx +22 -29
- package/src/components/ui/tabs.tsx +81 -0
- package/src/index.ts +12 -17
- package/src/lib/api-keys-api.ts +0 -28
- package/src/lib/api-keys-rpc.ts +27 -38
- package/src/lib/api-rpc.ts +197 -221
- package/src/lib/api.ts +11 -13
- package/src/lib/bundle-activity.ts +31 -0
- package/src/lib/console-access.ts +20 -0
- package/src/lib/console-features-api.ts +68 -0
- package/src/lib/console-features-rpc.ts +13 -0
- package/src/lib/console-features.ts +91 -0
- package/src/lib/insights-api.ts +37 -1
- package/src/lib/insights-failures-rpc.ts +21 -0
- package/src/lib/insights-failures.ts +129 -0
- package/src/lib/insights-recovery-rpc.ts +51 -0
- package/src/lib/insights-recovery.ts +68 -0
- package/src/lib/insights-retention.ts +21 -0
- package/src/lib/insights-rpc.ts +30 -12
- package/src/lib/insights-search.ts +58 -0
- package/src/lib/insights-usage-rpc.ts +29 -0
- package/src/lib/insights-usage.ts +74 -0
- package/src/lib/insights-view.ts +38 -2
- package/src/lib/scroll-restoration.ts +21 -0
- package/src/lib/server/adminInsights.ts +124 -0
- package/src/lib/server/auth.server.ts +13 -5
- package/src/lib/server/bundleActivity.ts +37 -0
- package/src/lib/server/config.server.ts +16 -32
- package/src/lib/server/console-feature-apis.ts +59 -0
- package/src/lib/server/console-runtime.server.ts +6 -40
- package/src/lib/server/deleteBundle.ts +16 -25
- package/src/lib/server/downloadBundle.ts +7 -10
- package/src/lib/server/getBundleChildren.ts +31 -122
- package/src/lib/server/insightsRecovery.ts +55 -0
- package/src/lib/server/insightsUsage.ts +63 -0
- package/src/lib/server/listReleases.ts +109 -44
- package/src/lib/server/releaseReachability.ts +4 -3
- package/src/lib/server/runtime.server.ts +132 -31
- package/src/lib/server/updateFailures.ts +31 -0
- package/src/routeTree.gen.ts +21 -21
- package/src/router.tsx +3 -2
- package/src/routes/-installations-search.ts +32 -8
- package/src/routes/-releases-search.ts +76 -29
- package/src/routes/__root.tsx +10 -4
- package/src/routes/api/bundles/$bundleId/download.ts +2 -5
- package/src/routes/api-keys.tsx +5 -2
- package/src/routes/index.tsx +167 -104
- package/src/routes/insights.tsx +100 -59
- package/src/routes/insights_.distribution.tsx +398 -0
- package/src/routes/installations.tsx +98 -41
- package/src/vite-internal.ts +6 -3
- package/.output/public/assets/HashValueDisplay-CB0Eskit.js +0 -1
- package/.output/public/assets/InsightsPageHeader-Car5LNiZ.js +0 -1
- package/.output/public/assets/api-keys-BzKocqRy.js +0 -1
- package/.output/public/assets/api-keys-api-BHcODB7q.js +0 -1
- package/.output/public/assets/card-Dhr_eFYj.js +0 -1
- package/.output/public/assets/chart-no-axes-combined-Dy4WJv2U.js +0 -1
- package/.output/public/assets/composite-Bp98A0Ld.js +0 -1
- package/.output/public/assets/createServerFn-CA8fs7QD.js +0 -3
- package/.output/public/assets/dialog-CUTrcPlB.js +0 -1
- package/.output/public/assets/dist-C_NydL0e.js +0 -1
- package/.output/public/assets/index-DdAz-CXv.js +0 -10
- package/.output/public/assets/input-group-cSOG4wh_.js +0 -1
- package/.output/public/assets/insights-C0PBSZ-n.js +0 -1
- package/.output/public/assets/installations-CE33wgbY.js +0 -2
- package/.output/public/assets/installations-CStZja8x.js +0 -1
- package/.output/public/assets/lazyRouteComponent-Ccp3bwBY.js +0 -1
- package/.output/public/assets/link-CI8idAUi.js +0 -1
- package/.output/public/assets/loader-circle-BoxLrsOu.js +0 -1
- package/.output/public/assets/preload-helper-CQ36nxok.js +0 -1
- package/.output/public/assets/refresh-cw-Bqc72UZG.js +0 -1
- package/.output/public/assets/routes-DGVXdzpw.js +0 -2
- package/.output/public/assets/routes-DTlwOr8I.js +0 -1
- package/.output/public/assets/shield-check-uK3MHWJZ.js +0 -1
- package/.output/public/assets/signing-CMf4aqDO.js +0 -1
- package/.output/public/assets/styles-BCvbtKsm.css +0 -2
- package/.output/public/assets/table-2vcV89QB.js +0 -1
- package/.output/public/assets/useCompositeListItem-CHLITE_4.js +0 -1
- package/.output/public/assets/x-DCd0j8c6.js +0 -1
- package/.output/server/_ssr/InsightsPageHeader-Df4Brj8u.mjs +0 -484
- package/.output/server/_ssr/api-keys-api-BUPQVSpk.mjs +0 -60
- package/.output/server/_ssr/api-keys-rpc-Cs7tS5_j.mjs +0 -136
- package/.output/server/_ssr/api-rpc-tAupfGQm.mjs +0 -1399
- package/.output/server/_ssr/auth.server-DW71WzsD.mjs +0 -47
- package/.output/server/_ssr/bundle-signing-rpc-BhnBw0-d.mjs +0 -16
- package/.output/server/_ssr/bundle-signing.server-C4NW5mWx.mjs +0 -12
- package/.output/server/_ssr/card-BRiPmi0C.mjs +0 -108
- package/.output/server/_ssr/config-Dv8qLDZ0.mjs +0 -13
- package/.output/server/_ssr/config.server-afDuAwaG.mjs +0 -368
- package/.output/server/_ssr/databaseJsonValue-d6I3nAS4.mjs +0 -45
- package/.output/server/_ssr/databaseRows-5bCRTxm-.mjs +0 -126
- package/.output/server/_ssr/getBundleChildren-C0vh4ZvE.mjs +0 -50
- package/.output/server/_ssr/insights-BdS364Xu.mjs +0 -460
- package/.output/server/_ssr/insightsContract-fjJDBeEE.mjs +0 -303
- package/.output/server/_ssr/installations-CtA59MQG.mjs +0 -29
- package/.output/server/_ssr/routes-CKrrS2q2.mjs +0 -37
- package/.output/server/_ssr/runtime.server-DacU1TBV.mjs +0 -438
- package/.output/server/_ssr/signing-Dz1WkZOf.mjs +0 -133
- package/.output/server/_tanstack-start-manifest_v-2MjTyxil.mjs +0 -97
- package/src/components/features/insights/InsightsBundleReports.tsx +0 -51
- package/src/components/features/signing/BundleSigningPage.tsx +0 -139
- package/src/lib/bundle-signing-api.ts +0 -14
- package/src/lib/bundle-signing-rpc.ts +0 -16
- package/src/lib/server/bundle-signing.server.ts +0 -23
- package/src/routes/signing.tsx +0 -37
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
1
|
+
import { i as __toESM } from "../_runtime.mjs";
|
|
2
|
+
import { mt as require_react, ut as require_react_dom } from "./@base-ui/react+[...].mjs";
|
|
3
3
|
//#region ../../node_modules/.pnpm/sonner@2.0.7_react-dom@19.2.6_react@19.2.6__react@19.2.6/node_modules/sonner/dist/index.mjs
|
|
4
4
|
var import_react = /* @__PURE__ */ __toESM(require_react(), 1);
|
|
5
5
|
var import_react_dom = /* @__PURE__ */ __toESM(require_react_dom(), 1);
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
1
|
+
import { i as __toESM } from "../_runtime.mjs";
|
|
2
|
+
import { mt as require_react, pt as require_jsx_runtime } from "./@base-ui/react+[...].mjs";
|
|
3
3
|
import { c as noop, i as notifyManager, l as shouldThrowError, n as MutationObserver, r as QueryObserver, s as environmentManager } from "./tanstack__query-core.mjs";
|
|
4
4
|
//#region ../../node_modules/.pnpm/@tanstack+react-query@5.101.0_react@19.2.6/node_modules/@tanstack/react-query/build/modern/QueryClientProvider.js
|
|
5
5
|
var import_react = /* @__PURE__ */ __toESM(require_react(), 1);
|
|
@@ -124,6 +124,11 @@ function useQuery(options, queryClient) {
|
|
|
124
124
|
return useBaseQuery(options, QueryObserver, queryClient);
|
|
125
125
|
}
|
|
126
126
|
//#endregion
|
|
127
|
+
//#region ../../node_modules/.pnpm/@tanstack+react-query@5.101.0_react@19.2.6/node_modules/@tanstack/react-query/build/modern/queryOptions.js
|
|
128
|
+
function queryOptions(options) {
|
|
129
|
+
return options;
|
|
130
|
+
}
|
|
131
|
+
//#endregion
|
|
127
132
|
//#region ../../node_modules/.pnpm/@tanstack+react-query@5.101.0_react@19.2.6/node_modules/@tanstack/react-query/build/modern/useMutation.js
|
|
128
133
|
function useMutation(options, queryClient) {
|
|
129
134
|
const client = useQueryClient(queryClient);
|
|
@@ -143,4 +148,4 @@ function useMutation(options, queryClient) {
|
|
|
143
148
|
};
|
|
144
149
|
}
|
|
145
150
|
//#endregion
|
|
146
|
-
export { useQueryClient as i,
|
|
151
|
+
export { useQueryClient as a, QueryClientProvider as i, queryOptions as n, useQuery as r, useMutation as t };
|
|
@@ -68,6 +68,36 @@ function parse(version, options = {}) {
|
|
|
68
68
|
prerelease
|
|
69
69
|
};
|
|
70
70
|
}
|
|
71
|
+
var NUMERIC = /^\d+$/;
|
|
72
|
+
function compareIdentifiers(left, right) {
|
|
73
|
+
if (typeof left === "number" && typeof right === "number") return left === right ? 0 : left < right ? -1 : 1;
|
|
74
|
+
const leftNumeric = NUMERIC.test(String(left));
|
|
75
|
+
const rightNumeric = NUMERIC.test(String(right));
|
|
76
|
+
const normalizedLeft = leftNumeric ? Number(left) : left;
|
|
77
|
+
const normalizedRight = rightNumeric ? Number(right) : right;
|
|
78
|
+
return normalizedLeft === normalizedRight ? 0 : leftNumeric && !rightNumeric ? -1 : rightNumeric && !leftNumeric ? 1 : normalizedLeft < normalizedRight ? -1 : 1;
|
|
79
|
+
}
|
|
80
|
+
function compareMainParsed(left, right) {
|
|
81
|
+
return left.major === right.major ? left.minor === right.minor ? left.patch === right.patch ? 0 : left.patch < right.patch ? -1 : 1 : left.minor < right.minor ? -1 : 1 : left.major < right.major ? -1 : 1;
|
|
82
|
+
}
|
|
83
|
+
function comparePrereleaseParsed(left, right) {
|
|
84
|
+
const leftPrerelease = left.prerelease;
|
|
85
|
+
const rightPrerelease = right.prerelease;
|
|
86
|
+
if (leftPrerelease?.length && !rightPrerelease?.length) return -1;
|
|
87
|
+
if (!leftPrerelease?.length && rightPrerelease?.length) return 1;
|
|
88
|
+
if (!leftPrerelease?.length && !rightPrerelease?.length) return 0;
|
|
89
|
+
for (let index = 0;; index++) {
|
|
90
|
+
const leftIdentifier = leftPrerelease?.[index];
|
|
91
|
+
const rightIdentifier = rightPrerelease?.[index];
|
|
92
|
+
if (leftIdentifier === void 0 && rightIdentifier === void 0) return 0;
|
|
93
|
+
if (rightIdentifier === void 0) return 1;
|
|
94
|
+
if (leftIdentifier === void 0) return -1;
|
|
95
|
+
if (leftIdentifier !== rightIdentifier) return compareIdentifiers(leftIdentifier, rightIdentifier);
|
|
96
|
+
}
|
|
97
|
+
}
|
|
98
|
+
function compareParsed(left, right) {
|
|
99
|
+
return compareMainParsed(left, right) || comparePrereleaseParsed(left, right);
|
|
100
|
+
}
|
|
71
101
|
//#endregion
|
|
72
102
|
//#region ../../node_modules/.pnpm/verkit@0.4.0/node_modules/verkit/dist/set-CC5YeoYX.js
|
|
73
103
|
var STRICT_COMPARATOR = safeRegex(String.raw`^${GREATER_LESS_THAN}\s*(${FULL_PLAIN})$|^$`);
|
|
@@ -89,6 +119,40 @@ function parseComparator(comparator, options = {}) {
|
|
|
89
119
|
version
|
|
90
120
|
};
|
|
91
121
|
}
|
|
122
|
+
function testParsedComparator(comparator, version) {
|
|
123
|
+
if (!comparator.version) return true;
|
|
124
|
+
const comparison = compareParsed(version, comparator.version);
|
|
125
|
+
switch (comparator.operator) {
|
|
126
|
+
case "": return comparison === 0;
|
|
127
|
+
case ">": return comparison > 0;
|
|
128
|
+
case ">=": return comparison >= 0;
|
|
129
|
+
case "<": return comparison < 0;
|
|
130
|
+
case "<=": return comparison <= 0;
|
|
131
|
+
}
|
|
132
|
+
}
|
|
133
|
+
function comparatorAllowsPrerelease(comparator, version) {
|
|
134
|
+
const allowed = comparator.version;
|
|
135
|
+
return allowed !== null && !!allowed.prerelease?.length && allowed.major === version.major && allowed.minor === version.minor && allowed.patch === version.patch;
|
|
136
|
+
}
|
|
137
|
+
function testComparatorSet(set, version, options) {
|
|
138
|
+
if (set.some((comparator) => !testParsedComparator(comparator, version))) return false;
|
|
139
|
+
return !version.prerelease?.length || !!options.includePrerelease || set.some((comparator) => comparatorAllowsPrerelease(comparator, version));
|
|
140
|
+
}
|
|
141
|
+
function parsedComparatorsIntersect(left, right, options = {}) {
|
|
142
|
+
if (!left.version || !right.version) return true;
|
|
143
|
+
if (left.operator === "") return testComparatorSet([right], left.version, options);
|
|
144
|
+
if (right.operator === "") return testComparatorSet([left], right.version, options);
|
|
145
|
+
const leftValue = formatComparator(left);
|
|
146
|
+
const rightValue = formatComparator(right);
|
|
147
|
+
if (options.includePrerelease && (leftValue === "<0.0.0-0" || rightValue === "<0.0.0-0")) return false;
|
|
148
|
+
if (!options.includePrerelease && (leftValue.startsWith("<0.0.0") || rightValue.startsWith("<0.0.0"))) return false;
|
|
149
|
+
if (left.operator.startsWith(">") && right.operator.startsWith(">")) return true;
|
|
150
|
+
if (left.operator.startsWith("<") && right.operator.startsWith("<")) return true;
|
|
151
|
+
const comparison = compareParsed(left.version, right.version);
|
|
152
|
+
if (comparison === 0 && left.operator.includes("=") && right.operator.includes("=")) return true;
|
|
153
|
+
if (comparison < 0 && left.operator.startsWith(">") && right.operator.startsWith("<")) return true;
|
|
154
|
+
return comparison > 0 && left.operator.startsWith("<") && right.operator.startsWith(">");
|
|
155
|
+
}
|
|
92
156
|
//#endregion
|
|
93
157
|
//#region ../../node_modules/.pnpm/verkit@0.4.0/node_modules/verkit/dist/range-DvX-Y6iv.js
|
|
94
158
|
function formatRange(range) {
|
|
@@ -243,9 +307,43 @@ function tryParseRange(range, options = {}) {
|
|
|
243
307
|
return null;
|
|
244
308
|
}
|
|
245
309
|
}
|
|
310
|
+
function exactVersion(set) {
|
|
311
|
+
for (const comparator of set) if (comparator.operator === "" && comparator.version) return comparator.version;
|
|
312
|
+
return null;
|
|
313
|
+
}
|
|
314
|
+
function isSatisfiable(comparators, options) {
|
|
315
|
+
const exact = exactVersion(comparators);
|
|
316
|
+
if (exact) return testComparatorSet(comparators, exact, options);
|
|
317
|
+
const remaining = [...comparators];
|
|
318
|
+
let current = remaining.pop();
|
|
319
|
+
while (current && remaining.length) {
|
|
320
|
+
if (remaining.some((other) => !parsedComparatorsIntersect(current, other, options))) return false;
|
|
321
|
+
current = remaining.pop();
|
|
322
|
+
}
|
|
323
|
+
return true;
|
|
324
|
+
}
|
|
325
|
+
function setsIntersect(left, right, options) {
|
|
326
|
+
const leftExact = exactVersion(left);
|
|
327
|
+
if (leftExact) return testComparatorSet(right, leftExact, options);
|
|
328
|
+
const rightExact = exactVersion(right);
|
|
329
|
+
if (rightExact) return testComparatorSet(left, rightExact, options);
|
|
330
|
+
return left.every((leftComparator) => right.every((rightComparator) => parsedComparatorsIntersect(leftComparator, rightComparator, options)));
|
|
331
|
+
}
|
|
332
|
+
function parsedRangesIntersect(left, right, options = {}) {
|
|
333
|
+
return left.sets.some((leftSet) => isSatisfiable(leftSet, options) && right.sets.some((rightSet) => isSatisfiable(rightSet, options) && setsIntersect(leftSet, rightSet, options)));
|
|
334
|
+
}
|
|
246
335
|
function normalizeRange(range, options = {}) {
|
|
247
336
|
const parsed = tryParseRange(range, options);
|
|
248
337
|
return parsed ? formatRange(parsed) || "*" : null;
|
|
249
338
|
}
|
|
339
|
+
function rangesIntersect(left, right, options = {}) {
|
|
340
|
+
const parsedLeft = parseRange(left, options);
|
|
341
|
+
const parsedRight = parseRange(right, options);
|
|
342
|
+
return parsedRangesIntersect(parsedLeft, parsedRight, {
|
|
343
|
+
...parsedLeft.options,
|
|
344
|
+
...parsedRight.options,
|
|
345
|
+
...options
|
|
346
|
+
});
|
|
347
|
+
}
|
|
250
348
|
//#endregion
|
|
251
|
-
export { normalizeRange as t };
|
|
349
|
+
export { rangesIntersect as n, normalizeRange as t };
|
|
@@ -7,6 +7,15 @@ var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
|
7
7
|
var __getProtoOf = Object.getPrototypeOf;
|
|
8
8
|
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
9
9
|
var __commonJSMin = (cb, mod) => () => (mod || cb((mod = { exports: {} }).exports, mod), mod.exports);
|
|
10
|
+
var __exportAll = (all, no_symbols) => {
|
|
11
|
+
let target = {};
|
|
12
|
+
for (var name in all) __defProp(target, name, {
|
|
13
|
+
get: all[name],
|
|
14
|
+
enumerable: true
|
|
15
|
+
});
|
|
16
|
+
if (!no_symbols) __defProp(target, Symbol.toStringTag, { value: "Module" });
|
|
17
|
+
return target;
|
|
18
|
+
};
|
|
10
19
|
var __copyProps = (to, from, except, desc) => {
|
|
11
20
|
if (from && typeof from === "object" || typeof from === "function") for (var keys = __getOwnPropNames(from), i = 0, n = keys.length, key; i < n; i++) {
|
|
12
21
|
key = keys[i];
|
|
@@ -23,4 +32,4 @@ var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__ge
|
|
|
23
32
|
}) : target, mod));
|
|
24
33
|
var __require = /* @__PURE__ */ createRequire(import.meta.url);
|
|
25
34
|
//#endregion
|
|
26
|
-
export {
|
|
35
|
+
export { __toESM as i, __exportAll as n, __require as r, __commonJSMin as t };
|
|
@@ -0,0 +1,58 @@
|
|
|
1
|
+
import { pt as require_jsx_runtime } from "../_libs/@base-ui/react+[...].mjs";
|
|
2
|
+
import { L as ArrowUpRight } from "../_libs/lucide-react.mjs";
|
|
3
|
+
import { D as buttonVariants, x as SidebarTrigger } from "./sidebar-Cw1VuC7d.mjs";
|
|
4
|
+
import { a as unavailableReason, n as consoleFeatures } from "./console-features-CsbyHYfK.mjs";
|
|
5
|
+
import { a as useConsoleFeatures, n as notFoundFeature } from "./console-features-api-B-KVuo4p.mjs";
|
|
6
|
+
import { t as NotFoundPage } from "./NotFoundPage-Cd-A8ock.mjs";
|
|
7
|
+
import { a as EmptyTitle, i as EmptyHeader, n as EmptyContent, r as EmptyDescription, t as Empty } from "./empty-BHoY_5jt.mjs";
|
|
8
|
+
//#region node_modules/.nitro/vite/services/ssr/assets/ConsoleFeatureUnavailable-DoxET2AT.js
|
|
9
|
+
var import_jsx_runtime = require_jsx_runtime();
|
|
10
|
+
var CONSOLE_DEPLOYMENT_GUIDE_URL = "https://hot-updater.dev/docs/guides/console-deployment";
|
|
11
|
+
/**
|
|
12
|
+
* A feature route's not-found state: the plugin to add, or, for a feature a
|
|
13
|
+
* self-hosted server does not serve, the database config it needs.
|
|
14
|
+
*/
|
|
15
|
+
function ConsoleFeatureUnavailable({ data }) {
|
|
16
|
+
const feature = notFoundFeature(data);
|
|
17
|
+
const remote = useConsoleFeatures().data?.remote === true;
|
|
18
|
+
if (feature === void 0) return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(NotFoundPage, {});
|
|
19
|
+
const { label, plugin } = consoleFeatures[feature];
|
|
20
|
+
const pluginCall = /* @__PURE__ */ (0, import_jsx_runtime.jsx)("code", {
|
|
21
|
+
className: "font-mono",
|
|
22
|
+
children: `${plugin}()`
|
|
23
|
+
});
|
|
24
|
+
return /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", {
|
|
25
|
+
className: "flex h-svh min-h-0 flex-col",
|
|
26
|
+
children: [/* @__PURE__ */ (0, import_jsx_runtime.jsxs)("header", {
|
|
27
|
+
className: "sticky top-0 z-10 flex shrink-0 items-center gap-3 border-b bg-background px-3 py-3 sm:min-h-12 sm:bg-card/70 sm:px-4 sm:backdrop-blur-sm",
|
|
28
|
+
children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)(SidebarTrigger, { className: "-ml-1" }), /* @__PURE__ */ (0, import_jsx_runtime.jsx)("h1", {
|
|
29
|
+
className: "text-sm font-medium",
|
|
30
|
+
children: label
|
|
31
|
+
})]
|
|
32
|
+
}), /* @__PURE__ */ (0, import_jsx_runtime.jsx)("div", {
|
|
33
|
+
className: "flex min-h-0 min-w-0 flex-1 overflow-y-auto bg-muted/5 p-3 sm:p-6",
|
|
34
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(Empty, { children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)(EmptyHeader, { children: unavailableReason(feature, { remote }) === "remote" ? /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(import_jsx_runtime.Fragment, { children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)(EmptyTitle, { children: "Needs the server's database" }), /* @__PURE__ */ (0, import_jsx_runtime.jsx)(EmptyDescription, { children: "This console reaches a self-hosted server through its admin API, which does not serve this page. Configure the console with the database the server uses." })] }) : /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(import_jsx_runtime.Fragment, { children: [/* @__PURE__ */ (0, import_jsx_runtime.jsxs)(EmptyTitle, { children: [label, " not installed"] }), /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(EmptyDescription, { children: [
|
|
35
|
+
"Add ",
|
|
36
|
+
pluginCall,
|
|
37
|
+
" to ",
|
|
38
|
+
/* @__PURE__ */ (0, import_jsx_runtime.jsx)("code", {
|
|
39
|
+
className: "font-mono",
|
|
40
|
+
children: "plugins"
|
|
41
|
+
}),
|
|
42
|
+
" ",
|
|
43
|
+
remote ? "where you create the server." : "where you create the server and in the console config."
|
|
44
|
+
] })] }) }), /* @__PURE__ */ (0, import_jsx_runtime.jsx)(EmptyContent, { children: /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("a", {
|
|
45
|
+
className: buttonVariants({ variant: "outline" }),
|
|
46
|
+
href: CONSOLE_DEPLOYMENT_GUIDE_URL,
|
|
47
|
+
rel: "noreferrer",
|
|
48
|
+
target: "_blank",
|
|
49
|
+
children: ["Console setup guide", /* @__PURE__ */ (0, import_jsx_runtime.jsx)(ArrowUpRight, {
|
|
50
|
+
"aria-hidden": "true",
|
|
51
|
+
"data-icon": "inline-end"
|
|
52
|
+
})]
|
|
53
|
+
}) })] })
|
|
54
|
+
})]
|
|
55
|
+
});
|
|
56
|
+
}
|
|
57
|
+
//#endregion
|
|
58
|
+
export { ConsoleFeatureUnavailable as t };
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { C as
|
|
1
|
+
import { pt as require_jsx_runtime } from "../_libs/@base-ui/react+[...].mjs";
|
|
2
|
+
import { C as Tooltip$1, E as TooltipTrigger, O as cn, w as TooltipContent } from "./sidebar-Cw1VuC7d.mjs";
|
|
3
3
|
import { n as toast } from "../_libs/sonner.mjs";
|
|
4
|
-
//#region node_modules/.nitro/vite/services/ssr/assets/HashValueDisplay-
|
|
4
|
+
//#region node_modules/.nitro/vite/services/ssr/assets/HashValueDisplay-BplboHEb.js
|
|
5
5
|
var import_jsx_runtime = require_jsx_runtime();
|
|
6
6
|
var shortenIdentifier = (value, maxLength = 12) => value.length > maxLength ? `${value.slice(0, Math.max(1, maxLength - 4))}…${value.slice(-4)}` : value;
|
|
7
7
|
function HashValueDisplay({ value, maxLength = 12, className, buttonClassName }) {
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
import { i as __toESM } from "../_runtime.mjs";
|
|
2
|
+
import { mt as require_react, pt as require_jsx_runtime } from "../_libs/@base-ui/react+[...].mjs";
|
|
3
|
+
import { S as Info } from "../_libs/lucide-react.mjs";
|
|
4
|
+
import { C as Tooltip$1, E as TooltipTrigger, t as Button$1, w as TooltipContent } from "./sidebar-Cw1VuC7d.mjs";
|
|
5
|
+
//#region node_modules/.nitro/vite/services/ssr/assets/InsightsInfo-o2YPd5Qc.js
|
|
6
|
+
var import_react = /* @__PURE__ */ __toESM(require_react());
|
|
7
|
+
var import_jsx_runtime = require_jsx_runtime();
|
|
8
|
+
function InsightsInfo({ label, children }) {
|
|
9
|
+
const id = (0, import_react.useId)();
|
|
10
|
+
const [open, setOpen] = (0, import_react.useState)(false);
|
|
11
|
+
return /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(Tooltip$1, {
|
|
12
|
+
open,
|
|
13
|
+
onOpenChange: setOpen,
|
|
14
|
+
triggerId: id,
|
|
15
|
+
children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)(TooltipTrigger, {
|
|
16
|
+
id,
|
|
17
|
+
"aria-describedby": open ? `${id}-description` : void 0,
|
|
18
|
+
closeOnClick: false,
|
|
19
|
+
onClick: () => setOpen((value) => !value),
|
|
20
|
+
render: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Button$1, {
|
|
21
|
+
"aria-label": label,
|
|
22
|
+
className: "size-11 sm:size-7",
|
|
23
|
+
size: "icon",
|
|
24
|
+
variant: "ghost"
|
|
25
|
+
}),
|
|
26
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Info, {})
|
|
27
|
+
}), /* @__PURE__ */ (0, import_jsx_runtime.jsx)(TooltipContent, {
|
|
28
|
+
id: `${id}-description`,
|
|
29
|
+
role: "tooltip",
|
|
30
|
+
className: "max-w-64",
|
|
31
|
+
side: "bottom",
|
|
32
|
+
children
|
|
33
|
+
})]
|
|
34
|
+
});
|
|
35
|
+
}
|
|
36
|
+
//#endregion
|
|
37
|
+
export { InsightsInfo as t };
|
|
@@ -0,0 +1,154 @@
|
|
|
1
|
+
import { E as TabsRoot, T as TabsTab, pt as require_jsx_runtime, w as TabsList$1 } from "../_libs/@base-ui/react+[...].mjs";
|
|
2
|
+
import { I as ChartNoAxesCombined, S as Info, b as List, n as TriangleAlert } from "../_libs/lucide-react.mjs";
|
|
3
|
+
import { t as cva } from "../_libs/class-variance-authority+clsx.mjs";
|
|
4
|
+
import { D as buttonVariants, O as cn, x as SidebarTrigger } from "./sidebar-Cw1VuC7d.mjs";
|
|
5
|
+
import { i as AlertTitle, r as AlertDescription, t as Alert } from "./field-mjhcNEXD.mjs";
|
|
6
|
+
import { r as isConsoleFeatureUnavailableError } from "./console-features-CsbyHYfK.mjs";
|
|
7
|
+
import { h as Link } from "../_libs/@tanstack/react-router+[...].mjs";
|
|
8
|
+
import { i as useConsoleFeature } from "./console-features-api-B-KVuo4p.mjs";
|
|
9
|
+
import { n as usageMetrics } from "./insights-usage-1nVTQrLy.mjs";
|
|
10
|
+
//#region node_modules/.nitro/vite/services/ssr/assets/InsightsPageHeader-NExCJL1I.js
|
|
11
|
+
var import_jsx_runtime = require_jsx_runtime();
|
|
12
|
+
function InsightsErrorAlert({ error, fallbackTitle }) {
|
|
13
|
+
if (isConsoleFeatureUnavailableError(error)) return /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(Alert, { children: [
|
|
14
|
+
/* @__PURE__ */ (0, import_jsx_runtime.jsx)(Info, { "aria-hidden": "true" }),
|
|
15
|
+
/* @__PURE__ */ (0, import_jsx_runtime.jsx)(AlertTitle, { children: "Insights not installed" }),
|
|
16
|
+
/* @__PURE__ */ (0, import_jsx_runtime.jsx)(AlertDescription, { children: error.message })
|
|
17
|
+
] });
|
|
18
|
+
return /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(Alert, {
|
|
19
|
+
variant: "destructive",
|
|
20
|
+
children: [
|
|
21
|
+
/* @__PURE__ */ (0, import_jsx_runtime.jsx)(TriangleAlert, { "aria-hidden": "true" }),
|
|
22
|
+
/* @__PURE__ */ (0, import_jsx_runtime.jsx)(AlertTitle, { children: fallbackTitle }),
|
|
23
|
+
/* @__PURE__ */ (0, import_jsx_runtime.jsx)(AlertDescription, { children: "Refresh to try again. If this keeps happening, check your Insights provider connection." })
|
|
24
|
+
]
|
|
25
|
+
});
|
|
26
|
+
}
|
|
27
|
+
function Tabs$1({ className, orientation = "horizontal", ...props }) {
|
|
28
|
+
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(TabsRoot, {
|
|
29
|
+
orientation,
|
|
30
|
+
"data-slot": "tabs",
|
|
31
|
+
"data-orientation": orientation,
|
|
32
|
+
className: cn("group/tabs flex gap-2 data-horizontal:flex-col", className),
|
|
33
|
+
...props
|
|
34
|
+
});
|
|
35
|
+
}
|
|
36
|
+
var tabsListVariants = cva("group/tabs-list inline-flex w-fit items-center justify-center rounded-lg p-[3px] text-muted-foreground group-data-horizontal/tabs:h-8 group-data-vertical/tabs:h-fit group-data-vertical/tabs:flex-col data-[variant=line]:rounded-none", {
|
|
37
|
+
variants: { variant: {
|
|
38
|
+
default: "bg-muted",
|
|
39
|
+
line: "gap-1 bg-transparent"
|
|
40
|
+
} },
|
|
41
|
+
defaultVariants: { variant: "default" }
|
|
42
|
+
});
|
|
43
|
+
function TabsList({ className, variant = "default", ...props }) {
|
|
44
|
+
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(TabsList$1, {
|
|
45
|
+
"data-slot": "tabs-list",
|
|
46
|
+
"data-variant": variant,
|
|
47
|
+
className: cn(tabsListVariants({ variant }), className),
|
|
48
|
+
...props
|
|
49
|
+
});
|
|
50
|
+
}
|
|
51
|
+
function TabsTrigger({ className, ...props }) {
|
|
52
|
+
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(TabsTab, {
|
|
53
|
+
"data-slot": "tabs-trigger",
|
|
54
|
+
className: cn("relative inline-flex h-[calc(100%-1px)] flex-1 items-center justify-center gap-1.5 rounded-md border border-transparent px-1.5 py-0.5 text-xs font-medium whitespace-nowrap text-foreground/60 transition-all group-data-vertical/tabs:w-full group-data-vertical/tabs:justify-start group-data-vertical/tabs:py-[calc(--spacing(1.25))] hover:text-foreground focus-visible:border-ring focus-visible:ring-[3px] focus-visible:ring-ring/50 focus-visible:outline-1 focus-visible:outline-ring disabled:pointer-events-none disabled:opacity-50 has-data-[icon=inline-end]:pr-1 has-data-[icon=inline-start]:pl-1 aria-disabled:pointer-events-none aria-disabled:opacity-50 dark:text-muted-foreground dark:hover:text-foreground [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-3.5", "group-data-[variant=line]/tabs-list:bg-transparent group-data-[variant=line]/tabs-list:data-active:bg-transparent dark:group-data-[variant=line]/tabs-list:data-active:border-transparent dark:group-data-[variant=line]/tabs-list:data-active:bg-transparent", "data-active:bg-background data-active:text-foreground dark:data-active:border-input dark:data-active:bg-input/30 dark:data-active:text-foreground", "after:absolute after:bg-foreground after:opacity-0 after:transition-opacity group-data-horizontal/tabs:after:inset-x-0 group-data-horizontal/tabs:after:bottom-[-5px] group-data-horizontal/tabs:after:h-0.5 group-data-vertical/tabs:after:inset-y-0 group-data-vertical/tabs:after:-right-1 group-data-vertical/tabs:after:w-0.5 group-data-[variant=line]/tabs-list:data-active:after:opacity-100", className),
|
|
55
|
+
...props
|
|
56
|
+
});
|
|
57
|
+
}
|
|
58
|
+
/** A segmented control over fixed periods, each shown by its short value. */
|
|
59
|
+
function PeriodSelector({ label, onPeriodChange, period, periods }) {
|
|
60
|
+
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Tabs$1, {
|
|
61
|
+
value: period,
|
|
62
|
+
onValueChange: (value) => {
|
|
63
|
+
const next = periods.find((item) => item.value === value);
|
|
64
|
+
if (next) onPeriodChange(next.value);
|
|
65
|
+
},
|
|
66
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(TabsList, {
|
|
67
|
+
"aria-label": label,
|
|
68
|
+
className: "min-h-11 sm:min-h-9",
|
|
69
|
+
children: periods.map(({ value, name }) => /* @__PURE__ */ (0, import_jsx_runtime.jsx)(TabsTrigger, {
|
|
70
|
+
value,
|
|
71
|
+
"aria-label": name,
|
|
72
|
+
className: "min-w-12 px-3",
|
|
73
|
+
children: value
|
|
74
|
+
}, value))
|
|
75
|
+
})
|
|
76
|
+
});
|
|
77
|
+
}
|
|
78
|
+
var reportingPeriods = [
|
|
79
|
+
"24h",
|
|
80
|
+
"7d",
|
|
81
|
+
"30d"
|
|
82
|
+
].map((value) => ({
|
|
83
|
+
value,
|
|
84
|
+
name: usageMetrics[value].period
|
|
85
|
+
}));
|
|
86
|
+
var usagePeriods = Object.keys(usageMetrics).map((value) => ({
|
|
87
|
+
value,
|
|
88
|
+
name: usageMetrics[value].period
|
|
89
|
+
}));
|
|
90
|
+
function InsightsPeriodSelector({ window, onWindowChange }) {
|
|
91
|
+
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(PeriodSelector, {
|
|
92
|
+
label: "Reporting period",
|
|
93
|
+
onPeriodChange: onWindowChange,
|
|
94
|
+
period: window,
|
|
95
|
+
periods: reportingPeriods
|
|
96
|
+
});
|
|
97
|
+
}
|
|
98
|
+
/** App usage's periods: the reporting periods, and 12 months where daily totals cover it. */
|
|
99
|
+
function UsagePeriodSelector({ window, onWindowChange, twelveMonths = true }) {
|
|
100
|
+
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(PeriodSelector, {
|
|
101
|
+
label: "Reporting period",
|
|
102
|
+
onPeriodChange: onWindowChange,
|
|
103
|
+
period: window,
|
|
104
|
+
periods: usagePeriods.filter(({ value }) => twelveMonths || value !== "12m")
|
|
105
|
+
});
|
|
106
|
+
}
|
|
107
|
+
function InsightsPageHeader({ view, overviewSearch }) {
|
|
108
|
+
const overview = useConsoleFeature("insightsAnalytics");
|
|
109
|
+
return /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("header", {
|
|
110
|
+
className: "sticky top-0 z-10 flex shrink-0 flex-wrap items-center gap-3 border-b bg-background px-3 py-3 sm:bg-card/70 sm:px-4 sm:backdrop-blur-sm",
|
|
111
|
+
children: [
|
|
112
|
+
/* @__PURE__ */ (0, import_jsx_runtime.jsx)(SidebarTrigger, { className: "-ml-1 size-11 lg:size-7" }),
|
|
113
|
+
/* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", {
|
|
114
|
+
className: "flex items-center gap-1.5",
|
|
115
|
+
children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)(ChartNoAxesCombined, {
|
|
116
|
+
"aria-hidden": "true",
|
|
117
|
+
className: "size-3.5 text-muted-foreground"
|
|
118
|
+
}), /* @__PURE__ */ (0, import_jsx_runtime.jsx)("h1", {
|
|
119
|
+
className: "text-sm font-medium",
|
|
120
|
+
children: "Insights"
|
|
121
|
+
})]
|
|
122
|
+
}),
|
|
123
|
+
/* @__PURE__ */ (0, import_jsx_runtime.jsxs)("nav", {
|
|
124
|
+
"aria-label": "Insights views",
|
|
125
|
+
className: "ml-auto flex gap-2",
|
|
126
|
+
children: [overview ? /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Link, {
|
|
127
|
+
"aria-current": view === "overview" ? "page" : void 0,
|
|
128
|
+
className: cn(buttonVariants({
|
|
129
|
+
className: "h-11 px-3 lg:h-8 lg:px-2.5",
|
|
130
|
+
size: "lg",
|
|
131
|
+
variant: view === "overview" ? "secondary" : "ghost"
|
|
132
|
+
})),
|
|
133
|
+
search: overviewSearch,
|
|
134
|
+
to: "/insights",
|
|
135
|
+
children: "Overview"
|
|
136
|
+
}) : null, /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(Link, {
|
|
137
|
+
"aria-current": view === "events" ? "page" : void 0,
|
|
138
|
+
className: cn(buttonVariants({
|
|
139
|
+
className: "h-11 px-3 lg:h-8 lg:px-2.5",
|
|
140
|
+
size: "lg",
|
|
141
|
+
variant: view === "events" ? "secondary" : "ghost"
|
|
142
|
+
})),
|
|
143
|
+
to: "/installations",
|
|
144
|
+
children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)(List, {
|
|
145
|
+
"aria-hidden": "true",
|
|
146
|
+
"data-icon": "inline-start"
|
|
147
|
+
}), "All events"]
|
|
148
|
+
})]
|
|
149
|
+
})
|
|
150
|
+
]
|
|
151
|
+
});
|
|
152
|
+
}
|
|
153
|
+
//#endregion
|
|
154
|
+
export { UsagePeriodSelector as a, PeriodSelector as i, InsightsPageHeader as n, InsightsPeriodSelector as r, InsightsErrorAlert as t };
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
import { pt as require_jsx_runtime } from "../_libs/@base-ui/react+[...].mjs";
|
|
2
|
+
import { D as buttonVariants } from "./sidebar-Cw1VuC7d.mjs";
|
|
3
|
+
import { h as Link } from "../_libs/@tanstack/react-router+[...].mjs";
|
|
4
|
+
//#region node_modules/.nitro/vite/services/ssr/assets/NotFoundPage-Cd-A8ock.js
|
|
5
|
+
var import_jsx_runtime = require_jsx_runtime();
|
|
6
|
+
var homeSearch = {
|
|
7
|
+
afterReleaseId: void 0,
|
|
8
|
+
beforeReleaseId: void 0,
|
|
9
|
+
bundleId: void 0,
|
|
10
|
+
channelId: void 0,
|
|
11
|
+
enabled: void 0,
|
|
12
|
+
platform: void 0,
|
|
13
|
+
releaseId: void 0,
|
|
14
|
+
scopeKey: void 0
|
|
15
|
+
};
|
|
16
|
+
function NotFoundPage() {
|
|
17
|
+
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)("div", {
|
|
18
|
+
className: "flex min-h-svh flex-1 items-center justify-center px-6 py-10",
|
|
19
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("section", {
|
|
20
|
+
className: "flex max-w-md flex-col items-center text-center",
|
|
21
|
+
children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)("h1", {
|
|
22
|
+
className: "text-2xl font-semibold tracking-tight text-foreground",
|
|
23
|
+
children: "Page not found"
|
|
24
|
+
}), /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Link, {
|
|
25
|
+
className: buttonVariants({
|
|
26
|
+
className: "mt-6",
|
|
27
|
+
size: "lg"
|
|
28
|
+
}),
|
|
29
|
+
to: "/",
|
|
30
|
+
search: homeSearch,
|
|
31
|
+
children: "Go to home"
|
|
32
|
+
})]
|
|
33
|
+
})
|
|
34
|
+
});
|
|
35
|
+
}
|
|
36
|
+
//#endregion
|
|
37
|
+
export { NotFoundPage as t };
|