Merge pull request #2 from mounta11n/server-ui-improvements
Server UI improvements
This commit is contained in:
commit
d55b482361
8 changed files with 103 additions and 104 deletions
|
@ -35,4 +35,4 @@
|
||||||
"BUTTON_START_INFERENCE": "",
|
"BUTTON_START_INFERENCE": "",
|
||||||
"POWERED_BY": "",
|
"POWERED_BY": "",
|
||||||
"AND": ""
|
"AND": ""
|
||||||
}
|
}
|
||||||
|
|
|
@ -47,4 +47,4 @@ export const systemPrompts = {
|
||||||
synthia: {
|
synthia: {
|
||||||
systemPrompt: "Erarbeite das Thema anhand eines Gedankenbaums und gehe bei Bedarf zurück, um eine klare, zusammenhängende Gedankenkette zu erstellen. Antworte immer ohne zu zögern."
|
systemPrompt: "Erarbeite das Thema anhand eines Gedankenbaums und gehe bei Bedarf zurück, um eine klare, zusammenhängende Gedankenkette zu erstellen. Antworte immer ohne zu zögern."
|
||||||
},
|
},
|
||||||
};
|
};
|
||||||
|
|
|
@ -35,4 +35,4 @@
|
||||||
"BUTTON_START_INFERENCE": "Senden",
|
"BUTTON_START_INFERENCE": "Senden",
|
||||||
"POWERED_BY": "Unterstützt Durch",
|
"POWERED_BY": "Unterstützt Durch",
|
||||||
"AND": "und"
|
"AND": "und"
|
||||||
}
|
}
|
||||||
|
|
|
@ -35,4 +35,4 @@
|
||||||
"BUTTON_START_INFERENCE": "Submit",
|
"BUTTON_START_INFERENCE": "Submit",
|
||||||
"POWERED_BY": "Powered By",
|
"POWERED_BY": "Powered By",
|
||||||
"AND": "and"
|
"AND": "and"
|
||||||
}
|
}
|
||||||
|
|
|
@ -6,7 +6,7 @@
|
||||||
<meta name="color-scheme" content="light dark">
|
<meta name="color-scheme" content="light dark">
|
||||||
<title>llama.cpp - chat</title>
|
<title>llama.cpp - chat</title>
|
||||||
<link rel="stylesheet" href="style.css">
|
<link rel="stylesheet" href="style.css">
|
||||||
|
|
||||||
<script type="module">
|
<script type="module">
|
||||||
import {
|
import {
|
||||||
html, h, signal, effect, computed, render, useSignal, useEffect, useRef, Component
|
html, h, signal, effect, computed, render, useSignal, useEffect, useRef, Component
|
||||||
|
@ -230,8 +230,7 @@
|
||||||
currentMessages.push(data);
|
currentMessages.push(data);
|
||||||
slot_id = data.slot_id;
|
slot_id = data.slot_id;
|
||||||
if (selected_image && !data.multimodal) {
|
if (selected_image && !data.multimodal) {
|
||||||
alert("Der Server wurde nicht für multimodal zusammengestellt oder der Modellprojektor kann nicht geladen werden.");
|
alert("The server was not compiled for multimodal or the model projector can't be loaded."); return;
|
||||||
return;
|
|
||||||
}
|
}
|
||||||
transcriptUpdate([...history, [char, currentMessages]])
|
transcriptUpdate([...history, [char, currentMessages]])
|
||||||
}
|
}
|
||||||
|
@ -354,7 +353,7 @@
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="right">
|
<div class="right">
|
||||||
<button class="button-back" onclick=${reset}>Back</button>
|
<button class="button-back" onclick=${reset}>Back</button>
|
||||||
<button onclick=${uploadImage}>Upload Image</button>
|
<button onclick=${uploadImage}>Upload Image</button>
|
||||||
<button onclick=${stop} disabled=${!generating.value}>Stop</button>
|
<button onclick=${stop} disabled=${!generating.value}>Stop</button>
|
||||||
<button type="submit" disabled=${generating.value}>Submit</button>
|
<button type="submit" disabled=${generating.value}>Submit</button>
|
||||||
|
@ -372,7 +371,7 @@
|
||||||
<div>
|
<div>
|
||||||
<button onclick=${submit} type="button" disabled=${generating.value}>Start</button>
|
<button onclick=${submit} type="button" disabled=${generating.value}>Start</button>
|
||||||
<button onclick=${stop} disabled=${!generating.value}>Stop</button>
|
<button onclick=${stop} disabled=${!generating.value}>Stop</button>
|
||||||
<button onclick=${reset}>Back</button>
|
<button onclick=${reset}>Back</button>
|
||||||
</div>`;
|
</div>`;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -517,22 +516,22 @@ async function updateSystemLanguage(event) {
|
||||||
}
|
}
|
||||||
//
|
//
|
||||||
// async function updateTexts(systemPrompts) {
|
// async function updateTexts(systemPrompts) {
|
||||||
// // Aktualisiere die Texte, die aus den Sprachdateien kommen
|
// // Update the texts that come from the language files
|
||||||
// document.querySelector('#someElement').textContent = systemPrompts.default.systemPrompt;
|
// document.querySelector('#someElement').textContent = systemPrompts.default.systemPrompt;
|
||||||
// // Lade die JSON-Datei für die UI-Elemente
|
// // Load the JSON file for the UI elements
|
||||||
// const uiLanguageFile = `./${language}_texts.json`;
|
// const uiLanguageFile = `./${language}_texts.json`;
|
||||||
// try {
|
// try {
|
||||||
// const response = await fetch(uiLanguageFile);
|
// const response = await fetch(uiLanguageFile);
|
||||||
// const uiTexts = await response.json();
|
// const uiTexts = await response.json();
|
||||||
// // Aktualisiere die UI-Elemente
|
// // Update the UI elements
|
||||||
// // document.querySelector('label[for="user"]').textContent = uiTexts.USER_NAME;
|
// // document.querySelector('label[for="user"]').textContent = uiTexts.USER_NAME;
|
||||||
// document.getElementById('label-user').textContent = uiTexts.USER_NAME;
|
// document.getElementById('label-user').textContent = uiTexts.USER_NAME;
|
||||||
// // Weitere Elemente aktualisieren
|
// // Update further elements
|
||||||
// } catch (error) {
|
// } catch (error) {
|
||||||
// console.error('Fehler beim Laden der UI-Texte:', error);
|
// console.error('Error when loading the UI texts:', error);
|
||||||
// }
|
// }
|
||||||
// }
|
// }
|
||||||
//
|
//
|
||||||
///////////// WORK IN PROGRESS ///////////// MULTILINGUAL UI AND PROMPTS //
|
///////////// WORK IN PROGRESS ///////////// MULTILINGUAL UI AND PROMPTS //
|
||||||
//
|
//
|
||||||
///////////////////////////////////////////////////////////////////////////
|
///////////////////////////////////////////////////////////////////////////
|
||||||
|
@ -564,7 +563,7 @@ async function updateSystemLanguage(event) {
|
||||||
grammar: converter.formatGrammar(),
|
grammar: converter.formatGrammar(),
|
||||||
}
|
}
|
||||||
} catch (e) {
|
} catch (e) {
|
||||||
alert(`Konvertierung fehlgeschlagen: ${e.message}`)
|
alert(`Conversion failed: ${e.message}`)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -746,7 +745,7 @@ async function updateSystemLanguage(event) {
|
||||||
<details>
|
<details>
|
||||||
<summary><span class="summary-title" id="id_grammar-title" id_grammar-title>Grammar</span></summary>
|
<summary><span class="summary-title" id="id_grammar-title" id_grammar-title>Grammar</span></summary>
|
||||||
${GrammarControl()}
|
${GrammarControl()}
|
||||||
</details>
|
</details>
|
||||||
</fieldset>
|
</fieldset>
|
||||||
`
|
`
|
||||||
);
|
);
|
||||||
|
@ -768,7 +767,7 @@ async function updateSystemLanguage(event) {
|
||||||
</label>
|
</label>
|
||||||
<${UserTemplateResetButton}/>
|
<${UserTemplateResetButton}/>
|
||||||
</fieldset>
|
</fieldset>
|
||||||
|
|
||||||
${session.value.type === 'chat' ? ChatConfigForm() : CompletionConfigForm()}
|
${session.value.type === 'chat' ? ChatConfigForm() : CompletionConfigForm()}
|
||||||
|
|
||||||
<fieldset class="two">
|
<fieldset class="two">
|
||||||
|
@ -888,7 +887,7 @@ async function updateSystemLanguage(event) {
|
||||||
}
|
}
|
||||||
return html`
|
return html`
|
||||||
<span>
|
<span>
|
||||||
${llamaStats.value.predicted_per_token_ms.toFixed()}ms pro Token, ${llamaStats.value.predicted_per_second.toFixed(2)} Token pro Sekunde
|
${llamaStats.value.predicted_per_token_ms.toFixed()}ms per token, ${llamaStats.value.predicted_per_second.toFixed(2)} tokens per second
|
||||||
</span>
|
</span>
|
||||||
`
|
`
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
// extended list
|
// extended list
|
||||||
export const promptFormats = {
|
export const promptFormats = {
|
||||||
"airoborosl2": {
|
"airoborosl2": {
|
||||||
template: "{{prompt}} {{history}} {{char}}",
|
template: "{{prompt}} {{history}} {{char}}",
|
||||||
historyTemplate: "{{name}}: {{message}}",
|
historyTemplate: "{{name}}: {{message}}",
|
||||||
|
|
|
@ -10,7 +10,7 @@
|
||||||
--input-focus-border-color: #11a37f;
|
--input-focus-border-color: #11a37f;
|
||||||
--loading-color-1: #eeeeee00;
|
--loading-color-1: #eeeeee00;
|
||||||
--loading-color-2: #eeeeeeff;
|
--loading-color-2: #eeeeeeff;
|
||||||
|
|
||||||
/* Dark topic colors (to add/adapt — WIP) */
|
/* Dark topic colors (to add/adapt — WIP) */
|
||||||
--dark-primary-color: #13b896;
|
--dark-primary-color: #13b896;
|
||||||
--dark-secondary-color: #1a2a33;
|
--dark-secondary-color: #1a2a33;
|
||||||
|
@ -23,7 +23,7 @@
|
||||||
--dark-loading-color-1: #33333300;
|
--dark-loading-color-1: #33333300;
|
||||||
--dark-loading-color-2: #333333ff;
|
--dark-loading-color-2: #333333ff;
|
||||||
}
|
}
|
||||||
|
|
||||||
body {
|
body {
|
||||||
font-family: 'Arial', sans-serif;
|
font-family: 'Arial', sans-serif;
|
||||||
font-size: 90%;
|
font-size: 90%;
|
||||||
|
@ -35,11 +35,11 @@
|
||||||
margin: 0 auto;
|
margin: 0 auto;
|
||||||
padding: 0 0.5em;
|
padding: 0 0.5em;
|
||||||
}
|
}
|
||||||
|
|
||||||
code, pre code {
|
code, pre code {
|
||||||
font-family: 'Courier New', monospace;
|
font-family: 'Courier New', monospace;
|
||||||
}
|
}
|
||||||
|
|
||||||
#container {
|
#container {
|
||||||
margin: 0em auto;
|
margin: 0em auto;
|
||||||
display: flex;
|
display: flex;
|
||||||
|
@ -47,7 +47,7 @@
|
||||||
justify-content: space-between;
|
justify-content: space-between;
|
||||||
height: 100%;
|
height: 100%;
|
||||||
}
|
}
|
||||||
|
|
||||||
main {
|
main {
|
||||||
margin: 3px;
|
margin: 3px;
|
||||||
display: flex;
|
display: flex;
|
||||||
|
@ -60,7 +60,7 @@
|
||||||
border-radius: 5px;
|
border-radius: 5px;
|
||||||
padding: 0.5em;
|
padding: 0.5em;
|
||||||
}
|
}
|
||||||
|
|
||||||
p {
|
p {
|
||||||
overflow-wrap: break-word;
|
overflow-wrap: break-word;
|
||||||
word-wrap: break-word;
|
word-wrap: break-word;
|
||||||
|
@ -68,7 +68,7 @@
|
||||||
margin-top: 0.5em;
|
margin-top: 0.5em;
|
||||||
margin-bottom: 0.5em;
|
margin-bottom: 0.5em;
|
||||||
}
|
}
|
||||||
|
|
||||||
#write form {
|
#write form {
|
||||||
margin: 1em 0 0 0;
|
margin: 1em 0 0 0;
|
||||||
display: flex;
|
display: flex;
|
||||||
|
@ -76,34 +76,34 @@
|
||||||
gap: 0.5em;
|
gap: 0.5em;
|
||||||
align-items: stretch;
|
align-items: stretch;
|
||||||
}
|
}
|
||||||
|
|
||||||
.right {
|
.right {
|
||||||
display: flex;
|
display: flex;
|
||||||
flex-direction: row;
|
flex-direction: row;
|
||||||
gap: 0.5em;
|
gap: 0.5em;
|
||||||
justify-content: flex-end;
|
justify-content: flex-end;
|
||||||
}
|
}
|
||||||
|
|
||||||
.two-columns {
|
.two-columns {
|
||||||
display: grid;
|
display: grid;
|
||||||
grid-template-columns: 1fr 1fr;
|
grid-template-columns: 1fr 1fr;
|
||||||
gap: 1em;
|
gap: 1em;
|
||||||
}
|
}
|
||||||
|
|
||||||
.summary-title {
|
.summary-title {
|
||||||
font-weight: 600;
|
font-weight: 600;
|
||||||
font-size: x-small;
|
font-size: x-small;
|
||||||
color: var(--secondary-color);
|
color: var(--secondary-color);
|
||||||
text-transform: uppercase;
|
text-transform: uppercase;
|
||||||
}
|
}
|
||||||
|
|
||||||
fieldset {
|
fieldset {
|
||||||
border: none;
|
border: none;
|
||||||
padding: 0;
|
padding: 0;
|
||||||
margin: 0;
|
margin: 0;
|
||||||
color: #353740;
|
color: #353740;
|
||||||
}
|
}
|
||||||
|
|
||||||
fieldset.two {
|
fieldset.two {
|
||||||
display: grid;
|
display: grid;
|
||||||
grid-template: "a a";
|
grid-template: "a a";
|
||||||
|
@ -111,7 +111,7 @@
|
||||||
font-size: x-small;
|
font-size: x-small;
|
||||||
color: var(--text-color);
|
color: var(--text-color);
|
||||||
}
|
}
|
||||||
|
|
||||||
fieldset.three {
|
fieldset.three {
|
||||||
display: grid;
|
display: grid;
|
||||||
grid-template: "a a a";
|
grid-template: "a a a";
|
||||||
|
@ -119,7 +119,7 @@
|
||||||
font-size: x-small;
|
font-size: x-small;
|
||||||
color: var(--text-color);
|
color: var(--text-color);
|
||||||
}
|
}
|
||||||
|
|
||||||
fieldset.names {
|
fieldset.names {
|
||||||
display: grid;
|
display: grid;
|
||||||
grid-template: "a a";
|
grid-template: "a a";
|
||||||
|
@ -131,7 +131,7 @@
|
||||||
text-transform: uppercase;
|
text-transform: uppercase;
|
||||||
font-weight: 600;
|
font-weight: 600;
|
||||||
}
|
}
|
||||||
|
|
||||||
fieldset.dropdowns {
|
fieldset.dropdowns {
|
||||||
display: flex;
|
display: flex;
|
||||||
grid-template: "a a";
|
grid-template: "a a";
|
||||||
|
@ -143,7 +143,7 @@
|
||||||
text-transform: uppercase;
|
text-transform: uppercase;
|
||||||
font-weight: 600;
|
font-weight: 600;
|
||||||
}
|
}
|
||||||
|
|
||||||
.names input[type="text"] {
|
.names input[type="text"] {
|
||||||
font-family: Arial, sans-serif;
|
font-family: Arial, sans-serif;
|
||||||
font-size: medium;
|
font-size: medium;
|
||||||
|
@ -152,45 +152,45 @@
|
||||||
padding: 5px;
|
padding: 5px;
|
||||||
border: 1px solid var(--border-color);
|
border: 1px solid var(--border-color);
|
||||||
}
|
}
|
||||||
|
|
||||||
.names input[type="text"].special-text-format {
|
.names input[type="text"].special-text-format {
|
||||||
font-style: italic;
|
font-style: italic;
|
||||||
font-weight: bold;
|
font-weight: bold;
|
||||||
color: #FF0000;
|
color: #FF0000;
|
||||||
}
|
}
|
||||||
|
|
||||||
details {
|
details {
|
||||||
border: 1px solid #ececf1;
|
border: 1px solid #ececf1;
|
||||||
border-radius: 10px;
|
border-radius: 10px;
|
||||||
padding: 0.5em 0.5em 0;
|
padding: 0.5em 0.5em 0;
|
||||||
margin-top: 0.5em;
|
margin-top: 0.5em;
|
||||||
}
|
}
|
||||||
|
|
||||||
summary {
|
summary {
|
||||||
font-weight: bold;
|
font-weight: bold;
|
||||||
margin: -0.5em -0.5em 0;
|
margin: -0.5em -0.5em 0;
|
||||||
padding: 0.5em;
|
padding: 0.5em;
|
||||||
cursor: pointer;
|
cursor: pointer;
|
||||||
}
|
}
|
||||||
|
|
||||||
details[open] {
|
details[open] {
|
||||||
padding: 0.5em;
|
padding: 0.5em;
|
||||||
}
|
}
|
||||||
|
|
||||||
textarea-sec, input-sec, button-sec {
|
textarea-sec, input-sec, button-sec {
|
||||||
padding: 10px;
|
padding: 10px;
|
||||||
height: 40px;
|
height: 40px;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
}
|
}
|
||||||
|
|
||||||
textarea-sec::placeholder, input-sec::placeholder {
|
textarea-sec::placeholder, input-sec::placeholder {
|
||||||
padding-left: 10px;
|
padding-left: 10px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.toggleCheckbox {
|
.toggleCheckbox {
|
||||||
display: none;
|
display: none;
|
||||||
}
|
}
|
||||||
|
|
||||||
.toggleContainer {
|
.toggleContainer {
|
||||||
position: relative;
|
position: relative;
|
||||||
display: grid;
|
display: grid;
|
||||||
|
@ -203,7 +203,7 @@
|
||||||
cursor: pointer;
|
cursor: pointer;
|
||||||
overflow: hidden;
|
overflow: hidden;
|
||||||
}
|
}
|
||||||
|
|
||||||
.toggleContainer::before {
|
.toggleContainer::before {
|
||||||
content: '';
|
content: '';
|
||||||
position: absolute;
|
position: absolute;
|
||||||
|
@ -214,39 +214,39 @@
|
||||||
background: var(--primary-color);
|
background: var(--primary-color);
|
||||||
transition: all 0.3s;
|
transition: all 0.3s;
|
||||||
}
|
}
|
||||||
|
|
||||||
.toggleContainer div {
|
.toggleContainer div {
|
||||||
padding: 6px;
|
padding: 6px;
|
||||||
text-align: center;
|
text-align: center;
|
||||||
z-index: 1;
|
z-index: 1;
|
||||||
transition: color 0.3s;
|
transition: color 0.3s;
|
||||||
}
|
}
|
||||||
|
|
||||||
.toggleCheckbox:checked + .toggleContainer::before {
|
.toggleCheckbox:checked + .toggleContainer::before {
|
||||||
left: 50%;
|
left: 50%;
|
||||||
}
|
}
|
||||||
|
|
||||||
.toggleCheckbox:checked + .toggleContainer div:first-child {
|
.toggleCheckbox:checked + .toggleContainer div:first-child {
|
||||||
color: var(--text-color);
|
color: var(--text-color);
|
||||||
}
|
}
|
||||||
|
|
||||||
.toggleCheckbox:checked + .toggleContainer div:last-child {
|
.toggleCheckbox:checked + .toggleContainer div:last-child {
|
||||||
color: var(--background-color);
|
color: var(--background-color);
|
||||||
}
|
}
|
||||||
|
|
||||||
.toggleCheckbox + .toggleContainer div:first-child {
|
.toggleCheckbox + .toggleContainer div:first-child {
|
||||||
color: var(--background-color);
|
color: var(--background-color);
|
||||||
}
|
}
|
||||||
|
|
||||||
.toggleCheckbox + .toggleContainer div:last-child {
|
.toggleCheckbox + .toggleContainer div:last-child {
|
||||||
color: var(--text-color);
|
color: var(--text-color);
|
||||||
}
|
}
|
||||||
|
|
||||||
.button-container {
|
.button-container {
|
||||||
display: flex;
|
display: flex;
|
||||||
justify-content: flex-end;
|
justify-content: flex-end;
|
||||||
}
|
}
|
||||||
|
|
||||||
.reset-button {
|
.reset-button {
|
||||||
width: fit-content;
|
width: fit-content;
|
||||||
height: fit-content;
|
height: fit-content;
|
||||||
|
@ -258,13 +258,13 @@
|
||||||
border-radius: 50px;
|
border-radius: 50px;
|
||||||
overflow: hidden;
|
overflow: hidden;
|
||||||
}
|
}
|
||||||
|
|
||||||
.reset-button:hover {
|
.reset-button:hover {
|
||||||
color: var(--background-color);
|
color: var(--background-color);
|
||||||
background-color: var(--button-hover-alert);
|
background-color: var(--button-hover-alert);
|
||||||
border: 1px solid var(--button-hover-alert);
|
border: 1px solid var(--button-hover-alert);
|
||||||
}
|
}
|
||||||
|
|
||||||
select {
|
select {
|
||||||
padding: 5px;
|
padding: 5px;
|
||||||
border-radius: 8px;
|
border-radius: 8px;
|
||||||
|
@ -272,12 +272,12 @@
|
||||||
background-color: white;
|
background-color: white;
|
||||||
cursor: pointer;
|
cursor: pointer;
|
||||||
}
|
}
|
||||||
|
|
||||||
select:focus {
|
select:focus {
|
||||||
border: 1px solid var(--input-focus-border-color);
|
border: 1px solid var(--input-focus-border-color);
|
||||||
box-shadow: 0 0 1px var(--input-focus-border-color);
|
box-shadow: 0 0 1px var(--input-focus-border-color);
|
||||||
}
|
}
|
||||||
|
|
||||||
button {
|
button {
|
||||||
background-color: var(--primary-color);
|
background-color: var(--primary-color);
|
||||||
color: white;
|
color: white;
|
||||||
|
@ -294,13 +294,13 @@
|
||||||
border-radius: 12px;
|
border-radius: 12px;
|
||||||
border: 1px solid #f0f0f0;
|
border: 1px solid #f0f0f0;
|
||||||
}
|
}
|
||||||
|
|
||||||
button:hover {
|
button:hover {
|
||||||
background-color: var(--button-hover-color);
|
background-color: var(--button-hover-color);
|
||||||
font-size: x-small;
|
font-size: x-small;
|
||||||
font-weight: 600;
|
font-weight: 600;
|
||||||
}
|
}
|
||||||
|
|
||||||
button:disabled {
|
button:disabled {
|
||||||
color: #acacbd;
|
color: #acacbd;
|
||||||
background-color: #f7f7f8;
|
background-color: #f7f7f8;
|
||||||
|
@ -308,7 +308,7 @@
|
||||||
font-size: x-small;
|
font-size: x-small;
|
||||||
font-weight: 600;
|
font-weight: 600;
|
||||||
}
|
}
|
||||||
|
|
||||||
.button-back {
|
.button-back {
|
||||||
background-color: #cccccc;
|
background-color: #cccccc;
|
||||||
color: #353740;
|
color: #353740;
|
||||||
|
@ -325,7 +325,7 @@
|
||||||
border-radius: 12px;
|
border-radius: 12px;
|
||||||
border: 1px solid #f0f0f0;
|
border: 1px solid #f0f0f0;
|
||||||
}
|
}
|
||||||
|
|
||||||
.button-back:hover {
|
.button-back:hover {
|
||||||
background-color: #353740;
|
background-color: #353740;
|
||||||
color: #f0f0f0;
|
color: #f0f0f0;
|
||||||
|
@ -342,7 +342,7 @@
|
||||||
border-radius: 12px;
|
border-radius: 12px;
|
||||||
border: 1px solid #f0f0f0;
|
border: 1px solid #f0f0f0;
|
||||||
}
|
}
|
||||||
|
|
||||||
.button-grammar {
|
.button-grammar {
|
||||||
background-color: var(--primary-color);
|
background-color: var(--primary-color);
|
||||||
color: white;
|
color: white;
|
||||||
|
@ -358,7 +358,7 @@
|
||||||
border-radius: 10px;
|
border-radius: 10px;
|
||||||
border: 1px solid #f0f0f0;
|
border: 1px solid #f0f0f0;
|
||||||
}
|
}
|
||||||
|
|
||||||
.button-grammar:hover {
|
.button-grammar:hover {
|
||||||
background-color: var(--primary-color);
|
background-color: var(--primary-color);
|
||||||
color: white;
|
color: white;
|
||||||
|
@ -374,19 +374,19 @@
|
||||||
border-radius: 10px;
|
border-radius: 10px;
|
||||||
border: 1px solid #f0f0f0;
|
border: 1px solid #f0f0f0;
|
||||||
}
|
}
|
||||||
|
|
||||||
.prob-set {
|
.prob-set {
|
||||||
padding: 0.3em;
|
padding: 0.3em;
|
||||||
border-bottom: 1px solid #ccc;
|
border-bottom: 1px solid #ccc;
|
||||||
}
|
}
|
||||||
|
|
||||||
.popover-content {
|
.popover-content {
|
||||||
position: absolute;
|
position: absolute;
|
||||||
background-color: white;
|
background-color: white;
|
||||||
padding: 0.2em;
|
padding: 0.2em;
|
||||||
box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
|
box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
|
||||||
}
|
}
|
||||||
|
|
||||||
textarea {
|
textarea {
|
||||||
padding: 5px;
|
padding: 5px;
|
||||||
flex-grow: 1;
|
flex-grow: 1;
|
||||||
|
@ -396,24 +396,24 @@
|
||||||
resize: none;
|
resize: none;
|
||||||
height: 6em;
|
height: 6em;
|
||||||
}
|
}
|
||||||
|
|
||||||
input[type="text"],
|
input[type="text"],
|
||||||
input[type="range"] {
|
input[type="range"] {
|
||||||
padding: 5px;
|
padding: 5px;
|
||||||
border-radius: 8px;
|
border-radius: 8px;
|
||||||
border: 1px solid #ccc;
|
border: 1px solid #ccc;
|
||||||
}
|
}
|
||||||
|
|
||||||
input[type="text"]:focus {
|
input[type="text"]:focus {
|
||||||
outline: none;
|
outline: none;
|
||||||
border: 1px solid var(--input-focus-border-color);
|
border: 1px solid var(--input-focus-border-color);
|
||||||
box-shadow: 0 0 1px var(--input-focus-border-color);
|
box-shadow: 0 0 1px var(--input-focus-border-color);
|
||||||
}
|
}
|
||||||
|
|
||||||
input[type="text"] {
|
input[type="text"] {
|
||||||
border-radius: 8px;
|
border-radius: 8px;
|
||||||
}
|
}
|
||||||
|
|
||||||
input[type="range"] {
|
input[type="range"] {
|
||||||
-webkit-appearance: none;
|
-webkit-appearance: none;
|
||||||
width: 80%;
|
width: 80%;
|
||||||
|
@ -426,18 +426,18 @@
|
||||||
-webkit-transition: .2s;
|
-webkit-transition: .2s;
|
||||||
transition: opacity .2s;
|
transition: opacity .2s;
|
||||||
}
|
}
|
||||||
|
|
||||||
input[type="range"]:hover {
|
input[type="range"]:hover {
|
||||||
opacity: 1;
|
opacity: 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
input[type="range"]:focus,
|
input[type="range"]:focus,
|
||||||
textarea:focus {
|
textarea:focus {
|
||||||
outline: none;
|
outline: none;
|
||||||
border: 1px solid var(--primary-color);
|
border: 1px solid var(--primary-color);
|
||||||
box-shadow: 0 0 1px var(--input-focus-border-color);
|
box-shadow: 0 0 1px var(--input-focus-border-color);
|
||||||
}
|
}
|
||||||
|
|
||||||
input[type="range"]::-webkit-slider-thumb {
|
input[type="range"]::-webkit-slider-thumb {
|
||||||
-webkit-appearance: none;
|
-webkit-appearance: none;
|
||||||
appearance: none;
|
appearance: none;
|
||||||
|
@ -449,7 +449,7 @@
|
||||||
background-color: var(--background-color);
|
background-color: var(--background-color);
|
||||||
cursor: pointer;
|
cursor: pointer;
|
||||||
}
|
}
|
||||||
|
|
||||||
input[type="range"]::-moz-range-thumb {
|
input[type="range"]::-moz-range-thumb {
|
||||||
width: 3px;
|
width: 3px;
|
||||||
height: 25px;
|
height: 25px;
|
||||||
|
@ -458,23 +458,23 @@
|
||||||
background: var(--background-color);
|
background: var(--background-color);
|
||||||
cursor: pointer;
|
cursor: pointer;
|
||||||
}
|
}
|
||||||
|
|
||||||
input[type="range"]::-webkit-slider-runnable-track {
|
input[type="range"]::-webkit-slider-runnable-track {
|
||||||
background-size: var(--slider-track-size);
|
background-size: var(--slider-track-size);
|
||||||
}
|
}
|
||||||
|
|
||||||
input[type="range"]:focus {
|
input[type="range"]:focus {
|
||||||
background-size: var(--slider-track-size-focus);
|
background-size: var(--slider-track-size-focus);
|
||||||
}
|
}
|
||||||
|
|
||||||
input[type="radio"] {
|
input[type="radio"] {
|
||||||
accent-color: var(--primary-color);
|
accent-color: var(--primary-color);
|
||||||
}
|
}
|
||||||
|
|
||||||
.chat-input-container {
|
.chat-input-container {
|
||||||
position: relative;
|
position: relative;
|
||||||
}
|
}
|
||||||
|
|
||||||
.chat-input-label {
|
.chat-input-label {
|
||||||
position: absolute;
|
position: absolute;
|
||||||
top: 0;
|
top: 0;
|
||||||
|
@ -484,17 +484,17 @@
|
||||||
margin-left: 5px;
|
margin-left: 5px;
|
||||||
margin-top: 5px;
|
margin-top: 5px;
|
||||||
}
|
}
|
||||||
|
|
||||||
textarea#chat-input {
|
textarea#chat-input {
|
||||||
padding-top: 10px;
|
padding-top: 10px;
|
||||||
padding-left: 10px;
|
padding-left: 10px;
|
||||||
font-size: medium;
|
font-size: medium;
|
||||||
}
|
}
|
||||||
|
|
||||||
.input-container {
|
.input-container {
|
||||||
position: relative;
|
position: relative;
|
||||||
}
|
}
|
||||||
|
|
||||||
.input-label {
|
.input-label {
|
||||||
position: absolute;
|
position: absolute;
|
||||||
top: 0;
|
top: 0;
|
||||||
|
@ -507,7 +507,7 @@
|
||||||
font-weight: 600;
|
font-weight: 600;
|
||||||
font-size: small;
|
font-size: small;
|
||||||
}
|
}
|
||||||
|
|
||||||
.input-label-sec {
|
.input-label-sec {
|
||||||
position: absolute;
|
position: absolute;
|
||||||
top: 0;
|
top: 0;
|
||||||
|
@ -520,88 +520,88 @@
|
||||||
font-weight: 600;
|
font-weight: 600;
|
||||||
font-size: x-small;
|
font-size: x-small;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
textarea.persistent-input {
|
textarea.persistent-input {
|
||||||
padding-top: 42px;
|
padding-top: 42px;
|
||||||
padding-left: 11px;
|
padding-left: 11px;
|
||||||
font-size: medium;
|
font-size: medium;
|
||||||
}
|
}
|
||||||
|
|
||||||
textarea.persistent-input-sec {
|
textarea.persistent-input-sec {
|
||||||
padding-top: 42px;
|
padding-top: 42px;
|
||||||
padding-left: 11px;
|
padding-left: 11px;
|
||||||
font-size: small;
|
font-size: small;
|
||||||
}
|
}
|
||||||
|
|
||||||
.persistent-input-sec {
|
.persistent-input-sec {
|
||||||
height: auto;
|
height: auto;
|
||||||
min-height: 150px;
|
min-height: 150px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.json-schema-controls {
|
.json-schema-controls {
|
||||||
margin-top: 10px;
|
margin-top: 10px;
|
||||||
display: flex;
|
display: flex;
|
||||||
width: 100%;
|
width: 100%;
|
||||||
/*gap: 1em; Fügt einen Abstand zwischen den Elementen hinzu */
|
/*gap: 1em; Fügt einen Abstand zwischen den Elementen hinzu */
|
||||||
}
|
}
|
||||||
|
|
||||||
.json-schema-controls > * {
|
.json-schema-controls > * {
|
||||||
flex: 1; /* Teilt den verfügbaren Platz gleichmäßig auf */
|
flex: 1; /* Teilt den verfügbaren Platz gleichmäßig auf */
|
||||||
}
|
}
|
||||||
|
|
||||||
pre code {
|
pre code {
|
||||||
display: block;
|
display: block;
|
||||||
background-color: #222;
|
background-color: #222;
|
||||||
color: #ddd;
|
color: #ddd;
|
||||||
}
|
}
|
||||||
|
|
||||||
code {
|
code {
|
||||||
font-family: monospace;
|
font-family: monospace;
|
||||||
padding: 0.1em 0.3em;
|
padding: 0.1em 0.3em;
|
||||||
border-radius: 3px;
|
border-radius: 3px;
|
||||||
}
|
}
|
||||||
|
|
||||||
fieldset label {
|
fieldset label {
|
||||||
margin: 0.5em 0;
|
margin: 0.5em 0;
|
||||||
display: block;
|
display: block;
|
||||||
}
|
}
|
||||||
|
|
||||||
fieldset label.slim {
|
fieldset label.slim {
|
||||||
margin: 0 0.5em;
|
margin: 0 0.5em;
|
||||||
display: inline;
|
display: inline;
|
||||||
}
|
}
|
||||||
|
|
||||||
header,
|
header,
|
||||||
footer {
|
footer {
|
||||||
text-align: center;
|
text-align: center;
|
||||||
}
|
}
|
||||||
|
|
||||||
footer {
|
footer {
|
||||||
font-size: 80%;
|
font-size: 80%;
|
||||||
color: #888;
|
color: #888;
|
||||||
text-align: center;
|
text-align: center;
|
||||||
}
|
}
|
||||||
|
|
||||||
footer a {
|
footer a {
|
||||||
color: #333; /* Farbe des Links */
|
color: #333; /* Farbe des Links */
|
||||||
text-decoration: none; /* Keine Unterstreichung */
|
text-decoration: none; /* Keine Unterstreichung */
|
||||||
font-weight: bold; /* Fettgedruckt */
|
font-weight: bold; /* Fettgedruckt */
|
||||||
}
|
}
|
||||||
|
|
||||||
footer a:hover {
|
footer a:hover {
|
||||||
color: #555; /* Farbe des Links beim Hovern */
|
color: #555; /* Farbe des Links beim Hovern */
|
||||||
text-decoration: underline; /* Unterstreichung beim Hovern */
|
text-decoration: underline; /* Unterstreichung beim Hovern */
|
||||||
}
|
}
|
||||||
|
|
||||||
.mode-chat textarea[name=prompt] {
|
.mode-chat textarea[name=prompt] {
|
||||||
height: 8.5em;
|
height: 8.5em;
|
||||||
}
|
}
|
||||||
|
|
||||||
.mode-completion textarea[name=prompt] {
|
.mode-completion textarea[name=prompt] {
|
||||||
height: 30em;
|
height: 30em;
|
||||||
}
|
}
|
||||||
|
|
||||||
@keyframes loading-bg-wipe {
|
@keyframes loading-bg-wipe {
|
||||||
0% {
|
0% {
|
||||||
background-position: 0%;
|
background-position: 0%;
|
||||||
|
@ -610,13 +610,13 @@
|
||||||
background-position: 100%;
|
background-position: 100%;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
.loading {
|
.loading {
|
||||||
background-size: 50% 100%;
|
background-size: 50% 100%;
|
||||||
background-image: linear-gradient(90deg, var(--loading-color-1), var(--loading-color-2), var(--loading-color-1));
|
background-image: linear-gradient(90deg, var(--loading-color-1), var(--loading-color-2), var(--loading-color-1));
|
||||||
animation: loading-bg-wipe 2s linear infinite;
|
animation: loading-bg-wipe 2s linear infinite;
|
||||||
}
|
}
|
||||||
|
|
||||||
@media (prefers-color-scheme: dark) {
|
@media (prefers-color-scheme: dark) {
|
||||||
:root {
|
:root {
|
||||||
--primary-color: var(--dark-primary-color);
|
--primary-color: var(--dark-primary-color);
|
||||||
|
@ -639,4 +639,4 @@
|
||||||
.popover-content {
|
.popover-content {
|
||||||
background-color: black;
|
background-color: black;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -340,4 +340,4 @@ show_main_menu() {
|
||||||
|
|
||||||
|
|
||||||
# Show main menu
|
# Show main menu
|
||||||
show_main_menu
|
show_main_menu
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue