From fdfcc5aca14b49302085fdeb0ac1bc5614881732 Mon Sep 17 00:00:00 2001 From: Antoine M Date: Thu, 21 Dec 2023 15:46:59 +0100 Subject: [PATCH] line clamp after 4lines --- template-components/cards/card-news.css | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/template-components/cards/card-news.css b/template-components/cards/card-news.css index 5601118..1dbd976 100644 --- a/template-components/cards/card-news.css +++ b/template-components/cards/card-news.css @@ -49,7 +49,13 @@ &__title { @apply !text-lg font-bold text-secondary mb-1; + overflow: hidden; + text-overflow: ellipsis; line-height: 1.2 !important; + display: -webkit-box; + -webkit-line-clamp: 4; /* number of lines to show */ + line-clamp: 4; + -webkit-box-orient: vertical; } .cta--read-more { @apply text-neutral-900 mt-auto;