mirror of
https://github.com/penpot/penpot.git
synced 2026-03-25 04:40:40 +01:00
Merge pull request #7610 from mdbenito/fix/conflicting-selection-shortcut-text-shape
🐛 Fix conflicting shortcut in text editor
This commit is contained in:
@@ -231,13 +231,13 @@
|
||||
:subsections [:text-editor]
|
||||
:fn #(update-attrs-when-no-readonly {:text-decoration "toggle-line-through"})}
|
||||
|
||||
:font-size-inc {:tooltip (ds/meta-shift ds/right-arrow)
|
||||
:command (ds/c-mod "shift+right")
|
||||
:font-size-inc {:tooltip (ds/meta-shift ">")
|
||||
:command (ds/c-mod "shift+.")
|
||||
:subsections [:text-editor]
|
||||
:fn #(update-attrs-when-no-readonly {:font-size-inc true})}
|
||||
|
||||
:font-size-dec {:tooltip (ds/meta-shift ds/left-arrow)
|
||||
:command (ds/c-mod "shift+left")
|
||||
:font-size-dec {:tooltip (ds/meta-shift "<")
|
||||
:command (ds/c-mod "shift+,")
|
||||
:subsections [:text-editor]
|
||||
:fn #(update-attrs-when-no-readonly {:font-size-dec true})}
|
||||
|
||||
|
||||
@@ -101,8 +101,10 @@
|
||||
(impl/updateBlockData state block-key (clj->js attrs)))))
|
||||
|
||||
state (impl/applyInlineStyle state (legacy.txt/attrs-to-styles attrs))
|
||||
selected (impl/getSelectedBlocks state)]
|
||||
(reduce update-blocks state selected)))
|
||||
selection-after-apply (impl/getSelection state)
|
||||
selected (impl/getSelectedBlocks state)
|
||||
state (reduce update-blocks state selected)]
|
||||
(impl/setSelection state selection-after-apply)))
|
||||
|
||||
(defn update-editor-current-inline-styles-fn
|
||||
[state update-fn]
|
||||
|
||||
Reference in New Issue
Block a user