Skip to main content
Version: 18

Styling

The Styling card controls the colours and button radius of the white label's frontend. Colours are stored on the white label's settings.colors object as RGB values and applied throughout the application as CSS variables. Any colour left empty falls back to the Harmoney default.

A live Samples preview on the right of the card shows buttons, links, chips, toggle switches and status messages rendered with the current colours, so you can see the effect before saving.

Setting a colour​

Each colour has a square swatch. Click it to open the colour picker (RGB; transparency is disabled). A ? in the swatch means the colour is unset and the Harmoney default is in use. The × next to a swatch clears the colour back to that default. Recently used colours are remembered as presets in the picker.

Accessibility (colour contrast)​

Harmoney checks each colour's contrast against the colours it is shown on top of. When a colour does not reach the minimum WCAG AA non-text ratio of 3:1, an error icon appears next to it; hovering the icon shows the confronted colours and their measured contrast ratio.

LevelMinimum ratioApplies to
AA non-text / AA large text3:1UI components, graphical objects, large text
AA normal text4.5:1Normal body text
AAA large text4.5:1Large text (enhanced)
AAA normal text7:1Normal text (enhanced)

Colour reference​

Base​

FieldStyles
primaryPrimary brand colour
secondarySecondary brand colour
textDefault text colour
backgroundFillPage background fill

Buttons​

There are three button types — primary, secondary and tertiary — each with a background, text and border colour, in both a normal and a hover state. The field path is buttons.<type>.<part>.<state>.

Field patternStyles
buttons.<type>.background.<state>Button fill
buttons.<type>.text.<state>Button label
buttons.<type>.border.<state>Button border

For example, buttons.primary.background.hover is the primary button's fill colour while hovered.

FieldStyles
links.normalLink colour
links.hoverLink colour on hover
FieldStyles
header.fillHeader background
header.textHeader text
header.borderHeader border / separator line
FieldStyles
sidebar.primarySidebar background
sidebar.textSidebar text
sidebar.registerSidebar register section
sidebar.activeFlowstep.primaryActive flow step background
sidebar.activeFlowstep.textActive flow step text

Status messages​

FieldStyles
statusMessages.info.borderInfo status-message border
statusMessages.generic.borderGeneric status-message border

Button radius​

FieldStyles
radiusBorder radius applied to buttons. A free-text CSS value, e.g. 4px. Cleared with the × button.

Actions​

The card footer provides the following actions:

ActionEffect
SavePersists the colours and reloads the page so the changes take effect.
UndoReverts unsaved changes back to the last saved colours.
ResetResets all colours to the Harmoney system defaults.
Copy settingsCopies the current colours as JSON to the clipboard.
Import settingsOpens a modal where you can paste a colours JSON and apply it.