Use common generate-group

This commit is contained in:
bom 2024-07-02 15:31:11 +02:00
parent 4860e62fc2
commit f8638137d7

View file

@ -8,35 +8,21 @@
[dda.c4k-common.postgres :as pgc]
[dda.c4k-common.common :as cm]))
(defn generate-group
[name
content]
[{:type :element
:tag :div
:attrs {:class "rounded border border-3 m-3 p-2"}
:content [{:type :element
:tag :b
:attrs {:style "z-index: 1; position: relative; top: -1.3rem;"}
:content name}
{:type :element
:tag :fieldset
:content content}]}])
(defn generate-content []
(cm/concat-vec
[(assoc
(br/generate-needs-validation) :content
(cm/concat-vec
(generate-group
(br/generate-group
"domain"
(cm/concat-vec
(br/generate-input-field "fqdn" "Your fqdn:" "shynet.prod.meissa-gmbh.de")
(br/generate-input-field "issuer" "(Optional) Your issuer prod/staging:" "")))
(generate-group
(br/generate-group
"provider"
(cm/concat-vec
(br/generate-input-field "postgres-data-volume-path" "(Optional) Your postgres-data-volume-path if Persistent Volumes are not generated by an Operator:" "")))
(generate-group
(br/generate-group
"credentials"
(br/generate-text-area
"auth" "Your auth.edn:"