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    DiffSplit,
 96    DiffStacked,
 97    Disconnected,
 98    Download,
 99    EditorAtom,
100    EditorCursor,
101    EditorEmacs,
102    EditorJetBrains,
103    EditorSublime,
104    EditorVsCode,
105    Ellipsis,
106    EllipsisVertical,
107    Envelope,
108    Eraser,
109    Escape,
110    Exit,
111    ExpandDown,
112    ExpandUp,
113    ExpandVertical,
114    Eye,
115    File,
116    FileCode,
117    FileDiff,
118    FileDoc,
119    FileGeneric,
120    FileGit,
121    FileLock,
122    FileMarkdown,
123    FileRust,
124    FileTextFilled,
125    FileTextOutlined,
126    FileToml,
127    FileTree,
128    Filter,
129    Flame,
130    Folder,
131    FolderOpen,
132    FolderSearch,
133    Font,
134    FontSize,
135    FontWeight,
136    ForwardArrow,
137    GenericClose,
138    GenericMaximize,
139    GenericMinimize,
140    GenericRestore,
141    GitBranch,
142    GitBranchAlt,
143    GitBranchPlus,
144    Github,
145    Hash,
146    HistoryRerun,
147    Image,
148    Inception,
149    Indicator,
150    Info,
151    Json,
152    Keyboard,
153    Library,
154    LineHeight,
155    Link,
156    Linux,
157    ListCollapse,
158    ListFilter,
159    ListTodo,
160    ListTree,
161    ListX,
162    LoadCircle,
163    LocationEdit,
164    LockOutlined,
165    MagnifyingGlass,
166    Maximize,
167    Menu,
168    MenuAlt,
169    MenuAltTemp,
170    Mic,
171    MicMute,
172    Minimize,
173    Notepad,
174    Option,
175    PageDown,
176    PageUp,
177    Paperclip,
178    Pencil,
179    PencilUnavailable,
180    Person,
181    Pin,
182    PlayFilled,
183    PlayOutlined,
184    Plus,
185    Power,
186    Public,
187    PullRequest,
188    Quote,
189    Reader,
190    RefreshTitle,
191    Regex,
192    ReplNeutral,
193    Replace,
194    ReplaceAll,
195    ReplaceNext,
196    ReplyArrowRight,
197    Rerun,
198    Return,
199    RotateCcw,
200    RotateCw,
201    Scissors,
202    Screen,
203    SelectAll,
204    Send,
205    Server,
206    Settings,
207    ShieldCheck,
208    Shift,
209    Slash,
210    Sliders,
211    Space,
212    Sparkle,
213    Split,
214    SplitAlt,
215    SquareDot,
216    SquareMinus,
217    SquarePlus,
218    Star,
219    StarFilled,
220    Stop,
221    Supermaven,
222    SupermavenDisabled,
223    SupermavenError,
224    SupermavenInit,
225    SwatchBook,
226    SweepAi,
227    SweepAiDisabled,
228    SweepAiDown,
229    SweepAiError,
230    SweepAiUp,
231    Tab,
232    Terminal,
233    TerminalAlt,
234    TerminalGhost,
235    TextSnippet,
236    TextThread,
237    ThinkingMode,
238    Thread,
239    ThreadFromSummary,
240    ThumbsDown,
241    ThumbsUp,
242    TodoComplete,
243    TodoPending,
244    TodoProgress,
245    ToolCopy,
246    ToolDeleteFile,
247    ToolDiagnostics,
248    ToolFolder,
249    ToolHammer,
250    ToolNotification,
251    ToolPencil,
252    ToolRead,
253    ToolRegex,
254    ToolSearch,
255    ToolTerminal,
256    ToolThink,
257    ToolWeb,
258    Trash,
259    Triangle,
260    TriangleRight,
261    Undo,
262    Unpin,
263    UserCheck,
264    UserGroup,
265    UserRoundPen,
266    Warning,
267    WholeWord,
268    XCircle,
269    XCircleFilled,
270    ZedAgent,
271    ZedAgentTwo,
272    ZedAssistant,
273    ZedPredict,
274    ZedPredictDisabled,
275    ZedPredictDown,
276    ZedPredictError,
277    ZedPredictUp,
278    ZedSrcCustom,
279    ZedSrcExtension,
280    ZedXCopilot,
281}
282
283impl IconName {
284    /// Returns the path to this icon.
285    pub fn path(&self) -> Arc<str> {
286        let file_stem: &'static str = self.into();
287        format!("icons/{file_stem}.svg").into()
288    }
289}