Actions
Reminder for invoice 0142
A drawing of every sRGB colour as a solid. It is cut flat at the lightness of the accent colour, and the accent is marked on the cut. With a keyboard, change the colour with the sliders in the colour controls.
Konstruktor UI · the design system
Drag the solid. It holds every sRGB colour. This site is built on the kit, so it takes each new theme while you drag. The theme is derived in your browser by the same code as the command line, and every pair of text or control and background is measured against WCAG 2.2 AA.
Drag sideways for hue and up or down for lightness. Pull the mark for chroma. Or press any colour.
Components
These are the kit's own components, not pictures of them. Use them. They take your theme because they read tokens and nothing else. The reference has a page with examples for each of the 76 components.
Reminder for invoice 0142
The amount without tax.
| Month | Last year | This year |
|---|---|---|
| Jan | 18200 | 21400 |
| Feb | 17600 | 22900 |
| Mar | 20100 | 24800 |
| Apr | 19400 | 23600 |
| May | 21800 | 26100 |
| Jun | 22500 | 27900 |
| Jul | 19900 | 25200 |
| Aug | 16800 | 21700 |
| Sep | 23100 | 29400 |
| Oct | 24600 | 31200 |
| Nov | 25300 | 32800 |
| Dec | 27900 | 35100 |
Bank account connected
Payments appear here within a minute.
A warning keeps its own colour
When your accent comes close to it, the warning turns away.
14 documents: the claim, two replies and eleven exhibits.
Billed this year: 18 450,00 EUR.
A card on the accent surface asks for a decision. Its text and its link are measured on that surface too: see the pairs.
Recipes
The kit ships 11 recipes: complete pages to start a product from. The frame below is one of them, loaded from the reference and drawn in the theme you chose. Change the colour and it changes with the rest.
Proof
For each mode the generator measures 53 pairs of text or control and background that the components draw. The numbers below are for the theme on screen now and change as you drag. A colour whose theme has a pair under AA is never shown: the studio moves it to the nearest colour that passes, and says so.
| Pair | Light | Dark | Needs |
|---|
Contrast is the WCAG 2 ratio of the two colours. Text needs 4.5:1. The outline of a control, a focus ring and a checked control need 3:1. The check is the function checkMode in ui/tools/kui-theme-core.mjs, the same one the command line runs.
Take it
A theme is a small seed file. The stylesheet below is derived from it. It is the same text that node ui/tools/kui-theme.mjs --seed theme.json --out theme.css writes for this seed.
The theme is in the part after the # sign. That part stays in the browser and is not sent to the server.
Start
The kit is plain CSS and JavaScript: one stylesheet, one script, the fonts and the icons. It has no framework and no build step, and it loads nothing from another site.
A new product starts from the folder templates/product-web/ of the Konstruktor engine repository. Its tools/kit-update.sh copies the kit into kit/ and writes down which version it is.
<html lang="en" data-kui-theme="gold">
<link rel="stylesheet" href="kit/kui.css">
<script src="kit/kui.js" defer></script>
Add a skip link as the first element of the body.
Save the seed from this page as theme/theme.json and run the starter's tools/theme.sh. It writes the stylesheet and fails if any pair is under AA. Then build pages from the recipes and the components.