Skip to content

Date picker applies non-date mask when dropdown mode is set after init #6749

Closed
@damyanpetev

Description

@damyanpetev

Description

When the mode option is changed to dropdown after control init, the picker applies a mask that's not a date (the igxMask default)

  • igniteui-angular version: 9.0.x
  • browser: N/A

Steps to reproduce

  1. Open https://stackblitz.com/edit/datepicker-mode-switch
  2. Change the mode from the select
  3. Focus the input

Result

The editor displays the date correctly as "5/15/19", but when you focus there's no value and the placeholder shows the underlying mask as "CCCCCCC..":
image

Also if you clear the editor and focus again, the picker throws a parsing error:

image

Expected result

The editor should work the same as if mode="dropdown" has been assigned intially, formatting the date as "_5/15/2019" when focused and display an empty mask (__/__/____) for cleared.

Metadata

Metadata

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions