Skip to content

[upstream-port] 表格行入场动画结束后释放 transform(new-api 5e959519,前端) #935

Closed

Description

@LIghtJUNction

上游变更

  • 提交:5e959519(feat(channels): add drag mode for channel priority ordering,2026-10-17,无独立 PR 号)

这个提交主体是渠道优先级拖拽排序(见下方「不适用」),但顺带改了一行通用样式:web/src/styles/index.css 里表格行入场动画的填充模式从 both 改成 backwards:

-  /* Table row stagger-in animation */
+  /* Only fill the entrance delay; completed animations must release transform/opacity. */
   [data-slot='table'] tbody tr {
-    animation: tableRowEnter 0.2s cubic-bezier(0.33, 1, 0.68, 1) both;
+    animation: tableRowEnter 0.2s cubic-bezier(0.33, 1, 0.68, 1) backwards;
   }

用 both 时,动画结束后每一行会一直保留 transform: translateY(0) 和 opacity: 1。transform 只要不是 none,该行就会成为新的层叠上下文,也会成为其内部 position: fixed 元素的包含块。上游是在做拖拽预览时撞上这个问题的;改成 backwards 后只在延迟阶段保持起始帧,动画结束就释放 transform/opacity,入场效果不变。

LMM 中的现状(默认分支 wip/rust-core-go-extensions)

  • apps/web/src/styles/index.css 第 638–641 行仍是同样的 animation: tableRowEnter ... both;,所以所有 [data-slot='table'] 表格(渠道、日志、用户、钱包流水等)的每一行在动画结束后都带着常驻 transform。
  • 可能的影响:行内用 position: fixed 或依赖层叠顺序的东西(行内浮层、粘性列、行内高亮/拖拽态)会被困在行里或出现 z-index 异常。我没有在线上逐页复现,需要在改动时顺手确认一下。

建议改动

  • 把 apps/web/src/styles/index.css 第 640 行的 both 改成 backwards,注释同步更新;
  • 不需要引入上游的渠道拖拽代码。

风险与冲突

  • 很低,只改动画填充模式,入场视觉一致。需要确认没有组件依赖「动画结束后行上有 transform」这一副作用(例如有人靠它给行内 fixed 元素定位)。
  • 与钱包上下限、支付、订阅、assistant、HeroSMS、bounty 契约、Redis-off 运行时、1 USD = 500000 credits、task/JS 插件宿主决策都无关。

需要跑的测试

  • apps/web 下 vitest、typecheck、lint;
  • 手动:打开渠道、日志、用户表格,确认入场动画仍然正常,行内下拉菜单、tooltip、粘性列显示正常。

工作量估计

很小(约 0.25 小时)。这是前端改动,必须由 Claude Opus 5.5(claude-opus-5-5)云端代理完成,并保留 LMM 品牌和 DESIGN.md 的要求。可以和 #920、#933、#934 放进同一个前端 PR。

同批次不适用的上游提交

  • 5e959519 的渠道优先级拖拽主体(controller/channel_priority.go、model/channel_priority.go、GET /api/channel/priority/order、POST /api/channel/priority/reorder,以及 web/src/features/channels/ 下的拖拽 hook、控件和 7 个语言包词条):暂不适用。默认分支已没有 Go 的渠道管理后端(services/extensions 里没有 channel 模块),路由改由 Rust services/core/src/routing 负责,且契约是「数值越小优先级越高」,与上游「越大越优先」相反,还有每条路由最多 64 个 target 的约束。要做这个功能需要先在 Rust 侧设计带 revision 冲突检测的批量调优先级接口,前端排序方向也要反过来,属于新功能设计,不是直接移植。
  • 5a59d691(fix(pricing): hide task prices left at zero when another price is set):不适用。它修的是上游 task 插件分档计价(task-matrix-display.ts、billing_usage_schema、isTaskUsage)的展示;fork 的 apps/web/src/features/pricing/ 没有这套代码,task/JS 插件宿主按 FORK.md 已暂缓。

由 lightbot 每小时上游审查自动创建。

Activity

  1. added
    botOpened by the maintenance bot
    upstream-portQuantumNous/new-api upstream commit port candidate
    on Oct 17, 2026
  2. LIghtJUNction commented on Oct 18, 2026

    @LIghtJUNction
    MemberAuthor

    已在 5e8f1190 将表格行入场动画填充模式改为 backwards。

    真实应用 API Key 表格验证通过:正常动画结束后计算样式为 transform: none、opacity: 1;减少动态效果模式没有入场动画且保持同样的最终样式。相关前端回归、格式检查及完整 Web typecheck 通过。

    本轮只处理通用动画状态释放;渠道拖拽排序仍按正文中的独立契约范围推进。

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    botOpened by the maintenance botupstream-portQuantumNous/new-api upstream commit port candidate

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions