mirror of
https://github.com/logseq/logseq.git
synced 2026-05-04 02:46:45 +00:00
feat: show theme plugin settings under Settings menu
This commit is contained in:
@@ -163,7 +163,7 @@
|
||||
|
||||
(defn get-enabled-plugins-if-setting-schema
|
||||
[]
|
||||
(when-let [plugins (seq (state/get-enabled?-installed-plugins false nil true))]
|
||||
(when-let [plugins (seq (state/get-all-enabled?-installed-plugins nil true))]
|
||||
(filter #(has-setting-schema? (:id %)) plugins)))
|
||||
|
||||
(defn setup-install-listener!
|
||||
|
||||
@@ -1764,6 +1764,13 @@ Similar to re-frame subscriptions"
|
||||
(when-let [id (and id (keyword id))]
|
||||
(get-in @state [:plugin/installed-plugins id])))
|
||||
|
||||
(defn get-all-enabled?-installed-plugins
|
||||
([enabled? include-unpacked?]
|
||||
(filterv
|
||||
#(and (if include-unpacked? true (:iir %))
|
||||
(if-not (boolean? enabled?) true (= (not enabled?) (boolean (get-in % [:settings :disabled])))))
|
||||
(vals (:plugin/installed-plugins @state)))))
|
||||
|
||||
(defn get-enabled?-installed-plugins
|
||||
([theme?] (get-enabled?-installed-plugins theme? true false))
|
||||
([theme? enabled? include-unpacked?]
|
||||
|
||||
Reference in New Issue
Block a user