anchor.diff:    (:use :common-lisp :nyxt)
     (:documentation "Mode for editing macros."))
   (in-package :nyxt/macro-edit-mode)
  +(use-nyxt-package-nicknames)
   
   (define-mode macro-edit-mode ()
     "Mode for creating and editing macros."
     ((name
       ""
  -    :documentation "The name used for the macro."
  -    :accessor nil)
  +    :accessor nil
  +    :documentation "The name used for the macro.")
      (functions
  -    (make-hash-table)
  -    :documentation "A hash table of functions the user has added to their
  -macro. The key represents a unique identifier for a command, and the value
  -represents a command.")))
  +    '()
  +    :documentation "Functions the user has added to their macro.")))
   
   (define-internal-page-command-global edit-macro ()
       (buffer "*Macro edit*" 'nyxt/macro-edit-mode:macro-edit-mode)
  
positive.code:              (ps:lisp
                (render-functions)))))))
  
  (defmethod command-help ((macro-editor macro-edit-mode) command-id)
    (nyxt::describe-command :command (name (gethash command-id (functions macro-editor)))))
  
  (defmethod add-function ((macro-editor macro-edit-mode) command)
    (setf (gethash (parse-integer (symbol-name (gensym "")))
                   (functions macro-editor))
          command)
    (render-functions macro-editor))
  
  (defmethod remove-function ((macro-editor macro-edit-mode) command-id)
    (remhash command-id (functions macro-editor))
    (render-functions macro-editor))
  
  (defmethod name ((macro-editor macro-edit-mode))
  
negative.code:   (flet ((render-functions ()
             (spinneret:with-html-string
               (:table
                (loop for function in (functions macro-editor)
                      for index from 0
                      collect (:tr (:td (:button :class "button"
                                                 :onclick (ps:ps (nyxt/ps:lisp-eval
                                                                  `(nyxt/macro-edit-mode::remove-function
                                                                    (current-mode 'macro-edit-mode)
                                                                    ,index)))
                                                 "✕"))
                                   (:td (:button :class "button"
                                                 :onclick (ps:ps (nyxt/ps:lisp-eval
                                                                  `(nyxt/macro-edit-mode::command-help
                                                                    (current-mode 'macro-edit-mode)
                                                                    ,index)))
                                                 "🛈"))
                                   (:td (symbol-name (name function)))))))))
      (ffi-buffer-evaluate-javascript-async
       (buffer macro-editor)
       (ps:ps
  