From: Xuan Son Nguyen Date: Fri, 15 Nov 2024 09:48:49 +0000 (-0400) Subject: server : (web UI) add copy button for code block, fix api key (#10242) X-Git-Tag: upstream/0.0.4488~402 X-Git-Url: https://git.djapps.eu/?a=commitdiff_plain;h=9901068ac78838745e604fffb4601d315a610456;p=pkg%2Fggml%2Fsources%2Fllama.cpp server : (web UI) add copy button for code block, fix api key (#10242) * server : (web ui) add copy btn for code blocks * fix problem with api key * use settings-modal-short-input component * always show copy btn for code snippet --- diff --git a/examples/server/public/index.html b/examples/server/public/index.html index 55639a94..65a915d5 100644 --- a/examples/server/public/index.html +++ b/examples/server/public/index.html @@ -12,7 +12,7 @@ .markdown { h1, h2, h3, h4, h5, h6, ul, ol, li { all: revert; } pre { - @apply whitespace-pre-wrap my-4 rounded-lg p-2; + @apply whitespace-pre-wrap rounded-lg p-2; border: 1px solid currentColor; } /* TODO: fix markdown table */ @@ -25,8 +25,11 @@ .bg-base-200 {background-color: var(--fallback-b2,oklch(var(--b2)/1))} .bg-base-300 {background-color: var(--fallback-b3,oklch(var(--b3)/1))} .text-base-content {color: var(--fallback-bc,oklch(var(--bc)/1))} + .show-on-hover { + @apply opacity-0 group-hover:opacity-100; + } .btn-mini { - @apply cursor-pointer opacity-0 group-hover:opacity-100 hover:shadow-md; + @apply cursor-pointer hover:shadow-md; } .chat-screen { max-width: 900px; } /* because the default bubble color is quite dark, we will make a custom one using bg-base-300 */ @@ -152,14 +155,14 @@
- - -
@@ -196,12 +199,13 @@

Settings

Settings below are saved in browser's localStorage

+ @@ -209,7 +213,7 @@ Other sampler settings
@@ -218,7 +222,7 @@ Penalties settings
@@ -245,7 +249,7 @@
-