mod asset_loader;
mod systems;
pub(crate) mod render;
mod asset;
pub use asset::VelloSvg;
mod parse;
pub use parse::{load_svg_from_bytes, load_svg_from_str};
mod plugin;
pub(crate) use plugin::SvgIntegrationPlugin;
use bevy::{
camera::{primitives::Aabb, visibility::VisibilityClass},
prelude::*,
};
#[derive(Component, Default, Debug, Clone, Deref, DerefMut, PartialEq, Eq, Reflect)]
#[require(Aabb, VelloSvgAnchor, Transform, Visibility, VisibilityClass)]
#[cfg_attr(feature = "picking", require(Pickable))]
#[reflect(Component)]
#[component(on_add = bevy::camera::visibility::add_visibility_class::<VelloSvg2d>)]
pub struct VelloSvg2d(pub Handle<VelloSvg>);
#[derive(Component, Default, Debug, Clone, Deref, DerefMut, PartialEq, Eq, Reflect)]
#[require(Node, VelloSvgAnchor, Visibility, VisibilityClass)]
#[reflect(Component)]
#[component(on_add = bevy::camera::visibility::add_visibility_class::<UiVelloSvg>)]
pub struct UiVelloSvg(pub Handle<VelloSvg>);
#[derive(Component, Default, Debug, Clone, Copy, PartialEq, Eq, Reflect)]
#[reflect(Component)]
pub enum VelloSvgAnchor {
BottomLeft,
Bottom,
BottomRight,
Left,
#[default]
Center,
Right,
TopLeft,
Top,
TopRight,
}