@hot-updater/console 0.29.4 → 0.29.6
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.output/nitro.json +1 -1
- package/.output/public/assets/{main-Dlx8-qN-.js → main-hOHGHX7C.js} +1 -1
- package/.output/public/assets/{routes-DB0tWmiJ.js → routes-B2UPnemG.js} +3 -3
- package/.output/server/_ssr/{api-rpc-CVBxLaGD.mjs → api-rpc-Cr26KHOK.mjs} +13 -5
- package/.output/server/_ssr/{router-BnX8JLYH.mjs → router-DB7WR5Zr.mjs} +15 -6
- package/.output/server/_ssr/{routes-z71qW0Uy.mjs → routes-FhQwSgxW.mjs} +148 -99
- package/.output/server/_ssr/ssr.mjs +12 -12
- package/.output/server/{_tanstack-start-manifest_v-DTbQVOpU.mjs → _tanstack-start-manifest_v-bE9hwtzg.mjs} +4 -4
- package/.output/server/index.mjs +31 -31
- package/package.json +6 -6
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import "../_libs/@radix-ui/react-alert-dialog+[...].mjs";
|
|
2
2
|
import { n as createServerFn, r as TSS_SERVER_FUNCTION } from "./ssr.mjs";
|
|
3
|
-
//#region node_modules/.nitro/vite/services/ssr/assets/api-rpc-
|
|
3
|
+
//#region node_modules/.nitro/vite/services/ssr/assets/api-rpc-Cr26KHOK.js
|
|
4
4
|
var createServerRpc = (serverFnMeta, splitImportFn) => {
|
|
5
5
|
const url = "/_serverFn/" + serverFnMeta.id;
|
|
6
6
|
return Object.assign(splitImportFn, {
|
|
@@ -64,8 +64,10 @@ var getBundles = createServerFn({ method: "GET" }).inputValidator((input) => inp
|
|
|
64
64
|
const query = {
|
|
65
65
|
channel: data?.channel ?? void 0,
|
|
66
66
|
platform: data?.platform ?? void 0,
|
|
67
|
+
page: typeof data?.page === "number" && Number.isInteger(data.page) && data.page > 1 ? data.page : void 0,
|
|
67
68
|
limit: data?.limit ? Number(data.limit) : 20,
|
|
68
|
-
|
|
69
|
+
after: data?.after ?? void 0,
|
|
70
|
+
before: data?.before ?? void 0
|
|
69
71
|
};
|
|
70
72
|
const { databasePlugin } = await prepareConfig();
|
|
71
73
|
return await databasePlugin.getBundles({
|
|
@@ -74,13 +76,19 @@ var getBundles = createServerFn({ method: "GET" }).inputValidator((input) => inp
|
|
|
74
76
|
platform: query.platform
|
|
75
77
|
},
|
|
76
78
|
limit: query.limit,
|
|
77
|
-
|
|
79
|
+
page: query.page,
|
|
80
|
+
cursor: query.after || query.before ? {
|
|
81
|
+
after: query.after,
|
|
82
|
+
before: query.before
|
|
83
|
+
} : void 0
|
|
78
84
|
}) ?? {
|
|
79
85
|
data: [],
|
|
80
86
|
pagination: {
|
|
81
87
|
total: 0,
|
|
82
|
-
|
|
83
|
-
|
|
88
|
+
hasNextPage: false,
|
|
89
|
+
hasPreviousPage: false,
|
|
90
|
+
currentPage: 1,
|
|
91
|
+
totalPages: 0
|
|
84
92
|
}
|
|
85
93
|
};
|
|
86
94
|
} catch (error) {
|
|
@@ -8,7 +8,7 @@ import { t as QueryClient } from "../_libs/tanstack__query-core.mjs";
|
|
|
8
8
|
import { r as QueryClientProvider } from "../_libs/tanstack__react-query.mjs";
|
|
9
9
|
import { t as z } from "../_libs/next-themes.mjs";
|
|
10
10
|
import { t as Toaster } from "../_libs/sonner.mjs";
|
|
11
|
-
//#region node_modules/.nitro/vite/services/ssr/assets/router-
|
|
11
|
+
//#region node_modules/.nitro/vite/services/ssr/assets/router-DB7WR5Zr.js
|
|
12
12
|
var import_jsx_runtime = require_jsx_runtime();
|
|
13
13
|
var import_react = /* @__PURE__ */ __toESM(require_react());
|
|
14
14
|
function HotUpdaterLogo({ className }) {
|
|
@@ -94,7 +94,9 @@ function AppSidebar() {
|
|
|
94
94
|
search: {
|
|
95
95
|
channel: void 0,
|
|
96
96
|
platform: void 0,
|
|
97
|
-
|
|
97
|
+
page: void 0,
|
|
98
|
+
after: void 0,
|
|
99
|
+
before: void 0,
|
|
98
100
|
bundleId: void 0
|
|
99
101
|
},
|
|
100
102
|
className: "flex items-center gap-3 p-1 group-data-[collapsible=icon]:justify-center group-data-[collapsible=icon]:p-2",
|
|
@@ -119,7 +121,9 @@ function AppSidebar() {
|
|
|
119
121
|
search: {
|
|
120
122
|
channel: void 0,
|
|
121
123
|
platform: void 0,
|
|
122
|
-
|
|
124
|
+
page: void 0,
|
|
125
|
+
after: void 0,
|
|
126
|
+
before: void 0,
|
|
123
127
|
bundleId: void 0
|
|
124
128
|
},
|
|
125
129
|
children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)(Package, {}), /* @__PURE__ */ (0, import_jsx_runtime.jsx)("span", { children: "Bundles" })]
|
|
@@ -136,7 +140,9 @@ function AppSidebar() {
|
|
|
136
140
|
var homeSearch = {
|
|
137
141
|
channel: void 0,
|
|
138
142
|
platform: void 0,
|
|
139
|
-
|
|
143
|
+
page: void 0,
|
|
144
|
+
after: void 0,
|
|
145
|
+
before: void 0,
|
|
140
146
|
bundleId: void 0
|
|
141
147
|
};
|
|
142
148
|
function NotFoundPage() {
|
|
@@ -221,14 +227,17 @@ function RootLayout() {
|
|
|
221
227
|
(0, import_react.useEffect)(() => {}, []);
|
|
222
228
|
return /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(SidebarProvider, { children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)(AppSidebar, {}), /* @__PURE__ */ (0, import_jsx_runtime.jsx)(SidebarInset, { children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Outlet, {}) })] });
|
|
223
229
|
}
|
|
224
|
-
var $$splitComponentImporter = () => import("./routes-
|
|
230
|
+
var $$splitComponentImporter = () => import("./routes-FhQwSgxW.mjs");
|
|
225
231
|
var rootRouteChildren = { IndexRoute: createFileRoute("/")({
|
|
226
232
|
component: lazyRouteComponent($$splitComponentImporter, "component"),
|
|
227
233
|
validateSearch: (search) => {
|
|
234
|
+
const parsedPage = typeof search.page === "number" ? search.page : typeof search.page === "string" ? Number(search.page) : void 0;
|
|
228
235
|
return {
|
|
229
236
|
channel: search.channel,
|
|
230
237
|
platform: search.platform,
|
|
231
|
-
|
|
238
|
+
page: parsedPage !== void 0 && Number.isInteger(parsedPage) && parsedPage > 1 ? parsedPage : void 0,
|
|
239
|
+
after: search.after,
|
|
240
|
+
before: search.before,
|
|
232
241
|
bundleId: search.bundleId
|
|
233
242
|
};
|
|
234
243
|
}
|
|
@@ -17,75 +17,12 @@ import { n as toast } from "../_libs/sonner.mjs";
|
|
|
17
17
|
import { t as require_semver } from "../_libs/semver.mjs";
|
|
18
18
|
import { i as getCoreRowModel, n as useReactTable, r as createColumnHelper, t as flexRender } from "../_libs/@tanstack/react-table+[...].mjs";
|
|
19
19
|
import { n as require_dayjs_min, t as require_relativeTime } from "../_libs/dayjs.mjs";
|
|
20
|
-
//#region node_modules/.nitro/vite/services/ssr/assets/routes-
|
|
20
|
+
//#region node_modules/.nitro/vite/services/ssr/assets/routes-FhQwSgxW.js
|
|
21
21
|
var import_jsx_runtime = require_jsx_runtime();
|
|
22
22
|
var import_react = /* @__PURE__ */ __toESM(require_react());
|
|
23
23
|
var import_semver = /* @__PURE__ */ __toESM(require_semver());
|
|
24
24
|
var import_dayjs_min = /* @__PURE__ */ __toESM(require_dayjs_min());
|
|
25
25
|
var import_relativeTime = /* @__PURE__ */ __toESM(require_relativeTime());
|
|
26
|
-
function AppleIcon({ className }) {
|
|
27
|
-
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)("svg", {
|
|
28
|
-
role: "img",
|
|
29
|
-
"aria-label": "iOS",
|
|
30
|
-
viewBox: "0 0 24 24",
|
|
31
|
-
xmlns: "http://www.w3.org/2000/svg",
|
|
32
|
-
className,
|
|
33
|
-
fill: "currentColor",
|
|
34
|
-
children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)("path", { d: "M12.152 6.896c-.948 0-2.415-1.078-3.96-1.04-2.04.027-3.91 1.183-4.961 3.014-2.117 3.675-.546 9.103 1.519 12.09 1.013 1.454 2.208 3.09 3.792 3.039 1.52-.065 2.09-.987 3.935-.987 1.831 0 2.35.987 3.96.948 1.637-.026 2.676-1.48 3.676-2.948 1.156-1.688 1.636-3.325 1.662-3.415-.039-.013-3.182-1.221-3.22-4.857-.026-3.04 2.48-4.494 2.597-4.559-1.429-2.09-3.623-2.324-4.39-2.376-2-.156-3.675 1.09-4.61 1.09zM15.53 3.83c.843-1.012 1.4-2.427 1.245-3.83-1.207.052-2.662.805-3.532 1.818-.78.896-1.454 2.338-1.273 3.714 1.338.104 2.715-.688 3.559-1.701" })
|
|
35
|
-
});
|
|
36
|
-
}
|
|
37
|
-
function AndroidIcon({ className }) {
|
|
38
|
-
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)("svg", {
|
|
39
|
-
role: "img",
|
|
40
|
-
"aria-label": "Android",
|
|
41
|
-
viewBox: "0 0 24 24",
|
|
42
|
-
xmlns: "http://www.w3.org/2000/svg",
|
|
43
|
-
className,
|
|
44
|
-
fill: "currentColor",
|
|
45
|
-
children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)("path", { d: "M18.4395 5.5586c-.675 1.1664-1.352 2.3318-2.0274 3.498-.0366-.0155-.0742-.0286-.1113-.043-1.8249-.6957-3.484-.8-4.42-.787-1.8551.0185-3.3544.4643-4.2597.8203-.084-.1494-1.7526-3.021-2.0215-3.4864a1.1451 1.1451 0 0 0-.1406-.1914c-.3312-.364-.9054-.4859-1.379-.203-.475.282-.7136.9361-.3886 1.5019 1.9466 3.3696-.0966-.2158 1.9473 3.3593.0172.031-.4946.2642-1.3926 1.0177C2.8987 12.176.452 14.772 0 18.9902h24c-.119-1.1108-.3686-2.099-.7461-3.0683-.7438-1.9118-1.8435-3.2928-2.7402-4.1836a12.1048 12.1048 0 0 0-2.1309-1.6875c.6594-1.122 1.312-2.2559 1.9649-3.3848.2077-.3615.1886-.7956-.0079-1.1191a1.1001 1.1001 0 0 0-.8515-.5332c-.5225-.0536-.9392.3128-1.0488.5449zm-.0391 8.461c.3944.5926.324 1.3306-.1563 1.6503-.4799.3197-1.188.0985-1.582-.4941-.3944-.5927-.324-1.3307.1563-1.6504.4727-.315 1.1812-.1086 1.582.4941zM7.207 13.5273c.4803.3197.5506 1.0577.1563 1.6504-.394.5926-1.1038.8138-1.584.4941-.48-.3197-.5503-1.0577-.1563-1.6504.4008-.6021 1.1087-.8106 1.584-.4941z" })
|
|
46
|
-
});
|
|
47
|
-
}
|
|
48
|
-
function PlatformIcon({ platform, className }) {
|
|
49
|
-
if (platform === "ios") return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(AppleIcon, { className });
|
|
50
|
-
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(AndroidIcon, { className });
|
|
51
|
-
}
|
|
52
|
-
function BundleBasicInfo({ bundle }) {
|
|
53
|
-
return /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", {
|
|
54
|
-
className: "flex flex-col gap-3 text-sm mt-1",
|
|
55
|
-
children: [
|
|
56
|
-
/* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", {
|
|
57
|
-
className: "flex items-center gap-2",
|
|
58
|
-
children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)(PlatformIcon, {
|
|
59
|
-
platform: bundle.platform,
|
|
60
|
-
className: "h-4 w-4"
|
|
61
|
-
}), /* @__PURE__ */ (0, import_jsx_runtime.jsx)("span", {
|
|
62
|
-
className: "font-medium",
|
|
63
|
-
children: bundle.platform === "ios" ? "iOS" : "Android"
|
|
64
|
-
})]
|
|
65
|
-
}),
|
|
66
|
-
/* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", {
|
|
67
|
-
className: "flex items-center gap-2",
|
|
68
|
-
children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)("span", {
|
|
69
|
-
className: "font-medium text-muted-foreground",
|
|
70
|
-
children: "Bundle ID"
|
|
71
|
-
}), /* @__PURE__ */ (0, import_jsx_runtime.jsx)("span", {
|
|
72
|
-
className: "text-xs text-foreground",
|
|
73
|
-
children: bundle.id
|
|
74
|
-
})]
|
|
75
|
-
}),
|
|
76
|
-
/* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", {
|
|
77
|
-
className: "flex items-center gap-2",
|
|
78
|
-
children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)("span", {
|
|
79
|
-
className: "font-medium text-muted-foreground",
|
|
80
|
-
children: "Channel"
|
|
81
|
-
}), /* @__PURE__ */ (0, import_jsx_runtime.jsx)("span", {
|
|
82
|
-
className: "text-xs text-foreground",
|
|
83
|
-
children: bundle.channel
|
|
84
|
-
})]
|
|
85
|
-
})
|
|
86
|
-
]
|
|
87
|
-
});
|
|
88
|
-
}
|
|
89
26
|
var NUMERIC_COHORT_SIZE = 1e3;
|
|
90
27
|
var DEFAULT_ROLLOUT_COHORT_COUNT = NUMERIC_COHORT_SIZE;
|
|
91
28
|
var INVALID_COHORT_ERROR_MESSAGE = `Invalid cohort. Use 1-1000 or a lowercase slug without spaces, up to 64 characters.`;
|
|
@@ -176,6 +113,69 @@ function getNumericCohortRolloutPosition(bundleId, cohortValue) {
|
|
|
176
113
|
const { offset, inverseMultiplier } = getRolloutShuffleParameters(bundleId);
|
|
177
114
|
return positiveMod(inverseMultiplier * (cohortValue - 1 - offset), NUMERIC_COHORT_SIZE);
|
|
178
115
|
}
|
|
116
|
+
function AppleIcon({ className }) {
|
|
117
|
+
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)("svg", {
|
|
118
|
+
role: "img",
|
|
119
|
+
"aria-label": "iOS",
|
|
120
|
+
viewBox: "0 0 24 24",
|
|
121
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
122
|
+
className,
|
|
123
|
+
fill: "currentColor",
|
|
124
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)("path", { d: "M12.152 6.896c-.948 0-2.415-1.078-3.96-1.04-2.04.027-3.91 1.183-4.961 3.014-2.117 3.675-.546 9.103 1.519 12.09 1.013 1.454 2.208 3.09 3.792 3.039 1.52-.065 2.09-.987 3.935-.987 1.831 0 2.35.987 3.96.948 1.637-.026 2.676-1.48 3.676-2.948 1.156-1.688 1.636-3.325 1.662-3.415-.039-.013-3.182-1.221-3.22-4.857-.026-3.04 2.48-4.494 2.597-4.559-1.429-2.09-3.623-2.324-4.39-2.376-2-.156-3.675 1.09-4.61 1.09zM15.53 3.83c.843-1.012 1.4-2.427 1.245-3.83-1.207.052-2.662.805-3.532 1.818-.78.896-1.454 2.338-1.273 3.714 1.338.104 2.715-.688 3.559-1.701" })
|
|
125
|
+
});
|
|
126
|
+
}
|
|
127
|
+
function AndroidIcon({ className }) {
|
|
128
|
+
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)("svg", {
|
|
129
|
+
role: "img",
|
|
130
|
+
"aria-label": "Android",
|
|
131
|
+
viewBox: "0 0 24 24",
|
|
132
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
133
|
+
className,
|
|
134
|
+
fill: "currentColor",
|
|
135
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)("path", { d: "M18.4395 5.5586c-.675 1.1664-1.352 2.3318-2.0274 3.498-.0366-.0155-.0742-.0286-.1113-.043-1.8249-.6957-3.484-.8-4.42-.787-1.8551.0185-3.3544.4643-4.2597.8203-.084-.1494-1.7526-3.021-2.0215-3.4864a1.1451 1.1451 0 0 0-.1406-.1914c-.3312-.364-.9054-.4859-1.379-.203-.475.282-.7136.9361-.3886 1.5019 1.9466 3.3696-.0966-.2158 1.9473 3.3593.0172.031-.4946.2642-1.3926 1.0177C2.8987 12.176.452 14.772 0 18.9902h24c-.119-1.1108-.3686-2.099-.7461-3.0683-.7438-1.9118-1.8435-3.2928-2.7402-4.1836a12.1048 12.1048 0 0 0-2.1309-1.6875c.6594-1.122 1.312-2.2559 1.9649-3.3848.2077-.3615.1886-.7956-.0079-1.1191a1.1001 1.1001 0 0 0-.8515-.5332c-.5225-.0536-.9392.3128-1.0488.5449zm-.0391 8.461c.3944.5926.324 1.3306-.1563 1.6503-.4799.3197-1.188.0985-1.582-.4941-.3944-.5927-.324-1.3307.1563-1.6504.4727-.315 1.1812-.1086 1.582.4941zM7.207 13.5273c.4803.3197.5506 1.0577.1563 1.6504-.394.5926-1.1038.8138-1.584.4941-.48-.3197-.5503-1.0577-.1563-1.6504.4008-.6021 1.1087-.8106 1.584-.4941z" })
|
|
136
|
+
});
|
|
137
|
+
}
|
|
138
|
+
function PlatformIcon({ platform, className }) {
|
|
139
|
+
if (platform === "ios") return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(AppleIcon, { className });
|
|
140
|
+
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(AndroidIcon, { className });
|
|
141
|
+
}
|
|
142
|
+
function BundleBasicInfo({ bundle }) {
|
|
143
|
+
return /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", {
|
|
144
|
+
className: "flex flex-col gap-3 text-sm mt-1",
|
|
145
|
+
children: [
|
|
146
|
+
/* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", {
|
|
147
|
+
className: "flex items-center gap-2",
|
|
148
|
+
children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)(PlatformIcon, {
|
|
149
|
+
platform: bundle.platform,
|
|
150
|
+
className: "h-4 w-4"
|
|
151
|
+
}), /* @__PURE__ */ (0, import_jsx_runtime.jsx)("span", {
|
|
152
|
+
className: "font-medium",
|
|
153
|
+
children: bundle.platform === "ios" ? "iOS" : "Android"
|
|
154
|
+
})]
|
|
155
|
+
}),
|
|
156
|
+
/* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", {
|
|
157
|
+
className: "flex items-center gap-2",
|
|
158
|
+
children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)("span", {
|
|
159
|
+
className: "font-medium text-muted-foreground",
|
|
160
|
+
children: "Bundle ID"
|
|
161
|
+
}), /* @__PURE__ */ (0, import_jsx_runtime.jsx)("span", {
|
|
162
|
+
className: "text-xs text-foreground",
|
|
163
|
+
children: bundle.id
|
|
164
|
+
})]
|
|
165
|
+
}),
|
|
166
|
+
/* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", {
|
|
167
|
+
className: "flex items-center gap-2",
|
|
168
|
+
children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)("span", {
|
|
169
|
+
className: "font-medium text-muted-foreground",
|
|
170
|
+
children: "Channel"
|
|
171
|
+
}), /* @__PURE__ */ (0, import_jsx_runtime.jsx)("span", {
|
|
172
|
+
className: "text-xs text-foreground",
|
|
173
|
+
children: bundle.channel
|
|
174
|
+
})]
|
|
175
|
+
})
|
|
176
|
+
]
|
|
177
|
+
});
|
|
178
|
+
}
|
|
179
179
|
var badgeVariants = cva("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", {
|
|
180
180
|
variants: { variant: {
|
|
181
181
|
default: "border-transparent bg-primary text-primary-foreground shadow hover:bg-primary/80",
|
|
@@ -639,7 +639,9 @@ function useFilterParams() {
|
|
|
639
639
|
const filters = {
|
|
640
640
|
channel: search.channel,
|
|
641
641
|
platform: search.platform,
|
|
642
|
-
|
|
642
|
+
page: search.page,
|
|
643
|
+
after: search.after,
|
|
644
|
+
before: search.before
|
|
643
645
|
};
|
|
644
646
|
const bundleId = search.bundleId;
|
|
645
647
|
const navigateWithSearch = (nextSearch) => {
|
|
@@ -651,11 +653,17 @@ function useFilterParams() {
|
|
|
651
653
|
const getNextFilters = (newFilters) => {
|
|
652
654
|
const hasChannel = Object.hasOwn(newFilters, "channel");
|
|
653
655
|
const hasPlatform = Object.hasOwn(newFilters, "platform");
|
|
654
|
-
const
|
|
656
|
+
const hasPage = Object.hasOwn(newFilters, "page");
|
|
657
|
+
const hasAfter = Object.hasOwn(newFilters, "after");
|
|
658
|
+
const hasBefore = Object.hasOwn(newFilters, "before");
|
|
659
|
+
const shouldResetPagination = hasChannel || hasPlatform;
|
|
660
|
+
const nextPage = hasPage && newFilters.page !== void 0 && newFilters.page > 1 ? newFilters.page : void 0;
|
|
655
661
|
return {
|
|
656
662
|
channel: hasChannel ? newFilters.channel : filters.channel,
|
|
657
663
|
platform: hasPlatform ? newFilters.platform : filters.platform,
|
|
658
|
-
|
|
664
|
+
page: shouldResetPagination ? void 0 : hasPage ? nextPage : filters.page,
|
|
665
|
+
after: shouldResetPagination ? void 0 : hasAfter ? newFilters.after : filters.after,
|
|
666
|
+
before: shouldResetPagination ? void 0 : hasBefore ? newFilters.before : filters.before
|
|
659
667
|
};
|
|
660
668
|
};
|
|
661
669
|
const setFilters = (newFilters) => {
|
|
@@ -674,7 +682,9 @@ function useFilterParams() {
|
|
|
674
682
|
navigateWithSearch({
|
|
675
683
|
channel: void 0,
|
|
676
684
|
platform: void 0,
|
|
677
|
-
|
|
685
|
+
page: void 0,
|
|
686
|
+
after: void 0,
|
|
687
|
+
before: void 0,
|
|
678
688
|
bundleId: void 0
|
|
679
689
|
});
|
|
680
690
|
};
|
|
@@ -714,7 +724,8 @@ function PromoteChannelDialog({ bundle, open, onOpenChange, onSuccess }) {
|
|
|
714
724
|
const openBundleDetail = (nextBundleId, nextChannel) => {
|
|
715
725
|
setBundleId(nextBundleId, {
|
|
716
726
|
channel: nextChannel,
|
|
717
|
-
|
|
727
|
+
after: void 0,
|
|
728
|
+
before: void 0
|
|
718
729
|
});
|
|
719
730
|
};
|
|
720
731
|
const handlePromote = async () => {
|
|
@@ -1638,22 +1649,37 @@ var bundleColumns = [
|
|
|
1638
1649
|
cell: (info) => /* @__PURE__ */ (0, import_jsx_runtime.jsx)(TimestampDisplay, { uuid: info.getValue() })
|
|
1639
1650
|
})
|
|
1640
1651
|
];
|
|
1641
|
-
function BundlesTable({ bundles, selectedBundleId, onRowClick }) {
|
|
1642
|
-
const {
|
|
1643
|
-
const currentOffset = Number(filters.offset || 0);
|
|
1652
|
+
function BundlesTable({ bundles, pagination, selectedBundleId, onRowClick }) {
|
|
1653
|
+
const { setFilters } = useFilterParams();
|
|
1644
1654
|
const table = useReactTable({
|
|
1645
1655
|
data: bundles,
|
|
1646
1656
|
columns: bundleColumns,
|
|
1647
1657
|
getCoreRowModel: getCoreRowModel()
|
|
1648
1658
|
});
|
|
1659
|
+
const hasNextPage = pagination?.hasNextPage ?? false;
|
|
1660
|
+
const hasPreviousPage = pagination?.hasPreviousPage ?? false;
|
|
1661
|
+
const currentPage = pagination?.currentPage ?? 1;
|
|
1662
|
+
const totalPages = pagination?.totalPages ?? 0;
|
|
1649
1663
|
const handlePreviousPage = () => {
|
|
1650
|
-
|
|
1664
|
+
const previousCursor = pagination?.previousCursor ?? bundles[0]?.id;
|
|
1665
|
+
if (!previousCursor) return;
|
|
1666
|
+
setFilters({
|
|
1667
|
+
page: Math.max(1, currentPage - 1),
|
|
1668
|
+
after: void 0,
|
|
1669
|
+
before: previousCursor
|
|
1670
|
+
});
|
|
1651
1671
|
};
|
|
1652
1672
|
const handleNextPage = () => {
|
|
1653
|
-
|
|
1673
|
+
const nextCursor = pagination?.nextCursor ?? bundles.at(-1)?.id;
|
|
1674
|
+
if (!nextCursor) return;
|
|
1675
|
+
setFilters({
|
|
1676
|
+
page: currentPage + 1,
|
|
1677
|
+
after: nextCursor,
|
|
1678
|
+
before: void 0
|
|
1679
|
+
});
|
|
1654
1680
|
};
|
|
1655
|
-
const
|
|
1656
|
-
const
|
|
1681
|
+
const startEntry = bundles.length === 0 ? 0 : (currentPage - 1) * 20 + 1;
|
|
1682
|
+
const endEntry = startEntry === 0 ? 0 : startEntry + bundles.length - 1;
|
|
1657
1683
|
return /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", {
|
|
1658
1684
|
className: "space-y-4",
|
|
1659
1685
|
children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)("div", {
|
|
@@ -1688,35 +1714,54 @@ function BundlesTable({ bundles, selectedBundleId, onRowClick }) {
|
|
|
1688
1714
|
"Showing ",
|
|
1689
1715
|
/* @__PURE__ */ (0, import_jsx_runtime.jsx)("span", {
|
|
1690
1716
|
className: "text-foreground",
|
|
1691
|
-
children:
|
|
1717
|
+
children: startEntry
|
|
1692
1718
|
}),
|
|
1693
|
-
" ",
|
|
1694
|
-
"to",
|
|
1719
|
+
" to",
|
|
1695
1720
|
" ",
|
|
1696
1721
|
/* @__PURE__ */ (0, import_jsx_runtime.jsx)("span", {
|
|
1697
1722
|
className: "text-foreground",
|
|
1698
|
-
children:
|
|
1723
|
+
children: endEntry
|
|
1699
1724
|
}),
|
|
1700
|
-
" "
|
|
1701
|
-
"entries"
|
|
1725
|
+
" entries"
|
|
1702
1726
|
]
|
|
1703
1727
|
}), /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", {
|
|
1704
|
-
className: "flex items-center gap-
|
|
1705
|
-
children: [
|
|
1706
|
-
|
|
1707
|
-
|
|
1708
|
-
|
|
1709
|
-
|
|
1710
|
-
|
|
1711
|
-
|
|
1712
|
-
|
|
1713
|
-
|
|
1714
|
-
|
|
1715
|
-
|
|
1716
|
-
|
|
1717
|
-
|
|
1718
|
-
|
|
1719
|
-
|
|
1728
|
+
className: "flex items-center gap-3",
|
|
1729
|
+
children: [
|
|
1730
|
+
/* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", {
|
|
1731
|
+
className: "text-xs text-muted-foreground font-medium",
|
|
1732
|
+
children: [
|
|
1733
|
+
"Page ",
|
|
1734
|
+
/* @__PURE__ */ (0, import_jsx_runtime.jsx)("span", {
|
|
1735
|
+
className: "text-foreground",
|
|
1736
|
+
children: currentPage
|
|
1737
|
+
}),
|
|
1738
|
+
totalPages > 0 ? /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(import_jsx_runtime.Fragment, { children: [
|
|
1739
|
+
" ",
|
|
1740
|
+
"of ",
|
|
1741
|
+
/* @__PURE__ */ (0, import_jsx_runtime.jsx)("span", {
|
|
1742
|
+
className: "text-foreground",
|
|
1743
|
+
children: totalPages
|
|
1744
|
+
})
|
|
1745
|
+
] }) : null
|
|
1746
|
+
]
|
|
1747
|
+
}),
|
|
1748
|
+
/* @__PURE__ */ (0, import_jsx_runtime.jsxs)(Button, {
|
|
1749
|
+
variant: "outline",
|
|
1750
|
+
size: "sm",
|
|
1751
|
+
onClick: handlePreviousPage,
|
|
1752
|
+
disabled: !hasPreviousPage,
|
|
1753
|
+
className: "h-8 px-3 text-xs",
|
|
1754
|
+
children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)(ChevronLeft, { className: "h-3.5 w-3.5 mr-1" }), "Previous"]
|
|
1755
|
+
}),
|
|
1756
|
+
/* @__PURE__ */ (0, import_jsx_runtime.jsxs)(Button, {
|
|
1757
|
+
variant: "outline",
|
|
1758
|
+
size: "sm",
|
|
1759
|
+
onClick: handleNextPage,
|
|
1760
|
+
disabled: !hasNextPage,
|
|
1761
|
+
className: "h-8 px-3 text-xs",
|
|
1762
|
+
children: ["Next", /* @__PURE__ */ (0, import_jsx_runtime.jsx)(ChevronRight, { className: "h-3.5 w-3.5 ml-1" })]
|
|
1763
|
+
})
|
|
1764
|
+
]
|
|
1720
1765
|
})]
|
|
1721
1766
|
})]
|
|
1722
1767
|
});
|
|
@@ -1787,10 +1832,13 @@ function BundlesPage() {
|
|
|
1787
1832
|
const { data: bundlesData, isLoading } = useBundlesQuery({
|
|
1788
1833
|
channel: filters.channel,
|
|
1789
1834
|
platform: filters.platform,
|
|
1790
|
-
|
|
1835
|
+
page: filters.page,
|
|
1836
|
+
after: filters.after,
|
|
1837
|
+
before: filters.before,
|
|
1791
1838
|
limit: "20"
|
|
1792
1839
|
});
|
|
1793
1840
|
const bundles = bundlesData?.data ?? [];
|
|
1841
|
+
const pagination = bundlesData?.pagination;
|
|
1794
1842
|
const selectedBundleFromList = activeBundleId ? bundles.find((bundle) => bundle.id === activeBundleId) ?? null : null;
|
|
1795
1843
|
const { data: selectedBundleFromQuery, isPending: isSelectedBundlePending } = useBundleQuery(activeBundleId);
|
|
1796
1844
|
const selectedBundle = selectedBundleFromQuery ?? selectedBundleFromList;
|
|
@@ -1815,6 +1863,7 @@ function BundlesPage() {
|
|
|
1815
1863
|
className: "flex-1 p-6 space-y-6 bg-muted/5",
|
|
1816
1864
|
children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(BundlesTable, {
|
|
1817
1865
|
bundles,
|
|
1866
|
+
pagination,
|
|
1818
1867
|
selectedBundleId: bundleId,
|
|
1819
1868
|
onRowClick: (bundle) => setBundleId(bundle.id)
|
|
1820
1869
|
})
|
|
@@ -4269,7 +4269,7 @@ function getResponse() {
|
|
|
4269
4269
|
return getH3Event().res;
|
|
4270
4270
|
}
|
|
4271
4271
|
async function getStartManifest(matchedRoutes) {
|
|
4272
|
-
const { tsrStartManifest } = await import("../_tanstack-start-manifest_v-
|
|
4272
|
+
const { tsrStartManifest } = await import("../_tanstack-start-manifest_v-bE9hwtzg.mjs");
|
|
4273
4273
|
const startManifest = tsrStartManifest();
|
|
4274
4274
|
const rootRoute = startManifest.routes[rootRouteId] = startManifest.routes["__root__"] || {};
|
|
4275
4275
|
rootRoute.assets = rootRoute.assets || [];
|
|
@@ -4408,43 +4408,43 @@ function createMultiplexedStream(jsonStream, rawStreams) {
|
|
|
4408
4408
|
var manifest = {
|
|
4409
4409
|
"51a34c05479a893c7d320bd4cd1604427289d667698c48b9f30a01aabf8a5e68": {
|
|
4410
4410
|
functionName: "getConfig_createServerFn_handler",
|
|
4411
|
-
importer: () => import("./api-rpc-
|
|
4411
|
+
importer: () => import("./api-rpc-Cr26KHOK.mjs")
|
|
4412
4412
|
},
|
|
4413
4413
|
"79ada05964de8f2123bfcd62b10097d59bf8fd689ef5c7161031e5871d8396c5": {
|
|
4414
4414
|
functionName: "getChannels_createServerFn_handler",
|
|
4415
|
-
importer: () => import("./api-rpc-
|
|
4415
|
+
importer: () => import("./api-rpc-Cr26KHOK.mjs")
|
|
4416
4416
|
},
|
|
4417
4417
|
"f8bdca3d0579adb812d6404f55d9261a89cdb025e920b1fcad82883646a5fe9e": {
|
|
4418
4418
|
functionName: "getConfigLoaded_createServerFn_handler",
|
|
4419
|
-
importer: () => import("./api-rpc-
|
|
4419
|
+
importer: () => import("./api-rpc-Cr26KHOK.mjs")
|
|
4420
4420
|
},
|
|
4421
4421
|
"00ccacb4a0212c83ec29f4d11719046ad91ea8291cfc557d514dbf00d3bd7f5f": {
|
|
4422
4422
|
functionName: "getBundles_createServerFn_handler",
|
|
4423
|
-
importer: () => import("./api-rpc-
|
|
4423
|
+
importer: () => import("./api-rpc-Cr26KHOK.mjs")
|
|
4424
4424
|
},
|
|
4425
4425
|
"1bd85c2a50e24785cb6abb023a247a9f048f37ddfa85cbb1c57e579563bad013": {
|
|
4426
4426
|
functionName: "getBundle_createServerFn_handler",
|
|
4427
|
-
importer: () => import("./api-rpc-
|
|
4427
|
+
importer: () => import("./api-rpc-Cr26KHOK.mjs")
|
|
4428
4428
|
},
|
|
4429
4429
|
"e000081a14772a0496dfdf615232fbbb1a23b89191d0e32f89a05dd67a1916f7": {
|
|
4430
4430
|
functionName: "getBundleDownloadUrl_createServerFn_handler",
|
|
4431
|
-
importer: () => import("./api-rpc-
|
|
4431
|
+
importer: () => import("./api-rpc-Cr26KHOK.mjs")
|
|
4432
4432
|
},
|
|
4433
4433
|
"67f90ce4cd10fd0226cd9d77cdcd8d0f25a59a6ac406360b655e44296bc4208b": {
|
|
4434
4434
|
functionName: "updateBundle_createServerFn_handler",
|
|
4435
|
-
importer: () => import("./api-rpc-
|
|
4435
|
+
importer: () => import("./api-rpc-Cr26KHOK.mjs")
|
|
4436
4436
|
},
|
|
4437
4437
|
"c4ef3bbb77ea8a4410623fd18a4741e2ff0668b1a97510bcdd032a8428eaa5da": {
|
|
4438
4438
|
functionName: "promoteBundle_createServerFn_handler",
|
|
4439
|
-
importer: () => import("./api-rpc-
|
|
4439
|
+
importer: () => import("./api-rpc-Cr26KHOK.mjs")
|
|
4440
4440
|
},
|
|
4441
4441
|
"16cc7c2f080ea5b73e0c6bba815b110dbd7727796036d248ba0d8ae819ddef08": {
|
|
4442
4442
|
functionName: "createBundle_createServerFn_handler",
|
|
4443
|
-
importer: () => import("./api-rpc-
|
|
4443
|
+
importer: () => import("./api-rpc-Cr26KHOK.mjs")
|
|
4444
4444
|
},
|
|
4445
4445
|
"3a27ff5679228b86a346b3fe42142e7a5bf0264f73173c0dbe5f07fb37c43cf7": {
|
|
4446
4446
|
functionName: "deleteBundle_createServerFn_handler",
|
|
4447
|
-
importer: () => import("./api-rpc-
|
|
4447
|
+
importer: () => import("./api-rpc-Cr26KHOK.mjs")
|
|
4448
4448
|
}
|
|
4449
4449
|
};
|
|
4450
4450
|
async function getServerFnById(id) {
|
|
@@ -4747,7 +4747,7 @@ var entriesPromise;
|
|
|
4747
4747
|
var baseManifestPromise;
|
|
4748
4748
|
var cachedFinalManifestPromise;
|
|
4749
4749
|
async function loadEntries() {
|
|
4750
|
-
const routerEntry = await import("./router-
|
|
4750
|
+
const routerEntry = await import("./router-DB7WR5Zr.mjs");
|
|
4751
4751
|
return {
|
|
4752
4752
|
startEntry: await import("./start-DQK0r85G.mjs"),
|
|
4753
4753
|
routerEntry
|
|
@@ -1,17 +1,17 @@
|
|
|
1
|
-
//#region node_modules/.nitro/vite/services/ssr/assets/_tanstack-start-manifest_v-
|
|
1
|
+
//#region node_modules/.nitro/vite/services/ssr/assets/_tanstack-start-manifest_v-bE9hwtzg.js
|
|
2
2
|
var tsrStartManifest = () => ({
|
|
3
3
|
"routes": {
|
|
4
4
|
"__root__": {
|
|
5
5
|
"filePath": "/home/runner/work/hot-updater/hot-updater/packages/console/src/routes/__root.tsx",
|
|
6
6
|
"children": ["/"],
|
|
7
|
-
"preloads": ["/assets/main-
|
|
7
|
+
"preloads": ["/assets/main-hOHGHX7C.js"]
|
|
8
8
|
},
|
|
9
9
|
"/": {
|
|
10
10
|
"filePath": "/home/runner/work/hot-updater/hot-updater/packages/console/src/routes/index.tsx",
|
|
11
|
-
"preloads": ["/assets/routes-
|
|
11
|
+
"preloads": ["/assets/routes-B2UPnemG.js"]
|
|
12
12
|
}
|
|
13
13
|
},
|
|
14
|
-
"clientEntry": "/assets/main-
|
|
14
|
+
"clientEntry": "/assets/main-hOHGHX7C.js"
|
|
15
15
|
});
|
|
16
16
|
//#endregion
|
|
17
17
|
export { tsrStartManifest };
|