mirror of
https://github.com/siyuan-note/siyuan.git
synced 2025-12-23 10:00:13 +01:00
This commit is contained in:
parent
fff0db0d2c
commit
6ad5949200
1 changed files with 7 additions and 3 deletions
|
|
@ -125,13 +125,17 @@ const setSync = (key?: string, dialog?: Dialog) => {
|
||||||
window.siyuan.config.repo.key = key;
|
window.siyuan.config.repo.key = key;
|
||||||
}
|
}
|
||||||
if (!window.siyuan.config.sync.enabled) {
|
if (!window.siyuan.config.sync.enabled) {
|
||||||
const listHTML = `<div class="b3-dialog__content" style="display: flex;flex-direction: column;height: 40vh;">
|
const listHTML = `<div class="b3-dialog__content">
|
||||||
|
<div class="ft__on-surface">TODO</div>
|
||||||
|
<div style="display: flex;flex-direction: column;height: 40vh;">
|
||||||
<img style="margin: 0 auto;display: block;width: 64px;height: 100%" src="/stage/loading-pure.svg">
|
<img style="margin: 0 auto;display: block;width: 64px;height: 100%" src="/stage/loading-pure.svg">
|
||||||
</div>
|
</div>
|
||||||
|
</div>
|
||||||
<div class="b3-dialog__action">
|
<div class="b3-dialog__action">
|
||||||
<button class="b3-button">${window.siyuan.languages.openSyncTip1}</button>
|
<button class="b3-button">${window.siyuan.languages.openSyncTip1}</button>
|
||||||
</div>`;
|
</div>`;
|
||||||
if (dialog) {
|
if (dialog) {
|
||||||
|
dialog.element.querySelector(".b3-dialog__header").innerHTML = window.siyuan.languages.cloudSyncDir;
|
||||||
dialog.element.querySelector(".b3-dialog__container").lastElementChild.innerHTML = listHTML;
|
dialog.element.querySelector(".b3-dialog__container").lastElementChild.innerHTML = listHTML;
|
||||||
} else {
|
} else {
|
||||||
dialog = new Dialog({
|
dialog = new Dialog({
|
||||||
|
|
@ -140,7 +144,7 @@ const setSync = (key?: string, dialog?: Dialog) => {
|
||||||
width: isMobile() ? "80vw" : "520px",
|
width: isMobile() ? "80vw" : "520px",
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
const contentElement = dialog.element.querySelector(".b3-dialog__content");
|
const contentElement = dialog.element.querySelector(".b3-dialog__content").lastElementChild;
|
||||||
bindSyncCloudListEvent(contentElement);
|
bindSyncCloudListEvent(contentElement);
|
||||||
getSyncCloudList(contentElement);
|
getSyncCloudList(contentElement);
|
||||||
dialog.element.querySelector(".b3-button").addEventListener("click", () => {
|
dialog.element.querySelector(".b3-button").addEventListener("click", () => {
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue