mirror of
https://github.com/siyuan-note/siyuan.git
synced 2026-01-04 07:48:49 +01:00
This commit is contained in:
parent
c1770324f5
commit
bd544b239b
8 changed files with 46 additions and 16 deletions
|
|
@ -1,4 +1,8 @@
|
|||
{
|
||||
"localRepo":"local",
|
||||
"localSnapshotRepo":"Local Snapshot",
|
||||
"cloudSnapshotRepo":"Cloud Snapshot",
|
||||
"cloudBackupTip":"Move to Data History => Data Snapshot",
|
||||
"snapshotMemo": "Snapshot Memo",
|
||||
"snapshotMemoTip": "Please enter the snapshot memo",
|
||||
"tagSnapshot": "Tag Snapshot",
|
||||
|
|
|
|||
|
|
@ -1,4 +1,8 @@
|
|||
{
|
||||
"localRepo":"local",
|
||||
"localSnapshotRepo":"Instantánea local",
|
||||
"cloudSnapshotRepo":"Instantánea de la nube",
|
||||
"cloudBackupTip":"Mover a Historial de datos => Instantánea de datos",
|
||||
"snapshotMemo": "Memo de Instantánea",
|
||||
"snapshotMemoTip": "Ingrese la nota instantánea",
|
||||
"tagSnapshot": "Instantánea de la etiqueta",
|
||||
|
|
|
|||
|
|
@ -1,4 +1,8 @@
|
|||
{
|
||||
"localRepo":"local",
|
||||
"localSnapshotRepo":"instantané local",
|
||||
"cloudSnapshotRepo":"Instantané cloud",
|
||||
"cloudBackupTip":"Déplacer vers l'historique des données => Instantané des données",
|
||||
"snapshotMemo": "Mémo d'instantané",
|
||||
"snapshotMemoTip": "Veuillez entrer le mémo instantané",
|
||||
"tagSnapshot": "Instantané de balise",
|
||||
|
|
|
|||
|
|
@ -1,4 +1,8 @@
|
|||
{
|
||||
"localRepo":"本地",
|
||||
"localSnapshotRepo":"本地快照",
|
||||
"cloudSnapshotRepo":"雲端快照",
|
||||
"cloudBackupTip":"遷移至數據歷史 => 數據快照",
|
||||
"snapshotMemo": "快照備註",
|
||||
"snapshotMemoTip": "請輸入快照備註",
|
||||
"tagSnapshot": "標記快照",
|
||||
|
|
|
|||
|
|
@ -1,4 +1,8 @@
|
|||
{
|
||||
"localRepo":"本地",
|
||||
"localSnapshotRepo":"本地快照",
|
||||
"cloudSnapshotRepo":"云端快照",
|
||||
"cloudBackupTip":"迁移至数据历史 => 数据快照",
|
||||
"snapshotMemo": "快照备注",
|
||||
"snapshotMemoTip": "请输入快照备注",
|
||||
"tagSnapshot": "标记快照",
|
||||
|
|
|
|||
|
|
@ -292,15 +292,6 @@
|
|||
flex: 1;
|
||||
}
|
||||
}
|
||||
|
||||
.history__repo > .fn__flex-1 {
|
||||
flex-direction: column;
|
||||
|
||||
ul {
|
||||
width: auto !important;
|
||||
flex: 1;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@media (max-width: 620px) {
|
||||
|
|
|
|||
|
|
@ -380,6 +380,10 @@ ${passwordHTML}
|
|||
<div id="reposCloudSyncList" class="fn__none config-repos__sync"><img style="margin: 0 auto;display: block;" src="/stage/loading-pure.svg"></div>
|
||||
</div>
|
||||
<div id="reposBackup" class="b3-label${window.siyuan.config.sync.useDataRepo ? " fn__none" : ""}">${window.siyuan.languages.cloudBackup}</div>
|
||||
<div class="b3-label fn__flex${window.siyuan.config.sync.useDataRepo ? "" : " fn__none"}">
|
||||
<div class="fn__flex-center">${window.siyuan.languages.cloudBackup}</div>
|
||||
<div class="b3-list-item__meta fn__flex-center">${window.siyuan.languages.cloudBackupTip}</div>
|
||||
</div>
|
||||
</div>`;
|
||||
},
|
||||
bindEvent: () => {
|
||||
|
|
@ -428,8 +432,10 @@ ${passwordHTML}
|
|||
const reposBackupElement = repos.element.querySelector("#reposBackup") as HTMLElement;
|
||||
if (useDataRepoElement.checked) {
|
||||
reposBackupElement.classList.add("fn__none");
|
||||
reposBackupElement.nextElementSibling.classList.remove("fn__none");
|
||||
} else {
|
||||
reposBackupElement.classList.remove("fn__none");
|
||||
reposBackupElement.nextElementSibling.classList.add("fn__none");
|
||||
}
|
||||
}
|
||||
});
|
||||
|
|
|
|||
|
|
@ -125,15 +125,17 @@ const renderRepo = (element: Element, currentPage: number) => {
|
|||
return;
|
||||
}
|
||||
let repoHTML = "";
|
||||
response.data.logs.forEach((item: { memo: string, id: string, hCreated: string, count: number, hSize: string }, index: number) => {
|
||||
repoHTML += `<li class="b3-list-item b3-list-item--hide-action${index === 0 ? " b3-list-item--focus" : ""}" data-id="${item.id}">
|
||||
response.data.logs.forEach((item: { memo: string, id: string, hCreated: string, count: number, hSize: string }) => {
|
||||
repoHTML += `<li class="b3-list-item b3-list-item--hide-action" data-id="${item.id}">
|
||||
<div class="b3-list-item__text">
|
||||
${item.hCreated}
|
||||
<span class="fn__space"></span>
|
||||
${escapeHtml(item.memo)}
|
||||
<span class="fn__space"></span>
|
||||
<span class="ft__smaller ft__on-surface">${item.hSize}</span>
|
||||
${item.hCreated}<span class="fn__space"></span>${escapeHtml(item.memo)}<span class="b3-list-item__meta">${item.hSize}</span>
|
||||
</div>
|
||||
<span class="b3-list-item__action b3-tooltips b3-tooltips__w" data-type="uploadSnapshot" aria-label="${window.siyuan.languages.upload}">
|
||||
<svg><use xlink:href="#iconUpload"></use></svg>
|
||||
</span>
|
||||
<span class="b3-list-item__action b3-tooltips b3-tooltips__w" data-type="downloadSnapshot" aria-label="${window.siyuan.languages.download}">
|
||||
<svg><use xlink:href="#iconDownload"></use></svg>
|
||||
</span>
|
||||
<span class="b3-list-item__action b3-tooltips b3-tooltips__w" data-type="genTag" aria-label="${window.siyuan.languages.createSnapshot}">
|
||||
<svg><use xlink:href="#iconAdd"></use></svg>
|
||||
</span>
|
||||
|
|
@ -219,6 +221,13 @@ export const openHistory = () => {
|
|||
<span class="fn__space"></span>
|
||||
<span data-type="next" class="block__icon b3-tooltips b3-tooltips__se" disabled="disabled" aria-label="${window.siyuan.languages.nextLabel}"><svg><use xlink:href='#iconRight'></use></svg></span>
|
||||
<div class="fn__flex-1"></div>
|
||||
<select>
|
||||
<option value="">${window.siyuan.languages.localRepo}</option>
|
||||
<option value="">${window.siyuan.languages.localRepo}</option>
|
||||
<option value="">${window.siyuan.languages.localSnapshotRepo}</option>
|
||||
<option value="">${window.siyuan.languages.cloudSnapshotRepo}</option>
|
||||
</select>
|
||||
<span class="fn__space"></span>
|
||||
<button class="b3-button b3-button--outline" data-type="genRepo">
|
||||
<svg><use xlink:href="#iconAdd"></use></svg>${window.siyuan.languages.createSnapshot}
|
||||
</button>
|
||||
|
|
@ -387,6 +396,10 @@ export const openHistory = () => {
|
|||
genRepoDialog.destroy();
|
||||
});
|
||||
break;
|
||||
} else if (type === "uploadSnapshot") {
|
||||
// TODO
|
||||
} else if (type === "downloadSnapshot") {
|
||||
// TODO
|
||||
} else if (type === "genTag") {
|
||||
const genTagDialog = new Dialog({
|
||||
title: window.siyuan.languages.snapshotMemo,
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue