+
+ {/* Swiper - Autoplays Image Slideshow */}
+
+ {/* Each Image Presented in the Swiper */}
+
+
>
)
+ // ________________________________________________________________________________________________
}
export default Home
+// AutoRedirect() - Detects the user's browser language on page load
function autoRedirect() {
+
+ // User Language
let lang = global.navigator?.language || navigator?.userLanguage
+
+ // If language is chinese, redirect to "/zh-cn" version of the site
if (lang != null && (lang.toLowerCase() === 'zh-cn' || lang.toLowerCase().indexOf('zh') > 0)) {
console.log(window.location.pathname);
if (sessionStorage.getItem('auto_detect_redirect') !== 'true' && !window.location.pathname.startsWith('/zh-cn', false)) {
@@ -130,4 +173,5 @@ function autoRedirect() {
window.location.href = '/zh-cn'
}
}
+
}
diff --git a/home/src/pages/styles.module.css b/home/src/pages/styles.module.css
index ec05956c26c..38405e19485 100644
--- a/home/src/pages/styles.module.css
+++ b/home/src/pages/styles.module.css
@@ -1,5 +1,4 @@
/* stylelint-disable docusaurus/copyright-header */
-
/**
* CSS files with the .module.css suffix will be treated as CSS modules
* and scoped locally.
diff --git a/home/src/theme/BlogPostItems/index.js b/home/src/theme/BlogPostItems/index.js
new file mode 100644
index 00000000000..73ee74e1e6e
--- /dev/null
+++ b/home/src/theme/BlogPostItems/index.js
@@ -0,0 +1,91 @@
+import React from 'react';
+import {BlogPostProvider, useBlogPost} from '@docusaurus/plugin-content-blog/client';
+import Link from '@docusaurus/Link';
+import './styles.css'
+
+// import BlogPostItem from '@theme/BlogPostItem';
+// This is the default component that renders blog posts one by
+// one in a vertical list
+//_________________________________________________________________
+// export default function BlogPostItems({
+// items,
+// component: BlogPostItemComponent = BlogPostItem,
+// }) {
+// return (
+// <>
+// {items.map(({content: BlogPostContent}) => (
+//
+//
+//
+//
+//
+// ))}
+// >
+// );
+// }
+//_________________________________________________________________
+
+
+// _________________________________________________________________
+// REFACTORED BLOG SITE - Serafin O. Gargantiel III.
+// _________________________________________________________________
+
+// Renders a blog card out of data from a blog post
+function BlogCard() {
+
+ // Docusaurus Hook giving you access to the current post's metadata
+ // formats it for BlogCard rendering
+ const {metadata} = useBlogPost();
+ const {permalink, title, date, authors, description, tags} = metadata;
+ const formattedDate = new Date(date).toLocaleDateString('en-US', {
+ year: 'numeric',
+ month: 'long',
+ day: 'numeric',
+ });
+
+ // Rending a BlogCard
+ return (
+
+ );
+}
+
+// Main Component - Access each blog posts in items and renders each one
+// a BlogCard() as defined in the top. The className, "blog-grid", is a
+// column card grid.
+export default function BlogPostItems({items}) {
+ return (
+