Skip to main content

pictogram/
lib.rs

1#![doc = include_str!("../README.md")]
2
3mod svg;
4mod view_box;
5
6#[doc(hidden)]
7pub use pictogram_macro::svg_icon as zzz__macro_use_svg_icon;
8
9/// Index to lookup available icons from material
10#[cfg(feature = "material")]
11pub use pictogram_icons_material::index as material;
12
13/// Index to lookup available icons from bootstrap
14#[cfg(feature = "bootstrap")]
15pub use pictogram_icons_bootstrap::index as bootstrap;
16
17/// Index to lookup available icons from feather
18#[cfg(feature = "feather")]
19pub use pictogram_icons_feather::index as feather;
20
21/// Index to lookup available icons from font awesome
22#[cfg(feature = "font-awesome")]
23pub use pictogram_icons_font_awesome::index as font_awesome;
24
25/// Index to lookup available icons from tabler
26#[cfg(feature = "tabler")]
27pub use pictogram_icons_tabler::index as tabler;
28
29/// Index to lookup available icons from simple
30#[cfg(feature = "simple")]
31pub use pictogram_icons_simple::index as simple;
32
33/// Index to lookup available icons from heroicons
34#[cfg(feature = "hero")]
35pub use pictogram_icons_hero::index as hero;
36
37/// Index to lookup available icons from ion
38#[cfg(feature = "ion")]
39pub use pictogram_icons_ion::index as ion;
40
41/// Index to lookup available icons from lucide
42#[cfg(feature = "lucide")]
43pub use pictogram_icons_lucide::index as lucide;
44
45/// Index to lookup available icons from oct
46#[cfg(feature = "oct")]
47pub use pictogram_icons_oct::index as oct;
48
49/// Index to lookup available icons from vscode
50#[cfg(feature = "vscode")]
51pub use pictogram_icons_vscode::index as vscode;
52
53pub use svg::*;
54pub use view_box::*;
55
56/// Macro to lookup a SVG at compile time.
57/// Wraps the proc-macro for better ergonomics.
58/// ```rust, ignore
59/// // Using the index
60/// let svg = pictogram::svg!(pictogram::material::action_123::filled);
61/// println!("{}", svg);
62/// ```
63#[macro_export]
64macro_rules! svg {
65    ($path:path) => {{
66        const _: () = {
67            let _ = $path;
68        };
69        $crate::zzz__macro_use_svg_icon!($path)
70    }};
71}