gsap_tween_tail counts GSAP's force3D and autoRound flags as properties
维护者通常 1 天内回复
评估
- 难度
- 2/5
- 预计耗时
- 1-3 小时
- 新手友好度
- 78/100
- Issue 类型
- 缺陷
- 描述清晰度
- 描述清楚
- 活跃度
- 活跃
- 技术栈
- cli, typescript
- 领域
- cli
调研方向
该警告来自 packages/cli/src/utils/gsapTweenTails.ts:NOT_PROPERTIES 列表(约第 77-113 行)缺少 force3D 和 autoRound,而 plainProperties(约第 133 行)仍保留了它们。将这两个键添加到列表中,然后检查 issue 中的复现不再输出 gsap_tween_tail,而真实的共享属性(例如两个 opacity 补间)仍会输出该警告。复现结果干净且现有的补间尾部测试仍然通过时,即为完成。
由索引模型根据 Issue 内容生成。
描述
Describe the bug
check's runtime warning gsap_tween_tail treats GSAP's force3D and autoRound flags as tweened properties.
collectTweenRecords leaves out GSAP's special keys (NOT_PROPERTIES: duration, ease, overwrite, immediateRender, ...) but not force3D or autoRound. So tailBetween finds a shared "property" in any two overlapping tweens of one element that both pass them, whatever they animate, whenever the earlier one ends up to 0.25 s after the later one.
A composition that passes force3D: false, autoRound: false on every tween (ours does, for crisp scaled text) gets a warning for every such pair: about 60 on a 65 s composition, every one naming only force3D, autoRound, none a real property.
That hides the case the warning is for. We had two genuine pairs (two tweens of opacity on one element at once), found by their frames once 0.8.158's seek drew them in another order, and they were lost among the flag-only warnings.
Measured on 0.8.158 (0.8.152 has the same list). The code is unchanged in v0.8.162: NOT_PROPERTIES has neither key (packages/cli/src/utils/gsapTweenTails.ts, lines 77-113), and plainProperties keeps every other key of vars (line 133).
Minimal reproduction
npx hyperframes init repro --non-interactive --example blank
Then replace repro/index.html with the file below. Only the <script> differs from the blank template: one element, two overlapping tweens of different properties (x, then opacity), both with force3D: false, autoRound: false. The earlier tween ends 0.1 s after the later one.
<!doctype html>
<html lang="en">
<head>
<meta charset="UTF-8" />
<meta name="viewport" content="width=1920, height=1080" />
<script src="https://cdn.jsdelivr.net/npm/[email protected]/dist/gsap.min.js"></script>
<style>
* {
margin: 0;
padding: 0;
box-sizing: border-box;
}
html,
body {
margin: 0;
width: 1920px;
height: 1080px;
overflow: hidden;
background: #0a0a0a;
}
#root {
width: 100%;
height: 100%;
display: flex;
align-items: center;
justify-content: center;
font-family: Inter, ui-sans-serif, system-ui, sans-serif;
}
#title {
color: #f4f4f5;
font-size: 72px;
font-weight: 600;
letter-spacing: -0.03em;
}
</style>
</head>
<body>
<div
id="root"
data-composition-id="main"
data-start="0"
data-duration="10"
data-width="1920"
data-height="1080"
>
<h1 id="title" class="clip" data-start="0" data-duration="10" data-track-index="0">Title</h1>
</div>
<script>
const tl = gsap.timeline({ paused: true });
// One element, two overlapping tweens of different properties (x, then opacity).
// The earlier tween ends 0.1 s after the later one. Both pass force3D and autoRound.
tl.to("#title", { x: 200, duration: 1, force3D: false, autoRound: false }, 0);
tl.to("#title", { opacity: 0.5, duration: 0.4, force3D: false, autoRound: false }, 0.5);
window.__timelines["main"] = tl;
tl.seek(0);
</script>
</body>
</html>
Steps to reproduce
- Set up the reproduction above.
- In
repro, runnpx [email protected] check --json. - Look at
runtime.findings: onegsap_tween_tailwarning namingforce3D, autoRound. - For comparison, remove
, force3D: false, autoRound: falsefrom both tweens and run the check again:runtime.findingsis empty.
Expected behavior
No gsap_tween_tail warning. The two tweens share no tweened property (x and opacity). force3D and autoRound are GSAP flags, not properties a tween animates, so they should be left out as ease and overwrite are, and the warning should name only properties two tweens really share.
Actual behavior
check --json exits 0 with this runtime finding (other fields trimmed):
{
"code": "gsap_tween_tail",
"severity": "warning",
"message": "In timeline \"main\", a tween on force3D, autoRound of #title ends at 1.000 s, 0.100 s after a later tween on force3D, autoRound ends at 0.900 s. For that tail the earlier tween takes force3D, autoRound back and leaves its own end value on screen, so the later tween's end never shows. End the earlier tween by 0.500 s, or add overwrite: \"auto\" to the later tween.",
"sourceFile": "index.html",
"time": 0.9
}
The same composition without the two flags has no runtime findings.
Environment
OS: Windows 11 (build 26200)
Node.js: v24.14.0
HyperFrames: 0.8.158 (0.8.152 has the same NOT_PROPERTIES; code unchanged at v0.8.162)
Chrome: Chrome Headless Shell 152.0.7977.30
Additional context
Request: add force3D and autoRound to NOT_PROPERTIES (or leave out every GSAP flag that is not a tweened property), so the warning names only properties two tweens really share.
- 主要语言
- TypeScript
- 星标
- 54.1k
- 派生
- 4.9k
- 平均合并
- 8 小时 33 分钟
- 30 天内合并 PR
- 665
环境准备
这个项目没有提供开发容器、Dockerfile 或贡献指南,环境需要你自己搭建:先看它的 README,通用步骤见我们的新手贡献指南。
从这里开始
- 先读完整个 Issue,再读项目的贡献指南。
- 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
- Fork 仓库,在一个分支上完成修改。
- 提交 Pull Request,并在描述里引用这个 Issue 编号。
heygen-com/hyperframes 的其他 Issue
-
product-launch-video: assemble-index.mjs is not idempotent — a second run drops every approved frame video可能已有人在做 @Dante-dan 于 1 天前认领。 未关闭
难度 2/5 1-3 小时 新手友好度 75/100
heygen-com/hyperframes#5733 ·
维护者通常 1 天内回复
-
desktop-candidate difficulty/easy enhancement good first issue help wanted triage/ready
难度 2/5 1-3 小时 新手友好度 85/100
heygen-com/hyperframes#5582 · 1 条评论 ·
维护者通常 1 天内回复
-
Studio: press ? to open the keyboard shortcuts panel可能已有人在做 @B-Payal 于 4 天前认领。 未关闭desktop-candidate difficulty/easy enhancement good first issue help wanted triage/ready
难度 2/5 1-3 小时 新手友好度 82/100
heygen-com/hyperframes#5580 · 1 条评论 ·
维护者通常 1 天内回复
-
remotion-to-hyperframes: Easing.cubic is mapped to power3 (quartic); cubic is power2可能已有人在做 @user-github-me 于 4 天前认领。 未关闭difficulty/easy documentation help wanted triage/ready
难度 1/5 1 小时以内 新手友好度 88/100
heygen-com/hyperframes#5538 · 1 条评论 ·
维护者通常 1 天内回复
-
`hyperframes docs examples` lists templates that don't exist可能已有人在做 @Muhtasim-Munif-Fahim 于 7 天前认领。 未关闭bug difficulty/easy help wanted triage/ready
难度 2/5 1-3 小时 新手友好度 82/100
heygen-com/hyperframes#5393 · 1 条评论 ·
维护者通常 1 天内回复
查看 heygen-com/hyperframes 的全部 Issue
相似的 Issue
-
难度 2/5 1-3 小时 新手友好度 86/100
维护者通常 1 天内回复
-
难度 1/5 1 小时以内 新手友好度 90/100
chrisparsons83/flexspotff#215 ·
维护者通常 1 天内回复
-
难度 2/5 1-3 小时 新手友好度 78/100
维护者通常 1 天内回复
-
难度 2/5 1-3 小时 新手友好度 82/100
vitest-dev/vitest#11633 · 1 条评论 ·
维护者通常 1 天内回复
-
难度 2/5 1-3 小时 新手友好度 65/100
维护者通常 1 天内回复