Loading...
Loading...
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.
npx skill4agent add govtechsg/sgds-web-component sgds-themingthemes/day.css| What you want to change | Token / mechanism |
|---|---|
| Product brand colour (custom) | Override |
| Product brand colour (GovTech) | Import one |
| Enable dark/night mode | Import |
| Font typeface | Override |
--sgds-product-primary-*:root/* yourCustomCss.css */
:root {
--sgds-product-primary-100: #F5B6DA;
--sgds-product-primary-200: #F186C0;
--sgds-product-primary-300: #EE4FA6;
--sgds-product-primary-400: #EE0290;
--sgds-product-primary-500: #EF0078;
--sgds-product-primary-600: #DD0074;
--sgds-product-primary-700: #C6006E;
--sgds-product-primary-800: #B0006A;
--sgds-product-primary-900: #880061;
}import "@govtechsg/sgds-web-component/themes/day.css";
import "./yourCustomCss.css";@import "@govtechsg/sgds-web-component/themes/day.css";
@import "./yourCustomCss.css";--sgds-primary-*themes/gt/| File | Colour |
|---|---|
| Blue |
| Cyan |
| Magenta |
| Pink |
| Purple |
| Red |
--gt-color-100--gt-color-900:root/* yourCustomCss.css */
:root {
--sgds-product-primary-100: var(--gt-color-100);
--sgds-product-primary-200: var(--gt-color-200);
--sgds-product-primary-300: var(--gt-color-300);
--sgds-product-primary-400: var(--gt-color-400);
--sgds-product-primary-500: var(--gt-color-500);
--sgds-product-primary-600: var(--gt-color-600);
--sgds-product-primary-700: var(--gt-color-700);
--sgds-product-primary-800: var(--gt-color-800);
--sgds-product-primary-900: var(--gt-color-900);
}--gt-color-*import "@govtechsg/sgds-web-component/themes/day.css";
import "@govtechsg/sgds-web-component/themes/gt/blue.css"; // pick one colour only
import "./yourCustomCss.css";@import "@govtechsg/sgds-web-component/themes/day.css";
@import "@govtechsg/sgds-web-component/themes/gt/blue.css"; /* pick one colour only */
@import "./yourCustomCss.css";--sgds-product-primary-*themes/day.css@import "@govtechsg/sgds-web-component/themes/day.css";sgds-night-theme<html>:root.sgds-night-themethemes/night.cssimport "@govtechsg/sgds-web-component/themes/day.css";
import "@govtechsg/sgds-web-component/themes/night.css";@import "@govtechsg/sgds-web-component/themes/day.css";
@import "@govtechsg/sgds-web-component/themes/night.css";<html><html class="sgds-night-theme">document.documentElement.classList.toggle("sgds-night-theme");themes/night.cssthemes/day.css:root.sgds-night-theme--sgds-font-family-brand:root {
--sgds-font-family-brand: "Your Font", system-ui, sans-serif;
}<link>@font-facethemes/day.css--sgds-product-primary-{100–900}themes/night.csssgds-night-theme<html>themes/night.csssgds-day-theme--sgds-font-family-brand:rootthemes/gt/--gt-color-*--sgds-product-primary-*themes/day.css--gt-color-*