Mejora estética y participa ahora

This commit is contained in:
2024-11-06 17:52:30 +01:00
parent f3221dce96
commit c02b3771c3
3 changed files with 342 additions and 289 deletions

View File

@@ -11,7 +11,7 @@ const posts = await Astro.glob("../pages/posts/*.mdx");
<h5 class="card-title">
{post.frontmatter.titulo}
</h5>
<p class="card-text">
<p class="card-text post-content">
{post.frontmatter.descripcion}
...
</p>
@@ -23,4 +23,15 @@ const posts = await Astro.glob("../pages/posts/*.mdx");
</div>
))
}
</div>
</div>
<style>
.post-content {
display: -webkit-box;
-webkit-box-orient: vertical;
overflow: hidden;
-webkit-line-clamp: 4; /* Limita a 4 líneas */
line-height: 1.5; /* Ajusta según el diseño */
max-height: calc(1.5em * 4); /* Calcula la altura máxima */
}
</style>