From 558bbce919643177b4a0de3d3dd6784a249944ac Mon Sep 17 00:00:00 2001 From: Cohee <18619528+Cohee1207@users.noreply.github.com> Date: Mon, 15 Jul 2024 01:18:54 +0300 Subject: [PATCH 01/71] Fix phone scrolling of logprobs --- public/scripts/logprobs.js | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/public/scripts/logprobs.js b/public/scripts/logprobs.js index 90050b4d1..3eec73aae 100644 --- a/public/scripts/logprobs.js +++ b/public/scripts/logprobs.js @@ -110,7 +110,9 @@ function renderAlternativeTokensView() { // scroll past long prior context if (prefix) { - view.find('.logprobs_output_token').first()[0].scrollIntoView(); + const element = view.find('.logprobs_output_token').first(); + const scrollOffset = element.offset().top - element.parent().offset().top; + element.parent().scrollTop(scrollOffset); } } From 6f936bc99791ef8ea1e4b2663b21c6b3be3b10b9 Mon Sep 17 00:00:00 2001 From: Wolfsblvt Date: Mon, 15 Jul 2024 00:46:45 +0200 Subject: [PATCH 02/71] I can't spell. Don't look at it. --- public/scripts/popup.js | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/public/scripts/popup.js b/public/scripts/popup.js index 4b69041d0..691f42aae 100644 --- a/public/scripts/popup.js +++ b/public/scripts/popup.js @@ -339,9 +339,9 @@ export class Popup { this.dlg.addEventListener('cancel', cancelListener.bind(this)); // Don't ask me why this is needed. I don't get it. But we have to keep it. - // We make sure that the modal on it's own doesn't hide. Dunno why, if onClosing is triggered multiple times through the cancel event, and stopped - // It seems to just call 'close' on the dialog even if the 'cancel' event was prevented. - // Here, we just say that close should not happen if the dalog has no result. + // We make sure that the modal on its own doesn't hide. Dunno why, if onClosing is triggered multiple times through the cancel event, and stopped, + // it seems to just call 'close' on the dialog even if the 'cancel' event was prevented. + // So here we just say that close should not happen if it was prevented. const closeListener = async (evt) => { if (this.#isClosingPrevented) { evt.preventDefault(); From 921ae16391c9fb1401c563e96b87f93f4eff29ab Mon Sep 17 00:00:00 2001 From: Succubyss <87207237+Succubyss@users.noreply.github.com> Date: Mon, 15 Jul 2024 13:17:30 -0500 Subject: [PATCH 03/71] layman's explanation of REPLACE_GETVAR --- public/index.html | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/public/index.html b/public/index.html index 450f33f0e..6ac770401 100644 --- a/public/index.html +++ b/public/index.html @@ -4259,7 +4259,7 @@ -