1use std::sync::Arc;
2
3use serde::{Deserialize, Serialize};
4use strum::{EnumIter, EnumString, IntoStaticStr};
5
6#[derive(
7 Debug, PartialEq, Eq, Copy, Clone, EnumIter, EnumString, IntoStaticStr, Serialize, Deserialize,
8)]
9#[strum(serialize_all = "snake_case")]
10pub enum IconName {
11 Ai,
12 AiAnthropic,
13 AiBedrock,
14 AiDeepSeek,
15 AiEdit,
16 AiGoogle,
17 AiLmStudio,
18 AiMistral,
19 AiOllama,
20 AiOpenAi,
21 AiZed,
22 ArrowCircle,
23 ArrowDown,
24 ArrowDownFromLine,
25 ArrowDownRight,
26 ArrowLeft,
27 ArrowRight,
28 ArrowRightLeft,
29 ArrowUp,
30 ArrowUpFromLine,
31 ArrowUpRight,
32 ArrowUpRightAlt,
33 AtSign,
34 AudioOff,
35 AudioOn,
36 Backspace,
37 Bell,
38 BellDot,
39 BellOff,
40 BellRing,
41 Binary,
42 Blocks,
43 Bolt,
44 Book,
45 BookCopy,
46 BookPlus,
47 Brain,
48 BugOff,
49 CaseSensitive,
50 Check,
51 CheckDouble,
52 ChevronDown,
53 /// This chevron indicates a popover menu.
54 ChevronDownSmall,
55 ChevronLeft,
56 ChevronRight,
57 ChevronUp,
58 ChevronUpDown,
59 Circle,
60 CircleOff,
61 Clipboard,
62 Close,
63 Cloud,
64 Code,
65 Cog,
66 Command,
67 Context,
68 Control,
69 Copilot,
70 CopilotDisabled,
71 CopilotError,
72 CopilotInit,
73 Copy,
74 CountdownTimer,
75 Crosshair,
76 CursorIBeam,
77 Dash,
78 DatabaseZap,
79 Debug,
80 DebugBreakpoint,
81 DebugContinue,
82 DebugDisabledBreakpoint,
83 DebugDisabledLogBreakpoint,
84 DebugDetach,
85 DebugIgnoreBreakpoints,
86 DebugLogBreakpoint,
87 DebugPause,
88 DebugRestart,
89 DebugStepBack,
90 DebugStepInto,
91 DebugStepOut,
92 DebugStepOver,
93 DebugStop,
94 Delete,
95 Diff,
96 Disconnected,
97 DocumentText,
98 Download,
99 Ellipsis,
100 EllipsisVertical,
101 Envelope,
102 Eraser,
103 Escape,
104 Exit,
105 ExpandDown,
106 ExpandUp,
107 ExpandVertical,
108 ExternalLink,
109 Eye,
110 File,
111 FileCode,
112 FileCreate,
113 FileDelete,
114 FileDiff,
115 FileDoc,
116 FileGeneric,
117 FileGit,
118 FileLock,
119 FileRust,
120 FileSearch,
121 FileText,
122 FileToml,
123 FileTree,
124 Filter,
125 Flame,
126 Folder,
127 FolderOpen,
128 FolderX,
129 Font,
130 FontSize,
131 FontWeight,
132 ForwardArrow,
133 Function,
134 GenericClose,
135 GenericMaximize,
136 GenericMinimize,
137 GenericRestore,
138 GitBranch,
139 GitBranchSmall,
140 Github,
141 Globe,
142 Hammer,
143 Hash,
144 HistoryRerun,
145 Image,
146 Indicator,
147 Info,
148 InlayHint,
149 Keyboard,
150 Layout,
151 Library,
152 LightBulb,
153 LineHeight,
154 Link,
155 ListCollapse,
156 ListTree,
157 ListX,
158 LoadCircle,
159 LockOutlined,
160 MagnifyingGlass,
161 MailOpen,
162 Maximize,
163 Menu,
164 MenuAlt,
165 MessageBubbles,
166 Mic,
167 MicMute,
168 Microscope,
169 Minimize,
170 Option,
171 PageDown,
172 PageUp,
173 PanelLeft,
174 PanelRight,
175 Pencil,
176 Person,
177 PersonCircle,
178 PhoneIncoming,
179 Pin,
180 Play,
181 Plus,
182 PocketKnife,
183 Power,
184 Public,
185 PullRequest,
186 Quote,
187 RefreshTitle,
188 Regex,
189 ReplNeutral,
190 Replace,
191 ReplaceAll,
192 ReplaceNext,
193 ReplyArrowRight,
194 Rerun,
195 Return,
196 Reveal,
197 RotateCcw,
198 RotateCw,
199 Route,
200 Save,
201 Scissors,
202 Screen,
203 SearchCode,
204 SearchSelection,
205 SelectAll,
206 Send,
207 Server,
208 Settings,
209 SettingsAlt,
210 Shift,
211 Slash,
212 SlashSquare,
213 Sliders,
214 SlidersVertical,
215 Snip,
216 Space,
217 Sparkle,
218 SparkleAlt,
219 SparkleFilled,
220 Spinner,
221 Split,
222 SquareDot,
223 SquareMinus,
224 SquarePlus,
225 Star,
226 StarFilled,
227 Stop,
228 StopFilled,
229 Strikethrough,
230 Supermaven,
231 SupermavenDisabled,
232 SupermavenError,
233 SupermavenInit,
234 SwatchBook,
235 Tab,
236 Terminal,
237 TextSnippet,
238 ThumbsDown,
239 ThumbsUp,
240 Trash,
241 TrashAlt,
242 Triangle,
243 TriangleRight,
244 Undo,
245 Unpin,
246 Update,
247 UserCheck,
248 UserGroup,
249 UserRoundPen,
250 Visible,
251 Wand,
252 Warning,
253 WholeWord,
254 X,
255 XCircle,
256 ZedAssistant,
257 ZedAssistantFilled,
258 ZedMaxMode,
259 ZedPredict,
260 ZedPredictDisabled,
261 ZedPredictDown,
262 ZedPredictError,
263 ZedPredictUp,
264 ZedXCopilot,
265}
266
267impl IconName {
268 /// Returns the path to this icon.
269 pub fn path(&self) -> Arc<str> {
270 let file_stem: &'static str = self.into();
271 format!("icons/{file_stem}.svg").into()
272 }
273}