@surstromming/design

Everything related to design system, including colors, typography, and spacing.
1,363
Install
npm install @surstromming/design
Latest Version:0.1.2
License:MIT
Last Updated:Oct 17, 2026
Links: GitHub  ·  npm
Maintainer: evgeniy_mnatsakanov

@surstromming/design

Design values (colors, fonts, screens, spacing) exposed as SCSS getters, plus the app-shell layout() mixin and the one CSS-emitting stylesheet, reset.scss.

Dependency graph

graph LR
  design["@surstromming/design"]

Usage

@use '@surstromming/design' as design;

.root {
  background-color: design.color(primary); // var(--primary, <light value>)
  padding: design.spacing(2);              // calc(var(--spacing, 0.25rem) * 2)
  font-family: design.font(sans);          // plain stack, not themable
  @include design.screen(md) { /* md and up */ }
}

An unknown token name fails the build. Theming overrides the custom properties under data-theme on the root.

  • reset.scss — modern reset; loads the font, puts font/background/ foreground on body. The app imports it once in main.ts; component styles must never @use it (or anything CSS-emitting — every SFC style block compiles separately and would duplicate it).
  • layout($selector, $sidebarInset) — grid-template-areas app shell over semantic direct children aside / header / main / footer. The footer is a full-width status bar row in both modes; any absent child collapses its track, so a shell without one is unchanged.

Related Packages

@surstromming/popover

Panel anchored under a trigger; closes on outside click and Escape.

1,481 0
@surstromming/dialog

Modal dialog, with an alert-dialog mode and sheets on the screen's edges.

1,382 0
@surstromming/scroll-area

A scroll container with an Edge-style overlay scrollbar.

1,157 0

Version History

Version Released License
0.1.2 MIT
0.1.1 MIT
0.1.0 MIT