feat: mode-aware entry tab extensions.#108
Merged
knightedcodemonkey merged 2 commits intonextfrom May 1, 2026
Merged
Conversation
Contributor
There was a problem hiding this comment.
Pull request overview
This PR makes the workspace “entry” tab rules aware of the current render mode (DOM vs React), and improves UX by surfacing a specific guidance error when React mode is selected with an incompatible entry tab filename.
Changes:
- Add render-mode–aware allowed entry filenames (e.g., allow
App.tsfor DOM; require.tsx/.jsx/.jsfor React) and thread this through tab shaping + rename validation. - Introduce a dedicated React entry-tab compatibility error and surface its message in the app status + preview error output.
- Refactor editor source setters into a small helper module and update Playwright tests to cover the new behavior.
Reviewed changes
Copilot reviewed 15 out of 15 changed files in this pull request and generated no comments.
Show a summary per file
| File | Description |
|---|---|
| src/modules/workspace/workspace-tab-shape.js | Pass renderMode-aware allowed entry filenames into entry-path normalization when shaping workspace tabs. |
| src/modules/workspace/workspace-tab-helpers.js | Define DOM vs React allowed entry filenames and export getAllowedEntryTabFileNames. |
| src/modules/preview/render-runtime.js | Validate React entry tab compatibility pre-render and surface the specific error message in status. |
| src/modules/preview/preview-entry-resolver.js | Add React entry-tab compatibility check + named error/message exports. |
| src/modules/diagnostics/type-diagnostics.js | Expand extension replacement regex to normalize more TS/JS variants to .tsx for typechecking. |
| src/modules/app-core/workspace-tab-mutations-controller.js | Enforce mode-aware entry tab rename rules and improve rename guidance messaging. |
| src/modules/app-core/workspace-controllers-setup.js | Wire getAllowedEntryTabFileNames + getRenderModeValue into the tab mutations controller. |
| src/modules/app-core/workspace-context-controller.js | Ensure tab shaping uses the workspace’s renderMode when applying a workspace record. |
| src/modules/app-core/source-setters.js | New helper for setJsxSource / setCssSource using editor getters (refactor). |
| src/modules/app-core/runtime-core-setup.js | Surface render-mode compatibility errors via setStatus when switching modes. |
| src/modules/app-core/app-composition-options.js | Thread setStatus + getRenderModeCompatibilityError into runtime-core setup options. |
| src/app.js | Integrate new helpers, mode compatibility checks, and runtimeCore wiring used by GitHub workflows/actions. |
| playwright/rendering-modes/core.spec.ts | Add test coverage for React mode guidance when entry tab is renamed to App.ts. |
| playwright/github-byot-ai.spec.ts | Make status assertion tolerant of Rendered after reload timing changes. |
| AGENTS.md | Document preference for const-assigned function expressions over function declarations. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
knightedcodemonkey
added a commit
that referenced
this pull request
May 2, 2026
* feat: idb infrastructure. (#63) * feat: dynamic tabs. (#64) * refactor: better accessbility for tabs. (#68) * feat: remove allow-same-origin for better security. (#69) * feat: tab reordering via drag-n-drop. (#70) * feat: explicit css imports, diagnostics per editor buffer. (#71) * feat: idb + github sync with atomic open and push to remote. (#78) * closes #73, closes #74, closes #75. * refactor: more colocation and smaller file sizes. (#79) * refactor: improvements with styles and gh syncs. (#82) * test: webkit flake. (#83) * test: address flake. (#84) * refactor: github pr context. (#85) * fix: require app in entry, hide workspaces without pat, remove star important. (#86) * feat: make idb source of truth for pr context. (#87) * fix: active pr context on reload and dedupe workspace identity. (#88) * fix: edited and push sync across reloads. (#89) * fix: properly commit tab name changes. (#90) * fix(tabs): filename edits, min-widths, scrolling, content sync. (#91) * feat: improved workspace disconnect and closed ux. (#92) * refactor: status styling and biome config. (#94) * fix(diagnostics): enforce current-editor snapshots and stale results. (#95) * fix: consistent head handling. (#96) * fix: prevent workspace overwrites. (#100) * fix(playwright): stabilize lint diagnostics waits with one-time rerun fallback. (#101) * feat: improved workspace ux and state identity separation. (#103) * fix: iframe protocol mismatch in receiver reads. (#104) * refactor: remove remaining fixed editor assumptions. (#105) * refactor: simplify PR close flow with deterministic workspace state updates (#106) * feat: mode-aware entry tab extensions. (#108) * feat: workspace status bar. (#109) * feat: tab-scoped ai chat. (#111) * refactor: better workspace drawer ux. (#112) * refactor: remove collapsible editors and update breakpoint styles. (#113) * docs: update for vnext. (#114) Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com> --------- Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com> --------- Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
No description provided.