Compare commits
2 Commits
442440454a
...
feat/tailw
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
f9160e4b98 | ||
|
|
67fad13998 |
@@ -44,67 +44,12 @@
|
|||||||
<div class="max-w-3xl mx-auto">
|
<div class="max-w-3xl mx-auto">
|
||||||
<div class="flex items-start space-x-6">
|
<div class="flex items-start space-x-6">
|
||||||
<div>
|
<div>
|
||||||
<h3 class="text-xl font-semibold text-gray-900">{{ .Params.author | default "Auteur" }}</h3>
|
<span class="text-2xl">Article rédigé par {{ .Params.author | default "Auteur" }}</span>
|
||||||
<p class="text-blue-600 font-medium mb-4">Rédacteur technologique & chercheur sur le futur du travail</p>
|
|
||||||
<p class="text-gray-700">{{ .Params.author_bio | default "Biographie de l'auteur ici." }}</p>
|
|
||||||
<div class="flex space-x-4 mt-4">
|
|
||||||
<a href="#" class="text-gray-600 hover:text-blue-600 transition-colors"><i class="fab fa-twitter"></i></a>
|
|
||||||
<a href="#" class="text-gray-600 hover:text-blue-600 transition-colors"><i class="fab fa-linkedin"></i></a>
|
|
||||||
<a href="#" class="text-gray-600 hover:text-blue-600 transition-colors"><i class="fab fa-medium"></i></a>
|
|
||||||
</div>
|
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<!-- Related Articles -->
|
|
||||||
<div class="py-12">
|
|
||||||
<div class="container mx-auto px-4 sm:px-6 lg:px-8">
|
|
||||||
<h2 class="text-2xl font-bold text-gray-900 mb-8 text-center">Articles connexes</h2>
|
|
||||||
<div class="grid grid-cols-1 md:grid-cols-3 gap-8">
|
|
||||||
{{ range first 3 (where .Site.RegularPages "Type" "post") }}
|
|
||||||
<div class="bg-white rounded-xl overflow-hidden shadow-md hover:shadow-lg transition-shadow">
|
|
||||||
{{ if .Params.featured_image }}
|
|
||||||
<img src="{{ .Params.featured_image }}" alt="Article" class="w-full h-48 object-cover">
|
|
||||||
{{ else }}
|
|
||||||
<img src="https://images.unsplash.com/photo-1581091226033-d5c48150dbaa?ixlib=rb-4.0.3&ixid=MnwxMjA3fDB8MHxwaG90by1wYWdlfHx8fGVufDB8fHx8&auto=format&fit=crop&w=1000&q=80" alt="Article" class="w-full h-48 object-cover">
|
|
||||||
{{ end }}
|
|
||||||
<div class="p-6">
|
|
||||||
<span class="text-sm font-medium text-blue-600">
|
|
||||||
{{ with .Params.categories }}
|
|
||||||
{{ range first 1 . }}
|
|
||||||
{{ . }}
|
|
||||||
{{ end }}
|
|
||||||
{{ end }}
|
|
||||||
</span>
|
|
||||||
<h3 class="text-xl font-semibold mt-2 mb-3">
|
|
||||||
<a href="{{ .Permalink }}" class="text-gray-900 hover:text-blue-600 transition-colors">{{ .Title }}</a>
|
|
||||||
</h3>
|
|
||||||
<p class="text-gray-600">{{ .Summary | truncate 100 }}</p>
|
|
||||||
<div class="flex items-center mt-4 text-sm text-gray-500">
|
|
||||||
<span>{{ .Date.Format "2 janvier 2006" }}</span>
|
|
||||||
<span class="mx-2">•</span>
|
|
||||||
<span>{{ .ReadingTime }} min de lecture</span>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
{{ end }}
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<!-- Newsletter -->
|
|
||||||
<div class="py-12 bg-blue-50">
|
|
||||||
<div class="container mx-auto px-4 sm:px-6 lg:px-8">
|
|
||||||
<div class="max-w-3xl mx-auto text-center">
|
|
||||||
<h2 class="text-2xl font-bold text-gray-900 mb-4">Rejoignez la newsletter</h2>
|
|
||||||
<p class="text-gray-700 mb-6">Restez informé des dernières actualités sur la technologie et le futur du travail.</p>
|
|
||||||
<form class="flex flex-col sm:flex-row gap-4 max-w-xl mx-auto">
|
|
||||||
<input type="email" placeholder="Votre adresse email" class="flex-grow px-4 py-3 rounded-lg border border-gray-300 focus:outline-none focus:ring-2 focus:ring-blue-500">
|
|
||||||
<button type="submit" class="bg-blue-600 hover:bg-blue-700 text-white px-6 py-3 rounded-lg font-medium transition-colors">S'abonner</button>
|
|
||||||
</form>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
{{ end }}
|
{{ end }}
|
||||||
|
|||||||
@@ -1,49 +1,87 @@
|
|||||||
{{ define "main" }}
|
{{ define "main" }}
|
||||||
{{ $authors := site.Data.wordpress.authors }}
|
<!-- layouts/author/list.html - Author posts listing -->
|
||||||
|
<div class="min-h-screen bg-white">
|
||||||
|
|
||||||
<div class="section-sm bg-gray-lighter">
|
<!-- Hero Section with Author Title -->
|
||||||
<div class="container text-center">
|
<section class="gradient-bg py-12 md:py-16 lg:py-20">
|
||||||
<h3 class="font-family-playfair">{{ .Title }}</h3>
|
<div class="container mx-auto px-4 sm:px-6 lg:px-8">
|
||||||
<p class="mt-2">Liste de tous les auteurs</p>
|
<div class="max-w-4xl mx-auto text-center">
|
||||||
</div><!-- end container -->
|
<h1 class="text-4xl md:text-5xl lg:text-6xl font-bold text-gray-900 mb-6">Tous les auteurs</h1>
|
||||||
</div>
|
|
||||||
|
|
||||||
<div class="section">
|
|
||||||
<div class="container">
|
|
||||||
<div class="author-list">
|
|
||||||
<div class="row">
|
|
||||||
{{ range $author := $authors }}
|
|
||||||
<div class="col-md-6 mb-4">
|
|
||||||
<article class="author-card-item h-100 card" data-author-name="{{ $author.name }}">
|
|
||||||
<div class="row g-0 align-items-center">
|
|
||||||
<div class="author-card-image col-md-4 p-2">
|
|
||||||
{{ with index $author.avatar_urls "96" }}
|
|
||||||
<img decoding="async" src="{{ . }}" alt="{{ $author.name }}" class="author-image img-fluid" loading="lazy">
|
|
||||||
{{ else }}
|
|
||||||
<img decoding="async" src="/assets/images/img-avatar-md@2x.jpg" alt="{{ $author.name }}" class="author-image img-fluid" loading="lazy">
|
|
||||||
{{ end }}
|
|
||||||
</div>
|
|
||||||
<div class="author-card-info col-md-8">
|
|
||||||
<div class="card-body">
|
|
||||||
<h5 class="card-title author-card-name">{{ $author.name }}</h5>
|
|
||||||
{{ with $author.description }}
|
|
||||||
<p class="card-text author-card-title">
|
|
||||||
<small class="text-muted author-card-title-text">{{ . }}</small>
|
|
||||||
</p>
|
|
||||||
{{ end }}
|
|
||||||
<div class="author-card-buttons mt-3">
|
|
||||||
<div class="author-card-button">
|
|
||||||
<a href="/author/{{ $author.slug | anchorize }}" class="author-button-link" aria-label="Voir les articles de {{ $author.name }}">Voir les articles<svg class="uikit-icon" style="width: 1em;" xmlns="http://www.w3.org/2000/svg" fill="none" viewBox="0 0 24 24"><path fill="var(--c-svg, currentColor)" d="M7.5 4.5V6h9.442L4.5 18.442 5.558 19.5 18 7.058V16.5h1.5v-12z"></path></svg></a>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</div>
|
</div>
|
||||||
</article>
|
|
||||||
</div>
|
</div>
|
||||||
{{ end }}
|
</section>
|
||||||
</div>
|
|
||||||
</div>
|
<!-- Author Bio Section -->
|
||||||
</div><!-- end container -->
|
{{ if .Data.Term }}
|
||||||
|
{{ $authorSlug := .Data.Term }}
|
||||||
|
{{ $authors := site.Data.wordpress.authors }}
|
||||||
|
{{ $author := index $authors $authorSlug }}
|
||||||
|
|
||||||
|
{{ if $author }}
|
||||||
|
<section class="py-12 bg-gray-50">
|
||||||
|
<div class="container mx-auto px-4 sm:px-6 lg:px-8">
|
||||||
|
<div class="max-w-3xl mx-auto">
|
||||||
|
<div class="flex items-start space-x-6">
|
||||||
|
<div class="flex-1">
|
||||||
|
<h3 class="text-2xl font-semibold text-gray-900">{{ $author.name }}</h3>
|
||||||
|
{{ with $author.description }}
|
||||||
|
<p class="text-gray-700 mt-2">{{ . }}</p>
|
||||||
|
{{ end }}
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</section>
|
||||||
|
{{ end }}
|
||||||
|
{{ end }}
|
||||||
|
|
||||||
|
<!-- Author's Articles Section -->
|
||||||
|
<section id="latest-articles" class="py-12 md:py-16">
|
||||||
|
<div class="container mx-auto px-4 sm:px-6 lg:px-8">
|
||||||
|
{{ $paginator := .Paginate .Pages 9 }}
|
||||||
|
|
||||||
|
{{ if gt (len $paginator.Pages) 0 }}
|
||||||
|
<div class="grid grid-cols-1 md:grid-cols-2 lg:grid-cols-3 gap-8 mb-12">
|
||||||
|
{{ range $paginator.Pages }}
|
||||||
|
<div class="bg-white rounded-xl overflow-hidden shadow-md article-card">
|
||||||
|
<div class="p-6">
|
||||||
|
<div class="flex flex-wrap gap-2 mb-3">
|
||||||
|
{{ if .Params.categories }}
|
||||||
|
{{ range first 1 .Params.categories }}
|
||||||
|
<a href="/categories/{{ . | urlize }}" class="bg-blue-100 text-blue-800 text-xs font-medium px-2 py-1 rounded hover:underline">{{ . }}</a>
|
||||||
|
{{ end }}
|
||||||
|
{{ end }}
|
||||||
|
</div>
|
||||||
|
<h3 class="text-lg font-bold text-gray-900 mb-3"><a href="{{ .RelPermalink }}">{{ .Title }}</a></h3>
|
||||||
|
<p class="text-gray-600 text-sm mb-4">
|
||||||
|
{{ if .Params.excerpt }}
|
||||||
|
{{ .Params.excerpt }}
|
||||||
|
{{ else if .Summary }}
|
||||||
|
{{ .Summary }}
|
||||||
|
{{ else }}
|
||||||
|
{{ truncate 200 .Content }}
|
||||||
|
{{ end }}
|
||||||
|
</p>
|
||||||
|
<div class="flex items-center justify-between text-sm text-gray-500">
|
||||||
|
<a href="{{ .RelPermalink }}" class="text-blue-600 hover:text-blue-800 font-medium text-sm">Lire la suite →</a>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
{{ end }}
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<!-- Pagination -->
|
||||||
|
<div class="flex justify-center mt-12">
|
||||||
|
{{ if gt .Paginator.TotalPages 1 }}
|
||||||
|
{{ partial "pagination-tailwind.html" .Paginator }}
|
||||||
|
{{ end }}
|
||||||
|
</div>
|
||||||
|
{{ else }}
|
||||||
|
<div class="text-center py-12">
|
||||||
|
<p class="text-xl text-gray-600">Aucun article trouvé pour cet auteur.</p>
|
||||||
|
</div>
|
||||||
|
{{ end }}
|
||||||
|
</div>
|
||||||
|
</section>
|
||||||
</div>
|
</div>
|
||||||
{{ end }}
|
{{ end }}
|
||||||
|
|||||||
@@ -1,56 +0,0 @@
|
|||||||
{{ define "main" }}
|
|
||||||
{{ $authorName := .Params.author }}
|
|
||||||
{{ $authorSlug := .Params.author_slug }}
|
|
||||||
{{ $authorPosts := where .Site.RegularPages "Params.author" $authorName }}
|
|
||||||
|
|
||||||
<div class="section-sm bg-gray-lighter">
|
|
||||||
<div class="container text-center">
|
|
||||||
<h1 class="font-family-playfair">{{ .Title }}</h1>
|
|
||||||
<p class="mt-2">Retrouvez toutes les pages utiles du site ici.</p>
|
|
||||||
</div><!-- end container -->
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<!-- Blog section -->
|
|
||||||
<div class="section">
|
|
||||||
<div class="container">
|
|
||||||
<div class="row g-4">
|
|
||||||
<div class="col-12 col-sm-10 offset-sm-1 col-md-8 offset-md-2">
|
|
||||||
{{ $paginationLimit := 10 }}
|
|
||||||
{{ if .Site.Params.paginationLimit }}{{ $paginationLimit = .Site.Params.paginationLimit }}{{ end }}
|
|
||||||
{{ $paginator := .Paginate $authorPosts $paginationLimit }}
|
|
||||||
|
|
||||||
{{ if gt (len $authorPosts) 0 }}
|
|
||||||
{{ range $paginator.Pages }}
|
|
||||||
<!-- Blog Post box -->
|
|
||||||
<div class="mb-5">
|
|
||||||
<div class="mt-4">
|
|
||||||
<h2><a class="text-link-1" href="{{ .RelPermalink }}">{{ .Title }}</a></h2>
|
|
||||||
{{ if .Params.excerpt }}
|
|
||||||
<p>{{ .Params.excerpt }}</p>
|
|
||||||
{{ else if .Summary }}
|
|
||||||
<p>{{ .Summary }}</p>
|
|
||||||
{{ else }}
|
|
||||||
<p>{{ truncate 200 .Content }}</p>
|
|
||||||
{{ end }}
|
|
||||||
<div class="mt-3">
|
|
||||||
<a class="button-text-1" href="{{ .RelPermalink }}">Lire la suite</a>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
<!-- End Blog Post box -->
|
|
||||||
{{ end }}
|
|
||||||
|
|
||||||
<!-- Pagination -->
|
|
||||||
{{ partial "pagination.html" (dict "Paginator" .Paginator "Page" .) }}
|
|
||||||
{{ else }}
|
|
||||||
<div class="text-center py-5">
|
|
||||||
<h4>Aucun article trouvé</h4>
|
|
||||||
<p>Aucun article n'a été trouvé pour cet auteur.</p>
|
|
||||||
</div>
|
|
||||||
{{ end }}
|
|
||||||
</div>
|
|
||||||
</div><!-- end row -->
|
|
||||||
</div><!-- end container -->
|
|
||||||
</div>
|
|
||||||
<!-- end Blog section -->
|
|
||||||
{{ end }}
|
|
||||||
@@ -1,40 +1,58 @@
|
|||||||
<footer class="bg-gray-900 text-white py-12">
|
<footer class="bg-gray-900 text-white py-12">
|
||||||
<div class="container mx-auto px-4 sm:px-6 lg:px-8">
|
<div class="container mx-auto px-4 sm:px-6 lg:px-8">
|
||||||
<div class="grid grid-cols-1 md:grid-cols-4 gap-8">
|
<div class="grid grid-cols-1 sm:grid-cols-2 lg:grid-cols-3 gap-8">
|
||||||
<div>
|
<div class="col-span-1">
|
||||||
<h3 class="text-xl font-bold mb-4">TechInsights</h3>
|
<h3 class="uppercase tracking-wider text-xl font-bold">{{ .Site.Title }}</h3>
|
||||||
<p class="text-gray-400">Exploring the future of work and technology through thoughtful analysis and commentary.</p>
|
|
||||||
</div>
|
</div>
|
||||||
<div>
|
|
||||||
<h4 class="font-semibold mb-4">Explore</h4>
|
<div class="col-span-1">
|
||||||
<ul class="space-y-2">
|
<h6 class="text-sm font-medium uppercase mb-4">Pages</h6>
|
||||||
<li><a href="#" class="text-gray-400 hover:text-white">Home</a></li>
|
<ul class="list-none space-y-2">
|
||||||
<li><a href="#" class="text-gray-400 hover:text-white">Articles</a></li>
|
<li><a href="/" class="text-gray-400 hover:text-white">Accueil</a></li>
|
||||||
<li><a href="#" class="text-gray-400 hover:text-white">Topics</a></li>
|
{{ if .Site.Data.wordpress }}
|
||||||
<li><a href="#" class="text-gray-400 hover:text-white">About</a></li>
|
{{ range $index, $element := .Site.Data.wordpress.navigation }}
|
||||||
|
<li>
|
||||||
|
<a href="/pages/{{ $element.slug }}" class="text-gray-400 hover:text-white">{{ $element.title }}</a>
|
||||||
|
</li>
|
||||||
|
{{ end }}
|
||||||
|
{{ end }}
|
||||||
</ul>
|
</ul>
|
||||||
</div>
|
</div>
|
||||||
<div>
|
|
||||||
<h4 class="font-semibold mb-4">Topics</h4>
|
<div class="col-span-1">
|
||||||
<ul class="space-y-2">
|
<h6 class="text-sm font-medium uppercase mb-4">Toutes les catégories</h6>
|
||||||
<li><a href="#" class="text-gray-400 hover:text-white">AI</a></li>
|
<ul class="list-none space-y-2">
|
||||||
<li><a href="#" class="text-gray-400 hover:text-white">Remote Work</a></li>
|
{{ if .Site.Data.wordpress }}
|
||||||
<li><a href="#" class="text-gray-400 hover:text-white">Productivity</a></li>
|
{{ range $index, $element := .Site.Data.wordpress.categories }}
|
||||||
<li><a href="#" class="text-gray-400 hover:text-white">Web3</a></li>
|
{{ if and (ne $element.name "Featured") (gt $element.count 0) }}
|
||||||
|
<li>
|
||||||
|
<a class="text-gray-400 hover:text-white" href="/{{ $element.slug }}">{{ $element.name }}</a>
|
||||||
|
</li>
|
||||||
|
{{ end }}
|
||||||
|
{{ end }}
|
||||||
|
{{ end }}
|
||||||
</ul>
|
</ul>
|
||||||
</div>
|
</div>
|
||||||
<div>
|
|
||||||
<h4 class="font-semibold mb-4">Connect</h4>
|
|
||||||
<div class="flex space-x-4">
|
|
||||||
<a href="#" class="text-gray-400 hover:text-white"><i class="fab fa-twitter text-xl"></i></a>
|
</div><!-- end grid -->
|
||||||
<a href="#" class="text-gray-400 hover:text-white"><i class="fab fa-linkedin text-xl"></i></a>
|
</div><!-- end container -->
|
||||||
<a href="#" class="text-gray-400 hover:text-white"><i class="fab fa-instagram text-xl"></i></a>
|
<div class="bg-black py-4 mt-8">
|
||||||
<a href="#" class="text-gray-400 hover:text-white"><i class="fab fa-github text-xl"></i></a>
|
<div class="container mx-auto px-4 sm:px-6 lg:px-8">
|
||||||
|
<div class="flex flex-col md:flex-row items-center justify-between gap-2 lg:gap-3">
|
||||||
|
<div class="text-center md:text-start">
|
||||||
|
<p class="text-gray-400">© {{ now.Format "2006" }} {{ .Site.Title }}, All Rights Reserved.</p>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
<div class="text-center md:text-end">
|
||||||
</div>
|
<ul class="flex justify-center md:justify-end space-x-4">
|
||||||
<div class="border-t border-gray-800 mt-8 pt-8 text-center text-gray-400">
|
<li><a class="w-8 h-8 rounded-full flex items-center justify-center bg-blue-600 hover:bg-blue-700 text-white" href="https://www.facebook.com/mistergeekfrance"><i class="bi bi-facebook"></i></a></li>
|
||||||
<p>© {{ now.Format "2006" }} TechInsights. All rights reserved.</p>
|
<!-- <li><a class="w-8 h-8 rounded-full flex items-center justify-center bg-blue-400 hover:bg-blue-500 text-white" href="#"><i class="bi bi-twitter-x"></i></a></li> -->
|
||||||
</div>
|
<!-- <li><a class="w-8 h-8 rounded-full flex items-center justify-center bg-red-600 hover:bg-red-700 text-white" href="#"><i class="bi bi-pinterest"></i></a></li> -->
|
||||||
|
<!-- <li><a class="w-8 h-8 rounded-full flex items-center justify-center bg-pink-600 hover:bg-pink-700 text-white" href="#"><i class="bi bi-instagram"></i></a></li> -->
|
||||||
|
</ul>
|
||||||
|
</div>
|
||||||
|
</div><!-- end flex -->
|
||||||
|
</div><!-- end container -->
|
||||||
</div>
|
</div>
|
||||||
</footer>
|
</footer>
|
||||||
|
|||||||
@@ -32,9 +32,6 @@
|
|||||||
<i class="fas text-xl transition-transform duration-300 ease-in-out"
|
<i class="fas text-xl transition-transform duration-300 ease-in-out"
|
||||||
:class="mobileMenuOpen ? 'fa-times' : 'fa-bars'"></i>
|
:class="mobileMenuOpen ? 'fa-times' : 'fa-bars'"></i>
|
||||||
</button>
|
</button>
|
||||||
<button class="hidden md:block bg-blue-600 hover:bg-blue-700 text-white px-4 py-2 rounded-lg font-medium">
|
|
||||||
Subscribe
|
|
||||||
</button>
|
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
13
layouts/partials/newsletter.html
Normal file
13
layouts/partials/newsletter.html
Normal file
@@ -0,0 +1,13 @@
|
|||||||
|
<!-- Newsletter -->
|
||||||
|
<div class="py-12 bg-blue-50">
|
||||||
|
<div class="container mx-auto px-4 sm:px-6 lg:px-8">
|
||||||
|
<div class="max-w-3xl mx-auto text-center">
|
||||||
|
<h2 class="text-2xl font-bold text-gray-900 mb-4">Rejoignez la newsletter</h2>
|
||||||
|
<p class="text-gray-700 mb-6">Restez informé des dernières actualités sur la technologie et le futur du travail.</p>
|
||||||
|
<form class="flex flex-col sm:flex-row gap-4 max-w-xl mx-auto">
|
||||||
|
<input type="email" placeholder="Votre adresse email" class="flex-grow px-4 py-3 rounded-lg border border-gray-300 focus:outline-none focus:ring-2 focus:ring-blue-500">
|
||||||
|
<button type="submit" class="bg-blue-600 hover:bg-blue-700 text-white px-6 py-3 rounded-lg font-medium transition-colors">S'abonner</button>
|
||||||
|
</form>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
35
layouts/partials/related-posts.html
Normal file
35
layouts/partials/related-posts.html
Normal file
@@ -0,0 +1,35 @@
|
|||||||
|
<!-- Related Articles -->
|
||||||
|
<div class="py-12">
|
||||||
|
<div class="container mx-auto px-4 sm:px-6 lg:px-8">
|
||||||
|
<h2 class="text-2xl font-bold text-gray-900 mb-8 text-center">Articles connexes</h2>
|
||||||
|
<div class="grid grid-cols-1 md:grid-cols-3 gap-8">
|
||||||
|
{{ range first 3 (where .Site.RegularPages "Type" "post") }}
|
||||||
|
<div class="bg-white rounded-xl overflow-hidden shadow-md hover:shadow-lg transition-shadow">
|
||||||
|
{{ if .Params.featured_image }}
|
||||||
|
<img src="{{ .Params.featured_image }}" alt="Article" class="w-full h-48 object-cover">
|
||||||
|
{{ else }}
|
||||||
|
<img src="https://images.unsplash.com/photo-1581091226033-d5c48150dbaa?ixlib=rb-4.0.3&ixid=MnwxMjA3fDB8MHxwaG90by1wYWdlfHx8fGVufDB8fHx8&auto=format&fit=crop&w=1000&q=80" alt="Article" class="w-full h-48 object-cover">
|
||||||
|
{{ end }}
|
||||||
|
<div class="p-6">
|
||||||
|
<span class="text-sm font-medium text-blue-600">
|
||||||
|
{{ with .Params.categories }}
|
||||||
|
{{ range first 1 . }}
|
||||||
|
{{ . }}
|
||||||
|
{{ end }}
|
||||||
|
{{ end }}
|
||||||
|
</span>
|
||||||
|
<h3 class="text-xl font-semibold mt-2 mb-3">
|
||||||
|
<a href="{{ .Permalink }}" class="text-gray-900 hover:text-blue-600 transition-colors">{{ .Title }}</a>
|
||||||
|
</h3>
|
||||||
|
<p class="text-gray-600">{{ .Summary | truncate 100 }}</p>
|
||||||
|
<div class="flex items-center mt-4 text-sm text-gray-500">
|
||||||
|
<span>{{ .Date.Format "2 janvier 2006" }}</span>
|
||||||
|
<span class="mx-2">•</span>
|
||||||
|
<span>{{ .ReadingTime }} min de lecture</span>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
{{ end }}
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
Reference in New Issue
Block a user