forked from baron/baron-sso
local 브런치 code-check 오류 수정
This commit is contained in:
@@ -46,10 +46,9 @@ function AppLayout() {
|
||||
const isMockRoleEnabled =
|
||||
isDevRoleOverrideEnabled &&
|
||||
window.localStorage.getItem("X-Mock-Role-Enabled") === "true";
|
||||
const mockRoleOverride =
|
||||
isMockRoleEnabled
|
||||
? window.localStorage.getItem("X-Mock-Role")
|
||||
: null;
|
||||
const mockRoleOverride = isMockRoleEnabled
|
||||
? window.localStorage.getItem("X-Mock-Role")
|
||||
: null;
|
||||
const [theme, setTheme] = useState<"light" | "dark">(() => {
|
||||
const stored = window.localStorage.getItem("admin_theme");
|
||||
return stored === "dark" ? "dark" : "light";
|
||||
@@ -337,10 +336,7 @@ function AppLayout() {
|
||||
const handleSessionExpiryToggle = () => {
|
||||
setIsSessionExpiryEnabled((prev) => {
|
||||
const next = !prev;
|
||||
window.localStorage.setItem(
|
||||
"baron_session_expiry_enabled",
|
||||
String(next),
|
||||
);
|
||||
window.localStorage.setItem("baron_session_expiry_enabled", String(next));
|
||||
return next;
|
||||
});
|
||||
};
|
||||
@@ -413,10 +409,7 @@ function AppLayout() {
|
||||
{t("ui.admin.header.plane", "ADMIN PLANE")}
|
||||
</p>
|
||||
<span className="text-lg font-semibold">
|
||||
{t(
|
||||
"ui.admin.header.subtitle",
|
||||
"Manage your organization",
|
||||
)}
|
||||
{t("ui.admin.header.subtitle", "Manage your organization")}
|
||||
</span>
|
||||
</div>
|
||||
|
||||
@@ -518,9 +511,7 @@ function AppLayout() {
|
||||
onClick={handleSessionExpiryToggle}
|
||||
className={[
|
||||
"relative inline-flex h-6 w-11 shrink-0 items-center rounded-full transition",
|
||||
isSessionExpiryEnabled
|
||||
? "bg-primary"
|
||||
: "bg-muted",
|
||||
isSessionExpiryEnabled ? "bg-primary" : "bg-muted",
|
||||
].join(" ")}
|
||||
>
|
||||
<span
|
||||
@@ -580,7 +571,9 @@ function AppLayout() {
|
||||
type="button"
|
||||
onClick={() => {
|
||||
setIsProfileOpen(false);
|
||||
navigate(`/users/${profile?.id || auth.user?.profile.sub}`);
|
||||
navigate(
|
||||
`/users/${profile?.id || auth.user?.profile.sub}`,
|
||||
);
|
||||
}}
|
||||
className="mt-2 flex w-full items-center gap-2 rounded-lg border border-border px-3 py-2 text-left text-sm text-foreground transition hover:bg-muted/20"
|
||||
>
|
||||
|
||||
@@ -130,8 +130,12 @@ const RoleSwitcher: FC = () => {
|
||||
alignItems: "center",
|
||||
}}
|
||||
>
|
||||
<span>{t("ui.admin.dev_role_switcher_real", "실제 역할 사용")}</span>
|
||||
{!isOverrideEnabled && <span style={{ marginLeft: "8px" }}>✅</span>}
|
||||
<span>
|
||||
{t("ui.admin.dev_role_switcher_real", "실제 역할 사용")}
|
||||
</span>
|
||||
{!isOverrideEnabled && (
|
||||
<span style={{ marginLeft: "8px" }}>✅</span>
|
||||
)}
|
||||
</button>
|
||||
{(["super_admin", "tenant_admin", "rp_admin", "user"] as const).map(
|
||||
(role) => (
|
||||
|
||||
Reference in New Issue
Block a user