aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJonas Bernoulli2025-10-13 20:33:30 +0200
committerJonas Bernoulli2025-10-13 20:33:30 +0200
commit0dd8138d3f1a5ce8f5bde5cc671fe22b9b00912d (patch)
tree034a024bd347cfedbccdf87819bd8eea849b3a1a
parentaae6a9a74017207a1251d272892d141cec9cf0fb (diff)
downloademacs-0dd8138d3f1a5ce8f5bde5cc671fe22b9b00912d.tar.gz
emacs-0dd8138d3f1a5ce8f5bde5cc671fe22b9b00912d.zip
Update to Transient v0.10.1-8-g188ec9a1
-rw-r--r--doc/misc/transient.texi4
-rw-r--r--lisp/transient.el32
2 files changed, 19 insertions, 17 deletions
diff --git a/doc/misc/transient.texi b/doc/misc/transient.texi
index f2e06009771..71f35011496 100644
--- a/doc/misc/transient.texi
+++ b/doc/misc/transient.texi
@@ -31,7 +31,7 @@ General Public License for more details.
31@finalout 31@finalout
32@titlepage 32@titlepage
33@title Transient User and Developer Manual 33@title Transient User and Developer Manual
34@subtitle for version 0.10.0 34@subtitle for version 0.10.1
35@author Jonas Bernoulli 35@author Jonas Bernoulli
36@page 36@page
37@vskip 0pt plus 1filll 37@vskip 0pt plus 1filll
@@ -53,7 +53,7 @@ resource to get over that hurdle is Psionic K's interactive tutorial,
53available at @uref{https://github.com/positron-solutions/transient-showcase}. 53available at @uref{https://github.com/positron-solutions/transient-showcase}.
54 54
55@noindent 55@noindent
56This manual is for Transient version 0.10.0. 56This manual is for Transient version 0.10.1.
57 57
58@insertcopying 58@insertcopying
59@end ifnottex 59@end ifnottex
diff --git a/lisp/transient.el b/lisp/transient.el
index 1f458be8829..520270972e8 100644
--- a/lisp/transient.el
+++ b/lisp/transient.el
@@ -5,7 +5,7 @@
5;; Author: Jonas Bernoulli <jonas@bernoul.li> 5;; Author: Jonas Bernoulli <jonas@bernoul.li>
6;; URL: https://github.com/magit/transient 6;; URL: https://github.com/magit/transient
7;; Keywords: extensions 7;; Keywords: extensions
8;; Version: 0.10.0 8;; Version: 0.10.1
9 9
10;; SPDX-License-Identifier: GPL-3.0-or-later 10;; SPDX-License-Identifier: GPL-3.0-or-later
11 11
@@ -33,7 +33,7 @@
33;;; Code: 33;;; Code:
34;;;; Frontmatter 34;;;; Frontmatter
35 35
36(defconst transient-version "0.10.0-builtin") 36(defconst transient-version "v0.10.1-8-g188ec9a1-builtin")
37 37
38(require 'cl-lib) 38(require 'cl-lib)
39(require 'eieio) 39(require 'eieio)
@@ -1961,9 +1961,10 @@ probably use this instead:
1961 (t nil)))) 1961 (t nil))))
1962 ((and-let* ((obj (transient--suffix-prototype (or command this-command))) 1962 ((and-let* ((obj (transient--suffix-prototype (or command this-command)))
1963 (obj (clone obj))) 1963 (obj (clone obj)))
1964 (transient-init-scope obj) 1964 (progn
1965 (transient-init-value obj) 1965 (transient-init-scope obj)
1966 obj)))) 1966 (transient-init-value obj)
1967 obj)))))
1967 1968
1968(defun transient--suffix-prototype (command) 1969(defun transient--suffix-prototype (command)
1969 (or (get command 'transient--suffix) 1970 (or (get command 'transient--suffix)
@@ -2249,10 +2250,10 @@ of the corresponding object."
2249 map)) 2250 map))
2250 2251
2251(defun transient--make-predicate-map () 2252(defun transient--make-predicate-map ()
2252 (let* ((default (transient--resolve-pre-command 2253 (let ((default (transient--resolve-pre-command
2253 (oref transient--prefix transient-suffix))) 2254 (oref transient--prefix transient-suffix)))
2254 (return (and transient--stack (oref transient--prefix return))) 2255 (return (and transient--stack (oref transient--prefix return)))
2255 (map (make-sparse-keymap))) 2256 (map (make-sparse-keymap)))
2256 (set-keymap-parent map transient-predicate-map) 2257 (set-keymap-parent map transient-predicate-map)
2257 (when (or (and (slot-boundp transient--prefix 'transient-switch-frame) 2258 (when (or (and (slot-boundp transient--prefix 'transient-switch-frame)
2258 (transient--resolve-pre-command 2259 (transient--resolve-pre-command
@@ -2463,9 +2464,9 @@ value. Otherwise return CHILDREN as is.")
2463 (cl-etypecase spec 2464 (cl-etypecase spec
2464 (symbol (mapcan (lambda (c) (transient--init-child levels c parent)) 2465 (symbol (mapcan (lambda (c) (transient--init-child levels c parent))
2465 (transient--get-children spec))) 2466 (transient--get-children spec)))
2466 (vector (transient--init-group levels spec parent)) 2467 (vector (transient--init-group levels spec parent))
2467 (list (transient--init-suffix levels spec parent)) 2468 (list (transient--init-suffix levels spec parent))
2468 (string (list spec)))) 2469 (string (list spec))))
2469 2470
2470(defun transient--init-group (levels spec parent) 2471(defun transient--init-group (levels spec parent)
2471 (pcase-let* ((`[,class ,args ,children] spec) 2472 (pcase-let* ((`[,class ,args ,children] spec)
@@ -2479,8 +2480,9 @@ value. Otherwise return CHILDREN as is.")
2479 (oset obj inapt t)))) 2480 (oset obj inapt t))))
2480 (suffixes (mapcan (lambda (c) (transient--init-child levels c obj)) 2481 (suffixes (mapcan (lambda (c) (transient--init-child levels c obj))
2481 (transient-setup-children obj children)))) 2482 (transient-setup-children obj children))))
2482 (oset obj suffixes suffixes) 2483 (progn
2483 (list obj)))) 2484 (oset obj suffixes suffixes)
2485 (list obj)))))
2484 2486
2485(defun transient--init-suffix (levels spec parent) 2487(defun transient--init-suffix (levels spec parent)
2486 (let* ((class (car spec)) 2488 (let* ((class (car spec))
@@ -4037,7 +4039,7 @@ the value."
4037 (and (not (and (slot-exists-p obj 'unsavable) 4039 (and (not (and (slot-exists-p obj 'unsavable)
4038 (oref obj unsavable))) 4040 (oref obj unsavable)))
4039 (transient--get-wrapped-value obj))) 4041 (transient--get-wrapped-value obj)))
4040 transient--suffixes))) 4042 (or transient--suffixes transient-current-suffixes))))
4041 4043
4042(defun transient--get-wrapped-value (obj) 4044(defun transient--get-wrapped-value (obj)
4043 "Return a list of the value(s) of suffix object OBJ. 4045 "Return a list of the value(s) of suffix object OBJ.