Skip to content

Commit 24a93f9

Browse files
committed
Hide canvas only for real online case
In all other situations try to display with default settings
1 parent d5cf394 commit 24a93f9

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

modules/gpad/RPadPainter.mjs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -561,7 +561,7 @@ class RPadPainter extends RObjectPainter {
561561
this.createAttFill({ pattern: 1001, color: 0 });
562562

563563
if ((rect.width <= lmt) || (rect.height <= lmt)) {
564-
if (!this.hasSnapId()) {
564+
if (this.getSnapId()) {
565565
svg.style('display', 'none');
566566
console.warn(`Hide canvas while geometry too small w=${rect.width} h=${rect.height}`);
567567
}

modules/gpad/TPadPainter.mjs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -823,7 +823,7 @@ class TPadPainter extends ObjectPainter {
823823
this.createAttFill({ attr: this.#pad });
824824

825825
if ((rect.width <= lmt) || (rect.height <= lmt)) {
826-
if (this.hasSnapId()) {
826+
if (this.getSnapId()) {
827827
svg.style('display', 'none');
828828
console.warn(`Hide canvas while geometry too small w=${rect.width} h=${rect.height}`);
829829
}

0 commit comments

Comments
 (0)