Skip to content

Commit

Permalink
Merge pull request #12920 from nucleogenesis/12425-eqm-preview-quiz-t…
Browse files Browse the repository at this point in the history
…he-selection-effect-is-reversed

Fix colors of list items in quiz preview
  • Loading branch information
rtibbles authored Dec 11, 2024
2 parents d5d8c42 + cd6091d commit a7402a3
Showing 1 changed file with 17 additions and 15 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -79,12 +79,7 @@
</h3>
</template>
<template #content>
<div
v-show="isExpanded(index)"
:style="{
backgroundColor: $themePalette.grey.v_200,
}"
>
<div v-show="isExpanded(index)">
<ul class="question-list">
<li
v-for="(question, i) in section.questions"
Expand All @@ -94,7 +89,7 @@
tabindex="0"
class="question-button"
appearance="basic-link"
:class="{ selected: isSelected(question) }"
:class="[listItemClass, isSelected(question) ? selectedListItemClass : '']"
:style="accordionStyleOverrides"
@click="handleQuestionChange(i, index)"
>
Expand Down Expand Up @@ -320,6 +315,21 @@
textDecoration: 'none',
};
},
listItemClass() {
return this.$computedClass({
':hover': {
backgroundColor: this.$themePalette.grey.v_100,
},
});
},
selectedListItemClass() {
return this.$computedClass({
backgroundColor: this.$themePalette.grey.v_100,
':hover': {
backgroundColor: this.$themePalette.grey.v_200,
},
});
},
resourceMissingText() {
return this.coreString('resourceNotFoundOnDevice');
},
Expand Down Expand Up @@ -414,14 +424,6 @@
width: 100%;
height: 100%;
padding: 0.5em;
&:hover {
background-color: white;
}
&.selected {
background-color: white;
}
}
</style>

0 comments on commit a7402a3

Please sign in to comment.