feat : big update
CI / Verify (push) Successful in 51s
CI / Build immutable images and deploy (push) Successful in 1m36s

This commit is contained in:
2026-08-30 10:52:37 +00:00 Unverified
parent 0a643dd60e
commit 273baa55d8
22 changed files with 4025 additions and 87 deletions
+17
View File
@@ -0,0 +1,17 @@
import { describe, expect, it } from "vitest";
import { imageContentDisposition } from "@/lib/guides/export-image";
describe("guide image downloads", () => {
it("provides a safe ASCII fallback and a UTF-8 filename", () => {
expect(imageContentDisposition("ไกด์อาวุธ", "weapons")).toBe(
"attachment; filename=\"weapons.png\"; filename*=UTF-8''%E0%B9%84%E0%B8%81%E0%B8%94%E0%B9%8C%E0%B8%AD%E0%B8%B2%E0%B8%A7%E0%B8%B8%E0%B8%98.png",
);
});
it("sanitizes punctuation in the fallback filename", () => {
expect(imageContentDisposition("Arlecchino / R5", "weapons")).toContain(
'filename="Arlecchino-R5.png"',
);
});
});