diff options
author | AUTOMATIC1111 <16777216c@gmail.com> | 2023-05-13 16:43:15 +0000 |
---|---|---|
committer | AUTOMATIC <16777216c@gmail.com> | 2023-05-13 17:22:09 +0000 |
commit | 12c78138dd56eef029ce74e371c8e646cb07f6fb (patch) | |
tree | 5c364eb703e6ded486cae3ce385c81af736dd68b | |
parent | 063848798c4d4df6d3e108f4cc00c35ca38f5ebd (diff) | |
download | stable-diffusion-webui-gfx803-12c78138dd56eef029ce74e371c8e646cb07f6fb.tar.gz stable-diffusion-webui-gfx803-12c78138dd56eef029ce74e371c8e646cb07f6fb.tar.bz2 stable-diffusion-webui-gfx803-12c78138dd56eef029ce74e371c8e646cb07f6fb.zip |
Merge pull request #10324 from catboxanon/offline
Allow web UI to be ran fully offline
-rw-r--r-- | modules/shared.py | 9 | ||||
-rw-r--r-- | style.css | 3 |
2 files changed, 10 insertions, 2 deletions
diff --git a/modules/shared.py b/modules/shared.py index 4631965b..b3508883 100644 --- a/modules/shared.py +++ b/modules/shared.py @@ -667,14 +667,19 @@ def reload_gradio_theme(theme_name=None): if not theme_name:
theme_name = opts.gradio_theme
+ default_theme_args = dict(
+ font=["Source Sans Pro", 'ui-sans-serif', 'system-ui', 'sans-serif'],
+ font_mono=['IBM Plex Mono', 'ui-monospace', 'Consolas', 'monospace'],
+ )
+
if theme_name == "Default":
- gradio_theme = gr.themes.Default()
+ gradio_theme = gr.themes.Default(**default_theme_args)
else:
try:
gradio_theme = gr.themes.ThemeClass.from_hub(theme_name)
except Exception as e:
errors.display(e, "changing gradio theme")
- gradio_theme = gr.themes.Default()
+ gradio_theme = gr.themes.Default(**default_theme_args)
@@ -1,3 +1,6 @@ +/* temporary fix to load default gradio font in frontend instead of backend */
+
+@import url('https://fonts.googleapis.com/css2?family=Source+Sans+Pro:wght@400;600&display=swap');
/* general gradio fixes */
|