Skip to content

Storybook: Inline Save & Submit Canvas code example - #85766

Merged
aduth merged 1 commit into
trunkfrom
fix/storybook-inline-save-submit
Oct 29, 2026
Merged

aduth merged 1 commit into
trunkfrom
fix/storybook-inline-save-submit

Conversation

@aduth

@aduth aduth commented Oct 27, 2026 •

Copy link
Copy Markdown
Member

What?

Updates the "Save & Submit" design system Storybook pattern documentation associated story code to inline the "Save form layout card" rendered code.

Why?

So that the example is functionally usable to a reader through copyable code.

Storybook will only copy the code assigned to render, so if the example code is abstracted to a component, the only thing that a reader will see is the component abstraction, not the actual implementation. By inlining the component implementation, the full copyable code is available.

Testing Instructions

  1. Run Storybook: npm run storybook:dev
  2. Go to http://127.0.0.1:50240/?path=/docs/design-system-patterns-save-submit--docs#manual-save-model
  3. Click "Show code"
  4. Observe full code example for the modal

Screenshots or screencast

Before After
image image

Use of AI Tools

Originally drafted by Claude Code + Opus 5.5 for #84864, ported and adapted manually for reuse here.

@aduth
aduth requested a review from ciampo October 27, 2026 17:16
@github-actions

github-actions Bot commented Oct 27, 2026 •

Copy link
Copy Markdown

🤖 PR meta 🤖

Preview in WordPress Playground

🎉 Props

If you're merging code through a pull request on GitHub, copy and paste the following into the bottom of the merge commit message.

Co-authored-by: aduth <aduth@git.wordpress.org>
Co-authored-by: simison <simison@git.wordpress.org>

To understand the WordPress project's expectations around crediting contributors, please review the Contributor Attribution page in the Core Handbook.


Props Bot commands

You can trigger Props Bot actions by commenting on this PR:

  • @propsbot add <username> to give props to a GitHub user. Requires write access.
  • @propsbot remove <username> to leave a user out of the props. Requires write access.
  • @propsbot refresh to refresh this list. Adding the props-bot label works too.

Updated as activity occurs, without notifying anyone named here. Add the props-bot label to refresh.

📦 Bundle size

Size Change: 0 B

Total Size: 8.55 MB

b1227a8 Run

@aduth aduth added [Type] Developer Documentation Documentation for developers Storybook Storybook and its stories for components labels Oct 27, 2026

@simison simison left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Great! 👍

@aduth
aduth merged commit ef38cda into trunk Oct 29, 2026
87 of 89 checks passed
@aduth
aduth deleted the fix/storybook-inline-save-submit branch October 29, 2026 13:26
@github-actions github-actions Bot added this to the Gutenberg 24.4 milestone Oct 29, 2026
Vedant-Gandhi pushed a commit to Vedant-Gandhi/gutenberg that referenced this pull request Nov 30, 2026
Co-authored-by: aduth <aduth@git.wordpress.org>
Co-authored-by: simison <simison@git.wordpress.org>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Storybook Storybook and its stories for components [Type] Developer Documentation Documentation for developers

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants