From fd9920b5182069467dc32e0492efc2d9acbc98a5 Mon Sep 17 00:00:00 2001 From: tiye Date: Fri, 13 Nov 2026 15:00:26 +0800 Subject: [PATCH] Read Markup editor content as Option String --- calcit.cirru | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) diff --git a/calcit.cirru b/calcit.cirru index bc9bf43..a4778ed 100644 --- a/calcit.cirru +++ b/calcit.cirru @@ -23,14 +23,11 @@ (:ok checked) checked (:err _) (raise "|Expected List cursor") state $ schema/read-editor-data $ respo.cursor/get-state-at states ([] :data) - content $ get state :content + content $ .map (get state :content) + fn (value) (decode-map-as value String) div {} $ :class-name $ str-spaced css/global css/row - textarea $ {} - :value $ match content - (:some value) (decode-map-as value String) - (:none) None - :placeholder |Content + textarea $ {} (:value content) (:placeholder |Content) :class-name $ str-spaced css/expand css/textarea :style $ {} $ :height |320px :on-input $ fn (e d!)