Date Field

3.0.0

Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua.

Demo

NamnTypBeskrivning

calendarButtonAriaLabel

stringAria label for calendar button.

customAttribute

{ attribute: string; value: string | number }Used for tests. Clickable and requested subcomponents will be suffixed with "-[ComponentName]".

customCalendarButtonRef

RefUse this if you want to bypasss internal focus handling

customTranslation

DeepPartialTranslation object used for screen reader texts.

hasAdornments

booleanRender Calendar and Chevron IconButtons in DateField. Default off in stand alone DateField and deafult on in DatePicker

isCalendarOpen

booleanDetermines if the calendar is open.

isLoading

booleanIf true, a loading skeleton will be rendered instead of the component.

lang *

"sv" | "en"Language used for localization and date formatting.

maxDate

stringDisable all dates after this. Expected in 'yyyy-MM-dd' format.

minDate

stringDisable all dates before this. Expected in 'yyyy-MM-dd' format.

onAccept

(value: string) => voidCallback that is fired when input value passes validation

onChange

(event: ChangeEvent) => voidCallback when field changes.

onFocus

FocusEventHandlerCallback when field is focused.

onToggleCalendar

() => voidFunction to run on open calendar button.

timeZone

stringSet timezone for the DateField

value *

stringDateField value.

Installation

npm install @sj-ab/component-library.ui.date-field

Länkar

Tillgänglighet

Se dokumentationen av tillgängligheten för komponenterna DatePicker och TextField:

Change log

Statistik