Skip to content

chore: freeze themes - #2725

Merged
HerrTopi merged 1 commit into
masterfrom
test-freeze
Oct 2, 2026
Merged

HerrTopi merged 1 commit into
masterfrom
test-freeze

Conversation

@HerrTopi

@HerrTopi HerrTopi commented Sep 21, 2026 •

Copy link
Copy Markdown
Contributor

chore(many): freeze Alert and Pill v2 against design tokens v1
Alert v2 and Pill v2 now resolve their component tokens from a frozen snapshot of design
tokens v1 instead of the live theme, so their styling stays put while the shared token set
keeps moving. Both pass frozenThemesDesignTokensV1 to withStyleNew and type themeOverride
against DesignTokensV1ComponentTypes.

For a frozen component, themeOverride.components now accepts either the frozen token shape
or the current one, but rejects a mix of the two. Keys from the wrong shape used to
typecheck and then get silently ignored at runtime.

Bumps @instructure/instructure-design-tokens from v1.5.0 to v1.9.0.

@github-actions

github-actions Bot commented Sep 22, 2026 •

Copy link
Copy Markdown
Contributor
PR Preview Action v1.8.1
Preview removed because the pull request was closed.
2026-10-02 00:16 UTC

@github-actions

github-actions Bot commented Sep 22, 2026 •

Copy link
Copy Markdown
Contributor

Visual regression report

Cypress suite: ✅ Passing

Visual diff: ⚠️ Changes detected.

Status Count
Unchanged 71
Changed 28
New 0
Removed 0

Accessibility (axe): ✅ No violations.

📊 View full report — click a screenshot's ⚠ badge to see each violation boxed on the image, with the offending element named and contrast failures shown as color swatches.

Diff images (28)

alert-canvas.png — 753 pixels differ

alert-dark.png — 2385 pixels differ

alert-light.png — 2442 pixels differ

avatar-dark.png — 107 pixels differ

avatar-light.png — 107 pixels differ

badge-canvas.png — 1573 pixels differ

billboard-dark.png — 36899 pixels differ

billboard-light.png — 36841 pixels differ

colorpicker-dark.png — 50708 pixels differ

colorpicker-light.png — 39157 pixels differ

custom-icons-canvas.png — 565 pixels differ

custom-icons-dark.png — 498 pixels differ

custom-icons-light.png — 594 pixels differ

filedrop-dark.png — 6892 pixels differ

filedrop-light.png — 6957 pixels differ

heading-dark.png — 27544 pixels differ

heading-light.png — 27459 pixels differ

progressbar-canvas.png — 1661 pixels differ

progressbar-dark.png — 1672 pixels differ

progressbar-light.png — 1661 pixels differ

small-components-canvas.png — 85 pixels differ

small-components-dark.png — 319 pixels differ

small-components-light.png — 408 pixels differ

tooltip-dark.png — 84597 pixels differ

tooltip-light.png — 82455 pixels differ

view-canvas.png — 1088 pixels differ

view-dark.png — 2112 pixels differ

view-light.png — 2112 pixels differ

Baselines come from the visual-baselines branch. They refresh on every merge to master. The Cypress suite line covers the a11y and console-error assertions — a ❌ there means the suite found real issues even if the visual diff is clean.

github-actions Bot pushed a commit that referenced this pull request Sep 22, 2026
@HerrTopi
HerrTopi force-pushed the test-freeze branch 2 times, most recently from 757c81c to 97552aa Compare September 22, 2026 09:06
github-actions Bot pushed a commit that referenced this pull request Sep 22, 2026
@HerrTopi HerrTopi changed the title (chore) freeze themes chore: freeze themes Sep 22, 2026
github-actions Bot pushed a commit that referenced this pull request Sep 22, 2026
github-actions Bot pushed a commit that referenced this pull request Sep 22, 2026
github-actions Bot pushed a commit that referenced this pull request Sep 22, 2026
@HerrTopi
HerrTopi requested a review from matyasf September 22, 2026 10:31

@matyasf matyasf left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

  • in withStyleNew line 165 is a crash if frozenTheme[themeKey] does not exist the code will crash a bit later when trying to access theme.newTheme.primitives
    maybe throw an error instead of console.error in line 156?
  • A Select test is failing, I guess because of the new theme tokens? perhaps generalize that test?
    otherwise it looks good!

@matyasf
matyasf requested a review from balzss September 22, 2026 14:52
github-actions Bot pushed a commit that referenced this pull request Sep 22, 2026
@HerrTopi
HerrTopi requested a review from matyasf September 23, 2026 08:56

@joyenjoyer joyenjoyer left a comment •

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Either write a longer explanation comment or a docs page for this but otherwise looks nice

Alert v2 and Pill v2 now resolve their component tokens from a frozen snapshot of design
tokens v1 instead of the live theme, so their styling stays put while the shared token set
keeps moving. Both pass frozenThemesDesignTokensV1 to withStyleNew and type themeOverride
against DesignTokensV1ComponentTypes.

For a frozen component, themeOverride.components now accepts either the frozen token shape
or the current one, but rejects a mix of the two. Keys from the wrong shape used to
typecheck and then get silently ignored at runtime.

Bumps @instructure/instructure-design-tokens from v1.5.0 to v1.9.0.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
github-actions Bot pushed a commit that referenced this pull request Oct 1, 2026
@joyenjoyer
joyenjoyer self-requested a review October 1, 2026 09:06

@joyenjoyer joyenjoyer left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nice work

@HerrTopi
HerrTopi merged commit ae15759 into master Oct 2, 2026
9 of 10 checks passed
@HerrTopi
HerrTopi deleted the test-freeze branch October 2, 2026 00:15
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants