Skip to content

[EuiSuperDatePicker] Does not properly restore relative dates #4026

@matt-moses

Description

@matt-moses

SuperDatePicker does not properly restore relative dates

Steps to reproduce:

  1. Go to https://elastic.github.io/eui/#/forms/super-date-picker and to the first time picker on that page
  2. Click start date to edit the start date and enter 15 months ago
    image
  3. Observe SuperDatePicker puts human friendly desc in start date of ~ 1 year ago which is handy.
  4. Click Update
  5. Observe the time picker reflects 15 months ago just fine.
    image
  6. Click to edit the start date again
  7. Observe that 1 year ago is populate in the time picker GUI instead of 15 months ago. Note the underlying date is still correct (verify this by looking at the absolute date at the bottom of the picker).
    image
  8. As a user I would expect it to restore 15 months ago and if I manually fix it myself it causes the dialog to get stuck in "update mode" (see SuperDatePicker gets stuck in "update" mode. #4025)

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type
No fields configured for issues without a type.

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions