From 594789bdfadebea41bceef069adfbe24dbaa82d9 Mon Sep 17 00:00:00 2001 From: ebolam Date: Mon, 15 Aug 2022 18:17:25 -0400 Subject: [PATCH 1/3] Fix for retry --- aiserver.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/aiserver.py b/aiserver.py index f422a89b..425862ed 100644 --- a/aiserver.py +++ b/aiserver.py @@ -6382,6 +6382,7 @@ def UI_2_Pinning(data): @socketio.on('back') def UI_2_back(data): print("back") + koboldai_vars.actions.clear_unused_options() ignore = koboldai_vars.actions.pop() #==================================================================# @@ -6391,13 +6392,15 @@ def UI_2_back(data): def UI_2_redo(data): if len(koboldai_vars.actions.get_current_options()) == 1: koboldai_vars.actions.use_option(0) + #==================================================================# # Event triggered when user clicks the retry button #==================================================================# @socketio.on('retry') def UI_2_retry(data): - if koboldai_vars.numseqs == 1: + + if len(koboldai_vars.actions.get_current_options()) == 0: UI_2_back(None) koboldai_vars.actions.clear_unused_options() koboldai_vars.lua_koboldbridge.feedback = None From 8cd14713f95ce4a0b707e2224808470afefa1616 Mon Sep 17 00:00:00 2001 From: ebolam Date: Mon, 15 Aug 2022 18:56:39 -0400 Subject: [PATCH 2/3] Better Random Story placement --- static/koboldai.css | 18 ++++++++++++++---- templates/index_new.html | 25 +++++++++++++++---------- 2 files changed, 29 insertions(+), 14 deletions(-) diff --git a/static/koboldai.css b/static/koboldai.css index 25f0ae5e..c13b2618 100644 --- a/static/koboldai.css +++ b/static/koboldai.css @@ -102,6 +102,8 @@ z-index: 2; border-bottom-color: #FFF; } + + .tabrow:before { position: absolute; content: " "; @@ -166,7 +168,7 @@ grid-template-areas: "label value" "item item" "minlabel maxlabel"; - grid-template-rows: 20px 25px 10px; + grid-template-rows: 20px 25px 15px; grid-template-columns: 160px 40px; row-gap: 0.2em; background-color: var(--setting_background); @@ -190,12 +192,16 @@ .setting_minlabel { grid-area: minlabel; overflow: hidden; + padding: 5px; + padding-top: 0px; font-size: 0.8em; } .setting_maxlabel { grid-area: maxlabel; overflow: hidden; + padding: 5px; + padding-top: 0px; text-align: right; font-size: 0.8em; } @@ -203,11 +209,15 @@ .setting_label { grid-area: label; overflow: hidden; + padding: 5px; + padding-top: 0px; } .setting_value { text-align: right; grid-area: value; + padding: 5px; + padding-top: 0px; background-color: inherit; color: inherit; border: none; @@ -319,7 +329,7 @@ height: 100%; width: var(--flyout_menu_closed_width); position: fixed; - z-index: 1; + z-index: 3; top: 0; left: 0; background-color: var(--flyout_background); @@ -332,7 +342,7 @@ height: 100%; width: var(--flyout_menu_width); position: fixed; - z-index: 1; + z-index: 2; top: 0; left: 0; background-color: var(--flyout_background); @@ -511,7 +521,7 @@ height: 100%; width: 0; position: fixed; - z-index: 1; + z-index: 3; top: 0; right: 0; background-color: var(--flyout_background); diff --git a/templates/index_new.html b/templates/index_new.html index 0757654c..51045d63 100644 --- a/templates/index_new.html +++ b/templates/index_new.html @@ -45,20 +45,25 @@
-

If you want to generate a random prompt, insert a theme here:

- -

If you want to write your prompt, insert it here:

+
+ Prompt + Random Prompt +
+ {% endif %} {% endfor %} \ No newline at end of file