mirror of
https://github.com/siyuan-note/siyuan.git
synced 2026-03-08 05:32:33 +01:00
🚨
This commit is contained in:
parent
c8b05a6b96
commit
ac8748d161
13 changed files with 36 additions and 36 deletions
|
|
@ -88,7 +88,7 @@ window.openFileByURL = (openURL) => {
|
|||
if (openURL && /^siyuan:\/\/blocks\/\d{14}-\w{7}/.test(openURL)) {
|
||||
openMobileFileById(openURL.substr(16, 22),
|
||||
getSearch("focus", openURL) === "1" ? [Constants.CB_GET_ALL, Constants.CB_GET_FOCUS] : [Constants.CB_GET_FOCUS, Constants.CB_GET_CONTEXT]);
|
||||
return true
|
||||
return true;
|
||||
}
|
||||
return false
|
||||
}
|
||||
return false;
|
||||
};
|
||||
|
|
|
|||
|
|
@ -132,7 +132,7 @@ export const initFramework = () => {
|
|||
mountHelp();
|
||||
}
|
||||
const transactionTipElement = document.getElementById("transactionTip");
|
||||
transactionTipElement.innerHTML = `${window.siyuan.languages.waitSync} <button class="b3-button">${window.siyuan.languages.syncNow}</button>`
|
||||
transactionTipElement.innerHTML = `${window.siyuan.languages.waitSync} <button class="b3-button">${window.siyuan.languages.syncNow}</button>`;
|
||||
transactionTipElement.querySelector(".b3-button").addEventListener(getEventName(), () => {
|
||||
syncGuide();
|
||||
});
|
||||
|
|
@ -162,7 +162,7 @@ export const initFramework = () => {
|
|||
});
|
||||
}
|
||||
});
|
||||
return
|
||||
return;
|
||||
}
|
||||
setEmpty();
|
||||
};
|
||||
|
|
|
|||
|
|
@ -62,7 +62,7 @@ const showAccountInfo = (modelElement: HTMLElement, modelMainElement: Element) =
|
|||
window.siyuan.user = null;
|
||||
closePanel();
|
||||
document.getElementById("menuAccount").innerHTML = `<svg class="b3-list-item__graphic"><use xlink:href="#iconAccount"></use></svg><span class="b3-list-item__text">${window.siyuan.languages.login}</span>`;
|
||||
processSync()
|
||||
processSync();
|
||||
});
|
||||
});
|
||||
modelMainElement.querySelector("#deactivateUser").addEventListener(getEventName(), () => {
|
||||
|
|
@ -71,7 +71,7 @@ const showAccountInfo = (modelElement: HTMLElement, modelMainElement: Element) =
|
|||
window.siyuan.user = null;
|
||||
closePanel();
|
||||
document.getElementById("menuAccount").innerHTML = `<svg class="b3-list-item__graphic"><use xlink:href="#iconAccount"></use></svg><span class="b3-list-item__text">${window.siyuan.languages.login}</span>`;
|
||||
processSync()
|
||||
processSync();
|
||||
});
|
||||
});
|
||||
});
|
||||
|
|
@ -94,7 +94,7 @@ const showAccountInfo = (modelElement: HTMLElement, modelMainElement: Element) =
|
|||
} else {
|
||||
menuAccountElement.innerHTML = `<svg class="b3-list-item__graphic"><use xlink:href="#iconAccount"></use></svg><span class="b3-list-item__text">${window.siyuan.languages.login}</span>`;
|
||||
}
|
||||
processSync()
|
||||
processSync();
|
||||
});
|
||||
});
|
||||
};
|
||||
|
|
@ -174,7 +174,7 @@ ${accountHTML}
|
|||
<svg class="b3-list-item__graphic"><use xlink:href="#iconQuit"></use></svg><span class="b3-list-item__text">${window.siyuan.languages.safeQuit}</span>
|
||||
</div>`;
|
||||
// 只能用 click,否则无法上下滚动 https://github.com/siyuan-note/siyuan/issues/6628
|
||||
processSync()
|
||||
processSync();
|
||||
menuElement.addEventListener("click", (event) => {
|
||||
let target = event.target as HTMLElement;
|
||||
while (target && !target.isEqualNode(menuElement)) {
|
||||
|
|
@ -669,7 +669,7 @@ ${accountHTML}
|
|||
closePanel();
|
||||
document.getElementById("menuAccount").innerHTML = `<img class="b3-list-item__graphic" src="${window.siyuan.user.userAvatarURL}"/>
|
||||
<span class="b3-list-item__text">${window.siyuan.user.userName}</span>`;
|
||||
processSync()
|
||||
processSync();
|
||||
});
|
||||
});
|
||||
});
|
||||
|
|
@ -686,7 +686,7 @@ ${accountHTML}
|
|||
closePanel();
|
||||
document.getElementById("menuAccount").innerHTML = `<img class="b3-list-item__graphic" src="${window.siyuan.user.userAvatarURL}"/>
|
||||
<span class="b3-list-item__text">${window.siyuan.user.userName}</span>`;
|
||||
processSync()
|
||||
processSync();
|
||||
});
|
||||
});
|
||||
});
|
||||
|
|
|
|||
|
|
@ -11,7 +11,7 @@ export const onMessage = (data: IWebSocketData) => {
|
|||
case"syncing":
|
||||
processSync(data);
|
||||
if (data.code !== 0) {
|
||||
document.getElementById("transactionTip").classList.add("fn__none")
|
||||
document.getElementById("transactionTip").classList.add("fn__none");
|
||||
}
|
||||
break;
|
||||
case "create":
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue