add background image name reporting for /bg with no args
This commit is contained in:
parent
afeaca0fe0
commit
94f14340ae
|
@ -49,6 +49,7 @@ import { textgen_types, textgenerationwebui_settings } from './textgen-settings.
|
||||||
import { decodeTextTokens, getFriendlyTokenizerName, getTextTokens, getTokenCount } from './tokenizers.js';
|
import { decodeTextTokens, getFriendlyTokenizerName, getTextTokens, getTokenCount } from './tokenizers.js';
|
||||||
import { delay, isFalseBoolean, isTrueBoolean, stringToRange, trimToEndSentence, trimToStartSentence, waitUntilCondition } from './utils.js';
|
import { delay, isFalseBoolean, isTrueBoolean, stringToRange, trimToEndSentence, trimToStartSentence, waitUntilCondition } from './utils.js';
|
||||||
import { registerVariableCommands, resolveVariable } from './variables.js';
|
import { registerVariableCommands, resolveVariable } from './variables.js';
|
||||||
|
import { background_settings } from './backgrounds.js';
|
||||||
export {
|
export {
|
||||||
executeSlashCommands, getSlashCommandsHelp, registerSlashCommand,
|
executeSlashCommands, getSlashCommandsHelp, registerSlashCommand,
|
||||||
};
|
};
|
||||||
|
@ -1609,7 +1610,9 @@ $(document).on('click', '[data-displayHelp]', function (e) {
|
||||||
|
|
||||||
function setBackgroundCallback(_, bg) {
|
function setBackgroundCallback(_, bg) {
|
||||||
if (!bg) {
|
if (!bg) {
|
||||||
return;
|
// allow reporting of the background name if called without args
|
||||||
|
// for use in ST Scripts via pipe
|
||||||
|
return background_settings.name;
|
||||||
}
|
}
|
||||||
|
|
||||||
console.log('Set background to ' + bg);
|
console.log('Set background to ' + bg);
|
||||||
|
|
Loading…
Reference in New Issue