Sebastiankay commited on
Commit
9ce41a9
·
verified ·
1 Parent(s): 9fa446e

Upload 14 files

Browse files
.gitattributes CHANGED
@@ -33,3 +33,4 @@ saved_model/**/* filter=lfs diff=lfs merge=lfs -text
33
  *.zip filter=lfs diff=lfs merge=lfs -text
34
  *.zst filter=lfs diff=lfs merge=lfs -text
35
  *tfevents* filter=lfs diff=lfs merge=lfs -text
 
 
33
  *.zip filter=lfs diff=lfs merge=lfs -text
34
  *.zst filter=lfs diff=lfs merge=lfs -text
35
  *tfevents* filter=lfs diff=lfs merge=lfs -text
36
+ _res/assets/webfonts/GeistMono.ttf filter=lfs diff=lfs merge=lfs -text
_res/_custom.css ADDED
@@ -0,0 +1,275 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ @import url("https://fonts.googleapis.com/css2?family=Baloo+Tamma+2:wght@400..800&display=swap");
2
+
3
+ @font-face {
4
+ font-family: "Geist Mono";
5
+ src: url("file=_res/assets/webfonts/GeistMono-Thin.woff2") format("woff2");
6
+ font-weight: 100;
7
+ font-style: normal;
8
+ }
9
+ @font-face {
10
+ font-family: "Geist Mono";
11
+ src: url("file=_res/assets/webfonts/GeistMono-Light.woff2") format("woff2");
12
+ font-weight: 300;
13
+ font-style: normal;
14
+ }
15
+ @font-face {
16
+ font-family: "Geist Mono";
17
+ src: url("file=_res/assets/webfonts/GeistMono-Regular.woff2") format("woff2");
18
+ font-weight: 400;
19
+ font-style: normal;
20
+ }
21
+ @font-face {
22
+ font-family: "Geist Mono";
23
+ src: url("file=_res/assets/webfonts/GeistMono-SemiBold.woff2") format("woff2");
24
+ font-weight: 600;
25
+ font-style: normal;
26
+ }
27
+ @font-face {
28
+ font-family: "Geist Mono";
29
+ src: url("file=_res/assets/webfonts/GeistMono-Bold.woff2") format("woff2");
30
+ font-weight: 700;
31
+ font-style: normal;
32
+ }
33
+
34
+ @font-face {
35
+ font-family: "Qartella-Light";
36
+ src: url("file=_res/assets/webfonts/Qartella-Light.woff2") format("woff2"), url("file=_res/assets/webfonts/Qartella-Light.woff") format("woff");
37
+ font-weight: normal;
38
+ font-style: light;
39
+ }
40
+
41
+ @font-face {
42
+ font-family: "Qartella-Bold";
43
+ src: url("file=_res/assets/webfonts/Qartella-Bold.woff2") format("woff2"), url("file=_res/assets/webfonts/Qartella-Bold.woff") format("woff");
44
+ font-weight: normal;
45
+ font-style: bold;
46
+ }
47
+
48
+ ::-webkit-scrollbar {
49
+ width: 0px;
50
+ }
51
+
52
+ body {
53
+ background: var(--background-fill-primary);
54
+ background: linear-gradient(180deg, var(--primary-800) 355px, var(--background-fill-primary) 355px);
55
+ }
56
+
57
+ .gradio-container-5-29-0 {
58
+ padding-top: 30px !important;
59
+ transition: opacity 0.4s linear;
60
+ position: relative;
61
+ font-family: "Geist Mono", sans-serif !important;
62
+ font-weight: 400;
63
+ }
64
+
65
+ .md-header-wrapper,
66
+ .md-header > span > div {
67
+ width: 100%;
68
+ height: 200px;
69
+ display: flex;
70
+ flex-direction: column;
71
+ justify-content: flex-end;
72
+ position: relative;
73
+ background-image: url("gradio_api/file=_res/assets/Schaafe.png");
74
+ background-position: 70% bottom;
75
+ background-repeat: no-repeat;
76
+ padding: 0 10px;
77
+
78
+ h1 {
79
+ --sc: rgb(2, 44, 32);
80
+ font-family: "Baloo Tamma 2", system-ui;
81
+ font-optical-sizing: auto;
82
+ font-weight: 600;
83
+ font-style: normal;
84
+ font-size: 3.8rem;
85
+ padding: 8px;
86
+ text-shadow: 2px 2px 2px var(--sc), -2px 2px 2px var(--sc), -2px -2px 0 var(--sc), 2px -2px 0 var(--sc);
87
+ display: flex;
88
+ flex-direction: column;
89
+ text-align: right;
90
+ margin-right: 45%;
91
+ position: absolute;
92
+ right: 0;
93
+ bottom: 0;
94
+
95
+ & span {
96
+ font-weight: 400;
97
+ font-size: 2rem;
98
+ margin-top: -20px;
99
+ text-transform: uppercase;
100
+ }
101
+ }
102
+
103
+ p {
104
+ margin-top: var(--spacing-xs);
105
+
106
+ #wink,
107
+ #heart {
108
+ display: inline;
109
+ width: 26px;
110
+ margin-bottom: 8px;
111
+ }
112
+
113
+ #wink {
114
+ animation: wink 3s ease-in-out infinite;
115
+ }
116
+
117
+ #heart {
118
+ animation: beat 2s ease-in-out infinite;
119
+ }
120
+ }
121
+ }
122
+
123
+ .row-main {
124
+ padding: 16px;
125
+ background-color: var(--neutral-900) !important;
126
+ border-right-width: 0px !important;
127
+ border-bottom-width: 0px !important;
128
+ border-left-width: 0px !important;
129
+ border-top: 8px solid var(--primary-600) !important;
130
+ border-radius: var(--container-radius) !important;
131
+ }
132
+
133
+ .primary.svelte-1ixn6qd,
134
+ span.svelte-g2oxp3,
135
+ .wrap.svelte-12ioyct,
136
+ label.svelte-1to105q.svelte-1to105q,
137
+ label.selected.svelte-1bx8sav.svelte-1bx8sav.svelte-1bx8sav,
138
+ label.svelte-1bx8sav.svelte-1bx8sav.svelte-1bx8sav:hover,
139
+ .md-header > span > div p {
140
+ color: var(--text-color-by-luminance, #fff);
141
+ transition: color 0.4s ease-in-out;
142
+ }
143
+
144
+ label.svelte-1bx8sav > .svelte-1bx8sav + .svelte-1bx8sav {
145
+ margin-left: 0;
146
+ }
147
+
148
+ .app.svelte-1y320eu.svelte-1y320eu {
149
+ position: relative;
150
+ margin: auto;
151
+ padding: var(--size-4) var(--size-8);
152
+ width: 100%;
153
+ height: 100%;
154
+ }
155
+
156
+ @media (min-width: 640px) {
157
+ .fillable.svelte-1y320eu.svelte-1y320eu:not(.fill_width) {
158
+ max-width: 640px;
159
+ }
160
+ }
161
+
162
+ @media (min-width: 768px) {
163
+ .fillable.svelte-1y320eu.svelte-1y320eu:not(.fill_width) {
164
+ max-width: 768px;
165
+ }
166
+ }
167
+
168
+ @media (min-width: 1024px) {
169
+ .fillable.svelte-1y320eu.svelte-1y320eu:not(.fill_width) {
170
+ max-width: 1024px;
171
+ }
172
+ }
173
+
174
+ @media (min-width: 1280px) {
175
+ .fillable.svelte-1y320eu.svelte-1y320eu:not(.fill_width) {
176
+ max-width: 1280px;
177
+ }
178
+ }
179
+
180
+ @media (min-width: 1536px) {
181
+ .fillable.svelte-1y320eu.svelte-1y320eu:not(.fill_width) {
182
+ max-width: 1536px;
183
+ }
184
+ }
185
+
186
+ @media (min-width: 1920px) {
187
+ .fillable.svelte-1y320eu.svelte-1y320eu:not(.fill_width) {
188
+ max-width: 1536px !important;
189
+ }
190
+ }
191
+
192
+ .info.svelte-1y320eu.svelte-1y320eu {
193
+ display: flex;
194
+ position: absolute;
195
+ bottom: 0;
196
+ justify-content: flex-start;
197
+ border-top: 1px solid var(--button-secondary-border-color);
198
+ padding: var(--size-1) var(--size-5);
199
+ width: 100%;
200
+ color: var(--body-text-color-subdued);
201
+ font-size: var(--text-md);
202
+ white-space: nowrap;
203
+ }
204
+
205
+ .app.svelte-1y320eu.svelte-1y320eu {
206
+ max-width: 1536px !important;
207
+ position: relative;
208
+ margin: auto;
209
+ padding: var(--size-4) var(--size-8);
210
+ width: 100%;
211
+ height: 100%;
212
+ }
213
+
214
+ .input-image,
215
+ .output-slider {
216
+ height: 800px;
217
+ }
218
+
219
+ .hidethis,
220
+ input.svelte-1bx8sav.svelte-1bx8sav.svelte-1bx8sav {
221
+ display: none;
222
+ }
223
+
224
+ /* Keyframes */
225
+
226
+ @keyframes wink {
227
+ 0%,
228
+ 60%,
229
+ 100% {
230
+ transform: rotate(0deg);
231
+ }
232
+ 10%,
233
+ 30%,
234
+ 70%,
235
+ 90% {
236
+ transform: rotate(14deg);
237
+ }
238
+ 20%,
239
+ 80% {
240
+ transform: rotate(-8deg);
241
+ }
242
+ 40% {
243
+ transform: rotate(-4deg);
244
+ }
245
+ 50% {
246
+ transform: rotate(10deg);
247
+ }
248
+ }
249
+
250
+ @keyframes beat {
251
+ 0% {
252
+ transform: scale(1);
253
+ }
254
+ 5% {
255
+ transform: scale(0.75);
256
+ }
257
+ 20% {
258
+ transform: scale(1);
259
+ }
260
+ 30% {
261
+ transform: scale(1);
262
+ }
263
+ 35% {
264
+ transform: scale(0.75);
265
+ }
266
+ 50% {
267
+ transform: scale(1);
268
+ }
269
+ 55% {
270
+ transform: scale(0.75);
271
+ }
272
+ 70% {
273
+ transform: scale(1);
274
+ }
275
+ }
_res/_custom.js ADDED
@@ -0,0 +1,98 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ function gradioCustomJS() {
2
+ console.log("gradioCustomJS Started");
3
+
4
+ // MARK: berechne Helligkeit der Akzentfarbe
5
+ function berechneHelligkeit(rgb) {
6
+ const match = rgb.match(/^rgb\((\d+),\s*(\d+),\s*(\d+)\)$/);
7
+ if (!match) {
8
+ throw new Error("Ungültiges Farbformat");
9
+ }
10
+
11
+ const r = parseInt(match[1]) / 255;
12
+ const g = parseInt(match[2]) / 255;
13
+ const b = parseInt(match[3]) / 255;
14
+
15
+ const rLin = r <= 0.03928 ? r / 12.92 : Math.pow((r + 0.055) / 1.055, 2.4);
16
+ const gLin = g <= 0.03928 ? g / 12.92 : Math.pow((g + 0.055) / 1.055, 2.4);
17
+ const bLin = b <= 0.03928 ? b / 12.92 : Math.pow((b + 0.055) / 1.055, 2.4);
18
+
19
+ const luminanz = 0.2126 * rLin + 0.7152 * gLin + 0.0722 * bLin;
20
+
21
+ return luminanz;
22
+ }
23
+
24
+ // MARK: Textfarbe bestimmen
25
+ function anpasseTextfarbe(farbe) {
26
+ const luminanz = berechneHelligkeit(farbe);
27
+ const textFarbe = luminanz > 0.4 ? "var(--neutral-950)" : "var(--neutral-50)";
28
+ console.log("Luminanz: " + luminanz + " Text-Farbe: " + textFarbe);
29
+
30
+ return textFarbe;
31
+ }
32
+
33
+ // MARK: Body Styles
34
+ const body = document.querySelector("body");
35
+ body.className = "dark";
36
+
37
+ // Catppuccin colors
38
+ const rosewater = "245, 224, 220";
39
+ const flamingo = "242, 205, 205";
40
+ const pink = "245, 194, 231";
41
+ const mauve = "203, 166, 247";
42
+ const red = "243, 139, 168";
43
+ const maroon = "235, 160, 172";
44
+ const peach = "250, 179, 135";
45
+ const yellow = "249, 226, 175";
46
+ const green = "166, 227, 161";
47
+ const teal = "148, 226, 213";
48
+ const sky = "137, 220, 235";
49
+ const sapphire = "116, 199, 236";
50
+ const blue = "137, 180, 250";
51
+
52
+ let colors = [rosewater, flamingo, pink, mauve, red, maroon, peach, yellow, green, teal, sky, sapphire, blue];
53
+ //let usedColor = `rgb(${colors[Math.floor(Math.random() * colors.length)]})`
54
+ let usedColor = `rgb(${sky})`;
55
+ const textColorByLuminance = anpasseTextfarbe(usedColor);
56
+
57
+ body.style.setProperty("--cat-rosewater", "rgb(" + rosewater + ")");
58
+ body.style.setProperty("--cat-flamingo", "rgb(" + flamingo + ")");
59
+ body.style.setProperty("--cat-pink", "rgb(" + pink + ")");
60
+ body.style.setProperty("--cat-mauve", "rgb(" + mauve + ")");
61
+ body.style.setProperty("--cat-red", "rgb(" + red + ")");
62
+ body.style.setProperty("--cat-maroon", "rgb(" + maroon + ")");
63
+ body.style.setProperty("--cat-peach", "rgb(" + peach + ")");
64
+ body.style.setProperty("--cat-yellow", "rgb(" + yellow + ")");
65
+ body.style.setProperty("--cat-green", "rgb(" + green + ")");
66
+ body.style.setProperty("--cat-teal", "rgb(" + teal + ")");
67
+ body.style.setProperty("--cat-sky", "rgb(" + sky + ")");
68
+ body.style.setProperty("--cat-sapphire", "rgb(" + sapphire + ")");
69
+ body.style.setProperty("--cat-blue", "rgb(" + blue + ")");
70
+
71
+ body.style.setProperty("--primary-600", usedColor);
72
+ body.style.setProperty("--primary-50", "color-mix(in srgb, var(--primary-600) 5%, white)");
73
+ body.style.setProperty("--primary-100", "color-mix(in srgb, var(--primary-600) 10%, white)");
74
+ body.style.setProperty("--primary-200", "color-mix(in srgb, var(--primary-600) 20%, white)");
75
+ body.style.setProperty("--primary-300", "color-mix(in srgb, var(--primary-600) 60%, white)");
76
+ body.style.setProperty("--primary-400", "color-mix(in srgb, var(--primary-600) 70%, white)");
77
+ body.style.setProperty("--primary-500", "color-mix(in srgb, var(--primary-600) 80%, white)");
78
+ body.style.setProperty("--primary-700", "color-mix(in srgb, var(--primary-600) 80%, black)");
79
+ body.style.setProperty("--primary-800", "color-mix(in srgb, var(--primary-600) 65%, black)");
80
+ body.style.setProperty("--primary-900", "color-mix(in srgb, var(--primary-600) 40%, black)");
81
+ body.style.setProperty("--primary-950", "color-mix(in srgb, var(--primary-600) 30%, black)");
82
+
83
+ body.style.setProperty("--button-primary-background-fill", "var(--primary-600)");
84
+ body.style.setProperty("--button-primary-background-fill-hover", "var(--primary-500)");
85
+ body.style.setProperty("--blur-value", "0px");
86
+
87
+ body.style.setProperty("--text-color-by-luminance", textColorByLuminance);
88
+ body.style.setProperty("--block-label-text-color", textColorByLuminance);
89
+ body.style.setProperty("--block-title-text-color", textColorByLuminance);
90
+ body.style.setProperty("--button-primary-text-color", textColorByLuminance);
91
+ body.style.setProperty("--checkbox-label-text-color-selected", textColorByLuminance);
92
+
93
+ // MARK: SVG Animationen & Emojis
94
+ // document.querySelector(".row-header i#wink").innerHTML = ''
95
+ // document.querySelector(".row-header i.heart-beat-emoji").innerHTML = ''
96
+
97
+ return "Animation created";
98
+ }
_res/assets/webfonts/GeistMono-Bold.woff2 ADDED
Binary file (44.2 kB). View file
 
_res/assets/webfonts/GeistMono-Light.woff2 ADDED
Binary file (43.5 kB). View file
 
_res/assets/webfonts/GeistMono-Regular.woff2 ADDED
Binary file (43.3 kB). View file
 
_res/assets/webfonts/GeistMono-SemiBold.woff2 ADDED
Binary file (44.1 kB). View file
 
_res/assets/webfonts/GeistMono-Thin.woff2 ADDED
Binary file (42.8 kB). View file
 
_res/assets/webfonts/GeistMono.ttf ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:2386ddac2c72b6e0c126561e91486b7284412f303d8d9513da9ffec789e63338
3
+ size 138896
_res/assets/webfonts/Qartella-Bold.woff ADDED
Binary file (12.3 kB). View file
 
_res/assets/webfonts/Qartella-Bold.woff2 ADDED
Binary file (9.66 kB). View file
 
_res/assets/webfonts/Qartella-Light.woff ADDED
Binary file (11.1 kB). View file
 
_res/assets/webfonts/Qartella-Light.woff2 ADDED
Binary file (8.48 kB). View file
 
_res/heart.png ADDED
_res/wink.png ADDED