Skip to content

Commit

Permalink
docs: fix component.on_click params (#179)
Browse files Browse the repository at this point in the history
components.on_click should receive (_, _, _, _, buffer) instead of (buffer) to get the buffer object.
  • Loading branch information
gitgitchinchin authored Oct 18, 2023
1 parent 8575496 commit 8fc35d2
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -181,7 +181,7 @@ require('cokeline').setup({
},
{
text = '󰖭',
on_click = function(buffer)
on_click = function(_, _, _, _, buffer)
buffer:delete()
end
},
Expand Down Expand Up @@ -293,7 +293,7 @@ require('cokeline').setup({
},
{
text = '',
on_click = function(buffer)
on_click = function(_, _, _, _, buffer)
buffer:delete()
end,
},
Expand Down Expand Up @@ -378,7 +378,7 @@ require('cokeline').setup({
},
{
text = '',
on_click = function(buffer)
on_click = function(_, _, _, _, buffer)
buffer:delete()
end,
},
Expand Down Expand Up @@ -866,7 +866,7 @@ require('cokeline').setup({
},
{
text = '󰅖',
on_click = function(buffer)
on_click = function(_, _, _, _, buffer)
buffer:delete()
end
},
Expand Down

0 comments on commit 8fc35d2

Please sign in to comment.