mirror of
https://github.com/penpot/penpot.git
synced 2025-06-07 09:31:38 +02:00
✨ Adds shadows to texts
This commit is contained in:
parent
b8fbe65d36
commit
5e73da4bca
2 changed files with 11 additions and 2 deletions
|
@ -24,6 +24,7 @@
|
||||||
[app.main.ui.shapes.text :as text]
|
[app.main.ui.shapes.text :as text]
|
||||||
[app.main.ui.keyboard :as kbd]
|
[app.main.ui.keyboard :as kbd]
|
||||||
[app.main.ui.context :as muc]
|
[app.main.ui.context :as muc]
|
||||||
|
[app.main.ui.shapes.filters :as filters]
|
||||||
[app.main.fonts :as fonts]
|
[app.main.fonts :as fonts]
|
||||||
[app.util.color :as color]
|
[app.util.color :as color]
|
||||||
[app.util.dom :as dom]
|
[app.util.dom :as dom]
|
||||||
|
@ -73,11 +74,15 @@
|
||||||
(dom/stop-propagation event)
|
(dom/stop-propagation event)
|
||||||
(dom/prevent-default event)
|
(dom/prevent-default event)
|
||||||
(when selected?
|
(when selected?
|
||||||
(st/emit! (dw/start-edition-mode (:id shape)))))]
|
(st/emit! (dw/start-edition-mode (:id shape)))))
|
||||||
|
|
||||||
|
filter-id (mf/use-memo filters/get-filter-id)]
|
||||||
|
|
||||||
[:g.shape {:on-double-click on-double-click
|
[:g.shape {:on-double-click on-double-click
|
||||||
:on-mouse-down on-mouse-down
|
:on-mouse-down on-mouse-down
|
||||||
:on-context-menu on-context-menu}
|
:on-context-menu on-context-menu
|
||||||
|
:filter (filters/filter-str filter-id shape)}
|
||||||
|
[:& filters/filters {:filter-id filter-id :shape shape}]
|
||||||
[:*
|
[:*
|
||||||
(when (and (not edition?) (not embed-resources?))
|
(when (and (not edition?) (not embed-resources?))
|
||||||
[:g {:opacity 0
|
[:g {:opacity 0
|
||||||
|
|
|
@ -21,6 +21,7 @@
|
||||||
[app.main.refs :as refs]
|
[app.main.refs :as refs]
|
||||||
[app.main.ui.workspace.sidebar.options.measures :refer [measure-attrs measures-menu]]
|
[app.main.ui.workspace.sidebar.options.measures :refer [measure-attrs measures-menu]]
|
||||||
[app.main.ui.workspace.sidebar.options.fill :refer [fill-menu]]
|
[app.main.ui.workspace.sidebar.options.fill :refer [fill-menu]]
|
||||||
|
[app.main.ui.workspace.sidebar.options.shadow :refer [shadow-menu]]
|
||||||
[app.main.ui.components.editable-select :refer [editable-select]]
|
[app.main.ui.components.editable-select :refer [editable-select]]
|
||||||
[app.util.dom :as dom]
|
[app.util.dom :as dom]
|
||||||
[app.main.fonts :as fonts]
|
[app.main.fonts :as fonts]
|
||||||
|
@ -442,6 +443,9 @@
|
||||||
:type type
|
:type type
|
||||||
:values converted-fill-values
|
:values converted-fill-values
|
||||||
:editor editor}]
|
:editor editor}]
|
||||||
|
[:& shadow-menu {:ids ids
|
||||||
|
:type type
|
||||||
|
:values (select-keys shape [:shadow])}]
|
||||||
[:& text-menu {:ids ids
|
[:& text-menu {:ids ids
|
||||||
:type type
|
:type type
|
||||||
:editor editor
|
:editor editor
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue