From b6f9d39428b47bc794d3832dcae39a43288ef006 Mon Sep 17 00:00:00 2001 From: Dima Date: Mon, 17 Feb 2025 12:01:09 +0200 Subject: [PATCH] Allow to hide flowrunner block arguments --- lib/util/jsdoc.js | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/lib/util/jsdoc.js b/lib/util/jsdoc.js index 21b104ab..e3881528 100644 --- a/lib/util/jsdoc.js +++ b/lib/util/jsdoc.js @@ -42,7 +42,7 @@ class MethodDef { this.metaInfo.args[name] = this.metaInfo.args[name] || {} } - addParam({ name, label, type, optional, description, dictionary, dependsOn, uiComponent, defaultValue }) { + addParam({ name, label, type, optional, description, dictionary, dependsOn, uiComponent, defaultValue, hidden }) { this.params.push(new ParamDef(name, label, type, optional, description, defaultValue)) if (dictionary) { @@ -69,6 +69,12 @@ class MethodDef { this.metaInfo.args[name].defaultValue = defaultValue } + + if (hidden) { + this.ensureMetaInfoArgument(name) + + this.metaInfo.args[name].hidden = true + } } addTag(name, value) { @@ -201,6 +207,7 @@ const tagHandlers = { dependsOn : paramDef.dependsOn, uiComponent : paramDef.uiComponent, defaultValue: paramDef.defaultValue, + hidden : paramDef.hidden, }) registeredParams[paramDef.name] = 1 @@ -270,6 +277,7 @@ exports.describeClasses = function(fileName) { dependsOn, uiComponent, defaultValue, + hidden, } = param methodDef.addParam({ @@ -282,6 +290,7 @@ exports.describeClasses = function(fileName) { dependsOn, uiComponent, defaultValue, + hidden, }) } })