icons.rs

  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    AiClaude,
 15    AiDeepSeek,
 16    AiEdit,
 17    AiGemini,
 18    AiGoogle,
 19    AiLmStudio,
 20    AiMistral,
 21    AiOllama,
 22    AiOpenAi,
 23    AiOpenAiCompat,
 24    AiOpenRouter,
 25    AiVZero,
 26    AiXAi,
 27    AiZed,
 28    ArrowCircle,
 29    ArrowDown,
 30    ArrowDown10,
 31    ArrowDownFromLine,
 32    ArrowDownRight,
 33    ArrowLeft,
 34    ArrowRight,
 35    ArrowRightLeft,
 36    ArrowUp,
 37    ArrowUpAlt,
 38    ArrowUpFromLine,
 39    ArrowUpRight,
 40    ArrowUpRightAlt,
 41    AudioOff,
 42    AudioOn,
 43    Backspace,
 44    Bell,
 45    BellDot,
 46    BellOff,
 47    BellRing,
 48    Binary,
 49    Blocks,
 50    BoltOutlined,
 51    BoltFilled,
 52    Book,
 53    BookCopy,
 54    BugOff,
 55    CaseSensitive,
 56    Chat,
 57    Check,
 58    CheckDouble,
 59    ChevronDown,
 60    /// This chevron indicates a popover menu.
 61    ChevronDownSmall,
 62    ChevronLeft,
 63    ChevronRight,
 64    ChevronUp,
 65    ChevronUpDown,
 66    Circle,
 67    CircleOff,
 68    CircleHelp,
 69    Close,
 70    Cloud,
 71    CloudDownload,
 72    Code,
 73    Cog,
 74    Command,
 75    Context,
 76    Control,
 77    Copilot,
 78    CopilotDisabled,
 79    CopilotError,
 80    CopilotInit,
 81    Copy,
 82    CountdownTimer,
 83    Crosshair,
 84    CursorIBeam,
 85    Dash,
 86    DatabaseZap,
 87    Debug,
 88    DebugBreakpoint,
 89    DebugContinue,
 90    DebugDisabledBreakpoint,
 91    DebugDisabledLogBreakpoint,
 92    DebugDetach,
 93    DebugIgnoreBreakpoints,
 94    DebugLogBreakpoint,
 95    DebugPause,
 96    DebugRestart,
 97    DebugStepBack,
 98    DebugStepInto,
 99    DebugStepOut,
100    DebugStepOver,
101    DebugStop,
102    Delete,
103    Diff,
104    Disconnected,
105    DocumentText,
106    Download,
107    EditorAtom,
108    EditorCursor,
109    EditorEmacs,
110    EditorJetBrains,
111    EditorSublime,
112    EditorVsCode,
113    Ellipsis,
114    EllipsisVertical,
115    Envelope,
116    Equal,
117    Eraser,
118    Escape,
119    Exit,
120    ExpandDown,
121    ExpandUp,
122    ExpandVertical,
123    ExternalLink,
124    Eye,
125    File,
126    FileCode,
127    FileCreate,
128    FileDiff,
129    FileDoc,
130    FileGeneric,
131    FileGit,
132    FileLock,
133    FileRust,
134    FileSearch,
135    FileText,
136    FileToml,
137    FileTree,
138    Filter,
139    Flame,
140    Folder,
141    FolderOpen,
142    FolderX,
143    Font,
144    FontSize,
145    FontWeight,
146    ForwardArrow,
147    Function,
148    GenericClose,
149    GenericMaximize,
150    GenericMinimize,
151    GenericRestore,
152    GitBranch,
153    GitBranchSmall,
154    Github,
155    Globe,
156    Hammer,
157    Hash,
158    HistoryRerun,
159    Image,
160    Indicator,
161    Info,
162    InlayHint,
163    Keyboard,
164    Layout,
165    Library,
166    LightBulb,
167    LineHeight,
168    Link,
169    ListCollapse,
170    ListTodo,
171    ListTree,
172    ListX,
173    LoadCircle,
174    LocationEdit,
175    LockOutlined,
176    LspDebug,
177    LspRestart,
178    LspStop,
179    MagnifyingGlass,
180    MailOpen,
181    Maximize,
182    Menu,
183    MenuAlt,
184    Mic,
185    MicMute,
186    Minimize,
187    Option,
188    PageDown,
189    PageUp,
190    PanelLeft,
191    PanelRight,
192    Pencil,
193    Person,
194    PersonCircle,
195    PhoneIncoming,
196    Pin,
197    PlayOutlined,
198    PlayFilled,
199    Plus,
200    PocketKnife,
201    Power,
202    Public,
203    PullRequest,
204    Quote,
205    RefreshTitle,
206    Regex,
207    ReplNeutral,
208    Replace,
209    ReplaceAll,
210    ReplaceNext,
211    ReplyArrowRight,
212    Rerun,
213    Return,
214    RotateCcw,
215    RotateCw,
216    Route,
217    Save,
218    Scissors,
219    Screen,
220    ScrollText,
221    SearchSelection,
222    SelectAll,
223    Send,
224    Server,
225    Settings,
226    SettingsAlt,
227    ShieldCheck,
228    Shift,
229    Slash,
230    SlashSquare,
231    Sliders,
232    SlidersVertical,
233    Snip,
234    Space,
235    Sparkle,
236    SparkleAlt,
237    SparkleFilled,
238    Split,
239    SplitAlt,
240    SquareDot,
241    SquareMinus,
242    SquarePlus,
243    Star,
244    StarFilled,
245    Stop,
246    StopFilled,
247    Supermaven,
248    SupermavenDisabled,
249    SupermavenError,
250    SupermavenInit,
251    SwatchBook,
252    Tab,
253    Terminal,
254    TerminalAlt,
255    TextSnippet,
256    TextThread,
257    Thread,
258    ThreadFromSummary,
259    ThumbsDown,
260    ThumbsUp,
261    TodoComplete,
262    TodoPending,
263    TodoProgress,
264    ToolBulb,
265    ToolCopy,
266    ToolDeleteFile,
267    ToolDiagnostics,
268    ToolFolder,
269    ToolHammer,
270    ToolNotification,
271    ToolPencil,
272    ToolRead,
273    ToolRegex,
274    ToolSearch,
275    ToolTerminal,
276    ToolWeb,
277    Trash,
278    Triangle,
279    TriangleRight,
280    Undo,
281    Unpin,
282    Update,
283    UserCheck,
284    UserGroup,
285    UserRoundPen,
286    Visible,
287    Wand,
288    Warning,
289    WholeWord,
290    X,
291    XCircle,
292    ZedAssistant,
293    ZedAssistantFilled,
294    ZedBurnMode,
295    ZedBurnModeOn,
296    ZedMcpCustom,
297    ZedMcpExtension,
298    ZedPredict,
299    ZedPredictDisabled,
300    ZedPredictDown,
301    ZedPredictError,
302    ZedPredictUp,
303    ZedXCopilot,
304}
305
306impl IconName {
307    /// Returns the path to this icon.
308    pub fn path(&self) -> Arc<str> {
309        let file_stem: &'static str = self.into();
310        format!("icons/{file_stem}.svg").into()
311    }
312}