feat: enable/disable specific replacers

This commit is contained in:
2024-04-30 17:53:53 +03:00
committed by Chen Asraf
parent 5c0132fe95
commit fbb89b1b44
5 changed files with 56 additions and 2 deletions

View File

@@ -57,6 +57,17 @@ local items = {
function TextTransform.popup()
state.save_positions()
local filtered = {}
local config = _G.TextTransform.options
for _, item in ipairs(items) do
if not config.replacers[item.value] or not config.replacers[item.value].enabled then
goto continue
end
table.insert(filtered, item)
::continue::
end
local picker = pickers.new(dropdown, {
prompt_title = "Change Case",
finder = finders.new_table({