leds: add inner border and set rgbled initial alpha to 0
This commit is contained in:
parent
17796ed4a2
commit
00dc551eea
2 changed files with 3 additions and 2 deletions
|
|
@ -48,7 +48,7 @@ module.exports = class Led extends _widgets_base {
|
|||
|
||||
if (this.getProp('widgetId').length) $('body').on(`sync.${this.hash}`,this.syncHandle.bind(this))
|
||||
|
||||
this.setValue([0,0,0])
|
||||
this.setValue([0,0,0,0])
|
||||
|
||||
}
|
||||
|
||||
|
|
@ -82,7 +82,7 @@ module.exports = class Led extends _widgets_base {
|
|||
v[i] = parseInt(clip(v[i],[0,255]))
|
||||
}
|
||||
|
||||
v[3] = clip(v[3]||1,[0,1])
|
||||
v[3] = clip(v[3] != undefined ? v[3] : 1,[0,1])
|
||||
|
||||
this.led[0].style.setProperty('--color-custom',`rgba(${v[0]}, ${v[1]}, ${v[2]}, ${v[3]})`)
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue