hmd/markdown/
icon.rs

1mod render;
2
3use lazy_static::lazy_static;
4use std::collections::HashMap;
5
6
7lazy_static! {
8    static ref ICONS: HashMap<Vec<u16>, Vec<u16>> = self::render::data();
9}
10
11
12pub fn get_icon(name: &Vec<u16>, size: usize, color: Option<(u8, u8, u8)>, standalone: bool) -> Option<Vec<u16>> {
13
14    match ICONS.get(name) {
15        Some(s) => Some(self::render::format(s, size, color, standalone)),
16        _ => None
17    }
18
19}