Arbitrary Rhythm Multiplier
Error:
[ERR_ARBITRARY_RHYTHM_MULTIPLIER] Found arbitrary decimal multiplier on "var(--space)". Use canonical rhythm tokens (--space-half, --trim, --space-d*) instead of floating-point multipliers.
The Problem
A stylesheet, Astro component, or Svelte view applies an arbitrary floating-point decimal multiplier directly to var(--space) (the baseline rhythm unit 1rlh):
/* Problematic: Off-grid floating multipliers */
.panel-head {
min-height: calc(var(--space) * 1.45);
}
.panel-group {
height: calc(var(--space) * 0.85);
}
.item {
min-height: calc(var(--space) * 1.1);
}
The Why
In the Standard framework, --space is not an arbitrary pixel value: it is the baseline rhythm unit (--baseline, set to 1rlh). It defines the vertical cadence of every paragraph, heading, list item, and layout block.
When a developer writes calc(var(--space) * 1.45) or calc(var(--space) * 0.85):
- Broken Cadence: Fractional decimal multipliers fall outside the baseline grid. Neighboring UI elements (e.g. an edge trigger button and an inner header) end up separated by fractional sub-pixel differences that fail to align.
- Theme Fragility: When theme typography changes font-size, line-height, or density, arbitrary decimal fractions produce unpredicted rounding artifacts.
- Redundant Nudging: Standard already provides an exact mathematical scale of rhythm subdivisions and typographic optical trims:
--space-half: Official half-step baseline (calc(var(--baseline) / 2)).--space-d1through--space-d12: Harmonic baseline division steps (e.g.--space-d4= quarter step,--space-d2= half step).--trim: Optical half-leading box trim (calc(var(--leading) / 2)).--leading: Interline space beyond font cap-height.--space-1through--space-12: Integer harmonic multipliers.
The Solution
Never multiply --space by arbitrary decimals. Compose canonical rhythm intervals using addition or subtraction:
1. One and a Half Steps (1.5x)
Use --space plus --space-half:
/* Correct: 1.5 rhythm steps */
min-height: calc(var(--space) + var(--space-half));
2. Baseline with Optical Trim (~1.1x)
Use --space plus the typography box trim:
/* Correct: Baseline with optical clearance */
min-height: calc(var(--space) + var(--trim));
3. Compact Group Header (~0.85x)
Use --space minus the optical trim:
/* Correct: Trimmed baseline box */
height: calc(var(--space) - var(--trim));
4. Quarter Step Increments (1.25x, 2.75x)
Compose with integer steps, --space-half, and --space-d4:
/* 1.25x: One step plus a quarter step */
right: calc(var(--space) + var(--space-d4));
/* 2.75x: Two steps, half step, and quarter step */
--panel-rail: calc(var(--space-2) + var(--space-half) + var(--space-d4));