mirror of
https://github.com/NotAShelf/nvf.git
synced 2026-01-02 09:05:55 +00:00
visuals/fidget-nvim: update setupOpts to match upstream
This commit is contained in:
parent
45553196b3
commit
c53042a705
2 changed files with 71 additions and 5 deletions
|
|
@ -7,6 +7,7 @@
|
|||
inherit (lib.options) mkEnableOption mkOption literalExpression;
|
||||
inherit (lib.strings) toUpper;
|
||||
inherit (lib.types) int float bool str enum listOf attrsOf oneOf nullOr submodule;
|
||||
inherit (lib.trivial) warn;
|
||||
inherit (lib.nvim.types) mkPluginSetupOption luaInline borderType;
|
||||
inherit (lib.generators) mkLuaInline;
|
||||
in {
|
||||
|
|
@ -53,6 +54,16 @@ in {
|
|||
end
|
||||
'';
|
||||
};
|
||||
clear_on_detach = mkOption {
|
||||
description = "Clear notification group when LSP server detaches";
|
||||
type = nullOr luaInline;
|
||||
default = mkLuaInline ''
|
||||
function(client_id)
|
||||
local client = vim.lsp.get_client_by_id(client_id)
|
||||
return client and client.name or nil
|
||||
end
|
||||
'';
|
||||
};
|
||||
ignore = mkOption {
|
||||
description = "Ignore LSP servers by name";
|
||||
type = listOf str;
|
||||
|
|
@ -417,6 +428,20 @@ in {
|
|||
type = bool;
|
||||
default = true;
|
||||
};
|
||||
align = mkOption {
|
||||
description = "Indent messages longer than a single line";
|
||||
type = enum ["message" "annote"];
|
||||
default = "message";
|
||||
};
|
||||
reflow = mkOption {
|
||||
description = ''
|
||||
Reflow (wrap) messages wider than notification window
|
||||
|
||||
The various options determine how wrapping is handled mid-word.
|
||||
'';
|
||||
type = enum ["hard" "hyphenate" "ellipsis" "false"];
|
||||
default = "false";
|
||||
};
|
||||
icon_separator = mkOption {
|
||||
description = "Separator between group name and icon";
|
||||
type = str;
|
||||
|
|
@ -432,6 +457,16 @@ in {
|
|||
type = str;
|
||||
default = "Comment";
|
||||
};
|
||||
line_margin = mkOption {
|
||||
description = ''
|
||||
Spaces to pad both sides of each non-empty line
|
||||
|
||||
Useful for adding a visual gap between notification text
|
||||
and any buffer it may overlap with.
|
||||
'';
|
||||
type = int;
|
||||
default = 1;
|
||||
};
|
||||
render_message = mkOption {
|
||||
description = "How to render notification messages";
|
||||
type = luaInline;
|
||||
|
|
@ -462,6 +497,15 @@ in {
|
|||
then config.vim.ui.borders.globalStyle
|
||||
else "none";
|
||||
};
|
||||
border_hl = mkOption {
|
||||
description = ''
|
||||
Highlight group for notification window border
|
||||
|
||||
Set to empty string to keep your theme's default `FloatBorder` highlight.
|
||||
'';
|
||||
type = str;
|
||||
default = "";
|
||||
};
|
||||
zindex = mkOption {
|
||||
description = "Stacking priority of the notification window";
|
||||
type = int;
|
||||
|
|
@ -497,6 +541,16 @@ in {
|
|||
type = enum ["editor" "win"];
|
||||
default = "editor";
|
||||
};
|
||||
tabstop = mkOption {
|
||||
description = "Width of each tab character in the notification window";
|
||||
type = int;
|
||||
default = 8;
|
||||
};
|
||||
avoid = mkOption {
|
||||
description = "Filetypes the notification window should avoid";
|
||||
type = listOf str;
|
||||
default = [];
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
|
|
@ -505,17 +559,27 @@ in {
|
|||
enable = mkOption {
|
||||
description = "Integrate with nvim-tree/nvim-tree.lua (if enabled)";
|
||||
type = bool;
|
||||
default =
|
||||
if config.vim.filetree.nvimTree.enable
|
||||
then true
|
||||
else false;
|
||||
default = false;
|
||||
visible = false;
|
||||
apply = warn ''
|
||||
Option `vim.visuals.fidget-nvim.setupOpts.integration.nvim-tree.enable`
|
||||
has been deprecated upstream. Use
|
||||
`vim.visuals.fidget-nvim.setupOpts.notification.window.avoid = ["NvimTree"]` instead.
|
||||
This is already set if `vim.filetree.nvimTree.enable == true`.
|
||||
'';
|
||||
};
|
||||
};
|
||||
xcodebuild-nvim = {
|
||||
enable = mkOption {
|
||||
description = "Integrate with wojciech-kulik/xcodebuild.nvim (if enabled)";
|
||||
type = bool;
|
||||
default = true;
|
||||
default = false;
|
||||
visible = false;
|
||||
apply = warn ''
|
||||
Option `vim.visuals.fidget-nvim.setupOpts.integration.xcodebuild-nvim.enable`
|
||||
has been deprecated upstream. Use
|
||||
`vim.visuals.fidget-nvim.setupOpts.notification.window.avoid = ["TestExplorer"]` instead.
|
||||
'';
|
||||
};
|
||||
};
|
||||
};
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue