mirror of
https://github.com/node-red/node-red.git
synced 2023-10-10 13:36:53 +02:00
Ensure node default color is used if palette.theme has no match
This commit is contained in:
parent
db1b0ccb79
commit
c1a1a73599
@ -800,8 +800,9 @@ RED.utils = (function() {
|
|||||||
var paletteTheme = RED.settings.theme('palette.theme') || [];
|
var paletteTheme = RED.settings.theme('palette.theme') || [];
|
||||||
if (paletteTheme.length > 0) {
|
if (paletteTheme.length > 0) {
|
||||||
if (!nodeColorCache.hasOwnProperty(type)) {
|
if (!nodeColorCache.hasOwnProperty(type)) {
|
||||||
|
nodeColorCache[type] = def.color;
|
||||||
var l = paletteTheme.length;
|
var l = paletteTheme.length;
|
||||||
for (var i=0;i<l;i++ ){
|
for (var i = 0; i < l; i++ ){
|
||||||
var themeRule = paletteTheme[i];
|
var themeRule = paletteTheme[i];
|
||||||
if (themeRule.hasOwnProperty('category')) {
|
if (themeRule.hasOwnProperty('category')) {
|
||||||
if (!themeRule.hasOwnProperty('_category')) {
|
if (!themeRule.hasOwnProperty('_category')) {
|
||||||
|
Loading…
Reference in New Issue
Block a user