Forum Discussion
Changing the Matching dropdown graded quiz/survey colors
- 4 months ago
You’ll need to inject JavaScript to target the selected state. To do this, add an Execute JavaScript trigger that runs when the timeline starts on the slide:
const style = document.createElement('style'); style.innerHTML = ` .drop-list-item-selected { fill: #87CEEB !important; } `; document.head.appendChild(style);
You’ll need to inject JavaScript to target the selected state. To do this, add an Execute JavaScript trigger that runs when the timeline starts on the slide:
const style = document.createElement('style');
style.innerHTML = `
.drop-list-item-selected {
fill: #87CEEB !important;
}
`;
document.head.appendChild(style);
Nedim Wow, thank you so much! This absolutely worked. Is it possible to also change the font color using JavaScript? If so, what would I need to enter?
- Nedim4 months agoCommunity Member
I don't see a way to change the font color only for the selected answer. You can add another CSS rule (e.g., .drop-list text), but it seems to affect the font color of all drop-list items.
const style = document.createElement('style'); style.innerHTML = ` .drop-list-item-selected { fill: #87CEEB !important; } .drop-list text { fill: #2a2b2c !important; } `; document.head.appendChild(style);
- Nedim4 months agoCommunity Member
More CSS properties you can play with:
const style = document.createElement('style'); style.innerHTML = ` .drop-list-item-selected { fill: #87CEEB !important; } .drop-list text { fill: #2a2b2c !important; } .drop-list-drop-down text { fill: #fff !important; } .drop-list-item-out { fill: #222 !important; } .drop-list-item-over { fill: #aaa !important; } #drop-list-gradient stop:first-child { stop-color: #222 !important; } #drop-list-gradient stop:last-child { stop-color: #aaa !important; } .drop-list-top > rect { fill: aliceblue !important; } `; document.head.appendChild(style);
- JennaG4 months agoCommunity Member
This is amazing and helps so much. I really appreciate your time and expertise 🙂
Related Content
- 8 months ago
- 9 months ago
- 10 months ago
- 3 months ago