mirror of
https://github.com/SillyTavern/SillyTavern.git
synced 2025-06-05 21:59:27 +02:00
6 favorite character hotswaps (beta quality)
This commit is contained in:
@ -1,4 +1,4 @@
|
||||
import { humanizedDateTime } from "./scripts/RossAscends-mods.js";
|
||||
import { humanizedDateTime, favsToHotswap } from "./scripts/RossAscends-mods.js";
|
||||
import { encode } from "../scripts/gpt-2-3-tokenizer/mod.js";
|
||||
import { GPT3BrowserTokenizer } from "../scripts/gpt-3-tokenizer/gpt3-tokenizer.js";
|
||||
import {
|
||||
@ -735,9 +735,12 @@ function printCharacters() {
|
||||
$("#rm_print_characters_block").append(template);
|
||||
});
|
||||
$("#rm_print_characters_block").prepend(`<hr>`);
|
||||
|
||||
printTags();
|
||||
printGroups();
|
||||
sortCharactersList();
|
||||
favsToHotswap();
|
||||
|
||||
}
|
||||
|
||||
async function getCharacters() {
|
||||
@ -1356,6 +1359,8 @@ function applyFavFilter(enabled) {
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
class StreamingProcessor {
|
||||
showStopButton(messageId) {
|
||||
if (messageId == -1) {
|
||||
@ -3554,6 +3559,7 @@ function updateFavButtonState(state) {
|
||||
$("#fav_checkbox").val(fav_ch_checked);
|
||||
$("#favorite_button").toggleClass('fav_on', fav_ch_checked);
|
||||
$("#favorite_button").toggleClass('fav_off', !fav_ch_checked);
|
||||
|
||||
}
|
||||
|
||||
function callPopup(text, type, inputValue = '') {
|
||||
@ -3818,8 +3824,11 @@ window["SillyTavern"].getContext = function () {
|
||||
};
|
||||
};
|
||||
|
||||
|
||||
|
||||
$(document).ready(function () {
|
||||
|
||||
|
||||
//////////INPUT BAR FOCUS-KEEPING LOGIC/////////////
|
||||
|
||||
let S_TAFocused = false;
|
||||
@ -4704,6 +4713,7 @@ $(document).ready(function () {
|
||||
updateFavButtonState(!fav_ch_checked);
|
||||
if (menu_type != "create") {
|
||||
saveCharacterDebounced();
|
||||
|
||||
}
|
||||
});
|
||||
|
||||
|
Reference in New Issue
Block a user