sgds-utilities-color-semantics
SGDS Color Token Suffix Semantics
Shared reference for suffix modifiers used consistently across all SGDS color utilities — background, border, and text.
Semantic Color Categories
All color utilities share the same set of semantic category names:
| Category | Meaning |
|---|---|
primary |
Brand color — emphasis, identity |
accent |
Informational / links — neutral, no urgency |
success |
Positive feedback, completion |
danger |
Errors, destructive actions |
warning |
Caution, needs attention |
purple |
Visual variety — no semantic meaning |
cyan |
Visual variety — no semantic meaning |
neutral |
Equal importance — no differentiation |
Purple and Cyan are non-semantic alternatives used for visual variety. Use them when primary and accent colors are similar and you need a third distinguishable color, or when you want alternating colors without implying priority.
Emphasis Modifiers
Applied to all semantic color tokens (primary, accent, success, danger, warning, purple, cyan, neutral):
default
Balanced, standard appearance — the baseline.
- Use for typical states and common-frequency elements
- Neither draws maximum attention nor recedes into the background
emphasis
Strong, high-visibility appearance.
- Use when the element must draw attention
- Maximum saturation/contrast within the color family
- For active states, call-to-action indicators, high-priority signals
muted
Reduced, subtle appearance.
- Use when color should be present but not dominate
- Lower saturation or lighter tint
- For secondary information, inactive states, or low-priority indicators
Emphasis progression (weakest → strongest):
muted → default → emphasis
Theme Behavior Modifiers
fixed-light
Always light — never changes with theme mode.
- The color is locked to its light-mode value regardless of the user's current theme (day or night)
- Use when a specific region must always appear on a light surface — e.g., a section with a background image that requires light borders or text
fixed-dark
Always dark — never changes with theme mode.
- The color is locked to its dark-mode value regardless of theme
- Use for regions that must always appear dark — e.g., a footer or hero that never inverts
inverse
Opposite of the current theme.
- In light (day) mode → renders as dark
- In dark (night) mode → renders as light
- Use for high-contrast elements that should visually stand out from the surrounding theme background
Transparency Modifiers
translucent
Semi-transparent — allows underlying content to show through.
- Use for hover/active state overlays on buttons or interactive elements
- Use on elements layered over images or gradients where full opacity would look harsh
transparent
Fully invisible — no visible color, but the element still occupies space.
- Use for outline-style components that need consistent sizing with their filled variants
- Maintains box model without rendering any color
Background-Specific Modifiers
These modifiers exist only in background-color tokens:
alternate
Second page-level background for creating visual rhythm.
- Alternate between
defaultandalternateacross page sections to create clear visual separation - Neither value is "primary" — they are equals used for alternation
overlay
Full-screen backdrop — never use on components.
- Exclusively for modal, drawer, and dialog backdrops
- Should always span the full viewport
surface
Component-level scope — the key distinction from page-level tokens.
- Background tokens containing
surface→ scoped to components (cards, badges, panels, inputs) - Background tokens without
surface→ scoped to page sections (body, section, full-width areas) - Border and text tokens do not use
surface— they apply at component/container level only
Background level summary:
| Token pattern | Scope |
|---|---|
sgds:bg-{color}-default |
Page level |
sgds:bg-{color}-surface-default |
Component level |
sgds:bg-surface-default |
Component (foundational, no semantic color) |
Quick Reference
| Modifier | Meaning | Changes with theme? |
|---|---|---|
default |
Standard | ✅ Yes |
emphasis |
Strong | ✅ Yes |
muted |
Subtle | ✅ Yes |
fixed-light |
Always light | ❌ No |
fixed-dark |
Always dark | ❌ No |
inverse |
Opposite theme | ✅ Yes (inverted) |
translucent |
Semi-transparent | ✅ Yes |
transparent |
Invisible | N/A |
alternate |
Section rhythm (bg only) | ✅ Yes |
overlay |
Full-screen backdrop (bg only) | ✅ Yes |
surface |
Component scope (bg only) | ✅ Yes |
See Also
- utilities-background-color — Background color utilities
- utilities-border-color — Border color, width, and radius utilities
- utilities-text-color — Text color utilities
More from govtechsg/sgds-web-component
sgds-components
Complete reference for all SGDS web components including installation and framework integration. Use when users ask about any <sgds-*> component — accordion, alert, badge, breadcrumb, button, card, checkbox, close-button, combo-box, datepicker, description-list, divider, drawer, dropdown, file-upload, footer, icon, icon-button, icon-card, icon-list, image-card, input, link, mainnav, masthead, modal, overflow-menu, pagination, progress-bar, quantity-toggle, radio, select, sidebar, sidenav, skeleton, spinner, stepper, subnav, switch, system-banner, tab, table, table-of-contents, textarea, thumbnail-card, toast, or tooltip. Also covers React 19+, React ≤18, Vue, Angular, and Next.js integration.
58sgds-theming
Customising the visual theme of an SGDS application — product brand colours, day/night mode, and font. Use when users ask about changing the primary colour, theming their app, enabling dark mode, night mode, overriding CSS tokens, or customising the font. Apply this skill whenever theming, branding, or CSS token overrides are mentioned.
55sgds-workflow
ALWAYS use this skill when building UI with @govtechsg/sgds-web-component or when a user mentions SGDS or Singapore Design System — even if they don't explicitly ask for help. This is the mandatory entry point for all SGDS development: it guides you to the right skill for setup, components, utilities, forms, theming, page layouts, block templates, and data visualisation. Read this before writing any SGDS application code.
53sgds-data-visualisation
Use this skill when users ask about data visualisation, charts, graphs, or dashboards in an SGDS application. Covers ECharts setup and applying the SGDS colour palette to charts.
53sgds-forms
Use this skill when users ask about form validation in SGDS, hasFeedback prop, constraint validation, custom validation, noValidate, setInvalid, form submission, or reading FormData from SGDS form components.
53sgds-getting-started
Starting point for any new application built with the SGDS web component library. Apply this skill first whenever a user is bootstrapping a new SGDS project, setting up a new app, or asking where to begin with SGDS. Covers font setup, foundation CSS, utilities, components, and app layout in the correct order.
53