aboutsummaryrefslogtreecommitdiffhomepage
path: root/nuldoc-src/components/slide_page_entry.ts
diff options
context:
space:
mode:
authornsfisis <nsfisis@gmail.com>2023-03-19 04:32:36 +0900
committernsfisis <nsfisis@gmail.com>2023-03-19 04:37:08 +0900
commitf2424f306be40e27c76def020ecb2ce1ec2aad4e (patch)
tree4ab51d9d20707dac51a4a2be60bc476bbac9bdbd /nuldoc-src/components/slide_page_entry.ts
parentca7a609fef1167374f7c36ae87be154b0142dd47 (diff)
downloadblog.nsfisis.dev-f2424f306be40e27c76def020ecb2ce1ec2aad4e.tar.gz
blog.nsfisis.dev-f2424f306be40e27c76def020ecb2ce1ec2aad4e.tar.zst
blog.nsfisis.dev-f2424f306be40e27c76def020ecb2ce1ec2aad4e.zip
refactor: change type of Revision.date
Diffstat (limited to 'nuldoc-src/components/slide_page_entry.ts')
-rw-r--r--nuldoc-src/components/slide_page_entry.ts9
1 files changed, 5 insertions, 4 deletions
diff --git a/nuldoc-src/components/slide_page_entry.ts b/nuldoc-src/components/slide_page_entry.ts
index 3aff5ae..4767ca2 100644
--- a/nuldoc-src/components/slide_page_entry.ts
+++ b/nuldoc-src/components/slide_page_entry.ts
@@ -1,6 +1,7 @@
import { el, Element, text } from "../dom.ts";
import { getPostCreatedDate, getPostUpdatedDate } from "../pages/post.ts";
import { SlidePage } from "../pages/slide.ts";
+import { dateToString } from "../revision.ts";
export function slidePageEntry(slide: SlidePage): Element {
return el(
@@ -24,8 +25,8 @@ export function slidePageEntry(slide: SlidePage): Element {
[["class", "entry-footer"]],
el(
"time",
- [["datetime", getPostCreatedDate(slide)]],
- text(getPostCreatedDate(slide)),
+ [["datetime", dateToString(getPostCreatedDate(slide))]],
+ text(dateToString(getPostCreatedDate(slide))),
),
text(" 登壇"),
...(slide.revisions.length > 1
@@ -33,8 +34,8 @@ export function slidePageEntry(slide: SlidePage): Element {
text("、"),
el("time", [[
"datetime",
- getPostUpdatedDate(slide),
- ]], text(getPostUpdatedDate(slide))),
+ dateToString(getPostUpdatedDate(slide)),
+ ]], text(dateToString(getPostUpdatedDate(slide)))),
text(" 更新"),
]
: []),