From: Vincent Vanwaelscappel Date: Mon, 16 Jun 2025 11:06:03 +0000 (+0200) Subject: wip #7588 @1 X-Git-Url: http://git.cubedesigners.com/?a=commitdiff_plain;h=67d07ca409fa965161346ff08d7976d3b8581eda;p=fluidbook-toolbox.git wip #7588 @1 --- diff --git a/app/Elearning/QuizCompiler.php b/app/Elearning/QuizCompiler.php index b53ace60a..d2fdbd5eb 100644 --- a/app/Elearning/QuizCompiler.php +++ b/app/Elearning/QuizCompiler.php @@ -170,15 +170,17 @@ class QuizCompiler extends Base $this->sassVariables['nok-color'] = $this->theme->nokColor; $this->sassVariables['card-disabled-background'] = $darkTheme ? $this->theme->neutralColor : $textsColor; $this->sassVariables['card-disabled-color'] = $darkTheme ? $textsColor : $oppositeTextsColor; + // Active colors + $this->sassVariables['stroke-color'] = $this->theme->strokeColor ?: 'rgba($texts-color, .24)'; + $this->sassVariables['active-stroke-color'] = $this->theme->activeStrokeColor ?: $textsColor; + $this->sassVariables['active-background-color'] = $this->theme->activeBackgroundColor ?: 'rgba($neutral-color,.8)'; // Fonts size:Line Height $this->sassVariables['fonts-size'] = "(14: 20px, 16: 22px, 20: 28px, 24: 35px)"; - // fill areas $this->sassVariables['intro-fill-area'] = $this->theme->introColor ?: 'transparent'; $this->sassVariables['outro-fill-area'] = $this->theme->outroColor ?: 'transparent'; $this->sassVariables['standard-fill-area'] = $this->theme->standardColor ?: 'transparent'; $this->sassVariables['drangandrop-fill-area'] = $this->theme->draganddropColor ?: 'transparent'; - // Main background $this->sassVariables['background-color'] = Color::colorToCSS($this->theme->backgroundColor); diff --git a/app/Models/QuizTheme.php b/app/Models/QuizTheme.php index 907ead57f..7b27b776f 100644 --- a/app/Models/QuizTheme.php +++ b/app/Models/QuizTheme.php @@ -84,6 +84,11 @@ class QuizTheme extends ToolboxModel $this->addField('neutralColor', Color::class, __('Couleur neutre principale'), ['hint' => __('Couleur des éléments d\'habillage du thème (privilégier une couleur foncée)')]); $this->addField('okColor', Color::class, __('Couleur OK'), ['hint' => __('Couleur générale affectée aux bonnes réponses (habituellement vert)')]); $this->addField('nokColor', Color::class, __('Couleur pas OK'), ['hint' => __('Couleur générale affectée aux mauvaises réponses (habituellement rouge)')]); + $this->addField('', FormSeparator::class); + $this->addField('strokeColor', Color::class, __('Couleur de contour des tuiles non-sélectionnées'), ['hint' => __('Laisser vide pour laisser le système déterminer la couleur'), 'allows_empty' => true]); + $this->addField('', FormSeparator::class); + $this->addField('activeStrokeColor', Color::class, __('Couleur de contour des tuiles sélectionnées'), ['hint' => __('Laisser vide pour laisser le système déterminer la couleur'), 'allows_empty' => true]); + $this->addField('activeBackgroundColor', Color::class, __('Couleur de fond des tuiles sélectionnées'), ['hint' => __('Laisser vide pour laisser le système déterminer la couleur'), 'allows_empty' => true]); }