Skip to content

Component to display relative dates #326

Description

@markstos

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

Presenting relative dates should be displayed in a consistent way, but there are enough details to consider to package them as reusable component.

Describe the solution you'd like

  • Use Intl.RelatieTimeFormat() as the foundation.
  • Wrap the date in a <time> tag for better semantics.
  • Show the full, precise timestamp on hover.
  • At least allow presenting "short" format dates, possibly long format if we need it.

Both Stormbox and Accounts settings need to display relative dates.

Describe alternatives you've considered

  • Considered one-off implementation in accounts, but this is expected to a common pattern we'll want to re-use.

Additional context

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Fields

    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