Skip to content

feat(editor): add Inspector.Document defaults and EmailTheming validation#3189

Open
joaopcm wants to merge 1 commit intofeat/inspector-section-componentsfrom
feat/inspector-document-defaults
Open

feat(editor): add Inspector.Document defaults and EmailTheming validation#3189
joaopcm wants to merge 1 commit intofeat/inspector-section-componentsfrom
feat/inspector-document-defaults

Conversation

@joaopcm
Copy link
Copy Markdown
Member

@joaopcm joaopcm commented Apr 6, 2026

Summary

  • Inspector.Document now renders default sections (Background + Container) when no children are passed
  • Inspector.Provider throws a clear error if EmailTheming extension is missing

Usage

// Default rendering — Background and Container sections
<Inspector.Document />

// Custom rendering — same render-props API as before
<Inspector.Document>
  {({ findStyleValue, setGlobalStyle }) => (
    <div>...</div>
  )}
</Inspector.Document>

Context

Final PR in the inspector sidebar redesign stack (PRODUCT-1739). Stacked on top of #3188 (section components).

Test plan

  • pnpm lint:fix passes
  • All 119 existing inspector tests still pass
  • children prop is now optional on Inspector.Document
  • EmailTheming validation throws at render time (fail-fast)

Summary by cubic

Adds default Background and Container sections to Inspector.Document when no children are provided, and adds a fail-fast check in Inspector.Provider for the EmailTheming extension. Supports PRODUCT-1739 (inspector sidebar redesign).

  • New Features

    • Inspector.Document renders Background + Container by default when no children are passed.
    • children is now optional; the render-props API is unchanged.
    • Inspector.Provider throws a clear error if EmailTheming is missing.
  • Migration

    • Ensure the EmailTheming extension is included in your editor setup (e.g., EmailTheming or EmailTheming.configure({...})).

Written for commit eda3861. Summary will update on new commits.

@changeset-bot
Copy link
Copy Markdown

changeset-bot bot commented Apr 6, 2026

⚠️ No Changeset found

Latest commit: eda3861

Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.

This PR includes no changesets

When changesets are added to this PR, you'll see the packages that this PR includes changesets for and the associated semver types

Click here to learn what changesets are, and how to add one.

Click here if you're a maintainer who wants to add a changeset to this PR

@vercel
Copy link
Copy Markdown
Contributor

vercel bot commented Apr 6, 2026

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
react-email Ready Ready Preview, Comment Apr 6, 2026 7:51pm
react-email-demo Ready Ready Preview, Comment Apr 6, 2026 7:51pm
react-email-examples Ready Ready Preview, Comment Apr 6, 2026 7:51pm

Request Review

@cubic-dev-ai
Copy link
Copy Markdown
Contributor

cubic-dev-ai bot commented Apr 6, 2026

This review could not be run because your cubic account has exceeded the monthly review limit. If you need help restoring access, please contact contact@cubic.dev.

@pkg-pr-new
Copy link
Copy Markdown

pkg-pr-new bot commented Apr 6, 2026

Open in StackBlitz

npm i https://pkg.pr.new/@react-email/editor@3189

commit: eda3861

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