aboutsummaryrefslogtreecommitdiffstats
path: root/subprojects/frontend/src/editor/EditorTheme.ts
diff options
context:
space:
mode:
Diffstat (limited to 'subprojects/frontend/src/editor/EditorTheme.ts')
-rw-r--r--subprojects/frontend/src/editor/EditorTheme.ts12
1 files changed, 11 insertions, 1 deletions
diff --git a/subprojects/frontend/src/editor/EditorTheme.ts b/subprojects/frontend/src/editor/EditorTheme.ts
index c3cbffc8..89bc8932 100644
--- a/subprojects/frontend/src/editor/EditorTheme.ts
+++ b/subprojects/frontend/src/editor/EditorTheme.ts
@@ -52,6 +52,8 @@ export default styled('div', {
52 }, 52 },
53 }; 53 };
54 54
55 const scrollerThumbOpacity = theme.palette.mode === 'dark' ? 0.16 : 0.28;
56
55 const generalStyle: CSSObject = { 57 const generalStyle: CSSObject = {
56 background: theme.palette.background.default, 58 background: theme.palette.background.default,
57 '&, .cm-editor': { 59 '&, .cm-editor': {
@@ -70,6 +72,7 @@ export default styled('div', {
70 zIndex: 300, 72 zIndex: 300,
71 width: 1, 73 width: 1,
72 marginRight: -1, 74 marginRight: -1,
75 pointerEvents: 'none',
73 }, 76 },
74 '.cm-scroller': { 77 '.cm-scroller': {
75 color: theme.palette.text.secondary, 78 color: theme.palette.text.secondary,
@@ -84,12 +87,17 @@ export default styled('div', {
84 '.cm-scroller-thumb': { 87 '.cm-scroller-thumb': {
85 position: 'absolute', 88 position: 'absolute',
86 background: theme.palette.text.secondary, 89 background: theme.palette.text.secondary,
87 opacity: theme.palette.mode === 'dark' ? 0.16 : 0.28, 90 opacity: scrollerThumbOpacity,
88 transition: theme.transitions.create('opacity', { 91 transition: theme.transitions.create('opacity', {
89 duration: theme.transitions.duration.shortest, 92 duration: theme.transitions.duration.shortest,
90 }), 93 }),
94 touchAction: 'none',
95 WebkitTapHighlightColor: 'transparent',
91 '&:hover': { 96 '&:hover': {
92 opacity: 0.75, 97 opacity: 0.75,
98 '@media (hover: none)': {
99 opacity: scrollerThumbOpacity,
100 },
93 }, 101 },
94 '&.active': { 102 '&.active': {
95 opacity: 1, 103 opacity: 1,
@@ -445,6 +453,7 @@ export default styled('div', {
445 background: theme.palette.text.primary, 453 background: theme.palette.text.primary,
446 border: 'none', 454 border: 'none',
447 cursor: 'pointer', 455 cursor: 'pointer',
456 WebkitTapHighlightColor: 'transparent',
448 [theme.breakpoints.down('sm')]: { 457 [theme.breakpoints.down('sm')]: {
449 margin: '2px 0', 458 margin: '2px 0',
450 }, 459 },
@@ -471,6 +480,7 @@ export default styled('div', {
471 background: 'transparent', 480 background: 'transparent',
472 border: 'none', 481 border: 'none',
473 cursor: 'pointer', 482 cursor: 'pointer',
483 WebkitTapHighlightColor: 'transparent',
474 // Use an inner `span` element to match the height of other text highlights. 484 // Use an inner `span` element to match the height of other text highlights.
475 span: { 485 span: {
476 color: theme.palette.text.secondary, 486 color: theme.palette.text.secondary,