fix(ui): null while query .editor-wrapper

pull/8386/head
Andelf 2023-01-18 15:21:57 +08:00
parent cfe28ca88a
commit 5dcbe6cdf5
1 changed files with 2 additions and 2 deletions

View File

@ -381,7 +381,7 @@
:z-index 11}
(when set-default-width?
{:width max-width})
(let [^js/HTMLElement editor
(when-let [^js/HTMLElement editor
(js/document.querySelector ".editor-wrapper")]
(if (<= (.-clientWidth editor) (+ left (if set-default-width? max-width 500)))
{:right 0}