From 40d204b2f68b90bd2c5e9940cd128c4c16cd5274 Mon Sep 17 00:00:00 2001 From: Kia King Ishii Date: Tue, 24 Nov 2020 19:11:12 +0900 Subject: [PATCH] feat: add "last updated" feature --- .../theme-default/components/EditLink.vue | 7 +- .../theme-default/components/LastUpdated.vue | 67 +++++++++++++++++++ src/client/theme-default/components/Page.vue | 7 +- .../theme-default/components/PageFooter.vue | 49 ++++++++++++++ src/client/theme-default/config.ts | 6 ++ 5 files changed, 127 insertions(+), 9 deletions(-) create mode 100644 src/client/theme-default/components/LastUpdated.vue create mode 100644 src/client/theme-default/components/PageFooter.vue diff --git a/src/client/theme-default/components/EditLink.vue b/src/client/theme-default/components/EditLink.vue index 19d73490..54d9dd71 100644 --- a/src/client/theme-default/components/EditLink.vue +++ b/src/client/theme-default/components/EditLink.vue @@ -28,14 +28,9 @@ export default defineComponent({ diff --git a/src/client/theme-default/components/Page.vue b/src/client/theme-default/components/Page.vue index 43b2ae47..910d1042 100644 --- a/src/client/theme-default/components/Page.vue +++ b/src/client/theme-default/components/Page.vue @@ -6,7 +6,8 @@ - + + @@ -15,12 +16,12 @@ + + diff --git a/src/client/theme-default/config.ts b/src/client/theme-default/config.ts index 4c60f0f5..91ec3605 100644 --- a/src/client/theme-default/config.ts +++ b/src/client/theme-default/config.ts @@ -51,7 +51,13 @@ export namespace DefaultTheme { */ editLinkText?: string + /** + * Show last updated time at the bottom of the page. Defaults to `false`. + * If given a string, it will be displayed as a prefix (default value: + * "Last Updated"). + */ lastUpdated?: string | boolean + prevLink?: boolean nextLink?: boolean }