From ce2d03d6fe7b3803f316afeff3980f58f64b6515 Mon Sep 17 00:00:00 2001 From: Marcus Kammer Date: Thu, 13 Jul 2023 09:07:02 +0200 Subject: [PATCH] Update docstring for define-btns --- src/component/button.lisp | 14 +++++++++----- 1 file changed, 9 insertions(+), 5 deletions(-) diff --git a/src/component/button.lisp b/src/component/button.lisp index 8fff6ca..dc8dcbc 100644 --- a/src/component/button.lisp +++ b/src/component/button.lisp @@ -119,9 +119,13 @@ `(btn (:type ,(string ',type-name) :size ,(string ',size-name)) ,@body)))) (defmacro define-btns (names) - "This macro generates specific button macros based on the provided names. + "This macro generates a suite of button-creating macros for each provided button type. - NAMES: A list of button type names. For each name in this list, three macros will be generated: a standard button, a large button, and a small button." + NAMES: A list of button type names. Each name should be a string representing a Bootstrap button type (like 'primary', 'secondary', 'success', etc.). + + For each type name in NAMES, this macro defines six new macros: a standard button, an outline button, a large button, a small button, a large outline button, and a small outline button. + + The newly defined macros, when called, will generate HTML for a Bootstrap button of the corresponding type, size, and outline style." `(progn ,@(loop for item in names @@ -129,9 +133,9 @@ collect `(progn (define-btn ,type-name) (define-btn ,type-name t) - (define-btn ,type-name nil "lg") - (define-btn ,type-name nil "sm") (define-btn ,type-name t "lg") - (define-btn ,type-name t "sm"))))) + (define-btn ,type-name t "sm") + (define-btn ,type-name nil "lg") + (define-btn ,type-name nil "sm"))))) (define-btns (primary secondary success danger warning info light dark link))