File tree Expand file tree Collapse file tree 1 file changed +20
-5
lines changed Expand file tree Collapse file tree 1 file changed +20
-5
lines changed Original file line number Diff line number Diff line change @@ -101,12 +101,27 @@ <h1 class="text-2xl font-sans text-navysciam font-bold">{{ author.name }}</h1>
101
101
< div class ="bg-white py-10 px-14 rounded-lg shadow-md ">
102
102
< h2 class ="text-2xl font-sans text-navysciam font-bold my-4 "> Articles publiés</ h2 >
103
103
< div >
104
- {% for post in site.posts %}
105
- {% if author_username == post.author or post.auteurs contains author_username %}
106
- {% include postbox.html %}
107
- < br >
108
- {% endif %}
104
+ {% for post in paginator.posts %}
105
+ {% include postbox.html %}
106
+ < br >
109
107
{% endfor %}
110
108
</ div >
111
109
</ div >
110
+
111
+ {% if paginator.total_pages > 1 %}
112
+ < ul class ="flex justify-center list-none mt-6 ">
113
+ {% if paginator.previous_page %}
114
+ < li class ="mx-2 ">
115
+ < a class ="bg-gray-200 hover:bg-gray-300 text-black py-2 px-4 rounded "
116
+ href ="{{ paginator.previous_page_path | relative_url | replace: '//', '/' }} "> ← Articles précédents</ a >
117
+ </ li >
118
+ {% endif %}
119
+ {% if paginator.next_page %}
120
+ < li class ="mx-2 ">
121
+ < a class ="bg-gray-200 hover:bg-gray-300 text-black py-2 px-4 rounded "
122
+ href ="{{ paginator.next_page_path | relative_url | replace: '//', '/' }} "> Articles suivants →</ a >
123
+ </ li >
124
+ {% endif %}
125
+ </ ul >
126
+ {% endif %}
112
127
</ div >
You can’t perform that action at this time.
0 commit comments