Skip to content

Commit

Permalink
Exclude grayscale from selection (#3445)
Browse files Browse the repository at this point in the history
- Do not consider grayscale as option in selection as it would make it less visible.
- Resolves #1020
  • Loading branch information
Gusted committed Aug 21, 2020
1 parent 872d933 commit 16f0ad0
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/inject/dynamic-theme/modify-css.ts
Expand Up @@ -93,8 +93,8 @@ export function getSelectionColor(theme: Theme) {
let backgroundColorSelection: string;
let foregroundColorSelection: string;
if (theme.selectionColor === 'auto') {
backgroundColorSelection = modifyBackgroundColor({r: 0, g: 96, b: 212}, theme);
foregroundColorSelection = modifyForegroundColor({r: 255, g: 255, b: 255}, theme);
backgroundColorSelection = modifyBackgroundColor({r: 0, g: 96, b: 212}, {...theme, grayscale: 0});
foregroundColorSelection = modifyForegroundColor({r: 255, g: 255, b: 255}, {...theme, grayscale: 0});
} else {
const rgb = parse(theme.selectionColor);
const hsl = rgbToHSL(rgb);
Expand Down

0 comments on commit 16f0ad0

Please sign in to comment.