mirror of
https://github.com/logseq/logseq.git
synced 2026-05-24 20:54:09 +00:00
fix: popup can't be scrolled
This commit is contained in:
@@ -157,6 +157,7 @@ ul {
|
||||
|
||||
.app-silk-scroll-content {
|
||||
@apply min-h-screen;
|
||||
padding-bottom: 200px;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -335,7 +336,6 @@ ul {
|
||||
overflow: hidden;
|
||||
overflow: clip;
|
||||
position: relative;
|
||||
padding-bottom: 200px;
|
||||
}
|
||||
|
||||
html[data-silk-native-page-scroll-replaced=false] .app-silk-index-scroll-view {
|
||||
|
||||
@@ -101,19 +101,26 @@
|
||||
(silkhq/bottom-sheet-content
|
||||
{:class "flex flex-col items-center p-2"}
|
||||
(silkhq/bottom-sheet-handle)
|
||||
(let [title (or (:title opts) (when (string? content-fn) content-fn))
|
||||
content (if (fn? content-fn)
|
||||
[:div {:style (cond-> {}
|
||||
(or (nil? default-height) (number? default-height))
|
||||
(assoc :min-height (or default-height 300)))}
|
||||
(content-fn)]
|
||||
(if-let [buttons (and action-sheet? (:buttons opts))]
|
||||
[:div.-mx-2
|
||||
(for [{:keys [role text]} buttons]
|
||||
(ui/menu-link {:on-click #(some-> (:on-action opts) (apply [{:role role}]))
|
||||
:data-role role}
|
||||
[:span.text-lg.flex.items-center text]))]
|
||||
(when-not (string? content-fn) content-fn)))]
|
||||
[:div.w-full.app-silk-popup-content-inner.p-2
|
||||
(when title [:h2.py-2.opacity-40 title])
|
||||
content])))))))
|
||||
(silkhq/scroll
|
||||
{:as-child true}
|
||||
(silkhq/scroll-view
|
||||
{:class "app-silk-scroll-view overflow-y-scroll"
|
||||
:scrollGestureTrap {:yEnd true}
|
||||
:style {:min-height (if (number? default-height)
|
||||
default-height
|
||||
400)
|
||||
:max-height "80vh"}}
|
||||
(silkhq/scroll-content
|
||||
(let [title (or (:title opts) (when (string? content-fn) content-fn))
|
||||
content (if (fn? content-fn)
|
||||
(content-fn)
|
||||
(if-let [buttons (and action-sheet? (:buttons opts))]
|
||||
[:div.-mx-2
|
||||
(for [{:keys [role text]} buttons]
|
||||
(ui/menu-link {:on-click #(some-> (:on-action opts) (apply [{:role role}]))
|
||||
:data-role role}
|
||||
[:span.text-lg.flex.items-center text]))]
|
||||
(when-not (string? content-fn) content-fn)))]
|
||||
[:div.w-full.app-silk-popup-content-inner.p-2
|
||||
(when title [:h2.py-2.opacity-40 title])
|
||||
content]))))))))))
|
||||
|
||||
Reference in New Issue
Block a user