mirror of
https://github.com/SillyTavern/SillyTavern.git
synced 2025-03-03 03:17:54 +01:00
trim start of first and end of lat value part in unsplit unnamed arg (analog to pure text arg)
This commit is contained in:
parent
bc40ee084d
commit
13496cfb3a
@ -904,6 +904,14 @@ export class SlashCommandParser {
|
|||||||
listValues.push(assignment);
|
listValues.push(assignment);
|
||||||
}
|
}
|
||||||
if (isList) {
|
if (isList) {
|
||||||
|
const firstVal = listValues[0];
|
||||||
|
if (typeof firstVal.value == 'string') {
|
||||||
|
firstVal.value = firstVal.value.trimStart();
|
||||||
|
}
|
||||||
|
const lastVal = listValues.slice(-1)[0];
|
||||||
|
if (typeof lastVal.value == 'string') {
|
||||||
|
lastVal.value = lastVal.value.trimEnd();
|
||||||
|
}
|
||||||
return listValues;
|
return listValues;
|
||||||
}
|
}
|
||||||
this.indexMacros(this.index - value.length, value);
|
this.indexMacros(this.index - value.length, value);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user