From 657129e4a7d95b1f23b25085e12fb3cd92f30081 Mon Sep 17 00:00:00 2001 From: cmdr2 Date: Fri, 23 Sep 2022 22:01:38 +0530 Subject: [PATCH] Don't cache modifiers; rearrange the modifier controls --- ui/index.html | 11 +++++------ ui/media/modifier-thumbnails.css | 1 + ui/server.py | 3 ++- 3 files changed, 8 insertions(+), 7 deletions(-) diff --git a/ui/index.html b/ui/index.html index c84dbeff..1aaa1a72 100644 --- a/ui/index.html +++ b/ui/index.html @@ -170,15 +170,14 @@

Image Modifiers (art styles, tags etc)

- + -
- - -
+   + +
diff --git a/ui/media/modifier-thumbnails.css b/ui/media/modifier-thumbnails.css index 23b3aec0..765bcb17 100644 --- a/ui/media/modifier-thumbnails.css +++ b/ui/media/modifier-thumbnails.css @@ -209,4 +209,5 @@ #modifier-card-size-slider { width: 6em; margin-bottom: 0.5em; + transform: translateY(9pt); } \ No newline at end of file diff --git a/ui/server.py b/ui/server.py index b3aa45a5..b446b2f1 100644 --- a/ui/server.py +++ b/ui/server.py @@ -206,7 +206,8 @@ def getAppConfig(): @app.get('/modifiers.json') def read_modifiers(): - return FileResponse(os.path.join(SD_UI_DIR, 'modifiers.json')) + headers = {"Cache-Control": "no-cache, no-store, must-revalidate", "Pragma": "no-cache", "Expires": "0"} + return FileResponse(os.path.join(SD_UI_DIR, 'modifiers.json'), headers=headers) @app.get('/output_dir') def read_home_dir():