⚡️ refactor(core): 优化 UI 交互体验与列表高度动画逻辑

* 引入 fcb-secondary-card 样式类统一卡片视觉表现
* 增强卡片悬停效果与过渡动画平滑度
* 优化 FileManageView 高度切换的动画计算逻辑
* 修正列表组件样式类以适配新的交互规范
This commit is contained in:
orion committed 2026-09-11 11:12:30 +08:00
1 parent 8c0503a020
commit 29c2fd9cb8
4 files changed
+26 -5

No files matched your search

+8 -3
View File
@@ -1879,19 +1879,24 @@ const animateLifecycleHeight = async () => {
await nextTick()
const viewport = lifecycleViewportRef.value
if (!viewport || reducedMotionQuery.matches) return
lifecycleHeightAnimation?.cancel()
lifecycleHeightAnimation = null
viewport.style.height = ''
await nextTick()
const currentHeight = viewport.getBoundingClientRect().height
viewport.style.height = `${currentHeight}px`
await nextTick()
const targetHeight = viewport.scrollHeight
lifecycleHeightAnimation?.cancel()
lifecycleHeightAnimation = viewport.animate(
[{ height: `${currentHeight}px` }, { height: `${targetHeight}px` }],
{ duration: 420, easing: 'cubic-bezier(0.22, 1, 0.36, 1)', fill: 'forwards' }
)
lifecycleHeightAnimation.addEventListener('finish', () => {
const cleanup = () => {
viewport.style.height = ''
lifecycleHeightAnimation = null
}, { once: true })
}
lifecycleHeightAnimation.addEventListener('finish', cleanup, { once: true })
lifecycleHeightAnimation.addEventListener('cancel', cleanup, { once: true })
}
const LIFECYCLE_ENTER_MS = 160