From ef21397f0dcedc42bbb6909ad8facbd19a677697 Mon Sep 17 00:00:00 2001 From: "Timothy J. Baek" Date: Wed, 10 Jul 2024 14:20:02 -0700 Subject: [PATCH 1/4] chore: dockerfile --- Dockerfile | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/Dockerfile b/Dockerfile index 2bd05e6ba..ac9ca72f4 100644 --- a/Dockerfile +++ b/Dockerfile @@ -95,8 +95,8 @@ RUN chown -R $UID:$GID /app $HOME RUN if [ "$USE_OLLAMA" = "true" ]; then \ apt-get update && \ - # Install pandoc and netcat - apt-get install -y --no-install-recommends pandoc netcat-openbsd curl && \ + # Install pandoc, netcat and gcc + apt-get install -y --no-install-recommends pandoc gcc netcat-openbsd curl && \ # for RAG OCR apt-get install -y --no-install-recommends ffmpeg libsm6 libxext6 && \ # install helper tools @@ -107,8 +107,8 @@ RUN if [ "$USE_OLLAMA" = "true" ]; then \ rm -rf /var/lib/apt/lists/*; \ else \ apt-get update && \ - # Install pandoc and netcat - apt-get install -y --no-install-recommends pandoc netcat-openbsd curl jq && \ + # Install pandoc, netcat and gcc + apt-get install -y --no-install-recommends pandoc gcc netcat-openbsd curl jq && \ # for RAG OCR apt-get install -y --no-install-recommends ffmpeg libsm6 libxext6 && \ # cleanup From fae7db89e66f6a6657137e5063a2dcc8566be785 Mon Sep 17 00:00:00 2001 From: "Timothy J. Baek" Date: Wed, 10 Jul 2024 14:29:39 -0700 Subject: [PATCH 2/4] chore: dockerfile --- Dockerfile | 6 ++++-- backend/requirements.txt | 2 +- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/Dockerfile b/Dockerfile index ac9ca72f4..a217595ea 100644 --- a/Dockerfile +++ b/Dockerfile @@ -95,8 +95,9 @@ RUN chown -R $UID:$GID /app $HOME RUN if [ "$USE_OLLAMA" = "true" ]; then \ apt-get update && \ - # Install pandoc, netcat and gcc - apt-get install -y --no-install-recommends pandoc gcc netcat-openbsd curl && \ + # Install pandoc and netcat + apt-get install -y --no-install-recommends pandoc netcat-openbsd curl && \ + apt-get install -y --no-install-recommends gcc python3-dev && \ # for RAG OCR apt-get install -y --no-install-recommends ffmpeg libsm6 libxext6 && \ # install helper tools @@ -109,6 +110,7 @@ RUN if [ "$USE_OLLAMA" = "true" ]; then \ apt-get update && \ # Install pandoc, netcat and gcc apt-get install -y --no-install-recommends pandoc gcc netcat-openbsd curl jq && \ + apt-get install -y --no-install-recommends gcc python3-dev && \ # for RAG OCR apt-get install -y --no-install-recommends ffmpeg libsm6 libxext6 && \ # cleanup diff --git a/backend/requirements.txt b/backend/requirements.txt index 9cef39ac2..b2bc0e0ac 100644 --- a/backend/requirements.txt +++ b/backend/requirements.txt @@ -51,7 +51,7 @@ openpyxl==3.1.5 pyxlsb==1.0.10 xlrd==2.0.1 validators==0.28.1 -psutil==5.9.7 +psutil opencv-python-headless==4.10.0.84 rapidocr-onnxruntime==1.3.22 From 37ff651723925217c9babcf8adff892e47f90e56 Mon Sep 17 00:00:00 2001 From: "Timothy J. Baek" Date: Wed, 10 Jul 2024 14:43:00 -0700 Subject: [PATCH 3/4] refac --- src/app.html | 191 +++++++++++++++++++++++---------------------------- 1 file changed, 85 insertions(+), 106 deletions(-) diff --git a/src/app.html b/src/app.html index 6f637bf61..2f07e12d0 100644 --- a/src/app.html +++ b/src/app.html @@ -1,149 +1,126 @@ - - - - - - - - + + + + + + + - - window.matchMedia('(prefers-color-scheme: dark)').addListener((e) => { - if (localStorage.theme === 'system') { - if (e.matches) { - document.documentElement.classList.add('dark'); - document.documentElement.classList.remove('light'); - } else { - document.documentElement.classList.add('light'); - document.documentElement.classList.remove('dark'); - } - } + + } else if (localStorage.theme && localStorage.theme === 'system') { + systemTheme = window.matchMedia('(prefers-color-scheme: dark)').matches; + document.documentElement.classList.add(systemTheme ? 'dark' : 'light'); + } else if (localStorage.theme && localStorage.theme === 'her') { + document.documentElement.classList.add('dark'); + document.documentElement.classList.add('her'); + } else { + document.documentElement.classList.add('dark'); + } - Open WebUI - - %sveltekit.head% - - -
%sveltekit.body%
- -
- + }); + })(); + - +
%sveltekit.body%
+ +
+ + + + transform: translateX(-50%); + " src="/static/splash.png" /> -
- + "> + -
-
+
+ ">
-
-
+ " class="bg-white">
+
- - - + + + + \ No newline at end of file From 38cc0da9905437fb7c1b3fa4dc60f65f7836be59 Mon Sep 17 00:00:00 2001 From: "Timothy J. Baek" Date: Wed, 10 Jul 2024 14:43:59 -0700 Subject: [PATCH 4/4] chore; format --- src/app.html | 182 +++++++++++++++++++++++++++++---------------------- 1 file changed, 103 insertions(+), 79 deletions(-) diff --git a/src/app.html b/src/app.html index 2f07e12d0..5d48e1d7e 100644 --- a/src/app.html +++ b/src/app.html @@ -1,87 +1,99 @@ + + + + + + + - - - - - - - - - - - - window.matchMedia('(prefers-color-scheme: dark)').addListener((e) => { - if (localStorage.theme === 'system') { - if (e.matches) { - document.documentElement.classList.add('dark'); - document.documentElement.classList.remove('light'); - } else { - document.documentElement.classList.add('light'); - document.documentElement.classList.remove('dark'); - } + - Open WebUI + window.matchMedia('(prefers-color-scheme: dark)').addListener((e) => { + if (localStorage.theme === 'system') { + if (e.matches) { + document.documentElement.classList.add('dark'); + document.documentElement.classList.remove('light'); + } else { + document.documentElement.classList.add('light'); + document.documentElement.classList.remove('dark'); + } + } + }); + })(); + - %sveltekit.head% - + Open WebUI - -
%sveltekit.body%
+ %sveltekit.head% + -
- + +
%sveltekit.body%
- + + + + " + src="/static/splash.png" + /> -
- + " + > + -
-
+
+ " + >
-
+ " + class="bg-white" + >
+
- - - - - + + \ No newline at end of file +