Homepage
- Add HomepageService with hero, trending (award-weighted), fresh uploads,
popular tags, creator spotlight (weekly uploads ranking), and news sections
- Add React components: HomePage, HomeHero, HomeTrending, HomeFresh,
HomeTags, HomeCreators, HomeNews (lazy-loaded below the fold)
- Wire home.blade.php with JSON props, SEO meta, JSON-LD, and hero preload
- Add HomePage.jsx to vite.config.js inputs
Profile page
- Hero banner with random user artwork as background + dark gradient overlay
- Favourites section uses real Artwork models + <x-artwork-card> for CDN URLs
- Newest artworks grid: gallery-grid → grid grid-cols-2 gap-4
Edit Profile page (user.blade.php)
- Add hero banner (featured wallpaper/photography via artwork_features,
content_type_id IN [2,3]) sourced in UserController
- Remove bg-deep from outer wrapper; card backgrounds: bg-panel → bg-nova-800
- Remove stray AI-generated tag fragment from template
Author profile links
- Fix all /@username routes in: HomepageService, MonthlyCommentatorsController,
LatestCommentsController, MyBuddiesController and corresponding blade views
Legacy view namespace
- Register View::addNamespace('legacy', resource_path('views/_legacy'))
in AppServiceProvider::boot()
- Convert all view('legacy.x') and @include('legacy.x') calls to legacy::x
- Migrate legacy views to resources/views/_legacy/ with namespace support
71 lines
2.8 KiB
PHP
71 lines
2.8 KiB
PHP
@extends('layouts.nova')
|
|
|
|
@push('head')
|
|
<title>{{ $meta['title'] }}</title>
|
|
<meta name="description" content="{{ $meta['description'] }}">
|
|
<meta name="keywords" content="{{ $meta['keywords'] }}">
|
|
<link rel="canonical" href="{{ $meta['canonical'] }}">
|
|
|
|
{{-- Open Graph --}}
|
|
<meta property="og:type" content="website">
|
|
<meta property="og:site_name" content="Skinbase">
|
|
<meta property="og:title" content="{{ $meta['title'] }}">
|
|
<meta property="og:description" content="{{ $meta['description'] }}">
|
|
<meta property="og:url" content="{{ $meta['canonical'] }}">
|
|
@if(!empty($meta['og_image']))
|
|
<meta property="og:image" content="{{ $meta['og_image'] }}">
|
|
<meta property="og:image:type" content="image/webp">
|
|
@endif
|
|
|
|
{{-- Twitter --}}
|
|
<meta name="twitter:card" content="summary_large_image">
|
|
<meta name="twitter:title" content="{{ $meta['title'] }}">
|
|
<meta name="twitter:description" content="{{ $meta['description'] }}">
|
|
@if(!empty($meta['og_image']))
|
|
<meta name="twitter:image" content="{{ $meta['og_image'] }}">
|
|
@endif
|
|
|
|
{{-- JSON-LD WebSite schema --}}
|
|
@php
|
|
$websiteSchema = [
|
|
'@context' => 'https://schema.org',
|
|
'@type' => 'WebSite',
|
|
'name' => 'Skinbase',
|
|
'url' => url('/'),
|
|
'description' => $meta['description'],
|
|
'potentialAction' => [
|
|
'@type' => 'SearchAction',
|
|
'target' => url('/search') . '?q={search_term_string}',
|
|
'query-input' => 'required name=search_term_string',
|
|
],
|
|
];
|
|
@endphp
|
|
<script type="application/ld+json">{!! json_encode($websiteSchema, JSON_UNESCAPED_SLASHES | JSON_UNESCAPED_UNICODE | JSON_HEX_TAG) !!}</script>
|
|
|
|
{{-- Preload hero image for faster LCP --}}
|
|
@if(!empty($props['hero']['thumb_lg']))
|
|
<link rel="preload" as="image" href="{{ $props['hero']['thumb_lg'] }}">
|
|
@elseif(!empty($props['hero']['thumb']))
|
|
<link rel="preload" as="image" href="{{ $props['hero']['thumb'] }}">
|
|
@endif
|
|
@endpush
|
|
|
|
@section('main-class', '')
|
|
|
|
@section('content')
|
|
{{-- Inline props for the React component (avoids data-attribute length limits) --}}
|
|
<script id="homepage-props" type="application/json">
|
|
{!! json_encode($props, JSON_UNESCAPED_SLASHES | JSON_UNESCAPED_UNICODE | JSON_HEX_TAG | JSON_HEX_AMP) !!}
|
|
</script>
|
|
|
|
<div id="homepage-root" class="min-h-screen">
|
|
{{-- Loading skeleton (replaced by React on hydration) --}}
|
|
<div class="flex min-h-[60vh] items-center justify-center">
|
|
<div class="h-8 w-8 animate-spin rounded-full border-4 border-nova-500 border-t-transparent"></div>
|
|
</div>
|
|
</div>
|
|
|
|
@vite(['resources/js/Pages/Home/HomePage.jsx'])
|
|
@endsection
|
|
|