/
githubmirror
/
components
Обзор
Документация
Войти
/
githubmirror
/
components
Код
Запросы
0
Пакеты
0
Релизы
0
Аналитика
Безопасность
main
src/components-examples/material/timepicker/timepicker-validation/timepicker-validation-example.html
26 строк
729 B
Kristiyan Kostadinov
docs(material/timepicker): add timepicker documentation and live examples
04 ноя 2024, 09:00
04 ноя 2024, 09:00
ade32c6
Код
Авторство
О чём код?
<mat-form-field> <mat-label>Pick a time</mat-label> <input matInput [formControl]="formControl" [matTimepicker]="picker" matTimepickerMin="12:30" matTimepickerMax="17:30"> <mat-timepicker-toggle matIconSuffix [for]="picker"/> <mat-timepicker #picker/> @if (formControl.errors?.['matTimepickerParse']) { <mat-error>Value isn't a valid time</mat-error> } @if (formControl.errors?.['matTimepickerMin']) { <mat-error>Value is too early</mat-error> } @if (formControl.errors?.['matTimepickerMax']) { <mat-error>Value is too late</mat-error> } </mat-form-field> <p>Enter a value before 12:30 PM or after 5:30 PM to see the errors</p> <p>Errors: {{formControl.errors | json}}</p>