From 354b76ed1a92e3d719bc684932390ab87b7e2a30 Mon Sep 17 00:00:00 2001 From: Hubert Pelczarski <41551030+hoob3rt@users.noreply.github.com> Date: Fri, 14 May 2021 02:09:34 +0200 Subject: [PATCH] perf: prevent rehashing in themes for slight performance increase (#244) --- CONTRIBUTING.md | 84 ++++++++++--------------- lua/lualine/themes/16color.lua | 34 +++++----- lua/lualine/themes/ayu_dark.lua | 5 +- lua/lualine/themes/ayu_light.lua | 5 +- lua/lualine/themes/ayu_mirage.lua | 5 +- lua/lualine/themes/codedark.lua | 54 +++++++--------- lua/lualine/themes/dracula.lua | 69 +++++++++----------- lua/lualine/themes/everforest.lua | 80 +++++++++++------------ lua/lualine/themes/gruvbox.lua | 69 +++++++++----------- lua/lualine/themes/gruvbox_material.lua | 4 +- lua/lualine/themes/iceberg_dark.lua | 5 +- lua/lualine/themes/iceberg_light.lua | 5 +- lua/lualine/themes/jellybeans.lua | 5 +- lua/lualine/themes/material.lua | 52 +++++++-------- lua/lualine/themes/modus_vivendi.lua | 71 +++++++++------------ lua/lualine/themes/molokai.lua | 34 +++++----- lua/lualine/themes/nightfly.lua | 5 +- lua/lualine/themes/nord.lua | 33 +++++----- lua/lualine/themes/oceanicnext.lua | 5 +- lua/lualine/themes/onedark.lua | 34 +++++----- lua/lualine/themes/onelight.lua | 33 +++++----- lua/lualine/themes/palenight.lua | 1 - lua/lualine/themes/papercolor_dark.lua | 33 +++++----- lua/lualine/themes/papercolor_light.lua | 34 +++++----- lua/lualine/themes/powerline.lua | 46 ++++++-------- lua/lualine/themes/seoul256.lua | 5 +- lua/lualine/themes/solarized_dark.lua | 34 +++++----- lua/lualine/themes/solarized_light.lua | 34 +++++----- lua/lualine/themes/tomorrow.lua | 5 +- lua/lualine/themes/wombat.lua | 34 +++++----- 30 files changed, 378 insertions(+), 539 deletions(-) diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index 2033df6..84a3fc5 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -1,12 +1,5 @@ # Contributing to lualine.nvim - -### General - -please use lua-format before creating a pr :smile: - -### All contributions are very welcome but themes require a lot of work on my part if not done properly so here's a guide on how to do them. - ### Adding a theme * refer to example below to see how themes are defined @@ -30,10 +23,8 @@ But if unspecified then they default to c, b, a sections theme respectively . Adding theme is really easy in lua. Here is and example of a gruvbox theme. ```lua -local gruvbox = { } - local colors = { - black = "#282828", + black = '#282828', white = '#ebdbb2', red = '#fb4934', green = '#b8bb26', @@ -44,49 +35,38 @@ local colors = { lightgray = '#504945', inactivegray = '#7c6f64', } - -gruvbox.normal = { - -- gui parameter is optional and behaves the same way as in vim's highlight command - a = { bg = colors.gray, fg = colors.black, gui = "bold", }, - b = { bg = colors.lightgray, fg = colors.white, }, - c = { bg = colors.darkgray, fg = colors.gray } +return { + normal = { + a = {bg = colors.gray, fg = colors.black, gui = 'bold'}, + b = {bg = colors.lightgray, fg = colors.white}, + c = {bg = colors.darkgray, fg = colors.gray} + }, + insert = { + a = {bg = colors.blue, fg = colors.black, gui = 'bold'}, + b = {bg = colors.lightgray, fg = colors.white}, + c = {bg = colors.lightgray, fg = colors.white} + }, + visual = { + a = {bg = colors.yellow, fg = colors.black, gui = 'bold'}, + b = {bg = colors.lightgray, fg = colors.white}, + c = {bg = colors.inactivegray, fg = colors.black} + }, + replace = { + a = {bg = colors.red, fg = colors.black, gui = 'bold'}, + b = {bg = colors.lightgray, fg = colors.white}, + c = {bg = colors.black, fg = colors.white} + }, + command = { + a = {bg = colors.green, fg = colors.black, gui = 'bold'}, + b = {bg = colors.lightgray, fg = colors.white}, + c = {bg = colors.inactivegray, fg = colors.black} + }, + inactive = { + a = {bg = colors.darkgray, fg = colors.gray, gui = 'bold'}, + b = {bg = colors.darkgray, fg = colors.gray}, + c = {bg = colors.darkgray, fg = colors.gray} + } } - -gruvbox.insert = { - a = { bg = colors.blue, fg = colors.black, gui = "bold", }, - b = { bg = colors.lightgray, fg = colors.white, }, - c = { bg = colors.lightgray, fg = colors.white } -} - - -gruvbox.visual = { - a = { bg = colors.yellow, fg = colors.black, gui = "bold", }, - b = { bg = colors.lightgray, fg = colors.white, }, - c = { bg = colors.inactivegray, fg = colors.black }, -} - -gruvbox.replace = { - a = { bg = colors.red, fg = colors.black, gui = "bold", }, - b = { bg = colors.lightgray, fg = colors.white, }, - c = { bg = colors.black, fg = colors.white }, -} - -gruvbox.command = { - a = { bg = colors.green, fg = colors.black, gui = "bold", }, - b = { bg = colors.lightgray, fg = colors.white, }, - c = { bg = colors.inactivegray, fg = colors.black }, -} - --- you can assign one colorscheme to another, if a colorscheme is --- undefined it falls back to normal -gruvbox.terminal = gruvbox.normal - -gruvbox.inactive = { - a = { bg = colors.darkgray, fg = colors.gray, gui = "bold", }, - b = { bg = colors.darkgray, fg = colors.gray, }, - c = { bg = colors.darkgray, fg = colors.gray }, -} - require('lualine').setup {options = {theme = gruvbox}} ``` diff --git a/lua/lualine/themes/16color.lua b/lua/lualine/themes/16color.lua index 91819b3..f77577e 100644 --- a/lua/lualine/themes/16color.lua +++ b/lua/lualine/themes/16color.lua @@ -1,7 +1,6 @@ -- Copyright (c) 2020-2021 shadmansaleh -- MIT license, see LICENSE for more details. -- Credit itchyny, jackno (lightline) -local M = {} -- LuaFormatter off local colors = { black = '#000000', @@ -22,23 +21,18 @@ local colors = { white = '#ffffff', } -- LuaFormatter on - -M.normal = { - a = {fg = colors.white, bg = colors.blue, gui = 'bold'}, - b = {fg = colors.white, bg = colors.gray}, - c = {fg = colors.silver, bg = colors.black} +return { + normal = { + a = {fg = colors.white, bg = colors.blue, gui = 'bold'}, + b = {fg = colors.white, bg = colors.gray}, + c = {fg = colors.silver, bg = colors.black} + }, + insert = {a = {fg = colors.white, bg = colors.green, gui = 'bold'}}, + visual = {a = {fg = colors.white, bg = colors.purple, gui = 'bold'}}, + replace = {a = {fg = colors.white, bg = colors.red, gui = 'bold'}}, + inactive = { + a = {fg = colors.silver, bg = colors.gray, gui = 'bold'}, + b = {fg = colors.gray, bg = colors.black}, + c = {fg = colors.silver, bg = colors.black} + } } - -M.insert = {a = {fg = colors.white, bg = colors.green, gui = 'bold'}} - -M.visual = {a = {fg = colors.white, bg = colors.purple, gui = 'bold'}} - -M.replace = {a = {fg = colors.white, bg = colors.red, gui = 'bold'}} - -M.inactive = { - a = {fg = colors.silver, bg = colors.gray, gui = 'bold'}, - b = {fg = colors.gray, bg = colors.black}, - c = {fg = colors.silver, bg = colors.black} -} - -return M diff --git a/lua/lualine/themes/ayu_dark.lua b/lua/lualine/themes/ayu_dark.lua index 830fd1c..7f0bc39 100644 --- a/lua/lualine/themes/ayu_dark.lua +++ b/lua/lualine/themes/ayu_dark.lua @@ -14,8 +14,7 @@ local colors = { color9 = '#3e4b59', } -- LuaFormatter on - -local ayu_dark = { +return { visual = { a = {fg = colors.color2, bg = colors.color3, gui = 'bold'}, b = {fg = colors.color4, bg = colors.color5} @@ -39,5 +38,3 @@ local ayu_dark = { b = {fg = colors.color4, bg = colors.color5} } } - -return ayu_dark diff --git a/lua/lualine/themes/ayu_light.lua b/lua/lualine/themes/ayu_light.lua index 050519e..2ce14bc 100644 --- a/lua/lualine/themes/ayu_light.lua +++ b/lua/lualine/themes/ayu_light.lua @@ -14,8 +14,7 @@ local colors = { color9 = '#828C99', } -- LuaFormatter on - -local ayu_light = { +return { visual = { a = {fg = colors.color2, bg = colors.color3, gui = 'bold'}, b = {fg = colors.color4, bg = colors.color5} @@ -39,5 +38,3 @@ local ayu_light = { b = {fg = colors.color4, bg = colors.color5} } } - -return ayu_light diff --git a/lua/lualine/themes/ayu_mirage.lua b/lua/lualine/themes/ayu_mirage.lua index 23b0126..39320d8 100644 --- a/lua/lualine/themes/ayu_mirage.lua +++ b/lua/lualine/themes/ayu_mirage.lua @@ -14,8 +14,7 @@ local colors = { color9 = '#607080', } -- LuaFormatter on - -local ayu_mirage = { +return { visual = { a = {fg = colors.color2, bg = colors.color3, gui = 'bold'}, b = {fg = colors.color4, bg = colors.color5} @@ -39,5 +38,3 @@ local ayu_mirage = { b = {fg = colors.color4, bg = colors.color5} } } - -return ayu_mirage diff --git a/lua/lualine/themes/codedark.lua b/lua/lualine/themes/codedark.lua index 0167861..1d3c9a7 100644 --- a/lua/lualine/themes/codedark.lua +++ b/lua/lualine/themes/codedark.lua @@ -1,6 +1,5 @@ -- Copyright (c) 2020-2021 Shatur95 -- MIT license, see LICENSE for more details. -local codedark = {} -- LuaFormatter off local colors = { gray = '#3C3C3C', @@ -12,33 +11,28 @@ local colors = { green = '#608B4E', } -- LuaFormatter on - -codedark.normal = { - b = {fg = colors.green, bg = colors.black}, - a = {fg = colors.black, bg = colors.green, gui = 'bold'}, - c = {fg = colors.white, bg = colors.black} +return { + normal = { + b = {fg = colors.green, bg = colors.black}, + a = {fg = colors.black, bg = colors.green, gui = 'bold'}, + c = {fg = colors.white, bg = colors.black} + }, + visual = { + b = {fg = colors.pink, bg = colors.black}, + a = {fg = colors.black, bg = colors.pink, gui = 'bold'} + }, + inactive = { + b = {fg = colors.black, bg = colors.blue}, + a = {fg = colors.white, bg = colors.gray, gui = 'bold'} + }, + replace = { + b = {fg = colors.lightred, bg = colors.black}, + a = {fg = colors.black, bg = colors.lightred, gui = 'bold'}, + c = {fg = colors.white, bg = colors.black} + }, + insert = { + b = {fg = colors.blue, bg = colors.black}, + a = {fg = colors.black, bg = colors.blue, gui = 'bold'}, + c = {fg = colors.white, bg = colors.black} + } } - -codedark.visual = { - b = {fg = colors.pink, bg = colors.black}, - a = {fg = colors.black, bg = colors.pink, gui = 'bold'} -} - -codedark.inactive = { - b = {fg = colors.black, bg = colors.blue}, - a = {fg = colors.white, bg = colors.gray, gui = 'bold'} -} - -codedark.replace = { - b = {fg = colors.lightred, bg = colors.black}, - a = {fg = colors.black, bg = colors.lightred, gui = 'bold'}, - c = {fg = colors.white, bg = colors.black} -} - -codedark.insert = { - b = {fg = colors.blue, bg = colors.black}, - a = {fg = colors.black, bg = colors.blue, gui = 'bold'}, - c = {fg = colors.white, bg = colors.black} -} - -return codedark diff --git a/lua/lualine/themes/dracula.lua b/lua/lualine/themes/dracula.lua index 066646a..bcbba03 100644 --- a/lua/lualine/themes/dracula.lua +++ b/lua/lualine/themes/dracula.lua @@ -1,7 +1,6 @@ -- Copyright (c) 2020-2021 shadmansaleh -- MIT license, see LICENSE for more details. -- Credit itchyny, jackno (lightline) -local dracula = {} -- LuaFormatter off local colors = { gray = '#44475a', @@ -15,41 +14,35 @@ local colors = { black = '#282a36', } -- LuaFormatter on - -dracula.normal = { - a = {bg = colors.purple, fg = colors.black, gui = 'bold'}, - b = {bg = colors.lightgray, fg = colors.white}, - c = {bg = colors.gray, fg = colors.white} +return { + normal = { + a = {bg = colors.purple, fg = colors.black, gui = 'bold'}, + b = {bg = colors.lightgray, fg = colors.white}, + c = {bg = colors.gray, fg = colors.white} + }, + insert = { + a = {bg = colors.green, fg = colors.black, gui = 'bold'}, + b = {bg = colors.lightgray, fg = colors.white}, + c = {bg = colors.gray, fg = colors.white} + }, + visual = { + a = {bg = colors.yellow, fg = colors.black, gui = 'bold'}, + b = {bg = colors.lightgray, fg = colors.white}, + c = {bg = colors.gray, fg = colors.white} + }, + replace = { + a = {bg = colors.red, fg = colors.black, gui = 'bold'}, + b = {bg = colors.lightgray, fg = colors.white}, + c = {bg = colors.gray, fg = colors.white} + }, + command = { + a = {bg = colors.orange, fg = colors.black, gui = 'bold'}, + b = {bg = colors.lightgray, fg = colors.white}, + c = {bg = colors.gray, fg = colors.white} + }, + inactive = { + a = {bg = colors.gray, fg = colors.white, gui = 'bold'}, + b = {bg = colors.lightgray, fg = colors.white}, + c = {bg = colors.gray, fg = colors.white} + } } - -dracula.insert = { - a = {bg = colors.green, fg = colors.black, gui = 'bold'}, - b = {bg = colors.lightgray, fg = colors.white}, - c = {bg = colors.gray, fg = colors.white} -} - -dracula.visual = { - a = {bg = colors.yellow, fg = colors.black, gui = 'bold'}, - b = {bg = colors.lightgray, fg = colors.white}, - c = {bg = colors.gray, fg = colors.white} -} - -dracula.replace = { - a = {bg = colors.red, fg = colors.black, gui = 'bold'}, - b = {bg = colors.lightgray, fg = colors.white}, - c = {bg = colors.gray, fg = colors.white} -} - -dracula.command = { - a = {bg = colors.orange, fg = colors.black, gui = 'bold'}, - b = {bg = colors.lightgray, fg = colors.white}, - c = {bg = colors.gray, fg = colors.white} -} - -dracula.inactive = { - a = {bg = colors.gray, fg = colors.white, gui = 'bold'}, - b = {bg = colors.lightgray, fg = colors.white}, - c = {bg = colors.gray, fg = colors.white} -} - -return dracula diff --git a/lua/lualine/themes/everforest.lua b/lua/lualine/themes/everforest.lua index bd27e36..2656b58 100644 --- a/lua/lualine/themes/everforest.lua +++ b/lua/lualine/themes/everforest.lua @@ -1,6 +1,5 @@ -- Copyright (c) 2020-2021 gnuyent -- MIT license, see LICENSE for more details. -local everforest = {} -- LuaFormatter off local colors = { bg0 = '#323d43', @@ -15,47 +14,40 @@ local colors = { grey1 = '#868d80', } -- LuaFormatter on - -everforest.normal = { - a = {bg = colors.green, fg = colors.bg0, gui = 'bold'}, - b = {bg = colors.bg3, fg = colors.fg}, - c = {bg = colors.bg1, fg = colors.fg} +return { + normal = { + a = {bg = colors.green, fg = colors.bg0, gui = 'bold'}, + b = {bg = colors.bg3, fg = colors.fg}, + c = {bg = colors.bg1, fg = colors.fg} + }, + insert = { + a = {bg = colors.fg, fg = colors.bg0, gui = 'bold'}, + b = {bg = colors.bg3, fg = colors.fg}, + c = {bg = colors.bg1, fg = colors.fg} + }, + visual = { + a = {bg = colors.red, fg = colors.bg0, gui = 'bold'}, + b = {bg = colors.bg3, fg = colors.fg}, + c = {bg = colors.bg1, fg = colors.fg} + }, + replace = { + a = {bg = colors.orange, fg = colors.bg0, gui = 'bold'}, + b = {bg = colors.bg3, fg = colors.fg}, + c = {bg = colors.bg1, fg = colors.fg} + }, + command = { + a = {bg = colors.aqua, fg = colors.bg0, gui = 'bold'}, + b = {bg = colors.bg3, fg = colors.fg}, + c = {bg = colors.bg1, fg = colors.fg} + }, + terminal = { + a = {bg = colors.purple, fg = colors.bg0, gui = 'bold'}, + b = {bg = colors.bg3, fg = colors.fg}, + c = {bg = colors.bg1, fg = colors.fg} + }, + inactive = { + a = {bg = colors.bg1, fg = colors.grey1, gui = 'bold'}, + b = {bg = colors.bg1, fg = colors.grey1}, + c = {bg = colors.bg1, fg = colors.grey1} + } } - -everforest.insert = { - a = {bg = colors.fg, fg = colors.bg0, gui = 'bold'}, - b = {bg = colors.bg3, fg = colors.fg}, - c = {bg = colors.bg1, fg = colors.fg} -} - -everforest.visual = { - a = {bg = colors.red, fg = colors.bg0, gui = 'bold'}, - b = {bg = colors.bg3, fg = colors.fg}, - c = {bg = colors.bg1, fg = colors.fg} -} - -everforest.replace = { - a = {bg = colors.orange, fg = colors.bg0, gui = 'bold'}, - b = {bg = colors.bg3, fg = colors.fg}, - c = {bg = colors.bg1, fg = colors.fg} -} - -everforest.command = { - a = {bg = colors.aqua, fg = colors.bg0, gui = 'bold'}, - b = {bg = colors.bg3, fg = colors.fg}, - c = {bg = colors.bg1, fg = colors.fg} -} - -everforest.terminal = { - a = {bg = colors.purple, fg = colors.bg0, gui = 'bold'}, - b = {bg = colors.bg3, fg = colors.fg}, - c = {bg = colors.bg1, fg = colors.fg} -} - -everforest.inactive = { - a = {bg = colors.bg1, fg = colors.grey1, gui = 'bold'}, - b = {bg = colors.bg1, fg = colors.grey1}, - c = {bg = colors.bg1, fg = colors.grey1} -} - -return everforest diff --git a/lua/lualine/themes/gruvbox.lua b/lua/lualine/themes/gruvbox.lua index a2237ce..05dd333 100644 --- a/lua/lualine/themes/gruvbox.lua +++ b/lua/lualine/themes/gruvbox.lua @@ -1,6 +1,5 @@ -- Copyright (c) 2020-2021 hoob3rt -- MIT license, see LICENSE for more details. -local gruvbox = {} -- LuaFormatter off local colors = { black = '#282828', @@ -15,41 +14,35 @@ local colors = { inactivegray = '#7c6f64', } -- LuaFormatter on - -gruvbox.normal = { - a = {bg = colors.gray, fg = colors.black, gui = 'bold'}, - b = {bg = colors.lightgray, fg = colors.white}, - c = {bg = colors.darkgray, fg = colors.gray} +return { + normal = { + a = {bg = colors.gray, fg = colors.black, gui = 'bold'}, + b = {bg = colors.lightgray, fg = colors.white}, + c = {bg = colors.darkgray, fg = colors.gray} + }, + insert = { + a = {bg = colors.blue, fg = colors.black, gui = 'bold'}, + b = {bg = colors.lightgray, fg = colors.white}, + c = {bg = colors.lightgray, fg = colors.white} + }, + visual = { + a = {bg = colors.yellow, fg = colors.black, gui = 'bold'}, + b = {bg = colors.lightgray, fg = colors.white}, + c = {bg = colors.inactivegray, fg = colors.black} + }, + replace = { + a = {bg = colors.red, fg = colors.black, gui = 'bold'}, + b = {bg = colors.lightgray, fg = colors.white}, + c = {bg = colors.black, fg = colors.white} + }, + command = { + a = {bg = colors.green, fg = colors.black, gui = 'bold'}, + b = {bg = colors.lightgray, fg = colors.white}, + c = {bg = colors.inactivegray, fg = colors.black} + }, + inactive = { + a = {bg = colors.darkgray, fg = colors.gray, gui = 'bold'}, + b = {bg = colors.darkgray, fg = colors.gray}, + c = {bg = colors.darkgray, fg = colors.gray} + } } - -gruvbox.insert = { - a = {bg = colors.blue, fg = colors.black, gui = 'bold'}, - b = {bg = colors.lightgray, fg = colors.white}, - c = {bg = colors.lightgray, fg = colors.white} -} - -gruvbox.visual = { - a = {bg = colors.yellow, fg = colors.black, gui = 'bold'}, - b = {bg = colors.lightgray, fg = colors.white}, - c = {bg = colors.inactivegray, fg = colors.black} -} - -gruvbox.replace = { - a = {bg = colors.red, fg = colors.black, gui = 'bold'}, - b = {bg = colors.lightgray, fg = colors.white}, - c = {bg = colors.black, fg = colors.white} -} - -gruvbox.command = { - a = {bg = colors.green, fg = colors.black, gui = 'bold'}, - b = {bg = colors.lightgray, fg = colors.white}, - c = {bg = colors.inactivegray, fg = colors.black} -} - -gruvbox.inactive = { - a = {bg = colors.darkgray, fg = colors.gray, gui = 'bold'}, - b = {bg = colors.darkgray, fg = colors.gray}, - c = {bg = colors.darkgray, fg = colors.gray} -} - -return gruvbox diff --git a/lua/lualine/themes/gruvbox_material.lua b/lua/lualine/themes/gruvbox_material.lua index 3e1128a..2fff333 100644 --- a/lua/lualine/themes/gruvbox_material.lua +++ b/lua/lualine/themes/gruvbox_material.lua @@ -14,8 +14,7 @@ local colors = { color9 = '#ea6962', } -- LuaFormatter on - -local M = { +return { normal = { a = {fg = colors.fg1, bg = colors.color4, gui = 'bold'}, b = {fg = colors.fg2, bg = colors.color2}, @@ -28,4 +27,3 @@ local M = { terminal = {a = {fg = colors.fg1, bg = colors.color8, gui = 'bold'}}, visual = {a = {fg = colors.fg1, bg = colors.color9, gui = 'bold'}} } -return M diff --git a/lua/lualine/themes/iceberg_dark.lua b/lua/lualine/themes/iceberg_dark.lua index 15164e3..21f53d1 100644 --- a/lua/lualine/themes/iceberg_dark.lua +++ b/lua/lualine/themes/iceberg_dark.lua @@ -16,8 +16,7 @@ local colors = { color15 = '#84a0c6', } -- LuaFormatter on - -local iceberg = { +return { visual = { a = {fg = colors.color2, bg = colors.color3, gui = 'bold'}, b = {fg = colors.color4, bg = colors.color5} @@ -41,5 +40,3 @@ local iceberg = { b = {fg = colors.color4, bg = colors.color5} } } - -return iceberg diff --git a/lua/lualine/themes/iceberg_light.lua b/lua/lualine/themes/iceberg_light.lua index e05b3c8..21a27c1 100644 --- a/lua/lualine/themes/iceberg_light.lua +++ b/lua/lualine/themes/iceberg_light.lua @@ -14,8 +14,7 @@ local colors = { color2 = '#c57339', } -- LuaFormatter on - -local iceberg = { +return { replace = { b = {fg = colors.color0, bg = colors.color1}, a = {fg = colors.color0, bg = colors.color2, gui = 'bold'} @@ -39,5 +38,3 @@ local iceberg = { a = {fg = colors.color0, bg = colors.color11, gui = 'bold'} } } - -return iceberg diff --git a/lua/lualine/themes/jellybeans.lua b/lua/lualine/themes/jellybeans.lua index 4828a35..5816eb6 100644 --- a/lua/lualine/themes/jellybeans.lua +++ b/lua/lualine/themes/jellybeans.lua @@ -15,8 +15,7 @@ local colors = { color14 = '#99ad6a', } -- LuaFormatter on - -local jellybeans = { +return { visual = { a = {fg = colors.color2, bg = colors.color3, gui = 'bold'}, b = {fg = colors.color4, bg = colors.color5} @@ -40,5 +39,3 @@ local jellybeans = { b = {fg = colors.color4, bg = colors.color5} } } - -return jellybeans diff --git a/lua/lualine/themes/material.lua b/lua/lualine/themes/material.lua index 35bb845..f216ed8 100644 --- a/lua/lualine/themes/material.lua +++ b/lua/lualine/themes/material.lua @@ -1,7 +1,6 @@ -- Copyright (c) 2020-2021 shadmansaleh -- MIT license, see LICENSE for more details. -- Credit: Lokesh Krishna(lightline) -local M = {} -- LuaFormatter off local colors = { fg = '#eeffff', @@ -17,32 +16,27 @@ local colors = { gray3 = '#515559', } -- LuaFormatter on - -M.normal = { - a = {fg = colors.bg, bg = colors.blue, gui = 'bold'}, - b = {fg = colors.fg, bg = colors.gray3}, - c = {fg = colors.fg, bg = colors.gray2} +return { + normal = { + a = {fg = colors.bg, bg = colors.blue, gui = 'bold'}, + b = {fg = colors.fg, bg = colors.gray3}, + c = {fg = colors.fg, bg = colors.gray2} + }, + insert = { + a = {fg = colors.bg, bg = colors.green, gui = 'bold'}, + b = {fg = colors.fg, bg = colors.gray3} + }, + visual = { + a = {fg = colors.bg, bg = colors.purple, gui = 'bold'}, + b = {fg = colors.fg, bg = colors.gray3} + }, + replace = { + a = {fg = colors.bg, bg = colors.red1, gui = 'bold'}, + b = {fg = colors.fg, bg = colors.gray3} + }, + inactive = { + a = {fg = colors.fg, bg = colors.bg, gui = 'bold'}, + b = {fg = colors.fg, bg = colors.bg}, + c = {fg = colors.fg, bg = colors.gray2} + } } - -M.insert = { - a = {fg = colors.bg, bg = colors.green, gui = 'bold'}, - b = {fg = colors.fg, bg = colors.gray3} -} - -M.visual = { - a = {fg = colors.bg, bg = colors.purple, gui = 'bold'}, - b = {fg = colors.fg, bg = colors.gray3} -} - -M.replace = { - a = {fg = colors.bg, bg = colors.red1, gui = 'bold'}, - b = {fg = colors.fg, bg = colors.gray3} -} - -M.inactive = { - a = {fg = colors.fg, bg = colors.bg, gui = 'bold'}, - b = {fg = colors.fg, bg = colors.bg}, - c = {fg = colors.fg, bg = colors.gray2} -} - -return M diff --git a/lua/lualine/themes/modus_vivendi.lua b/lua/lualine/themes/modus_vivendi.lua index b592ecb..40fa003 100644 --- a/lua/lualine/themes/modus_vivendi.lua +++ b/lua/lualine/themes/modus_vivendi.lua @@ -1,6 +1,5 @@ -- Copyright (c) 2020-2021 ronniedroid -- MIT license, see LICENSE for more details. -local modus_vivendi = {} -- LuaFormatter off local colors = { black = '#000000', @@ -15,43 +14,35 @@ local colors = { lightgray = '#434343' } -- LuaFormatter on - -modus_vivendi.normal = { - a = {bg = colors.blue, fg = colors.lightgray, gui = 'bold'}, - b = {bg = colors.lightgray, fg = colors.blue}, - c = {bg = colors.gray, fg = colors.white} +return { + normal = { + a = {bg = colors.blue, fg = colors.lightgray, gui = 'bold'}, + b = {bg = colors.lightgray, fg = colors.blue}, + c = {bg = colors.gray, fg = colors.white} + }, + insert = { + a = {bg = colors.cyan, fg = colors.lightgray, gui = 'bold'}, + b = {bg = colors.lightgray, fg = colors.cyan}, + c = {bg = colors.gray, fg = colors.white} + }, + visual = { + a = {bg = colors.magenta, fg = colors.lightgray, gui = 'bold'}, + b = {bg = colors.lightgray, fg = colors.magenta}, + c = {bg = colors.gray, fg = colors.white} + }, + replace = { + a = {bg = colors.red, fg = colors.lightgray, gui = 'bold'}, + b = {bg = colors.lightgray, fg = colors.red}, + c = {bg = colors.gray, fg = colors.white} + }, + command = { + a = {bg = colors.green, fg = colors.lightgray, gui = 'bold'}, + b = {bg = colors.lightgray, fg = colors.green}, + c = {bg = colors.gray, fg = colors.white} + }, + inactive = { + a = {bg = colors.darkgray, fg = colors.lightgray, gui = 'bold'}, + b = {bg = colors.darkgray, fg = colors.lightgray}, + c = {bg = colors.darkgray, fg = colors.lightgray} + } } - -modus_vivendi.insert = { - a = {bg = colors.cyan, fg = colors.lightgray, gui = 'bold'}, - b = {bg = colors.lightgray, fg = colors.cyan}, - c = {bg = colors.gray, fg = colors.white} -} - -modus_vivendi.visual = { - a = {bg = colors.magenta, fg = colors.lightgray, gui = 'bold'}, - b = {bg = colors.lightgray, fg = colors.magenta}, - c = {bg = colors.gray, fg = colors.white} -} - -modus_vivendi.replace = { - a = {bg = colors.red, fg = colors.lightgray, gui = 'bold'}, - b = {bg = colors.lightgray, fg = colors.red}, - c = {bg = colors.gray, fg = colors.white} -} - -modus_vivendi.command = { - a = {bg = colors.green, fg = colors.lightgray, gui = 'bold'}, - b = {bg = colors.lightgray, fg = colors.green}, - c = {bg = colors.gray, fg = colors.white} -} - -modus_vivendi.terminal = modus_vivendi.normal - -modus_vivendi.inactive = { - a = {bg = colors.darkgray, fg = colors.lightgray, gui = 'bold'}, - b = {bg = colors.darkgray, fg = colors.lightgray}, - c = {bg = colors.darkgray, fg = colors.lightgray} -} - -return modus_vivendi diff --git a/lua/lualine/themes/molokai.lua b/lua/lualine/themes/molokai.lua index 09bc476..b6cf8a6 100644 --- a/lua/lualine/themes/molokai.lua +++ b/lua/lualine/themes/molokai.lua @@ -1,7 +1,6 @@ -- Copyright (c) 2020-2021 shadmansaleh -- MIT license, see LICENSE for more details. -- Credit: challsted(lightline) -local molokai = {} -- LuaFormatter off local colors = { black = '#232526', @@ -15,23 +14,18 @@ local colors = { yellow = '#e6db74', } -- LuaFormatter on - -molokai.normal = { - a = {fg = colors.black, bg = colors.cyan, gui = 'bold'}, - b = {fg = colors.black, bg = colors.pink}, - c = {fg = colors.orange, bg = colors.black} +return { + normal = { + a = {fg = colors.black, bg = colors.cyan, gui = 'bold'}, + b = {fg = colors.black, bg = colors.pink}, + c = {fg = colors.orange, bg = colors.black} + }, + insert = {a = {fg = colors.black, bg = colors.green, gui = 'bold'}}, + visual = {a = {fg = colors.black, bg = colors.yellow, gui = 'bold'}}, + replace = {a = {fg = colors.black, bg = colors.red, gui = 'bold'}}, + inactive = { + a = {fg = colors.pink, bg = colors.black, gui = 'bold'}, + b = {fg = colors.white, bg = colors.pink}, + c = {fg = colors.gray, bg = colors.black} + } } - -molokai.insert = {a = {fg = colors.black, bg = colors.green, gui = 'bold'}} - -molokai.visual = {a = {fg = colors.black, bg = colors.yellow, gui = 'bold'}} - -molokai.replace = {a = {fg = colors.black, bg = colors.red, gui = 'bold'}} - -molokai.inactive = { - a = {fg = colors.pink, bg = colors.black, gui = 'bold'}, - b = {fg = colors.white, bg = colors.pink}, - c = {fg = colors.gray, bg = colors.black} -} - -return molokai diff --git a/lua/lualine/themes/nightfly.lua b/lua/lualine/themes/nightfly.lua index 3e411ce..5121140 100644 --- a/lua/lualine/themes/nightfly.lua +++ b/lua/lualine/themes/nightfly.lua @@ -11,8 +11,7 @@ local colors = { color2 = '#c3ccdc', } -- LuaFormatter on - -local nightfly = { +return { replace = { a = {fg = colors.color0, bg = colors.color1, gui = 'bold'}, b = {fg = colors.color2, bg = colors.color3} @@ -36,5 +35,3 @@ local nightfly = { b = {fg = colors.color2, bg = colors.color3} } } - -return nightfly diff --git a/lua/lualine/themes/nord.lua b/lua/lualine/themes/nord.lua index 7d6ac7b..332ebf5 100644 --- a/lua/lualine/themes/nord.lua +++ b/lua/lualine/themes/nord.lua @@ -1,6 +1,5 @@ -- Copyright (c) 2020-2021 shadmansaleh -- MIT license, see LICENSE for more details. -local nord = {} -- LuaFormatter off local colors = { nord1 = '#3B4252', @@ -12,23 +11,19 @@ local colors = { nord13 = '#EBCB8B', } -- LuaFormatter on - -nord.normal = { - a = {fg = colors.nord1, bg = colors.nord8, gui = 'bold'}, - b = {fg = colors.nord5, bg = colors.nord1}, - c = {fg = colors.nord5, bg = colors.nord3} +return { + normal = { + a = {fg = colors.nord1, bg = colors.nord8, gui = 'bold'}, + b = {fg = colors.nord5, bg = colors.nord1}, + c = {fg = colors.nord5, bg = colors.nord3} + }, + insert = {a = {fg = colors.nord1, bg = colors.nord6, gui = 'bold'}}, + visual = {a = {fg = colors.nord1, bg = colors.nord7, gui = 'bold'}}, + replace = {a = {fg = colors.nord1, bg = colors.nord13, gui = 'bold'}}, + inactive = { + a = {fg = colors.nord1, bg = colors.nord8, gui = 'bold'}, + b = {fg = colors.nord5, bg = colors.nord1}, + c = {fg = colors.nord5, bg = colors.nord1} + } } -nord.insert = {a = {fg = colors.nord1, bg = colors.nord6, gui = 'bold'}} - -nord.visual = {a = {fg = colors.nord1, bg = colors.nord7, gui = 'bold'}} - -nord.replace = {a = {fg = colors.nord1, bg = colors.nord13, gui = 'bold'}} - -nord.inactive = { - a = {fg = colors.nord1, bg = colors.nord8, gui = 'bold'}, - b = {fg = colors.nord5, bg = colors.nord1}, - c = {fg = colors.nord5, bg = colors.nord1} -} - -return nord diff --git a/lua/lualine/themes/oceanicnext.lua b/lua/lualine/themes/oceanicnext.lua index d501d3e..19adaca 100644 --- a/lua/lualine/themes/oceanicnext.lua +++ b/lua/lualine/themes/oceanicnext.lua @@ -14,8 +14,7 @@ local colors = { color7 = '#ec5f67', } -- LuaFormatter on - -local oceanicnext = { +return { insert = { a = {fg = colors.color0, bg = colors.color1, gui = 'bold'}, b = {fg = colors.color0, bg = colors.color2}, @@ -42,5 +41,3 @@ local oceanicnext = { c = {fg = colors.color0, bg = colors.color3} } } - -return oceanicnext diff --git a/lua/lualine/themes/onedark.lua b/lua/lualine/themes/onedark.lua index 7b897ba..011b668 100644 --- a/lua/lualine/themes/onedark.lua +++ b/lua/lualine/themes/onedark.lua @@ -1,7 +1,6 @@ -- Copyright (c) 2020-2021 shadmansaleh -- MIT license, see LICENSE for more details. -- Credit: Zoltan Dalmadi(lightline) -local M = {} -- LuaFormatter off local colors = { blue = '#61afef', @@ -17,23 +16,18 @@ local colors = { gray3 = '#3e4452', } -- LuaFormatter on - -M.normal = { - a = {fg = colors.bg, bg = colors.green, gui = 'bold'}, - b = {fg = colors.fg, bg = colors.gray3}, - c = {fg = colors.fg, bg = colors.gray2} +return { + normal = { + a = {fg = colors.bg, bg = colors.green, gui = 'bold'}, + b = {fg = colors.fg, bg = colors.gray3}, + c = {fg = colors.fg, bg = colors.gray2} + }, + insert = {a = {fg = colors.bg, bg = colors.blue, gui = 'bold'}}, + visual = {a = {fg = colors.bg, bg = colors.purple, gui = 'bold'}}, + replace = {a = {fg = colors.bg, bg = colors.red1, gui = 'bold'}}, + inactive = { + a = {fg = colors.gray1, bg = colors.bg, gui = 'bold'}, + b = {fg = colors.gray1, bg = colors.bg}, + c = {fg = colors.gray1, bg = colors.gray2} + } } - -M.insert = {a = {fg = colors.bg, bg = colors.blue, gui = 'bold'}} - -M.visual = {a = {fg = colors.bg, bg = colors.purple, gui = 'bold'}} - -M.replace = {a = {fg = colors.bg, bg = colors.red1, gui = 'bold'}} - -M.inactive = { - a = {fg = colors.gray1, bg = colors.bg, gui = 'bold'}, - b = {fg = colors.gray1, bg = colors.bg}, - c = {fg = colors.gray1, bg = colors.gray2} -} - -return M diff --git a/lua/lualine/themes/onelight.lua b/lua/lualine/themes/onelight.lua index 60c9e0b..9942c9d 100644 --- a/lua/lualine/themes/onelight.lua +++ b/lua/lualine/themes/onelight.lua @@ -1,7 +1,6 @@ -- Copyright (c) 2020-2021 shadmansaleh -- MIT license, see LICENSE for more details. -- Credit: Zoltan Dalmadi(lightline) -local M = {} -- LuaFormatter off local colors = { blue = '#61afef', @@ -17,23 +16,19 @@ local colors = { gray3 = '#d0d0d0', } -- LuaFormatter on +return { + normal = { + a = {fg = colors.bg, bg = colors.green, gui = 'bold'}, + b = {fg = colors.fg, bg = colors.gray3}, + c = {fg = colors.fg, bg = colors.gray2} + }, + insert = {a = {fg = colors.bg, bg = colors.blue, gui = 'bold'}}, + visual = {a = {fg = colors.bg, bg = colors.purple, gui = 'bold'}}, + replace = {a = {fg = colors.bg, bg = colors.red1, gui = 'bold'}}, + inactive = { + a = {fg = colors.bg, bg = colors.gray3, gui = 'bold'}, + b = {fg = colors.bg, bg = colors.gray3}, + c = {fg = colors.gray3, bg = colors.gray2} + } -M.normal = { - a = {fg = colors.bg, bg = colors.green, gui = 'bold'}, - b = {fg = colors.fg, bg = colors.gray3}, - c = {fg = colors.fg, bg = colors.gray2} } - -M.insert = {a = {fg = colors.bg, bg = colors.blue, gui = 'bold'}} - -M.visual = {a = {fg = colors.bg, bg = colors.purple, gui = 'bold'}} - -M.replace = {a = {fg = colors.bg, bg = colors.red1, gui = 'bold'}} - -M.inactive = { - a = {fg = colors.bg, bg = colors.gray3, gui = 'bold'}, - b = {fg = colors.bg, bg = colors.gray3}, - c = {fg = colors.gray3, bg = colors.gray2} -} - -return M diff --git a/lua/lualine/themes/palenight.lua b/lua/lualine/themes/palenight.lua index 2fe3c50..9130fd7 100644 --- a/lua/lualine/themes/palenight.lua +++ b/lua/lualine/themes/palenight.lua @@ -21,7 +21,6 @@ local colors = { black = '#292D3E', } -- LuaFormatter on - return { normal = { a = {fg = colors.black, bg = colors.purple, gui = 'bold'}, diff --git a/lua/lualine/themes/papercolor_dark.lua b/lua/lualine/themes/papercolor_dark.lua index d8d868e..8ea6883 100644 --- a/lua/lualine/themes/papercolor_dark.lua +++ b/lua/lualine/themes/papercolor_dark.lua @@ -1,7 +1,6 @@ -- Copyright (c) 2020-2021 shadmansaleh -- MIT license, see LICENSE for more details. -- Credit: TKNGUE(lightline) -local M = {} -- LuaFormatter off local colors = { red = '#df0000', @@ -26,23 +25,19 @@ local colors = { visual_bg = '#8787af', } -- LuaFormatter on +return { + normal = { + a = {fg = colors.foreground, bg = colors.background, gui = 'bold'}, + b = {fg = colors.statusline_active_fg, bg = colors.status}, + c = {fg = colors.statusline_active_fg, bg = colors.statusline_active_bg} + }, + insert = {a = {fg = colors.background, bg = colors.blue, gui = 'bold'}}, + visual = {a = {fg = colors.visual_fg, bg = colors.visual_bg, gui = 'bold'}}, + replace = {a = {fg = colors.background, bg = colors.pink, gui = 'bold'}}, + inactive = { + a = {fg = colors.foreground, bg = colors.background, gui = 'bold'}, + b = {fg = colors.foreground, bg = colors.background}, + c = {fg = colors.foreground, bg = colors.background} + } -M.normal = { - a = {fg = colors.foreground, bg = colors.background, gui = 'bold'}, - b = {fg = colors.statusline_active_fg, bg = colors.status}, - c = {fg = colors.statusline_active_fg, bg = colors.statusline_active_bg} } - -M.insert = {a = {fg = colors.background, bg = colors.blue, gui = 'bold'}} - -M.visual = {a = {fg = colors.visual_fg, bg = colors.visual_bg, gui = 'bold'}} - -M.replace = {a = {fg = colors.background, bg = colors.pink, gui = 'bold'}} - -M.inactive = { - a = {fg = colors.foreground, bg = colors.background, gui = 'bold'}, - b = {fg = colors.foreground, bg = colors.background}, - c = {fg = colors.foreground, bg = colors.background} -} - -return M diff --git a/lua/lualine/themes/papercolor_light.lua b/lua/lualine/themes/papercolor_light.lua index a33cd3b..b936a01 100644 --- a/lua/lualine/themes/papercolor_light.lua +++ b/lua/lualine/themes/papercolor_light.lua @@ -1,7 +1,6 @@ -- Copyright (c) 2020-2021 shadmansaleh -- MIT license, see LICENSE for more details. -- Credit: TKNGUE(lightline) -local M = {} -- LuaFormatter off local colors = { red = '#df0000', @@ -25,22 +24,19 @@ local colors = { } -- LuaFormatter on -M.normal = { - a = {fg = colors.foreground, bg = colors.background, gui = 'bold'}, - b = {fg = colors.statusline_active_fg, bg = colors.status}, - c = {fg = colors.statusline_active_fg, bg = colors.statusline_active_bg} +return { + normal = { + a = {fg = colors.foreground, bg = colors.background, gui = 'bold'}, + b = {fg = colors.statusline_active_fg, bg = colors.status}, + c = {fg = colors.statusline_active_fg, bg = colors.statusline_active_bg} + }, + insert = {a = {fg = colors.blue, bg = colors.background, gui = 'bold'}}, + visual = {a = {fg = colors.background, bg = colors.orange, gui = 'bold'}}, + replace = {a = {fg = colors.background, bg = colors.pink, gui = 'bold'}}, + inactive = { + a = {fg = colors.foreground, bg = colors.background, gui = 'bold'}, + b = {fg = colors.foreground, bg = colors.background}, + c = {fg = colors.foreground, bg = colors.background} + } + } - -M.insert = {a = {fg = colors.blue, bg = colors.background, gui = 'bold'}} - -M.visual = {a = {fg = colors.background, bg = colors.orange, gui = 'bold'}} - -M.replace = {a = {fg = colors.background, bg = colors.pink, gui = 'bold'}} - -M.inactive = { - a = {fg = colors.foreground, bg = colors.background, gui = 'bold'}, - b = {fg = colors.foreground, bg = colors.background}, - c = {fg = colors.foreground, bg = colors.background} -} - -return M diff --git a/lua/lualine/themes/powerline.lua b/lua/lualine/themes/powerline.lua index 35f35aa..a1674e6 100644 --- a/lua/lualine/themes/powerline.lua +++ b/lua/lualine/themes/powerline.lua @@ -1,6 +1,5 @@ -- Copyright (c) 2020-2021 shadmansaleh -- MIT license, see LICENSE for more details. -local powerline = {} -- LuaFormatter off local Colors = { white = '#ffffff', @@ -20,31 +19,22 @@ local Colors = { gray10 = '#f0f0f0', } -- LuaFormatter on - -powerline.normal = { - a = {fg = Colors.darkestgreen, bg = Colors.brightgreen, gui = 'bold'}, - b = {fg = Colors.gray10, bg = Colors.gray5}, - c = {fg = Colors.gray7, bg = Colors.gray2} +return { + normal = { + a = {fg = Colors.darkestgreen, bg = Colors.brightgreen, gui = 'bold'}, + b = {fg = Colors.gray10, bg = Colors.gray5}, + c = {fg = Colors.gray7, bg = Colors.gray2} + }, + insert = { + a = {fg = Colors.darkestcyan, bg = Colors.white, gui = 'bold'}, + b = {fg = Colors.darkestcyan, bg = Colors.mediumcyan}, + c = {fg = Colors.mediumcyan, bg = Colors.darkestblue} + }, + visual = {a = {fg = Colors.darkred, bg = Colors.brightorange, gui = 'bold'}}, + replace = {a = {fg = Colors.white, bg = Colors.brightred, gui = 'bold'}}, + inactive = { + a = {fg = Colors.gray1, bg = Colors.gray5, gui = 'bold'}, + b = {fg = Colors.gray1, bg = Colors.gray5}, + c = {bg = Colors.gray1, fg = Colors.gray5} + } } - -powerline.insert = { - a = {fg = Colors.darkestcyan, bg = Colors.white, gui = 'bold'}, - b = {fg = Colors.darkestcyan, bg = Colors.mediumcyan}, - c = {fg = Colors.mediumcyan, bg = Colors.darkestblue} -} - -powerline.visual = { - a = {fg = Colors.darkred, bg = Colors.brightorange, gui = 'bold'} -} - -powerline.replace = { - a = {fg = Colors.white, bg = Colors.brightred, gui = 'bold'} -} - -powerline.inactive = { - a = {fg = Colors.gray1, bg = Colors.gray5, gui = 'bold'}, - b = {fg = Colors.gray1, bg = Colors.gray5}, - c = {bg = Colors.gray1, fg = Colors.gray5} -} - -return powerline diff --git a/lua/lualine/themes/seoul256.lua b/lua/lualine/themes/seoul256.lua index b4c01d4..9e47d16 100644 --- a/lua/lualine/themes/seoul256.lua +++ b/lua/lualine/themes/seoul256.lua @@ -15,8 +15,7 @@ local colors = { color4 = '#30302c', } -- LuaFormatter on - -local seoul256 = { +return { visual = { b = {fg = colors.color0, bg = colors.color1}, a = {fg = colors.color4, bg = colors.color5, gui = 'bold'} @@ -40,5 +39,3 @@ local seoul256 = { a = {fg = colors.color4, bg = colors.color14, gui = 'bold'} } } - -return seoul256 diff --git a/lua/lualine/themes/solarized_dark.lua b/lua/lualine/themes/solarized_dark.lua index 4f8f253..9cca40d 100644 --- a/lua/lualine/themes/solarized_dark.lua +++ b/lua/lualine/themes/solarized_dark.lua @@ -1,7 +1,6 @@ -- Copyright (c) 2020-2021 shadmansaleh -- MIT license, see LICENSE for more details. -- Credit: itchyny(lightline) -local M = {} -- LuaFormatter off local colors = { base03 = '#002b36', @@ -22,23 +21,18 @@ local colors = { green = '#859900', } -- LuaFormatter on - -M.normal = { - a = {fg = colors.base03, bg = colors.blue, gui = 'bold'}, - b = {fg = colors.base03, bg = colors.base1}, - c = {fg = colors.base1, bg = colors.base02} +return { + normal = { + a = {fg = colors.base03, bg = colors.blue, gui = 'bold'}, + b = {fg = colors.base03, bg = colors.base1}, + c = {fg = colors.base1, bg = colors.base02} + }, + insert = {a = {fg = colors.base03, bg = colors.green, gui = 'bold'}}, + visual = {a = {fg = colors.base03, bg = colors.magenta, gui = 'bold'}}, + replace = {a = {fg = colors.base03, bg = colors.red, gui = 'bold'}}, + inactive = { + a = {fg = colors.base0, bg = colors.base02, gui = 'bold'}, + b = {fg = colors.base03, bg = colors.base00}, + c = {fg = colors.base01, bg = colors.base02} + } } - -M.insert = {a = {fg = colors.base03, bg = colors.green, gui = 'bold'}} - -M.visual = {a = {fg = colors.base03, bg = colors.magenta, gui = 'bold'}} - -M.replace = {a = {fg = colors.base03, bg = colors.red, gui = 'bold'}} - -M.inactive = { - a = {fg = colors.base0, bg = colors.base02, gui = 'bold'}, - b = {fg = colors.base03, bg = colors.base00}, - c = {fg = colors.base01, bg = colors.base02} -} - -return M diff --git a/lua/lualine/themes/solarized_light.lua b/lua/lualine/themes/solarized_light.lua index e3635df..41406bf 100644 --- a/lua/lualine/themes/solarized_light.lua +++ b/lua/lualine/themes/solarized_light.lua @@ -1,7 +1,6 @@ -- Copyright (c) 2020-2021 shadmansaleh -- MIT license, see LICENSE for more details. -- Credit: itchyny(lightline) -local M = {} -- LuaFormatter off local colors = { base3 = '#002b36', @@ -22,23 +21,18 @@ local colors = { green = '#859900', } -- LuaFormatter on - -M.normal = { - a = {fg = colors.base03, bg = colors.blue, gui = 'bold'}, - b = {fg = colors.base03, bg = colors.base1}, - c = {fg = colors.base1, bg = colors.base02} +return { + normal = { + a = {fg = colors.base03, bg = colors.blue, gui = 'bold'}, + b = {fg = colors.base03, bg = colors.base1}, + c = {fg = colors.base1, bg = colors.base02} + }, + insert = {a = {fg = colors.base03, bg = colors.green, gui = 'bold'}}, + visual = {a = {fg = colors.base03, bg = colors.magenta, gui = 'bold'}}, + replace = {a = {fg = colors.base03, bg = colors.red, gui = 'bold'}}, + inactive = { + a = {fg = colors.base0, bg = colors.base02, gui = 'bold'}, + b = {fg = colors.base03, bg = colors.base00}, + c = {fg = colors.base01, bg = colors.base02} + } } - -M.insert = {a = {fg = colors.base03, bg = colors.green, gui = 'bold'}} - -M.visual = {a = {fg = colors.base03, bg = colors.magenta, gui = 'bold'}} - -M.replace = {a = {fg = colors.base03, bg = colors.red, gui = 'bold'}} - -M.inactive = { - a = {fg = colors.base0, bg = colors.base02, gui = 'bold'}, - b = {fg = colors.base03, bg = colors.base00}, - c = {fg = colors.base01, bg = colors.base02} -} - -return M diff --git a/lua/lualine/themes/tomorrow.lua b/lua/lualine/themes/tomorrow.lua index 8836c9a..826b5a0 100644 --- a/lua/lualine/themes/tomorrow.lua +++ b/lua/lualine/themes/tomorrow.lua @@ -17,8 +17,7 @@ local colors = { color11 = '#f5871f', } -- LuaFormatter on - -local tomorrow = { +return { inactive = { a = {fg = colors.color0, bg = colors.color1, gui = 'bold'}, b = {fg = colors.color2, bg = colors.color3}, @@ -42,5 +41,3 @@ local tomorrow = { b = {fg = colors.color5, bg = colors.color6} } } - -return tomorrow diff --git a/lua/lualine/themes/wombat.lua b/lua/lualine/themes/wombat.lua index d88e894..4fb625c 100644 --- a/lua/lualine/themes/wombat.lua +++ b/lua/lualine/themes/wombat.lua @@ -1,7 +1,6 @@ -- Copyright (c) 2020-2021 shadmansaleh -- MIT license, see LICENSE for more details. -- Credit: itchyny(lightline) -local M = {} -- LuaFormatter off local colors = { base03 = '#242424', @@ -22,23 +21,18 @@ local colors = { green = '#95e454', } -- LuaFormatter on - -M.normal = { - a = {fg = colors.base02, bg = colors.blue, gui = 'bold'}, - b = {fg = colors.base02, bg = colors.base0}, - c = {fg = colors.base2, bg = colors.base02} +return { + normal = { + a = {fg = colors.base02, bg = colors.blue, gui = 'bold'}, + b = {fg = colors.base02, bg = colors.base0}, + c = {fg = colors.base2, bg = colors.base02} + }, + insert = {a = {fg = colors.base02, bg = colors.green, gui = 'bold'}}, + visual = {a = {fg = colors.base02, bg = colors.magenta, gui = 'bold'}}, + replace = {a = {fg = colors.base023, bg = colors.red, gui = 'bold'}}, + inactive = { + a = {fg = colors.base1, bg = colors.base02, gui = 'bold'}, + b = {fg = colors.base023, bg = colors.base01}, + c = {fg = colors.base1, bg = colors.base023} + } } - -M.insert = {a = {fg = colors.base02, bg = colors.green, gui = 'bold'}} - -M.visual = {a = {fg = colors.base02, bg = colors.magenta, gui = 'bold'}} - -M.replace = {a = {fg = colors.base023, bg = colors.red, gui = 'bold'}} - -M.inactive = { - a = {fg = colors.base1, bg = colors.base02, gui = 'bold'}, - b = {fg = colors.base023, bg = colors.base01}, - c = {fg = colors.base1, bg = colors.base023} -} - -return M