Skip to content

Commit 67b42dc

Browse files
committed
doc: Upadated config section
1 parent 752ef3a commit 67b42dc

1 file changed

Lines changed: 91 additions & 3 deletions

File tree

README.md

Lines changed: 91 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -121,7 +121,9 @@ MiniDeps.add({
121121

122122
## 🔩 Configuration
123123

124-
The plugin can be configured via the `setup()` function. You can check the default configuration table [here]().
124+
The plugin can be configured via the `setup()` function. You can check the default configuration table [here](https://github.com/OXY2DEV/ui.nvim/blob/752ef3a1eb2aa2ffa33efd055f3cbbc6b417b435/lua/ui/spec.lua#L5-L1172).
125+
126+
A simplified version of the configuration table is given below,
125127

126128
```lua
127129
require("ui").setup({
@@ -170,13 +172,99 @@ require("ui").setup({
170172
},
171173

172174
example = {
173-
condition = function ()
174-
return true;
175+
condition = function ()
176+
return true;
175177
end,
176178

177179
cursor = "@comment"
178180
}
179181
}
182+
},
183+
184+
message = {
185+
enable = true,
186+
187+
mesaage_winconfig = {},
188+
list_winconfig = {},
189+
confirm_winconfig = {},
190+
history_winconfig = {},
191+
192+
ignore = function ()
193+
return false:
194+
end,
195+
196+
showcmd = {
197+
max_width = 10,
198+
modifier = nil
199+
},
200+
201+
msg_styles = {
202+
default = {
203+
duration = 500,
204+
205+
modifier = nil,
206+
decorations = {
207+
icon = { { "I " } }
208+
}
209+
},
210+
211+
example = {
212+
condition = function ()
213+
return true;
214+
end,
215+
216+
decorations = {
217+
icon = { { "B " } }
218+
}
219+
}
220+
},
221+
222+
is_list = function ()
223+
return false;
224+
end,
225+
226+
list_styles = {
227+
default = {
228+
modifier = nil,
229+
230+
row = nil,
231+
col = nil,
232+
233+
width = nil,
234+
height = nil,
235+
236+
winhl = nil
237+
},
238+
239+
example = {
240+
condition = function ()
241+
return true;
242+
end,
243+
244+
border = "rounded"
245+
}
246+
},
247+
confirm_styles = {
248+
default = {
249+
modifier = nil,
250+
251+
row = nil,
252+
col = nil,
253+
254+
width = nil,
255+
height = nil,
256+
257+
winhl = nil
258+
},
259+
260+
example = {
261+
condition = function ()
262+
return true;
263+
end,
264+
265+
border = "rounded"
266+
}
267+
}
180268
}
181269
});
182270
```

0 commit comments

Comments
 (0)