From 6ec2513225ca21ba7e43ed12a4a07a64c7d9ba9c Mon Sep 17 00:00:00 2001 From: Vanessa Date: Wed, 21 Dec 2022 18:24:43 +0800 Subject: [PATCH] :art: fix https://github.com/siyuan-note/siyuan/issues/6899 --- app/src/assets/scss/_function.scss | 7 +++++++ app/src/history/diff.ts | 15 ++++++++------- 2 files changed, 15 insertions(+), 7 deletions(-) diff --git a/app/src/assets/scss/_function.scss b/app/src/assets/scss/_function.scss index d7108ef9d..254c3b54a 100644 --- a/app/src/assets/scss/_function.scss +++ b/app/src/assets/scss/_function.scss @@ -195,4 +195,11 @@ z-index: 1; } } + + &__date { + text-align: center; + line-height: 20px; + color: var(--b3-theme-on-surface); + background: var(--b3-theme-background); + } } diff --git a/app/src/history/diff.ts b/app/src/history/diff.ts index ce48a1db4..b4e4de97d 100644 --- a/app/src/history/diff.ts +++ b/app/src/history/diff.ts @@ -65,6 +65,7 @@ const renderCompare = (element: HTMLElement) => { } fetchPost("/api/repo/openRepoSnapshotDoc", {id: element.getAttribute("data-id")}, (response) => { + leftElement.classList.remove("fn__none"); const textElement = (leftElement.firstElementChild.nextElementSibling as HTMLTextAreaElement) if (response.data.isLargeDoc) { textElement.value = response.data.content; @@ -135,15 +136,15 @@ export const showDiff = (ids: string) => {
-
-
${dayjs(response.data.left.created).format("YYYY-MM-DD HH:mm")}
- -
+
+
${dayjs(response.data.left.created).format("YYYY-MM-DD HH:mm")}
+ +
-
${dayjs(response.data.right.created).format("YYYY-MM-DD HH:mm")}
- -
+
${dayjs(response.data.right.created).format("YYYY-MM-DD HH:mm")}
+ +
`,