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

Enhance for snacks.nvim dashboard #106

Open
2 tasks done
RomanAverin opened this issue Nov 21, 2024 · 8 comments
Open
2 tasks done

Enhance for snacks.nvim dashboard #106

RomanAverin opened this issue Nov 21, 2024 · 8 comments
Assignees
Labels
enhancement New feature or request

Comments

@RomanAverin
Copy link

I have done the following steps before reporting this issue:

  • I have searched the existing issues
  • I have read the FAQ in the help doc

Operating system/version

Fedora 41

Terminal emulator/version

Wezterm 20240203-110809-5046fc22

$TERM environment variable

xterm-256color

Tmux version

3.5a

Feature matrix


==============================================================================
diffview: require("diffview.health").check()

Checking plugin dependencies ~
- OK nvim-web-devicons installed.

Checking VCS tools ~
- The plugin requires at least one of the supported VCS tools to be valid.
- OK Git found.
- OK Git is up-to-date. (2.47.0)
- WARNING Configured `hg_cmd` is not executable: 'hg'

==============================================================================
lazy: require("lazy.health").check()

lazy.nvim ~
- {lazy.nvim} version `11.14.2`
- OK {git} `version 2.47.0`
- OK no existing packages found by other package managers
- OK packer_compiled.lua not found

luarocks ~
- checking `luarocks` installation
- OK no plugins require `luarocks`, so you can ignore any warnings below
- OK {luarocks} `/usr/bin/luarocks 3.9.2`
- WARNING `lua` version `5.1` needed, but found `Lua 5.4.6  Copyright (C) 1994-2023 Lua.org, PUC-Rio`
- WARNING {lua5.1} or {lua} or {lua-5.1} version `5.1` not installed

==============================================================================
lazyvim: require("lazyvim.health").check()

LazyVim ~
- OK Using Neovim >= 0.9.0
- OK `git` is installed
- OK `rg` is installed
- OK `fd` is installed
- WARNING `lazygit` is not installed

==============================================================================
noice: require("noice.health").check()

noice.nvim ~
- OK **Neovim** >= 0.9.0
- OK You're using a GUI that should work ok
- OK **vim.go.lazyredraw** is not enabled
- WARNING Noice needs nvim-notify for routes using the `notify` view
- OK **TreeSitter vim** parser is installed
- OK **TreeSitter regex** parser is installed
- OK **TreeSitter lua** parser is installed
- OK **TreeSitter bash** parser is installed
- OK **TreeSitter markdown** parser is installed
- OK **TreeSitter markdown_inline** parser is installed
- OK `vim.notify` is set to **Noice**
- OK `vim.lsp.buf.hover` is set to **Noice**
- OK `vim.lsp.buf.signature_help` is set to **Noice**
- OK `vim.lsp.handlers["window/showMessage"]` is set to **Noice**
- OK `vim.lsp.util.convert_input_to_markdown_lines` is set to **Noice**
- OK `vim.lsp.util.stylize_markdown` is set to **Noice**

==============================================================================
nvim: require("nvim.health").check()

Configuration ~
- OK no issues found

Runtime ~
- OK $VIMRUNTIME: /usr/share/nvim/runtime

Performance ~
- OK Build type: RelWithDebInfo

Remote Plugins ~
- OK Up to date

terminal ~
- key_backspace (kbs) terminfo entry: `key_backspace=\177`
- key_dc (kdch1) terminfo entry: `key_dc=\E[3~`
- $TERM_PROGRAM="WezTerm"
- $COLORTERM="truecolor"

External Tools ~
- OK ripgrep 14.1.1 (/usr/bin/rg)

==============================================================================
nvim-treesitter: require("nvim-treesitter.health").check()

Installation ~
- OK `tree-sitter` found 0.23.2 (parser generator, only needed for :TSInstallFromGrammar)
- OK `node` found v20.18.0 (only needed for :TSInstallFromGrammar)
- OK `git` executable found.
- OK `cc` executable found. Selected from { vim.NIL, "cc", "gcc", "clang", "cl", "zig" }
  Version: cc (GCC) 14.2.1 20240912 (Red Hat 14.2.1-3)
- OK Neovim was compiled with tree-sitter runtime ABI version 14 (required >=13). Parsers must be compatible with runtime ABI.

OS Info:
{
  machine = "x86_64",
  release = "6.11.9-300.fc41.x86_64",
  sysname = "Linux",
  version = "#1 SMP PREEMPT_DYNAMIC Sun Nov 17 18:52:54 UTC 2024"
} ~

Parser/Features         H L F I J
  - bash                ✓ ✓ ✓ . ✓
  - c                   ✓ ✓ ✓ ✓ ✓
  - diff                ✓ . ✓ . ✓
  - dockerfile          ✓ . . . ✓
  - git_config          ✓ . ✓ . ✓
  - go                  ✓ ✓ ✓ ✓ ✓
  - gomod               ✓ . . . ✓
  - gosum               ✓ . . . .
  - gowork              ✓ . . . ✓
  - hcl                 ✓ . ✓ ✓ ✓
  - html                ✓ ✓ ✓ ✓ ✓
  - hyprlang            ✓ . ✓ ✓ ✓
  - javascript          ✓ ✓ ✓ ✓ ✓
  - jsdoc               ✓ . . . .
  - json                ✓ ✓ ✓ ✓ .
  - json5               ✓ . . . ✓
  - jsonc               ✓ ✓ ✓ ✓ ✓
  - lua                 ✓ ✓ ✓ ✓ ✓
  - luadoc              ✓ . . . .
  - luap                ✓ . . . .
  - markdown            ✓ . ✓ ✓ ✓
  - markdown_inline     ✓ . . . ✓
  - ninja               ✓ . ✓ ✓ ✓
  - printf              ✓ . . . .
  - python              ✓ ✓ ✓ ✓ ✓
  - query               ✓ ✓ ✓ ✓ ✓
  - rasi                ✓ ✓ ✓ ✓ ✓
  - regex               ✓ . . . .
  - ron                 ✓ ✓ ✓ ✓ ✓
  - rst                 ✓ ✓ . . ✓
  - rust                ✓ ✓ ✓ ✓ ✓
  - terraform           ✓ . ✓ ✓ ✓
  - toml                ✓ ✓ ✓ ✓ ✓
  - tsx                 ✓ ✓ ✓ ✓ ✓
  - typescript          ✓ ✓ ✓ ✓ ✓
  - vim                 ✓ ✓ ✓ . ✓
  - vimdoc              ✓ . . . ✓
  - xml                 ✓ ✓ ✓ ✓ ✓
  - yaml                ✓ ✓ ✓ ✓ ✓

  Legend: H[ighlight], L[ocals], F[olds], I[ndents], In[j]ections
         +) multiple parsers found, only one will be used
         x) errors found in the query, try to run :TSUpdate {lang} ~

==============================================================================
provider.clipboard: require("provider.clipboard.health").check()

Clipboard (optional) ~
- OK Clipboard tool found: wl-copy

==============================================================================
provider.node: require("provider.node.health").check()

Node.js provider (optional) ~
- Node.js: v20.18.0
  
- WARNING Missing "neovim" npm (or yarn, pnpm) package.
  - ADVICE:
    - Run in shell: npm install -g neovim
    - Run in shell (if you use yarn): yarn global add neovim
    - Run in shell (if you use pnpm): pnpm install -g neovim
    - You may disable this provider (and warning) by adding `let g:loaded_node_provider = 0` to your init.vim

==============================================================================
provider.perl: require("provider.perl.health").check()

Perl provider (optional) ~
- WARNING "Neovim::Ext" cpan module is not installed
  - ADVICE:
    - See :help |provider-perl| for more information.
    - You may disable this provider (and warning) by adding `let g:loaded_perl_provider = 0` to your init.vim
- WARNING No usable perl executable found

==============================================================================
provider.python: require("provider.python.health").check()

Python 3 provider (optional) ~
- Using: g:python3_host_prog = "/usr/bin/python3"
- Executable: /usr/bin/python3
- ERROR Failed to run healthcheck for "provider.python" plugin. Exception:
  /usr/share/nvim/runtime/lua/vim/health.lua:336: Command error (job=9, exit code 1): '/usr/bin/python3' -c 'import sys; sys.path = [p for p in sys.path if p != ""]; import neovim; print(neovim.__file__)' (in /home/rastler/.config/nvim)
  

==============================================================================
provider.ruby: require("provider.ruby.health").check()

Ruby provider (optional) ~
- WARNING `ruby` and `gem` must be in $PATH.
  - ADVICE:
    - Install Ruby and verify that `ruby` and `gem` commands work.

==============================================================================
snacks: require("snacks.health").check()

Snacks ~
- OK setup called

Snacks.bigfile ~
- OK setup {enabled}

Snacks.dashboard ~
- OK setup {enabled}
- OK setup ran
- OK dashboard opened

Snacks.lazygit ~
- ERROR {lazygit} not installed

Snacks.notifier ~
- OK setup {enabled}
- OK is ready

Snacks.quickfile ~
- OK setup {enabled}

Snacks.statuscolumn ~
- WARNING setup {disabled}
- OK is manually configured
  - `vim.o.statuscolumn = "%!v:lua.require'snacks.statuscolumn'.get()"`

Snacks.terminal ~
- OK shell configured
  - `vim.o.shell`: /usr/bin/zsh
  - `parsed`: { "/usr/bin/zsh" }

Snacks.toggle ~
- OK {which-key} is installed

Snacks.words ~
- OK setup {enabled}

==============================================================================
telescope: require("telescope.health").check()

Checking for required plugins ~
- OK plenary installed.
- OK nvim-treesitter installed.

Checking external dependencies ~
- OK rg: found ripgrep 14.1.1
- OK fd: found fd 10.1.0

===== Installed extensions ===== ~

Telescope Extension: `fzf` ~
- OK lib working as expected
- OK file_sorter correctly configured
- OK generic_sorter correctly configured

==============================================================================
vim.lsp: require("vim.lsp.health").check()

- LSP log level : WARN
- Log path: /home/rastler/.local/state/nvim/lsp.log
- Log size: 2756 KB

vim.lsp: Active Clients ~
- No active clients

vim.lsp: File Watcher ~
- file watching "(workspace/didChangeWatchedFiles)" disabled on all clients

vim.lsp: Position Encodings ~
- No active clients

==============================================================================
vim.treesitter: require("vim.treesitter.health").check()

- Nvim runtime ABI version: 14
- OK Parser: bash                 ABI: 14, path: /home/rastler/.local/share/nvim/lazy/nvim-treesitter/parser/bash.so
- OK Parser: c                    ABI: 14, path: /home/rastler/.local/share/nvim/lazy/nvim-treesitter/parser/c.so
- OK Parser: diff                 ABI: 14, path: /home/rastler/.local/share/nvim/lazy/nvim-treesitter/parser/diff.so
- OK Parser: dockerfile           ABI: 14, path: /home/rastler/.local/share/nvim/lazy/nvim-treesitter/parser/dockerfile.so
- OK Parser: git_config           ABI: 13, path: /home/rastler/.local/share/nvim/lazy/nvim-treesitter/parser/git_config.so
- OK Parser: go                   ABI: 14, path: /home/rastler/.local/share/nvim/lazy/nvim-treesitter/parser/go.so
- OK Parser: gomod                ABI: 14, path: /home/rastler/.local/share/nvim/lazy/nvim-treesitter/parser/gomod.so
- OK Parser: gosum                ABI: 14, path: /home/rastler/.local/share/nvim/lazy/nvim-treesitter/parser/gosum.so
- OK Parser: gowork               ABI: 13, path: /home/rastler/.local/share/nvim/lazy/nvim-treesitter/parser/gowork.so
- OK Parser: hcl                  ABI: 14, path: /home/rastler/.local/share/nvim/lazy/nvim-treesitter/parser/hcl.so
- OK Parser: html                 ABI: 14, path: /home/rastler/.local/share/nvim/lazy/nvim-treesitter/parser/html.so
- OK Parser: hyprlang             ABI: 14, path: /home/rastler/.local/share/nvim/lazy/nvim-treesitter/parser/hyprlang.so
- OK Parser: javascript           ABI: 14, path: /home/rastler/.local/share/nvim/lazy/nvim-treesitter/parser/javascript.so
- OK Parser: jsdoc                ABI: 14, path: /home/rastler/.local/share/nvim/lazy/nvim-treesitter/parser/jsdoc.so
- OK Parser: json                 ABI: 14, path: /home/rastler/.local/share/nvim/lazy/nvim-treesitter/parser/json.so
- OK Parser: json5                ABI: 14, path: /home/rastler/.local/share/nvim/lazy/nvim-treesitter/parser/json5.so
- OK Parser: jsonc                ABI: 13, path: /home/rastler/.local/share/nvim/lazy/nvim-treesitter/parser/jsonc.so
- OK Parser: lua                  ABI: 14, path: /home/rastler/.local/share/nvim/lazy/nvim-treesitter/parser/lua.so
- OK Parser: luadoc               ABI: 14, path: /home/rastler/.local/share/nvim/lazy/nvim-treesitter/parser/luadoc.so
- OK Parser: luap                 ABI: 14, path: /home/rastler/.local/share/nvim/lazy/nvim-treesitter/parser/luap.so
- OK Parser: markdown             ABI: 14, path: /home/rastler/.local/share/nvim/lazy/nvim-treesitter/parser/markdown.so
- OK Parser: markdown_inline      ABI: 14, path: /home/rastler/.local/share/nvim/lazy/nvim-treesitter/parser/markdown_inline.so
- OK Parser: ninja                ABI: 13, path: /home/rastler/.local/share/nvim/lazy/nvim-treesitter/parser/ninja.so
- OK Parser: printf               ABI: 14, path: /home/rastler/.local/share/nvim/lazy/nvim-treesitter/parser/printf.so
- OK Parser: python               ABI: 14, path: /home/rastler/.local/share/nvim/lazy/nvim-treesitter/parser/python.so
- OK Parser: query                ABI: 14, path: /home/rastler/.local/share/nvim/lazy/nvim-treesitter/parser/query.so
- OK Parser: rasi                 ABI: 14, path: /home/rastler/.local/share/nvim/lazy/nvim-treesitter/parser/rasi.so
- OK Parser: regex                ABI: 14, path: /home/rastler/.local/share/nvim/lazy/nvim-treesitter/parser/regex.so
- OK Parser: ron                  ABI: 14, path: /home/rastler/.local/share/nvim/lazy/nvim-treesitter/parser/ron.so
- OK Parser: rst                  ABI: 14, path: /home/rastler/.local/share/nvim/lazy/nvim-treesitter/parser/rst.so
- OK Parser: rust                 ABI: 14, path: /home/rastler/.local/share/nvim/lazy/nvim-treesitter/parser/rust.so
- OK Parser: terraform            ABI: 14, path: /home/rastler/.local/share/nvim/lazy/nvim-treesitter/parser/terraform.so
- OK Parser: toml                 ABI: 14, path: /home/rastler/.local/share/nvim/lazy/nvim-treesitter/parser/toml.so
- OK Parser: tsx                  ABI: 14, path: /home/rastler/.local/share/nvim/lazy/nvim-treesitter/parser/tsx.so
- OK Parser: typescript           ABI: 14, path: /home/rastler/.local/share/nvim/lazy/nvim-treesitter/parser/typescript.so
- OK Parser: vim                  ABI: 14, path: /home/rastler/.local/share/nvim/lazy/nvim-treesitter/parser/vim.so
- OK Parser: vimdoc               ABI: 14, path: /home/rastler/.local/share/nvim/lazy/nvim-treesitter/parser/vimdoc.so
- OK Parser: xml                  ABI: 14, path: /home/rastler/.local/share/nvim/lazy/nvim-treesitter/parser/xml.so
- OK Parser: yaml                 ABI: 14, path: /home/rastler/.local/share/nvim/lazy/nvim-treesitter/parser/yaml.so
- OK Parser: c                    ABI: 14, path: /usr/lib64/nvim/parser/c.so
- OK Parser: lua                  ABI: 14, path: /usr/lib64/nvim/parser/lua.so
- OK Parser: markdown             ABI: 14, path: /usr/lib64/nvim/parser/markdown.so
- OK Parser: markdown_inline      ABI: 14, path: /usr/lib64/nvim/parser/markdown_inline.so
- OK Parser: query                ABI: 14, path: /usr/lib64/nvim/parser/query.so
- OK Parser: vim                  ABI: 14, path: /usr/lib64/nvim/parser/vim.so
- OK Parser: vimdoc               ABI: 14, path: /usr/lib64/nvim/parser/vimdoc.so

==============================================================================
which-key: require("which-key.health").check()

- OK Most of these checks are for informational purposes only.
  WARNINGS should be treated as a warning, and don't necessarily indicate a problem with your config.
  Please |DON'T| report these warnings as an issue.

Checking your config ~
- OK |mini.icons| is installed
- OK |nvim-web-devicons| is installed

Checking for issues with your mappings ~
- OK No issues reported

checking for overlapping keymaps ~
- WARNING In mode `n`, <g> overlaps with <gx>, <g%>, <g[>, <g]>, <gc>, <gcc>, <gco>, <gcO>:
  - <g>: goto
  - <gx>: Open with system app
  - <g%>: Cycle backwards through results
  - <g[>: Move to left "around"
  - <g]>: Move to right "around"
  - <gc>: Comment
  - <gcc>: Comment line
  - <gco>: Add Comment Below
  - <gcO>: Add Comment Above
- WARNING In mode `n`, <<Space>w> overlaps with <<Space>wm>, <<C-W><Space>>, <<C-W><C-D>>, <<Space>wd>:
  - <<Space>w>: windows
  - <<Space>wm>: Enable Maximize
  - <<C-W><Space>>: Window Hydra Mode (which-key)
  - <<C-W><C-D>>: Show diagnostics under the cursor
  - <<Space>wd>: Delete Window
- WARNING In mode `x`, <i> overlaps with <in>, <il>:
  - <i>: inside
  - <in>: next
  - <il>: last
- WARNING In mode `x`, <a> overlaps with <an>, <a%>, <al>:
  - <a>: around
  - <an>: next
  - <al>: last
- WARNING In mode `o`, <i> overlaps with <in>, <il>:
  - <i>: inside
  - <in>: next
  - <il>: last
- WARNING In mode `o`, <a> overlaps with <an>, <al>:
  - <a>: around
  - <an>: next
  - <al>: last
- WARNING In mode `n`, <gc> overlaps with <gcc>, <gco>, <gcO>:
  - <gc>: Comment
  - <gcc>: Comment line
  - <gco>: Add Comment Below
  - <gcO>: Add Comment Above
- OK Overlapping keymaps are only reported for informational purposes.
  This doesn't necessarily mean there is a problem with your config.

Checking for duplicate mappings ~
- OK No duplicate mappings found

Minimal vimrc that can reproduce this bug.

return {
  "sainnhe/sonokai",
  lazy = false,
  priority = 1000,
  config = function()
    -- Optionally configure and load the colorscheme
    -- directly inside the plugin declaration.
    vim.g.sonokai_enable_italic = 1
    vim.g.sonokai_better_performance = 1
    vim.g.sonokai_disable_terminal_colors = 1
    vim.g.sonokai_diagnostic_line_highlight = 1
  end,
  {
    "LazyVim/LazyVim",
    opts = {
      colorscheme = "sonokai",
    },
  },
}

Steps to reproduce this bug using minimal vimrc

  1. Install lazyvim
  2. Add the sonokai plugin
  3. Running with default configuration with snacks.nvim dashboard

Expected behavior

Correct color

Actual behavior

Incorrect colors for new dashboard from snacks.nvim
image

@RomanAverin RomanAverin added the bug Something isn't working label Nov 21, 2024
@antoineco antoineco added enhancement New feature or request and removed bug Something isn't working labels Nov 21, 2024
@antoineco
Copy link
Collaborator

antoineco commented Nov 21, 2024

The plugin's defaults don't look great it's true.

Do you have a reference of the same dashboard using a different colorscheme to share? That could help us come up with a sensible design, closer to what the author intended.

edit: found it in the project's README
image

@RomanAverin
Copy link
Author

Example of the everforest theme working well

image

@antoineco antoineco self-assigned this Nov 25, 2024
@antoineco antoineco changed the title Doesn't work for the new dashboard from snacks.nvim Enhance for snacks.nvim dashboard Nov 25, 2024
@antoineco
Copy link
Collaborator

I'm currently thinking how to best customize highlights for this plugin.

The main reason why things look more acceptable in Everforst is because its orange-yellow colors combination is more homogeneous than the red-purple used in Sonokai. But in my opinion, none of them are particularly faithful to the semantics of the colorscheme:

Sonokai
sonokai

Everforest
everforst

In comparison, a colorscheme like Tokyo Night which is optimized for the plugin uses a combination of colors that is much easier on the eye:

Tokyo Night
tokyonight

@antoineco
Copy link
Collaborator

antoineco commented Nov 25, 2024

@RomanAverin what do you think about this?

normal

@RomanAverin
Copy link
Author

So nice, but a little lacking in contrast for text with a full path. Also doesn't quite match the original colors. The colors you suggest are not quite complimentary. That is, not very harmonious.
But it's already better than it was. Thank you. I need time to think about it and come up with my own version.

@antoineco
Copy link
Collaborator

antoineco commented Nov 26, 2024

The difficulty with this kind of plugins is that the Sonokai palette is fairly restricted. There are few base colors for different semantic highlight groups, but we don't shade/tint those colors (and do not want to).

There are a few shades of grey available to play with, but if we want to use colors the result is unlikely to be very harmonious. Maybe it is best to play with those shades for all text elements actually, on only highlight the symbols with a color.

palette

@RomanAverin
Copy link
Author

RomanAverin commented Nov 26, 2024

Red and green are complimentary.
The onedark color scheme option for this plugin looks good.

image

@antoineco
Copy link
Collaborator

antoineco commented Nov 26, 2024

I like it more indeed. I would go as far as making the headers also blue, and maybe bold.

I need to experiment a bit on my side too it would be nice if Sonokai had a decent support for the multiple dashboard-style plugins out there.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants