mirror of
https://github.com/node-red/node-red.git
synced 2023-10-10 13:36:53 +02:00
List welcome tours in help sidebar under node-red section
This commit is contained in:
parent
42ecf54df6
commit
a7e3548f22
@ -685,7 +685,8 @@
|
||||
"showHelp": "Show help",
|
||||
"showInOutline": "Show in outline",
|
||||
"showTopics": "Show topics",
|
||||
"noHelp": "No help topic selected"
|
||||
"noHelp": "No help topic selected",
|
||||
"changeLog": "Change Log"
|
||||
},
|
||||
"config": {
|
||||
"name": "Configuration nodes",
|
||||
@ -1159,7 +1160,7 @@
|
||||
"takeATour": "Take a tour",
|
||||
"start": "Start",
|
||||
"next": "Next",
|
||||
"tours": "Tours"
|
||||
"welcomeTours": "Welcome Tours"
|
||||
},
|
||||
"diagnostics": {
|
||||
"title": "System Info"
|
||||
|
@ -20,10 +20,8 @@ RED.sidebar.help = (function() {
|
||||
var helpSection;
|
||||
var panels;
|
||||
var panelRatio;
|
||||
var helpTopics = [];
|
||||
var treeList;
|
||||
var tocPanel;
|
||||
var helpIndex = {};
|
||||
|
||||
function resizeStack() {
|
||||
var h = $(content).parent().height() - toolbar.outerHeight();
|
||||
@ -192,7 +190,6 @@ RED.sidebar.help = (function() {
|
||||
}
|
||||
|
||||
function refreshHelpIndex() {
|
||||
helpTopics = [];
|
||||
var modules = RED.nodes.registry.getModuleList();
|
||||
var moduleNames = Object.keys(modules);
|
||||
moduleNames.sort();
|
||||
@ -204,23 +201,28 @@ RED.sidebar.help = (function() {
|
||||
};
|
||||
var tours = RED.tourGuide.list().map(function (item) {
|
||||
return {
|
||||
icon: "fa fa-repeat",
|
||||
icon: "fa fa-play-circle-o",
|
||||
label: item.label,
|
||||
tour: item.path,
|
||||
};
|
||||
});
|
||||
var helpData = [
|
||||
{
|
||||
label: "Node-RED",
|
||||
children: [
|
||||
{
|
||||
id: 'changelog',
|
||||
label: "Node-RED v"+RED.settings.version,
|
||||
label: RED._("sidebar.help.changeLog"),
|
||||
content: getChangelog
|
||||
},
|
||||
nodeHelp,
|
||||
{
|
||||
id: "tours",
|
||||
label: RED._("tourGuide.tours"),
|
||||
label: RED._("tourGuide.welcomeTours"),
|
||||
children: tours
|
||||
}
|
||||
|
||||
]
|
||||
},
|
||||
nodeHelp
|
||||
];
|
||||
var subflows = RED.nodes.registry.getNodeTypes().filter(function(t) {return /subflow/.test(t)});
|
||||
if (subflows.length > 0) {
|
||||
|
@ -437,7 +437,7 @@ RED.tourGuide = (function() {
|
||||
return [
|
||||
{
|
||||
id: "2_3",
|
||||
label: "3.0.0-beta.3 (latest)",
|
||||
label: "3.0.0-beta.3",
|
||||
path: "./tours/welcome.js"
|
||||
},
|
||||
{
|
||||
@ -449,12 +449,7 @@ RED.tourGuide = (function() {
|
||||
id: "2_1",
|
||||
label: "2.1.0",
|
||||
path: "./tours/2.1/welcome.js"
|
||||
},
|
||||
{
|
||||
id: "first_flow",
|
||||
label: "First flow",
|
||||
path: "./tours/first-flow.js"
|
||||
},
|
||||
}
|
||||
];
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user