@hot-updater/console 0.29.6 → 0.29.8
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-hOHGHX7C.js → main-D3Zs0SgM.js} +1 -1
- package/.output/public/assets/{routes-B2UPnemG.js → routes-BfmmZvan.js} +2 -2
- package/.output/server/_ssr/{router-DB7WR5Zr.mjs → router-Bh38omGo.mjs} +2 -2
- package/.output/server/_ssr/{routes-FhQwSgxW.mjs → routes-X9PMA9HV.mjs} +214 -144
- package/.output/server/_ssr/ssr.mjs +2 -2
- package/.output/server/{_tanstack-start-manifest_v-bE9hwtzg.mjs → _tanstack-start-manifest_v-B8BW3bbi.mjs} +4 -4
- package/.output/server/index.mjs +30 -30
- package/package.json +6 -6
|
@@ -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-Bh38omGo.js
|
|
12
12
|
var import_jsx_runtime = require_jsx_runtime();
|
|
13
13
|
var import_react = /* @__PURE__ */ __toESM(require_react());
|
|
14
14
|
function HotUpdaterLogo({ className }) {
|
|
@@ -227,7 +227,7 @@ function RootLayout() {
|
|
|
227
227
|
(0, import_react.useEffect)(() => {}, []);
|
|
228
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, {}) })] });
|
|
229
229
|
}
|
|
230
|
-
var $$splitComponentImporter = () => import("./routes-
|
|
230
|
+
var $$splitComponentImporter = () => import("./routes-X9PMA9HV.mjs");
|
|
231
231
|
var rootRouteChildren = { IndexRoute: createFileRoute("/")({
|
|
232
232
|
component: lazyRouteComponent($$splitComponentImporter, "component"),
|
|
233
233
|
validateSearch: (search) => {
|
|
@@ -17,7 +17,7 @@ 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-X9PMA9HV.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());
|
|
@@ -439,7 +439,13 @@ function AlertDialogCancel({ className, variant = "outline", size = "default", .
|
|
|
439
439
|
}
|
|
440
440
|
function DeleteBundleDialog({ bundle, open, onOpenChange, onSuccess }) {
|
|
441
441
|
const deleteBundleMutation = useDeleteBundleMutation();
|
|
442
|
+
const isDeleting = deleteBundleMutation.isPending;
|
|
443
|
+
const handleOpenChange = (nextOpen) => {
|
|
444
|
+
if (!nextOpen && isDeleting) return;
|
|
445
|
+
onOpenChange(nextOpen);
|
|
446
|
+
};
|
|
442
447
|
const handleDelete = async () => {
|
|
448
|
+
if (isDeleting) return;
|
|
443
449
|
try {
|
|
444
450
|
await deleteBundleMutation.mutateAsync({ bundleId: bundle.id });
|
|
445
451
|
toast.success("Bundle deleted successfully");
|
|
@@ -452,37 +458,48 @@ function DeleteBundleDialog({ bundle, open, onOpenChange, onSuccess }) {
|
|
|
452
458
|
};
|
|
453
459
|
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(AlertDialog$1, {
|
|
454
460
|
open,
|
|
455
|
-
onOpenChange,
|
|
456
|
-
children: /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(AlertDialogContent, {
|
|
457
|
-
|
|
458
|
-
|
|
459
|
-
|
|
460
|
-
|
|
461
|
-
|
|
462
|
-
|
|
463
|
-
|
|
464
|
-
|
|
465
|
-
|
|
466
|
-
|
|
467
|
-
|
|
468
|
-
|
|
469
|
-
|
|
470
|
-
|
|
471
|
-
|
|
472
|
-
|
|
473
|
-
|
|
474
|
-
|
|
475
|
-
|
|
476
|
-
|
|
477
|
-
|
|
478
|
-
|
|
479
|
-
|
|
480
|
-
|
|
481
|
-
|
|
482
|
-
|
|
483
|
-
children:
|
|
484
|
-
|
|
485
|
-
|
|
461
|
+
onOpenChange: handleOpenChange,
|
|
462
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(AlertDialogContent, {
|
|
463
|
+
onEscapeKeyDown: (event) => {
|
|
464
|
+
if (isDeleting) event.preventDefault();
|
|
465
|
+
},
|
|
466
|
+
children: [
|
|
467
|
+
/* @__PURE__ */ (0, import_jsx_runtime.jsxs)(AlertDialogHeader, { children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)(AlertDialogTitle, { children: "Are you sure?" }), /* @__PURE__ */ (0, import_jsx_runtime.jsx)(AlertDialogDescription, { children: "This action cannot be undone. This will permanently delete the bundle and remove it from storage." })] }),
|
|
468
|
+
/* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", {
|
|
469
|
+
className: "my-4 p-4 bg-muted rounded-lg",
|
|
470
|
+
children: [
|
|
471
|
+
/* @__PURE__ */ (0, import_jsx_runtime.jsx)("p", {
|
|
472
|
+
className: "text-sm font-medium mb-1",
|
|
473
|
+
children: "Bundle ID:"
|
|
474
|
+
}),
|
|
475
|
+
/* @__PURE__ */ (0, import_jsx_runtime.jsx)("p", {
|
|
476
|
+
className: "text-xs font-mono text-muted-foreground break-all",
|
|
477
|
+
children: bundle.id
|
|
478
|
+
}),
|
|
479
|
+
/* @__PURE__ */ (0, import_jsx_runtime.jsx)("p", {
|
|
480
|
+
className: "text-sm font-medium mt-3 mb-1",
|
|
481
|
+
children: "Channel:"
|
|
482
|
+
}),
|
|
483
|
+
/* @__PURE__ */ (0, import_jsx_runtime.jsx)("p", {
|
|
484
|
+
className: "text-xs text-muted-foreground",
|
|
485
|
+
children: bundle.channel
|
|
486
|
+
})
|
|
487
|
+
]
|
|
488
|
+
}),
|
|
489
|
+
/* @__PURE__ */ (0, import_jsx_runtime.jsxs)(AlertDialogFooter, { children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)(AlertDialogCancel, {
|
|
490
|
+
disabled: isDeleting,
|
|
491
|
+
children: "Cancel"
|
|
492
|
+
}), /* @__PURE__ */ (0, import_jsx_runtime.jsx)(AlertDialogAction, {
|
|
493
|
+
onClick: (event) => {
|
|
494
|
+
event.preventDefault();
|
|
495
|
+
handleDelete();
|
|
496
|
+
},
|
|
497
|
+
className: "bg-destructive text-destructive-foreground hover:bg-destructive/90",
|
|
498
|
+
disabled: isDeleting,
|
|
499
|
+
children: isDeleting ? "Deleting..." : "Delete"
|
|
500
|
+
})] })
|
|
501
|
+
]
|
|
502
|
+
})
|
|
486
503
|
});
|
|
487
504
|
}
|
|
488
505
|
function Dialog$1({ ...props }) {
|
|
@@ -703,18 +720,25 @@ function PromoteChannelDialog({ bundle, open, onOpenChange, onSuccess }) {
|
|
|
703
720
|
const { setBundleId } = useFilterParams();
|
|
704
721
|
const { data: channels = [] } = useChannelsQuery();
|
|
705
722
|
const promoteBundleMutation = usePromoteBundleMutation();
|
|
723
|
+
const isPromoting = promoteBundleMutation.isPending;
|
|
706
724
|
const availableChannels = channels.filter((c) => c !== bundle.channel);
|
|
707
725
|
const isCopy = action === "copy";
|
|
708
726
|
const normalizedTargetChannel = targetChannel.trim();
|
|
709
727
|
const isSameChannel = normalizedTargetChannel === bundle.channel;
|
|
710
728
|
const displayedCopyBundleId = copyBundleId || "Generating bundle ID...";
|
|
729
|
+
const resetDialogState = () => {
|
|
730
|
+
setTargetChannel("");
|
|
731
|
+
setAction("move");
|
|
732
|
+
setCopyBundleId("");
|
|
733
|
+
};
|
|
734
|
+
const closeDialog = () => {
|
|
735
|
+
onOpenChange(false);
|
|
736
|
+
resetDialogState();
|
|
737
|
+
};
|
|
711
738
|
const handleOpenChange = (nextOpen) => {
|
|
739
|
+
if (!nextOpen && isPromoting) return;
|
|
712
740
|
onOpenChange(nextOpen);
|
|
713
|
-
if (!nextOpen)
|
|
714
|
-
setTargetChannel("");
|
|
715
|
-
setAction("move");
|
|
716
|
-
setCopyBundleId("");
|
|
717
|
-
}
|
|
741
|
+
if (!nextOpen) resetDialogState();
|
|
718
742
|
};
|
|
719
743
|
const handleActionChange = (value) => {
|
|
720
744
|
const nextAction = value;
|
|
@@ -746,7 +770,7 @@ function PromoteChannelDialog({ bundle, open, onOpenChange, onSuccess }) {
|
|
|
746
770
|
targetChannel: normalizedTargetChannel
|
|
747
771
|
});
|
|
748
772
|
const promotedBundleId = promotedBundle.id;
|
|
749
|
-
|
|
773
|
+
closeDialog();
|
|
750
774
|
onSuccess?.();
|
|
751
775
|
toast.success(isCopy ? `Bundle copied to ${normalizedTargetChannel}` : `Bundle moved to ${normalizedTargetChannel}`, {
|
|
752
776
|
description: `bundleId: ${promotedBundleId}`,
|
|
@@ -763,108 +787,123 @@ function PromoteChannelDialog({ bundle, open, onOpenChange, onSuccess }) {
|
|
|
763
787
|
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Dialog$1, {
|
|
764
788
|
open,
|
|
765
789
|
onOpenChange: handleOpenChange,
|
|
766
|
-
children: /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(DialogContent, {
|
|
767
|
-
|
|
768
|
-
|
|
769
|
-
|
|
770
|
-
|
|
771
|
-
|
|
772
|
-
|
|
773
|
-
|
|
774
|
-
|
|
775
|
-
|
|
776
|
-
|
|
777
|
-
|
|
778
|
-
|
|
779
|
-
|
|
780
|
-
|
|
781
|
-
|
|
782
|
-
|
|
783
|
-
|
|
784
|
-
|
|
785
|
-
|
|
786
|
-
|
|
787
|
-
|
|
788
|
-
|
|
789
|
-
|
|
790
|
-
|
|
791
|
-
|
|
792
|
-
|
|
793
|
-
|
|
794
|
-
|
|
795
|
-
|
|
796
|
-
|
|
797
|
-
|
|
798
|
-
|
|
799
|
-
|
|
800
|
-
|
|
801
|
-
|
|
802
|
-
|
|
803
|
-
|
|
804
|
-
|
|
805
|
-
|
|
806
|
-
|
|
807
|
-
|
|
808
|
-
|
|
809
|
-
|
|
810
|
-
|
|
811
|
-
|
|
812
|
-
|
|
813
|
-
|
|
814
|
-
|
|
815
|
-
|
|
816
|
-
|
|
817
|
-
|
|
818
|
-
|
|
819
|
-
|
|
820
|
-
|
|
821
|
-
|
|
822
|
-
|
|
823
|
-
|
|
824
|
-
|
|
825
|
-
|
|
826
|
-
|
|
827
|
-
|
|
828
|
-
|
|
829
|
-
|
|
830
|
-
|
|
831
|
-
|
|
832
|
-
|
|
833
|
-
|
|
834
|
-
|
|
835
|
-
|
|
836
|
-
|
|
837
|
-
|
|
838
|
-
|
|
839
|
-
|
|
840
|
-
|
|
841
|
-
|
|
842
|
-
|
|
843
|
-
|
|
844
|
-
|
|
845
|
-
|
|
846
|
-
|
|
847
|
-
|
|
848
|
-
|
|
849
|
-
|
|
850
|
-
|
|
851
|
-
|
|
852
|
-
|
|
853
|
-
|
|
854
|
-
|
|
855
|
-
|
|
856
|
-
|
|
857
|
-
|
|
858
|
-
|
|
859
|
-
|
|
860
|
-
|
|
861
|
-
|
|
862
|
-
|
|
863
|
-
|
|
864
|
-
|
|
865
|
-
|
|
866
|
-
|
|
867
|
-
|
|
790
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(DialogContent, {
|
|
791
|
+
showCloseButton: !isPromoting,
|
|
792
|
+
onEscapeKeyDown: (event) => {
|
|
793
|
+
if (isPromoting) event.preventDefault();
|
|
794
|
+
},
|
|
795
|
+
onInteractOutside: (event) => {
|
|
796
|
+
if (isPromoting) event.preventDefault();
|
|
797
|
+
},
|
|
798
|
+
children: [
|
|
799
|
+
/* @__PURE__ */ (0, import_jsx_runtime.jsxs)(DialogHeader, { children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)(DialogTitle, { children: "Promote to Channel" }), /* @__PURE__ */ (0, import_jsx_runtime.jsx)(DialogDescription, { children: "Choose how to promote this bundle, then select the target channel." })] }),
|
|
800
|
+
/* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", {
|
|
801
|
+
className: "space-y-4 py-4",
|
|
802
|
+
children: [
|
|
803
|
+
/* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", {
|
|
804
|
+
className: "space-y-2",
|
|
805
|
+
children: [
|
|
806
|
+
/* @__PURE__ */ (0, import_jsx_runtime.jsx)(Label$1, {
|
|
807
|
+
htmlFor: "promote-action",
|
|
808
|
+
children: "Action"
|
|
809
|
+
}),
|
|
810
|
+
/* @__PURE__ */ (0, import_jsx_runtime.jsxs)(Select$1, {
|
|
811
|
+
value: action,
|
|
812
|
+
onValueChange: handleActionChange,
|
|
813
|
+
disabled: isPromoting,
|
|
814
|
+
children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)(SelectTrigger, {
|
|
815
|
+
id: "promote-action",
|
|
816
|
+
disabled: isPromoting,
|
|
817
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(SelectValue, { placeholder: "Select an action" })
|
|
818
|
+
}), /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(SelectContent, { children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)(SelectItem, {
|
|
819
|
+
value: "move",
|
|
820
|
+
children: "Move bundle"
|
|
821
|
+
}), /* @__PURE__ */ (0, import_jsx_runtime.jsx)(SelectItem, {
|
|
822
|
+
value: "copy",
|
|
823
|
+
children: "Copy bundle"
|
|
824
|
+
})] })]
|
|
825
|
+
}),
|
|
826
|
+
/* @__PURE__ */ (0, import_jsx_runtime.jsx)("p", {
|
|
827
|
+
className: "text-xs text-muted-foreground",
|
|
828
|
+
children: isCopy ? "Create a new bundle in the target channel and keep the original in the current channel." : "Move the current bundle to the target channel without creating a new bundle ID."
|
|
829
|
+
})
|
|
830
|
+
]
|
|
831
|
+
}),
|
|
832
|
+
isCopy && /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", {
|
|
833
|
+
className: "space-y-2",
|
|
834
|
+
children: [
|
|
835
|
+
/* @__PURE__ */ (0, import_jsx_runtime.jsx)(Label$1, {
|
|
836
|
+
htmlFor: "copy-bundle-id",
|
|
837
|
+
children: "New Bundle ID"
|
|
838
|
+
}),
|
|
839
|
+
/* @__PURE__ */ (0, import_jsx_runtime.jsx)(Input, {
|
|
840
|
+
id: "copy-bundle-id",
|
|
841
|
+
value: displayedCopyBundleId,
|
|
842
|
+
readOnly: true,
|
|
843
|
+
disabled: isPromoting
|
|
844
|
+
}),
|
|
845
|
+
/* @__PURE__ */ (0, import_jsx_runtime.jsx)("p", {
|
|
846
|
+
className: "font-mono text-xs text-muted-foreground",
|
|
847
|
+
children: displayedCopyBundleId
|
|
848
|
+
})
|
|
849
|
+
]
|
|
850
|
+
}),
|
|
851
|
+
/* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", {
|
|
852
|
+
className: "space-y-2",
|
|
853
|
+
children: [
|
|
854
|
+
/* @__PURE__ */ (0, import_jsx_runtime.jsx)(Label$1, {
|
|
855
|
+
htmlFor: "target-channel",
|
|
856
|
+
children: "Target Channel"
|
|
857
|
+
}),
|
|
858
|
+
/* @__PURE__ */ (0, import_jsx_runtime.jsx)(Input, {
|
|
859
|
+
id: "target-channel",
|
|
860
|
+
value: targetChannel,
|
|
861
|
+
onChange: (event) => setTargetChannel(event.target.value),
|
|
862
|
+
placeholder: "Enter a channel name",
|
|
863
|
+
list: "available-channels",
|
|
864
|
+
"aria-invalid": isSameChannel,
|
|
865
|
+
disabled: isPromoting
|
|
866
|
+
}),
|
|
867
|
+
/* @__PURE__ */ (0, import_jsx_runtime.jsx)("datalist", {
|
|
868
|
+
id: "available-channels",
|
|
869
|
+
children: availableChannels.map((channel) => /* @__PURE__ */ (0, import_jsx_runtime.jsx)("option", { value: channel }, channel))
|
|
870
|
+
}),
|
|
871
|
+
availableChannels.length > 0 && /* @__PURE__ */ (0, import_jsx_runtime.jsx)("div", {
|
|
872
|
+
className: "flex flex-wrap gap-2",
|
|
873
|
+
children: availableChannels.map((channel) => /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Button, {
|
|
874
|
+
type: "button",
|
|
875
|
+
variant: "outline",
|
|
876
|
+
size: "xs",
|
|
877
|
+
onClick: () => setTargetChannel(channel),
|
|
878
|
+
disabled: isPromoting,
|
|
879
|
+
children: channel
|
|
880
|
+
}, channel))
|
|
881
|
+
}),
|
|
882
|
+
/* @__PURE__ */ (0, import_jsx_runtime.jsx)("p", {
|
|
883
|
+
className: "text-xs text-muted-foreground",
|
|
884
|
+
children: "Choose an existing channel or enter a new one."
|
|
885
|
+
}),
|
|
886
|
+
isSameChannel && /* @__PURE__ */ (0, import_jsx_runtime.jsx)("p", {
|
|
887
|
+
className: "text-xs text-destructive",
|
|
888
|
+
role: "alert",
|
|
889
|
+
children: "Target channel must be different from the current channel."
|
|
890
|
+
})
|
|
891
|
+
]
|
|
892
|
+
})
|
|
893
|
+
]
|
|
894
|
+
}),
|
|
895
|
+
/* @__PURE__ */ (0, import_jsx_runtime.jsxs)(DialogFooter, { children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)(Button, {
|
|
896
|
+
variant: "outline",
|
|
897
|
+
onClick: () => handleOpenChange(false),
|
|
898
|
+
disabled: isPromoting,
|
|
899
|
+
children: "Cancel"
|
|
900
|
+
}), /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Button, {
|
|
901
|
+
onClick: handlePromote,
|
|
902
|
+
disabled: !normalizedTargetChannel || isCopy && !copyBundleId || isSameChannel || isPromoting,
|
|
903
|
+
children: isPromoting ? isCopy ? "Copying..." : "Moving..." : isCopy ? "Copy" : "Move"
|
|
904
|
+
})] })
|
|
905
|
+
]
|
|
906
|
+
})
|
|
868
907
|
});
|
|
869
908
|
}
|
|
870
909
|
function Card({ className, ...props }) {
|
|
@@ -1008,7 +1047,7 @@ function getDefaultValues(bundle) {
|
|
|
1008
1047
|
};
|
|
1009
1048
|
}
|
|
1010
1049
|
var formatRolloutPercentage = (rolloutCohortCount) => (rolloutCohortCount / 10).toFixed(1);
|
|
1011
|
-
function BundleEditorForm({ bundle, onClose }) {
|
|
1050
|
+
function BundleEditorForm({ bundle, onClose, onBusyChange }) {
|
|
1012
1051
|
const bundleDownloadUrlMutation = useBundleDownloadUrlMutation();
|
|
1013
1052
|
const updateBundleMutation = useUpdateBundleMutation();
|
|
1014
1053
|
const [showPromoteDialog, setShowPromoteDialog] = (0, import_react.useState)(false);
|
|
@@ -1060,6 +1099,14 @@ function BundleEditorForm({ bundle, onClose }) {
|
|
|
1060
1099
|
};
|
|
1061
1100
|
const hasTargetAppVersionError = Boolean(targetAppVersionValidation.error);
|
|
1062
1101
|
const isDownloading = bundleDownloadUrlMutation.isPending;
|
|
1102
|
+
(0, import_react.useEffect)(() => {
|
|
1103
|
+
onBusyChange?.(isSaving);
|
|
1104
|
+
}, [isSaving, onBusyChange]);
|
|
1105
|
+
(0, import_react.useEffect)(() => {
|
|
1106
|
+
return () => {
|
|
1107
|
+
onBusyChange?.(false);
|
|
1108
|
+
};
|
|
1109
|
+
}, [onBusyChange]);
|
|
1063
1110
|
const handleAddCohort = () => {
|
|
1064
1111
|
const normalizedCohort = normalizeCohortValue(newCohort);
|
|
1065
1112
|
if (!normalizedCohort) return;
|
|
@@ -1302,6 +1349,7 @@ function BundleEditorForm({ bundle, onClose }) {
|
|
|
1302
1349
|
size: "sm",
|
|
1303
1350
|
className: "w-full",
|
|
1304
1351
|
onClick: () => setShowPromoteDialog(true),
|
|
1352
|
+
disabled: isSaving,
|
|
1305
1353
|
children: "Promote to Channel"
|
|
1306
1354
|
}),
|
|
1307
1355
|
/* @__PURE__ */ (0, import_jsx_runtime.jsxs)(Button, {
|
|
@@ -1309,7 +1357,7 @@ function BundleEditorForm({ bundle, onClose }) {
|
|
|
1309
1357
|
size: "sm",
|
|
1310
1358
|
className: "w-full",
|
|
1311
1359
|
onClick: handleDownloadBundle,
|
|
1312
|
-
disabled: isDownloading,
|
|
1360
|
+
disabled: isSaving || isDownloading,
|
|
1313
1361
|
children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)(Download, { className: "h-4 w-4" }), isDownloading ? "Preparing Download..." : "Download Bundle"]
|
|
1314
1362
|
}),
|
|
1315
1363
|
/* @__PURE__ */ (0, import_jsx_runtime.jsx)(Button, {
|
|
@@ -1317,6 +1365,7 @@ function BundleEditorForm({ bundle, onClose }) {
|
|
|
1317
1365
|
size: "sm",
|
|
1318
1366
|
className: "w-full",
|
|
1319
1367
|
onClick: () => setShowDeleteDialog(true),
|
|
1368
|
+
disabled: isSaving,
|
|
1320
1369
|
children: "Delete Bundle"
|
|
1321
1370
|
})
|
|
1322
1371
|
]
|
|
@@ -1421,11 +1470,31 @@ function BundleMetadata({ bundle }) {
|
|
|
1421
1470
|
})] });
|
|
1422
1471
|
}
|
|
1423
1472
|
function BundleEditorSheet({ bundleId, bundle, loading = false, open, onOpenChange }) {
|
|
1473
|
+
const [isSaving, setIsSaving] = (0, import_react.useState)(false);
|
|
1474
|
+
(0, import_react.useEffect)(() => {
|
|
1475
|
+
if (!open) setIsSaving(false);
|
|
1476
|
+
}, [open]);
|
|
1477
|
+
const handleOpenChange = (nextOpen) => {
|
|
1478
|
+
if (!nextOpen && isSaving) return;
|
|
1479
|
+
if (!nextOpen) setIsSaving(false);
|
|
1480
|
+
onOpenChange(nextOpen);
|
|
1481
|
+
};
|
|
1482
|
+
const closeSheet = () => {
|
|
1483
|
+
setIsSaving(false);
|
|
1484
|
+
onOpenChange(false);
|
|
1485
|
+
};
|
|
1424
1486
|
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Sheet, {
|
|
1425
1487
|
open,
|
|
1426
|
-
onOpenChange,
|
|
1488
|
+
onOpenChange: handleOpenChange,
|
|
1427
1489
|
children: /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(SheetContent, {
|
|
1428
1490
|
className: "w-[600px] sm:max-w-[600px] overflow-y-auto",
|
|
1491
|
+
showCloseButton: !isSaving,
|
|
1492
|
+
onEscapeKeyDown: (event) => {
|
|
1493
|
+
if (isSaving) event.preventDefault();
|
|
1494
|
+
},
|
|
1495
|
+
onInteractOutside: (event) => {
|
|
1496
|
+
if (isSaving) event.preventDefault();
|
|
1497
|
+
},
|
|
1429
1498
|
children: [/* @__PURE__ */ (0, import_jsx_runtime.jsxs)(SheetHeader, { children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)(SheetTitle, { children: bundle ? "Edit Bundle" : "Bundle Details" }), /* @__PURE__ */ (0, import_jsx_runtime.jsx)(SheetDescription, { children: bundle ? /* @__PURE__ */ (0, import_jsx_runtime.jsx)(BundleBasicInfo, { bundle }) : loading ? bundleId ? /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("span", {
|
|
1430
1499
|
className: "font-mono text-xs",
|
|
1431
1500
|
children: ["Loading ", bundleId]
|
|
@@ -1436,7 +1505,8 @@ function BundleEditorSheet({ bundleId, bundle, loading = false, open, onOpenChan
|
|
|
1436
1505
|
className: "px-6 pb-6 space-y-6",
|
|
1437
1506
|
children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)(BundleEditorForm, {
|
|
1438
1507
|
bundle,
|
|
1439
|
-
onClose:
|
|
1508
|
+
onClose: closeSheet,
|
|
1509
|
+
onBusyChange: setIsSaving
|
|
1440
1510
|
}, bundle.id), /* @__PURE__ */ (0, import_jsx_runtime.jsx)(BundleMetadata, { bundle })]
|
|
1441
1511
|
}) : loading ? /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", {
|
|
1442
1512
|
className: "px-6 pb-6 space-y-4",
|
|
@@ -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-B8BW3bbi.mjs");
|
|
4273
4273
|
const startManifest = tsrStartManifest();
|
|
4274
4274
|
const rootRoute = startManifest.routes[rootRouteId] = startManifest.routes["__root__"] || {};
|
|
4275
4275
|
rootRoute.assets = rootRoute.assets || [];
|
|
@@ -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-Bh38omGo.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-B8BW3bbi.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-D3Zs0SgM.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-BfmmZvan.js"]
|
|
12
12
|
}
|
|
13
13
|
},
|
|
14
|
-
"clientEntry": "/assets/main-
|
|
14
|
+
"clientEntry": "/assets/main-D3Zs0SgM.js"
|
|
15
15
|
});
|
|
16
16
|
//#endregion
|
|
17
17
|
export { tsrStartManifest };
|