-
Notifications
You must be signed in to change notification settings - Fork 62
/
chad_types.py
146 lines (100 loc) · 2.25 KB
/
chad_types.py
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
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
from dataclasses import dataclass
from enum import Enum, auto
from pathlib import Path
from typing import Mapping
TOP_LEVEL = Path(__file__).resolve(strict=True).parent
ASSETS = TOP_LEVEL / "assets"
ARTIFACT = TOP_LEVEL / "artifacts" / "artifact.json"
"""
Icons
"""
Icon = str
@dataclass(frozen=True)
class _FolderIcons:
open: Icon
closed: Icon
@dataclass(frozen=True)
class _LinkIcons:
normal: Icon
broken: Icon
@dataclass(frozen=True)
class _StatusIcons:
active: Icon
inactive: Icon
selected: Icon
not_selected: Icon
@dataclass(frozen=True)
class IconGlyphs:
default_icon: Icon
folder: _FolderIcons
link: _LinkIcons
status: _StatusIcons
ext_exact: Mapping[str, Icon]
name_exact: Mapping[str, Icon]
name_glob: Mapping[str, Icon]
@dataclass(frozen=True)
class IconGlyphSet:
ascii_hollow: IconGlyphs
ascii: IconGlyphs
devicons: IconGlyphs
emoji: IconGlyphs
class IconGlyphSetEnum(Enum):
ascii_hollow = auto()
ascii = auto()
devicons = auto()
emoji = auto()
"""
Icon Colours
"""
Hex = str
IconColours = Mapping[str, Hex]
@dataclass(frozen=True)
class IconColourSet:
github: IconColours
class IconColourSetEnum(Enum):
github = auto()
none = auto()
"""
LS Colours
"""
LS_COLOR = str
@dataclass(frozen=True)
class LSColourSet:
solarized_dark_256: LS_COLOR
solarized_dark: LS_COLOR
solarized_light: LS_COLOR
solarized_universal: LS_COLOR
nord: LS_COLOR
trapdoor: LS_COLOR
class LSColoursEnum(Enum):
env = auto()
solarized_dark_256 = auto()
solarized_dark = auto()
solarized_light = auto()
solarized_universal = auto()
nord = auto()
trapdoor = auto()
"""
Text Colours
"""
@dataclass(frozen=True)
class TextColours:
ext_exact: Mapping[str, Hex]
name_exact: Mapping[str, Hex]
name_glob: Mapping[str, Hex]
@dataclass(frozen=True)
class TextColourSet:
nerdtree_syntax_light: TextColours
nerdtree_syntax_dark: TextColours
class TextColourSetEnum(Enum):
nerdtree_syntax_light = auto()
nerdtree_syntax_dark = auto()
"""
Artifact
"""
@dataclass(frozen=True)
class Artifact:
icons: IconGlyphSet
ls_colours: LSColourSet
icon_colours: IconColourSet
text_colours: TextColourSet