diff --git a/pages/blog/index.page.tsx b/pages/blog/index.page.tsx index a866346cf..ea863c5cc 100644 --- a/pages/blog/index.page.tsx +++ b/pages/blog/index.page.tsx @@ -226,7 +226,7 @@ export default function StaticMarkdownPage({ {/* filterTag === frontmatter.type && */} -
+
{blogPosts .filter((post) => { if (!currentFilterTag || currentFilterTag === 'All') return true; @@ -241,88 +241,59 @@ export default function StaticMarkdownPage({ }) .map((blogPost: any) => { const { frontmatter, content } = blogPost; - const date = new Date(frontmatter.date); const timeToRead = Math.ceil(readingTime(content).minutes); return (
-
+
-
-
+
+ {frontmatter.title} +
+
-
-
{ - e.preventDefault(); - e.stopPropagation(); - - if (frontmatter.type) { - setCurrentFilterTag(frontmatter.type); - history.replaceState( - null, - '', - `/blog?type=${frontmatter.type}`, - ); - } - }} - > - {frontmatter.type || 'Unknown Type'} -
+
+ {frontmatter.type || 'Unknown Type'}
-
+
{frontmatter.title}
-
-
-
-
- {(frontmatter.authors || []).map( - (author: Author, index: number) => ( -
2 - ? 'h-8 w-8' - : 'h-11 w-11' - }`} - style={{ - backgroundImage: `url(${author.photo})`, - zIndex: 10 - index, - }} - /> - ), - )} -
- -
-
+
+
+
+ {(frontmatter.authors || []).map( + (author: Author, index: number) => ( +
2 + ? 'h-8 w-8' + : 'h-11 w-11' + }`} + style={{ + backgroundImage: `url(${author.photo})`, + zIndex: 10 - index, + }} + /> + ), + )} +
+
{frontmatter.authors.length > 2 ? ( <> {frontmatter.authors @@ -346,22 +317,46 @@ export default function StaticMarkdownPage({ ), ) )} -
- -
- {frontmatter.date && ( - - {date.toLocaleDateString('en-us', { - year: 'numeric', - month: 'long', - day: 'numeric', - })} - - )}{' '} - · {timeToRead} min read +
+ {frontmatter.date && ( + + {new Date( + frontmatter.date, + ).toLocaleDateString('en-us', { + year: 'numeric', + month: 'long', + day: 'numeric', + })} + + )} +
+
+ + {timeToRead} min read + + + Read More + + + + +
diff --git a/styles/globals.css b/styles/globals.css index 7d786ece1..f51290cdb 100644 --- a/styles/globals.css +++ b/styles/globals.css @@ -300,3 +300,25 @@ border-radius: 4px; */ .scrollbar-hidden::-webkit-scrollbar { display: none; } + +@keyframes shine { + from { + transform: translateX(-100%); + } + to { + transform: translateX(200%); + } +} + +.shine-animation { + animation: shine 2s infinite; +} + +.group { + transition: all 0.3s ease; +} + +.group:hover { + transform: translateY(-2px); +} +