mirror of
https://github.com/siyuan-note/siyuan.git
synced 2026-02-08 08:14:21 +01:00
This commit is contained in:
parent
286bbee02e
commit
cc99943cfd
1 changed files with 2 additions and 2 deletions
|
|
@ -357,7 +357,7 @@ const renderKeyboardToolbar = () => {
|
|||
const selectText = range.toString();
|
||||
|
||||
if (!nodeElement.classList.contains("code-block") &&
|
||||
(selectText || dynamicElements[0].querySelector('[data-type="goinline"]').classList.contains("protyle-toolbar__item--current"))) {
|
||||
(selectText || dynamicElements[0].querySelector('[data-type="goinline"]').classList.contains("protyle-toolbar__item--current"))) {
|
||||
dynamicElements[0].classList.add("fn__none");
|
||||
dynamicElements[1].classList.remove("fn__none");
|
||||
} else {
|
||||
|
|
@ -415,7 +415,7 @@ const renderKeyboardToolbar = () => {
|
|||
};
|
||||
|
||||
export const showKeyboardToolbar = () => {
|
||||
if (!showUtil) {
|
||||
if (!showUtil || getSelection().rangeCount === 0) {
|
||||
hideKeyboardToolbarUtil();
|
||||
}
|
||||
const toolbarElement = document.getElementById("keyboardToolbar");
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue