From ea2b5f9355f838f9168083e264ea3faeda417bec Mon Sep 17 00:00:00 2001 From: Howard Abrams Date: Wed, 27 Mar 2024 14:25:30 -0700 Subject: [PATCH] shrface project makes EWW look like my Org Which makes the websites I go to much easier to read. --- ha-applications.org | 30 ++++++++++++++++++++++++++++-- 1 file changed, 28 insertions(+), 2 deletions(-) diff --git a/ha-applications.org b/ha-applications.org index c0cfe56..d66054d 100644 --- a/ha-applications.org +++ b/ha-applications.org @@ -427,8 +427,8 @@ Web pages look pretty good with EWW, but I'm having difficulty getting it to ren ("y" eww-copy-page-url "Copy URL")) "Navigation" (("u" eww-top-url "Site Top") - ("n" eww-next-url "Next Page") - ("p" eww-previous-url "Previous")) + ("n" eww-next-url "Next Page" :color pink) + ("p" eww-previous-url "Previous" :color pink)) "Toggles" (("c" eww-toggle-colors "Colors") ("i" eww-toggle-images "Images") @@ -471,6 +471,32 @@ This function allows Imenu to offer HTML headings in EWW buffers, helpful for na (lambda () (setq-local imenu-create-index-function #'unpackaged/imenu-eww-headings)))) #+end_src +** SHRFace +Make my EWW browsers /look/ like an Org file with the [[https://github.com/chenyanming/shrface][shrface project]]. + +#+begin_src emacs-lisp + (use-package shrface + :straight (:host github :repo "chenyanming/shrface") + :config + (shrface-basic) + (shrface-trial) + ;; (shrface-default-keybindings) ; setup default keybindings + (setq shrface-href-versatile t) + + (major-mode-hydra-define+ eww-mode nil + ("Headlines" + (("j" shrface-next-headline "Next Heading" :color pink) + ("k" shrface-previous-headline "Previous" :color pink) + ("J" shrface-headline-consult "Goto Heading"))))) +#+end_src + +And connect it to EWW: + +#+begin_src emacs-lisp + (use-package eww + :after shrface + :hook (eww-after-render #'shrface-mode)) +#+end_src ** Get Pocket The [[https://github.com/alphapapa/pocket-reader.el][pocket-reader]] project connects to the [[https://getpocket.com/en/][Get Pocket]] service.