diff --git a/resources/forum/blade-tailwind/views/category/index.blade.php b/resources/forum/blade-tailwind/views/category/index.blade.php index d842689d6..eafbc9c98 100644 --- a/resources/forum/blade-tailwind/views/category/index.blade.php +++ b/resources/forum/blade-tailwind/views/category/index.blade.php @@ -1,7 +1,7 @@ {{-- $category is passed as NULL to the master layout view to prevent it from showing in the breadcrumbs --}} @extends ('forum::layouts.main', ['category' => null]) -@section ('content') +@section ('forum-content')

{{ trans('forum::general.index') }}

diff --git a/resources/forum/blade-tailwind/views/category/manage.blade.php b/resources/forum/blade-tailwind/views/category/manage.blade.php index 30a31176a..e982b8100 100644 --- a/resources/forum/blade-tailwind/views/category/manage.blade.php +++ b/resources/forum/blade-tailwind/views/category/manage.blade.php @@ -1,6 +1,6 @@ @extends ('forum::layouts.main', ['category' => null, 'thread' => null, 'breadcrumbs_append' => [trans('forum::general.manage')]]) -@section ('content') +@section ('forum-content')

{{ trans('forum::general.manage') }}

@@ -65,6 +65,7 @@ + @push('forum-page-scripts') + @endpush @stop diff --git a/resources/forum/blade-tailwind/views/category/partials/list.blade.php b/resources/forum/blade-tailwind/views/category/partials/list.blade.php index 402d7361c..59d811f65 100644 --- a/resources/forum/blade-tailwind/views/category/partials/list.blade.php +++ b/resources/forum/blade-tailwind/views/category/partials/list.blade.php @@ -1,11 +1,11 @@
-
-
+
+
-
+
{{ $category->title }}
-

{{ $category->description }}

+

{{ $category->description }}

@if ($category->accepts_threads) @@ -17,7 +17,7 @@ @endif
-
+
@if ($category->accepts_threads) @if ($category->newestThread)
@@ -37,13 +37,13 @@
@if ($category->children->count() > 0) -
+
@foreach ($category->children as $subcategory) -
-
+
+
- {{ $subcategory->title }} -
{{ $subcategory->description }}
+ {{ $subcategory->title }} +
{{ $subcategory->description }}
@@ -53,7 +53,7 @@ {{ trans_choice('forum::posts.post', 2) }}: {{ $subcategory->post_count }}
-
+
@if ($subcategory->newestThread)
{{ $subcategory->newestThread->title }} diff --git a/resources/forum/blade-tailwind/views/category/show.blade.php b/resources/forum/blade-tailwind/views/category/show.blade.php index 24975bd4f..d405cbf64 100644 --- a/resources/forum/blade-tailwind/views/category/show.blade.php +++ b/resources/forum/blade-tailwind/views/category/show.blade.php @@ -1,7 +1,7 @@ {{-- $thread is passed as NULL to the master layout view to prevent it from showing in the breadcrumbs --}} @extends('forum::layouts.main', ['thread' => null]) -@section('content') +@section('forum-content')

{{ $category->title }}   @@ -130,8 +130,8 @@ @endcan @endif @else -
-
+
+
{{ trans('forum::threads.none_found') }} @can ('createThreads', $category)
@@ -141,11 +141,11 @@
@endif -
-
+
+
{{ $threads->links('forum::pagination') }}
-
+
@if ($category->accepts_threads) @can ('createThreads', $category) {{ trans('forum::threads.new_thread') }} @@ -179,6 +179,7 @@ @endcan @endcan + @push('forum-page-scripts') + @endpush @stop diff --git a/resources/forum/blade-tailwind/views/layouts/main.blade.php b/resources/forum/blade-tailwind/views/layouts/main.blade.php index 519f60463..083c8c138 100644 --- a/resources/forum/blade-tailwind/views/layouts/main.blade.php +++ b/resources/forum/blade-tailwind/views/layouts/main.blade.php @@ -1,128 +1,90 @@ - - - - - - - @auth - - - @else - - @endauth +@php + $category = $category ?? null; + $thread = $thread ?? null; + $breadcrumbs_append = $breadcrumbs_append ?? []; + $thread_title = $thread_title ?? null; + + $meta_title = trim(collect([ + $thread_title, + data_get($category, 'title'), + trans('forum::general.home_title'), + ])->filter()->join(' — ')); +@endphp + +@extends('layouts.main') + +@push('meta') +@endpush - - @if (isset($thread_title)) - {{ $thread_title }} — - @endif - @if (isset($category)) - {{ $category->title }} — - @endif - {{ trans('forum::general.home_title') }} - +@push('styles') + @vite('resources/forum/blade-tailwind/css/forum.css') +@endpush - @vite(['resources/forum/blade-tailwind/css/forum.css', 'resources/forum/blade-tailwind/js/forum.js']) - - - + -
- @include ('forum::partials.breadcrumbs') - @include ('forum::partials.alerts') - - @yield('content') +
+ @yield('forum-content') +
- - @yield('footer') - - - - +@endsection diff --git a/resources/forum/blade-tailwind/views/post/confirm-delete.blade.php b/resources/forum/blade-tailwind/views/post/confirm-delete.blade.php index 739ccd7a9..88ec7e326 100644 --- a/resources/forum/blade-tailwind/views/post/confirm-delete.blade.php +++ b/resources/forum/blade-tailwind/views/post/confirm-delete.blade.php @@ -1,6 +1,6 @@ @extends ('forum::layouts.main', ['breadcrumbs_append' => [trans_choice('forum::posts.delete', 1)]]) -@section ('content') +@section ('forum-content')

{{ trans_choice('forum::posts.delete', 1) }}

diff --git a/resources/forum/blade-tailwind/views/post/confirm-restore.blade.php b/resources/forum/blade-tailwind/views/post/confirm-restore.blade.php index c06a903a1..8c7261e22 100644 --- a/resources/forum/blade-tailwind/views/post/confirm-restore.blade.php +++ b/resources/forum/blade-tailwind/views/post/confirm-restore.blade.php @@ -1,6 +1,6 @@ @extends ('forum::layouts.main', ['breadcrumbs_append' => [trans_choice('forum::posts.restore', 1)]]) -@section ('content') +@section ('forum-content')

{{ trans_choice('forum::posts.restore', 1) }}

diff --git a/resources/forum/blade-tailwind/views/post/create.blade.php b/resources/forum/blade-tailwind/views/post/create.blade.php index 6e773a317..b7ad114a1 100644 --- a/resources/forum/blade-tailwind/views/post/create.blade.php +++ b/resources/forum/blade-tailwind/views/post/create.blade.php @@ -1,6 +1,6 @@ @extends ('forum::layouts.main', ['breadcrumbs_append' => [trans('forum::general.new_reply')]]) -@section ('content') +@section ('forum-content')

{{ trans('forum::general.new_reply') }} ({{ $thread->title }})

diff --git a/resources/forum/blade-tailwind/views/post/edit.blade.php b/resources/forum/blade-tailwind/views/post/edit.blade.php index 2a637a9ab..7bc6c6100 100644 --- a/resources/forum/blade-tailwind/views/post/edit.blade.php +++ b/resources/forum/blade-tailwind/views/post/edit.blade.php @@ -1,6 +1,6 @@ @extends ('forum::layouts.main', ['breadcrumbs_append' => [trans('forum::posts.edit')]]) -@section ('content') +@section ('forum-content')

{{ trans('forum::posts.edit') }} ({{ $thread->title }})

diff --git a/resources/forum/blade-tailwind/views/post/partials/list.blade.php b/resources/forum/blade-tailwind/views/post/partials/list.blade.php index 499082f54..44dcefb33 100644 --- a/resources/forum/blade-tailwind/views/post/partials/list.blade.php +++ b/resources/forum/blade-tailwind/views/post/partials/list.blade.php @@ -1,4 +1,4 @@ -
trashed())id="post-{{ $post->sequence }}"@endif +
trashed()) id="post-{{ $post->sequence }}" @endif class="bg-white dark:bg-gray-800 border dark:border-gray-700 mb-2 rounded-md transition-colors {{ $post->trashed() || $thread->trashed() ? 'opacity-50' : '' }}" :class="{ 'border-blue-500 dark:border-blue-400': state.selectedPosts.includes({{ $post->id }}) }">
@@ -16,7 +16,7 @@ @endif
-
+
{{ $post->authorName }} @include ('forum::partials.timestamp', ['carbon' => $post->created_at]) diff --git a/resources/forum/blade-tailwind/views/post/partials/quote.blade.php b/resources/forum/blade-tailwind/views/post/partials/quote.blade.php index 7abb36b53..8e0b254b5 100644 --- a/resources/forum/blade-tailwind/views/post/partials/quote.blade.php +++ b/resources/forum/blade-tailwind/views/post/partials/quote.blade.php @@ -5,7 +5,7 @@ #{{ $post->sequence }}
-
+
{{ $post->authorName }} {{ $post->posted }}
diff --git a/resources/forum/blade-tailwind/views/post/pending-approval.blade.php b/resources/forum/blade-tailwind/views/post/pending-approval.blade.php new file mode 100644 index 000000000..27bd7c28d --- /dev/null +++ b/resources/forum/blade-tailwind/views/post/pending-approval.blade.php @@ -0,0 +1,107 @@ +@extends ('forum::layouts.main', ['breadcrumbs_append' => [trans('forum::posts.pending_approval')]]) + +@section ('forum-content') +
+
+

{{ trans('forum::posts.pending_approval') }}

+
+ + @if ($posts->isEmpty()) +
+ {{ trans('forum::posts.none_found') }} +
+ @else +
+ +
+ +
+ @foreach ($posts as $post) +
+
+
+
+ +
+
+
+ {!! $post->content !!} +
+
+ {{ $post->authorName }} + ({{ $post->created_at->diffForHumans() }}) +
+
+ {{ trans_choice('forum::threads.thread', 1) }}: + + {{ $post->thread->title }} + +
+
+
+
+
+ @endforeach +
+ +
+ + +
+ + @if ($posts->hasPages()) +
+ {{ $posts->links('forum::pagination') }} +
+ @endif + @endif + + @component('forum::modal-form') + @slot('key', 'delete-posts') + @slot('title', trans('forum::general.delete_selection')) + @slot('route', Forum::route('bulk.post.delete')) + @slot('method', 'DELETE') + @slot('actions') + + {{ trans('forum::general.proceed') }} + + @endslot + +

{{ trans('forum::general.generic_confirm') }}

+ + @endcomponent + + @component('forum::modal-form') + @slot('key', 'approve-posts') + @slot('title', trans('forum::general.approve_selection')) + @slot('route', Forum::route('bulk.post.approve')) + @slot('method', 'POST') + @slot('actions') + + {{ trans('forum::general.proceed') }} + + @endslot + +

{{ trans('forum::general.generic_confirm') }}

+ + @endcomponent +
+@stop + diff --git a/resources/forum/blade-tailwind/views/post/show.blade.php b/resources/forum/blade-tailwind/views/post/show.blade.php index 9e1d1b056..b3d854617 100644 --- a/resources/forum/blade-tailwind/views/post/show.blade.php +++ b/resources/forum/blade-tailwind/views/post/show.blade.php @@ -1,6 +1,6 @@ @extends ('forum::layouts.main', ['breadcrumbs_append' => [trans('forum::posts.view')]]) -@section ('content') +@section ('forum-content')

{{ trans('forum::posts.view') }} ({{ $thread->title }})

diff --git a/resources/forum/blade-tailwind/views/thread/create.blade.php b/resources/forum/blade-tailwind/views/thread/create.blade.php index 8544238ec..94b7492e6 100644 --- a/resources/forum/blade-tailwind/views/thread/create.blade.php +++ b/resources/forum/blade-tailwind/views/thread/create.blade.php @@ -1,6 +1,6 @@ @extends ('forum::layouts.main', ['breadcrumbs_append' => [trans('forum::threads.new_thread')]]) -@section ('content') +@section ('forum-content')

{{ trans('forum::threads.new_thread') }} ({{ $category->title }})

diff --git a/resources/forum/blade-tailwind/views/thread/partials/list.blade.php b/resources/forum/blade-tailwind/views/thread/partials/list.blade.php index f06b00f8c..43c6aaa11 100644 --- a/resources/forum/blade-tailwind/views/thread/partials/list.blade.php +++ b/resources/forum/blade-tailwind/views/thread/partials/list.blade.php @@ -1,16 +1,18 @@ -
-
+
+
- {{ $thread->title }} + {{ $thread->title }}
- {{ $thread->authorName }} - @include ('forum::partials.timestamp', ['carbon' => $thread->created_at]) + + {{ $thread->authorName }} + @include ('forum::partials.timestamp', ['carbon' => $thread->created_at]) + @if (!isset($category))
- {{ $thread->category->title }} + {{ $thread->category->title }} @endif
@@ -37,11 +39,11 @@
@if ($thread->lastPost) -
+
{{ trans('forum::posts.view') }} » -
+
{{ $thread->lastPost->authorName }} - @include ('forum::partials.timestamp', ['carbon' => $thread->lastPost->created_at]) + @include ('forum::partials.timestamp', ['carbon' => $thread->lastPost->created_at])
@endif diff --git a/resources/forum/blade-tailwind/views/thread/pending-approval.blade.php b/resources/forum/blade-tailwind/views/thread/pending-approval.blade.php new file mode 100644 index 000000000..499826505 --- /dev/null +++ b/resources/forum/blade-tailwind/views/thread/pending-approval.blade.php @@ -0,0 +1,111 @@ +@extends ('forum::layouts.main', ['breadcrumbs_append' => [trans('forum::threads.pending_approval')]]) + +@section ('forum-content') +
+
+

{{ trans('forum::threads.pending_approval') }}

+
+ + @if ($threads->isEmpty()) +
+ {{ trans('forum::threads.none_found') }} +
+ @else +
+ +
+ +
+ @foreach ($threads as $thread) +
+
+
+
+ +
+
+
+
+

+ {{ trans_choice('forum::threads.thread', 1) }}: + + {{ $thread->title }} + +

+
+ {{ $thread->authorName }} + ({{ $thread->created_at->diffForHumans() }}) +
+
+ {!! $thread->firstPost->content !!} +
+
+
+
+
+
+
+ @endforeach +
+ +
+ + +
+ + @if ($threads->hasPages()) +
+ {{ $threads->links('forum::pagination') }} +
+ @endif + @endif + + @component('forum::modal-form') + @slot('key', 'delete-threads') + @slot('title', trans('forum::general.delete_selection')) + @slot('route', Forum::route('bulk.thread.delete')) + @slot('method', 'DELETE') + @slot('actions') + + {{ trans('forum::general.proceed') }} + + @endslot + +

{{ trans('forum::general.generic_confirm') }}

+ + @endcomponent + + @component('forum::modal-form') + @slot('key', 'approve-threads') + @slot('title', trans('forum::general.approve_selection')) + @slot('route', Forum::route('bulk.thread.approve')) + @slot('method', 'POST') + @slot('actions') + + {{ trans('forum::general.proceed') }} + + @endslot + +

{{ trans('forum::general.generic_confirm') }}

+ + @endcomponent +
+@stop + diff --git a/resources/forum/blade-tailwind/views/thread/recent.blade.php b/resources/forum/blade-tailwind/views/thread/recent.blade.php index 3e8d2bd16..50a96c9d4 100644 --- a/resources/forum/blade-tailwind/views/thread/recent.blade.php +++ b/resources/forum/blade-tailwind/views/thread/recent.blade.php @@ -1,6 +1,6 @@ @extends ('forum::layouts.main', ['thread' => null, 'breadcrumbs_append' => [trans('forum::threads.recent')]]) -@section ('content') +@section ('forum-content')

{{ trans('forum::threads.recent') }}

diff --git a/resources/forum/blade-tailwind/views/thread/show.blade.php b/resources/forum/blade-tailwind/views/thread/show.blade.php index 7b8990e75..175b9f01c 100644 --- a/resources/forum/blade-tailwind/views/thread/show.blade.php +++ b/resources/forum/blade-tailwind/views/thread/show.blade.php @@ -1,6 +1,6 @@ @extends ('forum::layouts.main', ['thread' => null, 'breadcrumbs_append' => [$thread->title], 'thread_title' => $thread->title]) -@section ('content') +@section ('forum-content')

{{ $thread->title }}

@@ -350,6 +350,7 @@ @endcan @endif + @push('forum-page-scripts') + @endpush @stop diff --git a/resources/forum/blade-tailwind/views/thread/unread.blade.php b/resources/forum/blade-tailwind/views/thread/unread.blade.php index 54279348d..add41f2fb 100644 --- a/resources/forum/blade-tailwind/views/thread/unread.blade.php +++ b/resources/forum/blade-tailwind/views/thread/unread.blade.php @@ -1,6 +1,6 @@ @extends ('forum::layouts.main', ['thread' => null, 'breadcrumbs_append' => [trans('forum::threads.unread_updated')]]) -@section ('content') +@section ('forum-content')

{{ trans('forum::threads.unread_updated') }}