Ver Fonte

fix: increase the default search length

Fixes #10569
Tienson Qin há 2 anos atrás
pai
commit
9e412168ce
2 ficheiros alterados com 2 adições e 2 exclusões
  1. 1 1
      src/main/frontend/handler/editor.cljs
  2. 1 1
      src/main/frontend/search.cljs

+ 1 - 1
src/main/frontend/handler/editor.cljs

@@ -1643,7 +1643,7 @@
         editing-page (and block
                           (when-let [page-id (:db/id (:block/page block))]
                             (:block/name (db/entity page-id))))
-        pages (search/page-search q 100)]
+        pages (search/page-search q)]
     (if editing-page
       ;; To prevent self references
       (remove (fn [p] (= (util/page-name-sanity-lc p) editing-page)) pages)

+ 1 - 1
src/main/frontend/search.cljs

@@ -135,7 +135,7 @@
 (defn page-search
   "Return a list of page names that match the query"
   ([q]
-   (page-search q 10))
+   (page-search q 500))
   ([q limit]
    (when-let [repo (state/get-current-repo)]
      (let [q (util/search-normalize q (state/enable-search-remove-accents?))