zed/crates/ui2/src/slot.rs
Marshall Bowers d8ed7c0721
Move GraphicSlot out of components module (#3444)
This PR moves the `GraphicSlot` definition out of the `components`
module, as it doesn't contain a component.

Release Notes:

- N/A
2023-11-29 15:29:33 -05:00

12 lines
276 B
Rust

use gpui::{ImageSource, SharedString};
use crate::Icon;
/// A slot utility that provides a way to to pass either
/// an icon or an image to a component.
#[derive(Debug, Clone)]
pub enum GraphicSlot {
Icon(Icon),
Avatar(ImageSource),
PublicActor(SharedString),
}