Skip to content

SCM - cleanup some more eslint rules#276571

Merged
lszomoru merged 1 commit intomainfrom
lszomoru/early-kingfisher
Nov 10, 2025
Merged

SCM - cleanup some more eslint rules#276571
lszomoru merged 1 commit intomainfrom
lszomoru/early-kingfisher

Conversation

@lszomoru
Copy link
Member

No description provided.

Copilot AI review requested due to automatic review settings November 10, 2025 18:52
@lszomoru lszomoru enabled auto-merge (squash) November 10, 2025 18:52
@lszomoru lszomoru self-assigned this Nov 10, 2025
@vs-code-engineering vs-code-engineering bot added this to the November 2025 milestone Nov 10, 2025
Copy link
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

This PR refactors the SCM history view to remove hacky DOM manipulation code in favor of a cleaner CSS-only solution for hiding twisties (tree expand/collapse icons).

Key changes:

  • Removes DOM traversal code that dynamically added the force-no-twistie class to tree twistie elements
  • Simplifies the CSS selector to unconditionally hide twisties for all rows in the SCM history view

Reviewed Changes

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

File Description
src/vs/workbench/contrib/scm/browser/scmHistoryViewPane.ts Removes DOM manipulation hack from two renderer classes (HistoryItemRenderer and HistoryItemLoadMoreRenderer)
src/vs/workbench/contrib/scm/browser/media/scm.css Simplifies CSS selector by removing the .force-no-twistie class requirement, making the twistie hiding unconditional for the history view

@lszomoru lszomoru added the scm General SCM compound issues label Nov 10, 2025
@lszomoru lszomoru merged commit 4d84cf6 into main Nov 10, 2025
33 of 34 checks passed
@lszomoru lszomoru deleted the lszomoru/early-kingfisher branch November 10, 2025 19:38
@bpasero
Copy link
Member

bpasero commented Nov 10, 2025

@lszomoru are you sure this change works? Notice how I even had to copy it into my new stuff:

// Hack to disable twistie in advent of on official option
// eslint-disable-next-line no-restricted-syntax
container.parentElement?.parentElement?.querySelector('.monaco-tl-twistie')?.classList.add('force-no-twistie'); // hack, but no API for hiding twistie on tree

I was not able to figure out a CSS only solution and we still have many of these hacks elsehwere:

image

Would be great if we could consolidate 🙏

Kosta-Github added a commit to Kosta-Github/vscode that referenced this pull request Nov 11, 2025
…nal-tooltips-markdown

* 'main' of https://github.com/microsoft/vscode: (56 commits)
  edits: show diff for sensitive edit confirmations (microsoft#276620)
  Enable Back button on the Manage Accounts picker (microsoft#276622)
  Ignore obsolete chat content parts when loading persisted session (microsoft#276615)
  settings cleanup (microsoft#276602)
  Remove unused `args: any` parameter
  Terminal suggest - include persistent options in suggestions and improve suggestion grouping (microsoft#276409)
  fix selections not being added (microsoft#276600)
  Embed AI search into the existing search view message (microsoft#276586)
  Cleanup some eslint exemptions (microsoft#276581)
  fix microsoft#276579 (microsoft#276590)
  SCM - cleanup some more eslint rules (microsoft#276571)
  Bump gpu types and skip lib check for gpu typing issue
  Fix in smoke tests
  Remove `forChatSessionTypeAndId`
  Fix one more import
  detect `press any/a key` and ask if user wants to send `a` to terminal (microsoft#276554)
  Filter subagent and todo tools from subagent requests (microsoft#276553)
  Expand hover setting to allow for key modifier mode (microsoft#274001)
  Allow partial monacoEnvironment.getWorker/getWorkerUrl
  Update imports
  ...
lszomoru added a commit that referenced this pull request Nov 11, 2025
lszomoru added a commit that referenced this pull request Nov 11, 2025
* Revert "SCM - cleanup some more eslint rules (#276571)"

This reverts commit 4d84cf6.

* Remove querySelector
@vs-code-engineering vs-code-engineering bot locked and limited conversation to collaborators Dec 25, 2025
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

scm General SCM compound issues

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants