mirror of
https://github.com/SillyTavern/SillyTavern.git
synced 2025-06-05 21:59:27 +02:00
Editing bugfixes
This commit is contained in:
@ -2828,6 +2828,12 @@ function updateEditArrowClasses() {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
function closeMessageEditor() {
|
||||||
|
if (this_edit_mes_id) {
|
||||||
|
$(`#chat .mes[mesid="${this_edit_mes_id}"] .mes_edit_cancel`).click();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
window["TavernAI"].getContext = function () {
|
window["TavernAI"].getContext = function () {
|
||||||
return {
|
return {
|
||||||
chat: chat,
|
chat: chat,
|
||||||
@ -2867,6 +2873,10 @@ $(document).ready(function () {
|
|||||||
///// SWIPE BUTTON CLICKS ///////
|
///// SWIPE BUTTON CLICKS ///////
|
||||||
|
|
||||||
$(document).on('click', '.swipe_right', function () { //when we click swipe right button
|
$(document).on('click', '.swipe_right', function () { //when we click swipe right button
|
||||||
|
if (chat.length -1 === Number(this_edit_mes_id)) {
|
||||||
|
closeMessageEditor();
|
||||||
|
}
|
||||||
|
|
||||||
const swipe_duration = 120;
|
const swipe_duration = 120;
|
||||||
const swipe_range = 700;
|
const swipe_range = 700;
|
||||||
//console.log(swipe_range);
|
//console.log(swipe_range);
|
||||||
@ -3003,6 +3013,10 @@ $(document).ready(function () {
|
|||||||
});
|
});
|
||||||
|
|
||||||
$(document).on('click', '.swipe_left', function () { // when we swipe left..but no generation.
|
$(document).on('click', '.swipe_left', function () { // when we swipe left..but no generation.
|
||||||
|
if (chat.length -1 === Number(this_edit_mes_id)) {
|
||||||
|
closeMessageEditor();
|
||||||
|
}
|
||||||
|
|
||||||
const swipe_duration = 120;
|
const swipe_duration = 120;
|
||||||
const swipe_range = '700px';
|
const swipe_range = '700px';
|
||||||
chat[chat.length - 1]['swipe_id']--;
|
chat[chat.length - 1]['swipe_id']--;
|
||||||
@ -3745,6 +3759,7 @@ $(document).ready(function () {
|
|||||||
}
|
}
|
||||||
|
|
||||||
else if (id == "option_delete_mes") {
|
else if (id == "option_delete_mes") {
|
||||||
|
closeMessageEditor();
|
||||||
hideSwipeButtons();
|
hideSwipeButtons();
|
||||||
if ((this_chid != undefined && !is_send_press) || (selected_group && !is_group_generating)) {
|
if ((this_chid != undefined && !is_send_press) || (selected_group && !is_group_generating)) {
|
||||||
$("#dialogue_del_mes").css("display", "block");
|
$("#dialogue_del_mes").css("display", "block");
|
||||||
|
@ -2966,35 +2966,16 @@ body.no-blur * {
|
|||||||
backdrop-filter: unset !important;
|
backdrop-filter: unset !important;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
body.no-blur #bg1, body.no-blur #bg2 {
|
||||||
body.no-blur #chat {
|
|
||||||
background-color: var(--black90a) !important;
|
|
||||||
}
|
|
||||||
|
|
||||||
body.no-blur .drawer-content {
|
|
||||||
background-color: var(--black90a) !important;
|
|
||||||
}
|
|
||||||
|
|
||||||
body.no-blur #top-bar {
|
|
||||||
background-color: var(--black90a) !important;
|
|
||||||
}
|
|
||||||
|
|
||||||
body.no-blur #bg1 {
|
|
||||||
filter: unset;
|
filter: unset;
|
||||||
}
|
}
|
||||||
|
|
||||||
body.no-blur #bg2 {
|
body.no-blur .drawer-content,
|
||||||
filter: unset;
|
body.no-blur #chat,
|
||||||
}
|
body.no-blur #top-bar,
|
||||||
|
body.no-blur #character_popup,
|
||||||
body.no-blur #character_popup {
|
body.no-blur #world_popup,
|
||||||
background-color: var(--black90a) !important;
|
body.no-blur #dialogue_popup,
|
||||||
}
|
body.no-blur #select_chat_popup {
|
||||||
|
|
||||||
body.no-blur #world_popup {
|
|
||||||
background-color: var(--black90a) !important;
|
|
||||||
}
|
|
||||||
|
|
||||||
body.no-blur #dialogue_popup {
|
|
||||||
background-color: var(--black90a) !important;
|
background-color: var(--black90a) !important;
|
||||||
}
|
}
|
Reference in New Issue
Block a user