We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 80802ea commit 1490bb2Copy full SHA for 1490bb2
src/led-element.ts
@@ -9,6 +9,7 @@ const lightColors: { [key: string]: string } = {
9
yellow: '#ffff80',
10
orange: '#ffcf80',
11
white: '#ffffff',
12
+ purple: '#ff80ff',
13
};
14
15
@customElement('wokwi-led')
@@ -55,7 +56,7 @@ export class LEDElement extends LitElement {
55
56
57
render() {
58
const { color, lightColor, flip } = this;
- const lightColorActual = lightColor || lightColors[color?.toLowerCase()] || '#ff8080';
59
+ const lightColorActual = lightColor || lightColors[color?.toLowerCase()] || color;
60
const opacity = this.brightness ? 0.3 + this.brightness * 0.7 : 0;
61
const lightOn = this.value && this.brightness > Number.EPSILON;
62
const xScale = flip ? -1 : 1;
0 commit comments