镜像站点 · 本页由第三方 GitHub 只读镜像提供,非 GitHub 官方站点,不接受任何登录或凭据输入。前往 github.com
Skip to content

Add macOS and Win32 color token pinning tests - #4330

Merged
Jason Morse (JasonVMo) merged 2 commits into
mainfrom
user/jasonvmo/pin-win32-tokens
Sep 29, 2026
Merged

Jason Morse (JasonVMo) merged 2 commits into
mainfrom
user/jasonvmo/pin-win32-tokens

Conversation

@JasonVMo

Copy link
Copy Markdown
Contributor

Platforms Impacted

  • iOS
  • macOS
  • win32 (Office)
  • windows
  • android

Description of changes

  • Add shared test-only utilities for resolving v0 settings and v1 token layers into stable color-only snapshots.
  • Add platform-resolved macOS and Win32 pinning themes.
  • Teach the React and React Native Jest presets to discover .test.macos.ts and .test.win32.ts files.
  • Add paired macOS and Win32 token snapshots for 22 stable and experimental component packages.
  • Refresh the previously undiscovered StackUtils.test.win32.ts expectations to the current numeric spacing contract.
  • Add package-local test dependencies, TypeScript project references, Jest configuration, and a patch changeset where required.

Verification

  • yarn build — passed.
  • yarn format:check — passed.
  • yarn lage lint — passed.
  • yarn lage test — passed; 4 tasks executed and 77 package tasks reused valid cached results.
  • yarn test in packages/components/Stack — passed: 14 Win32 tests, 2 macOS tests, and 5 snapshots.
  • Focused package snapshot suites — passed for all 44 platform test files and matching snapshot files.
  • yarn lint-lockfile and dependency alignment/constraint checks — passed.
Before After
Component color tokens were not comprehensively pinned for macOS and Win32, and .test.<platform>.ts files were not discovered by the Jest presets. v0 and v1 color token trees are pinned in platform-specific snapshots across 22 packages, and the Jest presets execute the correct macOS and Win32 modules.

Pull request checklist

This PR has considered (when applicable):

  • Automated Tests
  • Documentation and examples
  • Keyboard Accessibility
  • Voiceover
  • Internationalization and Right-to-left Layouts

@github-actions

github-actions Bot commented Sep 29, 2026 •

Copy link
Copy Markdown
Contributor

Bundle size report

Tree-shaken production Metro bundles. Component costs are relative to their platform shell; shell costs are absolute.

Platform Scenario Baseline cost Current cost Cost delta Change Gzip delta Module delta
macos shell 801.3 KiB 801.3 KiB 0.0 KiB 0.00% 0.0 KiB +0
macos components-button 50.1 KiB 57.9 KiB +7.8 KiB +15.54% +2.5 KiB +17
macos components-catalog 267.3 KiB 282.9 KiB +15.5 KiB +5.82% +5.7 KiB +24
macos design-theme-state 33.3 KiB 33.7 KiB +0.4 KiB +1.34% +0.1 KiB +6
macos design-themed-root New 36.1 KiB New New New New
macos design-color-lib 7.1 KiB 7.1 KiB 0.0 KiB 0.00% 0.0 KiB +0
macos design-theme-state-legacy-source 35.3 KiB 35.8 KiB +0.4 KiB +1.26% +0.1 KiB +6
macos design-legacy-theme-from-flex 100.2 KiB 100.7 KiB +0.4 KiB +0.45% +0.1 KiB +6
windows shell 810.2 KiB 810.2 KiB 0.0 KiB 0.00% 0.0 KiB +0
windows components-button 50.0 KiB 57.7 KiB +7.7 KiB +15.39% +2.6 KiB +17
windows components-catalog 267.0 KiB 282.4 KiB +15.4 KiB +5.76% +5.7 KiB +24
windows design-theme-state 33.2 KiB 33.7 KiB +0.5 KiB +1.36% +0.1 KiB +6
windows design-themed-root New 36.0 KiB New New New New
windows design-color-lib 7.1 KiB 7.1 KiB 0.0 KiB 0.00% 0.0 KiB +0
windows design-theme-state-legacy-source 35.3 KiB 35.7 KiB +0.4 KiB +1.27% +0.1 KiB +6
windows design-legacy-theme-from-flex 100.0 KiB 100.4 KiB +0.4 KiB +0.44% +0.1 KiB +6

The job is advisory: size changes are reported but do not fail the pull request. Bundle or analysis errors still fail.


View bundle-size workflow run

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
@JasonVMo
Jason Morse (JasonVMo) added this pull request to stack #4334 September 29, 2026 16:39
@JasonVMo
Jason Morse (JasonVMo) merged commit 726912f into main Sep 29, 2026
17 checks passed
@JasonVMo
Jason Morse (JasonVMo) deleted the user/jasonvmo/pin-win32-tokens branch September 29, 2026 20:11
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.

2 participants