fix: frontend code shouldn't require mobile ns

This commit is contained in:
Tienson Qin
2025-11-28 04:34:43 +08:00
parent 8bb0cc16e0
commit 3952e5f1aa
2 changed files with 6 additions and 5 deletions

View File

@@ -11,7 +11,6 @@
[logseq.db :as ldb]
[logseq.shui.hooks :as hooks]
[logseq.shui.ui :as shui]
[mobile.components.ui :as mobile-ui]
[rum.core :as rum]))
(rum/defc page-blocks
@@ -58,8 +57,11 @@
"Quick add"]
(when mobile? add-button)]
(if mobile?
(mobile-ui/classic-app-container-wrap
(page-blocks add-page))
[:main#app-container-wrapper.ls-fold-button-on-right
[:div#app-container.pt-2
[:div#main-container.flex.flex-1
[:div.w-full
(page-blocks add-page)]]]]
[:div.content {:class "block -ml-6"}
(page-blocks add-page)])
(when-not mobile? add-button)]))))

View File

@@ -40,7 +40,6 @@
[goog.dom :as gdom]
[logseq.common.util :as common-util]
[logseq.shui.ui :as shui]
[mobile.state :as mobile-state]
[promesa.core :as p]))
(defmethod events/handle :go/search [_]
@@ -91,7 +90,7 @@
(defmethod events/handle :redirect-to-home [_]
(page-handler/create-today-journal!)
(when (util/capacitor?)
(mobile-state/set-tab! "home")))
(state/pub-event! [:mobile/set-tab "home"])))
(defmethod events/handle :page/show-delete-dialog [[_ selected-rows ok-handler]]
(shui/dialog-open!