From 6f978300fb022839ed4ef44dc57d4c8b4ef03b53 Mon Sep 17 00:00:00 2001 From: "vincent@cubedesigners.com" Date: Fri, 24 Dec 2021 09:42:06 +0000 Subject: [PATCH] wait #4993 @0.25 --- inc/ws/Metier/class.ws.book.parametres.php | 3 +- .../html5/master/class.ws.html5.compiler.php | 61 ++++++++++++++++++- 2 files changed, 62 insertions(+), 2 deletions(-) diff --git a/inc/ws/Metier/class.ws.book.parametres.php b/inc/ws/Metier/class.ws.book.parametres.php index 881083b83..9210069c2 100644 --- a/inc/ws/Metier/class.ws.book.parametres.php +++ b/inc/ws/Metier/class.ws.book.parametres.php @@ -740,8 +740,9 @@ class wsBookParametres extends wsParametres $this->fields['offlineWindowsInstallPath'] = ['type' => 'text', 'default' => '', 'editable' => true, 'label' => __('Chemin d\'installation par défaut'), 'hint' => __('Par défaut') . ': %LOCALAPPDATA%/%title%']; $this->fields['offlineWindowsProfilePath'] = ['type' => 'text', 'default' => '', 'editable' => true, 'label' => __('Répertoire de stockage du profile'), 'hint' => __('Par défaut') . ': %LOCALAPPDATA%/%title%']; $this->fields['offlineEnableAdvancedPrinting'] = ['type' => 'boolean', 'default' => true, 'editable' => true, 'label' => __('Activer le menu d\'impression avancée')]; + $this->fields['debugConsole'] = ['type' => 'boolean', 'default' => false, 'editable' => true, 'label' => __('Activer la console de débuggage')]; $this->forms['offline'] = array('label' => __('Version offline'), - 'fieldsnames' => array('offlineTitle', 'offlineLink', '|', 'offlineWindowsInstallPath', 'offlineWindowsProfilePath', '|', 'offlineEnableAdvancedPrinting')); + 'fieldsnames' => array('offlineTitle', 'offlineLink', '|', 'offlineWindowsInstallPath', 'offlineWindowsProfilePath', '|', 'offlineEnableAdvancedPrinting','|','debugConsole')); $this->fields['mobilefirstFluidbookId'] = ['type' => 'text', 'default' => '', 'editable' => true, 'label' => 'Identifiant du fluidbook "Mobile first"', 'grade' => 5]; $this->fields['mobilefirstBreakpoint'] = ['type' => 'text', 'default' => '640', 'editable' => true, 'label' => 'Breakpoint du passage à la version "Mobile first" (en pixels)', 'grade' => 5]; diff --git a/inc/ws/Util/html5/master/class.ws.html5.compiler.php b/inc/ws/Util/html5/master/class.ws.html5.compiler.php index 21f89381b..f52949350 100644 --- a/inc/ws/Util/html5/master/class.ws.html5.compiler.php +++ b/inc/ws/Util/html5/master/class.ws.html5.compiler.php @@ -1493,8 +1493,67 @@ height="0" width="0" style="display:none;visibility:hidden"> } $lang = $this->book->lang; + $console = ''; + if ($this->book->parametres->debugConsole) { + $console = '
+
+ +'; + } + $this->log('Got index vars 5'); - $vars = array('lang', 'titre', 'credits', 'style', 'script', 'pagesContents', 'print', 'hiddenContents', 'splash', 'splashstyles', 'cache', 'bgcolor', 'message', 'favicon', 'svg', 'beginbody', 'csp', 'opengraph', 'twittercard', 'description'); + $vars = array('lang', 'titre', 'credits', 'style', 'script', 'pagesContents', 'print', 'hiddenContents', 'splash', 'splashstyles', 'cache', 'bgcolor', 'message', 'favicon', 'svg', 'beginbody', 'csp', 'opengraph', 'twittercard', 'description', 'console'); $res = []; foreach ($vars as $v) { -- 2.39.5