Просмотр исходного кода

Fix tabindex console react warnings (#6520)

Follow up to #6442
Gabriel Horner 3 лет назад
Родитель
Сommit
0275e5a067

+ 1 - 1
src/main/frontend/components/block.cljs

@@ -451,7 +451,7 @@
   [config page-name-in-block page-name redirect-page-name page-entity contents-page? children html-export? label]
   (let [tag? (:tag? config)]
     [:a
-     {:tabindex "0"
+     {:tabIndex "0"
       :class (cond-> (if tag? "tag" "page-ref")
                (:property? config)
                (str " page-property-key block-property"))

+ 2 - 2
src/main/frontend/components/sidebar.cljs

@@ -333,8 +333,8 @@
                     :route-match route-match})
 
      [:div#main-content-container.scrollbar-spacing.w-full.flex.justify-center.flex-row
-      
-      {:tabindex "-1"}
+
+      {:tabIndex "-1"}
 
       (when (util/electron?)
         (find-in-page/search))

+ 1 - 1
src/main/frontend/extensions/code.cljs

@@ -231,7 +231,7 @@
         cm-options (merge default-cm-options
                           (extra-codemirror-options)
                           {:mode mode
-                           :tabindex -1 ;; do not accept TAB-in, since TAB is bind globally
+                           :tabIndex -1 ;; do not accept TAB-in, since TAB is bind globally
                            :extraKeys #js {"Esc" (fn [cm]
                                                    ;; Avoid reentrancy
                                                    (gobj/set cm "escPressed" true)