Date And Time Text Patterns




Date

Default


Variants


Alignment


Show Current Year


By default, the Date kit does NOT display the year if it is the current year. If you want to display the current year you can do so by setting showCurrentYear/show_current_year to true as shown here.

Unstyled


For alternative typography styles, you can pass a boolean prop called unstyled to the Date kit and wrap it in any of our typography kits (Title, Body, Caption, etc.). This will allow the Date kit to inherit any of our typography styles.

Date Range Inline

Default


Show Current Year


By default, the Date Range Inline kit does NOT display the year if it is the current year. If you want to display the current year you can do so by setting showCurrentYear/show_current_year to true as shown here.

Date Range Stacked

Default


Date Stacked

Default


Show Current Year


By default, the Date Stacked kit does NOT display the year if it is the current year. If you want to display the current year you can do so by setting showCurrentYear/show_current_year to true as shown here.

Day & Month Reverse


Sizes


Bold


Date Time

Default


Alignment


Size


Show Current Year


Pass in showCurrentYear to show this date's current year.

Date Time Stacked

Default


Show Current Year


By default, the Date Time Stacked kit does NOT display the year if it is the current year. If you want to display the current year you can do so by setting showCurrentYear/show_current_year to true as shown here.

Date Year Stacked

Default


Use this kits on table displays or column headers to display a single date format.

Time

Default


Use this anywhere needed to display a certain timestamp

Sizes


Timestamp Values


Handling Timezones


Simply enter the timezone you would like to use and it will appear.

The list of supported timezones is exhaustive and we're most likely to only use timezones from the Americas so we've highlighted those in the examples.

However, if you need to support another timezone you should be able to Google a specific list, otherwise you can follow the string pattern and try entering a continent and a city.

Remember, this is just labeling the timezone, please verify the actual time for a specified timezone is rendering properly.

Format: <Continent>/<Large_City_Name>

Continent Options: America | Europe | Asia | Africa | Pacific | India | Atlantic | Australia

Alignment


Unstyled


For alternative typography styles, you can pass a boolean prop called unstyled to the Time kit and wrap it in any of our typography kits (Title, Body, Caption, etc.). This will allow the Time kit to inherit any of our typography styles.

Time Range Inline

Default


Time Stacked

Default


Timestamp

Default


By default, the timestamp kit will display the date and time as shown here. If the date is NOT within the current year, the year will also be shown while dates in the current year will not show the year.

Hide Date


The showDate/show_date prop is set to true by default but can be set to false to hide the date.

Hide Time


The showTime/show_time prop is set to true by default but can be set to false to hide the time.

Show Current Year


Use the showCurrentYear/show_current_year prop to show the year even if it is the current year. This is set to false by default.

Show Timezones


The showTimezone/show_timezone prop can be used to show the timezone as well. This is set to false by default. NOTE: This prop must be used in conjunction with the timezone prop to specify which timezone to display.

Alignments


The align prop can be used to set alignment. This prop is set to 'left' by default.

Time Ago (Elapsed Variant)


Use variant elapsed to show time ago. This variant can be customized in several ways:

Use the optional showUser/show_user prop to show user as part of the text. When showing the user, pass in the user name using the text prop as shown. showUser/show_user is set to false by default.

Use the optional hideUpdated/hide_updated prop to hide the 'Last updated' text if needed.

Last Updated by (Updated Variant)


Use variant updated to show last updated at timestamp.

This variant can be customized using the optional showUser/show_user prop to show user as part of the text. When showing the user, pass in the user name using the text prop as shown.

showUser/show_user is set to false by default.

Last Updated by (Updated Variant) - Show Current Year


The updated variant can also be used in conjunction with the showCurrentYear/show_current_year prop to show the year even if it is the current year.

Last Updated by (Updated Variant) - Hide Date


The updated variant can also be used in conjunction with the showDate/show_date prop. This prop is set to true by default but can be set to false to hide the date.

Last Updated by (Updated Variant) - Hide Time


The updated variant can also be used in conjunction with the showTime/show_time prop. This prop is set to true by default but can be set to false to hide the time. This can also be used in conjunction with showCurrentYear/show_current_year to show the year even if it is the current year.

Unstyled


For alternative typography styles, you can pass a boolean prop called unstyled to the Timestamp kit and wrap it in any of our typography kits (Title, Body, etc.). This will allow the Timestamp kit to inherit any of our typography styles.

Weekday Stacked

Default


Compact


Variant