Skip to content

[FEATURE] Make it possible to configure what happens when the input gets focused #380

@Juljus777

Description

@Juljus777

Feature description
Make it possible to configure what happens when the input gets focused

Use case
Use case 1:
In massive forms with many date inputs there is an issue where some "power users" may not want to use the calendar widget to select dates and instead like to write the dates out manually because for them it's faster. The automatic opening of the calendar becomes a burden since users have to manually close it every time when using "ESC".

Use case 2:
A user might only be able to navigate a massive form using the keyboard for accessibility reasons and also uses a screen reader to read out the information in the forms. Let's say that the user has already filled out the form and wants to confirm the information by going over all the fields again. Currently after that user focuses on a date input in that form he will get stuck inside the calendar widget and will have to manually close it using "ESC" key. This again becomes a burden when the user just wants to get the information on the date input.

Proposed solution
Either add a "openOnFocus: boolean" configuration value or add some kind of an event like "onBeforeOpen" that includes information what triggered the opening or some kind of a callback that would allow for developers to intersect the opening.

Similar functionality in other calendars (optional)
Default html date input only opens the calendar widget only when keyboard users manually click a separate button.

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions