Skip to content

Add configuration options for modal editor dimensions#306882

Open
mrleemurray wants to merge 5 commits intomainfrom
mrleemurray/obnoxious-lime-buzzard
Open

Add configuration options for modal editor dimensions#306882
mrleemurray wants to merge 5 commits intomainfrom
mrleemurray/obnoxious-lime-buzzard

Conversation

@mrleemurray
Copy link
Copy Markdown
Contributor

@mrleemurray mrleemurray commented Mar 31, 2026

Introduce configuration options for setting minimum width and height of the modal editor overlay. Refactor existing code to utilize these new settings, ensuring a more flexible and customizable user experience.

Before
image

After
image

Copilot AI review requested due to automatic review settings March 31, 2026 17:43
@mrleemurray mrleemurray self-assigned this Mar 31, 2026
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

Adds configurable minimum dimensions for the modal editor overlay and wires them into the modal editor sizing logic, with tailored defaults for the Sessions window experience.

Changes:

  • Registers new settings: workbench.editor.modalMinWidth and workbench.editor.modalMinHeight.
  • Refactors ModalEditorPart to derive minimum sizing constraints from configuration (and to use the width value for sidebar clamping).
  • Overrides default values for these settings in the Sessions window default configuration.

Reviewed changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated 2 comments.

File Description
src/vs/workbench/browser/workbench.contribution.ts Adds configuration schema entries for modal min width/height.
src/vs/workbench/browser/parts/editor/modalEditorPart.ts Uses the new configuration values to set modal min size and sidebar resizing limits.
src/vs/sessions/contrib/configuration/browser/configuration.contribution.ts Sets Sessions window defaults for the new modal sizing settings.

mrleemurray and others added 2 commits March 31, 2026 18:47
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
@mrleemurray mrleemurray marked this pull request as ready for review March 31, 2026 18:23
@vs-code-engineering
Copy link
Copy Markdown
Contributor

📬 CODENOTIFY

The following users are being notified based on files changed in this PR:

@bpasero

Matched files:

  • src/vs/workbench/browser/parts/editor/modalEditorPart.ts
  • src/vs/workbench/browser/workbench.contribution.ts

Copy link
Copy Markdown
Member

@bpasero bpasero left a comment

Choose a reason for hiding this comment

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

I do not understand the need for this, esp. why a user should configure this. An editor should be able to declare its preferred min width (we already have that infrastructure in place) and then the modal editor respecting that.

Lets not do this for now, lets focus on P0s.

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.

4 participants