Switch /input command definition to fromProps

fa03443fe7c7fceb545dfa19ce224f4786260986

Wolfsblvt <wolfsblvt@gmail.com>

1 files changed, +34 -18Showing whitespace changes
public/scripts/slash-commands.js+34 -18
@@ -1287,26 +1287,42 @@ export function initDefaultSlashCommands() {
1287 callback: inputCallback,1287 callback: inputCallback,
1288 returns: 'user input',1288 returns: 'user input',
1289 namedArgumentList: [1289 namedArgumentList: [
1290 new SlashCommandNamedArgument(1290 SlashCommandNamedArgument.fromProps({
1291 'default', 'default value of the input field', [ARGUMENT_TYPE.STRING], false, false, '"string"',1291 name: 'default',
1292 ),1292 description: 'default value of the input field',
1293 new SlashCommandNamedArgument(1293 typeList: [ARGUMENT_TYPE.STRING],
1294 'large', 'show large input field', [ARGUMENT_TYPE.BOOLEAN], false, false, 'off', commonEnumProviders.boolean('onOff')(),1294 }),
1295 ),1295 SlashCommandNamedArgument.fromProps({
1296 new SlashCommandNamedArgument(1296 name: 'large',
1297 'wide', 'show wide input field', [ARGUMENT_TYPE.BOOLEAN], false, false, 'off', commonEnumProviders.boolean('onOff')(),1297 description: 'show large input field',
1298 ),1298 typeList: [ARGUMENT_TYPE.BOOLEAN],
1299 new SlashCommandNamedArgument(1299 defaultValue: 'off',
1300 'okButton', 'text for the ok button', [ARGUMENT_TYPE.STRING], false,1300 enumList: commonEnumProviders.boolean('onOff')(),
1301 ),1301 }),
1302 new SlashCommandNamedArgument(1302 SlashCommandNamedArgument.fromProps({
1303 'rows', 'number of rows for the input field', [ARGUMENT_TYPE.NUMBER], false,1303 name: 'wide',
1304 ),1304 description: 'show wide input field',
1305 typeList: [ARGUMENT_TYPE.BOOLEAN],
1306 defaultValue: 'off',
1307 enumList: commonEnumProviders.boolean('onOff')(),
1308 }),
1309 SlashCommandNamedArgument.fromProps({
1310 name: 'okButton',
1311 description: 'text for the ok button',
1312 typeList: [ARGUMENT_TYPE.STRING],
1313 defaultValue: 'Ok',
1314 }),
1315 SlashCommandNamedArgument.fromProps({
1316 name: 'rows',
1317 description: 'number of rows for the input field',
1318 typeList: [ARGUMENT_TYPE.NUMBER],
1319 }),
1305 ],1320 ],
1306 unnamedArgumentList: [1321 unnamedArgumentList: [
1307 new SlashCommandArgument(1322 SlashCommandArgument.fromProps({
1308 'text to display', [ARGUMENT_TYPE.STRING], false,1323 description: 'text to display',
1309 ),1324 typeList: [ARGUMENT_TYPE.STRING],
1325 }),
1310 ],1326 ],
1311 helpString: `1327 helpString: `
1312 <div>1328 <div>