optimize show original transition

This commit is contained in:
Qing 2022-10-08 22:03:46 +08:00
parent 3c5781c947
commit 33d2fd887f

View File

@ -972,7 +972,7 @@ export default function Editor() {
style={{ style={{
cursor: getCursor(), cursor: getCursor(),
clipPath: `inset(0 ${sliderPos}% 0 0)`, clipPath: `inset(0 ${sliderPos}% 0 0)`,
transition: 'clip-path 350ms ease-in-out', transition: 'clip-path 300ms cubic-bezier(0.4, 0, 0.2, 1)',
}} }}
onContextMenu={e => { onContextMenu={e => {
e.preventDefault() e.preventDefault()
@ -1143,7 +1143,7 @@ export default function Editor() {
setSliderPos(0) setSliderPos(0)
window.setTimeout(() => { window.setTimeout(() => {
setShowOriginal(false) setShowOriginal(false)
}, 350) }, 300)
}} }}
disabled={renders.length === 0} disabled={renders.length === 0}
/> />