Date Time Picker
Combines an Input and a Calendar/Time Picker popover to allow users to enter or select a date and time.
The label attribute provides a short description of the purpose of the Date Picker.
If a visible label can't be used, provide one using the aria-label
The helper-text attribute provides additional information to help the user enter the correct information.
To add HTML to the helper text, use the helper-text slot.
You can add the Contextual Help component using the contextual-help slot. It will be displayed next to the label, providing users additional information.
The error-text attribute provides a custom error message. Any current error state will be overridden by error-text.
The value attribute contains the currently selected date and time.
Empty string or undefined represent no value being selected.
It will always contain a valid value in the format YYYY-MM-DDTHH:MM:SS when a value is selected. If the user enters an invalid value, value will be empty.
The Date Time Picker is time zone agnostic. You need to ensure that value is interpreted correctly in your application.
Set the min attribute to configure the earliest value to accept. The user will be prevented from choosing an earlier value, however it is still possible to manually enter one.
Set the min-date attribute to configure the earliest date to accept. The user will be prevented from choosing an earlier date, however it is still possible to manually enter one.
The min-date attribute will take precedence over the min attribute.
Set the min-time attribute to configure the earliest time to accept. The user will be prevented from choosing an earlier time, however it is still possible to manually enter one.
The min-time attribute will take precedence over the min attribute.
Set the max attribute to configure the latest date to accept. The user will be prevented from choosing an later date, however it is still possible to manually enter one.
Set the max-date attribute to configure the latest date to accept. The user will be prevented from choosing a later date, however it is still possible to manually enter one.
The max-date attribute will take precedence over the max attribute.
Set the max-time attribute to configure the latest time to accept. The user will be prevented from choosing a later time, however it is still possible to manually enter one.
The max-time attribute will take precedence over the max attribute.
The Date Time Picker will display the time in 12h or 24h format depending on the configured locale.
Use the clock attribute to override this behavior.
Use the minutes-step attribute to configure the step between minutes in the Date Time Picker.
Use the seconds-step attribute to configure the step between seconds in the Date Time Picker.
If not set, the Date Time Picker will not display seconds.
The scale attribute controls the Date Time Picker input element display size.
Add the disabled attribute to disable the Date Time Picker.
Add the readonly attribute to make the Date Time Picker readonly.