@seliseblocks/genesis-os 4.3.6 → 4.3.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/dist/{chunk-VQWYNAO5.cjs → chunk-4QN4CYSC.cjs} +10 -7
- package/dist/chunk-4QN4CYSC.cjs.map +1 -0
- package/dist/{chunk-OJG2XE7Z.cjs → chunk-IJMKS4XG.cjs} +6 -6
- package/dist/{chunk-OJG2XE7Z.cjs.map → chunk-IJMKS4XG.cjs.map} +1 -1
- package/dist/{chunk-PKRBEIHK.js → chunk-JITR3QYC.js} +10 -7
- package/dist/chunk-JITR3QYC.js.map +1 -0
- package/dist/{chunk-SKKVJAXT.js → chunk-LNQUCEQU.js} +44 -7
- package/dist/chunk-LNQUCEQU.js.map +1 -0
- package/dist/{chunk-SHCA37CD.cjs → chunk-OVQEP63V.cjs} +215 -115
- package/dist/chunk-OVQEP63V.cjs.map +1 -0
- package/dist/{chunk-Y36F6N2O.js → chunk-PSJHGD3M.js} +156 -56
- package/dist/chunk-PSJHGD3M.js.map +1 -0
- package/dist/{chunk-JDWJ2HXQ.cjs → chunk-QN6HLQ67.cjs} +45 -8
- package/dist/chunk-QN6HLQ67.cjs.map +1 -0
- package/dist/{chunk-OAWBQY5W.js → chunk-XRAO7JBH.js} +3 -3
- package/dist/{chunk-OAWBQY5W.js.map → chunk-XRAO7JBH.js.map} +1 -1
- package/dist/components/index.cjs +351 -351
- package/dist/components/index.js +4 -4
- package/dist/guards/index.cjs +10 -10
- package/dist/guards/index.js +4 -4
- package/dist/hooks/index.cjs +54 -54
- package/dist/hooks/index.d.cts +3 -3
- package/dist/hooks/index.d.ts +3 -3
- package/dist/hooks/index.js +2 -2
- package/dist/index.cjs +431 -431
- package/dist/index.d.cts +2 -2
- package/dist/index.d.ts +2 -2
- package/dist/index.js +4 -4
- package/dist/layouts/index.cjs +11 -11
- package/dist/layouts/index.js +4 -4
- package/dist/models/index.d.cts +1 -1
- package/dist/models/index.d.ts +1 -1
- package/dist/pages/index.cjs +9 -9
- package/dist/pages/index.js +4 -4
- package/dist/providers/index.cjs +6 -6
- package/dist/providers/index.js +2 -2
- package/dist/{service-registry.model-pcv_ix2e.d.cts → service-registry.model-DJGsTRWZ.d.cts} +17 -1
- package/dist/{service-registry.model-pcv_ix2e.d.ts → service-registry.model-DJGsTRWZ.d.ts} +17 -1
- package/dist/store/index.cjs +7 -7
- package/dist/store/index.d.cts +16 -6
- package/dist/store/index.d.ts +16 -6
- package/dist/store/index.js +1 -1
- package/package.json +1 -1
- package/dist/chunk-JDWJ2HXQ.cjs.map +0 -1
- package/dist/chunk-PKRBEIHK.js.map +0 -1
- package/dist/chunk-SHCA37CD.cjs.map +0 -1
- package/dist/chunk-SKKVJAXT.js.map +0 -1
- package/dist/chunk-VQWYNAO5.cjs.map +0 -1
- package/dist/chunk-Y36F6N2O.js.map +0 -1
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
import { refractor } from './chunk-FGY7QM3Y.js';
|
|
2
|
-
import { useKeyboardShortcut, usePopoverWidth, useBlocksAppConfigStore, useTheme, useLogout, useGetMyOrganizations, useLanguageSwitcher, useGetBlocksNotificationConfig, notificationService, useLogo, useStartImpersonation, useGetProjects, useGetProject, useImpersonationStatusChecker, useStopImpersonation, useLogin, useSignUpAffordance, useSignUpRedirect, useInitiateRedirect, useGetEnvRepositories, useUpdateTenantGroup, useIcon, useDisableProject, projectService, initiateService, useGetNotifications, useMarkAsRead, useMarkAllAsRead, useDebouncedFuseFilter, useUpdateRepositories, usePrefetchRedirect } from './chunk-
|
|
2
|
+
import { useKeyboardShortcut, usePopoverWidth, useBlocksAppConfigStore, useTheme, useLogout, useGetMyOrganizations, useLanguageSwitcher, useGetBlocksNotificationConfig, notificationService, useLogo, useStartImpersonation, useGetProjects, useGetProject, useImpersonationStatusChecker, useStopImpersonation, useLogin, useSignUpAffordance, useSignUpRedirect, useInitiateRedirect, useGetEnvRepositories, useUpdateTenantGroup, useIcon, useDisableProject, projectService, initiateService, useGetNotifications, useMarkAsRead, useMarkAllAsRead, useDebouncedFuseFilter, useUpdateRepositories, usePrefetchRedirect } from './chunk-LNQUCEQU.js';
|
|
3
3
|
import { showErrorToast, createStorage, getForwardedToPath, debounce, formatFullDate, formatDate, deepEqual, showSuccessToast, isErrorWithErrors, getServiceBaseUrl, getServiceSwaggerUrl } from './chunk-JSXAKNHQ.js';
|
|
4
|
-
import { fadeTransition, fadeInUp, staggerContainer, staggerItem, fadeInScale,
|
|
4
|
+
import { fadeTransition, fadeInUp, staggerContainer, staggerItem, fadeInScale, readCurrentOwner, TAB_ID, subscribeToTenantClaims, iamClient, AUTH_ENDPOINTS, claimTenant, PROFILE_ENDPOINTS } from './chunk-46ZGVJEX.js';
|
|
5
5
|
import { getRuntimeEnv, HttpError } from './chunk-JUVLHPQI.js';
|
|
6
|
-
import { defaultRightSidePanelContextValue, RightSidePanelContext, SidebarContext, DashboardLayoutProvider } from './chunk-
|
|
6
|
+
import { defaultRightSidePanelContextValue, RightSidePanelContext, SidebarContext, DashboardLayoutProvider } from './chunk-XRAO7JBH.js';
|
|
7
7
|
import { useIsMobile, useIsActiveMenu, useFilteredMenus } from './chunk-AHCHUUXM.js';
|
|
8
8
|
import { cn } from './chunk-3MLPBMH2.js';
|
|
9
9
|
import { getQueryClient } from './chunk-BRHE44FE.js';
|
|
10
|
-
import { useLayoutSettingsStore, useLanguageViewStore, useImpersonateStore, useUserStore } from './chunk-
|
|
10
|
+
import { useLayoutSettingsStore, useLanguageViewStore, useImpersonateStore, useUserStore } from './chunk-JITR3QYC.js';
|
|
11
11
|
import { CookieStorage, useProjectStore, useAuthStore } from './chunk-4UHGGHI6.js';
|
|
12
12
|
import { __commonJS, __toESM } from './chunk-PL4HS6R6.js';
|
|
13
13
|
import * as React8 from 'react';
|
|
@@ -7797,6 +7797,7 @@ var AppLoadingSpinner = ({ size = 64 }) => /* @__PURE__ */ jsxs(Fragment, { chil
|
|
|
7797
7797
|
` }),
|
|
7798
7798
|
/* @__PURE__ */ jsx("div", { className: "bg-background fixed inset-0 z-50 flex items-center justify-center", children: /* @__PURE__ */ jsx("div", { className: "animate-breathe", children: /* @__PURE__ */ jsx(BlocksIcon, { size }) }) })
|
|
7799
7799
|
] });
|
|
7800
|
+
var projectNameFor = (projects, tenantId) => tenantId && projects.find((p) => p.tenantId === tenantId)?.name || null;
|
|
7800
7801
|
var ImpersonationChecker = ({
|
|
7801
7802
|
children
|
|
7802
7803
|
}) => {
|
|
@@ -7814,55 +7815,108 @@ var ImpersonationChecker = ({
|
|
|
7814
7815
|
if (isLoading || !isSuccess || !isInitialized) return null;
|
|
7815
7816
|
return /* @__PURE__ */ jsx(Fragment, { children });
|
|
7816
7817
|
};
|
|
7818
|
+
function ImpersonationBlocked({
|
|
7819
|
+
title,
|
|
7820
|
+
description,
|
|
7821
|
+
primaryLabel,
|
|
7822
|
+
onPrimary,
|
|
7823
|
+
consolePath
|
|
7824
|
+
}) {
|
|
7825
|
+
const navigate = useNavigate();
|
|
7826
|
+
return /* @__PURE__ */ jsxs("div", { className: "flex h-full min-h-[320px] w-full flex-col items-center justify-center gap-4 p-8 text-center", children: [
|
|
7827
|
+
/* @__PURE__ */ jsxs("div", { className: "flex flex-col gap-1", children: [
|
|
7828
|
+
/* @__PURE__ */ jsx("h2", { className: "text-base font-semibold", children: title }),
|
|
7829
|
+
/* @__PURE__ */ jsx("p", { className: "max-w-md text-sm text-muted-foreground", children: description })
|
|
7830
|
+
] }),
|
|
7831
|
+
/* @__PURE__ */ jsxs("div", { className: "flex flex-row items-center gap-2", children: [
|
|
7832
|
+
primaryLabel && onPrimary && /* @__PURE__ */ jsx(Button, { onClick: onPrimary, children: primaryLabel }),
|
|
7833
|
+
consolePath && /* @__PURE__ */ jsx(
|
|
7834
|
+
Button,
|
|
7835
|
+
{
|
|
7836
|
+
variant: primaryLabel && onPrimary ? "outline" : "default",
|
|
7837
|
+
onClick: () => navigate(consolePath),
|
|
7838
|
+
children: "Go to console"
|
|
7839
|
+
}
|
|
7840
|
+
)
|
|
7841
|
+
] })
|
|
7842
|
+
] });
|
|
7843
|
+
}
|
|
7844
|
+
function ImpersonationWaiting({ label }) {
|
|
7845
|
+
return /* @__PURE__ */ jsxs("div", { className: "flex h-full min-h-[320px] w-full flex-col items-center justify-center gap-3", children: [
|
|
7846
|
+
/* @__PURE__ */ jsx(AppLoadingSpinner, {}),
|
|
7847
|
+
/* @__PURE__ */ jsx("p", { className: "text-sm text-muted-foreground", children: label })
|
|
7848
|
+
] });
|
|
7849
|
+
}
|
|
7817
7850
|
function ImpersonationTerminator({
|
|
7818
7851
|
children
|
|
7819
7852
|
}) {
|
|
7820
|
-
const {
|
|
7853
|
+
const {
|
|
7854
|
+
terminate,
|
|
7855
|
+
isImpersonated,
|
|
7856
|
+
detachedReason,
|
|
7857
|
+
detachedTenantId,
|
|
7858
|
+
setDetached
|
|
7859
|
+
} = useImpersonateStore();
|
|
7821
7860
|
const { mutateAsync } = useStopImpersonation();
|
|
7861
|
+
const { projects } = useProjectStore();
|
|
7822
7862
|
const isTriggering = useRef(false);
|
|
7823
7863
|
const [isTerminating, setIsTerminating] = useState(false);
|
|
7864
|
+
const rootTenantId = window.process?.env.BLOCKS_X_BLOCKS_KEY || "";
|
|
7865
|
+
useEffect(() => {
|
|
7866
|
+
if (!rootTenantId) return;
|
|
7867
|
+
const owner = readCurrentOwner();
|
|
7868
|
+
if (owner && owner.tabId !== TAB_ID && owner.tenantId !== rootTenantId) {
|
|
7869
|
+
setDetached("another-project", owner.tenantId);
|
|
7870
|
+
}
|
|
7871
|
+
return subscribeToTenantClaims((claim) => {
|
|
7872
|
+
if (claim.tenantId === rootTenantId) {
|
|
7873
|
+
setDetached(null);
|
|
7874
|
+
return;
|
|
7875
|
+
}
|
|
7876
|
+
setDetached("another-project", claim.tenantId);
|
|
7877
|
+
});
|
|
7878
|
+
}, [rootTenantId, setDetached]);
|
|
7824
7879
|
useEffect(() => {
|
|
7825
7880
|
if (isTriggering.current || !isImpersonated) return;
|
|
7881
|
+
if (detachedReason) return;
|
|
7826
7882
|
isTriggering.current = true;
|
|
7827
7883
|
setIsTerminating(true);
|
|
7828
|
-
const blocksKey = window.process?.env.BLOCKS_X_BLOCKS_KEY || "";
|
|
7829
7884
|
const stopImpersonation = async () => {
|
|
7885
|
+
let sessionIsRootScoped = false;
|
|
7830
7886
|
try {
|
|
7831
7887
|
await mutateAsync(void 0);
|
|
7888
|
+
sessionIsRootScoped = true;
|
|
7832
7889
|
} catch (error) {
|
|
7833
7890
|
if (!(error instanceof HttpError) || error.status !== 401) {
|
|
7834
7891
|
console.error("Error stopping impersonation:", error);
|
|
7835
7892
|
}
|
|
7893
|
+
sessionIsRootScoped = error instanceof HttpError && error.status === 401;
|
|
7836
7894
|
} finally {
|
|
7837
|
-
terminate(
|
|
7895
|
+
terminate(rootTenantId);
|
|
7896
|
+
if (sessionIsRootScoped && rootTenantId) claimTenant(rootTenantId);
|
|
7838
7897
|
isTriggering.current = false;
|
|
7839
7898
|
setIsTerminating(false);
|
|
7840
7899
|
}
|
|
7841
7900
|
};
|
|
7842
7901
|
void stopImpersonation();
|
|
7843
|
-
}, [mutateAsync, terminate, isImpersonated]);
|
|
7844
|
-
if (
|
|
7902
|
+
}, [mutateAsync, terminate, isImpersonated, detachedReason, rootTenantId]);
|
|
7903
|
+
if (detachedReason) {
|
|
7904
|
+
const name = projectNameFor(projects, detachedTenantId);
|
|
7905
|
+
return /* @__PURE__ */ jsx(
|
|
7906
|
+
ImpersonationBlocked,
|
|
7907
|
+
{
|
|
7908
|
+
title: name ? `Your session is in ${name}` : "Your session is in a project",
|
|
7909
|
+
description: "The project is open in another window. A session can only be in one place at a time.",
|
|
7910
|
+
primaryLabel: name ? `Leave ${name}` : "Leave the project",
|
|
7911
|
+
onPrimary: () => setDetached(null)
|
|
7912
|
+
}
|
|
7913
|
+
);
|
|
7914
|
+
}
|
|
7915
|
+
if (isImpersonated || isTerminating) {
|
|
7916
|
+
return /* @__PURE__ */ jsx(ImpersonationWaiting, { label: "Returning to the console\u2026" });
|
|
7917
|
+
}
|
|
7845
7918
|
return /* @__PURE__ */ jsx(Fragment, { children });
|
|
7846
7919
|
}
|
|
7847
|
-
function ImpersonationBlocked({
|
|
7848
|
-
title,
|
|
7849
|
-
description,
|
|
7850
|
-
actionLabel,
|
|
7851
|
-
onAction,
|
|
7852
|
-
consolePath
|
|
7853
|
-
}) {
|
|
7854
|
-
const navigate = useNavigate();
|
|
7855
|
-
return /* @__PURE__ */ jsxs("div", { className: "flex h-full min-h-[320px] w-full flex-col items-center justify-center gap-4 p-8 text-center", children: [
|
|
7856
|
-
/* @__PURE__ */ jsxs("div", { className: "flex flex-col gap-1", children: [
|
|
7857
|
-
/* @__PURE__ */ jsx("h2", { className: "text-base font-semibold", children: title }),
|
|
7858
|
-
/* @__PURE__ */ jsx("p", { className: "max-w-md text-sm text-muted-foreground", children: description })
|
|
7859
|
-
] }),
|
|
7860
|
-
/* @__PURE__ */ jsxs("div", { className: "flex flex-row items-center gap-2", children: [
|
|
7861
|
-
/* @__PURE__ */ jsx(Button, { onClick: onAction, children: actionLabel }),
|
|
7862
|
-
/* @__PURE__ */ jsx(Button, { variant: "outline", onClick: () => navigate(consolePath), children: "Back to console" })
|
|
7863
|
-
] })
|
|
7864
|
-
] });
|
|
7865
|
-
}
|
|
7866
7920
|
function ImpersonationSynchronizer({
|
|
7867
7921
|
children,
|
|
7868
7922
|
consolePath = "/app/console"
|
|
@@ -7872,7 +7926,8 @@ function ImpersonationSynchronizer({
|
|
|
7872
7926
|
isImpersonated,
|
|
7873
7927
|
impersonatedTenantId,
|
|
7874
7928
|
impersonationError,
|
|
7875
|
-
|
|
7929
|
+
detachedReason,
|
|
7930
|
+
detachedTenantId,
|
|
7876
7931
|
setImpersonationError,
|
|
7877
7932
|
setDetached
|
|
7878
7933
|
} = useImpersonateStore();
|
|
@@ -7882,6 +7937,7 @@ function ImpersonationSynchronizer({
|
|
|
7882
7937
|
const isTriggering = useRef(false);
|
|
7883
7938
|
const [isImpersonating, setIsImpersonating] = useState(false);
|
|
7884
7939
|
const { itemId } = useParams();
|
|
7940
|
+
const rootTenantId = window.process?.env.BLOCKS_X_BLOCKS_KEY || "";
|
|
7885
7941
|
const routeTenantId = useMemo(() => {
|
|
7886
7942
|
if (!itemId) return null;
|
|
7887
7943
|
return projects.find((p) => p.itemId === itemId)?.tenantId ?? null;
|
|
@@ -7935,11 +7991,7 @@ function ImpersonationSynchronizer({
|
|
|
7935
7991
|
return;
|
|
7936
7992
|
}
|
|
7937
7993
|
await mutateAsync({ targeted_tenant_id: targetTenantId });
|
|
7938
|
-
impersonate(
|
|
7939
|
-
targetTenantId,
|
|
7940
|
-
window.process?.env.BLOCKS_X_BLOCKS_KEY || ""
|
|
7941
|
-
);
|
|
7942
|
-
claimTenant(targetTenantId);
|
|
7994
|
+
impersonate(targetTenantId, rootTenantId);
|
|
7943
7995
|
const project = knownProjects.find((p) => p.tenantId === targetTenantId);
|
|
7944
7996
|
if (project) {
|
|
7945
7997
|
setSelectedProject(project);
|
|
@@ -7954,30 +8006,41 @@ function ImpersonationSynchronizer({
|
|
|
7954
8006
|
}, [
|
|
7955
8007
|
mutateAsync,
|
|
7956
8008
|
impersonate,
|
|
8009
|
+
rootTenantId,
|
|
7957
8010
|
setSelectedProject,
|
|
7958
8011
|
setTenantGroup,
|
|
7959
8012
|
setImpersonationError
|
|
7960
8013
|
]);
|
|
7961
|
-
const
|
|
8014
|
+
const takeSession = useCallback(() => {
|
|
7962
8015
|
setImpersonationError(null);
|
|
7963
|
-
setDetached(
|
|
8016
|
+
setDetached(null);
|
|
7964
8017
|
void runImpersonation();
|
|
7965
8018
|
}, [runImpersonation, setImpersonationError, setDetached]);
|
|
7966
8019
|
useEffect(() => {
|
|
7967
8020
|
const owner = readCurrentOwner();
|
|
7968
|
-
if (owner && routeTenantId && owner.tenantId !== routeTenantId) {
|
|
7969
|
-
setDetached(
|
|
8021
|
+
if (owner && owner.tabId !== TAB_ID && routeTenantId && owner.tenantId !== routeTenantId) {
|
|
8022
|
+
setDetached(
|
|
8023
|
+
owner.tenantId === rootTenantId ? "console" : "another-project",
|
|
8024
|
+
owner.tenantId
|
|
8025
|
+
);
|
|
7970
8026
|
}
|
|
7971
8027
|
return subscribeToTenantClaims((claim) => {
|
|
7972
8028
|
const mine = routeTenantIdRef.current;
|
|
7973
8029
|
if (!mine) return;
|
|
7974
|
-
|
|
8030
|
+
if (claim.tenantId === mine) {
|
|
8031
|
+
setDetached(null);
|
|
8032
|
+
return;
|
|
8033
|
+
}
|
|
8034
|
+
setDetached(
|
|
8035
|
+
claim.tenantId === rootTenantId ? "console" : "another-project",
|
|
8036
|
+
claim.tenantId
|
|
8037
|
+
);
|
|
7975
8038
|
});
|
|
7976
|
-
}, [routeTenantId, setDetached]);
|
|
8039
|
+
}, [routeTenantId, rootTenantId, setDetached]);
|
|
7977
8040
|
useEffect(() => {
|
|
7978
8041
|
if (!itemId) return;
|
|
7979
8042
|
if (isTriggering.current) return;
|
|
7980
|
-
if (impersonationError ||
|
|
8043
|
+
if (impersonationError || detachedReason) return;
|
|
7981
8044
|
const needsColdStart = !routeTenantId && !!impersonatedTenantId && !selectedProject;
|
|
7982
8045
|
const needsRetarget = !!routeTenantId && routeTenantId !== impersonatedTenantId;
|
|
7983
8046
|
if (!needsColdStart && !needsRetarget) return;
|
|
@@ -7988,40 +8051,77 @@ function ImpersonationSynchronizer({
|
|
|
7988
8051
|
impersonatedTenantId,
|
|
7989
8052
|
selectedProject,
|
|
7990
8053
|
impersonationError,
|
|
7991
|
-
|
|
8054
|
+
detachedReason,
|
|
7992
8055
|
runImpersonation
|
|
7993
8056
|
]);
|
|
7994
|
-
|
|
8057
|
+
const thisProjectName = projectNameFor(projects, routeTenantId);
|
|
8058
|
+
if (isImpersonating) {
|
|
8059
|
+
return /* @__PURE__ */ jsx(
|
|
8060
|
+
ImpersonationWaiting,
|
|
8061
|
+
{
|
|
8062
|
+
label: thisProjectName ? `Opening ${thisProjectName}\u2026` : "Opening project\u2026"
|
|
8063
|
+
}
|
|
8064
|
+
);
|
|
8065
|
+
}
|
|
7995
8066
|
if (!itemId) {
|
|
7996
8067
|
if (!isImpersonated || isTriggering.current) return null;
|
|
7997
8068
|
return /* @__PURE__ */ jsx(Fragment, { children });
|
|
7998
8069
|
}
|
|
7999
8070
|
if (impersonationError) {
|
|
8071
|
+
const accessDenied = impersonationError instanceof HttpError && impersonationError.status === 403;
|
|
8072
|
+
return accessDenied ? /* @__PURE__ */ jsx(
|
|
8073
|
+
ImpersonationBlocked,
|
|
8074
|
+
{
|
|
8075
|
+
title: thisProjectName ? `You don't have access to ${thisProjectName}` : "You don't have access to this project",
|
|
8076
|
+
description: "Your access to this project may have been removed. Pick another project from the console.",
|
|
8077
|
+
consolePath
|
|
8078
|
+
}
|
|
8079
|
+
) : /* @__PURE__ */ jsx(
|
|
8080
|
+
ImpersonationBlocked,
|
|
8081
|
+
{
|
|
8082
|
+
title: thisProjectName ? `Couldn't open ${thisProjectName}` : "Couldn't open this project",
|
|
8083
|
+
description: "Something went wrong switching to this project. Try again, or pick a different one from the console.",
|
|
8084
|
+
primaryLabel: "Try again",
|
|
8085
|
+
onPrimary: takeSession,
|
|
8086
|
+
consolePath
|
|
8087
|
+
}
|
|
8088
|
+
);
|
|
8089
|
+
}
|
|
8090
|
+
if (detachedReason === "console") {
|
|
8000
8091
|
return /* @__PURE__ */ jsx(
|
|
8001
8092
|
ImpersonationBlocked,
|
|
8002
8093
|
{
|
|
8003
|
-
title: "
|
|
8004
|
-
description:
|
|
8005
|
-
|
|
8006
|
-
|
|
8094
|
+
title: "Your session returned to the console",
|
|
8095
|
+
description: thisProjectName ? `You went back to the console in another window, so ${thisProjectName} is no longer open here.` : "You went back to the console in another window, so this project is no longer open here.",
|
|
8096
|
+
primaryLabel: thisProjectName ? `Reopen ${thisProjectName}` : "Reopen this project",
|
|
8097
|
+
onPrimary: takeSession,
|
|
8007
8098
|
consolePath
|
|
8008
8099
|
}
|
|
8009
8100
|
);
|
|
8010
8101
|
}
|
|
8011
|
-
if (
|
|
8102
|
+
if (detachedReason === "another-project") {
|
|
8103
|
+
const otherName = projectNameFor(projects, detachedTenantId);
|
|
8012
8104
|
return /* @__PURE__ */ jsx(
|
|
8013
8105
|
ImpersonationBlocked,
|
|
8014
8106
|
{
|
|
8015
|
-
title: "
|
|
8016
|
-
description:
|
|
8017
|
-
|
|
8018
|
-
|
|
8107
|
+
title: "Another project is open in this browser",
|
|
8108
|
+
description: otherName ? `Your session moved to ${otherName} in another window. A session can only be in one project at a time.` : "Your session moved to another project in a different window. A session can only be in one project at a time.",
|
|
8109
|
+
primaryLabel: thisProjectName ? `Continue in ${thisProjectName}` : "Continue in this project",
|
|
8110
|
+
onPrimary: takeSession,
|
|
8019
8111
|
consolePath
|
|
8020
8112
|
}
|
|
8021
8113
|
);
|
|
8022
8114
|
}
|
|
8023
|
-
if (!routeTenantId)
|
|
8024
|
-
|
|
8115
|
+
if (!routeTenantId)
|
|
8116
|
+
return /* @__PURE__ */ jsx(ImpersonationWaiting, { label: "Loading your projects\u2026" });
|
|
8117
|
+
if (routeTenantId !== impersonatedTenantId) {
|
|
8118
|
+
return /* @__PURE__ */ jsx(
|
|
8119
|
+
ImpersonationWaiting,
|
|
8120
|
+
{
|
|
8121
|
+
label: thisProjectName ? `Switching to ${thisProjectName}\u2026` : "Switching projects\u2026"
|
|
8122
|
+
}
|
|
8123
|
+
);
|
|
8124
|
+
}
|
|
8025
8125
|
return /* @__PURE__ */ jsx(Fragment, { children });
|
|
8026
8126
|
}
|
|
8027
8127
|
function PublicLayout({ children }) {
|
|
@@ -13227,5 +13327,5 @@ var TablePagination2 = React8.forwardRef(
|
|
|
13227
13327
|
TablePagination2.displayName = "TablePagination";
|
|
13228
13328
|
|
|
13229
13329
|
export { Accordion, AccordionContent, AccordionItem, AccordionTrigger, Alert, AlertDescription, AlertDialog, AlertDialogAction, AlertDialogCancel, AlertDialogContent, AlertDialogDescription, AlertDialogFooter, AlertDialogHeader, AlertDialogOverlay, AlertDialogPortal, AlertDialogTitle, AlertDialogTrigger, AlertTitle, AppLoadingSpinner, AppSwitcher, ArchiveProject, AspectRatio, AuthLayout, AuthResolver, Avatar, AvatarFallback, AvatarImage, BackToConsoleNavigator, Badge, Breadcrumb, BreadcrumbEllipsis, BreadcrumbItem, BreadcrumbLink, BreadcrumbList, BreadcrumbPage, BreadcrumbSeparator, Button, Calendar, CallbackPage, Card, CardContent, CardDescription, CardFooter, CardHeader, CardTitle, Carousel, CarouselContent, CarouselItem, CarouselNext, CarouselPrevious, ChartContainer, ChartLegend, ChartLegendContent, ChartStyle, ChartTooltip, ChartTooltipContent, Checkbox, Collapsible, CollapsibleContent2 as CollapsibleContent, CollapsibleTrigger2 as CollapsibleTrigger, Command, CommandDialog, CommandEmpty, CommandGroup, CommandInput, CommandItem, CommandList, CommandSeparator, CommandShortcut, ConfirmationModal, ConsoleHeader, ConsoleLayout, ConsolePage, ContextMenu, ContextMenuCheckboxItem, ContextMenuContent, ContextMenuGroup, ContextMenuItem, ContextMenuLabel, ContextMenuPortal, ContextMenuRadioGroup, ContextMenuRadioItem, ContextMenuSeparator, ContextMenuShortcut, ContextMenuSub, ContextMenuSubContent, ContextMenuSubTrigger, ContextMenuTrigger, CopyToClipboardButton, CopyableSnippet, DEFAULT_KANBAN_COLUMNS, DashboardHeader, DashboardLayout, DashboardOverview, DashboardRoute, DashboardSectionCard, DataTable, DataTableHeaderCell, DateRangePicker, DesktopMenuItem, Dialog, DialogClose, DialogContent, DialogDescription, DialogFooter, DialogHeader, DialogOverlay, DialogPortal, DialogTitle, DialogTrigger, Drawer, DrawerClose, DrawerContent, DrawerDescription, DrawerFooter, DrawerHeader, DrawerOverlay, DrawerPortal, DrawerTitle, DrawerTrigger, DropdownMenu, DropdownMenuCheckboxItem, DropdownMenuContent, DropdownMenuGroup, DropdownMenuItem, DropdownMenuLabel, DropdownMenuPortal, DropdownMenuRadioGroup, DropdownMenuRadioItem, DropdownMenuSeparator, DropdownMenuShortcut, DropdownMenuSub, DropdownMenuSubContent, DropdownMenuSubTrigger, DropdownMenuTrigger, EditProject, EditProjectDialog, EditProjectForm, EnvironmentCard, EnvironmentList, ErrorBoundary, ErrorDisplay, ErrorDisplayWithCard, FileInput, FileUploader, FileUploaderContent, FileUploaderItem, FilterControls, FilterToolBarMobileView, FilterToolbar, Form, FormControl, FormDescription, FormField, FormItem, FormLabel, FormMessage, HoverCard, HoverCardContent, HoverCardTrigger, ImpersonationChecker, ImpersonationSynchronizer, ImpersonationTerminator, ImportFileModalContent, InfiniteScroll, InfiniteScroller, InfoTooltip, Input, InputOTP, InputOTPGroup, InputOTPSeparator, InputOTPSlot, KanbanBoard, KanbanBoardColumn, KanbanBoardContainer, KanbanTaskCard, Label, LanguageSelector, LoadingButton, LoginPage, Logo, MaskedText, Menubar, MenubarCheckboxItem, MenubarContent, MenubarGroup, MenubarItem, MenubarLabel, MenubarMenu, MenubarPortal, MenubarRadioGroup, MenubarRadioItem, MenubarSeparator, MenubarShortcut, MenubarSub, MenubarSubContent, MenubarSubTrigger, MenubarTrigger, MobileMenuItem, MultiSelect, NavigationMenu, NavigationMenuContent, NavigationMenuIndicator, NavigationMenuItem, NavigationMenuLink, NavigationMenuList, NavigationMenuTrigger, NavigationMenuViewport, Notification, OidcLayout, Pagination, PaginationContent, PaginationEllipsis, PaginationItem, PaginationLink, PaginationNext, PaginationPrevious, PasswordInput, Popover, PopoverContent, PopoverTrigger, ProfilePage, Progress, ProjectActions, ProjectCardLoadingSkeleton, ProjectDetail, ProjectList2 as ProjectList, ProjectListRowLoadingSkeleton, ProjectOverview, ProjectRepoList, ProtectedGuard, PublicGuard, PublicLayout, RadioGroup4 as RadioGroup, RadioGroupItem, RenderAlternatively, RenderConditionally, ResizableHandle, ResizablePanel, ResizablePanelGroup, RightSidePanel, RightSidePanelBody, RightSidePanelClose, RightSidePanelDescription, RightSidePanelFooter, RightSidePanelHeader, RightSidePanelProvider, RightSidePanelTitle, RightSidePanelTrigger, ScrollArea, ScrollBar, Select, SelectContent, SelectGroup, SelectItem, SelectLabel, SelectScrollDownButton, SelectScrollUpButton, SelectSeparator, SelectTrigger, SelectValue, SelectedEnvironment, SelectedProject, Separator, Sheet, SheetClose, SheetContent, SheetDescription, SheetFooter, SheetHeader, SheetOverlay, SheetPortal, SheetTitle, SheetTrigger, Sidebar, SidebarCollapsedTooltip, SidebarContent, SidebarFooter, SidebarGroup, SidebarGroupAction, SidebarGroupContent, SidebarGroupLabel, SidebarHeader, SidebarInput, SidebarInset, SidebarMenu, SidebarMenuAction, SidebarMenuBadge, SidebarMenuButton, SidebarMenuDesktop, SidebarMenuItem, SidebarMenuSkeleton, SidebarMenuSub, SidebarMenuSubButton, SidebarMenuSubItem, SidebarMobileView, SidebarProvider, SidebarRail, SidebarSeparator, SidebarTrigger, Skeleton, Slider, Spinner, Stepper, Switch, Table, TableBody, TableCaption, TableCell, TableFooter, TableHead, TableHeader, TableLoadingSkeleton, TablePagination2 as TablePagination, TableRow, Tabs, TabsContent, TabsList, TabsTrigger, Textarea, ThemeSwitcher, Timeline, Toggle, ToggleGroup, ToggleGroupItem, Tooltip, TooltipContent, TooltipProvider, TooltipTrigger, UserDropdownMenu, WizardHorizontalTrackBar, WizardStepContent, WizardStepIndicator, WizardStepViewport, WizardStepperProvider, WizardVerticalTrackBar, badgeVariants, buttonVariants, editProjectFormDefaultValues, editProjectFormSchema, filteredAppSwitcherData, hasDraggableData, kanbanKeyboardCoordinateGetter, navigationMenuTriggerStyle, paginationQueryParsers, sidebarCollapsedTooltipClass, sortQueryParsers, spinnerVariants, toggleVariants, useFileUpload, useFormField, useNotificationSocket, useOidcContext, usePaginationQueryParams, useRightSidePanel, useSortQueryParams, useWizardStepper };
|
|
13230
|
-
//# sourceMappingURL=chunk-
|
|
13231
|
-
//# sourceMappingURL=chunk-
|
|
13330
|
+
//# sourceMappingURL=chunk-PSJHGD3M.js.map
|
|
13331
|
+
//# sourceMappingURL=chunk-PSJHGD3M.js.map
|