icon-picker: lazy load

This commit is contained in:
Ching Pei Yang 2024-09-30 21:59:10 +02:00 committed by Ching Pei Yang
parent a9ce2fe101
commit fb36de0aac
No known key found for this signature in database
GPG key ID: 062FBBCE1D0C5DD9

View file

@ -4,20 +4,22 @@
... ...
}: let }: let
inherit (lib.modules) mkIf; inherit (lib.modules) mkIf;
inherit (lib.nvim.dag) entryAnywhere;
cfg = config.vim.utility.icon-picker; cfg = config.vim.utility.icon-picker;
in { in {
config = mkIf cfg.enable { config = mkIf cfg.enable {
vim.startPlugins = [ vim.startPlugins = ["dressing-nvim"];
"icon-picker-nvim"
"dressing-nvim"
];
vim.pluginRC.icon-picker = entryAnywhere '' vim.lazy.plugins = [
require("icon-picker").setup({ {
disable_legacy_commands = true package = "icon-picker-nvim";
}) setupModule = "icon-picker";
''; setupOpts = {
disable_legacy_commands = true;
};
cmd = ["IconPickerInsert" "IconPickerNormal" "IconPickerYank"];
}
];
}; };
} }