OpenParable
Skip to content
← Back to skills

Manage Scss Modules

Design
manage-scss-modules

Manage Scss Modules is an Agent Skill for design published in the telerik/kendo-themes repository on GitHub: a SKILL.md instruction file an AI agent can load to do this task.

Create or update design system foundation modules — spacing, color-system, typography, elevation, border-radii, motion, and z-index. These modules live in packages/core/scss/ and are re-exported by each theme via packages/{theme}/scss/core/. Use this skill when the user wants to add a spacing token, color constant, font size, elevation level, border-radius scale value, or animation timing.

View on GitHub ↗
QUICK START

How to use this skill

Bring this guide into your coding agent with a prompt tailored to the tool you use.

  1. Open your project in Codex.
  2. Copy and paste the prompt below.
  3. Review files and risks before approving any action.
Prompt to paste
Inspect the Agent Skill at https://github.com/telerik/kendo-themes/blob/HEAD/.github/skills/manage-scss-modules/SKILL.md and all supporting files. Report provenance, permissions, scripts, dependencies, and security risks. Propose an exact installation into .agents/skills/manage-scss-modules, but wait for my approval before writing files or running scripts.

Copying this prompt does not install or run the skill. Review third-party files before use.

SCSS Module

Create or update design system foundation modules in core and theme packages.

When to use

When the user asks to:

  • Add a new spacing token (e.g., "add a spacing step of 2.5rem")
  • Add or change a color constant or palette entry
  • Update typography tokens (font family, size, weight, line height)
  • Add or modify elevation levels (box-shadow scale)
  • Change border-radius scale values
  • Update motion/animation timing or easing
  • Add or change z-index layers

Not for component-level SCSS (use manage-scss-variables for component variables, manage-scss-styles for component layout/theme/wiring).

Module inventory

ModuleCore pathPurpose
spacingpackages/core/scss/spacing/index.scss$default-spacing map — spacing tokens (k-spacing() function)
color-systempackages/core/scss/color-system/Color constants, palettes, swatches, and functions (k-color())
typographypackages/core/scss/typography/index.scssFont families, sizes, weights, line heights
elevationpackages/core/scss/elevation/index.scssBox-shadow scale (k-elevation() function)
border-radiipackages/core/scss/border-radii/index.scssBorder-radius scale (k-border-radius() function)
motionpackages/core/scss/motion/index.scssAnimation timing, easing, and duration tokens
z-indexpackages/core/scss/z-index/index.scssStacking order layers

Theme re-exports

Each theme re-exports core modules via packages/{theme}/scss/core/. Theme-specific overrides are placed in the corresponding packages/{theme}/scss/core/{module}/ directory.

Inputs

InputRequiredDescription
ModuleYesWhich module: spacing, color-system, typography, elevation, border-radii, motion, z-index
ChangesYesWhat to add, change, or remove
Target themesNoThemes to update if theme-level overrides are needed. Usually changes are core-only.

Procedure

Step 1: Read the current module

Read the module's files in packages/core/scss/{module}/ to understand the current structure and conventions. Pay attention to:

  • How tokens are defined (maps, variables, constants)
  • SassDoc documentation patterns
  • The function API (e.g., k-spacing(), k-color(), k-elevation())

Step 2: Apply changes to core

Edit the appropriate file in packages/core/scss/{module}/.

Rules:

  • Follow the existing naming and documentation patterns in the module
  • Add SassDoc /// comments with @group annotations
  • Maintain the ordering convention (e.g., spacing values are ordered by size)
  • For color-system, respect the multi-file structure: constants in _constants.scss, palettes in _palettes.scss, functions in _functions.scss

Step 3: Apply theme overrides (if needed)

Most design system changes are core-only — themes inherit via packages/{theme}/scss/core/. Only edit theme-specific files when:

  • A theme needs a different token value (e.g., Material uses different elevation shadows)
  • A theme adds theme-specific tokens not in core
  • The swatch configuration (lib/swatches/) needs updating

Step 4: Validate

npm run lint:styles 2>&1
npm run sass 2>&1

If the change affects token functions used by components, also verify:

npm run docs 2>&1
npm run test:units 2>&1

Gotchas

  • Core modules are foundational — changes here affect every component and every theme. Be conservative.
  • Spacing map keys are not arbitrary — the $default-spacing map uses a scale (0, 0.5, 1, 1.5, 2...). New keys must fit the scale.
  • Color constants vs swatch colors — _constants.scss has immutable color values (white, black). Swatch-specific colors go in _swatch.scss or theme overrides.
  • Theme core re-exports — packages/{theme}/scss/core/_index.scss barrels all core modules. If you add a new sub-module, it needs to be forwarded there.
  • Function API stability — k-spacing(), k-color(), k-elevation(), k-border-radius() are used by hundreds of component files. Don't change function signatures.