mirror of
https://github.com/penpot/penpot.git
synced 2025-01-06 14:50:20 -05:00
Move out of legacy
This commit is contained in:
parent
43e5e78053
commit
c6770f43c7
2 changed files with 7 additions and 9 deletions
|
@ -465,13 +465,10 @@
|
|||
(def workspace-token-themes
|
||||
(l/derived #(or (some-> % ctob/get-themes) []) tokens-lib))
|
||||
|
||||
(dm/legacy
|
||||
(def workspace-selected-token-set-id
|
||||
(l/derived
|
||||
wtts/get-selected-token-set-id
|
||||
st/state
|
||||
=))
|
||||
(def workspace-selected-token-set-id
|
||||
(l/derived wtts/get-selected-token-set-id st/state))
|
||||
|
||||
(dm/legacy
|
||||
(def workspace-active-theme-ids
|
||||
(l/derived wtts/get-active-theme-ids st/state))
|
||||
|
||||
|
|
|
@ -1,9 +1,10 @@
|
|||
(ns app.main.ui.workspace.tokens.token-set
|
||||
(:require
|
||||
[app.common.data :refer [ordered-map]]
|
||||
[app.common.data.macros :as dm]
|
||||
[app.common.types.tokens-lib :as ctob]
|
||||
[app.main.ui.workspace.tokens.token :as wtt]
|
||||
[clojure.set :as set]
|
||||
[app.common.types.tokens-lib :as ctob]))
|
||||
[clojure.set :as set]))
|
||||
|
||||
(defn get-workspace-tokens-lib [state]
|
||||
(get-in state [:workspace-data :tokens-lib]))
|
||||
|
@ -167,7 +168,7 @@
|
|||
;; === Set selection
|
||||
|
||||
(defn get-selected-token-set-id [state]
|
||||
(or (get-in state [:workspace-local :selected-token-set-id])
|
||||
(or (dm/legacy (get-in state [:workspace-local :selected-token-set-id]))
|
||||
(some-> (get-workspace-tokens-lib state)
|
||||
(ctob/get-sets)
|
||||
(first)
|
||||
|
|
Loading…
Reference in a new issue