/* eslint-disable */ /* tslint:disable */ /** * This is an autogenerated file created by the Stencil compiler. * It contains typing information for all components that exist in this project. */ import { HTMLStencilElement, JSXBase } from "./stencil-public-runtime"; import { LogoutResult, PromptOption, ResponseType } from "./auth"; import { AuthResult } from "./components/unidy-login/unidy-login"; export { LogoutResult, PromptOption, ResponseType } from "./auth"; export { AuthResult } from "./components/unidy-login/unidy-login"; export namespace Components { interface UnidyLogin { /** * Initiates the authentication process * @param options - Options for the authentication process * @param options.trySilentAuth - Whether to attempt silent authentication without showing UI (defaults to false) * @returns Promise that resolves with authentication result containing success status and token or error * @example ```typescript // Default authentication, using the prompt prop const result = await component.auth(); // Silent authentication, will override the prompt prop with 'none' const result = await component.auth({ trySilentAuth: true }); if (result.success) { console.log('Token:', result.token); } else { console.error('Auth failed:', result.error); } ``` */ "auth": ({ trySilentAuth }?: { trySilentAuth?: boolean; }) => Promise; /** * The base URL of the Unidy authentication server, example: https://your-domain.unidy.de */ "baseUrl": string; /** * The client ID for the application */ "clientId": string; /** * Whether to enable logging, defaults to true * @default true */ "enableLogging": boolean; /** * Hides the authentication dialog modal. * @returns Promise that resolves when the dialog is hidden * @example ```typescript await component.hide(); ``` */ "hide": () => Promise; /** * Logs out the current user and clears any stored session data. * @returns Promise that resolves with logout result indicating success status * @example ```typescript const result = await component.logout(); if (result.success) { console.log('Successfully logged out'); } ``` */ "logout": () => Promise; /** * The rendering mode - 'dialog' for modal popup, 'inline' for embedded in page * @default "dialog" */ "mode": "dialog" | "inline"; /** * The prompt option for authentication, can be "none", "login", "consent", "select_account" or null * @default null */ "prompt": PromptOption; /** * Whether to use the special redirect behavior, for browsers limitation access to third party cookies. This should be disabled, when the Unidy instance runs on the same second level domain. Defaults to true * @default true */ "redirectFlowForLimitedThirdPartyCookieAccess": boolean; /** * When in inline mode and the browser has no access to third-party cookies, a login button is rendered with this label. Defaults to "Login" * @default "Login" */ "redirectFlowLoginButtonLabel": string; /** * The OAuth response type, defaults to "id_token" * @default "id_token" */ "responseType": ResponseType; /** * The OAuth scopes to request, defaults to "openid email" * @default "openid email" */ "scope": string; /** * Shows the authentication dialog modal to the user. * @returns Promise that resolves when the dialog is shown * @example ```typescript await component.show(); ``` */ "show": () => Promise; } } export interface UnidyLoginCustomEvent extends CustomEvent { detail: T; target: HTMLUnidyLoginElement; } declare global { interface HTMLUnidyLoginElementEventMap { "authEvent": { token: string }; } interface HTMLUnidyLoginElement extends Components.UnidyLogin, HTMLStencilElement { addEventListener(type: K, listener: (this: HTMLUnidyLoginElement, ev: UnidyLoginCustomEvent) => any, options?: boolean | AddEventListenerOptions): void; addEventListener(type: K, listener: (this: Document, ev: DocumentEventMap[K]) => any, options?: boolean | AddEventListenerOptions): void; addEventListener(type: K, listener: (this: HTMLElement, ev: HTMLElementEventMap[K]) => any, options?: boolean | AddEventListenerOptions): void; addEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | AddEventListenerOptions): void; removeEventListener(type: K, listener: (this: HTMLUnidyLoginElement, ev: UnidyLoginCustomEvent) => any, options?: boolean | EventListenerOptions): void; removeEventListener(type: K, listener: (this: Document, ev: DocumentEventMap[K]) => any, options?: boolean | EventListenerOptions): void; removeEventListener(type: K, listener: (this: HTMLElement, ev: HTMLElementEventMap[K]) => any, options?: boolean | EventListenerOptions): void; removeEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | EventListenerOptions): void; } var HTMLUnidyLoginElement: { prototype: HTMLUnidyLoginElement; new (): HTMLUnidyLoginElement; }; interface HTMLElementTagNameMap { "unidy-login": HTMLUnidyLoginElement; } } declare namespace LocalJSX { interface UnidyLogin { /** * The base URL of the Unidy authentication server, example: https://your-domain.unidy.de */ "baseUrl": string; /** * The client ID for the application */ "clientId": string; /** * Whether to enable logging, defaults to true * @default true */ "enableLogging"?: boolean; /** * The rendering mode - 'dialog' for modal popup, 'inline' for embedded in page * @default "dialog" */ "mode"?: "dialog" | "inline"; "onAuthEvent"?: (event: UnidyLoginCustomEvent<{ token: string }>) => void; /** * The prompt option for authentication, can be "none", "login", "consent", "select_account" or null * @default null */ "prompt"?: PromptOption; /** * Whether to use the special redirect behavior, for browsers limitation access to third party cookies. This should be disabled, when the Unidy instance runs on the same second level domain. Defaults to true * @default true */ "redirectFlowForLimitedThirdPartyCookieAccess"?: boolean; /** * When in inline mode and the browser has no access to third-party cookies, a login button is rendered with this label. Defaults to "Login" * @default "Login" */ "redirectFlowLoginButtonLabel"?: string; /** * The OAuth response type, defaults to "id_token" * @default "id_token" */ "responseType"?: ResponseType; /** * The OAuth scopes to request, defaults to "openid email" * @default "openid email" */ "scope"?: string; } interface IntrinsicElements { "unidy-login": UnidyLogin; } } export { LocalJSX as JSX }; declare module "@stencil/core" { export namespace JSX { interface IntrinsicElements { "unidy-login": LocalJSX.UnidyLogin & JSXBase.HTMLAttributes; } } }