Compare commits

..

2 commits

Author SHA1 Message Date
f1a673970a Add a new article 2025-05-15 20:29:47 +09:00
034a317648 Update some formats of this blog 2025-05-15 20:18:36 +09:00
7 changed files with 51 additions and 11 deletions

View file

@ -5,6 +5,7 @@ author: 'Nakahara Daisuke'
tags: ["introduction"]
---
# Hello!
Hello, my name is Daisuke.
This is my first blog post. Nice to meet you.

14
src/blog/post-2.md Normal file
View file

@ -0,0 +1,14 @@
---
title: 'I Have Finally Published My Blog Website'
pubDate: 2025-05-15
author: 'Nakahara Daisuke'
tags: []
---
I have finally published my blog website.
Its infrastructure relies on AWS, and I use Microsoft Copilot to manage the hosting.
This tool is particularly useful because it allows me to inquire about the contents of tags opened in Microsoft Edge.
Thank you.

View file

@ -15,7 +15,9 @@ const { pageTitle } = Astro.props;
</head>
<body>
<Header />
<h1>{pageTitle}</h1>
<h1 class="page-title">
{pageTitle}
</h1>
<slot />
<Footer>
<script>
@ -23,3 +25,9 @@ const { pageTitle } = Astro.props;
</script>
</body>
</html>
<style>
.page-title {
font-size: 2.8rem;
}
</style>

View file

@ -12,8 +12,7 @@ const optionsForDate = {
---
<BaseLayout pageTitle={frontmatter.title}>
<p>Created on: {frontmatter.pubDate.toLocaleDateString("ja-JP", optionsForDate)}</p>
<p>Written by: {frontmatter.author}</p>
<p>Created on: {frontmatter.pubDate.toLocaleDateString("en-US", optionsForDate)}</p>
<p><em>{frontmatter.description}</em></p>
<div class="tags">
{
@ -24,7 +23,9 @@ const optionsForDate = {
))
}
</div>
<slot />
<article class="markdown-content">
<slot />
</article>
</BaseLayout>
<style>
@ -45,4 +46,20 @@ const optionsForDate = {
font-size: 1.15em;
background-color: #f8fcfd;
}
.markdown-content {
font-family: sans-serif;
font-size: 1.2rem;
}
.markdown-content h1 {
font-size: 1.9rem;
}
.markdown-content h2 {
font-size: 1.75rem;
}
.markdown-content h3 {
font-size: 1.5rem;
}
</style>

View file

@ -20,10 +20,10 @@ const pageTitle = "Latest Posts";
<BlogPost
url={`/posts/${post.id}/`}
title={post.data.title}
datetime={post.data.pubDate.toLocaleDateString("ja-JP", {
datetime={post.data.pubDate.toLocaleDateString("en-US", {
year: "numeric",
month: "2-digit",
day: "2-digit",
month: "long",
day: "numeric",
})}
/>
))

View file

@ -45,10 +45,10 @@ const allPosts = await getCollection("blog");
<BlogPost
url={`/posts/${post.id}/`}
title={post.data.title}
datetime={post.data.pubDate.toLocaleDateString("ja-JP", {
datetime={post.data.pubDate.toLocaleDateString("en-US", {
year: "numeric",
month: "2-digit",
day: "2-digit",
month: "long",
day: "numeric",
})}
/>
))