/** * Copyright (c) 2026 Microblink Ltd. All rights reserved. */ import { SetStoreFunction } from "solid-js/store"; import { CameraManager } from "../core/CameraManager"; import { CameraUiLocalizationStrings } from "./LocalizationContext"; /** * The default mount point ID. */ export declare const MOUNT_POINT_ID = "camera-manager-mount-point"; import { Owner } from "solid-js"; import "virtual:uno.css"; /** * The camera manager component. */ export type CameraManagerComponent = { /** The camera manager. */ cameraManager: CameraManager; /** Updates the localization strings */ updateLocalization: SetStoreFunction; /** Dismounts the component from the DOM and unloads the SDK */ dismount: () => void; /** * Sets a callback to be called when the component is unmounted. * Returns a cleanup function that removes the callback when called. */ addOnDismountCallback: (fn: DismountCallback) => () => void; /** * The feedback layer node that can be used to append custom feedback elements */ feedbackLayerNode: HTMLDivElement; /** * The overlay layer node that can be used to append custom overlay elements */ overlayLayerNode: HTMLDivElement; /** * The owner of the component. * * @see https://docs.solidjs.com/reference/reactive-utilities/get-owner */ owner: Owner; }; /** * A dismount callback. */ export type DismountCallback = () => void; /** * The camera manager UI options. */ export type CameraManagerUiOptions = { /** * The localization strings. */ localizationStrings?: Partial; /** * If set to `true`, the mirror camera button will be shown. * * @defaultValue false */ showMirrorCameraButton?: boolean; /** * If set to `true`, the torch button will be shown. * * @defaultValue true */ showTorchButton?: boolean; /** * If set to `true`, the close button will be shown. * * @defaultValue true */ showCloseButton?: boolean; /** * If set to `true`, the camera error modal will be shown. * * @defaultValue true */ showCameraErrorModal?: boolean; /** * The z-index of the camera UI when rendered as a full-screen overlay. * Only applies when no target element is provided. * * If not provided, uses `calc(infinity)` to ensure the camera UI appears on top. * * @defaultValue calc(infinity) */ zIndex?: number; }; /** * Creates a new Camera Manager UI component. * * @param cameraManager - The camera manager. * @param target - The target element to mount the component to. * @param options - The options for the camera manager UI. * @returns The camera manager UI component. */ export declare function createCameraManagerUi(cameraManager: CameraManager, target?: HTMLElement, { localizationStrings, showMirrorCameraButton, showTorchButton, showCloseButton, showCameraErrorModal, zIndex, }?: CameraManagerUiOptions): Promise; //# sourceMappingURL=createCameraManagerUi.d.ts.map