fix: restyle pager chips and restore theme ad slots
Replace the loose page-count label with a SaBlog-style 6 / 316 chip, wire inject/stylevar HTML into list and post views, and flush page cache when ads are saved. Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
@@ -5,6 +5,7 @@
|
||||
<div class="container main-layout">
|
||||
<main class="content">
|
||||
<h1 class="list-title">文章归档</h1>
|
||||
@include('partials.theme-inject', ['point' => 'content_top'])
|
||||
|
||||
@forelse($archives as $year => $months)
|
||||
<h2 class="archive-year">{{ $year }} 年</h2>
|
||||
@@ -24,6 +25,7 @@
|
||||
@empty
|
||||
<div class="empty">暂无归档</div>
|
||||
@endforelse
|
||||
@include('partials.theme-inject', ['point' => 'content_bottom'])
|
||||
</main>
|
||||
@include('partials.sidebar')
|
||||
</div>
|
||||
|
||||
@@ -12,6 +12,7 @@
|
||||
@endif
|
||||
|
||||
@include('partials.view-mode-switcher')
|
||||
@include('partials.theme-inject', ['point' => 'content_top'])
|
||||
|
||||
@forelse($posts as $post)
|
||||
@include('partials.post-card', ['post' => $post])
|
||||
@@ -20,6 +21,7 @@
|
||||
@endforelse
|
||||
|
||||
@include('partials.pagination', ['paginator' => $posts])
|
||||
@include('partials.theme-inject', ['point' => 'content_bottom'])
|
||||
</main>
|
||||
@include('partials.sidebar')
|
||||
</div>
|
||||
|
||||
@@ -25,6 +25,7 @@
|
||||
|
||||
|
||||
@include('partials.view-mode-switcher')
|
||||
@include('partials.theme-inject', ['point' => 'content_top'])
|
||||
|
||||
@forelse($posts as $post)
|
||||
@include('partials.post-card', ['post' => $post])
|
||||
@@ -33,6 +34,7 @@
|
||||
@endforelse
|
||||
|
||||
@include('partials.pagination', ['paginator' => $posts])
|
||||
@include('partials.theme-inject', ['point' => 'content_bottom'])
|
||||
</main>
|
||||
@include('partials.sidebar')
|
||||
</div>
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
@stack('theme:footer')
|
||||
@include('partials.theme-inject', ['point' => 'footer'])
|
||||
<footer class="site-footer">
|
||||
<div class="container">
|
||||
<p>
|
||||
|
||||
@@ -29,4 +29,4 @@
|
||||
</nav>
|
||||
</div>
|
||||
</header>
|
||||
@stack('theme:header')
|
||||
@include('partials.theme-inject', ['point' => 'header'])
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
@if ($paginator->hasPages())
|
||||
<nav class="pagination-links" role="navigation" aria-label="分页">
|
||||
<span class="pagination-info">第 {{ $paginator->currentPage() }} / {{ $paginator->lastPage() }} 页</span>
|
||||
<span class="pagination-info">{{ $paginator->currentPage() }} / {{ $paginator->lastPage() }}</span>
|
||||
|
||||
@if ($paginator->onFirstPage())
|
||||
<span class="disabled">«</span>
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
<aside class="sidebar">
|
||||
@stack('theme:sidebar_top')
|
||||
@include('partials.theme-inject', ['point' => 'sidebar_top'])
|
||||
<section class="widget">
|
||||
<h3 class="widget-title">分类</h3>
|
||||
<ul class="widget-list">
|
||||
@@ -84,5 +84,5 @@
|
||||
<li>标签:{{ $blogStats['tags'] }} 个</li>
|
||||
</ul>
|
||||
</section>
|
||||
@stack('theme:sidebar_bottom')
|
||||
|
||||
@include('partials.theme-inject', ['point' => 'sidebar_bottom'])
|
||||
</aside>
|
||||
|
||||
@@ -0,0 +1,6 @@
|
||||
@php
|
||||
$injected = trim($__env->yieldPushContent('theme:'.$point));
|
||||
@endphp
|
||||
@if($injected !== '')
|
||||
<div class="theme-inject theme-inject-{{ $point }}">{!! $injected !!}</div>
|
||||
@endif
|
||||
@@ -11,6 +11,7 @@
|
||||
</form>
|
||||
|
||||
@include('partials.view-mode-switcher')
|
||||
@include('partials.theme-inject', ['point' => 'content_top'])
|
||||
|
||||
@forelse($posts as $post)
|
||||
@include('partials.post-card', ['post' => $post])
|
||||
@@ -19,6 +20,7 @@
|
||||
@endforelse
|
||||
|
||||
@include('partials.pagination', ['paginator' => $posts])
|
||||
@include('partials.theme-inject', ['point' => 'content_bottom'])
|
||||
</main>
|
||||
@include('partials.sidebar')
|
||||
</div>
|
||||
|
||||
@@ -50,10 +50,11 @@
|
||||
<span>· 阅读 {{ $post->views }}</span>
|
||||
</div>
|
||||
|
||||
@stack('theme:post_content_top')
|
||||
@include('partials.theme-inject', ['point' => 'post_content_top'])
|
||||
<div class="post-content">
|
||||
{!! $contentHtml !!}
|
||||
</div>
|
||||
@include('partials.theme-inject', ['point' => 'post_content_bottom'])
|
||||
|
||||
@if($post->tags->isNotEmpty())
|
||||
<div class="post-tags">
|
||||
|
||||
@@ -7,6 +7,7 @@
|
||||
<h1 class="list-title">标签:{{ $tag->name }}</h1>
|
||||
|
||||
@include('partials.view-mode-switcher')
|
||||
@include('partials.theme-inject', ['point' => 'content_top'])
|
||||
|
||||
@forelse($posts as $post)
|
||||
@include('partials.post-card', ['post' => $post])
|
||||
@@ -15,6 +16,7 @@
|
||||
@endforelse
|
||||
|
||||
@include('partials.pagination', ['paginator' => $posts])
|
||||
@include('partials.theme-inject', ['point' => 'content_bottom'])
|
||||
</main>
|
||||
@include('partials.sidebar')
|
||||
</div>
|
||||
|
||||
Reference in New Issue
Block a user