mirror of
https://github.com/toeverything/AFFiNE.git
synced 2026-02-12 04:18:54 +00:00
chore: fix color (#2049)
Co-authored-by: JimmFly <yangjinfei001@gmail.com>
This commit is contained in:
@@ -1,5 +1,4 @@
|
|||||||
import {
|
import {
|
||||||
alpha,
|
|
||||||
displayFlex,
|
displayFlex,
|
||||||
IconButton,
|
IconButton,
|
||||||
styled,
|
styled,
|
||||||
@@ -62,7 +61,7 @@ export const StyledPinboard = styled('div')<{
|
|||||||
? 'var(--affine-primary-color)'
|
? 'var(--affine-primary-color)'
|
||||||
: 'var(--affine-text-primary-color)',
|
: 'var(--affine-text-primary-color)',
|
||||||
cursor: disable ? 'not-allowed' : 'pointer',
|
cursor: disable ? 'not-allowed' : 'pointer',
|
||||||
background: isOver ? alpha('var(--affine-primary-color)', 0.06) : '',
|
background: isOver ? 'rgba(118, 95, 254, 0.06)' : '',
|
||||||
fontSize: 'var(--affine-font-base)',
|
fontSize: 'var(--affine-font-base)',
|
||||||
userSelect: 'none',
|
userSelect: 'none',
|
||||||
...(textWrap
|
...(textWrap
|
||||||
|
|||||||
@@ -4,17 +4,12 @@ export const StyledEditorModeSwitch = styled('div')<{
|
|||||||
switchLeft: boolean;
|
switchLeft: boolean;
|
||||||
showAlone?: boolean;
|
showAlone?: boolean;
|
||||||
}>(({ theme, switchLeft, showAlone }) => {
|
}>(({ theme, switchLeft, showAlone }) => {
|
||||||
const {
|
|
||||||
palette: { mode },
|
|
||||||
} = theme;
|
|
||||||
return {
|
return {
|
||||||
width: showAlone ? '40px' : '78px',
|
width: showAlone ? '40px' : '78px',
|
||||||
height: '32px',
|
height: '32px',
|
||||||
background: showAlone
|
background: showAlone
|
||||||
? 'transparent'
|
? 'transparent'
|
||||||
: mode === 'dark'
|
: 'var(--affine-background-primary-color)',
|
||||||
? '#242424'
|
|
||||||
: '#F9F9FB',
|
|
||||||
borderRadius: '12px',
|
borderRadius: '12px',
|
||||||
...displayFlex('space-between', 'center'),
|
...displayFlex('space-between', 'center'),
|
||||||
padding: '0 8px',
|
padding: '0 8px',
|
||||||
@@ -26,10 +21,7 @@ export const StyledEditorModeSwitch = styled('div')<{
|
|||||||
width: '24px',
|
width: '24px',
|
||||||
height: '24px',
|
height: '24px',
|
||||||
background: 'var(--affine-background-primary-color)',
|
background: 'var(--affine-background-primary-color)',
|
||||||
boxShadow:
|
boxShadow: 'var(--affine-tooltip-shadow)',
|
||||||
mode === 'dark'
|
|
||||||
? '0px 0px 6px rgba(22, 22, 22, 0.6)'
|
|
||||||
: '0px 0px 6px #E2E2E2',
|
|
||||||
borderRadius: '8px',
|
borderRadius: '8px',
|
||||||
zIndex: 1,
|
zIndex: 1,
|
||||||
position: 'absolute',
|
position: 'absolute',
|
||||||
|
|||||||
@@ -30,6 +30,9 @@ const CssVariablesInjector = memo<{
|
|||||||
return variables;
|
return variables;
|
||||||
}, {} as AffineCssVariables),
|
}, {} as AffineCssVariables),
|
||||||
},
|
},
|
||||||
|
body: {
|
||||||
|
color: 'var(--affine-text-primary-colorr)',
|
||||||
|
},
|
||||||
html: {
|
html: {
|
||||||
fontFamily: theme.fontFamily,
|
fontFamily: theme.fontFamily,
|
||||||
fontSize: theme.fontBase,
|
fontSize: theme.fontBase,
|
||||||
|
|||||||
@@ -44,7 +44,7 @@ export const StyledIconButton = styled('button', {
|
|||||||
width,
|
width,
|
||||||
height,
|
height,
|
||||||
fontSize,
|
fontSize,
|
||||||
color: 'var(--affine-hover-color)',
|
color: 'var(--affine-icon-color)',
|
||||||
...displayInlineFlex('center', 'center'),
|
...displayInlineFlex('center', 'center'),
|
||||||
position: 'relative',
|
position: 'relative',
|
||||||
...(disabled ? { cursor: 'not-allowed', pointerEvents: 'none' } : {}),
|
...(disabled ? { cursor: 'not-allowed', pointerEvents: 'none' } : {}),
|
||||||
|
|||||||
@@ -75,8 +75,8 @@ export const toast = (
|
|||||||
font-size: var(--affine-font-sm);
|
font-size: var(--affine-font-sm);
|
||||||
padding: 6px 12px;
|
padding: 6px 12px;
|
||||||
margin: 10px 0 0 0;
|
margin: 10px 0 0 0;
|
||||||
color: var(--affine-tooltip-color);
|
color: var(--affine-white);
|
||||||
background: var(--affine-tooltip-background);
|
background: var(--affine-tooltip);
|
||||||
box-shadow: var(--affine-tooltip-shadow);
|
box-shadow: var(--affine-tooltip-shadow);
|
||||||
border-radius: 10px;
|
border-radius: 10px;
|
||||||
transition: all 230ms cubic-bezier(0.21, 1.02, 0.73, 1);
|
transition: all 230ms cubic-bezier(0.21, 1.02, 0.73, 1);
|
||||||
|
|||||||
Reference in New Issue
Block a user