hyuskui 0.0.1

Add hyuskui components to a GPUI project: cargo hyuskui add button
pub struct File {
    /// Path relative to the project root, e.g. `src/ui/button.rs`.
    pub target: &'static str,
    pub content: &'static str,
}

pub struct Item {
    pub name: &'static str,
    /// `registry:ui` for components, `registry:lib` for shared code such as the theme.
    pub kind: &'static str,
    pub description: &'static str,
    pub dependencies: &'static [&'static str],
    pub files: &'static [File],
}

include!(concat!(env!("OUT_DIR"), "/registry.rs"));

/// Accepts the docs spelling (`input-otp`) as well as the module name (`input_otp`).
pub fn find(name: &str) -> Option<&'static Item> {
    let name = name.replace('-', "_");
    ITEMS.iter().find(|item| item.name == name)
}

pub fn components() -> impl Iterator<Item = &'static Item> {
    ITEMS.iter().filter(|item| item.kind == "registry:ui")
}