9f01e315c1
SSO settings page: resolve plan before the role check. A non-Enterprise org now renders the upsell state for every role instead of showing a "permission denied" panel to non-Owners for a feature their org can't use yet. manage:sso is only enforced once the org is actually entitled. Extracts EMPTY_SSO_STATUS and uses throwPermissionDenied(). Also removes the client-side SSO session fetch guard. It monkeypatched global window.fetch, which made it the initiator of every request and obfuscated the real call site on any 4xx/5xx. Session revocation is still enforced server-side on every authenticated request and surfaces as a logout redirect on the next navigation/refresh, so the client guard was UX-only and not worth the cross-cutting cost.
19 lines
682 B
TypeScript
19 lines
682 B
TypeScript
import { RemixBrowser } from "@remix-run/react";
|
|
import { hydrateRoot } from "react-dom/client";
|
|
import { clientBeforeFirstRender } from "./clientBeforeFirstRender";
|
|
import { LocaleContextProvider } from "./components/primitives/LocaleProvider";
|
|
import { OperatingSystemContextProvider } from "./components/primitives/OperatingSystemProvider";
|
|
|
|
clientBeforeFirstRender();
|
|
|
|
hydrateRoot(
|
|
document,
|
|
<OperatingSystemContextProvider
|
|
platform={window.navigator.userAgent.includes("Mac") ? "mac" : "windows"}
|
|
>
|
|
<LocaleContextProvider locales={window.navigator.languages as string[]}>
|
|
<RemixBrowser />
|
|
</LocaleContextProvider>
|
|
</OperatingSystemContextProvider>
|
|
);
|