Skip to content

Clause, a shadcn/ui preset

Lawyer blue with Montserrat, from a second legal theme. It comes from Clause, one of our website themes.

Fonts: Montserrat · radius 0.375rem · light and dark · lowest text contrast 6.51:1

npx shadcn@latest add https://www.themes.dev/r/presets/clause.json
Edit in the generator

Clause on six free blocks from themes.dev UI. Scroll inside the preview.

The colours

The main variables, light and dark. The full set of 31 per mode, sidebar and charts included, is in the CSS below.

Light

  • background#ffffff
  • foreground#152c2e
  • primary#1f509e
  • primary-foreground#ffffff
  • secondary#f6f2f3
  • muted-foreground#4a5a5c
  • accent#e7eef8
  • border#dfe4e6
  • destructive#b42318
  • ring#1f509e
  • chart-1#93c2ff
  • chart-2#6292df
  • chart-3#4a74b8
  • chart-4#355a95
  • chart-5#254477

Dark

  • background#0e1a1c
  • foreground#e6eeee
  • primary#83b8ff
  • primary-foreground#080e16
  • secondary#1d2b2d
  • muted-foreground#abbcbe
  • accent#253b3e
  • border#253a3d
  • destructive#ff9889
  • ring#b4ccf1
  • chart-1#99c5ff
  • chart-2#6e9fed
  • chart-3#5580c5
  • chart-4#3e639f
  • chart-5#2d4c80

Contrast, checked

Every pair shadcn/ui draws text with, measured as WCAG 2 contrast (AA needs 4.5:1) and APCA Lc (we ask 60 for text). Focus rings need 3:1 on the page.

WherePairLightDark
Body textforeground on background14.68:1 · Lc 10115.08:1 · Lc 95
Secondary text on the pagemuted-foreground on background7.21:1 · Lc 859.03:1 · Lc 63
Text in cardscard-foreground on card14.68:1 · Lc 10113.61:1 · Lc 93
Secondary text in cardsmuted-foreground on card7.21:1 · Lc 858.15:1 · Lc 62
Menus and popoverspopover-foreground on popover14.68:1 · Lc 10113.61:1 · Lc 93
Primary buttonsprimary-foreground on primary7.77:1 · Lc 919.46:1 · Lc 64
Links and outline accentsprimary on background7.77:1 · Lc 878.66:1 · Lc 61
Secondary buttonssecondary-foreground on secondary13.24:1 · Lc 9412.43:1 · Lc 92
Text on muted panelsmuted-foreground on muted6.51:1 · Lc 787.44:1 · Lc 61
Hovered menu itemsaccent-foreground on accent6.66:1 · Lc 767.26:1 · Lc 68
Error messagesdestructive on background6.58:1 · Lc 818.57:1 · Lc 61
Sidebarsidebar-foreground on sidebar14.18:1 · Lc 9914.01:1 · Lc 94
Sidebar active itemsidebar-primary-foreground on sidebar-primary7.77:1 · Lc 919.46:1 · Lc 64
Sidebar hoversidebar-accent-foreground on sidebar-accent13.24:1 · Lc 9412.43:1 · Lc 92
Focus ringring on background7.77:110.88:1

Use it

With the shadcn CLI, in a project set up with shadcn init:

npx shadcn@latest add https://www.themes.dev/r/presets/clause.json

Or paste the CSS into globals.css (Next.js) or your main stylesheet (Vite, Astro), replacing the :root and .dark values that are there.

Then load the font:

npm i @fontsource-variable/montserrat

The registry item: themes.dev/r/presets/clause.json. Free to use in any project.

globals.css
:root {
  --radius: 0.375rem;
  --background: oklch(1 0 0);
  --foreground: oklch(0.275 0.029 202.85);
  --card: oklch(1 0 0);
  --card-foreground: oklch(0.275 0.029 202.85);
  --popover: oklch(1 0 0);
  --popover-foreground: oklch(0.275 0.029 202.85);
  --primary: oklch(0.444 0.138 259.53);
  --primary-foreground: oklch(1 0 0);
  --secondary: oklch(0.965 0.004 0);
  --secondary-foreground: oklch(0.275 0.029 202.85);
  --muted: oklch(0.965 0.004 0);
  --muted-foreground: oklch(0.455 0.02 205.75);
  --accent: oklch(0.947 0.015 257.2);
  --accent-foreground: oklch(0.444 0.138 259.53);
  --destructive: oklch(0.5 0.182 29.51);
  --border: oklch(0.916 0.006 223.46);
  --input: oklch(0.611 0.02 209.43);
  --ring: oklch(0.444 0.138 259.53);
  --chart-1: oklch(0.804 0.1 255.34);
  --chart-2: oklch(0.66 0.127 259.53);
  --chart-3: oklch(0.56 0.116 259.53);
  --chart-4: oklch(0.47 0.105 259.53);
  --chart-5: oklch(0.39 0.094 259.53);
  --sidebar: oklch(0.988 0 0);
  --sidebar-foreground: oklch(0.275 0.029 202.85);
  --sidebar-primary: oklch(0.444 0.138 259.53);
  --sidebar-primary-foreground: oklch(1 0 0);
  --sidebar-accent: oklch(0.965 0.004 0);
  --sidebar-accent-foreground: oklch(0.275 0.029 202.85);
  --sidebar-border: oklch(0.916 0.006 223.46);
  --sidebar-ring: oklch(0.444 0.138 259.53);
}

.dark {
  --background: oklch(0.207 0.017 208.99);
  --foreground: oklch(0.943 0.009 197.01);
  --card: oklch(0.247 0.022 210.63);
  --card-foreground: oklch(0.943 0.009 197.01);
  --popover: oklch(0.247 0.022 210.63);
  --popover-foreground: oklch(0.943 0.009 197.01);
  --primary: oklch(0.773 0.117 256.12);
  --primary-foreground: oklch(0.16 0.02 256.12);
  --secondary: oklch(0.277 0.02 208.99);
  --secondary-foreground: oklch(0.943 0.009 197.01);
  --muted: oklch(0.277 0.02 208.99);
  --muted-foreground: oklch(0.783 0.019 205.29);
  --accent: oklch(0.335 0.028 206.67);
  --accent-foreground: oklch(0.84 0.058 258.96);
  --destructive: oklch(0.784 0.126 29.3);
  --border: oklch(0.332 0.027 207.15);
  --input: oklch(0.649 0.026 202.97);
  --ring: oklch(0.84 0.058 258.96);
  --chart-1: oklch(0.814 0.095 254.99);
  --chart-2: oklch(0.7 0.127 259.53);
  --chart-3: oklch(0.6 0.116 259.53);
  --chart-4: oklch(0.5 0.105 259.53);
  --chart-5: oklch(0.42 0.094 259.53);
  --sidebar: oklch(0.237 0.017 208.99);
  --sidebar-foreground: oklch(0.943 0.009 197.01);
  --sidebar-primary: oklch(0.773 0.117 256.12);
  --sidebar-primary-foreground: oklch(0.16 0.02 256.12);
  --sidebar-accent: oklch(0.277 0.02 208.99);
  --sidebar-accent-foreground: oklch(0.943 0.009 197.01);
  --sidebar-border: oklch(0.332 0.027 207.15);
  --sidebar-ring: oklch(0.84 0.058 258.96);
}

@theme inline {
  --font-sans: "Montserrat Variable", "Montserrat", ui-sans-serif, system-ui, sans-serif;
  --font-heading: "Montserrat Variable", "Montserrat", ui-sans-serif, system-ui, sans-serif;
}

The whole site

Clause started as Clause, a website theme

Clause is a complete site for Law firms and solicitors: every page, the content model and a live demo, built from the same blocks, in Astro and Next.js + Sanity. It comes with UI Pro, from €199 once, with every other theme.

More shadcn/ui presets

All 37 presets