waitForFrame in scrollChatToBottom in sync scenarios #4791
| @@ -1416,7 +1416,7 @@ export async function printMessages() { | ||
| 1416 | 1416 | chatElement.find('.mes').last().addClass('last_mes'); |
| 1417 | 1417 | refreshSwipeButtons(); |
| 1418 | 1418 | applyStylePins(); |
| 1419 | 1419 | scrollChatToBottom({ waitForFrame: true }); |
| 1420 | 1420 | delay(debounce_timeout.short).then(() => scrollOnMediaLoad()); |
| 1421 | 1421 | } |
| 1422 | 1422 | |
| @@ -2532,7 +2532,7 @@ export function addOneMessage(mes, { type = 'normal', insertAfter = null, scroll | ||
| 2532 | 2532 | |
| 2533 | 2533 | // Don't scroll if not inserting last |
| 2534 | 2534 | if (!insertAfter && !insertBefore && scroll) { |
| 2535 | 2535 | scrollChatToBottom({ waitForFrame: true }); |
| 2536 | 2536 | } |
| 2537 | 2537 | |
| 2538 | 2538 | applyCharacterTagsToMessageDivs({ mesIds: newMessageId }); |