nvf/modules/plugins/utility/motion/precognition/precognition.nix

70 lines
1.7 KiB
Nix
Raw Normal View History

{lib, ...}: let
2024-11-04 00:25:24 +00:00
inherit (lib.options) mkEnableOption mkOption literalExpression;
inherit (lib.types) attrsOf listOf str bool int submodule;
in {
2024-11-04 00:25:24 +00:00
options.vim.utility.motion.precognition = rec {
enable = mkEnableOption "precognition.nvim plugin";
startVisible = mkOption {
type = bool;
description = "Whether to start 'precognition' automatically.";
2024-11-04 00:25:24 +00:00
default = true;
};
showBlankVirtLine = mkOption {
type = bool;
description = "Whether to show a blank virtual line when no movements are shown.";
2024-11-04 00:25:24 +00:00
default = true;
};
highlightColor = mkOption {
type = attrsOf str;
example = literalExpression ''
{ link = "Comment"; }
# or
{ foreground = "#0000FF"; background = "#000000"; };
2024-11-04 00:25:24 +00:00
'';
default = {link = "Comment";};
description = ''
The highlight for the virtual text.
'';
2024-11-04 00:25:24 +00:00
};
hints = mkOption {
default = {};
description = ''
What motions display and at what priority.";
'';
2024-11-04 00:25:24 +00:00
type = attrsOf (submodule {
options = {
text = mkOption {
type = str;
description = "The easier-to-read depiction of the motion.";
};
prio = mkOption {
type = int;
2024-11-04 00:25:24 +00:00
description = "The priority of the hint.";
example = 10;
default = 1;
2024-11-04 00:25:24 +00:00
};
};
});
};
2024-11-04 07:48:31 +00:00
gutterHints =
hints
// {
description = ''
What motions display and at what priority. Only appears in gutters.
'';
};
2024-11-04 00:25:24 +00:00
disabled_fts = mkOption {
type = listOf str;
default = ["startify"];
example = literalExpression ''["startify"]'';
2024-11-04 00:25:24 +00:00
};
};
}