@cobaltcore-dev/aurora 2.0.0 → 2.1.0
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/dist/client/ContentHeader-fKKZVu-o.mjs +116 -0
- package/dist/client/ContentHeader-fKKZVu-o.mjs.map +1 -0
- package/dist/client/{DeleteFlavorModal-C2MqUgGR.mjs → DeleteFlavorModal-Be2GFiB_.mjs} +3 -2
- package/dist/client/DeleteFlavorModal-Be2GFiB_.mjs.map +1 -0
- package/dist/client/{RouteIdLevelDefaultError-CSseJ1yG.mjs → RouteIdLevelDefaultError-DPF_x2tG.mjs} +9 -9
- package/dist/client/RouteIdLevelDefaultError-DPF_x2tG.mjs.map +1 -0
- package/dist/client/StorageNotFound-B-zVinVD.mjs +30 -0
- package/dist/client/StorageNotFound-B-zVinVD.mjs.map +1 -0
- package/dist/client/{_flavorId-DYv_StX22.mjs → _flavorId-0PioWpEp.mjs} +4 -4
- package/dist/client/_flavorId-0PioWpEp.mjs.map +1 -0
- package/dist/client/{_flavorId-YV3jCS5g.mjs → _flavorId-B7fp6Nk8.mjs} +3 -3
- package/dist/client/{_flavorId-YV3jCS5g.mjs.map → _flavorId-B7fp6Nk8.mjs.map} +1 -1
- package/dist/client/{_flavorId-CaA4-Pnf.mjs → _flavorId-CgueqKTs.mjs} +3 -3
- package/dist/client/{_flavorId-CaA4-Pnf.mjs.map → _flavorId-CgueqKTs.mjs.map} +1 -1
- package/dist/client/{_floatingIpId-Dpsc7GU4.mjs → _floatingIpId-B8r64AL9.mjs} +3 -3
- package/dist/client/{_floatingIpId-Dpsc7GU4.mjs.map → _floatingIpId-B8r64AL9.mjs.map} +1 -1
- package/dist/client/{_floatingIpId-BeYElanB.mjs → _floatingIpId-lEobpOER.mjs} +2 -2
- package/dist/client/{_floatingIpId-BeYElanB.mjs.map → _floatingIpId-lEobpOER.mjs.map} +1 -1
- package/dist/client/{_imageId-pBSS0YcC.mjs → _imageId-Ccv8PedW.mjs} +3 -3
- package/dist/client/{_imageId-pBSS0YcC.mjs.map → _imageId-Ccv8PedW.mjs.map} +1 -1
- package/dist/client/_imageId-CiqEQB_J.mjs +558 -0
- package/dist/client/{_imageId-mfKp3JHn.mjs.map → _imageId-CiqEQB_J.mjs.map} +1 -1
- package/dist/client/{_imageId-mpXUMCh_.mjs → _imageId-D9LR-02T.mjs} +3 -3
- package/dist/client/{_imageId-mpXUMCh_.mjs.map → _imageId-D9LR-02T.mjs.map} +1 -1
- package/dist/client/{_projectId-BnTBxKfp.mjs → _projectId-BDARsteX.mjs} +3 -3
- package/dist/client/{_projectId-BnTBxKfp.mjs.map → _projectId-BDARsteX.mjs.map} +1 -1
- package/dist/client/{_projectId-CVrdJ52s.mjs → _projectId-CtyAHqhH.mjs} +2 -2
- package/dist/client/{_projectId-CVrdJ52s.mjs.map → _projectId-CtyAHqhH.mjs.map} +1 -1
- package/dist/client/_projectId-D3VOH5lN.mjs +94 -0
- package/dist/client/_projectId-D3VOH5lN.mjs.map +1 -0
- package/dist/client/{_projectId-AjgJX6Gl.mjs → _projectId-ZBk6vka0.mjs} +83 -81
- package/dist/client/_projectId-ZBk6vka0.mjs.map +1 -0
- package/dist/client/{_securityGroupId-AO3wnH8g.mjs → _securityGroupId-BwgZnoiR.mjs} +2 -2
- package/dist/client/{_securityGroupId-AO3wnH8g.mjs.map → _securityGroupId-BwgZnoiR.mjs.map} +1 -1
- package/dist/client/{_securityGroupId-Bq0ZyG6z.mjs → _securityGroupId-Cz2NUHdB.mjs} +3 -3
- package/dist/client/{_securityGroupId-Bq0ZyG6z.mjs.map → _securityGroupId-Cz2NUHdB.mjs.map} +1 -1
- package/dist/client/{_storageType-CzZ4u9x_.mjs → _storageType-BNpP1A2N.mjs} +3 -2
- package/dist/client/_storageType-BNpP1A2N.mjs.map +1 -0
- package/dist/client/_storageType-BxSGKhAI.mjs +15 -0
- package/dist/client/_storageType-BxSGKhAI.mjs.map +1 -0
- package/dist/client/_storageType-DZYCmiLt.mjs +30 -0
- package/dist/client/_storageType-DZYCmiLt.mjs.map +1 -0
- package/dist/client/{_storageType-c-DAu8qr.mjs → _storageType-UqAMP-8d.mjs} +286 -285
- package/dist/client/_storageType-UqAMP-8d.mjs.map +1 -0
- package/dist/client/_storageType-u51_7OwJ.mjs +7 -0
- package/dist/client/_storageType-u51_7OwJ.mjs.map +1 -0
- package/dist/client/components/Errors/RouteIdLevelDefaultError.d.ts +2 -1
- package/dist/client/{flavors-ZudiAiTU.mjs → flavors-Ce3J-cFa.mjs} +2 -2
- package/dist/client/{flavors-ZudiAiTU.mjs.map → flavors-Ce3J-cFa.mjs.map} +1 -1
- package/dist/client/{flavors-Bgq3KZmx.mjs → flavors-D5ThLaXO.mjs} +84 -77
- package/dist/client/flavors-D5ThLaXO.mjs.map +1 -0
- package/dist/client/{floatingips-B1oLH8z6.mjs → floatingips-DXnRlLvV.mjs} +2 -2
- package/dist/client/{floatingips-B1oLH8z6.mjs.map → floatingips-DXnRlLvV.mjs.map} +1 -1
- package/dist/client/{floatingips-BtLg3yEQ.mjs → floatingips-HRbuLxiN.mjs} +3 -3
- package/dist/client/{floatingips-BtLg3yEQ.mjs.map → floatingips-HRbuLxiN.mjs.map} +1 -1
- package/dist/client/{floatingips-BeQEkVH8.mjs → floatingips-nN1kQmsu.mjs} +2 -2
- package/dist/client/{floatingips-BeQEkVH8.mjs.map → floatingips-nN1kQmsu.mjs.map} +1 -1
- package/dist/client/{images-CnTW3bpy.mjs → images-C8M3ysWR.mjs} +3 -3
- package/dist/client/{images-CnTW3bpy.mjs.map → images-C8M3ysWR.mjs.map} +1 -1
- package/dist/client/{images-DZHDYDQu.mjs → images-Cf5R28NR.mjs} +2 -2
- package/dist/client/{images-DZHDYDQu.mjs.map → images-Cf5R28NR.mjs.map} +1 -1
- package/dist/client/index.js +198 -197
- package/dist/client/index.js.map +1 -1
- package/dist/client/{objects-jYQBFzwg.mjs → objects-BudUAfWY.mjs} +4265 -4275
- package/dist/client/objects-BudUAfWY.mjs.map +1 -0
- package/dist/client/objects-Dc7sKUr8.mjs +67 -0
- package/dist/client/objects-Dc7sKUr8.mjs.map +1 -0
- package/dist/client/objects-Dw7oeTq2.mjs +80 -0
- package/dist/client/objects-Dw7oeTq2.mjs.map +1 -0
- package/dist/client/objects-_g7nGIn5.mjs +25 -0
- package/dist/client/objects-_g7nGIn5.mjs.map +1 -0
- package/dist/client/objects-eBxvY6_n.mjs +78 -0
- package/dist/client/objects-eBxvY6_n.mjs.map +1 -0
- package/dist/client/projects-yiK0HGSA.mjs.map +1 -1
- package/dist/client/{securitygroups-BRndk7wh.mjs → securitygroups-67fFxiwt.mjs} +2 -2
- package/dist/client/{securitygroups-BRndk7wh.mjs.map → securitygroups-67fFxiwt.mjs.map} +1 -1
- package/dist/client/{securitygroups--0PS2wbM.mjs → securitygroups-DXrfyuVF.mjs} +3 -3
- package/dist/client/{securitygroups--0PS2wbM.mjs.map → securitygroups-DXrfyuVF.mjs.map} +1 -1
- package/dist/client/{securitygroups-Cs2Op-tu.mjs → securitygroups-WLB1_IM6.mjs} +3 -3
- package/dist/client/{securitygroups-Cs2Op-tu.mjs.map → securitygroups-WLB1_IM6.mjs.map} +1 -1
- package/dist/client/{securitygroups-CdN4yAAw.mjs → securitygroups-o0IXZM6S.mjs} +2 -2
- package/dist/client/{securitygroups-CdN4yAAw.mjs.map → securitygroups-o0IXZM6S.mjs.map} +1 -1
- package/dist/client/serviceCatalog-B3lKWC9V.mjs +6 -0
- package/dist/client/serviceCatalog-B3lKWC9V.mjs.map +1 -0
- package/dist/client/storageProviders-CJ5rOh13.mjs +15 -0
- package/dist/client/storageProviders-CJ5rOh13.mjs.map +1 -0
- package/dist/client/trpcClient.d.ts +96 -3
- package/dist/client/utils/serviceCatalog.d.ts +9 -0
- package/dist/client/utils/storageProviders.d.ts +44 -0
- package/dist/server/index.d.ts +96 -3
- package/dist/server/index.js +1224 -387
- package/package.json +1 -1
- package/dist/client/ContentHeader-CPJbgYWn.mjs +0 -115
- package/dist/client/ContentHeader-CPJbgYWn.mjs.map +0 -1
- package/dist/client/DeleteFlavorModal-C2MqUgGR.mjs.map +0 -1
- package/dist/client/RouteIdLevelDefaultError-CSseJ1yG.mjs.map +0 -1
- package/dist/client/_flavorId-DYv_StX22.mjs.map +0 -1
- package/dist/client/_imageId-mfKp3JHn.mjs +0 -558
- package/dist/client/_projectId-AjgJX6Gl.mjs.map +0 -1
- package/dist/client/_projectId-DgciZslU.mjs +0 -92
- package/dist/client/_projectId-DgciZslU.mjs.map +0 -1
- package/dist/client/_storageType-BRWWJtow.mjs +0 -14
- package/dist/client/_storageType-BRWWJtow.mjs.map +0 -1
- package/dist/client/_storageType-CzZ4u9x_.mjs.map +0 -1
- package/dist/client/_storageType-c-DAu8qr.mjs.map +0 -1
- package/dist/client/_storageType-zeSZe--V.mjs +0 -7
- package/dist/client/_storageType-zeSZe--V.mjs.map +0 -1
- package/dist/client/flavors-Bgq3KZmx.mjs.map +0 -1
- package/dist/client/objects-25xsh4Ia.mjs +0 -66
- package/dist/client/objects-25xsh4Ia.mjs.map +0 -1
- package/dist/client/objects-KXY6dgwq.mjs +0 -82
- package/dist/client/objects-KXY6dgwq.mjs.map +0 -1
- package/dist/client/objects-QryuClU3.mjs +0 -82
- package/dist/client/objects-QryuClU3.mjs.map +0 -1
- package/dist/client/objects-jYQBFzwg.mjs.map +0 -1
|
@@ -4,9 +4,10 @@ var n = e("/_auth/projects/$projectId/storage/$provider/$storageType")({
|
|
|
4
4
|
section: "storage",
|
|
5
5
|
service: "containers"
|
|
6
6
|
},
|
|
7
|
-
component: t(() => import("./_storageType-
|
|
7
|
+
component: t(() => import("./_storageType-BxSGKhAI.mjs"), "component"),
|
|
8
|
+
notFoundComponent: t(() => import("./_storageType-DZYCmiLt.mjs"), "notFoundComponent")
|
|
8
9
|
});
|
|
9
10
|
//#endregion
|
|
10
11
|
export { n as t };
|
|
11
12
|
|
|
12
|
-
//# sourceMappingURL=_storageType-
|
|
13
|
+
//# sourceMappingURL=_storageType-BNpP1A2N.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"_storageType-BNpP1A2N.mjs","names":["createFileRoute","Route","staticData","section","service","RouteInfo","component","lazyRouteComponent","$$splitComponentImporter","notFoundComponent","$$splitNotFoundComponentImporter"],"sources":["../../src/client/routes/_auth/projects/$projectId/storage/$provider/$storageType.tsx"],"sourcesContent":["import { createFileRoute, Outlet, useNavigate, useParams } from \"@tanstack/react-router\"\nimport { Button } from \"@cloudoperators/juno-ui-components\"\nimport { useLingui } from \"@lingui/react/macro\"\nimport type { RouteInfo } from \"@/client/routes/routeInfo\"\nimport { useSetBreadcrumb } from \"@/client/hooks/useSetBreadcrumb\"\nimport { RouteIdLevelDefaultError } from \"@/client/components/Errors/RouteIdLevelDefaultError\"\nimport { STORAGE_PROVIDER, isStorageProvider, storageTypeFor } from \"@/client/utils/storageProviders\"\n\n/**\n * Catches any address under `/storage/$provider/$storageType/` that matches no route —\n * `.../demo-bucket-1/object` (mistyped tail) or `.../demo-bucket-1` (truncated link).\n *\n * Without it these fall through to the router's global `defaultNotFoundComponent`, which\n * knows nothing about storage and offers only the project overview — a long way back from\n * a URL that is one segment away from correct.\n *\n * The exit is the provider's list. A button straight to the container the URL names was\n * tried and dropped: the name is unmatched path here rather than a validated route param\n * (there is no `$containerName` route, only the `$containerName/objects` leaf), so it would\n * have been a guess that could land on a second 404 — and the list is one click from the\n * container anyway.\n */\nfunction StorageTypeNotFound() {\n const { t } = useLingui()\n const navigate = useNavigate()\n const { projectId, provider } = useParams({ strict: false })\n\n const listProvider = isStorageProvider(provider) ? provider : undefined\n\n return (\n <RouteIdLevelDefaultError\n errorTitle={t`Page Not Found`}\n errorDescription={t`This address is not valid for this object storage service.`}\n action={\n projectId && listProvider ? (\n <Button\n variant=\"primary\"\n onClick={() =>\n navigate({\n to: \"/projects/$projectId/storage/$provider/$storageType\",\n params: { projectId, provider: listProvider, storageType: storageTypeFor(listProvider) },\n })\n }\n >\n {listProvider === STORAGE_PROVIDER.CEPH ? t`Back to Buckets` : t`Back to Containers`}\n </Button>\n ) : undefined\n }\n />\n )\n}\n\nexport const Route = createFileRoute(\"/_auth/projects/$projectId/storage/$provider/$storageType\")({\n staticData: {\n section: \"storage\",\n service: \"containers\",\n } satisfies RouteInfo,\n component: StorageTypeLayout,\n notFoundComponent: StorageTypeNotFound,\n})\n\nfunction StorageTypeLayout() {\n const { t } = useLingui()\n const { provider } = Route.useParams()\n const label = isStorageProvider(provider)\n ? provider === STORAGE_PROVIDER.SWIFT\n ? t`Object Storage (Swift)`\n : t`Object Storage (Ceph)`\n : t`Storage`\n useSetBreadcrumb(Route.id, label)\n return <Outlet />\n}\n"],"mappings":";AAoDA,IAAaC,IAAQD,EAAgB,2DAAA,CAAA,CAA6D;CAChGE,YAAY;EACVC,SAAS;EACTC,SAAS;CACX;CACAE,WAASC,+CAAA,WAAA;CACTE,mBAAiBF,+CAAA,mBAAA;AACnB,CAAA"}
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import { t as e } from "./_storageType-BNpP1A2N.mjs";
|
|
2
|
+
import { i as t, t as n } from "./storageProviders-CJ5rOh13.mjs";
|
|
3
|
+
import { t as r } from "./useSetBreadcrumb-tn7lBaQV.mjs";
|
|
4
|
+
import { jsx as i } from "react/jsx-runtime";
|
|
5
|
+
import { Outlet as a } from "@tanstack/react-router";
|
|
6
|
+
import { useLingui as o } from "@lingui/react";
|
|
7
|
+
//#region src/client/routes/_auth/projects/$projectId/storage/$provider/$storageType.tsx?tsr-split=component
|
|
8
|
+
function s() {
|
|
9
|
+
let { i18n: s, _: c } = o(), { provider: l } = e.useParams(), u = t(l) ? l === n.SWIFT ? s._({ id: "+OEi73" }) : s._({ id: "KhNDX4" }) : s._({ id: "BrrIs8" });
|
|
10
|
+
return r(e.id, u), /*#__PURE__*/ i(a, {});
|
|
11
|
+
}
|
|
12
|
+
//#endregion
|
|
13
|
+
export { s as component };
|
|
14
|
+
|
|
15
|
+
//# sourceMappingURL=_storageType-BxSGKhAI.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"_storageType-BxSGKhAI.mjs","names":["Outlet","useLingui","useSetBreadcrumb","STORAGE_PROVIDER","isStorageProvider","Route","StorageTypeLayout","t","provider","useParams","label","SWIFT","id","component"],"sources":["../../src/client/routes/_auth/projects/$projectId/storage/$provider/$storageType.tsx?tsr-split=component"],"sourcesContent":["import { createFileRoute, Outlet, useNavigate, useParams } from \"@tanstack/react-router\"\nimport { Button } from \"@cloudoperators/juno-ui-components\"\nimport { useLingui } from \"@lingui/react/macro\"\nimport type { RouteInfo } from \"@/client/routes/routeInfo\"\nimport { useSetBreadcrumb } from \"@/client/hooks/useSetBreadcrumb\"\nimport { RouteIdLevelDefaultError } from \"@/client/components/Errors/RouteIdLevelDefaultError\"\nimport { STORAGE_PROVIDER, isStorageProvider, storageTypeFor } from \"@/client/utils/storageProviders\"\n\n/**\n * Catches any address under `/storage/$provider/$storageType/` that matches no route —\n * `.../demo-bucket-1/object` (mistyped tail) or `.../demo-bucket-1` (truncated link).\n *\n * Without it these fall through to the router's global `defaultNotFoundComponent`, which\n * knows nothing about storage and offers only the project overview — a long way back from\n * a URL that is one segment away from correct.\n *\n * The exit is the provider's list. A button straight to the container the URL names was\n * tried and dropped: the name is unmatched path here rather than a validated route param\n * (there is no `$containerName` route, only the `$containerName/objects` leaf), so it would\n * have been a guess that could land on a second 404 — and the list is one click from the\n * container anyway.\n */\nfunction StorageTypeNotFound() {\n const { t } = useLingui()\n const navigate = useNavigate()\n const { projectId, provider } = useParams({ strict: false })\n\n const listProvider = isStorageProvider(provider) ? provider : undefined\n\n return (\n <RouteIdLevelDefaultError\n errorTitle={t`Page Not Found`}\n errorDescription={t`This address is not valid for this object storage service.`}\n action={\n projectId && listProvider ? (\n <Button\n variant=\"primary\"\n onClick={() =>\n navigate({\n to: \"/projects/$projectId/storage/$provider/$storageType\",\n params: { projectId, provider: listProvider, storageType: storageTypeFor(listProvider) },\n })\n }\n >\n {listProvider === STORAGE_PROVIDER.CEPH ? t`Back to Buckets` : t`Back to Containers`}\n </Button>\n ) : undefined\n }\n />\n )\n}\n\nexport const Route = createFileRoute(\"/_auth/projects/$projectId/storage/$provider/$storageType\")({\n staticData: {\n section: \"storage\",\n service: \"containers\",\n } satisfies RouteInfo,\n component: StorageTypeLayout,\n notFoundComponent: StorageTypeNotFound,\n})\n\nfunction StorageTypeLayout() {\n const { t } = useLingui()\n const { provider } = Route.useParams()\n const label = isStorageProvider(provider)\n ? provider === STORAGE_PROVIDER.SWIFT\n ? t`Object Storage (Swift)`\n : t`Object Storage (Ceph)`\n : t`Storage`\n useSetBreadcrumb(Route.id, label)\n return <Outlet />\n}\n"],"mappings":";;;;;;;AA6DA,SAASM,IAAAA;CACP,IAAM,EAAA,MAAA,GAAA,GAAA,MAAQL,EAAAA,GACR,EAAEO,gBAAaH,EAAMI,UAAS,GAC9BC,IAAQN,EAAkBI,CAAAA,IAC5BA,MAAaL,EAAiBQ,QAC5BJ,EAAAA,EAAC,EAAA,IAAA,SAAA,CAAA,IACDA,EAAAA,EAAC,EAAA,IAAA,SAAA,CAAA,IACHA,EAAAA,EAAC,EAAA,IAAA,SAAA,CAAA;CAEL,OADAL,EAAiBG,EAAMO,IAAIF,CAAAA,GACpB,gBAAC,GAAA,CAAA,CAAA;AACV"}
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
import { i as e } from "./build-WuxXRAqf.mjs";
|
|
2
|
+
import { a as t, i as n, t as r } from "./storageProviders-CJ5rOh13.mjs";
|
|
3
|
+
import { t as i } from "./RouteIdLevelDefaultError-DPF_x2tG.mjs";
|
|
4
|
+
import { jsx as a } from "react/jsx-runtime";
|
|
5
|
+
import { useNavigate as o, useParams as s } from "@tanstack/react-router";
|
|
6
|
+
import { useLingui as c } from "@lingui/react";
|
|
7
|
+
//#region src/client/routes/_auth/projects/$projectId/storage/$provider/$storageType.tsx?tsr-split=notFoundComponent
|
|
8
|
+
function l() {
|
|
9
|
+
let { i18n: l, _: u } = c(), d = o(), { projectId: f, provider: p } = s({ strict: !1 }), m = n(p) ? p : void 0;
|
|
10
|
+
return /*#__PURE__*/ a(i, {
|
|
11
|
+
errorTitle: l._({ id: "boJlGf" }),
|
|
12
|
+
errorDescription: l._({ id: "cyMmud" }),
|
|
13
|
+
action: f && m ? /*#__PURE__*/ a(e, {
|
|
14
|
+
variant: "primary",
|
|
15
|
+
onClick: () => d({
|
|
16
|
+
to: "/projects/$projectId/storage/$provider/$storageType",
|
|
17
|
+
params: {
|
|
18
|
+
projectId: f,
|
|
19
|
+
provider: m,
|
|
20
|
+
storageType: t(m)
|
|
21
|
+
}
|
|
22
|
+
}),
|
|
23
|
+
children: m === r.CEPH ? l._({ id: "Rzahyj" }) : l._({ id: "6nrGLS" })
|
|
24
|
+
}) : void 0
|
|
25
|
+
});
|
|
26
|
+
}
|
|
27
|
+
//#endregion
|
|
28
|
+
export { l as notFoundComponent };
|
|
29
|
+
|
|
30
|
+
//# sourceMappingURL=_storageType-DZYCmiLt.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"_storageType-DZYCmiLt.mjs","names":["useNavigate","useParams","Button","useLingui","RouteIdLevelDefaultError","STORAGE_PROVIDER","isStorageProvider","storageTypeFor","StorageTypeNotFound","t","navigate","projectId","provider","strict","listProvider","undefined","to","params","storageType","CEPH","notFoundComponent"],"sources":["../../src/client/routes/_auth/projects/$projectId/storage/$provider/$storageType.tsx?tsr-split=notFoundComponent"],"sourcesContent":["import { createFileRoute, Outlet, useNavigate, useParams } from \"@tanstack/react-router\"\nimport { Button } from \"@cloudoperators/juno-ui-components\"\nimport { useLingui } from \"@lingui/react/macro\"\nimport type { RouteInfo } from \"@/client/routes/routeInfo\"\nimport { useSetBreadcrumb } from \"@/client/hooks/useSetBreadcrumb\"\nimport { RouteIdLevelDefaultError } from \"@/client/components/Errors/RouteIdLevelDefaultError\"\nimport { STORAGE_PROVIDER, isStorageProvider, storageTypeFor } from \"@/client/utils/storageProviders\"\n\n/**\n * Catches any address under `/storage/$provider/$storageType/` that matches no route —\n * `.../demo-bucket-1/object` (mistyped tail) or `.../demo-bucket-1` (truncated link).\n *\n * Without it these fall through to the router's global `defaultNotFoundComponent`, which\n * knows nothing about storage and offers only the project overview — a long way back from\n * a URL that is one segment away from correct.\n *\n * The exit is the provider's list. A button straight to the container the URL names was\n * tried and dropped: the name is unmatched path here rather than a validated route param\n * (there is no `$containerName` route, only the `$containerName/objects` leaf), so it would\n * have been a guess that could land on a second 404 — and the list is one click from the\n * container anyway.\n */\nfunction StorageTypeNotFound() {\n const { t } = useLingui()\n const navigate = useNavigate()\n const { projectId, provider } = useParams({ strict: false })\n\n const listProvider = isStorageProvider(provider) ? provider : undefined\n\n return (\n <RouteIdLevelDefaultError\n errorTitle={t`Page Not Found`}\n errorDescription={t`This address is not valid for this object storage service.`}\n action={\n projectId && listProvider ? (\n <Button\n variant=\"primary\"\n onClick={() =>\n navigate({\n to: \"/projects/$projectId/storage/$provider/$storageType\",\n params: { projectId, provider: listProvider, storageType: storageTypeFor(listProvider) },\n })\n }\n >\n {listProvider === STORAGE_PROVIDER.CEPH ? t`Back to Buckets` : t`Back to Containers`}\n </Button>\n ) : undefined\n }\n />\n )\n}\n\nexport const Route = createFileRoute(\"/_auth/projects/$projectId/storage/$provider/$storageType\")({\n staticData: {\n section: \"storage\",\n service: \"containers\",\n } satisfies RouteInfo,\n component: StorageTypeLayout,\n notFoundComponent: StorageTypeNotFound,\n})\n\nfunction StorageTypeLayout() {\n const { t } = useLingui()\n const { provider } = Route.useParams()\n const label = isStorageProvider(provider)\n ? provider === STORAGE_PROVIDER.SWIFT\n ? t`Object Storage (Swift)`\n : t`Object Storage (Ceph)`\n : t`Storage`\n useSetBreadcrumb(Route.id, label)\n return <Outlet />\n}\n"],"mappings":";;;;;;;AAsBA,SAASQ,IAAAA;CACP,IAAM,EAAA,MAAA,GAAA,GAAA,MAAQL,EAAAA,GACRO,IAAWV,EAAAA,GACX,EAAEW,cAAWC,gBAAaX,EAAU,EAAEY,QAAQ,GAAM,CAAA,GAEpDC,IAAeR,EAAkBM,CAAAA,IAAYA,IAAWG,KAAAA;CAE9D,OACE,gBAAC,GAAA;EACC,YAAYN,EAAAA,EAAC,EAAA,IAAA,SAAA,CAAA;EACb,kBAAkBA,EAAAA,EAAC,EAAA,IAAA,SAAA,CAAA;EACnB,QACEE,KAAaG,IACX,gBAAC,GAAA;GACC,SAAQ;GACR,eACEJ,EAAS;IACPM,IAAI;IACJC,QAAQ;KAAEN;KAAWC,UAAUE;KAAcI,aAAaX,EAAeO,CAAAA;IAAc;GACzF,CAAA;GAGDA,UAAAA,MAAiBT,EAAiBc,OAAOV,EAAAA,EAAC,EAAA,IAAA,SAAA,CAAA,IAAoBA,EAAAA,EAAC,EAAA,IAAA,SAAA,CAAA;EAEhEM,CAAAA,IAAAA,KAAAA;;AAIZ"}
|