Pārlūkot izejas kodu

Update code edit for the codeblocks that are opened in main area and sidebar,or as embeds

sid597 2 gadi atpakaļ
vecāks
revīzija
d2b45a59b3
1 mainītis faili ar 2 papildinājumiem un 0 dzēšanām
  1. 2 0
      src/main/frontend/extensions/code.cljs

+ 2 - 0
src/main/frontend/extensions/code.cljs

@@ -260,6 +260,8 @@
                 state)
    :did-update (fn [state]
                  (reset! (:code-options state) (last (:rum/args state)))
+                 (.setValue @(:editor-atom state)
+                            (string/join "" (butlast (:lines (last (:rum/args state))))))
                  state)}
   [state _config id attr code _theme _options]
   [:div.extensions__code