import type { ReactNode } from 'react'; import { Outlet } from 'react-router-dom'; import { environment } from '../../environments/environment'; import { Alert, AlertDescription, AlertTitle } from '../ui/alert'; export const SANDBOX_DISABLED_TITLE = 'Disabled in sandbox mode'; // Text message registration and marketing stay visible in the sandbox but nothing on them can be // changed or sent. The disabled fieldset reaches every native control, and the server refuses anyway. const SandboxDisabled = ({ children }: { children: ReactNode }) => { if (!environment.inSandboxMode) return <>{children}; return ( <> {SANDBOX_DISABLED_TITLE} You can see how this is set up, but nothing here can be changed or sent from the sandbox.
{children}
); }; export const SandboxDisabledRoute = () => ; export default SandboxDisabled;