mirror of
https://github.com/sxyazi/yazi.git
synced 2026-07-25 08:41:05 +00:00
15 lines
268 B
Rust
15 lines
268 B
Rust
use mlua::UserDataMethods;
|
|
use yazi_fs::file::FileInventory;
|
|
|
|
use crate::THEME;
|
|
|
|
inventory::submit! {
|
|
FileInventory {
|
|
register: |registry| {
|
|
registry.add_method("icon", |_, me, ()| {
|
|
// TODO: use a cache
|
|
Ok(THEME.icon.matches(me, false))
|
|
});
|
|
}
|
|
}
|
|
}
|