]> _ Git - fluidbook_tools.git/commitdiff
wip #6968 @3
authorVincent Vanwaelscappel <vincent@cubedesigners.com>
Thu, 20 Jun 2024 06:42:59 +0000 (08:42 +0200)
committerVincent Vanwaelscappel <vincent@cubedesigners.com>
Thu, 20 Jun 2024 06:42:59 +0000 (08:42 +0200)
src/Links/HTMLMultimediaLink.php
src/Links/Link.php
src/Links/NormalLink.php

index 090d10026b044f35ad6b402e9afc7b33d897461a..69577844bf20d515c2587c87474bad9a00cb9357 100644 (file)
@@ -30,12 +30,6 @@ class HTMLMultimediaLink extends Link
                 $d = $this->unzipFile($this->to, false);
                 $this->_config = $this->getConfigZIP($d['dir']);
                 $this->copyExternalDir($d['dir'], $d['fdir']);
-                if (file_exists($d['dir'] . '/index.html')) {
-                    $html = file_get_contents($d['dir'] . '/index.html');
-                    $html = str_replace('var pRatio = window.devicePixelRatio || 1,', 'var pRatio = 0.5,', $html);
-                    $this->_config['lowDef'] = 'index_ld.html';
-                    $this->compiler->getVirtualDirectory()->file_put_contents($d['fdir'] . '/' . $this->_config['lowDef'], $html);
-                }
             } elseif ($ext === 'html') {
                 $fdir = 'data/links';
                 $dir = $fdir;
index 314d4cf7a13c898ccf712161ed321b5e849edaf6..3602b398f75878c7d83455814b25908f2845f421 100644 (file)
@@ -127,6 +127,7 @@ class Link
     public $transition;
     public $polygon = '';
     public $cursor = '';
+    public $blinkdelay=0;
     protected $role = 'button';
 
 
index d13be07bdde772c0e0ec9ea2e07771428a841012..2251de83e98062dbcfac614ab8713dd3cf116030 100644 (file)
@@ -22,8 +22,8 @@ class NormalLink extends Link
             $attrs .= ' class="' . implode(' ', $class) . '"';
         }
         $attrs .= $this->getTooltipAttribute();
-        if (isset($this->extra->blinkdelay)) {
-            $attrs .= ' data-blinkdelay="' . intval($this->extra->blinkdelay) . '"';
+        if ($this->blinkdelay>0) {
+            $attrs .= ' data-blinkdelay="' . intval($this->blinkdelay) . '"';
         }
         return '<a href="' . $this->getURL() . '" data-type="' . $this->type . '" target="' . $this->getTarget() . '"' . $attrs . $this->getAdditionnalContent() . $this->getTrack() . '>' . $this->getInnerContent() . '</a>';
     }