Select a row on the left.
}
+ Select a workflow on the left.
}
{selected && (
{selected.display_name}
diff --git a/src/scenes/Landing.tsx b/src/scenes/Landing.tsx
index 09d712b..b965305 100644
--- a/src/scenes/Landing.tsx
+++ b/src/scenes/Landing.tsx
@@ -79,7 +79,9 @@ export default function Landing() {
-
+ {(import.meta.env.VITE_ENABLE_GEO_PREVIEW ?? "true") !== "false" && (
+
+ )}
diff --git a/src/scenes/Login.tsx b/src/scenes/Login.tsx
index c83b4c8..abc2ff6 100644
--- a/src/scenes/Login.tsx
+++ b/src/scenes/Login.tsx
@@ -9,16 +9,28 @@ export default function Login() {
const [email, setEmail] = useState("");
const [password, setPassword] = useState("");
const [rememberMe, setRememberMe] = useState(false);
- const [devLoginEnabled, setDevLoginEnabled] = useState(true);
+ const buildAllowsDev = (import.meta.env.VITE_ENABLE_DEV_LOGIN ?? "true") !== "false";
+ const [devLoginEnabled, setDevLoginEnabled] = useState(buildAllowsDev);
+ const [ssoState, setSsoState] = useState<"unknown" | "ready" | "not-configured" | "not-wired">("unknown");
const [loading, setLoading] = useState(false);
const [error, setError] = useState
(null);
useEffect(() => {
- // dev-login is on by default. Only the endpoint can flip it OFF.
- api.devLoginConfig()
- .then((cfg) => { if (cfg.enabled === false) setDevLoginEnabled(false); })
- .catch(() => { /* endpoint absent → keep ON */ });
- }, []);
+ if (!buildAllowsDev) {
+ setDevLoginEnabled(false);
+ } else {
+ api.devLoginConfig()
+ .then((cfg) => { if (cfg.enabled === false) setDevLoginEnabled(false); })
+ .catch(() => { /* endpoint absent → keep state */ });
+ }
+ fetch("/api/v1/auth/microsoft/login", { method: "GET", redirect: "manual" })
+ .then((r) => {
+ if (r.status >= 300 && r.status < 400) setSsoState("ready");
+ else if (r.status === 503) setSsoState("not-configured");
+ else setSsoState("not-wired");
+ })
+ .catch(() => setSsoState("not-wired"));
+ }, [buildAllowsDev]);
const handleSubmit = async (e: React.FormEvent) => {
e.preventDefault();
@@ -142,14 +154,20 @@ export default function Login() {