Always render the invalid block ref regardless of contents

This commit is contained in:
David Vargas
2022-11-01 13:31:52 -04:00
committed by Tienson Qin
parent 2c5d2a42d7
commit 1bfb7321ec

View File

@@ -857,7 +857,7 @@
(rum/defc block-reference < rum/reactive
db-mixins/query
[config id label]
(when-let [block-id (parse-uuid id)]
(if-let [block-id (parse-uuid id)]
(let [db-id (:db/id (db/pull [:block/uuid block-id]))
block (when db-id (db/pull-block db-id))
block-type (keyword (get-in block [:block/properties :ls-type]))
@@ -927,7 +927,10 @@
:delay [1000, 100]} inner)
inner)])
[:span.warning.mr-1 {:title "Block ref invalid"}
(block-ref/->block-ref id)]))))
(block-ref/->block-ref id)]))
[:span.warning.mr-1 {:title "Block ref invalid"}
(block-ref/->block-ref id)]
))
(defn inline-text
([format v]