Skip to content

fix(visual-editing-standalone): drop types condition for styles.css - #3632

Open
stipsan wants to merge 2 commits into
mainfrom
cursor/simplify-styles-css-copy-3280
Open

fix(visual-editing-standalone): drop types condition for styles.css#3632
stipsan wants to merge 2 commits into
mainfrom
cursor/simplify-styles-css-copy-3280

Conversation

@stipsan

@stipsan stipsan commented Aug 13, 2026

Copy link
Copy Markdown
Member

Follow-up to #3630 that tried to drop the types condition on ./styles.css, keeping only the sibling dist/styles.css.d.ts.

That does not type-check. Through package.json "exports", TypeScript does not pick up styles.css.d.ts next to the stylesheet. pnpm lint (oxlint) and tsc fail with:

error TS2307: Cannot find module '@sanity/visual-editing-standalone/styles.css'

The last commit restores the types condition from #3630 so CI can pass. Net diff vs main is empty — this PR should be closed rather than merged. #3630 is the working fix.

Open in Web Open in Cursor 

The sibling dist/styles.css.d.ts is enough for TypeScript to type the
plain string ./styles.css export. Restore css.exports: true and drop
the customExports wrapper.

Co-authored-by: Cody Olsen <stipsan@users.noreply.github.com>
@changeset-bot

changeset-bot Bot commented Aug 13, 2026

Copy link
Copy Markdown

⚠️ No Changeset found

Latest commit: fc79bd4

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

vercel Bot commented Aug 13, 2026

Copy link
Copy Markdown

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

Project Deployment Actions Updated (UTC)
live-visual-editing-next Ready Ready Preview Aug 13, 2026 4:25pm
visual-editing-storybook Ready Ready Preview Aug 13, 2026 4:25pm
9 Skipped Deployments
Project Deployment Actions Updated (UTC)
visual-editing-astro Ignored Ignored Aug 13, 2026 4:25pm
visual-editing-next Ignored Ignored Preview Aug 13, 2026 4:25pm
visual-editing-next-with-i18n Ignored Ignored Aug 13, 2026 4:25pm
visual-editing-nuxt Ignored Ignored Aug 13, 2026 4:25pm
visual-editing-page-builder-demo Ignored Ignored Preview Aug 13, 2026 4:25pm
visual-editing-page-builder-vite Ignored Ignored Aug 13, 2026 4:25pm
visual-editing-remix Ignored Ignored Aug 13, 2026 4:25pm
visual-editing-studio Ignored Ignored Preview Aug 13, 2026 4:25pm
visual-editing-svelte Ignored Ignored Aug 13, 2026 4:25pm

Request Review

A sibling dist/styles.css.d.ts types relative CSS imports, not package
exports subpaths. Without a types condition, tsc and oxlint fail with
TS2307 on import '@sanity/visual-editing-standalone/styles.css'.

Co-authored-by: Cody Olsen <stipsan@users.noreply.github.com>

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Copilot wasn't able to review any files in this pull request.


💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

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