Fix naming inconsistencies
| @@ -746,14 +746,14 @@ export function initDefaultSlashCommands() { | |||
| 746 | ], | 746 | ], |
| 747 | }), | 747 | }), |
| 748 | SlashCommandNamedArgument.fromProps({ | 748 | SlashCommandNamedArgument.fromProps({ |
| 749 | name: 'timeOut', | 749 | name: 'timeout', |
| 750 | description: 'time in milliseconds to display the toast message. Set this and \'extendedTimeout\' to 0 to show indefinitely until dismissed.', | 750 | description: 'time in milliseconds to display the toast message. Set this and \'extendedTimeout\' to 0 to show indefinitely until dismissed.', |
| 751 | typeList: [ARGUMENT_TYPE.NUMBER], | 751 | typeList: [ARGUMENT_TYPE.NUMBER], |
| 752 | defaultValue: `${toastr.options.timeOut}`, | 752 | defaultValue: `${toastr.options.timeOut}`, |
| 753 | }), | 753 | }), |
| 754 | SlashCommandNamedArgument.fromProps({ | 754 | SlashCommandNamedArgument.fromProps({ |
| 755 | name: 'extendedTimeout', | 755 | name: 'extendedTimeout', |
| 756 | description: 'time in milliseconds to display the toast message. Set this and \'timeOut\' to 0 to show indefinitely until dismissed.', | 756 | description: 'time in milliseconds to display the toast message. Set this and \'timeout\' to 0 to show indefinitely until dismissed.', |
| 757 | typeList: [ARGUMENT_TYPE.NUMBER], | 757 | typeList: [ARGUMENT_TYPE.NUMBER], |
| 758 | defaultValue: `${toastr.options.extendedTimeOut}`, | 758 | defaultValue: `${toastr.options.extendedTimeOut}`, |
| 759 | }), | 759 | }), |
| @@ -1967,7 +1967,7 @@ async function generateCallback(args, value) { | |||
| 1967 | 1967 | ||
| 1968 | /** | 1968 | /** |
| 1969 | * | 1969 | * |
| 1970 | * @param {{title?: string, severity?: string, timeOut?: string, extendedTimeOut?: string, preventDuplicates?: string, awaitDismissal?: string}} args - named arguments from the slash command | 1970 | * @param {{title?: string, severity?: string, timeout?: string, extendedTimeout?: string, preventDuplicates?: string, awaitDismissal?: string}} args - named arguments from the slash command |
| 1971 | * @param {string} value - The string to echo (unnamed argument from the slash command) | 1971 | * @param {string} value - The string to echo (unnamed argument from the slash command) |
| 1972 | * @returns {Promise<string>} The text that was echoed | 1972 | * @returns {Promise<string>} The text that was echoed |
| 1973 | */ | 1973 | */ |
| @@ -1988,8 +1988,8 @@ async function echoCallback(args, value) { | |||
| 1988 | 1988 | ||
| 1989 | /** @type {ToastrOptions} */ | 1989 | /** @type {ToastrOptions} */ |
| 1990 | const options = {}; | 1990 | const options = {}; |
| 1991 | if (args.timeOut && !isNaN(parseInt(args.timeOut))) options.timeOut = parseInt(args.timeOut); | 1991 | if (args.timeout && !isNaN(parseInt(args.timeout))) options.timeOut = parseInt(args.timeout); |
| 1992 | if (args.extendedTimeOut && !isNaN(parseInt(args.extendedTimeOut))) options.extendedTimeOut = parseInt(args.extendedTimeOut); | 1992 | if (args.extendedTimeout && !isNaN(parseInt(args.extendedTimeout))) options.extendedTimeOut = parseInt(args.extendedTimeout); |
| 1993 | if (isTrueBoolean(args.preventDuplicates)) options.preventDuplicates = true; | 1993 | if (isTrueBoolean(args.preventDuplicates)) options.preventDuplicates = true; |
| 1994 | 1994 | ||
| 1995 | // Prepare possible await handling | 1995 | // Prepare possible await handling |