From 6b8c57625d4634effe1a43fdc88d42165253682e Mon Sep 17 00:00:00 2001 From: "vincent@cubedesigners.com" Date: Tue, 2 Apr 2019 14:05:59 +0000 Subject: [PATCH] wip #2660 @0:20 --- inc/ws/Metier/class.ws.theme.parametres.php | 503 +++++++++--------- .../html5/master/class.ws.html5.compiler.php | 1 + .../html5/master/class.ws.html5.links.php | 2 +- 3 files changed, 256 insertions(+), 250 deletions(-) diff --git a/inc/ws/Metier/class.ws.theme.parametres.php b/inc/ws/Metier/class.ws.theme.parametres.php index 21106428d..be6d4eb1a 100644 --- a/inc/ws/Metier/class.ws.theme.parametres.php +++ b/inc/ws/Metier/class.ws.theme.parametres.php @@ -1,278 +1,283 @@ parent)) { - return; - } + public function initFields() + { + if (is_null($this->parent)) { + return; + } - $themeRoot = 'fluidbook/themes/' . $this->parent->theme_id; + $themeRoot = 'fluidbook/themes/' . $this->parent->theme_id; - parent::initFields(); - /* Navigation */ - $this->fields['arrowsTheme'] = array('type' => 'boolean', "default" => false, "editable" => true, "label" => __('Nouveau thème')); - $this->fields['couleurA'] = array('type' => 'couleurAlpha', 'default' => 'ff000000', 'editable' => true, - 'label' => __("Couleur de fond")); - $this->fields['arrowsColor'] = array('type' => 'couleur', 'default' => 'ffffff', 'editable' => true, - 'label' => __('Couleur des flèches')); - $this->fields['shadeOnArrows'] = array('type' => 'boolean', 'default' => true, 'editable' => true, 'label' => __('Ombre portée sous les flèches')); + parent::initFields(); + /* Navigation */ + $this->fields['arrowsTheme'] = array('type' => 'boolean', "default" => false, "editable" => true, "label" => __('Nouveau thème')); + $this->fields['couleurA'] = array('type' => 'couleurAlpha', 'default' => 'ff000000', 'editable' => true, + 'label' => __("Couleur de fond")); + $this->fields['arrowsColor'] = array('type' => 'couleur', 'default' => 'ffffff', 'editable' => true, + 'label' => __('Couleur des flèches')); + $this->fields['shadeOnArrows'] = array('type' => 'boolean', 'default' => true, 'editable' => true, 'label' => __('Ombre portée sous les flèches')); - $this->forms['bouton'] = array('label' => __('Personnalisation des boutons'), - 'fieldsnames' => array('couleurA', 'arrowsColor', 'shadeOnArrows', 'arrowsTheme')); - /* Submenus */ - $this->fields['popupVideoOverlay'] = array('type' => 'couleurAlpha', 'default' => '4D000000', 'editable' => true, - 'label' => __('Overlay placé sous les menus en popup')); - $this->fields['couleurB'] = array('type' => 'couleurAlpha', 'default' => 'ff000000', 'editable' => true, - 'label' => __("Couleur de fond")); - $this->fields['subSecondaryColor'] = array('type' => 'text', 'default' => '', 'editable' => true, 'size' => 6, - 'label' => __("Couleur secondaire pour la version HTML5 (boutons)")); - $this->fields['subTextColor'] = array('type' => 'couleur', 'default' => 'ffffffff', 'editable' => true, - 'label' => __("Couleur du texte")); - $this->fields['subSelectColor'] = array('type' => 'couleurAlpha', 'default' => 'ffffffff', 'editable' => true, - 'label' => __("Couleur des zones de sélection")); - $this->fields['subTextSelectColor'] = array('type' => 'couleur', 'default' => '000000', 'editable' => true, - 'label' => __("Couleur des textes des zones de sélection")); - $this->fields['subTextFieldColor'] = array('type' => 'couleur', 'default' => '000000', 'editable' => true, - 'label' => __("Couleur des textes des champs d'édition")); - $this->fields['subFieldColor'] = array('type' => 'couleurAlpha', 'default' => 'ffffffff', 'editable' => true, - 'label' => __("Couleur des champs d'édition")); - $this->fields['subStrokeWidth'] = array('type' => 'integer', 'default' => 0, "editable" => true, 'label' => __('Largeur du contour')); - $this->fields['subStrokeColor'] = array('type' => 'couleur', 'default' => 'ffffff', "editable" => true, 'label' => __('Couleur du contour')); - $this->fields['subShade'] = array('type' => 'couleurAlpha', 'default' => '00000000', "editable" => true, 'label' => __('Ombre sous le sous-menu')); - $this->fields['subRound'] = array('type' => 'integer', 'default' => 10, "editable" => true, 'label' => __('Arrondi')); - $this->fields['subButtonCustom'] = array('type' => 'boolean', 'default' => false, 'editable' => true, 'label' => __('Personnalisation des boutons')); - $this->fields['subButtonBackground'] = array('type' => 'couleur', 'default' => 'cccccc', 'editable' => true, 'label' => __('Couleur de fond')); - $this->fields['subButtonColor'] = array('type' => 'couleur', 'default' => '000000', 'editable' => true, 'label' => __('Couleur du texte')); - $this->fields['subButtonDecoration'] = array('type' => 'couleur', 'default' => '797979', 'editable' => true, 'label' => __('Couleur des décorations')); - $this->fields['subCrossCircle'] = array('type' => 'boolean', 'default' => true, 'editable' => true, 'label' => __('Afficher un cercle sous la croix de fermeture')); + $this->forms['bouton'] = array('label' => __('Personnalisation des boutons'), + 'fieldsnames' => array('couleurA', 'arrowsColor', 'shadeOnArrows', 'arrowsTheme')); + /* Submenus */ + $this->fields['popupVideoOverlay'] = array('type' => 'couleurAlpha', 'default' => '4D000000', 'editable' => true, + 'label' => __('Overlay placé sous les menus en popup')); + $this->fields['couleurB'] = array('type' => 'couleurAlpha', 'default' => 'ff000000', 'editable' => true, + 'label' => __("Couleur de fond")); + $this->fields['subSecondaryColor'] = array('type' => 'text', 'default' => '', 'editable' => true, 'size' => 6, + 'label' => __("Couleur secondaire pour la version HTML5 (boutons)")); + $this->fields['subTextColor'] = array('type' => 'couleur', 'default' => 'ffffffff', 'editable' => true, + 'label' => __("Couleur du texte")); + $this->fields['subSelectColor'] = array('type' => 'couleurAlpha', 'default' => 'ffffffff', 'editable' => true, + 'label' => __("Couleur des zones de sélection")); + $this->fields['subTextSelectColor'] = array('type' => 'couleur', 'default' => '000000', 'editable' => true, + 'label' => __("Couleur des textes des zones de sélection")); + $this->fields['subTextFieldColor'] = array('type' => 'couleur', 'default' => '000000', 'editable' => true, + 'label' => __("Couleur des textes des champs d'édition")); + $this->fields['subFieldColor'] = array('type' => 'couleurAlpha', 'default' => 'ffffffff', 'editable' => true, + 'label' => __("Couleur des champs d'édition")); + $this->fields['subStrokeWidth'] = array('type' => 'integer', 'default' => 0, "editable" => true, 'label' => __('Largeur du contour')); + $this->fields['subStrokeColor'] = array('type' => 'couleur', 'default' => 'ffffff', "editable" => true, 'label' => __('Couleur du contour')); + $this->fields['subShade'] = array('type' => 'couleurAlpha', 'default' => '00000000', "editable" => true, 'label' => __('Ombre sous le sous-menu')); + $this->fields['subRound'] = array('type' => 'integer', 'default' => 10, "editable" => true, 'label' => __('Arrondi')); + $this->fields['subButtonCustom'] = array('type' => 'boolean', 'default' => false, 'editable' => true, 'label' => __('Personnalisation des boutons')); + $this->fields['subButtonBackground'] = array('type' => 'couleur', 'default' => 'cccccc', 'editable' => true, 'label' => __('Couleur de fond')); + $this->fields['subButtonColor'] = array('type' => 'couleur', 'default' => '000000', 'editable' => true, 'label' => __('Couleur du texte')); + $this->fields['subButtonDecoration'] = array('type' => 'couleur', 'default' => '797979', 'editable' => true, 'label' => __('Couleur des décorations')); + $this->fields['subCrossCircle'] = array('type' => 'boolean', 'default' => true, 'editable' => true, 'label' => __('Afficher un cercle sous la croix de fermeture')); - $this->forms['menu'] = array('label' => __('Personnalisation des menus'), - 'fieldsnames' => array('couleurB', 'subSecondaryColor', 'subTextColor', '|', 'subCrossCircle', '|', 'subSelectColor', 'subTextSelectColor', '|', 'subTextFieldColor', 'subFieldColor', - '|', 'subStrokeWidth', 'subStrokeColor', 'subShade', 'subRound', - '|', 'subButtonCustom', 'subButtonBackground', 'subButtonColor', 'subButtonDecoration', "|", 'popupVideoOverlay') - ); + $this->forms['menu'] = array('label' => __('Personnalisation des menus'), + 'fieldsnames' => array('couleurB', 'subSecondaryColor', 'subTextColor', '|', 'subCrossCircle', '|', 'subSelectColor', 'subTextSelectColor', '|', 'subTextFieldColor', 'subFieldColor', + '|', 'subStrokeWidth', 'subStrokeColor', 'subShade', 'subRound', + '|', 'subButtonCustom', 'subButtonBackground', 'subButtonColor', 'subButtonDecoration', "|", 'popupVideoOverlay') + ); - /* Search */ - $this->fields['couleurS'] = array('type' => 'couleur', 'default' => '000000', 'editable' => true, - 'label' => __("Couleur du texte")); - $this->fields['searchFieldColor'] = array('type' => 'couleur', 'default' => 'ffffff', 'editable' => true, - 'label' => __("Couleur du champs de saisie")); - $this->fields['searchShadeAlpha'] = array('type' => 'integer', 'default' => 0, 'editable' => true, - 'label' => __("Intensité de l'ombre dans le champ de saisie"), - 'min' => 0, 'max' => 100); - $this->fields['highlightColor'] = array('type' => 'couleur', 'default' => '00ff00', 'editable' => true, - 'label' => __("Couleur du surlignage des résultats")); - $this->fields['searchFieldWidth'] = array('type' => 'integer', 'default' => 230, 'editable' => true, - 'label' => __("Largeur du champ de recherche")); - $this->fields['searchIndexNoResultColor'] = array('type' => 'couleurAlpha', 'default' => 'CC000000', 'editable' => true, - 'label' => __("Couleur de l'overlay (aucun résultat)"), - 'grade' => 5); + /* Search */ + $this->fields['couleurS'] = array('type' => 'couleur', 'default' => '000000', 'editable' => true, + 'label' => __("Couleur du texte")); + $this->fields['searchFieldColor'] = array('type' => 'couleur', 'default' => 'ffffff', 'editable' => true, + 'label' => __("Couleur du champs de saisie")); + $this->fields['searchShadeAlpha'] = array('type' => 'integer', 'default' => 0, 'editable' => true, + 'label' => __("Intensité de l'ombre dans le champ de saisie"), + 'min' => 0, 'max' => 100); + $this->fields['highlightColor'] = array('type' => 'couleur', 'default' => '00ff00', 'editable' => true, + 'label' => __("Couleur du surlignage des résultats")); + $this->fields['searchFieldWidth'] = array('type' => 'integer', 'default' => 230, 'editable' => true, + 'label' => __("Largeur du champ de recherche")); + $this->fields['searchIndexNoResultColor'] = array('type' => 'couleurAlpha', 'default' => 'CC000000', 'editable' => true, + 'label' => __("Couleur de l'overlay (aucun résultat)"), + 'grade' => 5); - $this->forms['search'] = array('label' => __('Personnalisation de la recherche'), - 'fieldsnames' => array('couleurS', 'searchFieldColor', 'searchShadeAlpha', 'searchFieldWidth', '|', 'highlightColor', '|', 'searchIndexNoResultColor')); - /* Icones */ - $this->fields['iconSet'] = array('type' => 'icones', 'default' => 15, 'editable' => true, - 'label' => __("Jeu d'icônes")); - $this->fields['colorizeIcons'] = array('type' => 'boolean', 'default' => false, 'editable' => true, - 'label' => __('Colorier les icônes')); - $this->fields['couleurI'] = array('type' => 'couleur', 'default' => '$couleurA', 'editable' => true, - 'label' => __("Couleur des icônes")); - $this->fields['iconShadeColor'] = array('type' => 'couleurAlpha', 'default' => '00000000', 'editable' => true, - 'label' => __("Couleur de l'effet de rollover")); - $this->fields['iconsHMargin'] = array('type' => 'integer', 'default' => 15, 'editable' => true, - 'label' => __('Espace entre les icônes'), 'min' => 0, 'max' => 50); + $this->forms['search'] = array('label' => __('Personnalisation de la recherche'), + 'fieldsnames' => array('couleurS', 'searchFieldColor', 'searchShadeAlpha', 'searchFieldWidth', '|', 'highlightColor', '|', 'searchIndexNoResultColor')); + /* Icones */ + $this->fields['iconSet'] = array('type' => 'icones', 'default' => 15, 'editable' => true, + 'label' => __("Jeu d'icônes")); + $this->fields['colorizeIcons'] = array('type' => 'boolean', 'default' => false, 'editable' => true, + 'label' => __('Colorier les icônes')); + $this->fields['couleurI'] = array('type' => 'couleur', 'default' => '$couleurA', 'editable' => true, + 'label' => __("Couleur des icônes")); + $this->fields['iconShadeColor'] = array('type' => 'couleurAlpha', 'default' => '00000000', 'editable' => true, + 'label' => __("Couleur de l'effet de rollover")); + $this->fields['iconsHMargin'] = array('type' => 'integer', 'default' => 15, 'editable' => true, + 'label' => __('Espace entre les icônes'), 'min' => 0, 'max' => 50); - $this->fields['fontKit'] = array('type' => 'combo', 'default' => 'auto', 'editable' => true, - 'label' => __('Police de caractères'), 'datas' => array(__('Automatique') => 'auto', - 'VAG Rounded' => 'vagrounded', - 'Gill' => 'gill')); + $this->fields['fontKit'] = array('type' => 'combo', 'default' => 'auto', 'editable' => true, + 'label' => __('Police de caractères'), 'datas' => array(__('Automatique') => 'auto', + 'VAG Rounded' => 'vagrounded', + 'Gill' => 'gill')); - $this->forms['icones'] = array('label' => __('Personnalisation des icônes'), - 'fieldsnames' => array('iconSet', 'iconShadeColor', '|', 'iconsHMargin', '|', 'colorizeIcons', 'couleurI', '|', 'fontKit')); + $this->forms['icones'] = array('label' => __('Personnalisation des icônes'), + 'fieldsnames' => array('iconSet', 'iconShadeColor', '|', 'iconsHMargin', '|', 'colorizeIcons', 'couleurI', '|', 'fontKit')); - /* Book */ - $this->fields['bookShadeColor'] = array('type' => 'couleurAlpha', 'default' => '66000000', 'editable' => true, - 'label' => __("Couleur de l'ombre sous la publication")); - $this->fields['shadeAlpha'] = array('type' => 'integer', 'default' => 100, 'editable' => true, - 'label' => __('Transparence des ombres et reflets sur les pages'), - 'min' => 0, 'max' => 100); - $this->fields['pageReflection'] = array('type' => 'boolean', 'default' => false, 'editable' => true, - 'label' => __("Afficher le reflet sur la page")); - $this->fields['usePageEdges'] = array('type' => 'boolean', 'default' => true, 'editable' => true, - 'label' => __("Afficher la bordure des pages")); - $this->fields['displayPageNumber'] = array('type' => 'boolean', 'default' => true, 'editable' => true, - 'label' => __('Afficher les numéros de page')); - $this->fields['colorPageNumber'] = array('type' => 'couleur', 'default' => 'ffffff', 'editable' => true, - 'label' => __('Couleur des numéros de page')); - $this->fields['linksColor'] = array('type' => 'couleur', 'default' => '$couleurA', 'editable' => true, - 'label' => __('Couleur des liens')); - $this->fields['videoBackgroundColor'] = array('type' => 'couleur', 'default' => '000000', 'editable' => true, - 'label' => __('Couleur de fond des videos')); + /* Book */ + $this->fields['bookShadeColor'] = array('type' => 'couleurAlpha', 'default' => '66000000', 'editable' => true, + 'label' => __("Couleur de l'ombre sous la publication")); + $this->fields['shadeAlpha'] = array('type' => 'integer', 'default' => 100, 'editable' => true, + 'label' => __('Transparence des ombres et reflets sur les pages'), + 'min' => 0, 'max' => 100); + $this->fields['pageReflection'] = array('type' => 'boolean', 'default' => false, 'editable' => true, + 'label' => __("Afficher le reflet sur la page")); + $this->fields['usePageEdges'] = array('type' => 'boolean', 'default' => true, 'editable' => true, + 'label' => __("Afficher la bordure des pages")); + $this->fields['displayPageNumber'] = array('type' => 'boolean', 'default' => true, 'editable' => true, + 'label' => __('Afficher les numéros de page')); + $this->fields['colorPageNumber'] = array('type' => 'couleur', 'default' => 'ffffff', 'editable' => true, + 'label' => __('Couleur des numéros de page')); + $this->fields['linksColor'] = array('type' => 'couleur', 'default' => '$couleurA', 'editable' => true, + 'label' => __('Couleur des liens')); + $this->fields['videoBackgroundColor'] = array('type' => 'couleur', 'default' => '000000', 'editable' => true, + 'label' => __('Couleur de fond des videos')); - $this->fields['pageEdgeColor'] = array('type' => 'couleur', 'default' => 'dddddd', 'editable' => true, - 'label' => __('Couleur de la bordure')); - $this->fields['pageEdgeThickness'] = array('type' => 'integer', 'default' => 100, 'editable' => true, - 'label' => __('Epaisseur de la bordure')); - $this->fields['tooltipBackColor'] = array('type' => 'couleurAlpha', 'default' => 'CC000000', 'editable' => true, - 'label' => __("Couleur de fond des infobulles")); - $this->fields['tooltipTextColor'] = array('type' => 'couleur', 'default' => 'ffffff', 'editable' => true, - 'label' => __("Couleur du texte des infobulles")); - $this->fields['bookmarkBackgroundColor'] = array('type' => 'couleurAlpha', 'default' => 'ffadadad', 'editable' => true, - 'label' => __("Couleur de fond des marques-pages")); - $this->fields['bookmarkStarDisabledColor'] = array('type' => 'couleurAlpha', 'default' => '00ffffff', 'editable' => true, - 'label' => __("Couleur de l'étoile désactivée")); - $this->fields['bookmarkStarEnabledColor'] = array('type' => 'couleur', 'default' => 'ff7700', 'editable' => true, - 'label' => __("Couleur de l'étoile activée")); + $this->fields['pageEdgeColor'] = array('type' => 'couleur', 'default' => 'dddddd', 'editable' => true, + 'label' => __('Couleur de la bordure')); + $this->fields['pageEdgeThickness'] = array('type' => 'integer', 'default' => 100, 'editable' => true, + 'label' => __('Epaisseur de la bordure')); + $this->fields['tooltipBackColor'] = array('type' => 'couleurAlpha', 'default' => 'CC000000', 'editable' => true, + 'label' => __("Couleur de fond des infobulles")); + $this->fields['tooltipTextColor'] = array('type' => 'couleur', 'default' => 'ffffff', 'editable' => true, + 'label' => __("Couleur du texte des infobulles")); + $this->fields['tooltipTextSize'] = array('type' => 'integer', 'default' => 100, 'editable' => true, + 'label' => __('Taille du texte des infobulles')); + $this->fields['bookmarkBackgroundColor'] = array('type' => 'couleurAlpha', 'default' => 'ffadadad', 'editable' => true, + 'label' => __("Couleur de fond des marques-pages")); + $this->fields['bookmarkStarDisabledColor'] = array('type' => 'couleurAlpha', 'default' => '00ffffff', 'editable' => true, + 'label' => __("Couleur de l'étoile désactivée")); + $this->fields['bookmarkStarEnabledColor'] = array('type' => 'couleur', 'default' => 'ff7700', 'editable' => true, + 'label' => __("Couleur de l'étoile activée")); - $this->forms['book'] = array('label' => __('Personnalisation de la publication'), - 'fieldsnames' => array('pageReflection', 'shadeAlpha', - '|', 'usePageEdges', 'pageEdgeColor', 'pageEdgeThickness', - '|', 'bookShadeColor', - '|', 'displayPageNumber', 'colorPageNumber', - '|', 'linksColor', 'videoBackgroundColor', - '|', 'tooltipBackColor', 'tooltipTextColor', - '|', 'bookmarkBackgroundColor', 'bookmarkStarDisabledColor', 'bookmarkStarEnabledColor')); - /* Credits */ - $this->fields['creditsColor'] = array('type' => 'couleurAlpha', 'default' => '80ffffff', 'editable' => true, - 'label' => __("Couleur du texte")); + $this->forms['book'] = array('label' => __('Personnalisation de la publication'), + 'fieldsnames' => array('pageReflection', 'shadeAlpha', + '|', 'usePageEdges', 'pageEdgeColor', 'pageEdgeThickness', + '|', 'bookShadeColor', + '|', 'displayPageNumber', 'colorPageNumber', + '|', 'linksColor', 'videoBackgroundColor', + '|', 'tooltipBackColor', 'tooltipTextColor', 'tooltipTextSize', + '|', 'bookmarkBackgroundColor', 'bookmarkStarDisabledColor', 'bookmarkStarEnabledColor')); + /* Credits */ + $this->fields['creditsColor'] = array('type' => 'couleurAlpha', 'default' => '80ffffff', 'editable' => true, + 'label' => __("Couleur du texte")); - $this->forms['credits'] = array('label' => __('Personnalisation des crédits'), - 'fieldsnames' => array('creditsColor')); - /* Background */ - $this->fields['transparentBackground'] = array('type' => 'boolean', 'default' => false, 'editable' => true, - 'label' => __('Fond transparent'), 'hint' => __("Si cette option est cochée, aucun fond ne sera pris en compte (ni l'image, ni la couleur)")); - $this->fields['backgroundColor'] = array('type' => 'couleur', 'default' => 'ffffff', 'editable' => true, - 'label' => __("Couleur du fond")); - $this->fields['backgroundImage'] = array('type' => 'file', 'default' => 'backgroundImg.jpg', 'editable' => true, - 'label' => __('Image de fond'), - 'path' => $themeRoot, - 'uploadURL' => SITE_PATH . 'flash/uploadThemeFile/?theme_id=' . $this->parent->theme_id); - $this->fields['repeat'] = array('type' => 'combo', - 'datas' => array(__('Etirer') => wsTheme::STRETCH, - __('Etirer le fond en conservant les proportions') => wsTheme::RATIO, - __("Répéter") => wsTheme::REPEAT, - __('Ne pas répéter ni étirer') => wsTheme::NONE), - 'default' => 0, 'editable' => true, 'label' => __('Affichage du fond')); - $this->fields['backgroundHAlign'] = array('type' => 'combo', - 'datas' => array(__('Centré') => wsTheme::CENTER, - __('Gauche') => wsTheme::LEFT, - __("Droite") => wsTheme::RIGHT), - 'default' => wsTheme::CENTER, 'editable' => true, 'label' => __('Alignement Horizontal')); - $this->fields['backgroundVAlign'] = array('type' => 'combo', - 'datas' => array(__('Milieu') => wsTheme::MIDDLE, - __('Haut') => wsTheme::TOP, - __("Bas") => wsTheme::BOTTOM), - 'default' => wsTheme::MIDDLE, 'editable' => true, 'label' => __('Alignement Vertical')); - $this->fields['displayBackgroundDuringLoading'] = array('type' => 'boolean', 'default' => true, 'editable' => true, - 'label' => __('Afficher le fond pendant le chargement'), 'hint' => __("Si cette option est désactivée, le fond ne sera affiché qu'à la fin du chargement")); + $this->forms['credits'] = array('label' => __('Personnalisation des crédits'), + 'fieldsnames' => array('creditsColor')); + /* Background */ + $this->fields['transparentBackground'] = array('type' => 'boolean', 'default' => false, 'editable' => true, + 'label' => __('Fond transparent'), 'hint' => __("Si cette option est cochée, aucun fond ne sera pris en compte (ni l'image, ni la couleur)")); + $this->fields['backgroundColor'] = array('type' => 'couleur', 'default' => 'ffffff', 'editable' => true, + 'label' => __("Couleur du fond")); + $this->fields['backgroundImage'] = array('type' => 'file', 'default' => 'backgroundImg.jpg', 'editable' => true, + 'label' => __('Image de fond'), + 'path' => $themeRoot, + 'uploadURL' => SITE_PATH . 'flash/uploadThemeFile/?theme_id=' . $this->parent->theme_id); + $this->fields['repeat'] = array('type' => 'combo', + 'datas' => array(__('Etirer') => wsTheme::STRETCH, + __('Etirer le fond en conservant les proportions') => wsTheme::RATIO, + __("Répéter") => wsTheme::REPEAT, + __('Ne pas répéter ni étirer') => wsTheme::NONE), + 'default' => 0, 'editable' => true, 'label' => __('Affichage du fond')); + $this->fields['backgroundHAlign'] = array('type' => 'combo', + 'datas' => array(__('Centré') => wsTheme::CENTER, + __('Gauche') => wsTheme::LEFT, + __("Droite") => wsTheme::RIGHT), + 'default' => wsTheme::CENTER, 'editable' => true, 'label' => __('Alignement Horizontal')); + $this->fields['backgroundVAlign'] = array('type' => 'combo', + 'datas' => array(__('Milieu') => wsTheme::MIDDLE, + __('Haut') => wsTheme::TOP, + __("Bas") => wsTheme::BOTTOM), + 'default' => wsTheme::MIDDLE, 'editable' => true, 'label' => __('Alignement Vertical')); + $this->fields['displayBackgroundDuringLoading'] = array('type' => 'boolean', 'default' => true, 'editable' => true, + 'label' => __('Afficher le fond pendant le chargement'), 'hint' => __("Si cette option est désactivée, le fond ne sera affiché qu'à la fin du chargement")); - $this->forms['background'] = array('label' => __('Personnalisation du fond'), - 'fieldsnames' => array('transparentBackground', '|', 'backgroundColor', '|', 'backgroundImage', - 'repeat', 'backgroundHAlign', 'backgroundVAlign', '|', 'displayBackgroundDuringLoading')); - /* Menu bar */ - $this->fields['menuHeight'] = array('type' => 'integer', 'default' => 60, 'editable' => true, - 'label' => __('Hauteur (en pixels)')); - $this->fields['menuColor'] = array('type' => 'couleurAlpha', 'default' => 'ffffffff', 'editable' => true, - 'label' => __("Couleur du fond")); - $this->fields['shadeOnMenu'] = array('type' => 'boolean', 'default' => true, 'editable' => true, - 'label' => __('Ombre portée sous la barre du menu')); - $this->fields['menuImage'] = array('type' => 'file', 'default' => 'menu_back.png', 'editable' => true, - 'label' => __('Image de fond'), - 'path' => $themeRoot, - 'uploadURL' => SITE_PATH . 'flash/uploadThemeFile/?theme_id=' . $this->parent->theme_id); - $this->fields['invertMenuPosition'] = array('type' => 'boolean', 'default' => false, 'editable' => true, - 'label' => __("Intervertir le menu et le logo")); + $this->forms['background'] = array('label' => __('Personnalisation du fond'), + 'fieldsnames' => array('transparentBackground', '|', 'backgroundColor', '|', 'backgroundImage', + 'repeat', 'backgroundHAlign', 'backgroundVAlign', '|', 'displayBackgroundDuringLoading')); + /* Menu bar */ + $this->fields['menuHeight'] = array('type' => 'integer', 'default' => 60, 'editable' => true, + 'label' => __('Hauteur (en pixels)')); + $this->fields['menuColor'] = array('type' => 'couleurAlpha', 'default' => 'ffffffff', 'editable' => true, + 'label' => __("Couleur du fond")); + $this->fields['shadeOnMenu'] = array('type' => 'boolean', 'default' => true, 'editable' => true, + 'label' => __('Ombre portée sous la barre du menu')); + $this->fields['menuImage'] = array('type' => 'file', 'default' => 'menu_back.png', 'editable' => true, + 'label' => __('Image de fond'), + 'path' => $themeRoot, + 'uploadURL' => SITE_PATH . 'flash/uploadThemeFile/?theme_id=' . $this->parent->theme_id); + $this->fields['invertMenuPosition'] = array('type' => 'boolean', 'default' => false, 'editable' => true, + 'label' => __("Intervertir le menu et le logo")); - $this->fields['topBar'] = array('type' => 'file', 'default' => '', 'editable' => true, - 'label' => __('Top Bar'), - 'path' => $themeRoot, - 'uploadURL' => SITE_PATH . 'flash/uploadThemeFile/?theme_id=' . $this->parent->theme_id); - $this->fields['topBarAlign'] = array('type' => 'combo', - 'datas' => array(__('Centré') => wsTheme::CENTER, - __('Gauche') => wsTheme::LEFT, - __("Droite") => wsTheme::RIGHT), - 'default' => wsTheme::LEFT, 'editable' => true, 'label' => __('Alignement Horizontal de la Top Bar')); + $this->fields['topBar'] = array('type' => 'file', 'default' => '', 'editable' => true, + 'label' => __('Top Bar'), + 'path' => $themeRoot, + 'uploadURL' => SITE_PATH . 'flash/uploadThemeFile/?theme_id=' . $this->parent->theme_id); + $this->fields['topBarAlign'] = array('type' => 'combo', + 'datas' => array(__('Centré') => wsTheme::CENTER, + __('Gauche') => wsTheme::LEFT, + __("Droite") => wsTheme::RIGHT), + 'default' => wsTheme::LEFT, 'editable' => true, 'label' => __('Alignement Horizontal de la Top Bar')); - $this->fields['afterSearch'] = array('type' => 'file', 'default' => '', 'editable' => true, - 'label' => __('Image supplémentaire'), - 'path' => $themeRoot, - 'uploadURL' => SITE_PATH . 'flash/uploadThemeFile/?theme_id=' . $this->parent->theme_id, - 'hint' => __('Image disposée à droite du champ de recherche') - ); + $this->fields['afterSearch'] = array('type' => 'file', 'default' => '', 'editable' => true, + 'label' => __('Image supplémentaire'), + 'path' => $themeRoot, + 'uploadURL' => SITE_PATH . 'flash/uploadThemeFile/?theme_id=' . $this->parent->theme_id, + 'hint' => __('Image disposée à droite du champ de recherche') + ); - $this->forms['menubar'] = array('label' => __('Personnalisation de la barre de menu'), - 'fieldsnames' => array('menuHeight', '|', 'menuColor', '|', 'menuImage', '|', 'shadeOnMenu', '|', 'invertMenuPosition', '|', 'topBar', 'topBarAlign', '|', 'afterSearch')); - /* Menu bar logo */ + $this->forms['menubar'] = array('label' => __('Personnalisation de la barre de menu'), + 'fieldsnames' => array('menuHeight', '|', 'menuColor', '|', 'menuImage', '|', 'shadeOnMenu', '|', 'invertMenuPosition', '|', 'topBar', 'topBarAlign', '|', 'afterSearch')); + /* Menu bar logo */ - $imageFilter = new stdClass(); - $imageFilter->name = __('Image PNG ou SVG') . ' (*.png, *.svg)'; - $imageFilter->extensions = '*.svg;*.png'; + $imageFilter = new stdClass(); + $imageFilter->name = __('Image PNG ou SVG') . ' (*.png, *.svg)'; + $imageFilter->extensions = '*.svg;*.png'; - $this->fields['logo'] = array('type' => 'file', 'default' => 'menu_clientLogo.png', 'editable' => true, - 'label' => __('Logo'), - 'path' => $themeRoot, - 'uploadURL' => SITE_PATH . 'flash/uploadThemeFile/?theme_id=' . $this->parent->theme_id); - $this->fields['logoHideWhenOverriden'] = array('type' => 'boolean', 'default' => false, 'editable' => true, - 'label' => __("Cacher le logo lorsqu'il est partiellement masqué par la publication")); - $this->fields['favicon'] = array('type' => 'file', 'default' => '', 'editable' => true, - 'label' => __('Icone (pour favicon et CD-ROM)'), - 'path' => $themeRoot, - 'fileFilter' => $imageFilter, - 'uploadURL' => SITE_PATH . 'flash/uploadThemeFile/?theme_id=' . $this->parent->theme_id . '&type=favicon', - 'hint' => __('Image PNG de 256x256')); - $this->fields['iosicon'] = array('type' => 'file', 'default' => '', 'editable' => true, - 'label' => __('Icone (pour application iOS)'), - 'path' => $themeRoot, - 'fileFilter' => $imageFilter, - 'uploadURL' => SITE_PATH . 'flash/uploadThemeFile/?theme_id=' . $this->parent->theme_id . '&type=iosicon', - 'hint' => __('Image PNG de 1024x1024')); - $this->fields['androidicon'] = array('type' => 'file', 'default' => '', 'editable' => true, - 'label' => __('Icone (pour application Android)'), - 'path' => $themeRoot, - 'fileFilter' => $imageFilter, - 'uploadURL' => SITE_PATH . 'flash/uploadThemeFile/?theme_id=' . $this->parent->theme_id . '&type=androidicon', - 'hint' => __('Image PNG de 1024x1024')); + $this->fields['logo'] = array('type' => 'file', 'default' => 'menu_clientLogo.png', 'editable' => true, + 'label' => __('Logo'), + 'path' => $themeRoot, + 'uploadURL' => SITE_PATH . 'flash/uploadThemeFile/?theme_id=' . $this->parent->theme_id); + $this->fields['logoHideWhenOverriden'] = array('type' => 'boolean', 'default' => false, 'editable' => true, + 'label' => __("Cacher le logo lorsqu'il est partiellement masqué par la publication")); + $this->fields['favicon'] = array('type' => 'file', 'default' => '', 'editable' => true, + 'label' => __('Icone (pour favicon et CD-ROM)'), + 'path' => $themeRoot, + 'fileFilter' => $imageFilter, + 'uploadURL' => SITE_PATH . 'flash/uploadThemeFile/?theme_id=' . $this->parent->theme_id . '&type=favicon', + 'hint' => __('Image PNG de 256x256')); + $this->fields['iosicon'] = array('type' => 'file', 'default' => '', 'editable' => true, + 'label' => __('Icone (pour application iOS)'), + 'path' => $themeRoot, + 'fileFilter' => $imageFilter, + 'uploadURL' => SITE_PATH . 'flash/uploadThemeFile/?theme_id=' . $this->parent->theme_id . '&type=iosicon', + 'hint' => __('Image PNG de 1024x1024')); + $this->fields['androidicon'] = array('type' => 'file', 'default' => '', 'editable' => true, + 'label' => __('Icone (pour application Android)'), + 'path' => $themeRoot, + 'fileFilter' => $imageFilter, + 'uploadURL' => SITE_PATH . 'flash/uploadThemeFile/?theme_id=' . $this->parent->theme_id . '&type=androidicon', + 'hint' => __('Image PNG de 1024x1024')); - $this->forms['logo'] = array('label' => __('Personnalisation du logo'), - 'fieldsnames' => array('logo', 'logoHideWhenOverriden', '|', 'favicon', 'iosicon', 'androidicon')); - /* Loader */ - $this->fields['logoLoader'] = array('type' => 'file', 'default' => 'logoLoader.png', 'editable' => true, - 'label' => __('Logo affiché au chargement'), - 'path' => $themeRoot, - 'uploadURL' => SITE_PATH . 'flash/uploadThemeFile/?theme_id=' . $this->parent->theme_id); - $this->fields['couleurL'] = array('type' => 'couleur', 'default' => '', 'editable' => true, - 'label' => __("Couleur principale de la barre de chargement")); - $this->fields['loadingSecColor'] = array('type' => 'couleur', 'default' => 'ffffff', 'editable' => true, - 'label' => __("Couleur secondaire de la barre de chargement")); - $this->fields['loadingBackColor'] = array('type' => 'couleur', 'default' => 'ffffff', 'editable' => true, - 'label' => __("Couleur du fond affichée avant l'affichage de l'image de fond")); - $this->fields['loaderPosition'] = array('type' => 'boolean', 'default' => false, 'editable' => true, - 'label' => __('Placer le logo à gauche et le loader à droite'), 'grade' => 3); + $this->forms['logo'] = array('label' => __('Personnalisation du logo'), + 'fieldsnames' => array('logo', 'logoHideWhenOverriden', '|', 'favicon', 'iosicon', 'androidicon')); + /* Loader */ + $this->fields['logoLoader'] = array('type' => 'file', 'default' => 'logoLoader.png', 'editable' => true, + 'label' => __('Logo affiché au chargement'), + 'path' => $themeRoot, + 'uploadURL' => SITE_PATH . 'flash/uploadThemeFile/?theme_id=' . $this->parent->theme_id); + $this->fields['couleurL'] = array('type' => 'couleur', 'default' => '', 'editable' => true, + 'label' => __("Couleur principale de la barre de chargement")); + $this->fields['loadingSecColor'] = array('type' => 'couleur', 'default' => 'ffffff', 'editable' => true, + 'label' => __("Couleur secondaire de la barre de chargement")); + $this->fields['loadingBackColor'] = array('type' => 'couleur', 'default' => 'ffffff', 'editable' => true, + 'label' => __("Couleur du fond affichée avant l'affichage de l'image de fond")); + $this->fields['loaderPosition'] = array('type' => 'boolean', 'default' => false, 'editable' => true, + 'label' => __('Placer le logo à gauche et le loader à droite'), 'grade' => 3); - $this->forms['loader'] = array('label' => __('Personnalisation du loader'), - 'fieldsnames' => array('loadingBackColor', '|', 'couleurL', 'loadingSecColor', 'logoLoader', 'loaderPosition')); - /* Pages bar */ - $this->fields['pagesBar'] = array('type' => 'boolean', 'default' => true, 'editable' => true, - 'label' => __("Afficher la barre d'accès rapide aux pages")); - $this->fields['pageBarThumbBack'] = array('type' => 'couleurAlpha', 'default' => '80000000', 'editable' => true, - 'label' => __("Couleur de fond de la boîte")); - $this->fields['bookmarkColor'] = array('type' => 'couleur', 'default' => 'ffffff', 'editable' => true, - 'label' => __("Couleur des marques-pages")); + $this->forms['loader'] = array('label' => __('Personnalisation du loader'), + 'fieldsnames' => array('loadingBackColor', '|', 'couleurL', 'loadingSecColor', 'logoLoader', 'loaderPosition')); + /* Pages bar */ + $this->fields['pagesBar'] = array('type' => 'boolean', 'default' => true, 'editable' => true, + 'label' => __("Afficher la barre d'accès rapide aux pages")); + $this->fields['pageBarThumbBack'] = array('type' => 'couleurAlpha', 'default' => '80000000', 'editable' => true, + 'label' => __("Couleur de fond de la boîte")); + $this->fields['bookmarkColor'] = array('type' => 'couleur', 'default' => 'ffffff', 'editable' => true, + 'label' => __("Couleur des marques-pages")); - $this->forms['pagesbar'] = array('label' => __('Personnalisation de la barre des pages'), - 'fieldsnames' => array('pagesBar', 'pageBarThumbBack', '|', 'bookmarkColor')); + $this->forms['pagesbar'] = array('label' => __('Personnalisation de la barre des pages'), + 'fieldsnames' => array('pagesBar', 'pageBarThumbBack', '|', 'bookmarkColor')); - /* Paramètres non implémentés */ - /* $this->fields['extraXSpace'] = array('type' => 'integer', 'default' => '0', 'editable' => true, - 'label' => __('Marge supplémentaire horizontale'), 'min' => 0, 'max' => 200); - $this->fields['extraYSpace'] = array('type' => 'integer', 'default' => '0', 'editable' => true, - 'label' => __('Marge supplémentaire verticale'), 'min' => 0, 'max' => 200); */ - } + /* Paramètres non implémentés */ + /* $this->fields['extraXSpace'] = array('type' => 'integer', 'default' => '0', 'editable' => true, + 'label' => __('Marge supplémentaire horizontale'), 'min' => 0, 'max' => 200); + $this->fields['extraYSpace'] = array('type' => 'integer', 'default' => '0', 'editable' => true, + 'label' => __('Marge supplémentaire verticale'), 'min' => 0, 'max' => 200); */ + } } 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 36f61b631..331670a78 100644 --- a/inc/ws/Util/html5/master/class.ws.html5.compiler.php +++ b/inc/ws/Util/html5/master/class.ws.html5.compiler.php @@ -1919,6 +1919,7 @@ class wsHTML5Compiler #tooltip $lessVariables['tooltip-background'] = wsHTML5::colorToCSS($this->theme->parametres->tooltipBackColor); $lessVariables['tooltip-color'] = wsHTML5::colorToCSS($this->theme->parametres->tooltipTextColor); + $lessVariables['tooltip-font-size'] = 14 * ($this->theme->parametres->tooltipTextSize / 100); #fonts foreach ($this->cssfont as $hash => $item) { diff --git a/inc/ws/Util/html5/master/class.ws.html5.links.php b/inc/ws/Util/html5/master/class.ws.html5.links.php index 2c03fbb09..76e4b31a4 100644 --- a/inc/ws/Util/html5/master/class.ws.html5.links.php +++ b/inc/ws/Util/html5/master/class.ws.html5.links.php @@ -413,7 +413,7 @@ class normalLink extends wsHTML5Link } $t = $this->getTooltip(); if ($t !== false) { - $attrs .= ' data-tooltip="' . $t . '"'; + $attrs .= ' data-tooltip="' . htmlentities($t, ENT_QUOTES) . '"'; } if (isset($this->extra->blinkdelay)) { $attrs .= ' data-blinkdelay="' . intval($this->extra->blinkdelay) . '"'; -- 2.39.5