]> _ Git - fluidbook_tools.git/commitdiff
wait #6866 @1.5
authorVincent Vanwaelscappel <vincent@cubedesigners.com>
Wed, 15 Oct 2025 09:29:04 +0000 (11:29 +0200)
committerVincent Vanwaelscappel <vincent@cubedesigners.com>
Wed, 15 Oct 2025 09:29:04 +0000 (11:29 +0200)
src/Links/ZoomLink.php

index 0f1851f51d764153f2ff656b0f0011497133f7a0..83da35680650cdd59c8cfc2ec003d518f115f072 100644 (file)
@@ -83,7 +83,7 @@ class ZoomLink extends NormalLink
 
     public function getZoomAttributes()
     {
-        return [
+        $res = [
             'id' => $this->uid,
             'page' => $this->page,
             'maxzoom' => empty($this->to) ? $this->maxzoom_default : $this->to,
@@ -96,6 +96,11 @@ class ZoomLink extends NormalLink
             'border' => $this->border,
             'borderColor' => $this->borderColor,
         ];
+
+        if (!$this->compiler->getSetting('zoomAreaShowTexts', true)) {
+            $res['layer'] = 'image';
+        }
+        return $res;
     }
 
     /**
@@ -126,6 +131,9 @@ class ZoomLink extends NormalLink
         if (isset($attributes['quality'])) {
             $extractOptions['quality'] = $attributes['quality'];
         }
+        if (!isset($attributes['texts'])) {
+            $attributes['texts'] = '';
+        }
 
         if (isset($attributes['layer']) && !in_array($attributes['layer'], ['image', 'text', 'onlytext', 'bothsvg', 'textmask'])) {
             unset($attributes['layer']);