mirror of
https://github.com/scratchfoundation/scratch-paint.git
synced 2024-12-23 05:52:42 -05:00
Fix the pointer-events error in the console (#635)
This commit is contained in:
parent
07effb7fd8
commit
c6458ddebc
1 changed files with 10 additions and 10 deletions
|
@ -14,15 +14,15 @@ const ScrollableCanvasComponent = props => (
|
||||||
{props.children}
|
{props.children}
|
||||||
<div
|
<div
|
||||||
className={styles.horizontalScrollbarWrapper}
|
className={styles.horizontalScrollbarWrapper}
|
||||||
style={{'pointer-events': 'none'}}
|
style={{pointerEvents: 'none'}}
|
||||||
>
|
>
|
||||||
<div
|
<div
|
||||||
className={styles.horizontalScrollbar}
|
className={styles.horizontalScrollbar}
|
||||||
style={{
|
style={{
|
||||||
'width': `${props.horizontalScrollLengthPercent}%`,
|
width: `${props.horizontalScrollLengthPercent}%`,
|
||||||
'left': `${props.horizontalScrollStartPercent}%`,
|
left: `${props.horizontalScrollStartPercent}%`,
|
||||||
'pointer-events': 'all',
|
pointerEvents: 'auto',
|
||||||
'display': `${props.hideCursor ||
|
display: `${props.hideCursor ||
|
||||||
Math.abs(props.horizontalScrollLengthPercent - 100) < 1e-8 ? 'none' : 'block'}`
|
Math.abs(props.horizontalScrollLengthPercent - 100) < 1e-8 ? 'none' : 'block'}`
|
||||||
}}
|
}}
|
||||||
onMouseDown={props.onHorizontalScrollbarMouseDown}
|
onMouseDown={props.onHorizontalScrollbarMouseDown}
|
||||||
|
@ -30,15 +30,15 @@ const ScrollableCanvasComponent = props => (
|
||||||
</div>
|
</div>
|
||||||
<div
|
<div
|
||||||
className={styles.verticalScrollbarWrapper}
|
className={styles.verticalScrollbarWrapper}
|
||||||
style={{'pointer-events': 'none'}}
|
style={{pointerEvents: 'none'}}
|
||||||
>
|
>
|
||||||
<div
|
<div
|
||||||
className={styles.verticalScrollbar}
|
className={styles.verticalScrollbar}
|
||||||
style={{
|
style={{
|
||||||
'height': `${props.verticalScrollLengthPercent}%`,
|
height: `${props.verticalScrollLengthPercent}%`,
|
||||||
'top': `${props.verticalScrollStartPercent}%`,
|
top: `${props.verticalScrollStartPercent}%`,
|
||||||
'pointer-events': 'auto',
|
pointerEvents: 'auto',
|
||||||
'display': `${props.hideCursor ||
|
display: `${props.hideCursor ||
|
||||||
Math.abs(props.verticalScrollLengthPercent - 100) < 1e-8 ? 'none' : 'block'}`
|
Math.abs(props.verticalScrollLengthPercent - 100) < 1e-8 ? 'none' : 'block'}`
|
||||||
}}
|
}}
|
||||||
onMouseDown={props.onVerticalScrollbarMouseDown}
|
onMouseDown={props.onVerticalScrollbarMouseDown}
|
||||||
|
|
Loading…
Reference in a new issue