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