The UI language beyond the package reference
The source audit, experimental grammar, contents/sidebar distinction, independent footer anatomy, interaction obligations and framework support now have a consolidated language reference. That reference retains its original grammar-review versions and maturity labels; the package versions reported on this page identify this website’s installed dependencies separately.
Choose what to adopt
For colors or styles in any web project, install the core. Add Astro for native layouts, React for interactive components, or use the Jekyll source templates. Choose the framework that fits your application; each consumes Core’s visual rules.
| Implementation | Release | Use it for |
|---|---|---|
| Core | 3.0.1 | Tokens, fonts and shared visual rules |
| Astro | 3.0.0 | Native layouts and components |
| React | 1.0.1 | Interactive React 19 components |
| Jekyll | 2.0.0 | Source templates with synchronized Core assets |
Core owns the visual rules. Each framework supplies its native markup and behavior. The references share 50 canonical examples, dashboard applications and a scientific workspace, with representative data and simulated operations.
npm install @krigsvold/core@3.0.1| Import | Effect |
|---|---|
@krigsvold/core/css | Light and Dark semantic color variables only. |
@krigsvold/core/foundation.css | Namespaced typography, spacing, shape, depth, and interaction variables. |
@krigsvold/core/typography.css | Text styles inside .krigsvold; requires foundation variables. |
@krigsvold/core/components.css | Optional interface primitives; requires color and foundation variables. |
@krigsvold/core/fonts.css | Local font assets through the package’s pinned Fontsource dependencies. |
@krigsvold/core/full.css | Colors, foundation, typography, components, layouts, patterns and forms. Load fonts separately. |
@krigsvold/core/krigsvold.css | Canonical complete website and Astro/Jekyll reference stylesheet. |
@krigsvold/core/react.css | Canonical React visual rules, loaded by the React package stylesheet. |
import '@krigsvold/core/full.css';
import '@krigsvold/core/fonts.css';<section class="krigsvold" data-krigsvold="dark">
<h2>Your content</h2>
</section>Color scopes can coexist on a page. Add class="krigsvold" to opt into typography and component styling. The core also exports ESM, CommonJS, TypeScript declarations, per-mode JSON, and highlight.js styles. The color reference shows both semantic palettes. Use purpose-based roles such as --krigsvold-text, --krigsvold-bg, and --krigsvold-on-accent together; source colors and semantic roles serve different purposes.
Typography
| Role | Family and weights | Use |
|---|---|---|
--krigsvold-font-serif | Roboto Slab 400, 700 | Editorial headings, ledes, quotations |
--krigsvold-font-display | Roboto Slab 400, 700 | Hero and page titles, section headings |
--krigsvold-font-sans | Roboto 400, 500, 700 | Body prose, navigation, controls, tables, metadata |
--krigsvold-font-mono | Roboto Mono 400, 500, 700 | Code, terminal text, keyboard notation |
Display and serif are separate roles even where they use the same family. Monospace changes affect code and terminal roles. Optional font loading uses locally bundled open-source assets; Berkeley Mono is a personal licensed override and is not distributed.
Foundation tokens
These are the installed core’s exact defaults, including text sizes, line heights, spacing, widths, corners, shadows, focus dimensions, and motion. Responsive expressions are preserved as CSS values. Breakpoint tokens, where present, document the scale; ordinary CSS custom properties cannot be substituted directly into media-query conditions.
| CSS variable | Default |
|---|---|
--krigsvold-color-navy-950 | #061325 |
--krigsvold-color-navy-900 | #0a1d35 |
--krigsvold-color-navy-800 | #123456 |
--krigsvold-color-blue-600 | #286a9d |
--krigsvold-color-ice-400 | #9ed5e6 |
--krigsvold-color-ice-200 | #d9eef4 |
--krigsvold-color-ice-100 | #eef8fa |
--krigsvold-color-paper | #fbfaf7 |
--krigsvold-color-ink | #17202a |
--krigsvold-color-muted | #56616c |
--krigsvold-color-rule | #d9dee2 |
--krigsvold-color-gold | #b58a3b |
--krigsvold-font-serif | 'Roboto Slab', Georgia, serif |
--krigsvold-font-display | 'Roboto Slab', Georgia, serif |
--krigsvold-font-sans | 'Roboto', Arial, sans-serif |
--krigsvold-font-mono | 'Roboto Mono', ui-monospace, SFMono-Regular, Menlo, Consolas, monospace |
--krigsvold-space-1 | .25rem |
--krigsvold-space-2 | .5rem |
--krigsvold-space-3 | .75rem |
--krigsvold-space-4 | 1rem |
--krigsvold-space-6 | 1.5rem |
--krigsvold-space-8 | 2rem |
--krigsvold-space-12 | 3rem |
--krigsvold-space-16 | 4rem |
--krigsvold-space-24 | 6rem |
--krigsvold-reading-width | 760px |
--krigsvold-content-width | 1320px |
--krigsvold-archive-width | 1320px |
--krigsvold-radius-sm | .15rem |
--krigsvold-radius-md | .3rem |
--krigsvold-radius-lg | .4rem |
--krigsvold-radius-control | .15rem |
--krigsvold-radius-card | 0 |
--krigsvold-shadow-sm | 0 10px 35px rgb(0 0 0 / 12%) |
--krigsvold-shadow-md | 0 18px 44px rgb(6 19 37 / 18%) |
--krigsvold-shadow-lg | 0 24px 65px rgb(10 29 53 / 12%) |
--krigsvold-shadow-card | none |
--krigsvold-transition-ui | .15s ease-in |
--krigsvold-motion-duration | .15s |
--krigsvold-text-body | 1.06rem |
--krigsvold-text-h1 | clamp(2.8rem, 6vw, 5.5rem) |
--krigsvold-text-h2 | 2.1rem |
--krigsvold-text-h3 | 1.42rem |
--krigsvold-text-display | clamp(3.4rem, 7vw, 6.8rem) |
--krigsvold-text-section | clamp(2rem, 4vw, 3.5rem) |
--krigsvold-leading-body | 1.65 |
--krigsvold-leading-heading | 1.13 |
--krigsvold-leading-display | .98 |
--krigsvold-weight-heading | 700 |
--krigsvold-tracking-heading | -.025em |
--krigsvold-tracking-display | -.045em |
--krigsvold-tracking-label | .16em |
--krigsvold-tracking-button | .035em |
--krigsvold-border-width | 1px |
--krigsvold-focus-width | 3px |
--krigsvold-focus-gap | 3px |
--krigsvold-gutter | .75rem |
--krigsvold-section-space | clamp(4.5rem, 8vw, 7.5rem) |
--krigsvold-control-height | 2.75rem |
--krigsvold-control-padding | .9rem |
--krigsvold-button-padding | .625rem 1.5rem |
--krigsvold-text-button | .75rem |
--krigsvold-leading-button | 1.667 |
--krigsvold-divider-width | 3rem |
--krigsvold-divider-thickness | 3px |
--krigsvold-link-underline-offset | .18em |
--krigsvold-hero-overlay | linear-gradient(90deg, rgba(3,15,30,.93) 0%, rgba(6,27,51,.76) 52%, rgba(7,28,48,.42) 100%) |
--krigsvold-breakpoint-sm | 576px |
--krigsvold-breakpoint-md | 768px |
--krigsvold-breakpoint-lg | 992px |
--krigsvold-breakpoint-xl | 1200px |
--krigsvold-breakpoint-xxl | 1400px |
--krigsvold-layout-gap | 2rem |
--krigsvold-layout-gap-small | 1rem |
--krigsvold-layout-gap-large | 3rem |
--krigsvold-layout-sidebar-width | 20rem |
--krigsvold-layout-main-min | 30rem |
--krigsvold-layout-grid-min | 20rem |
--krigsvold-layout-split-min | 22rem |
--krigsvold-layout-section-space | clamp(4.5rem, 8vw, 7.5rem) |
Source provenance: basuhoward/krigsvold.org at e92e989. The JSON specification also includes grouped design definitions, both semantic color modes, and host capabilities.
Layout compositions
The installed layout system supplies stacks, wrapping clusters, bounded grids, sidebars and split regions, plus article, landing and documentation compositions. Explore the working layout gallery, or the complete independent Astro reference for the canonical page recipes.
Astro components and starter
The installed wrapper supports astro ^5.14.0 || ^6.0.0 || ^7.0.0 with @krigsvold/core ^3.0.0. Install the published packages together; historical theme releases remain available for existing consumers:
npm install @krigsvold/core@3.0.1 @krigsvold/astro@3.0.0 astro---
import { Layout, Container, SectionHeading, Card, Button } from '@krigsvold/astro';
---
<Layout title="Your website" mode="light">
<Container width="reading">
<h1>Your own identity</h1>
<SectionHeading title="Start here" />
<Card>
<p>Your content, using shared design definitions.</p>
<Button href={import.meta.env.BASE_URL.replace(//?$/, '/') + 'about/'}>About</Button>
</Card>
</Container>
</Layout>| Component | Contract |
|---|---|
Layout | Required title; optional description, lang, mode, mainId, mainTabindex, class, bodyClass, and skipLabel. Defaults to Light. Slots: head, header, footer, and body-end. Includes a skip link and the core styles and fonts. |
Container | width selects content, reading, or archive; content is the default. Accepts class and a default content slot. |
SectionHeading | Required title. Optional id, eyebrow, description, level (h2 or h3), align (left or center), and class hooks. Includes default and divider slots. |
Card | An article wrapper with a class hook and a default content slot. |
Button | With href, renders a link. Otherwise renders a button, defaulting to type="button". Accepts native attributes, including disabled on buttons, and a default content slot. |
Import components from @krigsvold/astro or use direct paths such as @krigsvold/astro/Card.astro. To retain your own document shell, import @krigsvold/astro/styles.css and apply the core’s class and appearance attributes.
Start a new site
Clone the separate Astro starter repository, then install its dependencies. The component package contains the reusable layouts and controls.
git clone https://github.com/krigsvolddesign/astro-starter.git my-krigsvold-site
cd my-krigsvold-site
npm install
npm run devThe starter currently uses Astro 7, so use Node 24 or another runtime supported by that Astro release. The starter supplies initial files; the packages supply updates afterward. Replace the sample content and metadata with your own.
Interaction and accessibility
The optional core components provide hover, disabled, and visible keyboard-focus styling. Motion tokens reduce to zero when prefers-reduced-motion: reduce is active. Use native links for navigation and native buttons for actions; retain labels, heading order, and the document skip link.
Pair foreground and background tokens deliberately. Existing contrast checks cover defined pairs, not every possible combination or application. Check normal, hover, focus, and disabled states in both appearances, with enlarged text, narrow viewports, keyboard navigation, and reduced motion. Use labels or symbols as well as color to communicate status.
Layouts and components supply primitives. Menus, dialogs, consent controls, analytics, and their behavior remain the responsibility of the consuming site. A themed page still needs application-level accessibility review.
What each integration applies
| Integration | Applied | Optional or host-specific |
|---|---|---|
| web-core | colors, typography variables, spacing, shape, depth, interaction variables, layout primitives | Optional: font loading, element typography, components. |
| astro | web-core, document shell, container, section heading, card, button, page header, site header, site footer, article layout, landing layout, documentation layout | Site-owned: navigation, content, consent, analytics, personal identity. |
| vim | colors, syntax | Configure separately: monospace font. Outside this integration: web layout, proportional typography. |
| emacs | colors, syntax | Configure separately: font roles. Outside this integration: web layout. |
| terminal | colors | Configure separately: monospace font. Outside this integration: web layout, serif, sans. |
| firefox | browser chrome colors | Outside this integration: fonts, website content, spacing, components. |
| chrome | browser chrome colors | Outside this integration: fonts, website content, spacing, components. |
Browser themes apply browser interface colors. Editor and terminal ports map the roles their hosts support. They do not all reproduce a web layout or change typography automatically.
Customization and releases
Moving to the current releases
Core 3 replaces the canonical reference.css export with krigsvold.css. Upgrade Astro to 3 with Core 3. React 1 keeps its public styles.css import and delegates styling to Core. Jekyll 2 includes synchronized Core 3 assets. Remove copied framework CSS and follow the Astro migration notes and each package’s changelog.
Override namespaced variables within your own site scope, loaded after the package styles. This changes your installation without creating another authoritative copy of the theme.
.my-site {
--krigsvold-reading-width: 44rem;
--krigsvold-font-mono: 'Your licensed font', monospace;
}Core, Astro, React and Jekyll are versioned independently. Their current 3 / 3 / 1 / 2 version numbers reflect different public contracts; they need not match. The release policy is semantic versioning: compatible fixes are patches, compatible additions are minor releases, and breaking changes to exports, tokens, component APIs, or documented behavior require a major release. Keep a lockfile and review updates against your application. This website pins the versions shown above; the reference changes when those pins change.
Propose shared visual changes in the core repository, with corresponding documentation and verification. Theme software uses the MIT license; fonts retain their bundled license notices. Heraldic artwork, personal identity, and site content are separate from the reusable design system.
