Add section macro

This commit is contained in:
Marcus Kammer 2024-07-31 18:26:25 +02:00
parent 889c05b0d3
commit 336856152c

14
src/section.lisp Normal file
View file

@ -0,0 +1,14 @@
;;;; -*- mode: common-lisp; coding: utf-8; -*-
(defpackage ml-sbt/section
(:use :cl)
(:export :with-section))
(in-package :ml-sbt/section)
(defmacro with-section (headline &body body)
`(spinneret:with-html
(:section :class "mb-3"
(:div :class "d-flex justify-content-between flex-wrap flex-md-nowrap align-items-center pt-3 pb-2 mb-3 border-bottom"
(:h* ,headline))
,@body)))