plugins/utils: normalize plugin defaults

This commit is contained in:
Matt Sturgeon 2024-06-11 16:54:57 +01:00
parent b10a391bd0
commit 6ab2a39e6a
No known key found for this signature in database
GPG key ID: 4F91844CED1A8299
53 changed files with 1434 additions and 1221 deletions

View file

@ -27,12 +27,11 @@ in
'';
mainImage =
helpers.defaultNullOpts.mkEnum
helpers.defaultNullOpts.mkEnumFirstDefault
[
"neovim"
"file"
]
"neovim"
''
Main image display.
'';
@ -63,24 +62,20 @@ in
Displays the current line number instead of the current project.
'';
blacklist = helpers.defaultNullOpts.mkNullable (types.listOf types.str) "[]" ''
blacklist = helpers.defaultNullOpts.mkListOf types.str [ ] ''
A list of strings or Lua patterns that disable Rich Presence if the
current file name, path, or workspace matches.
'';
buttons =
helpers.defaultNullOpts.mkNullable
(types.either helpers.nixvimTypes.rawLua (
types.listOf (
types.submodule {
options = {
label = helpers.mkNullOrOption types.str "";
url = helpers.mkNullOrOption types.str "";
};
}
)
))
"[]"
helpers.defaultNullOpts.mkListOf
(types.submodule {
options = {
label = helpers.mkNullOrOption types.str "";
url = helpers.mkNullOrOption types.str "";
};
})
[ ]
''
Button configurations which will always appear in Rich Presence.