@@ -2694,6 +2694,22 @@ test.describe("Workspace Manager V2 bootstrap", () => {
26942694 await expect(page.locator("#objectVectorStudioV2JsonDetails")).toContainText('"rotation": 15');
26952695 await expect(page.locator("#objectVectorStudioV2RotateInput")).toHaveValue("22");
26962696 await expect(page.locator("#statusLog")).toHaveValue(/OK Rotated shape row 0 by 15 degrees\. Snap Angle active: 22 -> 15\./);
2697+ const snapAngleRotateVerification = await page.evaluate(() => {
2698+ const shape = window.__objectVectorStudioV2App.selectedShape();
2699+ const statusLines = document.querySelector("#statusLog").value.trim().split("\n");
2700+ return {
2701+ angleSnapEnabled: window.__objectVectorStudioV2App.angleSnapEnabled,
2702+ inputValue: document.querySelector("#objectVectorStudioV2RotateInput").value,
2703+ rotation: shape.transform.rotation,
2704+ status: statusLines[statusLines.length - 1].replace(/^\[[^\]]+\]\s*/, "")
2705+ };
2706+ });
2707+ expect(snapAngleRotateVerification).toEqual({
2708+ angleSnapEnabled: true,
2709+ inputValue: "22",
2710+ rotation: 15,
2711+ status: "OK Rotated shape row 0 by 15 degrees. Snap Angle active: 22 -> 15."
2712+ });
26972713 await page.locator("#objectVectorStudioV2AngleSnapButton").click();
26982714 await page.locator("#objectVectorStudioV2RotateInput").fill("-30");
26992715 await expect(page.locator("#objectVectorStudioV2RotateInput")).toHaveValue("-30");
@@ -4075,6 +4091,42 @@ test.describe("Workspace Manager V2 bootstrap", () => {
40754091 pointRounding: [false, true, false, false],
40764092 strokeLinejoin: "miter"
40774093 });
4094+ await page.locator("#objectVectorStudioV2ShapeGeometryDetails [data-polygon-point-round='true'][data-polygon-point-index='2']").check();
4095+ await expect(page.locator("#statusLog")).toHaveValue(/OK Updated point 3 rounding to round for shape row 0\./);
4096+ const twoInteriorPointsRounded = await page.locator("#objectVectorStudioV2RenderSurface").evaluate((surface) => {
4097+ const shape = surface.querySelector("[data-shape-index='0']");
4098+ const markers = Array.from(surface.querySelectorAll("[data-point-style-caps='polygon'] [data-point-style-cap]")).map((marker) => marker.dataset.pointStyleCap);
4099+ return {
4100+ markers,
4101+ pointRounding: window.__objectVectorStudioV2App.selectedShape().style.pointRounding,
4102+ strokeLinejoin: shape.getAttribute("stroke-linejoin")
4103+ };
4104+ });
4105+ expect(twoInteriorPointsRounded).toEqual({
4106+ markers: ["point-1", "point-2"],
4107+ pointRounding: [false, true, true, false],
4108+ strokeLinejoin: "miter"
4109+ });
4110+ await page.locator("#objectVectorStudioV2ShapeGeometryDetails [data-polygon-point-round='true'][data-polygon-point-index='1']").uncheck();
4111+ await expect(page.locator("#statusLog")).toHaveValue(/OK Updated point 2 rounding to square for shape row 0\./);
4112+ const independentInteriorPoint = await page.locator("#objectVectorStudioV2RenderSurface").evaluate((surface) => {
4113+ const shape = surface.querySelector("[data-shape-index='0']");
4114+ const markers = Array.from(surface.querySelectorAll("[data-point-style-caps='polygon'] [data-point-style-cap]")).map((marker) => marker.dataset.pointStyleCap);
4115+ return {
4116+ markers,
4117+ pointRounding: window.__objectVectorStudioV2App.selectedShape().style.pointRounding,
4118+ strokeLinejoin: shape.getAttribute("stroke-linejoin")
4119+ };
4120+ });
4121+ expect(independentInteriorPoint).toEqual({
4122+ markers: ["point-2"],
4123+ pointRounding: [false, false, true, false],
4124+ strokeLinejoin: "miter"
4125+ });
4126+ await page.locator("#objectVectorStudioV2ShapeGeometryDetails [data-polygon-point-round='true'][data-polygon-point-index='1']").check();
4127+ await expect(page.locator("#statusLog")).toHaveValue(/OK Updated point 2 rounding to round for shape row 0\./);
4128+ await page.locator("#objectVectorStudioV2ShapeGeometryDetails [data-polygon-point-round='true'][data-polygon-point-index='2']").uncheck();
4129+ await expect(page.locator("#statusLog")).toHaveValue(/OK Updated point 3 rounding to square for shape row 0\./);
40784130 await page.locator("#objectVectorStudioV2ShapeGeometryDetails [data-polygon-point-add='true'][data-polygon-point-index='1']").click();
40794131 await expect.poll(() => page.locator("#objectVectorStudioV2ShapeGeometryDetails .object-vector-studio-v2__polygon-point-field").evaluateAll((rows) => rows.map((row) => ({
40804132 label: row.querySelector(".object-vector-studio-v2__polygon-point-label").textContent.trim(),
0 commit comments