/*
Date field

@uswds https://standards.usa.gov/components/form-controls/#date-input

Three text fields are the easiest way for users to enter most dates.

Markup: datefield.example.html

Style guide: components.date-field
*/

/*
`<DateField>`

@react-component DateField

Style guide: components.date-field.react
*/

/*
---

### When to use

- Use this format for most dates, particularly memorized dates.

### When to consider alternatives

- If users are trying to schedule something, a calendar picker might make more sense. Be sure to also provide an option for text entry as well.

### Usage

- Ensure you've [installed both the Core package and Layout package](/startup/installation)
- Allow users to enter the date as flexibly as possible, for example, allowing `1` as well as `01` for a month input.
- Be sure each field is properly labeled — some countries enter dates in day, month, year order.
- It may be tempting to switch all or some of these text fields to drop downs, but these tend to be more difficult to use than text boxes.

### Accessibility

- These text fields should follow the [accessibility guidelines for all text inputs](/components/text-field/#guidance).
- Do not use JavaScript to auto advance the focus from one field to the next. This makes it difficult for keyboard-only users to navigate and correct mistakes.

### Related patterns

- [Text field](/components/text-field/)
- [Grid](/layout/grid/)

Style guide: components.date-field.guidance
*/
