mirror of
https://github.com/node-red/node-red.git
synced 2023-10-10 13:36:53 +02:00
parent
d57425a15e
commit
92d5af7446
@ -1,5 +1,5 @@
|
|||||||
/**
|
/**
|
||||||
* Copyright 2013, 2015 IBM Corp.
|
* Copyright 2013, 2016 IBM Corp.
|
||||||
*
|
*
|
||||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
* you may not use this file except in compliance with the License.
|
* you may not use this file except in compliance with the License.
|
||||||
@ -102,11 +102,13 @@ RED.sidebar.info = (function() {
|
|||||||
if (node._def) {
|
if (node._def) {
|
||||||
for (var n in node._def.defaults) {
|
for (var n in node._def.defaults) {
|
||||||
if (n != "name" && node._def.defaults.hasOwnProperty(n)) {
|
if (n != "name" && node._def.defaults.hasOwnProperty(n)) {
|
||||||
var val = node[n]||"";
|
var val = node[n];
|
||||||
var type = typeof val;
|
var type = typeof val;
|
||||||
if (type === "string") {
|
if (val === null || val === undefined) {
|
||||||
|
val = '<span style="font-style: italic; color: #ccc;">'+RED._("sidebar.info.null")+'</span>';
|
||||||
|
} else if (type === "string") {
|
||||||
if (val.length === 0) {
|
if (val.length === 0) {
|
||||||
val += '<span style="font-style: italic; color: #ccc;">'+RED._("sidebar.info.blank")+'</span>';
|
val = '<span style="font-style: italic; color: #ccc;">'+RED._("sidebar.info.blank")+'</span>';
|
||||||
} else {
|
} else {
|
||||||
if (val.length > 30) {
|
if (val.length > 30) {
|
||||||
val = val.substring(0,30)+" ...";
|
val = val.substring(0,30)+" ...";
|
||||||
|
@ -212,6 +212,7 @@
|
|||||||
"instances": "Instances",
|
"instances": "Instances",
|
||||||
"properties": "Properties",
|
"properties": "Properties",
|
||||||
"blank": "blank",
|
"blank": "blank",
|
||||||
|
"null": "null",
|
||||||
"arrayItems": "__count__ items"
|
"arrayItems": "__count__ items"
|
||||||
},
|
},
|
||||||
"config": {
|
"config": {
|
||||||
|
Loading…
Reference in New Issue
Block a user