From e424680fc013c291bd7eea4dc63b96401e5126a8 Mon Sep 17 00:00:00 2001
From: flu0r1ne <flu0r1ne@flu0r1ne.net>
Date: Wed, 21 Jul 2021 04:42:31 -0500
Subject: Added a timestamp and sorts posts by timestamp

---
 templates/Default/index.tsx | 8 +++++++-
 1 file changed, 7 insertions(+), 1 deletion(-)

(limited to 'templates/Default/index.tsx')

diff --git a/templates/Default/index.tsx b/templates/Default/index.tsx
index 8902bf8..f693da2 100644
--- a/templates/Default/index.tsx
+++ b/templates/Default/index.tsx
@@ -7,6 +7,7 @@ import styles from './default.module.scss';
 export type DefaultPage = {
     className?: string;
     path?: string;
+    lastUpdated?: string;
 };
 
 export type RelPathProps = {
@@ -37,11 +38,16 @@ const RelPath : FC<RelPathProps> = ({path, ...props}) => {
     );
 }
 
-const DefaultPage : FC<DefaultPage> = ({className, children, path, ...props}) => (
+const LastUpdatedDate : FC = ({children}) => (
+    <span className={styles.date}><b>Last Updated: </b>{children}</span>
+)
+
+const DefaultPage : FC<DefaultPage> = ({className, lastUpdated, children, path, ...props}) => (
     <Viewport
         className={clsx(styles.viewportOverrides, className)}
     >
         {path !== undefined ? <RelPath path={path!} /> : undefined}
+        {lastUpdated ? <LastUpdatedDate>{lastUpdated}</LastUpdatedDate> : undefined}
         {children}
     </Viewport>
 );
-- 
cgit v1.2.3

