Colours

Choose the right colour role for the job, and learn how to read the colour tokens.

Primary is our main UI colour. It is reflected in the primary buttons, checkboxes, radio buttons, switches and other components, which makes it the most prominent colour in many components and, together with the Neutral colours, in your UI. It shows the user where to act and what is selected.

Primary colour role example showing a primary action button and selected radio button state.

When to use

  • The user’s main action in a view or step, for example the filled primary button for Save, Pay or Continue.
  • MDS components use Primary for selected and active states, for example a checked checkbox, a selected radio button or a switch that is on. The component applies it, so you don’t need to set the colour yourself.

When not to use

  • The colour is only there for decoration or to fill space. Use Neutral instead.
  • A view has several actions of equal weight. Keep one primary action and give the others a less prominent button variant.
  • The colour needs to say that something succeeded, failed or needs attention. Use a status colour instead.
  • The element needs a strong brand colour. Use Secondary instead.
  • If you are not using an MDS component, use the tokens below, not copied colour values. The values change with the brand and the theme.

Colour tokens

These are the Primary tokens, with their values for the Maersk brand in the light and dark themes.

UseLightDark
Weak border
brand_appearance_primary_weak_border-color
--mds_brand_appearance_primary_weak_border-color
rgb(212,212,212)
#D4D4D4
rgb(54,54,54)
#363636
Border
brand_appearance_primary_default_border-color
--mds_brand_appearance_primary_default_border-color
rgb(20,20,20)
#141414
rgb(255,255,255)
#FFFFFF
Weak background
brand_appearance_primary_weak_background-color
--mds_brand_appearance_primary_weak_background-color
rgb(240,240,240)
#F0F0F0
rgb(54,54,54)
#363636
Background
brand_appearance_primary_default_background-color
--mds_brand_appearance_primary_default_background-color
rgb(20,20,20)
#141414
rgb(255,255,255)
#FFFFFF
Weak on background
brand_appearance_primary_weak_on-background-color
--mds_brand_appearance_primary_weak_on-background-color
rgb(20,20,20)
#141414
rgb(240,240,240)
#F0F0F0
On background
brand_appearance_primary_default_on-background-color
--mds_brand_appearance_primary_default_on-background-color
rgb(255,255,255)
#FFFFFF
rgb(20,20,20)
#141414
Text
brand_appearance_primary_default_text-color
--mds_brand_appearance_primary_default_text-color
rgb(20,20,20)
#141414
rgb(240,240,240)
#F0F0F0
Link
brand_appearance_primary_default_link-color
--mds_brand_appearance_primary_default_link-color
rgb(0, 119, 178)
#0077B2
rgb(66,176,213)
#42B0D5

To understand what terms such as border, background, on-background, text, weak and strong mean in a token name, see Reading the colour tokens .

See also