New to Kendo UI for Angular? Start a free 30-day trial

Placeholders

For its input field, the DatePicker enables you to render a text hint and to provide descriptions for the format sections.

Text Hints

When the value of the DatePicker is null, you can specify a text hint for its input field by setting the placeholder option of the component.

Example
View Source
Change Theme:

Format Sections Description

The formatPlaceholder option enables you to set the way the format sections of the input field are rendered. For example, whether the month input is prompted as month or MM.

The formatPlaceholder provides the following available options which you can set:

  • 'wide'—Displays the full description of the format section. For example, turns MM into month. Retrieved from CLDR.
  • 'narrow'—Displays the narrow description of the format section. For example, turns MM into mo.. Retrieved from CLDR.
  • 'short'—Displays the short description of the format section. For example, turns MM into mo.. Retrieved from CLDR.
  • 'formatPattern'—Directly displays the format section. For example, turns MM into MM.
  • CustomFormatPlaceholder—An object that defines the description of the format sections. For example, { day: 'd.', month: 'M.', year: 'y', hour: 'h.' }.
Example
View Source
Change Theme:

In this article

Not finding the help you need?