Browse Source

fix: backward pos for embeds

Tienson Qin 4 years ago
parent
commit
536f1582dc
1 changed files with 3 additions and 3 deletions
  1. 3 3
      src/main/frontend/commands.cljs

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

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