From 14705242454ad62d781319399e09fd0bbdccd5d4 Mon Sep 17 00:00:00 2001 From: Andrea Bogazzi Date: Mon, 22 Apr 2024 11:20:15 +0200 Subject: [PATCH] added test and bad snapshot --- test/visual/control_rendering.js | 27 +++++++++++++++++++++++++ test/visual/golden/controls11group.png | Bin 0 -> 1142 bytes 2 files changed, 27 insertions(+) create mode 100644 test/visual/golden/controls11group.png diff --git a/test/visual/control_rendering.js b/test/visual/control_rendering.js index 09adcbaa38b..78690138a73 100644 --- a/test/visual/control_rendering.js +++ b/test/visual/control_rendering.js @@ -300,6 +300,33 @@ fabricClass: 'Canvas', }); + function controlboxFlippedXInGroup(canvas, callback) { + var rect = new fabric.Rect({ + width: 90, height: 90, padding: 9, angle: 0, flipX: true, + cornerSize: 12, cornerColor: 'green', cornerStrokeColor: 'blue', + transparentCorners: false, borderScaleFactor: 3, + fill: 'red', top: 50, left: 35, + }); + var group = new fabric.Group([rect], { + interactive: true, + subTargetCheck: true, + }); + canvas.add(group); + canvas.setActiveObject(rect); + canvas.renderAll(); + callback(canvas.lowerCanvasEl); + } + + tests.push({ + test: 'controlbox with flipped X in group', + code: controlboxFlippedXInGroup, + golden: 'controls11group.png', + percentage: 0.004, + width: 150, + height: 180, + fabricClass: 'Canvas', + }); + function controlboxOpacitySingle(canvas, callback) { var rect = new fabric.Rect({ width: 90, height: 90, padding: 3, opacity: 0.4, diff --git a/test/visual/golden/controls11group.png b/test/visual/golden/controls11group.png new file mode 100644 index 0000000000000000000000000000000000000000..31af2e2c52effb2e0a54b5c6d40953a83a14a62d GIT binary patch literal 1142 zcmeAS@N?(olHy`uVBq!ia0vp^(|~vj2OE$qOTBs@NU7mjX@L_tLzC8`N7@~r!`|6lIy zC(qNX?P_zXwm#|t*>~d>H^-N~Q#Mt)Ev3u>V^%LVZ&dOTtSKacdATalv zegB^0_kFM4ygd88^k%)o|26&?thS2&Z5n^afAzEVb(?!G|9tvP{`ZCdT-%Ks4L?UK zVh^&z=l7gfpMBoy{pB^)SL@C$`z|Q4dEs@g^Q&Lg6n^=6`t+%{cXOY2y;-wrW@vBq z+7Fx7Rog$?Ri(q2d;L??!&5VKqmAp%Ctpj=-hLy$DE{G$!&U~~iKVZt>rUGoCoP70 za^3e|w7S!K-Kb^j!qdCn?fp1w!;Lcw^Y(~6uoM$?&d;-6yK42(i_819-@mTv++_ZJ zvr1;^nQ3b!_shO;KKYvFyN%pMf5ziNyGQt<2AyD)~dVF1X$eIa~Mg zW5?rI^)*7*j=AlzzOPZ)=X&Hr_?q9^r%isV8Kiwvu=V?YMFdw7}?EC{0JN{euYpq%KD%$pM;`yIzC!puKr0mZT or#J7Au?q+0L{?yFfdZ62%P$suscG{`{Srvr)78&qol`;+08o??MgRZ+ literal 0 HcmV?d00001