//#region src/utilities/form-validity.d.ts /** * Form controls that wrap a native input, textarea, or select mirror that control's validity onto the host through * `ElementInternals`. Which flags are mirrored, and how a custom validity message overrides the native one, is one * rule — it lives here rather than being restated in every wrapping component. */ export interface MirroredValidity { /** The flags to hand to `ElementInternals.setValidity()`. */ flags: ValidityStateFlags; /** The message to report: the custom one when set, otherwise the native control's own message. */ validationMessage: string; /** Whether the host should consider itself invalid. */ isInvalid: boolean; } /** * Mirrors a native form control's validity, letting a non-empty custom validity message win over it. * * Every flag is passed on every call, whatever constraints the wrapped control actually supports. A checkbox only * validates `required`, so its other flags are always false — and `ElementInternals.setValidity()` clears any flag left * out of the object anyway, which makes the short form and the full form equivalent. Passing them all keeps one rule * here instead of a per-control opinion about which flags are worth naming. * * @param control The native control rendered inside the component's shadow root. * @param customValidity The component's current custom validity message, or an empty string when none is set. */ export declare function mirrorNativeValidity(control: HTMLInputElement | HTMLSelectElement | HTMLTextAreaElement, customValidity: string): MirroredValidity; //#endregion