From 454bab386309017a7833b91e8c1dcfd515c8e14c Mon Sep 17 00:00:00 2001 From: ebolam Date: Thu, 14 Jul 2022 19:34:14 -0400 Subject: [PATCH] Scroll Test --- static/koboldai.js | 8 +++++--- templates/index_new.html | 2 +- 2 files changed, 6 insertions(+), 4 deletions(-) diff --git a/static/koboldai.js b/static/koboldai.js index 10c0cb87..8e0bef57 100644 --- a/static/koboldai.js +++ b/static/koboldai.js @@ -992,9 +992,11 @@ function update_token_lengths() { } max_chunk = -1; for (item of document.getElementById("Selected Text").childNodes) { - chunk_num = parseInt(item.id.replace("Selected Text Chunk ", "")); - if (chunk_num > max_chunk) { - max_chunk = chunk_num; + if (item.id != "story_prompt") { + chunk_num = parseInt(item.id.replace("Selected Text Chunk ", "")); + if (chunk_num > max_chunk) { + max_chunk = chunk_num; + } } } diff --git a/templates/index_new.html b/templates/index_new.html index 4ae8016e..27630f78 100644 --- a/templates/index_new.html +++ b/templates/index_new.html @@ -49,7 +49,7 @@ - +