Made accounts page look great

This commit is contained in:
2023-10-23 10:57:35 -07:00
parent 2f05197f5b
commit 825443ef2c
5 changed files with 337 additions and 265 deletions

View File

@@ -24,3 +24,17 @@
"x-transition:enter" "transition duration-500"
"x-transition:enter-start" "opacity-0"
"x-transition:enter-end" "opacity-100"))
(defn alpine-disappear [m]
(assoc m
"x-transition:leave" "transition duration-500"
"x-transition:leave-start" "opacity-100"
"x-transition:leave-end" "opacity-0"))
(defn alpine-mount-then-appear [{:keys [data-key] :as params}]
(merge (-> {"x-data" (json {data-key false})
"x-init" (format "$nextTick(() => %s=true)" (name data-key))
"x-show" (name data-key)}
alpine-appear
alpine-disappear)
(dissoc params :data-key)))