From 1e7b20e51eeb2f5d7ab4df0f13ac25deeac2bfa1 Mon Sep 17 00:00:00 2001 From: Eltrac Date: Fri, 29 Nov 2024 00:12:57 +0800 Subject: feat(theme/swup): better transition animation --- themes/yinyang/assets/css/index.css | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/themes/yinyang/assets/css/index.css b/themes/yinyang/assets/css/index.css index 46e9fea4..bceabfdf 100644 --- a/themes/yinyang/assets/css/index.css +++ b/themes/yinyang/assets/css/index.css @@ -583,11 +583,13 @@ a.blog-link img { /* transition animation */ -html.is-changing .transition-fade { - transition: opacity 0.25s; +html.is-changing .transition-fade article { + transition: opacity, transform 0.25s; + transform: translateY(0); opacity: 1; } -html.is-animating .transition-fade { +html.is-animating .transition-fade article { + transform: translateY(2rem); opacity: 0; } \ No newline at end of file -- cgit v1.2.3