Working user, Keys and chat

This commit is contained in:
2024-05-11 12:17:09 +02:00
parent a109237922
commit 3061bf7837
11 changed files with 576 additions and 88 deletions
+12 -1
View File
@@ -8,7 +8,7 @@
<div class="dropdown-content">
<div class="dropdown-item">
<div class="field">
<form id="api-keys-form" hx-post="/addKeys" hx-trigger="submit" hx-swap="afterend">
<form id="api-keys-form" hx-post="/addKeys" hx-trigger="submit" hx-target="#api-keys-status">
<div class="field has-addons">
<p class="control has-icons-left is-expanded">
<input class="input is-small {% if OpenaiExists %}is-success{% endif %}" type="text"
@@ -29,6 +29,16 @@
</span>
</p>
</div>
<div class="field has-addons">
<p class="control has-icons-left is-expanded">
<input class="input is-small {% if MistralExists %}is-success{% endif %}" type="text"
{%if not IsLogin %}disabled{% endif %} placeholder="Mistral API key"
name="mistral_key" autocomplete="off">
<span class="icon is-small is-left">
<i class="fas fa-lock"></i>
</span>
</p>
</div>
<div class="field has-addons">
<p class="control">
<button {% if not IsLogin %}disabled{% endif %} type="submit"
@@ -36,6 +46,7 @@
</p>
</div>
</form>
<p id="api-keys-status"></p>
</div>
</div>
</div>