mirror of
https://github.com/siyuan-note/siyuan.git
synced 2025-05-21 19:41:05 +08:00
🚨
This commit is contained in:
parent
882883a9cc
commit
4ca684ca8a
@ -297,7 +297,7 @@ export const progressStatus = (data: IWebSocketData) => {
|
|||||||
} else {
|
} else {
|
||||||
const msgElement = statusElement.querySelector(".status__msg");
|
const msgElement = statusElement.querySelector(".status__msg");
|
||||||
if (msgElement) {
|
if (msgElement) {
|
||||||
clearTimeout(statusTimeout)
|
clearTimeout(statusTimeout);
|
||||||
msgElement.innerHTML = data.msg;
|
msgElement.innerHTML = data.msg;
|
||||||
statusTimeout = window.setTimeout(() => {
|
statusTimeout = window.setTimeout(() => {
|
||||||
msgElement.innerHTML = "";
|
msgElement.innerHTML = "";
|
||||||
|
@ -59,7 +59,7 @@ const initMultiMenu = (selectItemElements: NodeListOf<Element>, app: App) => {
|
|||||||
click: () => {
|
click: () => {
|
||||||
openSearchAV("", selectItemElements[0] as HTMLElement, (listItemElement) => {
|
openSearchAV("", selectItemElements[0] as HTMLElement, (listItemElement) => {
|
||||||
const avID = listItemElement.dataset.avId;
|
const avID = listItemElement.dataset.avId;
|
||||||
const srcs: IOperationSrcs[] = []
|
const srcs: IOperationSrcs[] = [];
|
||||||
blockIDs.forEach(id => {
|
blockIDs.forEach(id => {
|
||||||
srcs.push({
|
srcs.push({
|
||||||
id,
|
id,
|
||||||
|
@ -280,7 +280,7 @@ class="fn__flex-1 fn__flex${["url", "text", "number", "email", "phone", "block"]
|
|||||||
if (document.querySelector(".av__panel .b3-form__upload") && files && files.length > 0) {
|
if (document.querySelector(".av__panel .b3-form__upload") && files && files.length > 0) {
|
||||||
uploadFiles(protyle, files);
|
uploadFiles(protyle, files);
|
||||||
}
|
}
|
||||||
})
|
});
|
||||||
element.addEventListener("click", (event) => {
|
element.addEventListener("click", (event) => {
|
||||||
let target = event.target as HTMLElement;
|
let target = event.target as HTMLElement;
|
||||||
const blockElement = hasClosestBlock(target);
|
const blockElement = hasClosestBlock(target);
|
||||||
@ -302,7 +302,7 @@ class="fn__flex-1 fn__flex${["url", "text", "number", "email", "phone", "block"]
|
|||||||
} else if (type === "mAsset") {
|
} else if (type === "mAsset") {
|
||||||
element.querySelectorAll('.custom-attr__avvalue[data-type="mAsset"]').forEach(item => {
|
element.querySelectorAll('.custom-attr__avvalue[data-type="mAsset"]').forEach(item => {
|
||||||
item.removeAttribute("data-active");
|
item.removeAttribute("data-active");
|
||||||
})
|
});
|
||||||
target.setAttribute("data-active", "true");
|
target.setAttribute("data-active", "true");
|
||||||
target.focus();
|
target.focus();
|
||||||
popTextCell(protyle, [target], "mAsset");
|
popTextCell(protyle, [target], "mAsset");
|
||||||
|
@ -191,7 +191,7 @@ export const pasteText = (protyle: IProtyle, textPlain: string, nodeElement: Ele
|
|||||||
} else if (isFileAnnotation(textPlain)) {
|
} else if (isFileAnnotation(textPlain)) {
|
||||||
textPlain = textPlain.replace(/".+">>$/, `"${range.toString()}">>`);
|
textPlain = textPlain.replace(/".+">>$/, `"${range.toString()}">>`);
|
||||||
} else {
|
} else {
|
||||||
const linkDest = protyle.lute.GetLinkDest(textPlain)
|
const linkDest = protyle.lute.GetLinkDest(textPlain);
|
||||||
if (linkDest) {
|
if (linkDest) {
|
||||||
textPlain = `[${range.toString()}](${linkDest})`;
|
textPlain = `[${range.toString()}](${linkDest})`;
|
||||||
}
|
}
|
||||||
@ -448,7 +448,7 @@ export const paste = async (protyle: IProtyle, event: (ClipboardEvent | DragEven
|
|||||||
return;
|
return;
|
||||||
} else {
|
} else {
|
||||||
// https://github.com/siyuan-note/siyuan/issues/8475
|
// https://github.com/siyuan-note/siyuan/issues/8475
|
||||||
const linkDest = protyle.lute.GetLinkDest(textPlain)
|
const linkDest = protyle.lute.GetLinkDest(textPlain);
|
||||||
if (linkDest) {
|
if (linkDest) {
|
||||||
protyle.toolbar.setInlineMark(protyle, "a", "range", {
|
protyle.toolbar.setInlineMark(protyle, "a", "range", {
|
||||||
type: "a",
|
type: "a",
|
||||||
|
Loading…
Reference in New Issue
Block a user