mirror of
https://github.com/node-red/node-red.git
synced 2023-10-10 13:36:53 +02:00
Handle treeList labels as text not html
This commit is contained in:
parent
894d28c60b
commit
be1b9c0e43
@ -15,6 +15,19 @@
|
|||||||
**/
|
**/
|
||||||
(function($) {
|
(function($) {
|
||||||
|
|
||||||
|
/**
|
||||||
|
* options:
|
||||||
|
* - minimumLength : the minimum length of text before firing a change event
|
||||||
|
* - delay : delay, in ms, after a keystroke before firing change event
|
||||||
|
*
|
||||||
|
* methods:
|
||||||
|
* - value([val]) - gets the current value, or, if `val` is provided, sets the value
|
||||||
|
* - count - sets or clears a sub-label on the input. This can be used to provide
|
||||||
|
* a feedback on the number of matches, or number of available entries to search
|
||||||
|
* - change - trigger a change event
|
||||||
|
*
|
||||||
|
*/
|
||||||
|
|
||||||
$.widget( "nodered.searchBox", {
|
$.widget( "nodered.searchBox", {
|
||||||
_create: function() {
|
_create: function() {
|
||||||
var that = this;
|
var that = this;
|
||||||
|
@ -148,7 +148,7 @@
|
|||||||
if (item.icon) {
|
if (item.icon) {
|
||||||
$('<span class="red-ui-treeList-icon"><i class="'+item.icon+'" /></span>').appendTo(label);
|
$('<span class="red-ui-treeList-icon"><i class="'+item.icon+'" /></span>').appendTo(label);
|
||||||
}
|
}
|
||||||
$('<span class="red-ui-treeList-label-text"></span>').html(item.label).appendTo(label);
|
$('<span class="red-ui-treeList-label-text"></span>').text(item.label).appendTo(label);
|
||||||
if (item.children) {
|
if (item.children) {
|
||||||
if (Array.isArray(item.children)) {
|
if (Array.isArray(item.children)) {
|
||||||
that._addChildren(container,item.children,depth);
|
that._addChildren(container,item.children,depth);
|
||||||
|
Loading…
Reference in New Issue
Block a user