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

Move css rules from selections.ts to selections.css #166407

Merged

Conversation

jkei0
Copy link
Contributor

@jkei0 jkei0 commented Nov 15, 2022

Issue - #165169

  • src/vs/editor/browser/viewParts/selections/selections.ts

@jkei0
Copy link
Contributor Author

jkei0 commented Nov 15, 2022

@microsoft-github-policy-service agree

collector.addRule(`.monaco-editor .selected-text { background-color: ${editorInactiveSelectionColor}; }`);
}
const editorSelectionForegroundColor = theme.getColor(editorSelectionForeground);
if (editorSelectionForegroundColor && !editorSelectionForegroundColor.isTransparent()) {
Copy link
Member

Choose a reason for hiding this comment

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

This specific rule cannot be moved to CSS because its condition is if (editorSelectionForegroundColor && !editorSelectionForegroundColor.isTransparent()). This cannot be expressed in CSS.

@alexdima alexdima self-assigned this Nov 18, 2022
Copy link
Member

@alexdima alexdima left a comment

Choose a reason for hiding this comment

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

I pushed the necessary change

@alexdima alexdima added this to the November 2022 milestone Nov 18, 2022
@alexdima alexdima merged commit da44da2 into microsoft:main Nov 18, 2022
@alexdima
Copy link
Member

Thank you!

@github-actions github-actions bot locked and limited conversation to collaborators Jan 2, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

5 participants