From c8846dec902da59f78fe2d292bd512705d313c29 Mon Sep 17 00:00:00 2001 From: Zerohertz Date: Thu, 14 Nov 2024 10:00:18 +0900 Subject: [PATCH] add: anime duration config --- _config.yml | 1 + source/js/motion.js | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/_config.yml b/_config.yml index 34809c6d7..8afbe51d5 100644 --- a/_config.yml +++ b/_config.yml @@ -628,6 +628,7 @@ quicklink: motion: enable: true async: false + duration: 200 transition: # All available transition variants: https://theme-next.js.org/animate/ menu_item: fadeInDown diff --git a/source/js/motion.js b/source/js/motion.js index 02bcc9db4..0a472e053 100644 --- a/source/js/motion.js +++ b/source/js/motion.js @@ -17,7 +17,7 @@ NexT.motion.integrator = { if (!CONFIG.motion.async) this.queue = [this.queue.flat()]; this.queue.forEach(sequence => { const timeline = window.anime.timeline({ - duration: 200, + duration: CONFIG.motion?.duration ?? 200, easing : 'linear' }); sequence.forEach(item => {