Skip to content

Commit

Permalink
Update styles for block picker in dark mode
Browse files Browse the repository at this point in the history
  • Loading branch information
albinazs committed Jul 7, 2023
1 parent cfb0a4b commit 0672689
Show file tree
Hide file tree
Showing 6 changed files with 17 additions and 13 deletions.
3 changes: 0 additions & 3 deletions client/scss/components/_dialog.scss
Original file line number Diff line number Diff line change
Expand Up @@ -158,9 +158,6 @@

.w-dialog__box {
pointer-events: auto;
@include dark-theme() {
box-shadow: theme('boxShadow.lg');
}
box-shadow: theme('boxShadow.md');
}

Expand Down
3 changes: 0 additions & 3 deletions client/scss/layouts/_login.scss
Original file line number Diff line number Diff line change
Expand Up @@ -57,9 +57,6 @@
float: none;
padding: theme('spacing.10') theme('spacing.12');
background: theme('colors.surface-page');
@include dark-theme() {
box-shadow: theme('boxShadow.lg');
}
box-shadow: theme('boxShadow.md');
border-radius: theme('borderRadius.md');
margin-bottom: 15vh; // should appear slightly above centre
Expand Down
3 changes: 0 additions & 3 deletions client/src/components/ComboBox/ComboBox.scss
Original file line number Diff line number Diff line change
Expand Up @@ -12,9 +12,6 @@ $spacing-sm: theme('spacing.5');
color: theme('colors.text-context');
border-radius: theme('borderRadius.DEFAULT');
font-size: theme('fontSize.18');
@include dark-theme() {
box-shadow: theme('boxShadow.lg');
}
box-shadow: theme('boxShadow.md');
outline: 10px solid transparent;
}
Expand Down
16 changes: 14 additions & 2 deletions client/src/tokens/colorThemes.js
Original file line number Diff line number Diff line change
Expand Up @@ -246,7 +246,13 @@ const light = [
{
label: 'Misc',
tokens: {
focus: focusToken,
'focus': focusToken,
'box-shadow-md': {
value: 'var(--w-color-black-25)',
bgUtility: 'w-bg-box-shadow-md',
textUtility: 'w-text-box-shadow-md',
cssVariable: '--w-color-box-shadow-md',
},
},
},
];
Expand Down Expand Up @@ -474,7 +480,13 @@ const dark = [
{
label: 'Misc',
tokens: {
focus: focusToken,
'focus': focusToken,
'box-shadow-md': {
value: 'var(--w-color-black-50)',
bgUtility: 'w-bg-box-shadow-md',
textUtility: 'w-text-box-shadow-md',
cssVariable: '--w-color-box-shadow-md',
},
},
},
];
Expand Down
2 changes: 2 additions & 0 deletions client/src/tokens/colorVariables.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -183,6 +183,7 @@ describe('generateThemeColorVariables', () => {
"--w-color-border-field-hover": "var(--w-color-grey-200)",
"--w-color-border-field-inactive": "var(--w-color-grey-150)",
"--w-color-border-furniture": "var(--w-color-grey-100)",
"--w-color-box-shadow-md": "var(--w-color-black-25)",
"--w-color-focus": "#00A885",
"--w-color-icon-primary": "var(--w-color-primary)",
"--w-color-icon-primary-hover": "var(--w-color-primary-200)",
Expand Down Expand Up @@ -225,6 +226,7 @@ describe('generateThemeColorVariables', () => {
"--w-color-border-field-hover": "var(--w-color-grey-200)",
"--w-color-border-field-inactive": "var(--w-color-grey-500)",
"--w-color-border-furniture": "var(--w-color-grey-500)",
"--w-color-box-shadow-md": "var(--w-color-black-50)",
"--w-color-focus": "#00A885",
"--w-color-icon-primary": "var(--w-color-grey-150)",
"--w-color-icon-primary-hover": "var(--w-color-grey-50)",
Expand Down
3 changes: 1 addition & 2 deletions client/src/tokens/objectStyles.js
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,7 @@ const borderWidth = {
// If adding new values, use T-shirt sizing naming.
const boxShadow = {
DEFAULT: '5px 5px 20px rgba(0, 0, 0, 0.05)',
md: '5px 5px 30px rgba(0, 0, 0, 0.25)',
lg: '5px 5px 30px rgba(0, 0, 0, 0.5)',
md: '5px 5px 30px var(--w-color-box-shadow-md)',
};

module.exports = {
Expand Down

0 comments on commit 0672689

Please sign in to comment.