Repository navigation
Conversation
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…udio brands Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…olor-docs Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…s' into cass-gmt-1825-color-docs
- 45 roles: the shadow-* group (key, ambient, scrim) replaces backdrop. - surface-raised is the lighter surface step, not a depth; navs and headers are surface-default, fields surface-raised. - New guidance: raised surfaces take a border-subtle hairline, floating ones add a shadow, Card is default or brand. - Brand role overrides need both attributes on one element. - Elevation: old Core's hard offset for Original Codecademy, soft shadows elsewhere. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…t pairings Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…s' into cass-gmt-1825-color-docs
… your own brand Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The older color pages (color modes, design tokens, themes, supporting dark mode, theming your app, creating a custom theme) described the old aliases and Core theme. They now cover roles, the five brand themes and building a brand with @skillsoft/gamut-brand. Code samples on other pages use roles instead of old color names, Card documents its two variants, and the site's own Starlight colors come from the Skillsoft brand's tokens.css instead of a hand-copied Core palette. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Covers the variance createTheme and gamut-styles ColorMode prefixes, the gamut-brand Style Dictionary prefix, the docs and the regenerated tokens. Co-Authored-By: Claude Haiku 5.5 <noreply@anthropic.com>
Covers the variance createTheme and gamut-styles ColorMode prefixes, the gamut-brand Style Dictionary prefix, the docs site and the regenerated tokens. Co-Authored-By: Claude Haiku 5.5 <noreply@anthropic.com>
…s' into cass-gmt-1825-color-docs # Conflicts: # .changeset/color-system-brands.md # packages/gamut-brand/src/__tests__/system.test.ts # packages/gamut-styles/scripts/build-tokens.ts # packages/gamut-styles/scripts/validate-tokens.ts # packages/gamut-styles/src/colorSystem/README.md # packages/gamut-styles/src/themes/__tests__/__snapshots__/theme.test.ts.snap # packages/gamut-styles/src/themes/__tests__/brandElevation.test.ts # packages/gamut-styles/src/themes/__tests__/theme.test.ts # packages/gamut-styles/src/themes/platform.ts # packages/gamut-styles/src/tokens/generated/tokens.css # packages/gamut-styles/src/tokens/generated/tokensCss.ts
Roboto 500 and 700 share one bold file, so the preload list had two links with the same key (the file URL), and React warned about duplicate keys. Co-Authored-By: Claude Haiku 5.5 <noreply@anthropic.com>
Roboto 500 and 700 share one bold file, so the preload list had two links with the same key (the file URL), and React warned about duplicate keys. Co-Authored-By: Claude Haiku 5.5 <noreply@anthropic.com>
The skill triaged scope-swap only. Add a color-roles section: the dry-run and real-run steps, what the warnings and color-roles: comments mean and what to do for each, the checks before calling it done, and what not to do. The description names the preset so the skill triggers on color-name work. Co-Authored-By: Claude Haiku 5.5 <noreply@anthropic.com> (cherry picked from commit 6f0e3de)
The skill triaged scope-swap only. Add a color-roles section: the dry-run and real-run steps, what the warnings and color-roles: comments mean and what to do for each, the checks before calling it done, and what not to do. The description names the preset so the skill triggers on color-name work. Co-Authored-By: Claude Haiku 5.5 <noreply@anthropic.com> (cherry picked from commit 6f0e3de)
…on and cover every preset The skill covered scope-swap only. It's now gamut-migration: a presets table, one workflow for all presets, a section per preset (scope-swap, color-roles), and a section on documenting a new preset. Renames the changeset to match. Co-Authored-By: Claude Haiku 5.5 <noreply@anthropic.com> (cherry picked from commit f5bf30b)
Co-Authored-By: Claude Haiku 5.5 <noreply@anthropic.com> (cherry picked from commit 15c7699)
…section Co-Authored-By: Claude Haiku 5.5 <noreply@anthropic.com> (cherry picked from commit 80522ce)
…on and cover every preset The skill covered scope-swap only. It's now gamut-migration: a presets table, one workflow for all presets, a section per preset (scope-swap, color-roles), and a section on documenting a new preset. Renames the changeset to match. Co-Authored-By: Claude Haiku 5.5 <noreply@anthropic.com> (cherry picked from commit f5bf30b)
…lsoft-gamut into cass-gmt-1825-color-site Co-Authored-By: Claude Haiku 5.5 <noreply@anthropic.com>
Starlight now uses the skillsoft theme's families: Skillsoft Text for body, Skillsoft Sans for accents, Roboto and Roboto Mono for system and code. The files are the same codecademy.com/gamut assets gamut-styles serves to consumers. Adds an open question in astro.config.mjs: confirm the font license allows serving these files from a public docs site before publishing. Co-Authored-By: Claude Haiku 5.5 <noreply@anthropic.com>
A disabled field fills with surface-sunken and draws its outline, label and value in action-disabled (design's update of 2026-12-01). Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…date Brings in the stack through #67 (2d73ebf) and #53 (a16e5a3): - Disabled fields fill with surface-sunken and draw their outline, label, value and chevron in action-disabled; enabled chevrons are text-default (#52 map, #54 components, DatePicker included). - border-disabled splits between border-default and action-disabled in the color-roles codemod (#53). - The color system page's role table lists disabled fields (#59), and the docs site loads the Skillsoft theme fonts (#67). Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
There was a problem hiding this comment.
🟡 Changes recommended
Video detection and dependency ownership bugs can add unnecessary peers or omit required ones for re-exports and optional dependencies, leaving runtime imports unresolved.
6 open issues
Detect named Video re-exports for peer dependencies · New Restrict video detection to Gamut Video imports · New Include optional dependencies in video peer detection · New Keep stylis in the required peer dependency guidance · New Correct the coreTheme migration guidance · New Prefix standalone gamut-brand commands with yarn · New
What changed in this PR
Moves Gamut’s documentation and site styling onto the generated color system, following the color-system documentation and component updates. The PR also expands scope-swap codemod behavior.
Changes:
- Replaces legacy color guidance with roles, brand themes, and custom-brand generation.
- Applies Skillsoft tokens to the docs site and updates component examples.
- Adds conditional Video peers, usage-aware warnings, and codemod regression coverage.
| File | Description |
|---|---|
packages/gamut/src/Badge/Badge.stories.tsx |
Uses a palette token in the custom gradient. |
packages/gamut-docs/src/styles/gamut-theme.css |
Adds token-based site colors and fonts. |
packages/gamut-docs/src/styles/gamut-core-theme.css |
Removes the legacy Core stylesheet. |
packages/gamut-docs/src/content/docs/guides/theming-your-app.md |
Documents brand selection and role-based styling. |
packages/gamut-docs/src/content/docs/guides/supporting-dark-mode.md |
Explains roles and Background’s mode selection. |
packages/gamut-docs/src/content/docs/guides/creating-a-custom-theme.md |
Documents custom-brand generation and integration. |
packages/gamut-docs/src/content/docs/getting-started/installation.md |
Updates provider defaults and theme typing. |
packages/gamut-docs/src/content/docs/getting-started/build-your-first-page.md |
Replaces legacy background examples. |
packages/gamut-docs/src/content/docs/foundations/themes.md |
Describes the five brand themes. |
packages/gamut-docs/src/content/docs/foundations/system-props/prop-groups.md |
Uses roles in color-prop examples. |
packages/gamut-docs/src/content/docs/foundations/system-props/compose-and-variants.md |
Updates the variant color example. |
packages/gamut-docs/src/content/docs/foundations/eslint-rules.md |
Updates lint examples to color roles. |
packages/gamut-docs/src/content/docs/foundations/design-tokens.md |
Explains palette, role, and shadow tokens. |
packages/gamut-docs/src/content/docs/concepts/index.md |
Links the color-system page. |
packages/gamut-docs/src/content/docs/concepts/color-system.md |
Explains generation, usage, checks, and tradeoffs. |
packages/gamut-docs/src/content/docs/concepts/color-modes.md |
Explains attribute-based modes and brands. |
packages/gamut-docs/src/content/docs/concepts/best-practices.md |
Recommends roles over legacy aliases. |
packages/gamut-docs/src/content/docs/components/data-display/bar-chart.mdx |
Removes navy-specific border wording. |
packages/gamut-docs/src/content/docs/components/containers/card.mdx |
Updates variants, shadows, and story embeds. |
packages/gamut-docs/src/content/docs/components/actions/Buttons/text-button.mdx |
Generalizes dark-background guidance. |
packages/gamut-docs/src/content/docs/components/actions/Buttons/stroke-button.mdx |
Generalizes dark-background guidance. |
packages/gamut-docs/src/content/docs/components/actions/Buttons/icon-button.mdx |
Generalizes dark-background guidance. |
packages/gamut-docs/src/content/docs/components/actions/Buttons/fill-button.mdx |
Generalizes dark-background guidance. |
packages/gamut-docs/src/content/docs/components/actions/Buttons/cta-button.mdx |
Generalizes dark-background guidance. |
packages/gamut-docs/astro.config.mjs |
Loads generated tokens and the new stylesheet. |
packages/gamut-codemods/src/video-peers.test.ts |
Tests Video detection and conditional peers. |
packages/gamut-codemods/src/transform.test.ts |
Adds idempotency checks and preset-specific fixtures. |
packages/gamut-codemods/src/presets/scope-swap/manifest.ts |
Declares conditional Video peer requirements. |
packages/gamut-codemods/src/presets/scope-swap/index.ts |
Adds preset hooks and dependency guidance. |
packages/gamut-codemods/src/presets/manifest.test.ts |
Checks peer ranges against package declarations. |
packages/gamut-codemods/src/migrations/tsconfig-dom/index.ts |
Limits DOM warnings to Gamut usage. |
packages/gamut-codemods/src/migrations/package-json/index.ts |
Adds missing required peers conditionally. |
packages/gamut-codemods/src/migrations/package-json/__testfixtures__/required-peers.output.json |
Defines expected added peers. |
packages/gamut-codemods/src/migrations/package-json/__testfixtures__/required-peers.input.json |
Adds a missing-peer input case. |
packages/gamut-codemods/src/migrations/package-json/__testfixtures__/peers.output.json |
Updates expected peer dependencies. |
packages/gamut-codemods/src/migrations/package-json/__testfixtures__/newer-than-source.output.json |
Includes peers in version-warning expectations. |
packages/gamut-codemods/src/migrations/package-json/__testfixtures__/kit.output.json |
Includes peers after kit expansion. |
packages/gamut-codemods/src/migrations/package-json/__testfixtures__/already-renamed.output.json |
Includes peers for already-renamed dependencies. |
packages/gamut-codemods/src/lib/types.ts |
Adds generic manifests and usage callbacks. |
packages/gamut-codemods/src/lib/manifest.ts |
Defines required-peer metadata. |
packages/gamut-codemods/src/lib/leftovers.ts |
Excludes generated declaration files. |
packages/gamut-codemods/src/lib/gamut-imports.ts |
Adds cached Gamut and Video detection. |
packages/gamut-codemods/src/cli.ts |
Wires usage detection and preset hooks. |
packages/gamut-codemods/README.md |
Documents peer handling and preset guidance. |
Review effort: Balanced
| const GAMUT_VIDEO_PATH = | ||
| /['"`](?:@codecademy|@skillsoft)\/gamut\/Video[\w/-]*['"`]/; | ||
| const IMPORT = | ||
| /import\s[^;]*?from\s*['"`]((?:@codecademy|@skillsoft)\/gamut[\w./-]*)['"`]/g; |
| const GAMUT_VIDEO_PATH = | ||
| /['"`](?:@codecademy|@skillsoft)\/gamut\/Video[\w/-]*['"`]/; | ||
| const IMPORT = | ||
| /import\s[^;]*?from\s*['"`]((?:@codecademy|@skillsoft)\/gamut[\w./-]*)['"`]/g; |
| if (listed(name)) continue; | ||
| if (video && !usesVideo()) continue; | ||
| const owner = ( | ||
| ['dependencies', 'peerDependencies', 'devDependencies'] as const |
| conditionalChecklist: { | ||
| 'removed:@codecademy/gamut-kit': | ||
| "gamut-kit is gone. Delete anything that reads it for versions, such as a sync-gamut-deps script. @skillsoft/gamut-styles has @emotion/cache and stylis peer dependencies, so add them if yarn warns that they aren't provided.", | ||
| "gamut-kit is gone. Delete anything that reads it for versions, such as a sync-gamut-deps script. @skillsoft/gamut-styles needs @emotion/cache, so add it if yarn warns that it isn't provided. Don't add stylis by hand: @emotion/cache brings its own copy, and a second root copy can break style inserts.", |
|
|
||
| `GamutProvider` uses `skillsoftTheme` when you don't pass one. Every theme has the same palette keys and the same roles, so they all share one type, `SkillsoftTheme`, and a component that type-checks against one works on all of them. | ||
|
|
||
| `coreTheme` is still exported, on the old color names, until the move to roles is finished. Use `originalCodecademyTheme` for new work. |
There was a problem hiding this comment.
Agreed with this comment actually
| md: `0 4px 6px ${colors['shadow-secondary']}`, | ||
| })); | ||
| ```sh | ||
| gamut-brand build src/theme/acme.brand.ts |
There was a problem hiding this comment.
I also ran into this when testing the other white-labeling PR
The docs moved from single pages into folders on behavior. Ported the site's edits onto the new files: the two-layer color explanation and --color- variables (colors), the key and ambient shadow roles (elevation), role-based color props, and the accessing-tokens example now uses a role. Co-Authored-By: Claude Haiku 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Haiku 5.5 <noreply@anthropic.com>
…-1825-color-behavior)
|
|
||
| Create `src/presets/<name>/` with a manifest and an `index.ts`, register it in `src/presets/index.ts`, and reuse migrations from `src/migrations`. | ||
|
|
||
| Then document it in the `gamut-migration` skill (`packages/gamut-agent-tools/skills/gamut-migration/SKILL.md`): a row in its Presets table and a `## Preset: <name>` section. Add the same preset to the table at the top of this README. The skill's "Adding a preset" section lists what to cover. |
There was a problem hiding this comment.
good to know, I'll update the prop name stack to include this info!
LinKCoding
left a comment
There was a problem hiding this comment.
Overall, I like the updates! I gave some suggestions for doc updates.
I think for these pages, def run it by Stacey too since she'll also be making some updates and some of the points are addressed a little in her outline too.
| @@ -17,7 +17,7 @@ import styled from '@emotion/styled'; | |||
| const Box = styled.div(css({ p: 4 })); | |||
|
|
|||
| // A semantic color, not a raw one | |||
There was a problem hiding this comment.
semantic => role-based?
that seems to be the trend in some other edits
| --- | ||
| title: Themes | ||
| description: The theme palettes available (Core, Admin, LX Studio and Platform) and their values. | ||
| description: The themes Gamut ships (Skillsoft, Original Codecademy, Admin, Platform and LX Studio) and how they relate to brands. |
There was a problem hiding this comment.
I think we could have a group discussion about shipping themes, Evan's mentioned that we might not want to support brand themes in the future -- but not sure if that was just off-the-cuff or something we should plan for
| | Theme | Brand | For | | ||
| | ------------------------- | -------------------- | --------------------------------------------------------------- | | ||
| | `skillsoftTheme` | `skillsoft` | The default. Replaces `percipioTheme` | | ||
| | `originalCodecademyTheme` | `originalCodecademy` | Codecademy's public-facing product, rebuilt from the Core theme | |
There was a problem hiding this comment.
I was wondering about the naming -- I thought the basis of this was because coreTheme was still around or that maybe codecademy was being played around with still.
could this just be codecademyTheme?
There was a problem hiding this comment.
will note - that one thing that threw me off about Alert was that it's no longer Codecademy themed, it has some of the SkillsoftTheme colors now, esp for light mode.
|
|
||
| `GamutProvider` uses `skillsoftTheme` when you don't pass one. Every theme has the same palette keys and the same roles, so they all share one type, `SkillsoftTheme`, and a component that type-checks against one works on all of them. | ||
|
|
||
| `coreTheme` is still exported, on the old color names, until the move to roles is finished. Use `originalCodecademyTheme` for new work. |
There was a problem hiding this comment.
Agreed with this comment actually
| ## When to reach for this | ||
|
|
||
| Most apps should [choose an existing theme](/guides/theming-your-app/) rather than build a new one — reach for a custom theme only for a genuinely new product surface that doesn't fit Core, Admin, LX Studio or Platform. | ||
| Most apps should [choose an existing theme](/guides/theming-your-app/). Build your own only when a product needs its own colors, for example to white-label Gamut for a customer. |
There was a problem hiding this comment.
Would the audience always know what it means to "white-label"?
If not, maybe a link to an explanation would cut it
|
|
||
| export default defineBrand({ | ||
| ...skillsoftBrand, | ||
| name: 'acme', |
There was a problem hiding this comment.
consider replacing 'acme' with something even more generic - like 'customerBrandName'?
| md: `0 4px 6px ${colors['shadow-secondary']}`, | ||
| })); | ||
| ```sh | ||
| gamut-brand build src/theme/acme.brand.ts |
There was a problem hiding this comment.
I also ran into this when testing the other white-labeling PR
| gamut-brand build src/theme/acme.brand.ts | ||
| ``` | ||
|
|
||
| This writes `src/theme/acme/`: |
There was a problem hiding this comment.
same note about generic company name, but will stop commenting about this after this line.
| ## Checking your work | ||
|
|
||
| Toggle color mode with Storybook's Color Mode selector while reviewing a component or page — a component built entirely from semantic aliases and system props should need no other changes to read correctly in both modes. If something looks wrong in one mode only, that's usually a raw color value that should have been a semantic alias instead. | ||
| Toggle color mode with Storybook's Color Mode selector while reviewing a component or page. A component built entirely from roles and system props should need no other changes to read correctly in both modes. If something looks wrong in one mode only, it's usually a palette color or a raw value that should have been a role. A palette color, such as `palette-neutral-light-100`, is the same in every mode, so it doesn't change when the mode does. |
There was a problem hiding this comment.
Maybe a link to a Storybook page would be helpful here.


Overview
Moves the rest of the gamut-docs site onto the generated color system. #59 added the Color system page; the older pages still described the old aliases (
text,background,primary), the Core theme and palette names likenavyandbeige. This is the last PR in the color stack.Pages rewritten
concepts/color-modes.md: roles instead of aliases, modes asdata-color-modeattributes, and how a brand and a mode combine.foundations/themes.md: the five brand themes,skillsoftThemeas the default, the sharedSkillsoftThemetype, andcoreThemekept only until the move to roles is done.foundations/design-tokens.md: roles vs palette colors,--color-*custom properties, and elevation drawn inshadow-keyandshadow-ambient.guides/supporting-dark-mode.md: roles, andBackgroundchoosing its content mode from the build-time table.guides/theming-your-app.md: passing a brand theme toGamutProvider, with role-based samples.guides/creating-a-custom-theme.md: replaces the hand-builtcreateThemepalette with building a brand with@skillsoft/gamut-brand. It coversdefineBrand, overrides, the CLI (--watchand--check),createBrandTheme, types and previewing in Storybook. The override example was run throughgenerateBrandand passes.Smaller fixes
SkillsoftThemefor the Emotion theme type), build your first page, prop groups, compose and variants, best practices and the ESLint rule examples.components/containers/card.mdxdocumentsdefaultandbrand, which replace the color variants, and the interactive shadow. Its story embeds pointed atatoms-card--*ids that no longer exist; they now usecontainers-card--*.concepts/color-system.mddrops its note that Color modes still describes the old names.The site's own colors
src/styles/gamut-core-theme.csshand-copied old Core's navy, hyper and beige into Starlight's variables. It's nowgamut-theme.css, and loads@skillsoft/gamut-styles/tokens.cssfirst. Each Starlight variable points at the palette color its Gamut role uses in that mode, so the site follows the Skillsoft brand.Starlight switches modes with
data-theme, notdata-color-mode, so the roles' mode blocks don't apply and the mapping is per mode in the file. Starlight's cascade layers come after Gamut's, so its owncolor-schemeand base styles still win.Not in this PR
percipioas a--themevalue. That's the plugin's own flag, so it changes with the plugin.Stacked on #63, with #59 merged in.
PR Checklist
Testing Instructions
npx nx build gamut-docs: 154 pages build.npx nx dev gamut-docs, then switch the site between light and dark. The chrome uses Skillsoft's paper, navy and blue instead of Core's beige, navy and violet.text,background,primary,navy,beigeorhyperas colors.🤖 Generated with Claude Code