1
0
mirror of https://github.com/node-red/node-red.git synced 2023-10-10 13:36:53 +02:00

Found some more ids and classes to namespace

This commit is contained in:
Nick O'Leary 2019-05-16 22:32:28 +01:00
parent 8567f1655e
commit 0d75ff336d
No known key found for this signature in database
GPG Key ID: 4F2157149161A6C9
19 changed files with 124 additions and 127 deletions

View File

@ -97,14 +97,14 @@ RED.text.bidi = (function() {
} }
/** /**
* Enforces the text direction for all the spans with style bidiAware under * Enforces the text direction for all the spans with style red-ui-text-bidi-aware under
* workspace or sidebar div * workspace or sidebar div
*/ */
function enforceTextDirectionOnPage() { function enforceTextDirectionOnPage() {
$("#red-ui-workspace").find('span.bidiAware').each(function() { $("#red-ui-workspace").find('span.red-ui-text-bidi-aware').each(function() {
$(this).attr("dir", resolveBaseTextDir($(this).html())); $(this).attr("dir", resolveBaseTextDir($(this).html()));
}); });
$("#red-ui-sidebar").find('span.bidiAware').each(function() { $("#red-ui-sidebar").find('span.red-ui-text-bidi-aware').each(function() {
$(this).attr("dir", resolveBaseTextDir($(this).text())); $(this).attr("dir", resolveBaseTextDir($(this).text()));
}); });
} }

View File

@ -56,12 +56,12 @@ RED.menu = (function() {
} }
if (opt === null) { if (opt === null) {
item = $('<li class="divider"></li>'); item = $('<li class="red-ui-menu-divider"></li>');
} else { } else {
item = $('<li></li>'); item = $('<li></li>');
if (opt.group) { if (opt.group) {
item.addClass("rd-ui-menu-group-"+opt.group); item.addClass("red-ui-menu-group-"+opt.group);
} }
var linkContent = '<a '+(opt.id?'id="'+opt.id+'" ':'')+'tabindex="-1" href="#">'; var linkContent = '<a '+(opt.id?'id="'+opt.id+'" ':'')+'tabindex="-1" href="#">';

View File

@ -488,7 +488,7 @@ RED.tabs = (function() {
} else if (tab.iconClass) { } else if (tab.iconClass) {
$('<i>',{class:"red-ui-tab-icon "+tab.iconClass}).appendTo(link); $('<i>',{class:"red-ui-tab-icon "+tab.iconClass}).appendTo(link);
} }
var span = $('<span/>',{class:"bidiAware"}).text(tab.label).appendTo(link); var span = $('<span/>',{class:"red-ui-text-bidi-aware"}).text(tab.label).appendTo(link);
span.attr('dir', RED.text.bidi.resolveBaseTextDir(tab.label)); span.attr('dir', RED.text.bidi.resolveBaseTextDir(tab.label));
if (options.collapsible) { if (options.collapsible) {
li.addClass("red-ui-tab-pinned"); li.addClass("red-ui-tab-pinned");
@ -650,7 +650,7 @@ RED.tabs = (function() {
tabs[id].label = label; tabs[id].label = label;
var tab = ul.find("a[href='#"+id+"']"); var tab = ul.find("a[href='#"+id+"']");
tab.attr("title",label); tab.attr("title",label);
tab.find("span.bidiAware").text(label).attr('dir', RED.text.bidi.resolveBaseTextDir(label)); tab.find("span.red-ui-text-bidi-aware").text(label).attr('dir', RED.text.bidi.resolveBaseTextDir(label));
updateTabWidths(); updateTabWidths();
}, },
selection: getSelection, selection: getSelection,

View File

@ -44,7 +44,7 @@
'</div>'+ '</div>'+
'</div>'+ '</div>'+
'<div class="red-ui-panel">'+ '<div class="red-ui-panel">'+
'<div class="red-ui-editor-type-markdown-panel-preview node-help"></div>'+ '<div class="red-ui-editor-type-markdown-panel-preview red-ui-help"></div>'+
'</div>'+ '</div>'+
'</script>'; '</script>';

View File

@ -29,7 +29,7 @@ RED.library = (function() {
'<div id="red-ui-library-dialog-load-preview">'+ '<div id="red-ui-library-dialog-load-preview">'+
'<div class="red-ui-panel" id="red-ui-library-dialog-load-preview-text"></div>'+ '<div class="red-ui-panel" id="red-ui-library-dialog-load-preview-text"></div>'+
'<div class="red-ui-panel" id="red-ui-library-dialog-load-preview-details">'+ '<div class="red-ui-panel" id="red-ui-library-dialog-load-preview-details">'+
'<table id="red-ui-library-dialog-load-preview-details-table" class="node-info"></table>'+ '<table id="red-ui-library-dialog-load-preview-details-table" class="red-ui-info-table"></table>'+
'</div>'+ '</div>'+
'</div>'+ '</div>'+
'</div>'+ '</div>'+
@ -523,15 +523,15 @@ RED.library = (function() {
if (file && file.label && !file.children) { if (file && file.label && !file.children) {
$.get("library/"+file.library+"/"+file.type+"/"+file.path, function(data) { $.get("library/"+file.library+"/"+file.type+"/"+file.path, function(data) {
//TODO: nls + sanitize //TODO: nls + sanitize
var propRow = $('<tr class="node-info-node-row"><td>Type</td><td></td></tr>').appendTo(table); var propRow = $('<tr class="red-ui-help-info-row"><td>Type</td><td></td></tr>').appendTo(table);
$(propRow.children()[1]).text(activeLibrary.type); $(propRow.children()[1]).text(activeLibrary.type);
if (file.props.hasOwnProperty('name')) { if (file.props.hasOwnProperty('name')) {
propRow = $('<tr class="node-info-node-row"><td>Name</td><td>'+file.props.name+'</td></tr>').appendTo(table); propRow = $('<tr class="red-ui-help-info-row"><td>Name</td><td>'+file.props.name+'</td></tr>').appendTo(table);
$(propRow.children()[1]).text(file.props.name); $(propRow.children()[1]).text(file.props.name);
} }
for (var p in file.props) { for (var p in file.props) {
if (file.props.hasOwnProperty(p) && p !== 'name' && p !== 'fn') { if (file.props.hasOwnProperty(p) && p !== 'name' && p !== 'fn') {
propRow = $('<tr class="node-info-node-row"><td></td><td></td></tr>').appendTo(table); propRow = $('<tr class="red-ui-help-info-row"><td></td><td></td></tr>').appendTo(table);
$(propRow.children()[0]).text(p); $(propRow.children()[0]).text(p);
RED.utils.createObjectElement(file.props[p]).appendTo(propRow.children()[1]); RED.utils.createObjectElement(file.props[p]).appendTo(propRow.children()[1]);
} }

View File

@ -34,7 +34,7 @@ RED.palette = (function() {
function createCategoryContainer(originalCategory,category, labelId) { function createCategoryContainer(originalCategory,category, labelId) {
var label = RED._(labelId, {defaultValue:category}); var label = RED._(labelId, {defaultValue:category});
label = (label || category).replace(/_/g, " "); label = (label || category).replace(/_/g, " ");
var catDiv = $('<div id="red-ui-palette-container-'+category+'" class="red-ui-palette-category palette-close hide">'+ var catDiv = $('<div id="red-ui-palette-container-'+category+'" class="red-ui-palette-category hide">'+
'<div id="red-ui-palette-header-'+category+'" class="red-ui-palette-header"><i class="expanded fa fa-angle-down"></i><span>'+label+'</span></div>'+ '<div id="red-ui-palette-header-'+category+'" class="red-ui-palette-header"><i class="expanded fa fa-angle-down"></i><span>'+label+'</span></div>'+
'<div class="red-ui-palette-content" id="red-ui-palette-base-category-'+category+'">'+ '<div class="red-ui-palette-content" id="red-ui-palette-base-category-'+category+'">'+
'<div id="red-ui-palette-'+category+'-input"></div>'+ '<div id="red-ui-palette-'+category+'-input"></div>'+
@ -236,9 +236,9 @@ RED.palette = (function() {
RED.view.focus(); RED.view.focus();
var helpText; var helpText;
if (nt.indexOf("subflow:") === 0) { if (nt.indexOf("subflow:") === 0) {
helpText = marked(RED.nodes.subflow(nt.substring(8)).info||"")||('<span class="node-info-none">'+RED._("sidebar.info.none")+'</span>'); helpText = marked(RED.nodes.subflow(nt.substring(8)).info||"")||('<span class="red-ui-help-info-none">'+RED._("sidebar.info.none")+'</span>');
} else { } else {
helpText = $("script[data-help-name='"+d.type+"']").html()||('<span class="node-info-none">'+RED._("sidebar.info.none")+'</span>'); helpText = $("script[data-help-name='"+d.type+"']").html()||('<span class="red-ui-help-info-none">'+RED._("sidebar.info.none")+'</span>');
} }
RED.sidebar.info.set(helpText,RED._("sidebar.info.nodeHelp")); RED.sidebar.info.set(helpText,RED._("sidebar.info.nodeHelp"));
}); });

View File

@ -160,10 +160,10 @@ RED.projects.settings = (function() {
if (activeProject.description) { if (activeProject.description) {
desc = marked(activeProject.description); desc = marked(activeProject.description);
} else { } else {
desc = '<span class="node-info-none">'+'No description available'+'</span>'; desc = '<span class="red-ui-help-info-none">'+'No description available'+'</span>';
} }
var description = addTargetToExternalLinks($('<span class="bidiAware" dir=\"'+RED.text.bidi.resolveBaseTextDir(desc)+'">'+desc+'</span>')).appendTo(container); var description = addTargetToExternalLinks($('<span class="red-ui-text-bidi-aware" dir=\"'+RED.text.bidi.resolveBaseTextDir(desc)+'">'+desc+'</span>')).appendTo(container);
description.find(".bidiAware").contents().filter(function() { return this.nodeType === 3 && this.textContent.trim() !== "" }).wrap( "<span></span>" ); description.find(".red-ui-text-bidi-aware").contents().filter(function() { return this.nodeType === 3 && this.textContent.trim() !== "" }).wrap( "<span></span>" );
} }
function editSummary(activeProject, summary, container) { function editSummary(activeProject, summary, container) {
@ -222,13 +222,13 @@ RED.projects.settings = (function() {
if (summary) { if (summary) {
container.text(summary).removeClass('node-info-node'); container.text(summary).removeClass('node-info-node');
} else { } else {
container.text(RED._("sidebar.project.projectSettings.noSummaryAvailable")).addClass('node-info-none'); container.text(RED._("sidebar.project.projectSettings.noSummaryAvailable")).addClass('red-ui-help-info-none');
} }
} }
function createMainPane(activeProject) { function createMainPane(activeProject) {
var pane = $('<div id="red-ui-project-settings-tab-main" class="red-ui-project-settings-tab-pane node-help"></div>'); var pane = $('<div id="red-ui-project-settings-tab-main" class="red-ui-project-settings-tab-pane red-ui-help"></div>');
$('<h1>').text(activeProject.name).appendTo(pane); $('<h1>').text(activeProject.name).appendTo(pane);
var summary = $('<div style="position: relative">').appendTo(pane); var summary = $('<div style="position: relative">').appendTo(pane);
var summaryContent = $('<div></div>').appendTo(summary); var summaryContent = $('<div></div>').appendTo(summary);
@ -243,7 +243,7 @@ RED.projects.settings = (function() {
} }
$('<hr>').appendTo(pane); $('<hr>').appendTo(pane);
var description = $('<div class="node-help" style="position: relative"></div>').appendTo(pane); var description = $('<div class="red-ui-help" style="position: relative"></div>').appendTo(pane);
var descriptionContent = $('<div>',{style:"min-height: 200px"}).appendTo(description); var descriptionContent = $('<div>',{style:"min-height: 200px"}).appendTo(description);
updateProjectDescription(activeProject, descriptionContent); updateProjectDescription(activeProject, descriptionContent);
@ -378,7 +378,7 @@ RED.projects.settings = (function() {
} }
function createDependenciesPane(activeProject) { function createDependenciesPane(activeProject) {
var pane = $('<div id="red-ui-project-settings-tab-deps" class="red-ui-project-settings-tab-pane node-help"></div>'); var pane = $('<div id="red-ui-project-settings-tab-deps" class="red-ui-project-settings-tab-pane red-ui-help"></div>');
if (RED.user.hasPermission("projects.write")) { if (RED.user.hasPermission("projects.write")) {
$('<button class="editor-button editor-button-small" style="margin-top:10px;float: right;">' + RED._("sidebar.project.projectSettings.edit") + '</button>') $('<button class="editor-button editor-button-small" style="margin-top:10px;float: right;">' + RED._("sidebar.project.projectSettings.edit") + '</button>')
.appendTo(pane) .appendTo(pane)
@ -1576,7 +1576,7 @@ RED.projects.settings = (function() {
function createSettingsPane(activeProject) { function createSettingsPane(activeProject) {
var pane = $('<div id="red-ui-project-settings-tab-settings" class="red-ui-project-settings-tab-pane node-help"></div>'); var pane = $('<div id="red-ui-project-settings-tab-settings" class="red-ui-project-settings-tab-pane red-ui-help"></div>');
createFilesSection(activeProject,pane); createFilesSection(activeProject,pane);
// createLocalRepositorySection(activeProject,pane); // createLocalRepositorySection(activeProject,pane);
createRemoteRepositorySection(activeProject,pane); createRemoteRepositorySection(activeProject,pane);

View File

@ -389,7 +389,7 @@ RED.projects.userSettings = (function() {
} }
function createSettingsPane(activeProject) { function createSettingsPane(activeProject) {
var pane = $('<div id="red-ui-settings-tab-gitconfig" class="project-settings-tab-pane node-help"></div>'); var pane = $('<div id="red-ui-settings-tab-gitconfig" class="project-settings-tab-pane red-ui-help"></div>');
createGitUserSection(pane); createGitUserSection(pane);
createSSHKeySection(pane); createSSHKeySection(pane);
return pane; return pane;

View File

@ -118,7 +118,7 @@ RED.sidebar.versionControl = (function() {
row.addClass("red-ui-sidebar-vc-change-entry"); row.addClass("red-ui-sidebar-vc-change-entry");
var container = $('<div>').appendTo(row); var container = $('<div>').appendTo(row);
if (entry.label) { if (entry.label) {
row.addClass('node-info-none'); row.addClass('red-ui-help-info-none');
container.text(entry.label); container.text(entry.label);
if (entry.button) { if (entry.button) {
container.css({ container.css({
@ -618,7 +618,7 @@ RED.sidebar.versionControl = (function() {
RED.popover.tooltip(repoStatusButton,RED._("sidebar.project.versionControl.manageRemoteBranch")) RED.popover.tooltip(repoStatusButton,RED._("sidebar.project.versionControl.manageRemoteBranch"))
localCommitList = $("<ol>",{style:"position: absolute; top: 30px; bottom: 0px; right:0; left:0;"}).appendTo(localHistory.content); localCommitList = $("<ol>",{style:"position: absolute; top: 30px; bottom: 0px; right:0; left:0;"}).appendTo(localHistory.content);
localCommitListShade = $('<div class="component-shade" style="z-Index: 3"></div>').css('top',"30px").hide().appendTo(localHistory.content); localCommitListShade = $('<div class="red-ui-shade" style="z-Index: 3"></div>').css('top',"30px").hide().appendTo(localHistory.content);
localCommitList.editableList({ localCommitList.editableList({
addButton: false, addButton: false,
scrollOnAdd: false, scrollOnAdd: false,
@ -1021,7 +1021,7 @@ RED.sidebar.versionControl = (function() {
}); });
}); });
$('<div class="component-shade red-ui-sidebar-vc-shade">').appendTo(sidebarContent); $('<div class="red-ui-shade red-ui-sidebar-vc-shade">').appendTo(sidebarContent);
RED.sidebar.addTab({ RED.sidebar.addTab({
id: "version-control", id: "version-control",

View File

@ -87,8 +87,8 @@ RED.subflow = (function() {
RED.view.select(); RED.view.select();
RED.nodes.dirty(true); RED.nodes.dirty(true);
RED.view.redraw(); RED.view.redraw();
$("#workspace-subflow-input-add").addClass("active"); $("#red-ui-subflow-input-add").addClass("active");
$("#workspace-subflow-input-remove").removeClass("active"); $("#red-ui-subflow-input-remove").removeClass("active");
RED.palette.refresh(); RED.palette.refresh();
} }
@ -108,8 +108,8 @@ RED.subflow = (function() {
}); });
removedInputLinks.forEach(function(l) { RED.nodes.removeLink(l)}); removedInputLinks.forEach(function(l) { RED.nodes.removeLink(l)});
activeSubflow.in = []; activeSubflow.in = [];
$("#workspace-subflow-input-add").removeClass("active"); $("#red-ui-subflow-input-add").removeClass("active");
$("#workspace-subflow-input-remove").addClass("active"); $("#red-ui-subflow-input-remove").addClass("active");
activeSubflow.changed = true; activeSubflow.changed = true;
RED.palette.refresh(); RED.palette.refresh();
return {subflowInputs: [ removedInput ], links:removedInputLinks}; return {subflowInputs: [ removedInput ], links:removedInputLinks};
@ -151,7 +151,7 @@ RED.subflow = (function() {
RED.view.select(); RED.view.select();
RED.nodes.dirty(true); RED.nodes.dirty(true);
RED.view.redraw(); RED.view.redraw();
$("#workspace-subflow-output .spinner-value").text(subflow.out.length); $("#red-ui-subflow-output .spinner-value").text(subflow.out.length);
RED.palette.refresh(); RED.palette.refresh();
} }
@ -227,8 +227,8 @@ RED.subflow = (function() {
RED.view.select(); RED.view.select();
RED.nodes.dirty(true); RED.nodes.dirty(true);
RED.view.redraw(); RED.view.redraw();
$("#workspace-subflow-status").prop("checked",!!subflow.status); $("#red-ui-subflow-status").prop("checked",!!subflow.status);
$("#workspace-subflow-status").parent().parent().toggleClass("active",!!subflow.status); $("#red-ui-subflow-status").parent().parent().toggleClass("active",!!subflow.status);
} }
function removeSubflowStatus() { function removeSubflowStatus() {
@ -245,8 +245,8 @@ RED.subflow = (function() {
subflowRemovedLinks.forEach(function(l) { RED.nodes.removeLink(l)}); subflowRemovedLinks.forEach(function(l) { RED.nodes.removeLink(l)});
delete subflow.status; delete subflow.status;
$("#workspace-subflow-status").prop("checked",!!subflow.status); $("#red-ui-subflow-status").prop("checked",!!subflow.status);
$("#workspace-subflow-status").parent().parent().toggleClass("active",!!subflow.status); $("#red-ui-subflow-status").parent().parent().toggleClass("active",!!subflow.status);
return { links: subflowRemovedLinks } return { links: subflowRemovedLinks }
} }
@ -282,13 +282,13 @@ RED.subflow = (function() {
function refreshToolbar(activeSubflow) { function refreshToolbar(activeSubflow) {
if (activeSubflow) { if (activeSubflow) {
$("#workspace-subflow-input-add").toggleClass("active", activeSubflow.in.length !== 0); $("#red-ui-subflow-input-add").toggleClass("active", activeSubflow.in.length !== 0);
$("#workspace-subflow-input-remove").toggleClass("active",activeSubflow.in.length === 0); $("#red-ui-subflow-input-remove").toggleClass("active",activeSubflow.in.length === 0);
$("#workspace-subflow-output .spinner-value").text(activeSubflow.out.length); $("#red-ui-subflow-output .spinner-value").text(activeSubflow.out.length);
$("#workspace-subflow-status").prop("checked",!!activeSubflow.status); $("#red-ui-subflow-status").prop("checked",!!activeSubflow.status);
$("#workspace-subflow-status").parent().parent().toggleClass("active",!!activeSubflow.status); $("#red-ui-subflow-status").parent().parent().toggleClass("active",!!activeSubflow.status);
} }
} }
@ -298,35 +298,35 @@ RED.subflow = (function() {
toolbar.empty(); toolbar.empty();
// Edit properties // Edit properties
$('<a class="button" id="workspace-subflow-edit" href="#" data-i18n="[append]subflow.editSubflowProperties"><i class="fa fa-pencil"></i> </a>').appendTo(toolbar); $('<a class="button" id="red-ui-subflow-edit" href="#" data-i18n="[append]subflow.editSubflowProperties"><i class="fa fa-pencil"></i> </a>').appendTo(toolbar);
// Inputs // Inputs
$('<span style="margin-left: 5px;" data-i18n="subflow.input"></span> '+ $('<span style="margin-left: 5px;" data-i18n="subflow.input"></span> '+
'<div style="display: inline-block;" class="button-group">'+ '<div style="display: inline-block;" class="button-group">'+
'<a id="workspace-subflow-input-remove" class="button active" href="#">0</a>'+ '<a id="red-ui-subflow-input-remove" class="button active" href="#">0</a>'+
'<a id="workspace-subflow-input-add" class="button" href="#">1</a>'+ '<a id="red-ui-subflow-input-add" class="button" href="#">1</a>'+
'</div>').appendTo(toolbar); '</div>').appendTo(toolbar);
// Outputs // Outputs
$('<span style="margin-left: 5px;" data-i18n="subflow.output"></span> <div id="workspace-subflow-output" style="display: inline-block;" class="button-group spinner-group">'+ $('<span style="margin-left: 5px;" data-i18n="subflow.output"></span> <div id="red-ui-subflow-output" style="display: inline-block;" class="button-group spinner-group">'+
'<a id="workspace-subflow-output-remove" class="button" href="#"><i class="fa fa-minus"></i></a>'+ '<a id="red-ui-subflow-output-remove" class="button" href="#"><i class="fa fa-minus"></i></a>'+
'<div class="spinner-value">3</div>'+ '<div class="spinner-value">3</div>'+
'<a id="workspace-subflow-output-add" class="button" href="#"><i class="fa fa-plus"></i></a>'+ '<a id="red-ui-subflow-output-add" class="button" href="#"><i class="fa fa-plus"></i></a>'+
'</div>').appendTo(toolbar); '</div>').appendTo(toolbar);
// Status // Status
$('<span class="button-group"><span class="button" style="padding:0"><label for="workspace-subflow-status"><input id="workspace-subflow-status" type="checkbox"> <span data-i18n="subflow.status"></span></label></span></span>').appendTo(toolbar); $('<span class="button-group"><span class="button" style="padding:0"><label for="red-ui-subflow-status"><input id="red-ui-subflow-status" type="checkbox"> <span data-i18n="subflow.status"></span></label></span></span>').appendTo(toolbar);
// $('<a class="button disabled" id="workspace-subflow-add-input" href="#" data-i18n="[append]subflow.input"><i class="fa fa-plus"></i> </a>').appendTo(toolbar); // $('<a class="button disabled" id="red-ui-subflow-add-input" href="#" data-i18n="[append]subflow.input"><i class="fa fa-plus"></i> </a>').appendTo(toolbar);
// $('<a class="button" id="workspace-subflow-add-output" href="#" data-i18n="[append]subflow.output"><i class="fa fa-plus"></i> </a>').appendTo(toolbar); // $('<a class="button" id="red-ui-subflow-add-output" href="#" data-i18n="[append]subflow.output"><i class="fa fa-plus"></i> </a>').appendTo(toolbar);
// Delete // Delete
$('<a class="button" id="workspace-subflow-delete" href="#" data-i18n="[append]subflow.deleteSubflow"><i class="fa fa-trash"></i> </a>').appendTo(toolbar); $('<a class="button" id="red-ui-subflow-delete" href="#" data-i18n="[append]subflow.deleteSubflow"><i class="fa fa-trash"></i> </a>').appendTo(toolbar);
toolbar.i18n(); toolbar.i18n();
$("#workspace-subflow-output-remove").on("click", function(event) { $("#red-ui-subflow-output-remove").on("click", function(event) {
event.preventDefault(); event.preventDefault();
var wasDirty = RED.nodes.dirty(); var wasDirty = RED.nodes.dirty();
var wasChanged = activeSubflow.changed; var wasChanged = activeSubflow.changed;
@ -350,17 +350,17 @@ RED.subflow = (function() {
} }
}); });
$("#workspace-subflow-output-add").on("click", function(event) { $("#red-ui-subflow-output-add").on("click", function(event) {
event.preventDefault(); event.preventDefault();
addSubflowOutput(); addSubflowOutput();
}); });
$("#workspace-subflow-input-add").on("click", function(event) { $("#red-ui-subflow-input-add").on("click", function(event) {
event.preventDefault(); event.preventDefault();
addSubflowInput(); addSubflowInput();
}); });
$("#workspace-subflow-input-remove").on("click", function(event) { $("#red-ui-subflow-input-remove").on("click", function(event) {
event.preventDefault(); event.preventDefault();
var wasDirty = RED.nodes.dirty(); var wasDirty = RED.nodes.dirty();
var wasChanged = activeSubflow.changed; var wasChanged = activeSubflow.changed;
@ -384,7 +384,7 @@ RED.subflow = (function() {
} }
}); });
$("#workspace-subflow-status").on("change", function(evt) { $("#red-ui-subflow-status").on("change", function(evt) {
if (this.checked) { if (this.checked) {
addSubflowStatus(); addSubflowStatus();
} else { } else {
@ -411,12 +411,12 @@ RED.subflow = (function() {
} }
}) })
$("#workspace-subflow-edit").on("click", function(event) { $("#red-ui-subflow-edit").on("click", function(event) {
RED.editor.editSubflow(RED.nodes.subflow(RED.workspaces.active())); RED.editor.editSubflow(RED.nodes.subflow(RED.workspaces.active()));
event.preventDefault(); event.preventDefault();
}); });
$("#workspace-subflow-delete").on("click", function(event) { $("#red-ui-subflow-delete").on("click", function(event) {
event.preventDefault(); event.preventDefault();
var startDirty = RED.nodes.dirty(); var startDirty = RED.nodes.dirty();
var historyEvent = removeSubflow(RED.workspaces.active()); var historyEvent = removeSubflow(RED.workspaces.active());

View File

@ -53,7 +53,7 @@ RED.sidebar.context = (function() {
nodeSection.expand(); nodeSection.expand();
nodeSection.content.css({height:"100%"}); nodeSection.content.css({height:"100%"});
nodeSection.timestamp = $('<div class="red-ui-sidebar-context-updated">&nbsp;</div>').appendTo(nodeSection.content); nodeSection.timestamp = $('<div class="red-ui-sidebar-context-updated">&nbsp;</div>').appendTo(nodeSection.content);
var table = $('<table class="node-info"></table>').appendTo(nodeSection.content); var table = $('<table class="red-ui-info-table"></table>').appendTo(nodeSection.content);
nodeSection.table = $('<tbody>').appendTo(table); nodeSection.table = $('<tbody>').appendTo(table);
var bg = $('<div style="float: right"></div>').appendTo(nodeSection.header); var bg = $('<div style="float: right"></div>').appendTo(nodeSection.header);
$('<button class="editor-button editor-button-small"><i class="fa fa-refresh"></i></button>') $('<button class="editor-button editor-button-small"><i class="fa fa-refresh"></i></button>')
@ -87,7 +87,7 @@ RED.sidebar.context = (function() {
flowSection.expand(); flowSection.expand();
flowSection.content.css({height:"100%"}); flowSection.content.css({height:"100%"});
flowSection.timestamp = $('<div class="red-ui-sidebar-context-updated">&nbsp;</div>').appendTo(flowSection.content); flowSection.timestamp = $('<div class="red-ui-sidebar-context-updated">&nbsp;</div>').appendTo(flowSection.content);
var table = $('<table class="node-info"></table>').appendTo(flowSection.content); var table = $('<table class="red-ui-info-table"></table>').appendTo(flowSection.content);
flowSection.table = $('<tbody>').appendTo(table); flowSection.table = $('<tbody>').appendTo(table);
bg = $('<div style="float: right"></div>').appendTo(flowSection.header); bg = $('<div style="float: right"></div>').appendTo(flowSection.header);
$('<button class="editor-button editor-button-small"><i class="fa fa-refresh"></i></button>') $('<button class="editor-button editor-button-small"><i class="fa fa-refresh"></i></button>')
@ -105,7 +105,7 @@ RED.sidebar.context = (function() {
globalSection.expand(); globalSection.expand();
globalSection.content.css({height:"100%"}); globalSection.content.css({height:"100%"});
globalSection.timestamp = $('<div class="red-ui-sidebar-context-updated">&nbsp;</div>').appendTo(globalSection.content); globalSection.timestamp = $('<div class="red-ui-sidebar-context-updated">&nbsp;</div>').appendTo(globalSection.content);
var table = $('<table class="node-info"></table>').appendTo(globalSection.content); var table = $('<table class="red-ui-info-table"></table>').appendTo(globalSection.content);
globalSection.table = $('<tbody>').appendTo(table); globalSection.table = $('<tbody>').appendTo(table);
bg = $('<div style="float: right"></div>').appendTo(globalSection.header); bg = $('<div style="float: right"></div>').appendTo(globalSection.header);
@ -185,9 +185,9 @@ RED.sidebar.context = (function() {
} else { } else {
$(nodeSection.table).empty(); $(nodeSection.table).empty();
if (node) { if (node) {
$('<tr class="node-info-node-row red-ui-search-empty blank" colspan="2"><td data-i18n="sidebar.context.refresh"></td></tr>').appendTo(nodeSection.table).i18n(); $('<tr class="red-ui-help-info-row red-ui-search-empty blank" colspan="2"><td data-i18n="sidebar.context.refresh"></td></tr>').appendTo(nodeSection.table).i18n();
} else { } else {
$('<tr class="node-info-node-row red-ui-search-empty blank" colspan="2"><td data-i18n="sidebar.context.none"></td></tr>').appendTo(nodeSection.table).i18n(); $('<tr class="red-ui-help-info-row red-ui-search-empty blank" colspan="2"><td data-i18n="sidebar.context.none"></td></tr>').appendTo(nodeSection.table).i18n();
} }
nodeSection.timestamp.html("&nbsp;"); nodeSection.timestamp.html("&nbsp;");
@ -230,7 +230,7 @@ RED.sidebar.context = (function() {
sortedData[keys[i]].forEach(function(v) { sortedData[keys[i]].forEach(function(v) {
var k = keys[i]; var k = keys[i];
var l2 = sortedData[k].length; var l2 = sortedData[k].length;
var propRow = $('<tr class="node-info-node-row"><td class="red-ui-sidebar-context-property"></td><td></td></tr>').appendTo(container); var propRow = $('<tr class="red-ui-help-info-row"><td class="red-ui-sidebar-context-property"></td><td></td></tr>').appendTo(container);
var obj = $(propRow.children()[0]); var obj = $(propRow.children()[0]);
obj.text(k); obj.text(k);
var tools = $('<span class="button-group"></span>'); var tools = $('<span class="button-group"></span>');
@ -280,7 +280,7 @@ RED.sidebar.context = (function() {
if (data.format === 'undefined') { if (data.format === 'undefined') {
propRow.remove(); propRow.remove();
if (container.children().length === 0) { if (container.children().length === 0) {
$('<tr class="node-info-node-row red-ui-search-empty blank" colspan="2"><td data-i18n="sidebar.context.empty"></td></tr>').appendTo(container).i18n(); $('<tr class="red-ui-help-info-row red-ui-search-empty blank" colspan="2"><td data-i18n="sidebar.context.empty"></td></tr>').appendTo(container).i18n();
} }
} else { } else {
payload = data.msg; payload = data.msg;
@ -317,7 +317,7 @@ RED.sidebar.context = (function() {
}); });
} }
if (l === 0) { if (l === 0) {
$('<tr class="node-info-node-row red-ui-search-empty blank" colspan="2"><td data-i18n="sidebar.context.empty"></td></tr>').appendTo(container).i18n(); $('<tr class="red-ui-help-info-row red-ui-search-empty blank" colspan="2"><td data-i18n="sidebar.context.empty"></td></tr>').appendTo(container).i18n();
} }
$(section.timestamp).text(new Date().toLocaleString()); $(section.timestamp).text(new Date().toLocaleString());
}); });
@ -328,7 +328,7 @@ RED.sidebar.context = (function() {
refreshEntry(section,baseUrl,id); refreshEntry(section,baseUrl,id);
} else { } else {
$(container).empty(); $(container).empty();
$('<tr class="node-info-node-row red-ui-search-empty blank" colspan="2"><td data-i18n="sidebar.context.none"></td></tr>').appendTo(container).i18n(); $('<tr class="red-ui-help-info-row red-ui-search-empty blank" colspan="2"><td data-i18n="sidebar.context.none"></td></tr>').appendTo(container).i18n();
} }
} }

View File

@ -40,11 +40,11 @@ RED.sidebar.info = (function() {
function init() { function init() {
content = document.createElement("div"); content = document.createElement("div");
content.className = "sidebar-node-info" content.className = "red-ui-sidebar-info"
RED.actions.add("core:show-info-tab",show); RED.actions.add("core:show-info-tab",show);
var stackContainer = $("<div>",{class:"sidebar-node-info-stack"}).appendTo(content); var stackContainer = $("<div>",{class:"red-ui-sidebar-info-stack"}).appendTo(content);
sections = RED.stack.create({ sections = RED.stack.create({
container: stackContainer container: stackContainer
@ -71,7 +71,7 @@ RED.sidebar.info = (function() {
helpSection.content.css("padding","6px"); helpSection.content.css("padding","6px");
var tipContainer = $('<div class="red-ui-help-tips"></div>').appendTo(content); var tipContainer = $('<div class="red-ui-help-tips"></div>').appendTo(content);
tipBox = $('<div class="node-info-tip"></div>').appendTo(tipContainer); tipBox = $('<div class="red-ui-help-tip"></div>').appendTo(tipContainer);
var tipButtons = $('<div class="red-ui-help-tips-buttons"></div>').appendTo(tipContainer); var tipButtons = $('<div class="red-ui-help-tips-buttons"></div>').appendTo(tipContainer);
var tipRefresh = $('<a href="#" class="red-ui-footer-button"><i class="fa fa-refresh"></a>').appendTo(tipButtons); var tipRefresh = $('<a href="#" class="red-ui-footer-button"><i class="fa fa-refresh"></a>').appendTo(tipButtons);
@ -131,7 +131,7 @@ RED.sidebar.info = (function() {
var propRow; var propRow;
var table = $('<table class="node-info"></table>').appendTo(propertiesSection.content); var table = $('<table class="red-ui-info-table"></table>').appendTo(propertiesSection.content);
var tableBody = $('<tbody>').appendTo(table); var tableBody = $('<tbody>').appendTo(table);
var subflowNode; var subflowNode;
@ -139,9 +139,9 @@ RED.sidebar.info = (function() {
var activeProject = RED.projects.getActiveProject(); var activeProject = RED.projects.getActiveProject();
if (activeProject) { if (activeProject) {
propRow = $('<tr class="node-info-node-row"><td>Project</td><td></td></tr>').appendTo(tableBody); propRow = $('<tr class="red-ui-help-info-row"><td>Project</td><td></td></tr>').appendTo(tableBody);
$(propRow.children()[1]).text(activeProject.name||""); $(propRow.children()[1]).text(activeProject.name||"");
$('<tr class="node-info-property-expand blank"><td colspan="2"></td></tr>').appendTo(tableBody); $('<tr class="red-ui-help-property-expand blank"><td colspan="2"></td></tr>').appendTo(tableBody);
var editProjectButton = $('<button class="editor-button editor-button-small" style="position:absolute;right:2px;"><i class="fa fa-ellipsis-h"></i></button>') var editProjectButton = $('<button class="editor-button editor-button-small" style="position:absolute;right:2px;"><i class="fa fa-ellipsis-h"></i></button>')
.appendTo(propRow.children()[1]) .appendTo(propRow.children()[1])
.on("click", function(evt) { .on("click", function(evt) {
@ -177,7 +177,7 @@ RED.sidebar.info = (function() {
helpSection.container.hide(); helpSection.container.hide();
infoSection.container.hide(); infoSection.container.hide();
// - show the count of selected nodes // - show the count of selected nodes
propRow = $('<tr class="node-info-node-row"><td>'+RED._("sidebar.info.selection")+"</td><td></td></tr>").appendTo(tableBody); propRow = $('<tr class="red-ui-help-info-row"><td>'+RED._("sidebar.info.selection")+"</td><td></td></tr>").appendTo(tableBody);
var counts = $('<div>').appendTo($(propRow.children()[1])); var counts = $('<div>').appendTo($(propRow.children()[1]));
if (types.flows > 0) { if (types.flows > 0) {
@ -211,24 +211,24 @@ RED.sidebar.info = (function() {
} }
if (node.type === "tab" || node.type === "subflow") { if (node.type === "tab" || node.type === "subflow") {
// If nothing is selected, but we're on a flow or subflow tab. // If nothing is selected, but we're on a flow or subflow tab.
propRow = $('<tr class="node-info-node-row"><td>'+RED._("sidebar.info."+(node.type==='tab'?'flow':'subflow'))+'</td><td></td></tr>').appendTo(tableBody); propRow = $('<tr class="red-ui-help-info-row"><td>'+RED._("sidebar.info."+(node.type==='tab'?'flow':'subflow'))+'</td><td></td></tr>').appendTo(tableBody);
RED.utils.createObjectElement(node.id).appendTo(propRow.children()[1]); RED.utils.createObjectElement(node.id).appendTo(propRow.children()[1]);
propRow = $('<tr class="node-info-node-row"><td>'+RED._("sidebar.info.tabName")+"</td><td></td></tr>").appendTo(tableBody); propRow = $('<tr class="red-ui-help-info-row"><td>'+RED._("sidebar.info.tabName")+"</td><td></td></tr>").appendTo(tableBody);
$(propRow.children()[1]).text(node.label||node.name||""); $(propRow.children()[1]).text(node.label||node.name||"");
if (node.type === "tab") { if (node.type === "tab") {
propRow = $('<tr class="node-info-node-row"><td>'+RED._("sidebar.info.status")+'</td><td></td></tr>').appendTo(tableBody); propRow = $('<tr class="red-ui-help-info-row"><td>'+RED._("sidebar.info.status")+'</td><td></td></tr>').appendTo(tableBody);
$(propRow.children()[1]).text((!!!node.disabled)?RED._("sidebar.info.enabled"):RED._("sidebar.info.disabled")) $(propRow.children()[1]).text((!!!node.disabled)?RED._("sidebar.info.enabled"):RED._("sidebar.info.disabled"))
} }
} else { } else {
// An actual node is selected in the editor - build up its properties table // An actual node is selected in the editor - build up its properties table
propRow = $('<tr class="node-info-node-row"><td>'+RED._("sidebar.info.node")+"</td><td></td></tr>").appendTo(tableBody); propRow = $('<tr class="red-ui-help-info-row"><td>'+RED._("sidebar.info.node")+"</td><td></td></tr>").appendTo(tableBody);
RED.utils.createObjectElement(node.id).appendTo(propRow.children()[1]); RED.utils.createObjectElement(node.id).appendTo(propRow.children()[1]);
if (node.type !== "subflow" && node.type !== "unknown" && node.name) { if (node.type !== "subflow" && node.type !== "unknown" && node.name) {
propRow = $('<tr class="node-info-node-row"><td>'+RED._("common.label.name")+'</td><td></td></tr>').appendTo(tableBody); propRow = $('<tr class="red-ui-help-info-row"><td>'+RED._("common.label.name")+'</td><td></td></tr>').appendTo(tableBody);
$('<span class="bidiAware" dir="'+RED.text.bidi.resolveBaseTextDir(node.name)+'"></span>').text(node.name).appendTo(propRow.children()[1]); $('<span class="red-ui-text-bidi-aware" dir="'+RED.text.bidi.resolveBaseTextDir(node.name)+'"></span>').text(node.name).appendTo(propRow.children()[1]);
} }
if (!m) { if (!m) {
propRow = $('<tr class="node-info-node-row"><td>'+RED._("sidebar.info.type")+"</td><td></td></tr>").appendTo(tableBody); propRow = $('<tr class="red-ui-help-info-row"><td>'+RED._("sidebar.info.type")+"</td><td></td></tr>").appendTo(tableBody);
$(propRow.children()[1]).text((node.type === "unknown")?node._orig.type:node.type); $(propRow.children()[1]).text((node.type === "unknown")?node._orig.type:node.type);
if (node.type === "unknown") { if (node.type === "unknown") {
$('<span style="float: right; font-size: 0.8em"><i class="fa fa-warning"></i></span>').prependTo($(propRow.children()[1])) $('<span style="float: right; font-size: 0.8em"><i class="fa fa-warning"></i></span>').prependTo($(propRow.children()[1]))
@ -246,11 +246,11 @@ RED.sidebar.info = (function() {
}) })
} else if (node._def) { } else if (node._def) {
defaults = node._def.defaults; defaults = node._def.defaults;
propRow = $('<tr class="node-info-property-row'+(expandedSections.property?"":" hide")+'"><td>'+RED._("sidebar.info.module")+"</td><td></td></tr>").appendTo(tableBody); propRow = $('<tr class="red-ui-help-info-property-row'+(expandedSections.property?"":" hide")+'"><td>'+RED._("sidebar.info.module")+"</td><td></td></tr>").appendTo(tableBody);
$(propRow.children()[1]).text(RED.nodes.getType(node.type).set.module); $(propRow.children()[1]).text(RED.nodes.getType(node.type).set.module);
count++; count++;
} }
$('<tr class="node-info-property-expand node-info-property-row blank'+(expandedSections.property?"":" hide")+'"><td colspan="2"></td></tr>').appendTo(tableBody); $('<tr class="red-ui-help-property-expand red-ui-help-info-property-row blank'+(expandedSections.property?"":" hide")+'"><td colspan="2"></td></tr>').appendTo(tableBody);
if (defaults) { if (defaults) {
for (var n in defaults) { for (var n in defaults) {
@ -258,7 +258,7 @@ RED.sidebar.info = (function() {
var val = node[n]; var val = node[n];
var type = typeof val; var type = typeof val;
count++; count++;
propRow = $('<tr class="node-info-property-row'+(expandedSections.property?"":" hide")+'"><td>'+n+"</td><td></td></tr>").appendTo(tableBody); propRow = $('<tr class="red-ui-help-info-property-row'+(expandedSections.property?"":" hide")+'"><td>'+n+"</td><td></td></tr>").appendTo(tableBody);
if (defaults[n].type) { if (defaults[n].type) {
var configNode = RED.nodes.node(val); var configNode = RED.nodes.node(val);
if (!configNode) { if (!configNode) {
@ -288,18 +288,18 @@ RED.sidebar.info = (function() {
} }
} }
if (count > 0) { if (count > 0) {
$('<tr class="node-info-property-expand blank"><td colspan="2"><a href="#" class=" node-info-property-header'+(expandedSections.property?" expanded":"")+'"><span class="node-info-property-show-more">'+RED._("sidebar.info.showMore")+'</span><span class="node-info-property-show-less">'+RED._("sidebar.info.showLess")+'</span> <i class="fa fa-caret-down"></i></a></td></tr>').appendTo(tableBody); $('<tr class="red-ui-help-property-expand blank"><td colspan="2"><a href="#" class="node-info-property-header'+(expandedSections.property?" expanded":"")+'"><span class="red-ui-help-property-more">'+RED._("sidebar.info.showMore")+'</span><span class="red-ui-help-property-less">'+RED._("sidebar.info.showLess")+'</span> <i class="fa fa-caret-down"></i></a></td></tr>').appendTo(tableBody);
} }
} }
if (node.type !== 'tab') { if (node.type !== 'tab') {
if (m) { if (m) {
$('<tr class="blank"><th colspan="2">'+RED._("sidebar.info.subflow")+'</th></tr>').appendTo(tableBody); $('<tr class="blank"><th colspan="2">'+RED._("sidebar.info.subflow")+'</th></tr>').appendTo(tableBody);
$('<tr class="node-info-subflow-row"><td>'+RED._("common.label.name")+'</td><td><span class="bidiAware" dir=\"'+RED.text.bidi.resolveBaseTextDir(subflowNode.name)+'">'+RED.utils.sanitize(subflowNode.name)+'</span></td></tr>').appendTo(tableBody); $('<tr class="node-info-subflow-row"><td>'+RED._("common.label.name")+'</td><td><span class="red-ui-text-bidi-aware" dir=\"'+RED.text.bidi.resolveBaseTextDir(subflowNode.name)+'">'+RED.utils.sanitize(subflowNode.name)+'</span></td></tr>').appendTo(tableBody);
} }
} }
} }
if (m) { if (m) {
propRow = $('<tr class="node-info-node-row"><td>'+RED._("subflow.category")+'</td><td></td></tr>').appendTo(tableBody); propRow = $('<tr class="red-ui-help-info-row"><td>'+RED._("subflow.category")+'</td><td></td></tr>').appendTo(tableBody);
var category = subflowNode.category||"subflows"; var category = subflowNode.category||"subflows";
$(propRow.children()[1]).text(RED._("palette.label."+category,{defaultValue:category})) $(propRow.children()[1]).text(RED._("palette.label."+category,{defaultValue:category}))
$('<tr class="node-info-subflow-row"><td>'+RED._("sidebar.info.instances")+"</td><td>"+subflowUserCount+'</td></tr>').appendTo(tableBody); $('<tr class="node-info-subflow-row"><td>'+RED._("sidebar.info.instances")+"</td><td>"+subflowUserCount+'</td></tr>').appendTo(tableBody);
@ -313,9 +313,9 @@ RED.sidebar.info = (function() {
if (subflowNode && node.type !== "subflow") { if (subflowNode && node.type !== "subflow") {
// Selected a subflow instance node. // Selected a subflow instance node.
// - The subflow template info goes into help // - The subflow template info goes into help
helpText = (marked(subflowNode.info||"")||('<span class="node-info-none">'+RED._("sidebar.info.none")+'</span>')); helpText = (marked(subflowNode.info||"")||('<span class="red-ui-help-info-none">'+RED._("sidebar.info.none")+'</span>'));
} else { } else {
helpText = $("script[data-help-name='"+node.type+"']").html()||('<span class="node-info-none">'+RED._("sidebar.info.none")+'</span>'); helpText = $("script[data-help-name='"+node.type+"']").html()||('<span class="red-ui-help-info-none">'+RED._("sidebar.info.none")+'</span>');
} }
setInfoText(helpText, helpSection.content); setInfoText(helpText, helpSection.content);
} }
@ -332,18 +332,18 @@ RED.sidebar.info = (function() {
} }
setInfoText(infoText, infoSection.content); setInfoText(infoText, infoSection.content);
$(".sidebar-node-info-stack").scrollTop(0); $(".red-ui-sidebar-info-stack").scrollTop(0);
$(".node-info-property-header").on("click", function(e) { $(".node-info-property-header").on("click", function(e) {
e.preventDefault(); e.preventDefault();
expandedSections["property"] = !expandedSections["property"]; expandedSections["property"] = !expandedSections["property"];
$(this).toggleClass("expanded",expandedSections["property"]); $(this).toggleClass("expanded",expandedSections["property"]);
$(".node-info-property-row").toggle(expandedSections["property"]); $(".red-ui-help-info-property-row").toggle(expandedSections["property"]);
}); });
} }
// $('<tr class="blank"><th colspan="2"></th></tr>').appendTo(tableBody); // $('<tr class="blank"><th colspan="2"></th></tr>').appendTo(tableBody);
// propRow = $('<tr class="node-info-node-row"><td>Actions</td><td></td></tr>').appendTo(tableBody); // propRow = $('<tr class="red-ui-help-info-row"><td>Actions</td><td></td></tr>').appendTo(tableBody);
// var actionBar = $(propRow.children()[1]); // var actionBar = $(propRow.children()[1]);
// //
// // var actionBar = $('<div>',{style:"background: #fefefe; padding: 3px;"}).appendTo(propertiesSection.content); // // var actionBar = $('<div>',{style:"background: #fefefe; padding: 3px;"}).appendTo(propertiesSection.content);
@ -356,10 +356,10 @@ RED.sidebar.info = (function() {
} }
function setInfoText(infoText,target) { function setInfoText(infoText,target) {
var info = addTargetToExternalLinks($('<div class="node-help"><span class="bidiAware" dir=\"'+RED.text.bidi.resolveBaseTextDir(infoText)+'">'+infoText+'</span></div>')).appendTo(target); var info = addTargetToExternalLinks($('<div class="red-ui-help"><span class="red-ui-text-bidi-aware" dir=\"'+RED.text.bidi.resolveBaseTextDir(infoText)+'">'+infoText+'</span></div>')).appendTo(target);
info.find(".bidiAware").contents().filter(function() { return this.nodeType === 3 && this.textContent.trim() !== "" }).wrap( "<span></span>" ); info.find(".red-ui-text-bidi-aware").contents().filter(function() { return this.nodeType === 3 && this.textContent.trim() !== "" }).wrap( "<span></span>" );
var foldingHeader = "H3"; var foldingHeader = "H3";
info.find(foldingHeader).wrapInner('<a class="node-info-header expanded" href="#"></a>') info.find(foldingHeader).wrapInner('<a class="red-ui-help-info-header expanded" href="#"></a>')
.find("a").prepend('<i class="fa fa-angle-right">').on("click", function(e) { .find("a").prepend('<i class="fa fa-angle-right">').on("click", function(e) {
e.preventDefault(); e.preventDefault();
var isExpanded = $(this).hasClass('expanded'); var isExpanded = $(this).hasClass('expanded');
@ -420,7 +420,7 @@ RED.sidebar.info = (function() {
}) })
} }
function startTips() { function startTips() {
$(".sidebar-node-info").addClass('show-tips'); $(".red-ui-sidebar-info").addClass('show-tips');
if (enabled) { if (enabled) {
if (!startTimeout && !refreshTimeout) { if (!startTimeout && !refreshTimeout) {
if (tipCount === -1) { if (tipCount === -1) {
@ -433,7 +433,7 @@ RED.sidebar.info = (function() {
} }
} }
function stopTips() { function stopTips() {
$(".sidebar-node-info").removeClass('show-tips'); $(".red-ui-sidebar-info").removeClass('show-tips');
clearInterval(refreshTimeout); clearInterval(refreshTimeout);
clearTimeout(startTimeout); clearTimeout(startTimeout);
refreshTimeout = null; refreshTimeout = null;
@ -466,7 +466,7 @@ RED.sidebar.info = (function() {
infoSection.container.show(); infoSection.container.show();
//helpSection.title.text(title||RED._("sidebar.info.info")); //helpSection.title.text(title||RED._("sidebar.info.info"));
setInfoText(html,infoSection.content); setInfoText(html,infoSection.content);
$(".sidebar-node-info-stack").scrollTop(0); $(".red-ui-sidebar-info-stack").scrollTop(0);
} }
function refreshSelection(selection) { function refreshSelection(selection) {

View File

@ -133,7 +133,7 @@ RED.userSettings = (function() {
function createViewPane() { function createViewPane() {
var pane = $('<div id="red-ui-settings-tab-view" class="node-help"></div>'); var pane = $('<div id="red-ui-settings-tab-view" class="red-ui-help"></div>');
var currentEditorSettings = RED.settings.get('editor') || {}; var currentEditorSettings = RED.settings.get('editor') || {};
currentEditorSettings.view = currentEditorSettings.view || {}; currentEditorSettings.view = currentEditorSettings.view || {};

View File

@ -37,7 +37,7 @@
left: auto; left: auto;
} }
.divider { .red-ui-menu-divider {
height: 1px; height: 1px;
margin: 9px 1px; margin: 9px 1px;
overflow: hidden; overflow: hidden;

View File

@ -151,7 +151,7 @@
} }
#red-ui-library-dialog-load-preview-details { #red-ui-library-dialog-load-preview-details {
box-sizing: border-box; box-sizing: border-box;
.node-info-node-row:first-child { .red-ui-help-info-row:first-child {
border-top: none; border-top: none;
} }
} }

View File

@ -237,6 +237,6 @@
background: $shade-color; background: $shade-color;
z-index: 5; z-index: 5;
} }
.component-shade { .red-ui-shade {
@include shade @include shade
} }

View File

@ -506,7 +506,7 @@
display: block; display: block;
} }
} }
&.node-info-none { &.red-ui-help-info-node {
text-align: center; text-align: center;
background: $list-item-background; background: $list-item-background;
white-space: normal; white-space: normal;

View File

@ -14,19 +14,19 @@
* limitations under the License. * limitations under the License.
**/ **/
.sidebar-node-info hr { .red-ui-sidebar-info hr {
margin: 10px 0; margin: 10px 0;
} }
table.node-info { table.red-ui-info-table {
font-size: 14px; font-size: 14px;
margin: 0 0 10px; margin: 0 0 10px;
width: 100%; width: 100%;
} }
table.node-info tr:not(.blank) { table.red-ui-info-table tr:not(.blank) {
border-top: 1px solid $secondary-border-color; border-top: 1px solid $secondary-border-color;
border-bottom: 1px solid $secondary-border-color; border-bottom: 1px solid $secondary-border-color;
} }
.node-info-property-expand { .red-ui-help-property-expand {
font-size: 0.8em; font-size: 0.8em;
text-align: right; text-align: right;
line-height: 0.9em; line-height: 0.9em;
@ -35,7 +35,7 @@ table.node-info tr:not(.blank) {
} }
} }
table.node-info tr.blank { table.red-ui-info-table tr.blank {
border: none; border: none;
th { th {
text-align: left; text-align: left;
@ -58,10 +58,10 @@ table.node-info tr.blank {
text-decoration: none; text-decoration: none;
} }
&:not(.expanded) { &:not(.expanded) {
.node-info-property-show-more { .red-ui-help-property-more {
display: inline; display: inline;
} }
.node-info-property-show-less { .red-ui-help-property-less {
display: none; display: none;
} }
} }
@ -72,10 +72,10 @@ table.node-info tr.blank {
} }
&.expanded { &.expanded {
.node-info-property-show-more { .red-ui-help-property-more {
display: none; display: none;
} }
.node-info-property-show-less { .red-ui-help-property-less {
display: inline; display: inline;
} }
i { i {
@ -83,15 +83,12 @@ table.node-info tr.blank {
} }
} }
} }
&.node-info-info-row > td {
padding-left: 5px;
}
} }
.node-info-none { .red-ui-help-info-none {
font-style: italic; font-style: italic;
color: $tertiary-text-color; color: $tertiary-text-color;
} }
table.node-info tr:not(.blank) td:first-child{ table.red-ui-info-table tr:not(.blank) td:first-child{
color: $header-text-color; color: $header-text-color;
vertical-align: top; vertical-align: top;
width: 90px; width: 90px;
@ -99,15 +96,15 @@ table.node-info tr:not(.blank) td:first-child{
background:$tertiary-background; background:$tertiary-background;
border-right: 1px solid $secondary-border-color; border-right: 1px solid $secondary-border-color;
} }
table.node-info tr:not(.blank) td:last-child{ table.red-ui-info-table tr:not(.blank) td:last-child{
padding: 3px 3px 3px 6px; padding: 3px 3px 3px 6px;
color: $primary-text-color; color: $primary-text-color;
overflow-y: hidden; overflow-y: hidden;
} }
div.node-info { div.red-ui-info-table {
margin: 5px; margin: 5px;
} }
.node-help { .red-ui-help {
font-size: $primary-font-size; font-size: $primary-font-size;
line-height: 1.5em; line-height: 1.5em;
@ -197,7 +194,7 @@ div.node-info {
} }
} }
} }
.node-info-header { .red-ui-help-info-header {
i { i {
width: 10px; width: 10px;
text-align: center; text-align: center;
@ -216,7 +213,7 @@ div.node-info {
} }
} }
.sidebar-node-info-stack { .red-ui-sidebar-info-stack {
position: absolute; position: absolute;
top: 0; top: 0;
bottom: 0; bottom: 0;
@ -238,8 +235,8 @@ div.node-info {
box-shadow: 0 5px 20px 0px $shadow; box-shadow: 0 5px 20px 0px $shadow;
overflow-y: auto; overflow-y: auto;
} }
.sidebar-node-info.show-tips { .red-ui-sidebar-info.show-tips {
.sidebar-node-info-stack { .red-ui-sidebar-info-stack {
bottom: 150px; bottom: 150px;
} }
.red-ui-help-tips { .red-ui-help-tips {
@ -255,7 +252,7 @@ div.node-info {
margin-right: -0.25em; /* Adjusts for spacing */ margin-right: -0.25em; /* Adjusts for spacing */
} }
.node-info-tip { .red-ui-help-tip {
display: inline-block; display: inline-block;
vertical-align: middle; vertical-align: middle;
width: 100%; width: 100%;

View File

@ -69,7 +69,7 @@ RED.debug = (function() {
// var filterTypeRow = $('<div class="red-ui-debug-filter-row"></div>').appendTo(filterDialog); // var filterTypeRow = $('<div class="red-ui-debug-filter-row"></div>').appendTo(filterDialog);
// $('<select><option>Show all debug nodes</option><option>Show selected debug nodes</option><option>Show current flow only</option></select>').appendTo(filterTypeRow); // $('<select><option>Show all debug nodes</option><option>Show selected debug nodes</option><option>Show current flow only</option></select>').appendTo(filterTypeRow);
var debugNodeListRow = $('<div class="red-ui-debug-filter-row hide" id="debug-filter-node-list-row"></div>').appendTo(filterDialog); var debugNodeListRow = $('<div class="red-ui-debug-filter-row hide" id="red-ui-sidebar-debug-filter-node-list-row"></div>').appendTo(filterDialog);
var flowCheckboxes = {}; var flowCheckboxes = {};
var debugNodeListHeader = $('<div><span data-i18n="node-red:debug.sidebar.debugNodes"></span><span></span></div>'); var debugNodeListHeader = $('<div><span data-i18n="node-red:debug.sidebar.debugNodes"></span><span></span></div>');
var headerCheckbox = $('<input type="checkbox">').appendTo(debugNodeListHeader.find("span")[1]).checkboxSet(); var headerCheckbox = $('<input type="checkbox">').appendTo(debugNodeListHeader.find("span")[1]).checkboxSet();
@ -545,7 +545,7 @@ RED.debug = (function() {
$('.red-ui-sidebar-debug-filter-option').removeClass('selected'); $('.red-ui-sidebar-debug-filter-option').removeClass('selected');
$('#red-ui-sidebar-debug-filterAll').addClass('selected'); $('#red-ui-sidebar-debug-filterAll').addClass('selected');
$('#red-ui-sidebar-debug-filter span').text(RED._('node-red:debug.sidebar.filterAll')); $('#red-ui-sidebar-debug-filter span').text(RED._('node-red:debug.sidebar.filterAll'));
$('#debug-filter-node-list-row').slideUp(); $('#red-ui-sidebar-debug-filter-node-list-row').slideUp();
} }
return { return {