Skip to content

Input content select on date selection/focus input #5658

@zdrawku

Description

@zdrawku

Is your feature request related to a problem? Please describe.

When using the igxDatePicker with editable input (dropdown mode), on input focus or date select the caret is placed at the end of the input.

Describe the solution you'd like

I would like to select the whole input content on focus or when picking a date. Below you will find the proposed solutions:

  • Select the whole input content like the igDatePicker. Example:
    3

Note: This is the behavior of simple html input as well. Example.

Workaround:

Currently, in order to achieve the above functionalitiy, I am using `getEditElement().select.

      selection($event) {
        requestAnimationFrame(() => { 
          this.datePicker.getEditElement().select();
        });
      }

https://stackblitz.com/edit/angular-mask-and-datepicker-example

Metadata

Metadata

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions