Skip to content

Commit f7e7eda

Browse files
authored
Add config for index full post
1 parent 8441320 commit f7e7eda

File tree

1 file changed

+13
-9
lines changed

1 file changed

+13
-9
lines changed

src/Views/blogetc/partials/index_loop.blade.php

Lines changed: 13 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -5,16 +5,20 @@
55
<div class="" style='max-width:600px; margin: 50px auto; background: #fffbea;border-radius:3px;padding:0;' >
66

77
<div class='text-center'>
8-
<?=$post->image_tag("medium", true, ''); ?>
9-
</div>
10-
<div style='padding:10px;'>
11-
<h3 class=''><a href='{{$post->url()}}'>{{$post->title}}</a></h3>
12-
<h5 class=''>{{$post->subtitle}}</h5>
8+
<?=$post->image_tag("medium", true, ''); ?>
9+
</div>
10+
<div style='padding:10px;'>
11+
<h3 class=''><a href='{{$post->url()}}'>{{$post->title}}</a></h3>
12+
<h5 class=''>{{$post->subtitle}}</h5>
1313

14-
<p>{!! mb_strimwidth($post->post_body_output(), 0, 400, "...") !!}</p>
14+
@if (config('index_full_post'))
15+
<p>{!! $post->post_body_output() !!}</p>
16+
@else
17+
<p>{!! mb_strimwidth($post->post_body_output(), 0, 400, "...") !!}</p>
18+
@endif
1519

16-
<div class='text-center'>
17-
<a href="{{$post->url()}}" class="btn btn-primary">View Post</a>
18-
</div>
20+
<div class='text-center'>
21+
<a href="{{$post->url()}}" class="btn btn-primary">View Post</a>
1922
</div>
23+
</div>
2024
</div>

0 commit comments

Comments
 (0)