Improve dark mode
This commit is contained in:
parent
dfc063caa1
commit
bc78c03e29
2 changed files with 18 additions and 3 deletions
|
@ -5,10 +5,8 @@ import Quote from "@editorjs/quote";
|
||||||
import FormControl from "@material-ui/core/FormControl";
|
import FormControl from "@material-ui/core/FormControl";
|
||||||
import FormHelperText from "@material-ui/core/FormHelperText";
|
import FormHelperText from "@material-ui/core/FormHelperText";
|
||||||
import InputLabel from "@material-ui/core/InputLabel";
|
import InputLabel from "@material-ui/core/InputLabel";
|
||||||
import OutlinedInput from "@material-ui/core/OutlinedInput";
|
|
||||||
import { makeStyles } from "@material-ui/core/styles";
|
import { makeStyles } from "@material-ui/core/styles";
|
||||||
import { fade } from "@material-ui/core/styles/colorManipulator";
|
import { fade } from "@material-ui/core/styles/colorManipulator";
|
||||||
import Typography from "@material-ui/core/Typography";
|
|
||||||
import strikethroughIcon from "@saleor/icons/StrikethroughIcon";
|
import strikethroughIcon from "@saleor/icons/StrikethroughIcon";
|
||||||
import classNames from "classnames";
|
import classNames from "classnames";
|
||||||
import createGenericInlineTool from "editorjs-inline-tool";
|
import createGenericInlineTool from "editorjs-inline-tool";
|
||||||
|
@ -40,6 +38,9 @@ const useStyles = makeStyles(
|
||||||
"& .cdx-quote__text": {
|
"& .cdx-quote__text": {
|
||||||
minHeight: 24
|
minHeight: 24
|
||||||
},
|
},
|
||||||
|
"& .ce-block--selected .ce-block__content": {
|
||||||
|
background: `${fade(theme.palette.primary.main, 0.4)} !important`
|
||||||
|
},
|
||||||
"& .ce-block__content": {
|
"& .ce-block__content": {
|
||||||
margin: 0,
|
margin: 0,
|
||||||
maxWidth: "unset"
|
maxWidth: "unset"
|
||||||
|
@ -50,16 +51,30 @@ const useStyles = makeStyles(
|
||||||
"& .ce-conversion-tool--focused": {
|
"& .ce-conversion-tool--focused": {
|
||||||
background: `${fade(theme.palette.primary.main, 0.1)} !important`
|
background: `${fade(theme.palette.primary.main, 0.1)} !important`
|
||||||
},
|
},
|
||||||
|
"& .ce-conversion-tool__icon": {
|
||||||
|
background: "none"
|
||||||
|
},
|
||||||
|
"& .ce-conversion-toolbar": {
|
||||||
|
background: theme.palette.background.paper
|
||||||
|
},
|
||||||
"& .ce-header": {
|
"& .ce-header": {
|
||||||
marginBottom: 0,
|
marginBottom: 0,
|
||||||
paddingBottom: theme.spacing(1)
|
paddingBottom: theme.spacing(1)
|
||||||
},
|
},
|
||||||
"& .ce-inline-tool": {
|
"& .ce-inline-tool": {
|
||||||
...hover,
|
...hover,
|
||||||
|
color: theme.palette.text.primary,
|
||||||
height: 32,
|
height: 32,
|
||||||
transition: theme.transitions.duration.short + "ms",
|
transition: theme.transitions.duration.short + "ms",
|
||||||
width: 32
|
width: 32
|
||||||
},
|
},
|
||||||
|
"& .ce-inline-toolbar": {
|
||||||
|
"& input": {
|
||||||
|
background: "none"
|
||||||
|
},
|
||||||
|
background: theme.palette.background.paper,
|
||||||
|
color: theme.palette.text.primary
|
||||||
|
},
|
||||||
"& .ce-inline-toolbar__dropdown": {
|
"& .ce-inline-toolbar__dropdown": {
|
||||||
...hover,
|
...hover,
|
||||||
height: 32,
|
height: 32,
|
||||||
|
|
|
@ -17,7 +17,7 @@ export const Decorator = storyFn => (
|
||||||
>
|
>
|
||||||
<DateProvider value={+new Date("2018-08-07T14:30:44+00:00")}>
|
<DateProvider value={+new Date("2018-08-07T14:30:44+00:00")}>
|
||||||
<TimezoneProvider value="America/New_York">
|
<TimezoneProvider value="America/New_York">
|
||||||
<ThemeProvider isDefaultDark={false}>
|
<ThemeProvider isDefaultDark={true}>
|
||||||
<MessageManagerProvider>
|
<MessageManagerProvider>
|
||||||
<div
|
<div
|
||||||
style={{
|
style={{
|
||||||
|
|
Loading…
Reference in a new issue