Date time
<ns-date-time>
Overview
A standardised way to show the date and time.
Takes an input of a standard date and/or time string YYYY-MM-DDTHH:MM
and outputs it into the correct date and/or time format.
Examples
Guidance
Implementation
Placement
The ns-date-time
component can be used in the following components:
<p>
<div>
Specification
Attributes
date
- Property
date
- Description
- The date to display.
- Type
string
- Default
hide-date
- Property
hideDate
- Description
- Whether to hide the date.
- Type
boolean
- Default
false
hide-time
- Property
hideTime
- Description
- Whether to hide the time.
- Type
boolean
- Default
false
hide-day
- Property
hideDay
- Description
- Whether to hide the day.
- Type
boolean
- Default
false
hide-month
- Property
hideMonth
- Description
- Whether to hide the month.
- Type
boolean
- Default
false
hide-year
- Property
hideYear
- Description
- Whether to hide the year.
- Type
boolean
- Default
false
type
- Property
type
- Type
string
- Default
standard
Specification notes
date
The time specified in the date
attribute is in 24hrs format. It is displayed with am/pm following the tone of voice guidelines.
Be careful when passing timezones in the date string due to British Summer Time.
Last updated: