/** * Copyright (c) 2025 Elara AI Pty Ltd * Dual-licensed under AGPL-3.0 and commercial license. See LICENSE for details. */ import type { FieldSpecValue } from "@elaraai/east-ui/internal"; /** * A value with one field along a path set: a step into a variant sets its * case's value while it holds that case, and leaves it as it is while it holds * another. * * @param value - The form's value * @param path - The field's path * @param to - Its new value * @returns The value with it set */ export declare function setAt(value: unknown, path: readonly string[], to: unknown): unknown; /** * A field's value along a path: a step into a variant its case's value while * it holds that case. * * @param value - The form's value * @param path - The field's path * @returns Its value, `undefined` for none, or for a case the variant does not hold */ export declare function getAt(value: unknown, path: readonly string[]): unknown; /** * The first required field left empty: one holding no value, or a text input the viewer has emptied — never one under * a case its variant does not hold, which the form does not show. * * @param specs - The form's fields * @param value - The form's value as it stands * @param root - The element the form is drawn in, whose inputs are read * @returns The field, or `undefined` while every required one holds a value */ export declare function emptyRequired(specs: readonly FieldSpecValue[], value: unknown, root: HTMLElement | null): FieldSpecValue | undefined; /** The first control of a form: a text box, a choice's radio or a date's segment (K5; the hand test's F1 for a date field). */ export declare const FIRST_CONTROL = "input:not([type=hidden]), textarea, [role=radio], [role=spinbutton]"; //# sourceMappingURL=form-check.d.ts.map