/** * * Copyright © 2025 Ping Identity Corporation. All right reserved. * * This software may be modified and distributed under the terms * of the MIT license. See the LICENSE file for details. * **/ import type { SvelteComponent } from 'svelte'; import type { Writable } from 'svelte/store'; export interface ComponentStoreValue { lastAction: 'close' | 'open' | 'mount' | null; error: { code: string; message: string; } | null; modal: { component: SvelteComponent; element: HTMLDialogElement; } | null; mounted: boolean; open: boolean | null; reason: 'auto' | 'external' | 'user' | null; type: 'inline' | 'modal' | null; } export declare const componentStore: Writable; /** * @function closeComponent - this is a widget internal function not to be exposed to user * @param {object} args - object containing the reason for closing component * @param {boolean} shouldCloseDialog - if true, the close command comes from outside of dialog component */ export declare function closeComponent(args?: { reason: ComponentStoreValue['reason']; }, shouldCloseDialog?: boolean): void; /** * @function mount - this is a widget internal function not to be exposed to user * @param {object} component - actual Svelte component representing the dialog * @param {object} element - actual DOM element representing the dialog */ export declare function mount(component: SvelteComponent, element: HTMLDialogElement): void;