summaryrefslogtreecommitdiff
path: root/fnl
diff options
context:
space:
mode:
authorGustaf Rydholm <gustaf.rydholm@gmail.com>2024-07-19 01:49:09 +0200
committerGustaf Rydholm <gustaf.rydholm@gmail.com>2024-07-19 01:49:09 +0200
commit7f90f7c25da27ae42c72359395a2fa0008b24b8a (patch)
tree5440024e0293b62e5a21add5e30a81e1ce982860 /fnl
parentf546a6d45eb53012666676b6c3e60a6059de64f4 (diff)
Fix which-key and icons
Diffstat (limited to 'fnl')
-rw-r--r--fnl/plugins/which-key.fnl59
-rw-r--r--fnl/settings/icons.fnl19
2 files changed, 52 insertions, 26 deletions
diff --git a/fnl/plugins/which-key.fnl b/fnl/plugins/which-key.fnl
index cc40d17..269978e 100644
--- a/fnl/plugins/which-key.fnl
+++ b/fnl/plugins/which-key.fnl
@@ -5,43 +5,56 @@
(local opts {:plugins {:marks true
:registers true
:spelling {:enabled true :suggestions 20}
- :presets {:operators false
- :motions false
- :text_objects false
+ :presets {:operators true
+ :motions true
+ :text_objects true
:windows true
:nav true
:z true
:g true}}
:icons {:breadcrumb (. icons :guillemet)
:separator (.. (. icons :small-right-arrow) " ")
- :group "+"}
- :popup_mappings {:scroll_down :<c-d> :scroll_up :<c-u>}
- :window {:border :rounded :position :bottom :winblend 0}
+ :group "+"
+ :colors false
+ :keys {:Up (.. (. icons :up-arrow) " ")
+ :Down (.. (. icons :down-arrow) " ")
+ :Left (.. (. icons :left-arrow) " ")
+ :Right (.. (. icons :right-arrow) " ")
+ :C (.. (. icons :up-caret) " ")
+ :M (.. (. icons :meta) " ")
+ :D (.. (. icons :openbased) " ")
+ :S (.. (. icons :shift) " ")
+ :CR (.. (. icons :cr) " ")
+ :Esc (.. (. icons :esc) " ")
+ :NL (.. (. icons :cr) " ")
+ :BS (.. (. icons :bs) " ")
+ :Space (.. (. icons :space) " ")
+ :Tab (.. (. icons :tab) " ")}}
:layout {:height {:min 4 :max 25}
:width {:min 20 :max 50}
:spacing 3
:align :left}
- :hidden [:<silent> :<cmd> :<Cmd> :<CR> :call :lua "^:" "^ "]
:show_help true
- :triggers :auto
- :disable {:filetypes [:netrw]}
- :triggers_blacklist {:i [:j :k] :v [:j :k]}})
+ :disable {:filetypes [:netrw]}})
-(local groups {:mode [:n :v]
- :<leader>d {:name :+db}
- :<leader>f {:name :+find}
- :<leader>g {:name :+git}
- :<leader>i {:name :+diffview}
- :<leader>j {:name :+diagnostics}
- :<leader>l {:name :+lsp}
- :<leader>o {:name :+orgmode}
- :<leader>r {:name :+replace}
- :<leader>s {:name :+session}
- :<leader>w {:name :+worktree}})
+(local groups [{:mode [:n :v]
+ 1 {1 :<leader>d :group :+db}
+ 2 {1 :<leader>f :group :+find}
+ 3 {1 :<leader>g :group :+git}
+ 4 {1 :<leader>i :group :+diffview}
+ 5 {1 :<leader>j :group :+diagnostics}
+ 6 {1 :<leader>l :group :+lsp}
+ 7 {1 :<leader>o :group :+orgmode}
+ 8 {1 :<leader>r :group :+replace}
+ 9 {1 :<leader>s :group :+session}
+ 10 {1 :<leader>w :group :+worktree}}])
(fn config []
(let [which-key (require :which-key)]
(which-key.setup opts)
- (which-key.register groups)))
+ (which-key.add groups)))
-{1 :folke/which-key.nvim :event :VeryLazy : config}
+{1 :folke/which-key.nvim
+ :event :VeryLazy
+ : config
+ :dependencies :nvim-tree/nvim-web-devicons}
diff --git a/fnl/settings/icons.fnl b/fnl/settings/icons.fnl
index 6cbf106..2e40804 100644
--- a/fnl/settings/icons.fnl
+++ b/fnl/settings/icons.fnl
@@ -1,15 +1,20 @@
;; Icons.
-{:caret ">"
+{
+ :bs "󰭜"
+ :caret ">"
:checkmark ""
:close ""
:cmd ""
:code ""
:cog ""
:conflict ""
+ :cr "󰌑"
:document ""
+ :down-arrow "󰁅"
:down :
:error ""
+ :esc "󱊷"
:git " "
:git-add "|"
:git-change-delete "~"
@@ -24,29 +29,37 @@
:import ""
:info ""
:keyboard ""
+ :left-arrow "󰁍"
:lightning ""
:line "‒"
+ :meta "◆"
:notebook ""
+ :octagon "󰏄"
+ :octagon-filled "󰏃"
+ :openbased ""
:orb "○"
:orb-filled "●"
:org ""
:package "󰏗"
:pentagon "󰜀"
:pentagon-filled "󰜁"
- :octagon "󰏄"
- :octagon-filled "󰏃"
:play ""
:recent-files "󱋢"
:right-arrow ""
:search-files "󰱽"
:search-project "󰺅"
:search-text "󱎸"
+ :shift "󰘶"
:sleep "󰒲"
:small-right-arrow ""
+ :space ""
:staged ""
:star ""
+ :tab "󰌒"
:telescope ""
:unstaged ""
+ :up-caret "󰅃"
+ :up-arrow ""
:up :
:vim ""
:warn ""