import "@tanstack/react-start";

//#region src/auth/sso.d.ts

/**
 * Where a link or button sends a visitor to sign in with single sign-on. They
 * come back to `returnPath` once signed in. Without one, they land where
 * `auth.guard.alreadyAuthenticated` in softr.json points, as after any sign-in.
 *
 * A full page load, not a router navigation: the visitor leaves the app for
 * their identity provider.
 *
 * @example
 * <a href={ssoSignInHref(toReturnPath(location).href)}>Continue with SSO</a>
 */
declare function ssoSignInHref(returnPath?: string): string;
/**
 * Why single sign-on did not finish, as the `error` search param of the SSO
 * page. Never the platform's own message: that is for the builder, and it would
 * sit in the visitor's address bar.
 */
type SsoError = "host" | "idp" | "not-enabled" | "sign-up-disabled" | "restricted" | "expired" | "failed";
//#endregion
export { SsoError, ssoSignInHref };