@extends('layouts.app') @section('content') @php $humanizeSectionKey = function ($key) { $key = (string) $key; if (preg_match('/^[a-z0-9_]+$/', $key)) { return \Illuminate\Support\Str::title(str_replace('_', ' ', $key)); } return $key; }; $existingSections = []; foreach (($model->content_sections ?? []) as $key => $body) { if (! is_string($body) && ! is_numeric($body)) continue; $body = trim((string) $body); if ($body === '') continue; $existingSections[] = ['heading' => $humanizeSectionKey($key), 'body' => $body]; } $oldSections = old('sections'); $sectionsForForm = is_array($oldSections) && count($oldSections) > 0 ? $oldSections : $existingSections; $errorFields = $errors->any() ? array_values(array_unique(array_map(function ($key) { return explode('.', $key)[0]; }, array_keys($errors->getMessages())))) : []; @endphp

Edit Model

Work through each section below — your progress is saved when you hit Save progress.

@if(session('staff_notice'))
{{ session('staff_notice') }}
@endif @if($errors->any())

Please fix the following:

@endif
@csrf @method('PUT')
{{-- 1. BASICS --}}

Paste a normal Sketchfab model URL. We convert it to embed URL automatically.

{{-- 2. SOURCE CONTENT --}} {{-- 3. TEACHING SECTIONS --}} {{-- 4. AI ASSISTANT --}} @include('staff.models._assistant_panel', ['model' => $model, 'assistantModes' => $assistantModes]) {{-- 5. MEDIA & PUBLISH --}}
@include('staff.models._tabbed_form_script') @include('staff.models._assistant_panel_script') @endsection