style: remove positive letter spacing from Inter headings#780
Draft
croswell wants to merge 3 commits into
Draft
Conversation
Co-authored-by: Sam Croswell <croswell@users.noreply.github.com>
✅ Deploy Preview for pine-design-system ready!
To edit notification comments on pull requests, go to your Netlify project configuration. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
Inter headings and body copy currently inherit small positive letter spacing from the upstream
@kajabi-ui/stylesheading tokens (--pine-letter-spacing-heading-1…6, ranging.26px→.16px), which reads as too spread out. Most notably the large headings are missing the tight tracking they should have.This adds a local token override — following the existing
_motion.scsspattern — that normalizes the values without renaming any tokens:--pine-letter-spacing(body/default) →0(also cleans up the invalid upstream.16px * -1value, which browsers already ignore)--pine-letter-spacing-heading-1/-2→-0.025em(matches Tailwind'stracking-tight)--pine-letter-spacing-heading-3…-6→0The new file
libs/core/src/global/styles/_letter-spacing.scssis@used inapp.scssimmediately after the upstream import so its:rootdefinitions win. Consuming components need no changes — they inherit the updated values.pds-filter's direct use of the raw core token--pine-letter-spacing-114is intentionally left as-is.No new dependencies.
Note
This is a deliberately narrow, incremental fix. It stops the bleeding on Inter's positive tracking by overriding token values in place, without restructuring the token API. See "Follow-up" below for the more holistic work.
Follow-up (root-cause / holistic)
This PR intentionally does not tackle the following, which should be handled in a dedicated follow-up:
--pine-letter-spacing-tighter / tight / normal / wide / wider / widest) instead of the role-based--pine-letter-spacing-heading-*tokens, and repoint all consumers. This is the "at the root" cleanup and is a larger, purely-structural change (~16 SCSS files + Storybook chrome).@kajabi-ui/stylesso the override file can be deleted (the base--pine-letter-spacingvalue there is invalid CSS, and headings ship positive tracking). This override is designed to be removed in the same PR that bumps to a corrected@kajabi-ui/styles.<DocTokenTable category="letter-spacing" />reads the upstream JSON, so it still shows the old upstream values., normalfallback inlibs/core/src/utils/truncation-tooltip.ts(it guarded the previously-invalid upstream value).Before / after
Real Pine typography (Inter, correct weights/sizes) with the current upstream letter spacing (left) vs. this PR's values (right). The visible win is the tighter h1/h2; h3–h6 and body are effectively unchanged because the upstream positive tracking there was already sub-pixel/no-op.
Letter spacing before/after comparison
Zoomed in on a heading — the end-of-line markers expose the width delta (grey = before, purple = after tracking-tight):
Zoomed h1 before/after tracking-tight
Type of change
How Has This Been Tested?
Verified via the core build/lint/test targets (
@pine-ds/core:build,:lint,:test— 2906 tests passing). Confirmed the override wins in the compiledpine-core.css(our:rootblock emits after the upstream one). CSS custom-property overrides live in the global stylesheet and are not represented in Stencil spec snapshots, so existing component tests are unaffected.Checklist:
Review: The Pine gauntlet (design + existence reviewers) was run on this branch — APPROVED, no blockers or should-fix items; three CONSIDER notes (two folded into the file's comments, one is the
truncation-tooltip.tscleanup listed under Follow-up).To show artifacts inline, enable in settings.