-
Notifications
You must be signed in to change notification settings - Fork 25
/
uno.config.ts
48 lines (46 loc) · 1004 Bytes
/
uno.config.ts
1
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
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
import presetIcons from "@unocss/preset-icons";
import presetWind from "@unocss/preset-wind";
import {
defineConfig,
transformerDirectives,
transformerVariantGroup,
} from "unocss";
const zIndex = {
search: 12,
gnb: 11,
"gnb-body": 10,
"dropdown-link": 9,
"left-sidebar": 8,
"overlay-dim": 2,
"selected-tab": 1,
};
export default defineConfig({
presets: [presetIcons(), presetWind()],
transformers: [transformerDirectives(), transformerVariantGroup()],
theme: {
colors: {
portone: "#FC6B2D",
},
maxWidth: {
"8xl": "90rem",
},
zIndex,
},
blocklist: [
// z-index 숫자로 넣는 것 비활성화
/^z-\d+$/,
],
// 이름 붙여 정의된 z-index 값들을 z-$name 꼴로 사용
rules: [
[
/^z-(.*)$/,
([, name]) => {
if (name && name in zIndex) {
return { "z-index": zIndex[name as keyof typeof zIndex] };
}
return;
},
{ autocomplete: "z-$zIndex" },
],
],
});