import { CSSResultGroup, PropertyDeclaration } from 'lit'; import { SbbElement } from '../core/base-elements.ts'; import { SbbDatepickerElement } from '../datepicker.ts'; /** * Interface for elements that can be associated with a date input. * Implementing classes must also have a static property `sbbDateInputAssociated` set to `true`. */ export interface SbbDateInputAssociated { input: SbbDateInputElement | null; } declare const SbbDateInputElement_base: import('../core/mixins.ts').AbstractConstructor & typeof SbbElement; /** * Custom input for a date. */ export declare class SbbDateInputElement extends SbbDateInputElement_base { static readonly elementName: string; static styles: CSSResultGroup; /** * The value of the date input. Reflects the current text value * of this input. * The attribute `value` Accepts ISO8601 formatted values, which will be * formatted according to the current locale. */ set value(value: string); get value(): string; /** Formats the current input's value as date. */ set valueAsDate(value: T | null); get valueAsDate(): T | null; private _valueAsDate?; /** * The minimum valid date. Accepts a date object or null. * Accepts an ISO8601 formatted string (e.g. 2024-12-24) as attribute. */ accessor min: T | null; /** * The maximum valid date. Accepts a date object or null. * Accepts an ISO8601 formatted string (e.g. 2024-12-24) as attribute. */ accessor max: T | null; /** * A function used to filter out dates. * It is strongly recommended to use min and max dates alongside * this filter. */ set dateFilter(value: (date: T | null) => boolean); get dateFilter(): (date: T | null) => boolean; /** * How to format the displayed date. * `short`: Two letter abbreviation of the week day (e.g. Fr). * `none`: The weekday is not displayed. */ accessor weekdayStyle: 'short' | 'none'; /** * Stores the last string and parsed date object value to prevent repeated * parsing of the string value. */ private _valueCache?; private _dateAdapter; private _placeholderMutable; /** * Gets the associated datepicker, if any. * The sbb-date-input and the sbb-datepicker are assumed to be in the same parent container. */ get datepicker(): SbbDatepickerElement | null; constructor(); /** * Attempts to resolve the associated date input with the given element. */ static resolveAssociation(host: HTMLElement & SbbDateInputAssociated): void; private _dateFilter; connectedCallback(): void; requestUpdate(name?: PropertyKey, oldValue?: unknown, options?: PropertyDeclaration): void; protected updateFormValue(): void; private _tryParseValue; private _updateValueDateFormat; private _formatDate; protected shouldValidate(name: PropertyKey | undefined): boolean; protected validate(): void; private _removeValidityErrors; } declare global { interface HTMLElementTagNameMap { 'sbb-date-input': SbbDateInputElement; } interface CustomValidityState { sbbDateFilter: boolean; } } export {}; //# sourceMappingURL=date-input.component.d.ts.map