Skip to content

Commit e869a7b

Browse files
committed
wip
1 parent fc6bcc5 commit e869a7b

1 file changed

Lines changed: 14 additions & 26 deletions

File tree

Lines changed: 14 additions & 26 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
<x-app-layout>
22
<div class="fixed bg-dark-200 bg-doodles h-full w-full -z-10"></div>
3-
<div class="bg-dark-100 max-w-(--breakpoint-lg) mt mx-auto px-4 lg:px-12 py-12 lg:my-48">
3+
<div class="bg-dark-100 max-w-(--breakpoint-lg) mx-auto px-4 lg:px-12 py-12 lg:mt-48 lg:mb-12">
44
<h1 class="text-4xl font-medium text-neutral-200 leading-snug">{{ $post->title }}</h1>
55
<div class="flex flex-col md:flex-row md:items-center mb-4 mt-3 md:space-x-3 space-y-2 md:space-y-0">
66
@if($post->is_published)
@@ -21,30 +21,18 @@
2121
<section class="markup images-centered border-neutral-700 border-t pt-8">
2222
@markdown($post->text ?? '')
2323
</section>
24-
25-
@if($relatedPosts->isNotEmpty())
26-
<section class="border-neutral-700 border-t pt-8 mt-8">
27-
<h3 class="text-xl text-neutral-200 font-medium mb-6">Related Posts</h3>
28-
<div class="grid grid-cols-1 md:grid-cols-2 lg:grid-cols-3 gap-6">
29-
@foreach($relatedPosts as $relatedPost)
30-
<a href="{{ route('posts.show', $relatedPost) }}" class="block group">
31-
@if($relatedPost->getFirstMedia('thumbnail'))
32-
<img
33-
src="{{ $relatedPost->getFirstMedia('thumbnail')->getUrl('thumbnail') }}"
34-
alt="{{ $relatedPost->title }}"
35-
class="w-full h-40 object-cover rounded-lg mb-3"
36-
>
37-
@else
38-
<div class="w-full h-40 bg-neutral-800 rounded-lg mb-3 flex items-center justify-center">
39-
<span class="text-neutral-500 text-sm">No image</span>
40-
</div>
41-
@endif
42-
<h4 class="text-neutral-200 group-hover:text-ocean transition-colors">{{ $relatedPost->title }}</h4>
43-
<span class="text-sm text-neutral-400">{{ $relatedPost->published_at->format('d M Y') }}</span>
44-
</a>
45-
@endforeach
46-
</div>
47-
</section>
48-
@endif
4924
</div>
25+
26+
@if($relatedPosts->isNotEmpty())
27+
<section class="max-w-(--breakpoint-lg) mx-auto px-4 lg:px-0 py-12 lg:mb-48">
28+
<h3 class="text-3xl text-neutral-200 text-center font-medium uppercase font-heading">Related Posts</h3>
29+
<div class="border-b-2 border-ocean w-32 mx-auto mt-2 mb-10"></div>
30+
31+
<ul class="grid grid-cols-1 lg:grid-cols-3">
32+
@foreach($relatedPosts as $post)
33+
<x-post :post="$post" />
34+
@endforeach
35+
</ul>
36+
</section>
37+
@endif
5038
</x-app-layout>

0 commit comments

Comments
 (0)