Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

bug: day theme has lighter sidebars #499

Open
3 tasks done
kassio opened this issue Mar 5, 2024 · 5 comments
Open
3 tasks done

bug: day theme has lighter sidebars #499

kassio opened this issue Mar 5, 2024 · 5 comments
Labels
bug Something isn't working

Comments

@kassio
Copy link

kassio commented Mar 5, 2024

Did you check docs and existing issues?

  • I have read all the tokyonight.nvim docs
  • I have searched the existing issues of tokyonight.nvim
  • I have searched the existing issues of plugins related to this issue

Neovim version (nvim -v)

v0.10.0-dev-2513+g0ffc92649

Operating system/version

MacOS 14.3.1 (23D60)

Describe the bug

My config is giving me a different color set on day from what is shown in the README. My config:

  {
    'folke/tokyonight.nvim',
    lazy = false,
    priority = 1000,
    config = function()
      require('tokyonight').setup({
        style = 'night',
        light_style = 'day',
        terminal_colors = true,
        sidebars = { 'qf', 'help', 'terminal' },
        day_brightness = 0.3,
      })

      vim.cmd.colorscheme('tokyonight')
    end,
  }
readme image my config
orig

Am I doing something wrong?

Steps To Reproduce

detailed above

Expected Behavior

detailed above

Repro

-- DO NOT change the paths and don't remove the colorscheme
local root = vim.fn.fnamemodify("./.repro", ":p")

-- set stdpaths to use .repro
for _, name in ipairs({ "config", "data", "state", "cache" }) do
  vim.env[("XDG_%s_HOME"):format(name:upper())] = root .. "/" .. name
end

-- bootstrap lazy
local lazypath = root .. "/plugins/lazy.nvim"
if not vim.loop.fs_stat(lazypath) then
  vim.fn.system({ "git", "clone", "--filter=blob:none", "https://github.com/folke/lazy.nvim.git", lazypath, })
end
vim.opt.runtimepath:prepend(lazypath)

-- install plugins
local plugins = {
  "folke/tokyonight.nvim",
  {
    'folke/tokyonight.nvim',
    lazy = false,
    priority = 1000,
    config = function()
      require('tokyonight').setup({
        style = 'night',
        light_style = 'day',
        terminal_colors = true,
        sidebars = { 'qf', 'help', 'terminal' },
        day_brightness = 0.3,
      })

      vim.cmd.colorscheme('tokyonight')
    end,
  },
  -- add any other plugins here
}
require("lazy").setup(plugins, {
  root = root .. "/plugins",
})

vim.cmd.colorscheme("tokyonight")
-- add anything else here
@kassio kassio added the bug Something isn't working label Mar 5, 2024
@denisw
Copy link

denisw commented Mar 27, 2024

I have exactly the same problem. Other types of buffers defined as sidebars, like help and the quickfix list, are also lighter.

@kassio
Copy link
Author

kassio commented Mar 27, 2024

It seems that the light theme is not very used, so this wasn't noticed for a while. :/

@kassio
Copy link
Author

kassio commented Apr 2, 2024

I thought this could be due to my wezterm config, but I think I'm using the right themes:

if wezterm.gui.get_appearance():find('Dark') then
  config.color_scheme = 'tokyonight_night'
else
  config.color_scheme = 'tokyonight_day'
end

And from wezterm docs:

Author: folke
Source: https://github.com/folke/tokyonight.nvim
This scheme is also known as tokyonight-day.

To use this scheme, add this to your config:


config.color_scheme = 'tokyonight_day'

# ...

Author: folke
Source: https://github.com/folke/tokyonight.nvim
This scheme is also known as tokyonight.

To use this scheme, add this to your config:


config.color_scheme = 'tokyonight_night'

@kassio
Copy link
Author

kassio commented May 10, 2024

Hacky solution:

require('tokyonight').setup({
  style = 'storm',
  light_style = 'day',
  on_colors = function(colors)
    local bg_dark = colors.bg
    local bg = colors.bg_sidebar
    colors.bg = bg
    colors.bg_sidebar = bg_dark
  end
})

\cc @denisw @folke

@audendana
Copy link

@kassio your solution worked!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

3 participants