Compare commits

..

No commits in common. "fd081f1c6f0899986d4c77770d938bb65628563c" and "440f0c40e51a599e05ef81b60060c17db3ab2118" have entirely different histories.

View file

@ -11,29 +11,27 @@ interface Props {
const { post } = Astro.props; const { post } = Astro.props;
const img = findImageByPath(post.image.path); const img = findImageByPath(post.image.path);
const localeDate = formatLocalizedDateString(post.date); const localeDate = formatLocalizedDateString(post.date)
--- ---
<div class="wide-container"> <div class="wide-container">
<div class="image-col rounded"> <div class="image-col col rounded">
<a href={`/blog/${post.slug}`}> <a href={`/blog/${post.slug}`}>
<Image src={img} alt={post.image.alt} layout="constrained" /> <Image src={img} alt={post.image.alt} layout="constrained" />
</a> </a>
</div> </div>
<div class="text-col"> <div class="text-col col">
<div class="top-info">
<span id="new">NEU!</span>
<span>{localeDate}</span>
<span> | </span>
<span>Autor: {post.author}</span>
<span> | </span>
<span>Lesezeit: {post.time2read} min</span>
</div>
<a href={`/blog/${post.slug}`} class="headline-link"> <a href={`/blog/${post.slug}`} class="headline-link">
<h2 class="headline">{post.title}</h2> <h2 class="headline">{post.title}</h2>
</a> </a>
<h7>{post.subtitle}</h7> <h7>{post.subtitle}</h7>
<div class="top-info">
<span>{localeDate}</span>
<span class="vertical-line"></span>
<span>Autor: {post.author}</span>
<span class="vertical-line"></span>
<span>Lesezeit: {post.time2read} min</span>
</div>
<p class="description">{post.description}</p> <p class="description">{post.description}</p>
</div> </div>
</div> </div>
@ -42,24 +40,23 @@ const localeDate = formatLocalizedDateString(post.date);
.wide-container { .wide-container {
display: flex; display: flex;
gap: 32px; gap: 32px;
padding: 64px; padding: 0 32px;
width: 100%; min-width: 80%;
background-image: linear-gradient( max-width: 90%;
to bottom, margin-bottom: 64px;
var(--primary-dark), }
var(--primary-color)
);
* { .col {
color: white; width: 50%;
} box-sizing: border-box;
min-width: 0;
min-height: 0;
} }
.text-col { .text-col {
width: 40%;
display: flex;
flex-direction: column; flex-direction: column;
justify-content: center; justify-content: flex-start;
margin: 32px 0;
} }
h2 { h2 {
@ -67,19 +64,17 @@ const localeDate = formatLocalizedDateString(post.date);
} }
.image-col { .image-col {
width: 60%;
position: relative; position: relative;
overflow: hidden; overflow: hidden;
} }
.image-col img { .image-col img {
position: absolute;
inset: 0;
width: 100%; width: 100%;
height: 100%; height: 100%;
max-height: 250px;
object-fit: cover; object-fit: cover;
object-position: center; object-position: center;
border: 2px solid white;
border-radius: 12px;
} }
.top-info { .top-info {
@ -89,12 +84,6 @@ const localeDate = formatLocalizedDateString(post.date);
color: lightslategray; color: lightslategray;
} }
#new {
color: var(--accent-color);
margin-right: 12px;
font-weight: bolder;
}
.vertical-line { .vertical-line {
color: #789; color: #789;
border-right-width: 2px; border-right-width: 2px;
@ -108,7 +97,7 @@ const localeDate = formatLocalizedDateString(post.date);
min-width: auto; min-width: auto;
} }
.text-col, .image-col { .col {
width: 100%; width: 100%;
} }