Skip to content

Upgraded Shade Storybook to v10#27012

Merged
peterzimon merged 5 commits intomainfrom
DES-1321/shade-storybook-v10
Mar 30, 2026
Merged

Upgraded Shade Storybook to v10#27012
peterzimon merged 5 commits intomainfrom
DES-1321/shade-storybook-v10

Conversation

@peterzimon
Copy link
Copy Markdown
Contributor

ref https://linear.app/ghost/issue/DES-1321

Aligned Shade Storybook dependencies and config with Storybook 10 ESM requirements and fixed MDX provider resolution for successful static builds.
ref https://linear.app/ghost/issue/DES-1321

Added a dedicated shade path filter, setup output, and required CI job that builds Shade Storybook when relevant changes are detected.
ref https://linear.app/ghost/issue/DES-1321

Kept the Storybook 10 migration focused on local toolchain changes by removing the added CI workflow job and related path/output wiring.
@coderabbitai
Copy link
Copy Markdown
Contributor

coderabbitai bot commented Mar 30, 2026

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro

Run ID: 597c1853-c18d-4ab8-b4c2-6d4dfbf0901e

📥 Commits

Reviewing files that changed from the base of the PR and between 02fb7e6 and fd0fa36.

📒 Files selected for processing (1)
  • apps/shade/.storybook/main.tsx

Walkthrough

Storybook config for apps/shade was updated to use ESM-derived __dirname/__filename helpers. The addons entry for @storybook/addon-docs now provides mdxPluginOptions.mdxCompileOptions.providerImportSource. The viteFinal mutation was refactored to initialize config.resolve/config.build and config.build.rollupOptions when missing, handle config.resolve.alias as an array or object, remove the crypto alias, and delete config.build.rollupOptions.external. package.json upgrades Storybook packages to 10.3.3. One story import changed from @storybook/test to storybook/test.

🚥 Pre-merge checks | ✅ 3
✅ Passed checks (3 passed)
Check name Status Explanation
Title check ✅ Passed The title clearly and concisely summarizes the main change: upgrading the Shade Storybook from v9 to v10, which aligns with the overall objectives and all file modifications.
Description check ✅ Passed The description references a Linear issue ticket (DES-1321) related to updating Shade Storybook, which is directly relevant to the changeset's objective of upgrading Storybook to v10.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch DES-1321/shade-storybook-v10

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

Copy link
Copy Markdown
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

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

Actionable comments posted: 1

🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.

Inline comments:
In `@apps/shade/.storybook/main.tsx`:
- Line 42: The alias entry that maps {find: 'crypto', replacement:
require.resolve('rollup-plugin-node-builtins')} is incorrect because it points
to a Rollup plugin rather than a crypto polyfill; update that alias in the
Storybook Vite config (the alias object in apps/shade/.storybook/main.tsx) to
point to a proper polyfill such as 'crypto-browserify' (or remove the alias if
crypto is unused), e.g. replace the replacement value with
require.resolve('crypto-browserify') and ensure the polyfill is installed as a
dependency so imports of 'crypto' are resolved correctly in Storybook.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro

Run ID: d93cccf7-7a33-491b-bb42-7ca4cfa2dab8

📥 Commits

Reviewing files that changed from the base of the PR and between d5fca1c and 555e9a3.

⛔ Files ignored due to path filters (1)
  • yarn.lock is excluded by !**/yarn.lock, !**/*.lock
📒 Files selected for processing (2)
  • apps/shade/.storybook/main.tsx
  • apps/shade/package.json

@codecov
Copy link
Copy Markdown

codecov bot commented Mar 30, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 73.19%. Comparing base (d5fca1c) to head (fd0fa36).
⚠️ Report is 1 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main   #27012      +/-   ##
==========================================
- Coverage   73.20%   73.19%   -0.01%     
==========================================
  Files        1540     1540              
  Lines      121786   121786              
  Branches    14713    14710       -3     
==========================================
- Hits        89149    89141       -8     
- Misses      31627    31636       +9     
+ Partials     1010     1009       -1     
Flag Coverage Δ
admin-tests 54.37% <ø> (+0.01%) ⬆️
e2e-tests 73.19% <ø> (-0.01%) ⬇️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

ref https://linear.app/ghost/issue/DES-1321

Replaced deprecated scoped @storybook/test import with storybook/test to align with Storybook 10 package exports and avoid hoisted version fragility.
ref https://linear.app/ghost/issue/DES-1321

Removed the incorrect rollup-plugin-node-builtins alias for crypto in Storybook Vite config and cleaned up unused createRequire import.
@sonarqubecloud
Copy link
Copy Markdown

@peterzimon peterzimon enabled auto-merge (squash) March 30, 2026 11:38
@peterzimon peterzimon merged commit 9183778 into main Mar 30, 2026
38 checks passed
@peterzimon peterzimon deleted the DES-1321/shade-storybook-v10 branch March 30, 2026 12:11
cmraible pushed a commit that referenced this pull request Mar 30, 2026
ref https://linear.app/ghost/issue/DES-1321/update-shade-storybook

- Upgraded Shade Storybook to latest version so that we can utilize all the new features
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.

1 participant