feat: touched fields dont reset on change source image

This commit is contained in:
2026-10-04 15:51:47 +05:00
parent 08608b878a
commit 5743b9fb3f
5 changed files with 46 additions and 8 deletions
+14
View File
@@ -36,6 +36,20 @@ test("resize-png uses the source dimensions by default", async ({ page }) => {
expectNoErrors(sink);
});
test("resize-png keeps user-set size when another image is uploaded", async ({
page,
}) => {
await openTool(page, "resize-png");
await uploadImage(page, opaquePng);
const width = page.getByRole("spinbutton", { name: "Width" });
await width.fill("25");
await uploadImage(page, landscapePng);
await expect(width).toHaveValue("25");
await expect(page.getByRole("spinbutton", { name: "Height" })).toHaveValue(
"48",
);
});
test("crop-png starts with the full source area", async ({ page }) => {
const sink = trackErrors(page);
await openTool(page, "crop-png");