Save workspace changes

This commit is contained in:
2026-04-18 17:02:56 +02:00
parent f02ea9a711
commit 87d60af5a9
4220 changed files with 1388603 additions and 1554 deletions

View File

@@ -0,0 +1,19 @@
@extends('layouts.nova')
@php
$forumEditPostProps = json_encode([
'post' => ['id' => $post->id, 'content' => $post->content],
'thread' => ['id' => $thread->id, 'title' => $thread->title, 'slug' => $thread->slug],
'csrfToken' => csrf_token(),
'errors' => $errors->toArray(),
], JSON_THROW_ON_ERROR | JSON_UNESCAPED_UNICODE);
@endphp
@section('content')
<div id="forum-edit-post-root"></div>
<script type="application/json" id="forum-edit-post-props">{!! $forumEditPostProps !!}</script>
@endsection
@push('scripts')
@vite(['resources/js/entry-forum.jsx'])
@endpush

View File

@@ -0,0 +1,19 @@
@extends('layouts.nova')
@php
$forumNewThreadProps = json_encode([
'category' => ['id' => $category->id, 'name' => $category->name, 'slug' => $category->slug],
'csrfToken' => csrf_token(),
'errors' => $errors->toArray(),
'oldValues' => ['title' => old('title', ''), 'content' => old('content', '')],
], JSON_THROW_ON_ERROR | JSON_UNESCAPED_UNICODE);
@endphp
@section('content')
<div id="forum-new-thread-root"></div>
<script type="application/json" id="forum-new-thread-props">{!! $forumNewThreadProps !!}</script>
@endsection
@push('scripts')
@vite(['resources/js/entry-forum.jsx'])
@endpush

View File

@@ -0,0 +1,37 @@
@extends('layouts.nova')
@php
$threadsData = collect($subtopics->items())->map(fn ($sub) => [
'topic_id' => (int) ($sub->topic_id ?? $sub->id ?? 0),
'topic' => $sub->topic ?? $sub->title ?? 'Untitled',
'discuss' => $sub->discuss ?? null,
'num_posts' => (int) ($sub->num_posts ?? 0),
'uname' => $sub->uname ?? 'Unknown',
'last_update' => $sub->last_update ?? $sub->post_date ?? null,
'is_pinned' => $sub->is_pinned ?? false,
])->values();
$paginationData = (isset($subtopics) && method_exists($subtopics, 'currentPage'))
? [
'current_page' => $subtopics->currentPage(),
'last_page' => $subtopics->lastPage(),
'per_page' => $subtopics->perPage(),
'total' => $subtopics->total(),
] : null;
$forumCategoryProps = json_encode([
'category' => ['id' => $category->id ?? null, 'name' => $category->name ?? '', 'slug' => $category->slug ?? ''],
'threads' => $threadsData,
'pagination' => $paginationData,
'isAuthenticated' => auth()->check(),
], JSON_THROW_ON_ERROR | JSON_UNESCAPED_UNICODE);
@endphp
@section('content')
<div id="forum-category-root"></div>
<script type="application/json" id="forum-category-props">{!! $forumCategoryProps !!}</script>
@endsection
@push('scripts')
@vite(['resources/js/entry-forum.jsx'])
@endpush