Skip to content

Commit

Permalink
fix(theme): remove day configuration
Browse files Browse the repository at this point in the history
  • Loading branch information
pauchiner committed Feb 14, 2024
1 parent aebafc0 commit c780324
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 15 deletions.
1 change: 0 additions & 1 deletion lua/pastelnight/colors.lua
Original file line number Diff line number Diff line change
Expand Up @@ -96,7 +96,6 @@ function M.setup(opts)
colors.fg = colors.base

util.bg = colors.bg
util.day_brightness = config.options.day_brightness

colors.black = util.darken(colors.bg, 0.8, '#000000')
colors.border = colors.black
Expand Down
17 changes: 4 additions & 13 deletions lua/pastelnight/config.lua
Original file line number Diff line number Diff line change
Expand Up @@ -4,11 +4,8 @@ local M = {}
---@field on_colors fun(colors: ColorScheme)
---@field on_highlights fun(highlights: Highlights, colors: ColorScheme)
local defaults = {
--- The theme comes in three styles, `storm`, a darker variant `night` and `day`.
style = 'storm',

--- The theme is used when the background is set to light.
light_style = 'day',
--- The theme comes in two styles, `default` and `high-contrast`.
style = 'default',

--- Enable this to disable setting the background color
transparent = false,
Expand All @@ -32,9 +29,6 @@ local defaults = {
--- Set a darker background on sidebar-like windows. For example: `["qf", "vista_kind", "terminal", "packer"]`
sidebars = { 'qf', 'help' },

--- Adjusts the brightness of the colors of the **Day** style. Number between 0 and 1, from dull to vibrant colors.
day_brightness = 0.3,

--- Enabling this option, will hide inactive statuslines and replace them with a thin border instead. Should work with the standard **StatusLine** and **LuaLine**.
hide_inactive_statusline = false,

Expand All @@ -56,7 +50,8 @@ local defaults = {
---@param colors ColorScheme
---@diagnostic disable-next-line: unused-local
on_highlights = function(highlights, colors) end,
use_background = true, -- can be light/dark/auto. When auto, background will be set to vim.o.background

use_background = true,
}

---@type Config
Expand All @@ -73,10 +68,6 @@ function M.extend(options)
M.options = vim.tbl_deep_extend('force', {}, M.options or defaults, options or {})
end

function M.is_day()
return M.options.style == 'day' or M.options.use_background and vim.o.background == 'light'
end

M.setup()

return M
1 change: 0 additions & 1 deletion lua/pastelnight/util.lua
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@ local M = {}

M.bg = '#000000'
M.fg = '#ffffff'
M.day_brightness = 0.3

---@param c string
local function hexToRgb(c)
Expand Down

0 comments on commit c780324

Please sign in to comment.