Explorar o código

fix: backward pos for embeds

Tienson Qin %!s(int64=5) %!d(string=hai) anos
pai
achega
536f1582dc
Modificáronse 1 ficheiros con 3 adicións e 3 borrados
  1. 3 3
      src/main/frontend/commands.cljs

+ 3 - 3
src/main/frontend/commands.cljs

@@ -50,13 +50,13 @@
   []
   []
   (conj
   (conj
    [[:editor/input "{{embed [[]]}}" {:last-pattern slash
    [[:editor/input "{{embed [[]]}}" {:last-pattern slash
-                                     :backward-pos 5}]]
+                                     :backward-pos 4}]]
    [:editor/search-page :embed]))
    [:editor/search-page :embed]))
 
 
 (defn embed-block
 (defn embed-block
   []
   []
   [[:editor/input "{{embed (())}}" {:last-pattern slash
   [[:editor/input "{{embed (())}}" {:last-pattern slash
-                                    :backward-pos 5}]
+                                    :backward-pos 4}]
    [:editor/search-block :embed]])
    [:editor/search-block :embed]])
 
 
 ;; Stop now!!
 ;; Stop now!!
@@ -126,7 +126,7 @@
      (when (state/logged?)
      (when (state/logged?)
        ["Upload an image" [[:editor/click-hidden-file-input :id]]])
        ["Upload an image" [[:editor/click-hidden-file-input :id]]])
      ["Embed Youtube Video" [[:editor/input "{{youtube }}" {:last-pattern slash
      ["Embed Youtube Video" [[:editor/input "{{youtube }}" {:last-pattern slash
-                                                            :backward-pos 3}]]]
+                                                            :backward-pos 2}]]]
      ["Html Inline " (->inline "html")]
      ["Html Inline " (->inline "html")]
 
 
      ;; TODO:
      ;; TODO: