fix: disable fullscreen table token animation

This commit is contained in:
2026-07-20 18:47:26 +08:00
parent 86389de3fa
commit 3c0271bae8
2 changed files with 20 additions and 0 deletions
+7
View File
@@ -354,6 +354,13 @@ input:focus-visible {
--sd-easing: cubic-bezier(0.16, 1, 0.3, 1);
}
[data-streamdown="table-fullscreen"] [data-sd-animate] {
animation: none;
filter: none;
opacity: 1;
transform: none;
}
.agent-chart-line {
animation: agent-chart-line-in 220ms cubic-bezier(0.22, 1, 0.36, 1) both;
transform-origin: center;
@@ -0,0 +1,13 @@
import { readFileSync } from "node:fs";
import { join } from "node:path";
import { describe, expect, it } from "vitest";
describe("Streamdown fullscreen table", () => {
it("disables inherited token animations only inside the fullscreen copy", () => {
const styles = readFileSync(join(process.cwd(), "app/globals.css"), "utf8");
expect(styles).toMatch(
/\[data-streamdown="table-fullscreen"\] \[data-sd-animate\] \{\s*animation: none;\s*filter: none;\s*opacity: 1;\s*transform: none;\s*\}/
);
});
});