From fede39c6eb546c1b57ee38e747ee4dbf34c5f75e Mon Sep 17 00:00:00 2001 From: lutinglt Date: Sat, 1 Nov 2025 14:16:36 +0800 Subject: [PATCH] =?UTF-8?q?=E5=90=8C=E6=AD=A5=E5=AD=97=E7=AC=A6=E6=8F=90?= =?UTF-8?q?=E7=A4=BA=E7=9A=84=E6=8F=90=E7=A4=BA=E6=A1=86=E5=8A=A8=E7=94=BB?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- CHANGELOG.md | 2 ++ src/core/theme.ts | 2 ++ styles/public/animation.ts | 11 ++++++++++- styles/public/tippy.ts | 3 ++- 4 files changed, 16 insertions(+), 2 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index e81f115..b8b587f 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -5,6 +5,8 @@ - 优化用户头像样式 - 优化 Issue/PR/Diff/Actions 的三点菜单按钮样式 - 优化用户动态样式 +- 优化仓库发布页面样式 +- 同步字符提示的提示框动画 ### 🐞 Fix diff --git a/src/core/theme.ts b/src/core/theme.ts index 4e8641c..45dc5c5 100644 --- a/src/core/theme.ts +++ b/src/core/theme.ts @@ -6,6 +6,8 @@ import type { MapLeafNodes, WithOptionalLayer } from "./types"; export type Theme = WithOptionalLayer>; +export const overlayAppear = "overlay-appear"; +export const animation = `200ms cubic-bezier(0.33, 1, 0.68, 1) 0s 1 normal none running ${overlayAppear}`; export const overlayAppearDown = "overlay-appear-down"; export const animationDown = `200ms cubic-bezier(0.33, 1, 0.68, 1) 0s 1 normal none running ${overlayAppearDown}`; export const overlayAppearUp = "overlay-appear-up"; diff --git a/styles/public/animation.ts b/styles/public/animation.ts index e0f96f9..fa470df 100644 --- a/styles/public/animation.ts +++ b/styles/public/animation.ts @@ -1,7 +1,16 @@ -import { overlayAppearDown, overlayAppearUp } from "src/core/theme"; +import { overlayAppear, overlayAppearDown, overlayAppearUp } from "src/core/theme"; import { css } from "src/types/vars"; export const keyframe = css` + // 出现动画 + @keyframes ${overlayAppear} { + 0% { + opacity: 0; + } + 100% { + opacity: 1; + } + } // 向下出现动画 @keyframes ${overlayAppearDown} { 0% { diff --git a/styles/public/tippy.ts b/styles/public/tippy.ts index 8eda702..23c3d3c 100644 --- a/styles/public/tippy.ts +++ b/styles/public/tippy.ts @@ -1,4 +1,4 @@ -import { animationDown } from "src/core/theme"; +import { animation, animationDown } from "src/core/theme"; import { css, otherThemeVars, themeVars } from "src/types/vars"; // 一些界面内的提示框, 比如克隆按钮, PR信息, Runner信息 等 @@ -43,6 +43,7 @@ export const tippyBox = css` } // 专门用于提示信息的提示框, 比如提交的具体时间, 任务状态等 &[data-theme="tooltip"] { + animation: ${animation}; .tippy-content { font-size: 12px; font-weight: 400;