]> _ Git - fluidbook-toolbox.git/commitdiff
wait #6083 @0.25
authorVincent Vanwaelscappel <vincent@cubedesigners.com>
Mon, 26 Jun 2023 17:27:08 +0000 (19:27 +0200)
committerVincent Vanwaelscappel <vincent@cubedesigners.com>
Mon, 26 Jun 2023 17:27:08 +0000 (19:27 +0200)
resources/linkeditor/js/linkeditor.js

index e83ba587c3469ce346c76ce6a06abb4d76364048..dd3cd2a76fb47cf633e8e626147a7412b552c9f1 100644 (file)
@@ -62,7 +62,7 @@ $.ajaxSetup({
 
 function LinkEditor() {
     this.mobileFirst = FLUIDBOOK_DATA.settings.mobileNavigationType === 'mobilefirst';
-    this.single = ['mobilefirst', 'portrait'].indexOf(FLUIDBOOK_DATA.settings.mobileNavigationType) >= 0;
+    this.single = ['mobilefirst', 'portrait'].indexOf(FLUIDBOOK_DATA.settings.mobileNavigationType) >= 0 || FLUIDBOOK_DATA.settings.pages <= 1;
 
     this.pw = FLUIDBOOK_DATA.settings.width;
     this.ph = FLUIDBOOK_DATA.settings.height;
@@ -190,7 +190,7 @@ LinkEditor.prototype = {
             } else if (e.keyCode == 18) {
                 $("#linkeditor-main").addClass('duplicate');
 
-            } else if (e.key == '>' || e.keyCode===60 || e.keyCode===226) {
+            } else if (e.key == '>' || e.keyCode === 60 || e.keyCode === 226) {
                 $("#linkeditor-main").addClass('polygon');
             }
             $this.rulers.moveRuler();
@@ -204,7 +204,7 @@ LinkEditor.prototype = {
                 $this.zoom.resetZoomDrag();
             } else if (e.keyCode == 18) {
                 $("#linkeditor-main").removeClass('duplicate');
-            } else if (e.key == '>' || e.keyCode===60 || e.keyCode===226) {
+            } else if (e.key == '>' || e.keyCode === 60 || e.keyCode === 226) {
                 $("#linkeditor-main").removeClass('polygon');
                 $this.links.closePolygonShape();
             }