Back

Bland

A design system for client products: designed in Figma, published as a tested React package, and rebranded from a single colour.

Bland is the design system I use to build client products. It began as a Figma UI kit and is now a tested React package, bland-ui, published on npm: 61 components on about 600 design tokens, light and dark themes designed as separate palettes, and a brand layer that rebrands every component from a single colour.

It is in use on client work today, and I maintain it as a product: versioned releases, a changelog, documentation, and tests that run on every change.

61React components in bland-ui 0.4.0
~600Design tokens, generated from 646 Figma variables
1 colourIn, and a complete brand out: 13 brand steps and 13 tinted neutrals, contrast-checked
2Themes, light and dark, each designed as its own palette
718Automated tests in two browser engines, at the 3 November audit

Try it

These components are imported from the published package, not reproduced. Change the brand colour, the theme or the typeface, and every component responds the way a project's brand file would make it respond. Each one works with the keyboard and with a screen reader.

  • Upload file
    1. I am a chat bubble9:41 AMSeen
  • Storage
  • Your trial ends in 3 days
  • 1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    27
    28
    29
    30
    1
    2
    3
    4
    5

The source is on GitHub and the package is on npm, both under the MIT License.


The problem

Every product built from a design file was being built twice.

I carried the same Figma kit across client projects, and on each one, developers rebuilt its buttons, fields and menus by eye. Values drifted between design and code, dark mode arrived late, and brand colours were hard-coded throughout the codebase, so a rebrand became a search and replace.

Bland removes the second build. Figma and code read the same values, generated from one source, and a new project starts from working, accessible components. What changes per client is only what belongs to the client: the brand colour and the typefaces.

  • One source of truth. Every value is defined once, in Figma, and generated into code.
  • Rebranding is configuration. One colour produces a complete, contrast-checked brand.
  • Accessibility and theming are structural. Keyboard support, screen reader support and dark mode are part of each component, not added afterwards.

The name states the intent: a system neutral enough to disappear behind the product it serves.


Approach

Figma first, then tokens, then components, in that order.

  • The system was complete in Figma before any code was written. 584 variables at handoff in three layers: hidden primitives, a Theme layer for light and dark, and scales for spacing, radius, sizing and motion. Every variable and component carries a description written for an engineer.
  • The handoff was a written specification. On 16 October I documented the token architecture, the rules (chief among them: no hard-coded values in component code) and every decision already settled in Figma. It became the repository's CLAUDE.md.
  • Tokens came before components. The first day of code built the token pipeline for both themes and a lint that rejects any raw value in component CSS. Only then the first component, the Button, which set the pattern for the rest.
  • Components were built in parallel. From the second day, several Claude Code sessions built components side by side, each working from the same rules. Most of the library landed in the first week.
  • Then the system around them. The brand tool, the documentation site, the page grid, the npm release, the landing page, and an agent skill that ships inside the package.

  1. 16 OctFigma kit handed off to code
  2. 17 OctToken pipeline, lint, the first component and a local docs site
  3. 18 to 20 OctMost components, built in parallel sessions
  4. 26 to 27 OctBrand override, the Brand theme page, extra colours and a chart palette
  5. 28 OctPage grid
  6. 30 Octbland-ui 0.1.0 on npm
  7. 3 NovAudit: 4.2 out of 5, 718 tests passing
  8. 17 Novblandui.com live
  9. 21 NovAgent skill and the brand command in the package
  10. 25 Nov0.4.0

Architecture

Figma defines every value. The tooling exists to carry those values into code without manual transcription, and to prove they arrived intact.

  • FigmaThe source of truth for every value and visual, read through the Figma MCP.
  • Token pipelineExports variables to CSS custom properties for both themes; a checksum proves the code matches Figma.
  • Drift checkCompares Figma with code variable by variable, and lists what a change would reach before it is applied.
  • Token lintRejects any colour, size, spacing, radius, shadow or duration that is not a token, and names the token to use.
  • React AriaKeyboard, focus and screen-reader behaviour. Floating UI positions tooltips and menus.
  • Brand toolOne colour in; 13 brand steps and 13 tinted neutrals out, with a contrast check and a correction.
  • DocumentationEvery token and component with live controls, generated props tables and search, in both themes.
  • PlaywrightScreenshot, accessibility and behaviour tests of every component, in Chromium and WebKit.

The implementation was written by Claude Code under my direction. Three logs at the root of the repository keep every session consistent with the last:

  • INTERFACE.md: every design and API decision.
  • LEARNINGS.md: every defect, recorded as symptom, cause and rule.
  • EXECUTIONS.md: what was done, including the approaches that failed.

Engineering decisions

The problems worth recording, and how each was resolved.

Corner smoothing has no CSS equivalent

Figma's 100% corner smoothing spreads each curve over twice the radius. CSS now has corner-shape: superellipse(), but only Chromium draws it. Bland doubles the radius and draws it at superellipse(2), matched against Figma by eye. Safari and Firefox fall back to plain rounding, which is an accepted trade-off.

A brand is one colour; the system needs thirteen

The steps have to hold up in light and dark, and the neutrals should lean toward the brand. The generator places the chosen colour on its own step without altering it, builds the remaining steps around it, and checks every brand pairing for contrast. Where a pairing fails, the correction moves the other steps, never the client's colour.

Dark mode is its own palette

Dark is not an inversion. Neutrals mirror, tints become deep tones, solid colours move two steps lighter, and some surfaces deliberately do not mirror: a grey page with white cards stays darker than its cards in dark mode. These rules were settled in Figma, and the pipeline carries them into code.

Safari's behaviour differs

Safari does not focus a button on click, skips links on Tab, and hides a closing popover before its exit animation runs. The tests account for each, and exit animations are driven by Bland's own closing state rather than the browser's.

A 2.3MB icon

One SVG exported from Figma had its strokes flattened into traced paths, and that single icon was two thirds of the landing page's download. Every exported SVG is now checked for size, and malformed ones are rebuilt as clean strokes.


Lessons

  • Decide in Figma, enforce in code. A rule written in a document is a request. A lint error that names the correct token is enforcement.
  • Build the token pipeline before the first component. The time it took was repaid by every component after it, and by every rebrand.
  • Record decisions as they are made. A new session reads the logs and does not repeat a resolved mistake.
  • AI accelerates implementation; decisions stay with the designer. When no token fits, a session stops and asks rather than inventing a value. The answer becomes a Figma variable and flows through the pipeline.
  • Test what review cannot see. Accessibility checks found contrast failures in the tokens, not the components, and a second browser engine found defects the first never shows.
  • Choose fallbacks deliberately. Plain rounding in Safari and the absence of right-to-left layouts are documented decisions, not surprises.

Using Bland

Bland requires React 19.
npm install bland-ui
import 'bland-ui/tokens.css';
import 'bland-ui/fonts.css';
import 'bland-ui/base.css';
import 'bland-ui/styles.css';
import './brand.css'; // the project's brand, loaded last
import { Button, TextInput } from 'bland-ui';

<TextInput label="Name" placeholder="Ada Lovelace" />
<Button emotion="brand" type="primary">Save</Button>

A project's brand is one command, or the colour can be chosen on the Brand theme page and its CSS copied:

npx bland-ui brand "#ff5a1f" --fix --out src/brand.css
  • Themes follow the system setting; data-theme="dark" on any element takes precedence.
  • Typefaces are three variables in brand.css: --font-body, --font-heading and --font-code.
  • Icons can be any SVG set. Bland sizes and colours them.
  • AI agents can use Bland correctly from the skill the package ships at node_modules/bland-ui/dist/skill.

The full reference is in the documentation.


Roadmap

  • Right-to-left layouts.
  • The token lint as a package, so client projects can enforce the same rules.
  • New components as client work requires them, beginning with submenus and non-modal sheets.