mirror of
https://github.com/fofolee/uTools-quickcommand.git
synced 2025-12-18 18:04:28 +08:00
编排添加正则提取/替换
This commit is contained in:
@@ -144,24 +144,12 @@ export const textProcessingCommands = {
|
||||
],
|
||||
},
|
||||
{
|
||||
value: "quickcomposer.textProcessing.regexExtract",
|
||||
label: "正则提取",
|
||||
config: [
|
||||
{
|
||||
key: "text",
|
||||
label: "原始文本",
|
||||
type: "input",
|
||||
defaultValue: "",
|
||||
icon: "text_fields",
|
||||
},
|
||||
{
|
||||
key: "regex",
|
||||
label: "正则表达式",
|
||||
type: "input",
|
||||
defaultValue: "",
|
||||
icon: "regex",
|
||||
},
|
||||
],
|
||||
value: "quickcomposer.textProcessing.regexTransform",
|
||||
label: "正则提取/替换",
|
||||
component: "RegexEditor",
|
||||
componentProps: {
|
||||
inputLabel: "要处理的文本",
|
||||
},
|
||||
},
|
||||
],
|
||||
};
|
||||
|
||||
@@ -13,7 +13,7 @@ export function generateCode(commandFlow) {
|
||||
}
|
||||
|
||||
let awaitCmd = cmd.isAsync ? "await " : "";
|
||||
line += `${awaitCmd}${cmd.value}(${cmd.argv})`;
|
||||
line += `${awaitCmd} ${cmd.argv}`;
|
||||
|
||||
code.push(line);
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user