allow user to disable gestures on blocks with customized tags

This commit is contained in:
llcc
2022-06-22 19:20:57 +08:00
committed by Tienson Qin
parent 6de6222645
commit 2f35629738
2 changed files with 13 additions and 2 deletions

View File

@@ -152,8 +152,14 @@
(defn- target-disable-swipe?
[target]
(or (.closest target ".dsl-query")
(.closest target ".drawer")))
(let [user-defined-tags (get-in (state/get-config)
[:mobile :gestures/disabled-in-block-with-tags])]
(prn (some #(.closest target (util/format "[data-refs-self*=%s]" %))
user-defined-tags))
(or (.closest target ".dsl-query")
(.closest target ".drawer")
(some #(.closest target (util/format "[data-refs-self*=%s]" %))
user-defined-tags))))
(defn on-touch-start
[event uuid]