@directus/themes 0.1.0 → 0.3.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/components/index.d.ts +1 -0
- package/dist/components/theme-provider.vue.d.ts +971 -0
- package/dist/composables/index.d.ts +2 -0
- package/dist/composables/use-fonts.d.ts +5 -0
- package/dist/composables/use-theme.d.ts +455 -0
- package/dist/index.d.ts +5 -4
- package/dist/index.js +783 -203
- package/dist/schemas/index.d.ts +1 -0
- package/dist/schemas/theme.d.ts +247 -0
- package/dist/stores/index.d.ts +1 -0
- package/dist/stores/theme.d.ts +1412 -0
- package/dist/themes/dark/default.d.ts +223 -0
- package/dist/themes/dark/index.d.ts +1 -0
- package/dist/themes/index.d.ts +3 -0
- package/dist/themes/light/color-match.d.ts +97 -0
- package/dist/themes/light/default.d.ts +230 -0
- package/dist/themes/light/index.d.ts +3 -0
- package/dist/themes/light/minimal.d.ts +113 -0
- package/dist/utils/define-theme.d.ts +233 -0
- package/dist/utils/index.d.ts +2 -0
- package/dist/utils/rules-to-css-vars.d.ts +3 -0
- package/package.json +7 -7
- package/dist/schema.d.ts +0 -123
- package/dist/schema.json +0 -464
- package/dist/store.d.ts +0 -686
- package/dist/theme-provider.vue.d.ts +0 -487
- package/dist/themes/dark-directus.d.ts +0 -2
- package/dist/themes/light-directus.d.ts +0 -2
- package/dist/use-fonts.d.ts +0 -6
- package/dist/use-theme.d.ts +0 -117
package/dist/index.js
CHANGED
|
@@ -1,132 +1,321 @@
|
|
|
1
|
+
import { computed as v, unref as i, reactive as B, defineComponent as $, toRefs as D, openBlock as T, createBlock as L, Teleport as G, createTextVNode as N, toDisplayString as M } from "vue";
|
|
2
|
+
import { useHead as E } from "@unhead/vue";
|
|
3
|
+
import { get as W, merge as S, mapKeys as U } from "lodash-es";
|
|
4
|
+
import { defineStore as _, storeToRefs as I } from "pinia";
|
|
5
|
+
import P from "decamelize";
|
|
6
|
+
import { flatten as V } from "flat";
|
|
7
|
+
import { cssVar as z } from "@directus/utils/browser";
|
|
1
8
|
import { Type as r } from "@sinclair/typebox";
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
dangerBackground: e,
|
|
34
|
-
dangerSubdued: e,
|
|
35
|
-
dangerAccent: e,
|
|
36
|
-
fontFamilyDisplay: c,
|
|
37
|
-
fontFamilySansSerif: c,
|
|
38
|
-
fontFamilySerif: c,
|
|
39
|
-
fontFamilyMonospace: c,
|
|
40
|
-
navigation: r.Object({
|
|
41
|
-
background: e,
|
|
42
|
-
project: r.Object({
|
|
43
|
-
background: e,
|
|
44
|
-
foreground: e,
|
|
45
|
-
fontFamily: c
|
|
46
|
-
}),
|
|
47
|
-
modules: r.Object({
|
|
48
|
-
background: e,
|
|
49
|
-
button: r.Object({
|
|
50
|
-
foreground: e,
|
|
51
|
-
foregroundHover: e,
|
|
52
|
-
foregroundActive: e,
|
|
53
|
-
background: e,
|
|
54
|
-
backgroundHover: e,
|
|
55
|
-
backgroundActive: e
|
|
9
|
+
const e = r.String({ $id: "Color" }), u = r.String({ $id: "FamilyName" }), F = r.String({ $id: "FontWeight" }), k = r.String({ $id: "Length" }), O = r.String({ $id: "Percentage" }), y = r.String({ $id: "BoxShadow" }), j = r.String({ $id: "Number" }), H = r.String({ $id: "Size" }), b = r.Union([r.String(), r.Literal("thin"), r.Literal("medium"), r.Literal("thick")], {
|
|
10
|
+
$id: "LineWidth"
|
|
11
|
+
}), w = r.Optional(
|
|
12
|
+
r.Object({
|
|
13
|
+
columnGap: r.Optional(r.Union([r.Ref(k), r.Ref(O)])),
|
|
14
|
+
rowGap: r.Optional(r.Union([r.Ref(k), r.Ref(O)])),
|
|
15
|
+
field: r.Optional(
|
|
16
|
+
r.Object({
|
|
17
|
+
label: r.Optional(
|
|
18
|
+
r.Object({
|
|
19
|
+
foreground: r.Optional(r.Ref(e)),
|
|
20
|
+
fontFamily: r.Optional(r.Ref(u)),
|
|
21
|
+
fontWeight: r.Optional(r.Ref(F))
|
|
22
|
+
})
|
|
23
|
+
),
|
|
24
|
+
input: r.Optional(
|
|
25
|
+
r.Object({
|
|
26
|
+
background: r.Optional(r.Ref(e)),
|
|
27
|
+
backgroundSubdued: r.Optional(r.Ref(e)),
|
|
28
|
+
foreground: r.Optional(r.Ref(e)),
|
|
29
|
+
foregroundSubdued: r.Optional(r.Ref(e)),
|
|
30
|
+
borderColor: r.Optional(r.Ref(e)),
|
|
31
|
+
borderColorHover: r.Optional(r.Ref(e)),
|
|
32
|
+
borderColorFocus: r.Optional(r.Ref(e)),
|
|
33
|
+
boxShadow: r.Optional(r.Ref(y)),
|
|
34
|
+
boxShadowHover: r.Optional(r.Ref(y)),
|
|
35
|
+
boxShadowFocus: r.Optional(r.Ref(y)),
|
|
36
|
+
height: r.Optional(r.Ref(H)),
|
|
37
|
+
padding: r.Optional(r.Union([r.Ref(k), r.Ref(O)]))
|
|
38
|
+
})
|
|
39
|
+
)
|
|
56
40
|
})
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
41
|
+
)
|
|
42
|
+
})
|
|
43
|
+
), K = r.Object({
|
|
44
|
+
//////////////////////////////////////////////////////////////////////////////////////////////////////////
|
|
45
|
+
// Base border styles
|
|
46
|
+
borderRadius: r.Optional(r.Union([r.Ref(k), r.Ref(O)])),
|
|
47
|
+
borderWidth: r.Optional(r.Ref(b)),
|
|
48
|
+
//////////////////////////////////////////////////////////////////////////////////////////////////////////
|
|
49
|
+
// Base color palette
|
|
50
|
+
foreground: r.Optional(r.Ref(e)),
|
|
51
|
+
foregroundSubdued: r.Optional(r.Ref(e)),
|
|
52
|
+
foregroundAccent: r.Optional(r.Ref(e)),
|
|
53
|
+
background: r.Optional(r.Ref(e)),
|
|
54
|
+
backgroundNormal: r.Optional(r.Ref(e)),
|
|
55
|
+
backgroundAccent: r.Optional(r.Ref(e)),
|
|
56
|
+
backgroundSubdued: r.Optional(r.Ref(e)),
|
|
57
|
+
borderColor: r.Optional(r.Ref(e)),
|
|
58
|
+
borderColorAccent: r.Optional(r.Ref(e)),
|
|
59
|
+
borderColorSubdued: r.Optional(r.Ref(e)),
|
|
60
|
+
primary: r.Optional(r.Ref(e)),
|
|
61
|
+
primaryBackground: r.Optional(r.Ref(e)),
|
|
62
|
+
primarySubdued: r.Optional(r.Ref(e)),
|
|
63
|
+
primaryAccent: r.Optional(r.Ref(e)),
|
|
64
|
+
secondary: r.Optional(r.Ref(e)),
|
|
65
|
+
secondaryBackground: r.Optional(r.Ref(e)),
|
|
66
|
+
secondarySubdued: r.Optional(r.Ref(e)),
|
|
67
|
+
secondaryAccent: r.Optional(r.Ref(e)),
|
|
68
|
+
success: r.Optional(r.Ref(e)),
|
|
69
|
+
successBackground: r.Optional(r.Ref(e)),
|
|
70
|
+
successSubdued: r.Optional(r.Ref(e)),
|
|
71
|
+
successAccent: r.Optional(r.Ref(e)),
|
|
72
|
+
warning: r.Optional(r.Ref(e)),
|
|
73
|
+
warningBackground: r.Optional(r.Ref(e)),
|
|
74
|
+
warningSubdued: r.Optional(r.Ref(e)),
|
|
75
|
+
warningAccent: r.Optional(r.Ref(e)),
|
|
76
|
+
danger: r.Optional(r.Ref(e)),
|
|
77
|
+
dangerBackground: r.Optional(r.Ref(e)),
|
|
78
|
+
dangerSubdued: r.Optional(r.Ref(e)),
|
|
79
|
+
dangerAccent: r.Optional(r.Ref(e)),
|
|
80
|
+
//////////////////////////////////////////////////////////////////////////////////////////////////////////
|
|
81
|
+
// Base fonts
|
|
82
|
+
fonts: r.Optional(
|
|
83
|
+
r.Object({
|
|
84
|
+
display: r.Optional(
|
|
85
|
+
r.Object({
|
|
86
|
+
fontFamily: r.Optional(r.Ref(u)),
|
|
87
|
+
fontWeight: r.Optional(r.Ref(F))
|
|
88
|
+
})
|
|
89
|
+
),
|
|
90
|
+
sans: r.Optional(
|
|
91
|
+
r.Object({
|
|
92
|
+
fontFamily: r.Optional(r.Ref(u)),
|
|
93
|
+
fontWeight: r.Optional(r.Ref(F))
|
|
94
|
+
})
|
|
95
|
+
),
|
|
96
|
+
serif: r.Optional(
|
|
97
|
+
r.Object({
|
|
98
|
+
fontFamily: r.Optional(r.Ref(u)),
|
|
99
|
+
fontWeight: r.Optional(r.Ref(F))
|
|
100
|
+
})
|
|
101
|
+
),
|
|
102
|
+
monospace: r.Optional(
|
|
103
|
+
r.Object({
|
|
104
|
+
fontFamily: r.Optional(r.Ref(u)),
|
|
105
|
+
fontWeight: r.Optional(r.Ref(F))
|
|
106
|
+
})
|
|
107
|
+
)
|
|
71
108
|
})
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
109
|
+
),
|
|
110
|
+
//////////////////////////////////////////////////////////////////////////////////////////////////////////
|
|
111
|
+
// Scopes
|
|
112
|
+
navigation: r.Optional(
|
|
113
|
+
r.Object({
|
|
114
|
+
background: r.Optional(r.Ref(e)),
|
|
115
|
+
backgroundAccent: r.Optional(r.Ref(e)),
|
|
116
|
+
borderWidth: r.Optional(r.Ref(b)),
|
|
117
|
+
borderColor: r.Optional(r.Ref(e)),
|
|
118
|
+
project: r.Optional(
|
|
119
|
+
r.Object({
|
|
120
|
+
background: r.Optional(r.Ref(e)),
|
|
121
|
+
foreground: r.Optional(r.Ref(e)),
|
|
122
|
+
fontFamily: r.Optional(r.Ref(u)),
|
|
123
|
+
borderWidth: r.Optional(r.Ref(b)),
|
|
124
|
+
borderColor: r.Optional(r.Ref(e))
|
|
125
|
+
})
|
|
126
|
+
),
|
|
127
|
+
modules: r.Optional(
|
|
128
|
+
r.Object({
|
|
129
|
+
background: r.Optional(r.Ref(e)),
|
|
130
|
+
borderWidth: r.Optional(r.Ref(b)),
|
|
131
|
+
borderColor: r.Optional(r.Ref(e)),
|
|
132
|
+
button: r.Optional(
|
|
133
|
+
r.Object({
|
|
134
|
+
foreground: r.Optional(r.Ref(e)),
|
|
135
|
+
foregroundHover: r.Optional(r.Ref(e)),
|
|
136
|
+
foregroundActive: r.Optional(r.Ref(e)),
|
|
137
|
+
background: r.Optional(r.Ref(e)),
|
|
138
|
+
backgroundHover: r.Optional(r.Ref(e)),
|
|
139
|
+
backgroundActive: r.Optional(r.Ref(e))
|
|
140
|
+
})
|
|
141
|
+
)
|
|
142
|
+
})
|
|
143
|
+
),
|
|
144
|
+
list: r.Optional(
|
|
145
|
+
r.Object({
|
|
146
|
+
icon: r.Optional(
|
|
147
|
+
r.Object({
|
|
148
|
+
foreground: r.Optional(r.Ref(e)),
|
|
149
|
+
foregroundHover: r.Optional(r.Ref(e)),
|
|
150
|
+
foregroundActive: r.Optional(r.Ref(e))
|
|
151
|
+
})
|
|
152
|
+
),
|
|
153
|
+
foreground: r.Optional(r.Ref(e)),
|
|
154
|
+
foregroundHover: r.Optional(r.Ref(e)),
|
|
155
|
+
foregroundActive: r.Optional(r.Ref(e)),
|
|
156
|
+
background: r.Optional(r.Ref(e)),
|
|
157
|
+
backgroundHover: r.Optional(r.Ref(e)),
|
|
158
|
+
backgroundActive: r.Optional(r.Ref(e)),
|
|
159
|
+
fontFamily: r.Optional(r.Ref(u)),
|
|
160
|
+
divider: r.Object({
|
|
161
|
+
borderColor: r.Optional(r.Ref(e)),
|
|
162
|
+
borderWidth: r.Optional(r.Ref(b))
|
|
163
|
+
})
|
|
164
|
+
})
|
|
165
|
+
)
|
|
82
166
|
})
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
167
|
+
),
|
|
168
|
+
header: r.Optional(
|
|
169
|
+
r.Object({
|
|
170
|
+
background: r.Optional(r.Ref(e)),
|
|
171
|
+
borderWidth: r.Optional(r.Ref(b)),
|
|
172
|
+
borderColor: r.Optional(r.Ref(e)),
|
|
173
|
+
boxShadow: r.Optional(r.Ref(y)),
|
|
174
|
+
headline: r.Optional(
|
|
175
|
+
r.Object({
|
|
176
|
+
foreground: r.Optional(r.Ref(e)),
|
|
177
|
+
fontFamily: r.Optional(r.Ref(u))
|
|
178
|
+
})
|
|
179
|
+
),
|
|
180
|
+
title: r.Optional(
|
|
181
|
+
r.Object({
|
|
182
|
+
foreground: r.Optional(r.Ref(e)),
|
|
183
|
+
fontFamily: r.Optional(r.Ref(u)),
|
|
184
|
+
fontWeight: r.Optional(r.Ref(F))
|
|
185
|
+
})
|
|
186
|
+
)
|
|
95
187
|
})
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
188
|
+
),
|
|
189
|
+
form: w,
|
|
190
|
+
sidebar: r.Optional(
|
|
191
|
+
r.Object({
|
|
192
|
+
background: r.Optional(r.Ref(e)),
|
|
193
|
+
foreground: r.Optional(r.Ref(e)),
|
|
194
|
+
fontFamily: r.Optional(r.Ref(u)),
|
|
195
|
+
borderWidth: r.Optional(r.Ref(b)),
|
|
196
|
+
borderColor: r.Optional(r.Ref(e)),
|
|
197
|
+
section: r.Optional(
|
|
198
|
+
r.Object({
|
|
199
|
+
toggle: r.Optional(
|
|
200
|
+
r.Object({
|
|
201
|
+
icon: r.Optional(
|
|
202
|
+
r.Object({
|
|
203
|
+
foreground: r.Optional(r.Ref(e)),
|
|
204
|
+
foregroundHover: r.Optional(r.Ref(e)),
|
|
205
|
+
foregroundActive: r.Optional(r.Ref(e))
|
|
206
|
+
})
|
|
207
|
+
),
|
|
208
|
+
foreground: r.Optional(r.Ref(e)),
|
|
209
|
+
foregroundHover: r.Optional(r.Ref(e)),
|
|
210
|
+
foregroundActive: r.Optional(r.Ref(e)),
|
|
211
|
+
background: r.Optional(r.Ref(e)),
|
|
212
|
+
backgroundHover: r.Optional(r.Ref(e)),
|
|
213
|
+
backgroundActive: r.Optional(r.Ref(e)),
|
|
214
|
+
fontFamily: r.Optional(r.Ref(u)),
|
|
215
|
+
borderWidth: r.Optional(r.Ref(b)),
|
|
216
|
+
borderColor: r.Optional(r.Ref(e))
|
|
217
|
+
})
|
|
218
|
+
),
|
|
219
|
+
form: w
|
|
220
|
+
})
|
|
221
|
+
)
|
|
116
222
|
})
|
|
117
|
-
|
|
118
|
-
|
|
223
|
+
),
|
|
224
|
+
public: r.Optional(
|
|
225
|
+
r.Object({
|
|
226
|
+
background: r.Optional(r.Ref(e)),
|
|
227
|
+
foreground: r.Optional(r.Ref(e)),
|
|
228
|
+
foregroundAccent: r.Optional(r.Ref(e)),
|
|
229
|
+
art: r.Optional(
|
|
230
|
+
r.Object({
|
|
231
|
+
background: r.Optional(r.Ref(e)),
|
|
232
|
+
primary: r.Optional(r.Ref(e)),
|
|
233
|
+
secondary: r.Optional(r.Ref(e)),
|
|
234
|
+
speed: r.Optional(r.Ref(j))
|
|
235
|
+
})
|
|
236
|
+
),
|
|
237
|
+
form: w
|
|
238
|
+
})
|
|
239
|
+
),
|
|
240
|
+
popover: r.Optional(
|
|
241
|
+
r.Object({
|
|
242
|
+
menu: r.Optional(
|
|
243
|
+
r.Object({
|
|
244
|
+
background: r.Optional(r.Ref(e)),
|
|
245
|
+
borderRadius: r.Optional(r.Optional(r.Union([r.Ref(k), r.Ref(O)]))),
|
|
246
|
+
boxShadow: r.Optional(r.Ref(y))
|
|
247
|
+
})
|
|
248
|
+
)
|
|
249
|
+
})
|
|
250
|
+
)
|
|
251
|
+
}), Q = r.Object({
|
|
119
252
|
name: r.String(),
|
|
120
253
|
appearance: r.Union([r.Literal("light"), r.Literal("dark")]),
|
|
121
|
-
rules:
|
|
122
|
-
}),
|
|
123
|
-
|
|
254
|
+
rules: K
|
|
255
|
+
}), lr = {
|
|
256
|
+
$defs: {
|
|
257
|
+
Color: e,
|
|
258
|
+
FamilyName: u,
|
|
259
|
+
Length: k,
|
|
260
|
+
Percentage: O,
|
|
261
|
+
LineWidth: b,
|
|
262
|
+
BoxShadow: y,
|
|
263
|
+
Size: H,
|
|
264
|
+
Number: j
|
|
265
|
+
}
|
|
266
|
+
}, q = (d) => {
|
|
267
|
+
const s = v(() => {
|
|
268
|
+
const o = /* @__PURE__ */ new Map(), c = (m, a = []) => {
|
|
269
|
+
for (const [t, n] of Object.entries(m))
|
|
270
|
+
typeof n == "object" && n !== null && ("type" in n && n.type === "object" && "properties" in n && c(n.properties, [...a, t]), "$ref" in n && n.$ref === "FamilyName" && (o.has(a) ? o.set(a, { family: t, weight: o.get(a).weight }) : o.set(a, { family: t, weight: null })), "$ref" in n && n.$ref === "FontWeight" && (o.has(a) ? o.set(a, { family: o.get(a).family, weight: t }) : o.set(a, { family: null, weight: t })));
|
|
271
|
+
};
|
|
272
|
+
return c(Q.properties.rules.properties), o;
|
|
273
|
+
}), f = v(() => {
|
|
274
|
+
const o = /* @__PURE__ */ new Map();
|
|
275
|
+
for (const [c, { family: m, weight: a }] of s.value.entries()) {
|
|
276
|
+
let t = null, n = null;
|
|
277
|
+
if (m && (t = W(i(d).rules, [...c, m])), a && (n = W(i(d).rules, [...c, a])), t) {
|
|
278
|
+
const h = t.split(",");
|
|
279
|
+
for (const l of h) {
|
|
280
|
+
const g = l.trim();
|
|
281
|
+
if (g.startsWith("var(--")) {
|
|
282
|
+
h.push(z(g.slice(6, -1)));
|
|
283
|
+
continue;
|
|
284
|
+
}
|
|
285
|
+
if ((g.startsWith('"') && g.endsWith('"')) === !1)
|
|
286
|
+
continue;
|
|
287
|
+
const x = g.slice(1, -1);
|
|
288
|
+
o.has(x) ? o.get(x).add(n ?? "400") : o.set(x, /* @__PURE__ */ new Set([n ?? "400"]));
|
|
289
|
+
}
|
|
290
|
+
}
|
|
291
|
+
}
|
|
292
|
+
return o;
|
|
293
|
+
});
|
|
294
|
+
return { googleFonts: v(() => {
|
|
295
|
+
const o = [];
|
|
296
|
+
for (const [c, m] of f.value.entries())
|
|
297
|
+
if (["Inter", "Merriweather", "Fira Mono"].includes(c) === !1) {
|
|
298
|
+
const t = Array.from(m).join(";");
|
|
299
|
+
o.push(`${c.replace(" ", "+")}:wght@${t}`);
|
|
300
|
+
}
|
|
301
|
+
return o;
|
|
302
|
+
}) };
|
|
303
|
+
}, R = (d) => d, A = R({
|
|
304
|
+
name: "Directus Default",
|
|
124
305
|
appearance: "dark",
|
|
125
306
|
rules: {
|
|
307
|
+
borderRadius: "6px",
|
|
308
|
+
borderWidth: "2px",
|
|
126
309
|
foreground: "#c9d1d9",
|
|
127
310
|
foregroundAccent: "#f0f6fc",
|
|
128
311
|
foregroundSubdued: "#666672",
|
|
129
312
|
background: "#0d1117",
|
|
313
|
+
backgroundNormal: "#21262e",
|
|
314
|
+
backgroundAccent: "#30363d",
|
|
315
|
+
backgroundSubdued: "#161b22",
|
|
316
|
+
borderColor: "#21262e",
|
|
317
|
+
borderColorAccent: "#30363d",
|
|
318
|
+
borderColorSubdued: "#21262d",
|
|
130
319
|
primary: "var(--project-color)",
|
|
131
320
|
primaryBackground: "color-mix(in srgb, var(--theme--background), var(--theme--primary) 10%)",
|
|
132
321
|
primarySubdued: "color-mix(in srgb, var(--theme--background), var(--theme--primary) 50%)",
|
|
@@ -147,19 +336,40 @@ const y = {
|
|
|
147
336
|
dangerBackground: "color-mix(in srgb, var(--theme--background), var(--theme--danger) 10%)",
|
|
148
337
|
dangerSubdued: "color-mix(in srgb, var(--theme--background), var(--theme--danger) 50%)",
|
|
149
338
|
dangerAccent: "color-mix(in srgb, var(--theme--danger), #16151a 25%)",
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
339
|
+
fonts: {
|
|
340
|
+
display: {
|
|
341
|
+
fontFamily: '"Inter", system-ui',
|
|
342
|
+
fontWeight: "700"
|
|
343
|
+
},
|
|
344
|
+
sans: {
|
|
345
|
+
fontFamily: '"Inter", system-ui',
|
|
346
|
+
fontWeight: "500"
|
|
347
|
+
},
|
|
348
|
+
serif: {
|
|
349
|
+
fontFamily: '"Merriweather", serif',
|
|
350
|
+
fontWeight: "500"
|
|
351
|
+
},
|
|
352
|
+
monospace: {
|
|
353
|
+
fontFamily: '"Fira Mono", monospace',
|
|
354
|
+
fontWeight: "500"
|
|
355
|
+
}
|
|
356
|
+
},
|
|
154
357
|
navigation: {
|
|
155
358
|
background: "#21262e",
|
|
359
|
+
backgroundAccent: "#30363d",
|
|
360
|
+
borderColor: "transparent",
|
|
361
|
+
borderWidth: "0px",
|
|
156
362
|
project: {
|
|
363
|
+
borderColor: "transparent",
|
|
364
|
+
borderWidth: "0px",
|
|
157
365
|
background: "#30363d",
|
|
158
366
|
foreground: "var(--theme--foreground-accent)",
|
|
159
|
-
fontFamily: "var(--theme--font-family
|
|
367
|
+
fontFamily: "var(--theme--fonts--sans--font-family)"
|
|
160
368
|
},
|
|
161
369
|
modules: {
|
|
162
370
|
background: "var(--theme--background)",
|
|
371
|
+
borderColor: "transparent",
|
|
372
|
+
borderWidth: "0px",
|
|
163
373
|
button: {
|
|
164
374
|
foreground: "var(--theme--foreground-subdued)",
|
|
165
375
|
foregroundHover: "#fff",
|
|
@@ -181,37 +391,54 @@ const y = {
|
|
|
181
391
|
background: "transparent",
|
|
182
392
|
backgroundHover: "#30363d",
|
|
183
393
|
backgroundActive: "#30363d",
|
|
184
|
-
fontFamily: "var(--theme--font-family
|
|
394
|
+
fontFamily: "var(--theme--fonts--sans--font-family)",
|
|
395
|
+
divider: {
|
|
396
|
+
borderColor: "#30363d",
|
|
397
|
+
borderWidth: "var(--theme--border-width)"
|
|
398
|
+
}
|
|
185
399
|
}
|
|
186
400
|
},
|
|
187
401
|
header: {
|
|
188
402
|
background: "var(--theme--background)",
|
|
403
|
+
borderColor: "transparent",
|
|
404
|
+
borderWidth: "0px",
|
|
405
|
+
boxShadow: "0 4px 7px -4px rgb(var(--black) / 0.2)",
|
|
189
406
|
headline: {
|
|
190
407
|
foreground: "var(--theme--foreground-subdued)",
|
|
191
|
-
fontFamily: "var(--theme--font-family
|
|
408
|
+
fontFamily: "var(--theme--fonts--sans--font-family)"
|
|
192
409
|
},
|
|
193
410
|
title: {
|
|
194
411
|
foreground: "var(--theme--foreground-accent)",
|
|
195
|
-
fontFamily: "var(--theme--font-family
|
|
412
|
+
fontFamily: "var(--theme--fonts--display--font-family)"
|
|
196
413
|
}
|
|
197
414
|
},
|
|
198
415
|
form: {
|
|
199
416
|
field: {
|
|
200
417
|
label: {
|
|
201
418
|
foreground: "var(--theme--foreground-accent)",
|
|
202
|
-
fontFamily: "var(--theme--font-family
|
|
419
|
+
fontFamily: "var(--theme--fonts--sans--font-family)"
|
|
203
420
|
},
|
|
204
421
|
input: {
|
|
205
422
|
background: "var(--theme--background)",
|
|
423
|
+
backgroundSubdued: "var(--theme--background-subdued)",
|
|
206
424
|
foreground: "var(--theme--foreground)",
|
|
207
|
-
foregroundSubdued: "var(--theme--foreground-subdued)"
|
|
425
|
+
foregroundSubdued: "var(--theme--foreground-subdued)",
|
|
426
|
+
borderColor: "#21262e",
|
|
427
|
+
borderColorHover: "#30363d",
|
|
428
|
+
borderColorFocus: "var(--theme--primary)",
|
|
429
|
+
boxShadow: "none",
|
|
430
|
+
boxShadowHover: "none",
|
|
431
|
+
boxShadowFocus: "0 0 16px -8px var(--theme--primary)",
|
|
432
|
+
height: "60px"
|
|
208
433
|
}
|
|
209
434
|
}
|
|
210
435
|
},
|
|
211
436
|
sidebar: {
|
|
212
437
|
background: "#21262e",
|
|
213
438
|
foreground: "var(--theme--foreground-subdued)",
|
|
214
|
-
fontFamily: "var(--theme--font-family
|
|
439
|
+
fontFamily: "var(--theme--fonts--sans--font-family)",
|
|
440
|
+
borderColor: "transparent",
|
|
441
|
+
borderWidth: "0px",
|
|
215
442
|
section: {
|
|
216
443
|
toggle: {
|
|
217
444
|
icon: {
|
|
@@ -225,19 +452,175 @@ const y = {
|
|
|
225
452
|
background: "#30363d",
|
|
226
453
|
backgroundHover: "var(--theme--sidebar--section--toggle--background)",
|
|
227
454
|
backgroundActive: "var(--theme--sidebar--section--toggle--background)",
|
|
228
|
-
fontFamily: "var(--theme--font-family
|
|
455
|
+
fontFamily: "var(--theme--fonts--sans--font-family)",
|
|
456
|
+
borderColor: "transparent",
|
|
457
|
+
borderWidth: "0px"
|
|
458
|
+
},
|
|
459
|
+
form: {
|
|
460
|
+
columnGap: "var(--theme--form--column-gap)",
|
|
461
|
+
rowGap: "var(--theme--form--row-gap)",
|
|
462
|
+
label: {
|
|
463
|
+
foreground: "var(--theme--form--field--label--foreground)",
|
|
464
|
+
fontFamily: "var(--theme--form--field--label--font-family)"
|
|
465
|
+
},
|
|
466
|
+
field: {
|
|
467
|
+
input: {
|
|
468
|
+
background: "var(--theme--form--field--input--background)",
|
|
469
|
+
foreground: "var(--theme--form--field--input--foreground)",
|
|
470
|
+
foregroundSubdued: "var(--theme--form--field--input--foreground-subdued)",
|
|
471
|
+
borderColor: "var(--theme--form--field--input--border-color)",
|
|
472
|
+
borderColorHover: "var(--theme--form--field--input--border-color-hover)",
|
|
473
|
+
borderColorFocus: "var(--theme--form--field--input--border-color-focus)",
|
|
474
|
+
boxShadow: "var(--theme--form--field--input--box-shadow)",
|
|
475
|
+
boxShadowHover: "var(--theme--form--field--input--box-shadow-hover)",
|
|
476
|
+
boxShadowFocus: "var(--theme--form--field--input--box-shadow-focus)",
|
|
477
|
+
height: "52px"
|
|
478
|
+
}
|
|
479
|
+
}
|
|
480
|
+
}
|
|
481
|
+
}
|
|
482
|
+
},
|
|
483
|
+
public: {
|
|
484
|
+
background: "var(--theme--background)",
|
|
485
|
+
foreground: "var(--theme--foreground)",
|
|
486
|
+
foregroundAccent: "var(--theme--foreground-accent)",
|
|
487
|
+
art: {
|
|
488
|
+
background: "#0e1c2f",
|
|
489
|
+
primary: "var(--theme--primary)",
|
|
490
|
+
secondary: "var(--theme--secondary)",
|
|
491
|
+
speed: "1"
|
|
492
|
+
},
|
|
493
|
+
form: {
|
|
494
|
+
columnGap: "var(--theme--form--column-gap)",
|
|
495
|
+
rowGap: "var(--theme--form--row-gap)",
|
|
496
|
+
field: {
|
|
497
|
+
label: {
|
|
498
|
+
foreground: "var(--theme--form--field--label--foreground)",
|
|
499
|
+
fontFamily: "var(--theme--form--field--label--font-family)"
|
|
500
|
+
},
|
|
501
|
+
input: {
|
|
502
|
+
background: "var(--theme--form--field--input--background)",
|
|
503
|
+
foreground: "var(--theme--form--field--input--foreground)",
|
|
504
|
+
foregroundSubdued: "var(--theme--form--field--input--foreground-subdued)",
|
|
505
|
+
borderColor: "var(--theme--form--field--input--border-color)",
|
|
506
|
+
borderColorHover: "var(--theme--form--field--input--border-color-hover)",
|
|
507
|
+
borderColorFocus: "var(--theme--form--field--input--border-color-focus)",
|
|
508
|
+
boxShadow: "var(--theme--form--field--input--box-shadow)",
|
|
509
|
+
boxShadowHover: "var(--theme--form--field--input--box-shadow-hover)",
|
|
510
|
+
boxShadowFocus: "var(--theme--form--field--input--box-shadow-focus)",
|
|
511
|
+
height: "var(--theme--form--field--input--height)"
|
|
512
|
+
}
|
|
513
|
+
}
|
|
514
|
+
}
|
|
515
|
+
},
|
|
516
|
+
popover: {
|
|
517
|
+
menu: {
|
|
518
|
+
background: "#161b22",
|
|
519
|
+
borderRadius: "var(--theme--border-radius)",
|
|
520
|
+
boxShadow: "0px 0px 6px 0px rgb(0, 0, 0, 0.2)"
|
|
521
|
+
}
|
|
522
|
+
}
|
|
523
|
+
}
|
|
524
|
+
}), J = R({
|
|
525
|
+
name: "Directus Color Match",
|
|
526
|
+
appearance: "light",
|
|
527
|
+
rules: {
|
|
528
|
+
background: "color-mix(in srgb, #FFFFFF, var(--theme--primary) 7%)",
|
|
529
|
+
backgroundAccent: "color-mix(in srgb, #FFFFFF, var(--theme--primary) 20%)",
|
|
530
|
+
backgroundNormal: "color-mix(in srgb, #FFFFFF, var(--theme--primary) 15%)",
|
|
531
|
+
backgroundSubdued: "color-mix(in srgb, #FFFFFF, var(--theme--primary) 10%)",
|
|
532
|
+
borderColor: "color-mix(in srgb, #FFFFFF, var(--theme--primary) 20%)",
|
|
533
|
+
borderColorAccent: "color-mix(in srgb, #FFFFFF, var(--theme--primary) 40%)",
|
|
534
|
+
borderColorSubdued: "color-mix(in srgb, #FFFFFF, var(--theme--primary) 15%)",
|
|
535
|
+
borderRadius: "12px",
|
|
536
|
+
borderWidth: "1px",
|
|
537
|
+
foreground: "color-mix(in srgb, #000000, var(--theme--primary) 70%)",
|
|
538
|
+
foregroundAccent: "color-mix(in srgb, #000000, var(--theme--primary) 50%)",
|
|
539
|
+
foregroundSubdued: "color-mix(in srgb, #FFFFFF, var(--theme--primary) 60%)",
|
|
540
|
+
fonts: {
|
|
541
|
+
display: {
|
|
542
|
+
fontFamily: '"Montserrat", system-ui',
|
|
543
|
+
fontWeight: "400"
|
|
544
|
+
}
|
|
545
|
+
},
|
|
546
|
+
form: {
|
|
547
|
+
field: {
|
|
548
|
+
input: { background: "#FFFFFF", backgroundSubdued: "color-mix(in srgb, #FFFFFF, var(--theme--primary) 13%)" }
|
|
549
|
+
}
|
|
550
|
+
},
|
|
551
|
+
navigation: {
|
|
552
|
+
background: "#FFFFFF",
|
|
553
|
+
backgroundAccent: "var(--theme--background)",
|
|
554
|
+
borderWidth: "var(--theme--border-width)",
|
|
555
|
+
borderColor: "var(--theme--border-color-subdued)",
|
|
556
|
+
modules: {
|
|
557
|
+
background: "color-mix(in srgb, #000000, var(--theme--primary) 90%)",
|
|
558
|
+
button: {
|
|
559
|
+
backgroundActive: "#FFFFFF",
|
|
560
|
+
foreground: "color-mix(in srgb, #FFFFFF, var(--theme--primary) 20%)",
|
|
561
|
+
foregroundActive: "var(--theme--primary)"
|
|
562
|
+
}
|
|
563
|
+
},
|
|
564
|
+
project: { borderWidth: "1px", background: "#FFFFFF", borderColor: "var(--theme--border-color-subdued)" },
|
|
565
|
+
list: {
|
|
566
|
+
divider: { borderColor: "var(--theme--border-color-subdued)" },
|
|
567
|
+
icon: { foreground: "var(--theme--foreground)" },
|
|
568
|
+
foreground: "var(--theme--foreground)",
|
|
569
|
+
foregroundHover: "var(--theme--foreground)",
|
|
570
|
+
foregroundActive: "var(--theme--foreground)"
|
|
571
|
+
}
|
|
572
|
+
},
|
|
573
|
+
header: {
|
|
574
|
+
background: "#FFFFFF",
|
|
575
|
+
borderWidth: "1px",
|
|
576
|
+
borderColor: "var(--theme--border-color-subdued)",
|
|
577
|
+
boxShadow: "0 4px 7px -4px rgba(0,102,102, 0.2)"
|
|
578
|
+
},
|
|
579
|
+
sidebar: {
|
|
580
|
+
background: "#FFFFFF",
|
|
581
|
+
borderWidth: "1px",
|
|
582
|
+
borderColor: "var(--theme--border-color-subdued)",
|
|
583
|
+
section: {
|
|
584
|
+
toggle: {
|
|
585
|
+
borderColor: "var(--theme--border-color-subdued)",
|
|
586
|
+
borderWidth: "1px",
|
|
587
|
+
background: "#FFFFFF",
|
|
588
|
+
foreground: "var(--theme--foreground)",
|
|
589
|
+
foregroundHover: "var(--theme--foreground)",
|
|
590
|
+
foregroundActive: "var(--theme--foreground-accent)",
|
|
591
|
+
icon: {
|
|
592
|
+
foreground: "var(--theme--foreground)",
|
|
593
|
+
foregroundHover: "var(--theme--foreground)",
|
|
594
|
+
foregroundActive: "var(--theme--foreground-accent)"
|
|
595
|
+
}
|
|
229
596
|
}
|
|
230
597
|
}
|
|
598
|
+
},
|
|
599
|
+
public: {
|
|
600
|
+
art: {
|
|
601
|
+
background: "color-mix(in srgb, #FFFFFF, var(--theme--primary) 10%)",
|
|
602
|
+
primary: "color-mix(in srgb, #FFFFFF, var(--theme--primary) 60%)",
|
|
603
|
+
secondary: "color-mix(in srgb, #FFFFFF, var(--theme--secondary) 70%)"
|
|
604
|
+
},
|
|
605
|
+
background: "#FFFFFF"
|
|
231
606
|
}
|
|
232
607
|
}
|
|
233
|
-
},
|
|
234
|
-
name: "
|
|
608
|
+
}), C = R({
|
|
609
|
+
name: "Directus Default",
|
|
235
610
|
appearance: "light",
|
|
236
611
|
rules: {
|
|
612
|
+
borderRadius: "6px",
|
|
613
|
+
borderWidth: "2px",
|
|
237
614
|
foreground: "#4f5464",
|
|
238
615
|
foregroundAccent: "#172940",
|
|
239
616
|
foregroundSubdued: "#a2b5cd",
|
|
240
617
|
background: "#fff",
|
|
618
|
+
backgroundNormal: "#f0f4f9",
|
|
619
|
+
backgroundAccent: "#e4eaf1",
|
|
620
|
+
backgroundSubdued: "#f7fafc",
|
|
621
|
+
borderColor: "#e4eaf1",
|
|
622
|
+
borderColorAccent: "#d3dae4",
|
|
623
|
+
borderColorSubdued: "#f0f4f9",
|
|
241
624
|
primary: "var(--project-color)",
|
|
242
625
|
primaryBackground: "color-mix(in srgb, var(--theme--background), var(--theme--primary) 10%)",
|
|
243
626
|
primarySubdued: "color-mix(in srgb, var(--theme--background), var(--theme--primary) 50%)",
|
|
@@ -258,26 +641,47 @@ const y = {
|
|
|
258
641
|
dangerBackground: "color-mix(in srgb, var(--theme--background), var(--theme--danger) 10%)",
|
|
259
642
|
dangerSubdued: "color-mix(in srgb, var(--theme--background), var(--theme--danger) 50%)",
|
|
260
643
|
dangerAccent: "color-mix(in srgb, var(--theme--danger), #2e3c43 25%)",
|
|
261
|
-
|
|
262
|
-
|
|
263
|
-
|
|
264
|
-
|
|
644
|
+
fonts: {
|
|
645
|
+
display: {
|
|
646
|
+
fontFamily: '"Inter", system-ui',
|
|
647
|
+
fontWeight: "700"
|
|
648
|
+
},
|
|
649
|
+
sans: {
|
|
650
|
+
fontFamily: '"Inter", system-ui',
|
|
651
|
+
fontWeight: "500"
|
|
652
|
+
},
|
|
653
|
+
serif: {
|
|
654
|
+
fontFamily: '"Merriweather", serif',
|
|
655
|
+
fontWeight: "500"
|
|
656
|
+
},
|
|
657
|
+
monospace: {
|
|
658
|
+
fontFamily: '"Fira Mono", monospace',
|
|
659
|
+
fontWeight: "500"
|
|
660
|
+
}
|
|
661
|
+
},
|
|
265
662
|
navigation: {
|
|
266
|
-
background: "
|
|
663
|
+
background: "var(--theme--background-normal)",
|
|
664
|
+
backgroundAccent: "var(--theme--background-accent)",
|
|
665
|
+
borderColor: "transparent",
|
|
666
|
+
borderWidth: "0px",
|
|
267
667
|
project: {
|
|
268
|
-
|
|
668
|
+
borderColor: "transparent",
|
|
669
|
+
borderWidth: "0px",
|
|
670
|
+
background: "var(--theme--navigation--background-accent)",
|
|
269
671
|
foreground: "var(--theme--foreground-accent)",
|
|
270
672
|
fontFamily: "var(--theme--font-family-sans-serif)"
|
|
271
673
|
},
|
|
272
674
|
modules: {
|
|
273
|
-
background: "#
|
|
675
|
+
background: "#0e1c2f",
|
|
676
|
+
borderColor: "transparent",
|
|
677
|
+
borderWidth: "0px",
|
|
274
678
|
button: {
|
|
275
679
|
foreground: "#8196b1",
|
|
276
680
|
foregroundHover: "#fff",
|
|
277
681
|
foregroundActive: "var(--theme--foreground-accent)",
|
|
278
682
|
background: "transparent",
|
|
279
683
|
backgroundHover: "transparent",
|
|
280
|
-
backgroundActive: "
|
|
684
|
+
backgroundActive: "var(--theme--background-normal)"
|
|
281
685
|
}
|
|
282
686
|
},
|
|
283
687
|
list: {
|
|
@@ -290,39 +694,61 @@ const y = {
|
|
|
290
694
|
foregroundHover: "var(--theme--navigation--list--foreground)",
|
|
291
695
|
foregroundActive: "var(--theme--navigation--list--foreground)",
|
|
292
696
|
background: "transparent",
|
|
293
|
-
backgroundHover: "
|
|
294
|
-
backgroundActive: "
|
|
295
|
-
fontFamily: "var(--theme--font-family-sans-serif)"
|
|
697
|
+
backgroundHover: "var(--theme--navigation--background-accent)",
|
|
698
|
+
backgroundActive: "var(--theme--navigation--background-accent)",
|
|
699
|
+
fontFamily: "var(--theme--font-family-sans-serif)",
|
|
700
|
+
divider: {
|
|
701
|
+
borderColor: "var(--theme--border-color-accent)",
|
|
702
|
+
borderWidth: "var(--theme--border-width)"
|
|
703
|
+
}
|
|
296
704
|
}
|
|
297
705
|
},
|
|
298
706
|
header: {
|
|
299
707
|
background: "var(--theme--background)",
|
|
708
|
+
borderColor: "transparent",
|
|
709
|
+
borderWidth: "0px",
|
|
710
|
+
boxShadow: "0 4px 7px -4px rgb(0 0 0 / 0.2)",
|
|
300
711
|
headline: {
|
|
301
712
|
foreground: "var(--theme--foreground-subdued)",
|
|
302
713
|
fontFamily: "var(--theme--font-family-sans-serif)"
|
|
303
714
|
},
|
|
304
715
|
title: {
|
|
305
716
|
foreground: "var(--theme--foreground-accent)",
|
|
306
|
-
fontFamily: "var(--theme--font-family
|
|
717
|
+
fontFamily: "var(--theme--fonts--display--font-family)",
|
|
718
|
+
fontWeight: "var(--theme--fonts--display--font-weight)"
|
|
307
719
|
}
|
|
308
720
|
},
|
|
309
721
|
form: {
|
|
722
|
+
columnGap: "32px",
|
|
723
|
+
rowGap: "40px",
|
|
310
724
|
field: {
|
|
311
725
|
label: {
|
|
312
726
|
foreground: "var(--theme--foreground-accent)",
|
|
313
|
-
fontFamily: "var(--theme--font-family-sans-serif)"
|
|
727
|
+
fontFamily: "var(--theme--font-family-sans-serif)",
|
|
728
|
+
fontWeight: "600"
|
|
314
729
|
},
|
|
315
730
|
input: {
|
|
316
731
|
background: "var(--theme--background)",
|
|
732
|
+
backgroundSubdued: "var(--theme--background-subdued)",
|
|
317
733
|
foreground: "var(--theme--foreground)",
|
|
318
|
-
foregroundSubdued: "var(--theme--foreground-subdued)"
|
|
734
|
+
foregroundSubdued: "var(--theme--foreground-subdued)",
|
|
735
|
+
borderColor: "var(--theme--border-color)",
|
|
736
|
+
borderColorHover: "var(--theme--border-color-accent)",
|
|
737
|
+
borderColorFocus: "var(--theme--primary)",
|
|
738
|
+
boxShadow: "none",
|
|
739
|
+
boxShadowHover: "none",
|
|
740
|
+
boxShadowFocus: "0 0 16px -8px var(--theme--primary)",
|
|
741
|
+
height: "60px",
|
|
742
|
+
padding: "16px"
|
|
319
743
|
}
|
|
320
744
|
}
|
|
321
745
|
},
|
|
322
746
|
sidebar: {
|
|
323
|
-
background: "
|
|
747
|
+
background: "var(--theme--background-normal)",
|
|
324
748
|
foreground: "var(--theme--foreground-subdued)",
|
|
325
749
|
fontFamily: "var(--theme--font-family-sans-serif)",
|
|
750
|
+
borderColor: "transparent",
|
|
751
|
+
borderWidth: "0px",
|
|
326
752
|
section: {
|
|
327
753
|
toggle: {
|
|
328
754
|
icon: {
|
|
@@ -333,91 +759,245 @@ const y = {
|
|
|
333
759
|
foreground: "var(--theme--foreground-accent)",
|
|
334
760
|
foregroundHover: "var(--theme--sidebar--section--toggle--foreground)",
|
|
335
761
|
foregroundActive: "var(--theme--sidebar--section--toggle--foreground)",
|
|
336
|
-
background: "
|
|
762
|
+
background: "var(--theme--background-accent)",
|
|
337
763
|
backgroundHover: "var(--theme--sidebar--section--toggle--background)",
|
|
338
764
|
backgroundActive: "var(--theme--sidebar--section--toggle--background)",
|
|
339
|
-
fontFamily: "var(--theme--font-family-sans-serif)"
|
|
765
|
+
fontFamily: "var(--theme--font-family-sans-serif)",
|
|
766
|
+
borderColor: "transparent",
|
|
767
|
+
borderWidth: "0px"
|
|
768
|
+
},
|
|
769
|
+
form: {
|
|
770
|
+
columnGap: "var(--theme--form--column-gap)",
|
|
771
|
+
rowGap: "var(--theme--form--row-gap)",
|
|
772
|
+
label: {
|
|
773
|
+
foreground: "var(--theme--form--field--label--foreground)",
|
|
774
|
+
fontFamily: "var(--theme--form--field--label--font-family)"
|
|
775
|
+
},
|
|
776
|
+
field: {
|
|
777
|
+
input: {
|
|
778
|
+
background: "var(--theme--form--field--input--background)",
|
|
779
|
+
foreground: "var(--theme--form--field--input--foreground)",
|
|
780
|
+
foregroundSubdued: "var(--theme--form--field--input--foreground-subdued)",
|
|
781
|
+
borderColor: "var(--theme--form--field--input--border-color)",
|
|
782
|
+
borderColorHover: "var(--theme--form--field--input--border-color-hover)",
|
|
783
|
+
borderColorFocus: "var(--theme--form--field--input--border-color-focus)",
|
|
784
|
+
boxShadow: "var(--theme--form--field--input--box-shadow)",
|
|
785
|
+
boxShadowHover: "var(--theme--form--field--input--box-shadow-hover)",
|
|
786
|
+
boxShadowFocus: "var(--theme--form--field--input--box-shadow-focus)",
|
|
787
|
+
height: "52px",
|
|
788
|
+
padding: "12px"
|
|
789
|
+
}
|
|
790
|
+
}
|
|
340
791
|
}
|
|
341
792
|
}
|
|
793
|
+
},
|
|
794
|
+
public: {
|
|
795
|
+
background: "var(--theme--background)",
|
|
796
|
+
foreground: "var(--theme--foreground)",
|
|
797
|
+
foregroundAccent: "var(--theme--foreground-accent)",
|
|
798
|
+
art: {
|
|
799
|
+
background: "#0e1c2f",
|
|
800
|
+
primary: "var(--theme--primary)",
|
|
801
|
+
secondary: "var(--theme--secondary)",
|
|
802
|
+
speed: "1"
|
|
803
|
+
},
|
|
804
|
+
form: {
|
|
805
|
+
columnGap: "var(--theme--form--column-gap)",
|
|
806
|
+
rowGap: "var(--theme--form--row-gap)",
|
|
807
|
+
label: {
|
|
808
|
+
foreground: "var(--theme--form--field--label--foreground)",
|
|
809
|
+
fontFamily: "var(--theme--form--field--label--font-family)"
|
|
810
|
+
},
|
|
811
|
+
field: {
|
|
812
|
+
input: {
|
|
813
|
+
background: "var(--theme--form--field--input--background)",
|
|
814
|
+
foreground: "var(--theme--form--field--input--foreground)",
|
|
815
|
+
foregroundSubdued: "var(--theme--form--field--input--foreground-subdued)",
|
|
816
|
+
borderColor: "var(--theme--form--field--input--border-color)",
|
|
817
|
+
borderColorHover: "var(--theme--form--field--input--border-color-hover)",
|
|
818
|
+
borderColorFocus: "var(--theme--form--field--input--border-color-focus)",
|
|
819
|
+
boxShadow: "var(--theme--form--field--input--box-shadow)",
|
|
820
|
+
boxShadowHover: "var(--theme--form--field--input--box-shadow-hover)",
|
|
821
|
+
boxShadowFocus: "var(--theme--form--field--input--box-shadow-focus)",
|
|
822
|
+
height: "var(--theme--form--field--input--height)",
|
|
823
|
+
padding: "var(--theme--form--field--input--padding)"
|
|
824
|
+
}
|
|
825
|
+
}
|
|
826
|
+
}
|
|
827
|
+
},
|
|
828
|
+
popover: {
|
|
829
|
+
menu: {
|
|
830
|
+
background: "#fafcfd",
|
|
831
|
+
borderRadius: "var(--theme--border-radius)",
|
|
832
|
+
boxShadow: "0px 0px 6px 0px rgb(23, 41, 64, 0.2), 0px 0px 12px 2px rgb(23, 41, 64, 0.05)"
|
|
833
|
+
}
|
|
342
834
|
}
|
|
343
835
|
}
|
|
344
|
-
},
|
|
345
|
-
|
|
346
|
-
|
|
347
|
-
|
|
348
|
-
|
|
349
|
-
|
|
350
|
-
|
|
836
|
+
}), X = R({
|
|
837
|
+
name: "Directus Minimal",
|
|
838
|
+
appearance: "light",
|
|
839
|
+
rules: {
|
|
840
|
+
borderWidth: "1px",
|
|
841
|
+
backgroundPage: "color-mix(in srgb, #FFFFFF, var(--theme--primary) 7%)",
|
|
842
|
+
navigation: {
|
|
843
|
+
background: "#FFFFFF",
|
|
844
|
+
modules: {
|
|
845
|
+
background: "#FFFFFF",
|
|
846
|
+
button: {
|
|
847
|
+
backgroundActive: "#F1F5F9",
|
|
848
|
+
foreground: "var(--theme--foreground)",
|
|
849
|
+
foregroundHover: "var(--theme--primary)",
|
|
850
|
+
foregroundActive: "var(--theme--primary)",
|
|
851
|
+
backgroundHover: "#F1F5F9",
|
|
852
|
+
background: "#FFFFFF"
|
|
853
|
+
},
|
|
854
|
+
borderWidth: "1px",
|
|
855
|
+
borderColor: "var(--theme--border-color)"
|
|
856
|
+
},
|
|
857
|
+
project: {
|
|
858
|
+
borderWidth: "1px",
|
|
859
|
+
background: "#FFFFFF",
|
|
860
|
+
borderColor: "var(--theme--border-color)"
|
|
861
|
+
},
|
|
862
|
+
list: {
|
|
863
|
+
icon: {
|
|
864
|
+
foreground: "#0F172A"
|
|
865
|
+
},
|
|
866
|
+
divider: {
|
|
867
|
+
borderColor: "var(--theme--border-color)"
|
|
868
|
+
}
|
|
869
|
+
},
|
|
870
|
+
borderWidth: "1px",
|
|
871
|
+
backgroundAccent: "#F1F5F9",
|
|
872
|
+
borderColor: "var(--theme--border-color)"
|
|
873
|
+
},
|
|
874
|
+
header: {
|
|
875
|
+
background: "#FFFFFF",
|
|
876
|
+
borderWidth: "1px",
|
|
877
|
+
borderColor: "var(--theme--border-color)",
|
|
878
|
+
boxShadow: "0 4px 7px -4px rgba(0,102,102, 0.1)"
|
|
879
|
+
},
|
|
880
|
+
backgroundAccent: "#E2E8F0",
|
|
881
|
+
backgroundSubdued: "#F8FAFC",
|
|
882
|
+
background: "#FFFFFF",
|
|
883
|
+
foreground: "#1E293B",
|
|
884
|
+
foregroundAccent: "#0F172A",
|
|
885
|
+
foregroundSubdued: "#94A3B8",
|
|
886
|
+
borderRadius: "4px",
|
|
887
|
+
borderColor: "#E2E8F0",
|
|
888
|
+
borderColorAccent: "#CBD5E1",
|
|
889
|
+
borderColorSubdued: "#F1F5F9",
|
|
890
|
+
form: {
|
|
891
|
+
rowGap: "32px",
|
|
892
|
+
field: {
|
|
893
|
+
input: {
|
|
894
|
+
background: "#FFFFFF",
|
|
895
|
+
backgroundSubdued: "#F8FAFC",
|
|
896
|
+
boxShadowFocus: "none",
|
|
897
|
+
height: "52px"
|
|
898
|
+
}
|
|
899
|
+
}
|
|
900
|
+
},
|
|
901
|
+
sidebar: {
|
|
902
|
+
background: "#FFFFFF",
|
|
903
|
+
borderWidth: "1px",
|
|
904
|
+
borderColor: "var(--theme--border-color)",
|
|
905
|
+
section: {
|
|
906
|
+
toggle: {
|
|
907
|
+
borderColor: "var(--theme--border-color)",
|
|
908
|
+
borderWidth: "1px",
|
|
909
|
+
background: "#FFFFFF",
|
|
910
|
+
foreground: "var(--theme--foreground-subdued)",
|
|
911
|
+
foregroundHover: "var(--theme--foreground)",
|
|
912
|
+
foregroundActive: "var(--theme--foreground-accent)",
|
|
913
|
+
icon: {
|
|
914
|
+
foreground: "var(--theme--foreground)",
|
|
915
|
+
foregroundHover: "var(--theme--foreground)",
|
|
916
|
+
foregroundActive: "var(--theme--foreground-accent)"
|
|
917
|
+
}
|
|
918
|
+
},
|
|
919
|
+
form: {
|
|
920
|
+
field: {
|
|
921
|
+
input: {
|
|
922
|
+
height: "42px"
|
|
923
|
+
}
|
|
924
|
+
}
|
|
925
|
+
}
|
|
926
|
+
}
|
|
927
|
+
},
|
|
928
|
+
fontFamilyDisplay: "system-ui",
|
|
929
|
+
public: {
|
|
930
|
+
art: {
|
|
931
|
+
background: "color-mix(in srgb, #FFFFFF, var(--project-color) 10%)",
|
|
932
|
+
primary: "color-mix(in srgb, #FFFFFF, var(--project-color) 70%)",
|
|
933
|
+
secondary: "color-mix(in srgb, #FFFFFF, var(--project-color) 40%)"
|
|
934
|
+
},
|
|
935
|
+
background: "#FFFFFF"
|
|
936
|
+
},
|
|
937
|
+
backgroundNormal: "#F1F5F9",
|
|
938
|
+
secondary: "#64748B",
|
|
939
|
+
primary: "#0F172A",
|
|
940
|
+
primaryBackground: "#F1F5F9",
|
|
941
|
+
primarySubdued: "#F8FAFC",
|
|
942
|
+
primaryAccent: "#E2E8F0",
|
|
943
|
+
secondaryAccent: "#E2E8F0",
|
|
944
|
+
secondaryBackground: "#F1F5F9",
|
|
945
|
+
secondarySubdued: "#F8FAFC"
|
|
946
|
+
}
|
|
947
|
+
}), Y = [A], Z = [C, X, J], rr = _("🎨 Themes", () => {
|
|
948
|
+
const d = B({ light: Z, dark: Y });
|
|
949
|
+
return { themes: d, registerTheme: (f) => {
|
|
950
|
+
f.appearance === "light" ? d.light.push(f) : d.dark.push(f);
|
|
351
951
|
} };
|
|
352
|
-
}),
|
|
353
|
-
const
|
|
354
|
-
for (const [a, n] of Object.entries(o))
|
|
355
|
-
typeof n == "object" && n !== null && ("type" in n && n.type === "object" && "properties" in n && s(n.properties, [...i, a]), "$ref" in n && n.$ref === y.FontFamily && m.push([...i, a]));
|
|
356
|
-
};
|
|
357
|
-
s(N.properties.rules.properties);
|
|
358
|
-
const f = v(() => {
|
|
359
|
-
const o = [];
|
|
360
|
-
for (const a of m)
|
|
361
|
-
o.push(R(d(t).rules, a).trim());
|
|
362
|
-
const i = /* @__PURE__ */ new Set();
|
|
363
|
-
for (const a of o)
|
|
364
|
-
a.split(",").forEach((g) => i.add(g));
|
|
365
|
-
return Array.from(i);
|
|
366
|
-
}), b = v(() => f.value.filter((o) => {
|
|
367
|
-
if (o.startsWith('"') && o.endsWith('"') && o.includes("var(") === !1) {
|
|
368
|
-
const i = ["Inter", "Merriweather", "Fira Mono"];
|
|
369
|
-
return !(i.includes(o) || i.map((a) => `"${a}"`).includes(o));
|
|
370
|
-
}
|
|
371
|
-
return !1;
|
|
372
|
-
}).map((o) => (o.startsWith('"') && o.endsWith('"') && (o = o.slice(1, -1)), o.replace(" ", "+"))));
|
|
373
|
-
return { fonts: f, googleFonts: b };
|
|
374
|
-
}, P = (t, m, s, f, b) => {
|
|
375
|
-
const { themes: o } = j(E());
|
|
952
|
+
}), er = (d, s, f, p, o) => {
|
|
953
|
+
const { themes: c } = I(rr());
|
|
376
954
|
return { theme: v(() => {
|
|
377
|
-
const a = d
|
|
378
|
-
return h ?
|
|
955
|
+
const a = i(d) ? i(f) : i(s), t = i(d) ? A : C, n = i(d) ? i(o) : i(p), h = i(c)[i(d) ? "dark" : "light"].find((l) => l.name === a);
|
|
956
|
+
return h ? n ? S({}, t, h, { rules: n }) : S(t, h) : (a && a !== t.name && console.warn(`Theme "${a}" doesn't exist.`), n ? S({}, t, { rules: n }) : t);
|
|
379
957
|
}) };
|
|
380
|
-
},
|
|
958
|
+
}, or = (d) => {
|
|
959
|
+
const s = V(d, { delimiter: "--" }), f = (p) => `--theme--${P(p, { separator: "-" })}`;
|
|
960
|
+
return U(s, (p, o) => f(o));
|
|
961
|
+
}, gr = /* @__PURE__ */ $({
|
|
381
962
|
__name: "theme-provider",
|
|
382
963
|
props: {
|
|
383
964
|
darkMode: { type: Boolean },
|
|
384
|
-
themeLight: { default:
|
|
965
|
+
themeLight: { default: C.name },
|
|
385
966
|
themeLightOverrides: { default: () => ({}) },
|
|
386
|
-
themeDark: { default:
|
|
967
|
+
themeDark: { default: A.name },
|
|
387
968
|
themeDarkOverrides: { default: () => ({}) }
|
|
388
969
|
},
|
|
389
|
-
setup(
|
|
390
|
-
const
|
|
391
|
-
|
|
392
|
-
return I(u, (k, S) => l(S));
|
|
393
|
-
}), { googleFonts: g } = K(a);
|
|
394
|
-
M({
|
|
970
|
+
setup(d) {
|
|
971
|
+
const s = d, { darkMode: f, themeLight: p, themeDark: o, themeLightOverrides: c, themeDarkOverrides: m } = D(s), { theme: a } = er(f, p, o, c, m), t = v(() => or(i(a).rules)), { googleFonts: n } = q(a);
|
|
972
|
+
E({
|
|
395
973
|
link: v(() => {
|
|
396
|
-
let
|
|
397
|
-
if (
|
|
398
|
-
const
|
|
399
|
-
|
|
974
|
+
let l = "";
|
|
975
|
+
if (n.value.length > 0) {
|
|
976
|
+
const g = n.value.join("&family=");
|
|
977
|
+
l += `https://fonts.googleapis.com/css2?family=${g}`, l += `
|
|
400
978
|
`;
|
|
401
979
|
}
|
|
402
|
-
return
|
|
980
|
+
return l ? [
|
|
403
981
|
{
|
|
404
982
|
rel: "stylesheet",
|
|
405
|
-
href:
|
|
983
|
+
href: l
|
|
406
984
|
}
|
|
407
985
|
] : [];
|
|
408
986
|
})
|
|
409
987
|
});
|
|
410
|
-
const h = v(() => `:root {${Object.entries(
|
|
411
|
-
return (
|
|
412
|
-
|
|
988
|
+
const h = v(() => `:root {${Object.entries(i(t)).map(([g, x]) => `${g}: ${x};`).join(" ")}}`);
|
|
989
|
+
return (l, g) => (T(), L(G, { to: "#theme" }, [
|
|
990
|
+
N(M(h.value), 1)
|
|
413
991
|
]));
|
|
414
992
|
}
|
|
415
993
|
});
|
|
416
994
|
export {
|
|
417
|
-
|
|
418
|
-
|
|
419
|
-
|
|
420
|
-
|
|
421
|
-
|
|
422
|
-
|
|
995
|
+
lr as Definitions,
|
|
996
|
+
gr as ThemeProvider,
|
|
997
|
+
Q as ThemeSchema,
|
|
998
|
+
R as defineTheme,
|
|
999
|
+
or as rulesToCssVars,
|
|
1000
|
+
q as useFonts,
|
|
1001
|
+
er as useTheme,
|
|
1002
|
+
rr as useThemeStore
|
|
423
1003
|
};
|