branch: externals/transient
commit f8209cc8f48cb47902a86d1708d5c008cc4d9e88
Author: Jonas Bernoulli <jo...@bernoul.li>
Commit: Jonas Bernoulli <jo...@bernoul.li>

    transient--maybe-pad-keys: Ignore raw strings
    
    Previously combining raw string with `:pad-keys' would have resulted
    in an error.
---
 lisp/transient.el | 12 +++++++-----
 1 file changed, 7 insertions(+), 5 deletions(-)

diff --git a/lisp/transient.el b/lisp/transient.el
index dfb738f7ad..e712e2fac1 100644
--- a/lisp/transient.el
+++ b/lisp/transient.el
@@ -3706,12 +3706,14 @@ If the OBJ's `key' is currently unreachable, then apply 
the face
                          (oref parent pad-keys)))))
     (let ((width (apply #'max
                         (cons (if (integerp pad) pad 0)
-                              (mapcar (lambda (suffix)
-                                        (length (oref suffix key)))
-                                      (oref group suffixes))))))
+                              (seq-keep (lambda (suffix)
+                                          (and (not (stringp suffix))
+                                               (length (oref suffix key))))
+                                        (oref group suffixes))))))
       (dolist (suffix (oref group suffixes))
-        (oset suffix key
-              (truncate-string-to-width (oref suffix key) width nil ?\s))))))
+        (unless (stringp suffix)
+          (oset suffix key
+                (truncate-string-to-width (oref suffix key) width nil 
?\s)))))))
 
 (defun transient--pixel-width (string)
   (save-window-excursion

Reply via email to