diff --git a/homes/emenel/dotfiles/dot_config/nyxt/auto-config.3.lisp b/homes/emenel/dotfiles/dot_config/nyxt/auto-config.3.lisp new file mode 100644 index 0000000..f09408d --- /dev/null +++ b/homes/emenel/dotfiles/dot_config/nyxt/auto-config.3.lisp @@ -0,0 +1,23 @@ +(defmethod customize-instance ((buffer buffer) &key) + (setf (slot-value buffer 'default-modes + '(nyxt/mode/certificate-exception:certificate-exception-mode + nyxt/mode/autofill:autofill-mode + nyxt/mode/spell-check:spell-check-mode + nyxt/mode/search-buffer:search-buffer-mode + nyxt/mode/hint:hint-mode nyxt/mode/document:document-mode + nyxt/mode/password:password-mode + nyxt/mode/bookmark:bookmark-mode + nyxt/mode/annotate:annotate-mode + nyxt/mode/history:history-mode + nyxt/mode/blocker:blocker-mode + nyxt/mode/reduce-tracking:reduce-tracking-mode + nyxt/mode/bookmarklets:bookmarklets-mode base-mode)))) + +(define-configuration (web-buffer) + ((default-modes (pushnew 'nyxt/mode/style:dark-mode %slot-value%)))) + +(define-configuration (input-buffer) + ((default-modes (pushnew 'nyxt/mode/vi:vi-normal-mode %slot-value%)))) + +(define-configuration (prompt-buffer) + ((default-modes (pushnew 'nyxt/mode/vi:vi-insert-mode %slot-value%)))) diff --git a/homes/emenel/dotfiles/dot_config/nyxt/config.lisp b/homes/emenel/dotfiles/dot_config/nyxt/config.lisp index e4cbccf..776d17e 100644 --- a/homes/emenel/dotfiles/dot_config/nyxt/config.lisp +++ b/homes/emenel/dotfiles/dot_config/nyxt/config.lisp @@ -8,14 +8,10 @@ '("wiki" "https://en.wikipedia.org/w/index.php?search=~a" "https://en.wikipedia.org/") '("kagi" "https://kagi.com/search?q=~a" "https://www.kagi.com/"))) -(defvar *web-buffer-modes* - '(:blocker-mode - :reduce-tracking-mode)) - (define-configuration browser - ((restore-session-on-startup-p t) - ;; (default-new-buffer-url (quri:uri "https://github.com/atlas-engineer/nyxt")) - (external-editor-program '("emacsclient -r")))) + ((restore-session-on-startup-p t) + ;;(default-new-buffer-url (quri:uri "https://github.com/atlas-engineer/nyxt")) + (external-editor-program '("emacsclient -r")))) (define-configuration context-buffer "Go through the search engines above and make-search-engine" @@ -29,21 +25,17 @@ (define-configuration bookmark-frequent-visits-mode ((threshold 10))) -;; set web buffer default modes from *web-buffer-modes* above -(define-configuration web-buffer - "Basic modes setup for web-buffer." - ((default-modes `(,@*web-buffer-modes* ,@%slot-value%)))) - (define-configuration hint-mode "Set up QWERTY home row as the hint keys." ((hints-alphabet "DSJKHLFAGNMXCWEIO"))) -(define-configuration prompt-buffer - ((hide-single-source-header-p - t - :doc "This is to hide the header is there's only one source. -There also used to be other settings to make prompt-buffer a bit -more minimalist, but those are internal APIs :("))) +(define-nyxt-user-system-and-load "nyxt-user/rbw" + :depends-on ("nx-rbw")) + +(define-configuration :password-mode + ((pasword-interface (make-instance 'nx-rbw:rbw-interface)))) + + ;; key binds ;; (defvar mnl-keys (make-keyscheme cua))