mirror of
https://github.com/vector-im/element-web.git
synced 2025-08-28 18:01:46 +02:00
Merge remote-tracking branch 'origin/develop' into develop
This commit is contained in:
commit
c5b5a78e86
@ -19,6 +19,10 @@ const DEBUG = 0;
|
|||||||
|
|
||||||
// utility to turn #rrggbb or rgb(r,g,b) into [red,green,blue]
|
// utility to turn #rrggbb or rgb(r,g,b) into [red,green,blue]
|
||||||
function colorToRgb(color) {
|
function colorToRgb(color) {
|
||||||
|
if (!color) {
|
||||||
|
return [0, 0, 0];
|
||||||
|
}
|
||||||
|
|
||||||
if (color[0] === '#') {
|
if (color[0] === '#') {
|
||||||
color = color.slice(1);
|
color = color.slice(1);
|
||||||
if (color.length === 3) {
|
if (color.length === 3) {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user