Prepare components

This commit is contained in:
Olivier Roques
2020-12-22 23:53:44 +01:00
parent 355aacba17
commit 1d80803552
9 changed files with 36 additions and 26 deletions

View File

@@ -25,21 +25,21 @@ function M.get_paste()
if not o.paste then
return ''
end
return ' PASTE'
return 'PASTE'
end
function M.get_spell()
if not wo.spell then
return ''
end
return string.format(' SPELL [%s]', string.upper(bo.spelllang))
return string.format('SPELL [%s]', string.upper(bo.spelllang))
end
function M.get_component()
function M.get_item()
return table.concat({
[[%{luaeval('require("hardline.mode").get_mode()')}]],
[[%{luaeval('require("hardline.mode").get_paste()')}]],
[[%{luaeval('require("hardline.mode").get_spell()')}]],
[[%{luaeval('require("hardline.mode").get_mode()')}]], ' ',
[[%{luaeval('require("hardline.mode").get_paste()')}]], ' ',
[[%{luaeval('require("hardline.mode").get_spell()')}]], ' '
})
end