From 6c083dbf27d59187f38db178edbe1726edb62b32 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?ryan4yin=20=7C=20=E4=BA=8C=E8=8A=B1?= Date: Sat, 17 Oct 2026 12:05:30 +0800 Subject: [PATCH] feat(yazi): enlarge image previews and add four plugins (#469) Assisted-by: DeepSeek Harness (deepseek-flash) --- home/base/core/yazi.nix | 52 +++++++++++++++++++++++++++++++++++++++++ 1 file changed, 52 insertions(+) diff --git a/home/base/core/yazi.nix b/home/base/core/yazi.nix index e8b5a63e..520ed57d 100644 --- a/home/base/core/yazi.nix +++ b/home/base/core/yazi.nix @@ -13,6 +13,58 @@ show_hidden = true; sort_dir_first = true; }; + preview = { + max_width = 2000; + max_height = 2000; + }; + plugin.prepend_fetchers = [ + { + url = "*"; + run = "git"; + group = "git"; + } + { + url = "*/"; + run = "git"; + group = "git"; + } + ]; }; + plugins = with pkgs.yaziPlugins; { + git = { + package = git; + setup = true; + settings = { + order = 1500; + }; + }; + inherit + jump-to-char + toggle-pane + zoom + ; + }; + keymap.mgr.prepend_keymap = [ + { + on = "="; + run = "plugin zoom 1"; + desc = "Zoom in the preview"; + } + { + on = "-"; + run = "plugin zoom -1"; + desc = "Zoom out the preview"; + } + { + on = "T"; + run = "plugin toggle-pane max-preview"; + desc = "Maximize or restore the preview"; + } + { + on = "F"; + run = "plugin jump-to-char"; + desc = "Jump to the next file starting with a character"; + } + ]; }; }