]> _ Git - fluidbook-toolbox.git/commitdiff
wait #7252 @4
authorVincent Vanwaelscappel <vincent@cubedesigners.com>
Thu, 13 Mar 2025 14:37:43 +0000 (15:37 +0100)
committerVincent Vanwaelscappel <vincent@cubedesigners.com>
Thu, 13 Mar 2025 14:37:43 +0000 (15:37 +0100)
app/Fluidbook/Compiler/Compiler.php
app/Fluidbook/Compiler/Links.php

index fa258d199c810fa5b8e54d4ee0f9fa43a9176cd3..f9d182881abdcb4aebb2e5a9f0cf52e294cd1102 100644 (file)
@@ -334,7 +334,6 @@ class Compiler extends Base implements CompilerInterface, IVirtualDirectoryError
 
         PHP::memoryAllocate('12G');
 
-
         $this->log('Start compilation');
 
         $this->dir = $this->getFluidbook()->getFinalPath($theme, $scormVariant);
index c142531c3d2fed92dcea03e1a3edbebaf6057aa7..15648d2839ce840c13c38ecc4174e4f8f77087f0 100644 (file)
@@ -117,6 +117,9 @@ trait Links
 
         foreach ($linksCopy as $k => $linkData) {
 
+            if (stristr($linkData['to'], 'javascript:canvasToPDF(')) {
+                $this->addJsLib('jspdf', ['js/libs/jspdf.min.js']);
+            }
 
             if ($linkData['type'] == Link::EVENT_OVERLAY) {
                 if ($linkData['page'] % 2 == 1 || $linkData['left'] > $this->getWidthForLinks()) {