diff --git a/example/docs/zh-CN/components/animation.md b/example/docs/zh-CN/components/animation.md index 142890c1..b5f9dac0 100644 --- a/example/docs/zh-CN/components/animation.md +++ b/example/docs/zh-CN/components/animation.md @@ -16,51 +16,51 @@
@@ -72,7 +72,16 @@ import { ref } from 'vue' export default { setup() { + const playAnimation = (e) => { + const el = e.currentTarget; + const targetClass = el.classList[1]; + el.classList.remove(targetClass); + setTimeout(() => { + el.classList.add(targetClass); + },100) + } return { + playAnimation } } }