Page MenuHomeElementl

[dagit] Improve timestamp consistency and localization
ClosedPublic

Authored by dish on Feb 25 2021, 11:01 PM.

Details

Summary

Use toLocaleDateString for formatting our timestamps, which allows us to use the user's locale settings to determine the correct timestamp format.

A couple of time rendering options are available, namely rendering seconds and rendering the short version of the timestamp itself.

Additionally, remove the UTC-specific default formatting. My thought here is that a user should be able to use UTC as their timezone while still getting a local timestamp format string.

Test Plan

Jest test to validate correct rendering for same-year vs. different-year.

Load Dagit in various locales (en-US, de-DE, hu-HU). Click around and verify that timestamp strings are correctly localized.

Diff Detail

Repository
R1 dagster
Lint
Lint Not Applicable
Unit
Tests Not Applicable