Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Suggestion (all lists?) styles are different in notebook #93475

Closed
jrieken opened this issue Mar 26, 2020 · 2 comments
Closed

Suggestion (all lists?) styles are different in notebook #93475

jrieken opened this issue Mar 26, 2020 · 2 comments
Assignees
Labels
bug Issue identified by VS Code Team member as probable bug notebook verified Verification succeeded
Milestone

Comments

@jrieken
Copy link
Member

jrieken commented Mar 26, 2020

See attached screen shots: Upper is notebook, lower is editor. The styles are very different, e.g

  • background color
  • no hover color
  • selection color

Screenshot 2020-03-26 at 11 01 03

Screenshot 2020-03-26 at 11 01 21

@jrieken jrieken self-assigned this Mar 26, 2020
@jrieken
Copy link
Member Author

jrieken commented Mar 26, 2020

This happens because of these overwrite styles. Not sure why they bleed into the suggest widget (and other lists/trees, like peek references)

@rebornix rebornix added this to the March 2020 milestone Mar 26, 2020
@rebornix
Copy link
Member

rebornix commented Mar 26, 2020

The styler for list view only protects itself from leaking to list views externally, for all nested list views, they are all affected by the styler.

For example, the default styler used by the ListWidget will inject following style

`.monaco-list${suffix}:focus .monaco-list-row.focused { color: ${styles.listFocusForeground}; }`

As you can see from above, any .monaco-list-row inside .monaco-list${suffix} will inherit this rule.

IMHO the rule should be as restrict as

`.monaco-list${suffix}:focus > div.monaco-scrollable-element > .monaco-list-rows > .monaco-list-row.focused { color: ${styles.listFocusForeground}; }`

but I'm not confident to push this change to ListWidget, I'm sure it will break tons of list view which accidentally rely this loose rule. As a workaround, I plugin our own Styler for NotebookCellList, which only applies the CSS rules on the root list.

// @joaomoreno , @roblourens

@rebornix rebornix added the bug Issue identified by VS Code Team member as probable bug label Mar 26, 2020
@jrieken jrieken added the verified Verification succeeded label Apr 2, 2020
@github-actions github-actions bot locked and limited conversation to collaborators May 11, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
bug Issue identified by VS Code Team member as probable bug notebook verified Verification succeeded
Projects
None yet
Development

No branches or pull requests

2 participants