diff --git a/src/addons/mod/quiz/components/index/index.scss b/src/addons/mod/quiz/components/index/index.scss index ead659221..c1958ffb6 100644 --- a/src/addons/mod/quiz/components/index/index.scss +++ b/src/addons/mod/quiz/components/index/index.scss @@ -11,10 +11,7 @@ } .item:nth-child(even) { - --background: var(--gray-lighter); - // @include darkmode() { - // background-color: $core-dark-item-divider-bg-color; - // } + --background: var(--light); } .addon-mod_quiz-highlighted, @@ -24,21 +21,17 @@ --background: var(--blue-light); color: var(--blue-dark); } - - // @include darkmode() { - // .addon-mod_quiz-highlighted, - // .item.addon-mod_quiz-highlighted, - // .addon-mod_quiz-highlighted p, - // .item.addon-mod_quiz-highlighted p { - // background-color: $blue-dark; - // color: $blue-light; - // } - - // .item.addon-mod_quiz-highlighted.activated, - // .item.addon-mod_quiz-highlighted.activated p { - // background-color: $blue; - // color: $blue-light; - // } - // } + } +} + +:host-context(body.dark) { + .addon-mod_quiz-table { + .addon-mod_quiz-highlighted, + .item.addon-mod_quiz-highlighted, + .addon-mod_quiz-highlighted p, + .item.addon-mod_quiz-highlighted p { + --background: var(--blue-dark); + color: var(--blue-light); + } } } diff --git a/src/addons/qtype/ddwtos/component/ddwtos.scss b/src/addons/qtype/ddwtos/component/ddwtos.scss index a1643e2e9..4173fe334 100644 --- a/src/addons/qtype/ddwtos/component/ddwtos.scss +++ b/src/addons/qtype/ddwtos/component/ddwtos.scss @@ -76,16 +76,10 @@ } span.incorrect { - background-color: var(--red-light); - // @include darkmode() { - // background-color: $red-dark; - // } + background-color: var(--core-question-incorrect-color-bg); } span.correct { - background-color: var(--green-light); - // @include darkmode() { - // background-color: $green-dark; - // } + background-color: var(--core-question-correct-color-bg); } @for $i from 0 to length($core-dd-question-colors) { diff --git a/src/addons/qtype/gapselect/component/gapselect.scss b/src/addons/qtype/gapselect/component/gapselect.scss index 5060bcf32..7fc7fdbef 100644 --- a/src/addons/qtype/gapselect/component/gapselect.scss +++ b/src/addons/qtype/gapselect/component/gapselect.scss @@ -14,10 +14,5 @@ -moz-border-radius: 4px; border-radius: 4px; margin-bottom: 10px; - background: var(--gray-lighter); - - // @include darkmode() { - // background: $gray-dark; - // } } } diff --git a/src/core/features/question/question.scss b/src/core/features/question/question.scss index b6e4f4b80..1dce88eb1 100644 --- a/src/core/features/question/question.scss +++ b/src/core/features/question/question.scss @@ -1,27 +1,6 @@ @import "~theme/globals"; -$core-dd-question-colors: $white, $blue-light, #DCDCDC, #D8BFD8, #87CEFA, #DAA520, #FFD700, #F0E68C !default; - :host ::ng-deep { - --core-question-correct-color: var(--green-dark); - --core-question-correct-color-bg: var(--green-light); - --core-question-incorrect-color: var(--red); - --core-question-incorrect-color-bg: var(--red-light); - --core-question-feedback-color: var(--yellow-dark); - --core-question-feedback-color-bg: var(--yellow-light); - --core-question-warning-color: var(--red); - --core-question-saved-color-bg: var(--gray-light); - - --core-question-state-correct-color: var(--green-light); - --core-question-state-partial-color: var(--yellow-light); - --core-question-state-partial-text: var(--yellow); - --core-question-state-incorrect-color: var(--red-light); - - --core-question-feedback-color: var(--yellow-dark); - --core-question-feedback-background-color: var(--yellow-light); - - --core-dd-question-selected-shadow: 2px 2px 4px var(--gray-dark); - .core-question-answer-correct { color: var(--core-question-correct-color); } diff --git a/src/theme/theme.dark.scss b/src/theme/theme.dark.scss index 6bf965ee9..13496a06b 100644 --- a/src/theme/theme.dark.scss +++ b/src/theme/theme.dark.scss @@ -74,4 +74,23 @@ --core-login-background: var(--custom-login-background, #3a3a3a); --core-login-text-color: var(--custom-login-text-color, white); + + --core-question-correct-color: var(--green-light); + --core-question-correct-color-bg: var(--green-dark); + --core-question-incorrect-color: var(--red); + --core-question-incorrect-color-bg: var(--red-dark); + --core-question-feedback-color: var(--yellow-light); + --core-question-feedback-color-bg: var(--yellow-dark); + --core-question-warning-color: var(--red); + --core-question-saved-color-bg: var(--gray-dark); + + --core-question-state-correct-color: var(--green-dark); + --core-question-state-partial-color: var(--yellow-dark); + --core-question-state-partial-text: var(--yellow); + --core-question-state-incorrect-color: var(--red-dark); + + --core-question-feedback-color: var(--yellow-light); + --core-question-feedback-background-color: var(--yellow-dark); + + --core-dd-question-selected-shadow: 2px 2px 4px var(--gray-light); }