From: Vincent Vanwaelscappel Date: Thu, 1 Aug 2024 16:17:04 +0000 (+0200) Subject: wip #7034 @0.5 X-Git-Url: http://git.cubedesigners.com/?a=commitdiff_plain;h=f33639fa98250e15ad05adfd1a86bbccc455fee1;p=fluidbook-toolbox.git wip #7034 @0.5 --- diff --git a/app/Fluidbook/Compiler/Compiler.php b/app/Fluidbook/Compiler/Compiler.php index d3b46fdac..6e0e71847 100644 --- a/app/Fluidbook/Compiler/Compiler.php +++ b/app/Fluidbook/Compiler/Compiler.php @@ -53,6 +53,7 @@ class Compiler extends Base implements CompilerInterface, IVirtualDirectoryError use Tabs; use PDF; use Screensaver; + use PWA; /** @var Lock */ protected $lock; @@ -752,6 +753,8 @@ class Compiler extends Base implements CompilerInterface, IVirtualDirectoryError $this->log('Search written'); $this->writeAccessibility(); $this->log('Accessibility written'); + $this->writePWA(); + $this->log('PWA written'); $this->writeExtras(); $this->log('Extras written'); $this->populateConfig(); @@ -1131,8 +1134,10 @@ class Compiler extends Base implements CompilerInterface, IVirtualDirectoryError '; } + $pwa = $this->getPWAMarkup(); + $this->log('Got index vars 5'); - $vars = array('lang', 'titre', 'credits', 'style', 'script', 'pagesContents', 'print', 'splash', 'splashstyles', 'cache', 'bgcolor', 'message', 'favicon', 'svg', 'beginbody', 'csp', 'opengraph', 'twittercard', 'description', 'console'); + $vars = array('lang', 'titre', 'credits', 'style', 'script', 'pagesContents', 'print', 'splash', 'splashstyles', 'cache', 'bgcolor', 'message', 'favicon', 'svg', 'beginbody', 'csp', 'opengraph', 'twittercard', 'description', 'console', 'pwa'); $res = []; foreach ($vars as $v) { diff --git a/app/Fluidbook/Compiler/PWA.php b/app/Fluidbook/Compiler/PWA.php new file mode 100644 index 000000000..946a93531 --- /dev/null +++ b/app/Fluidbook/Compiler/PWA.php @@ -0,0 +1,22 @@ +config->pwa_ios) { + $res .= ' + + '; + } + return $res; + } +}