Restore toolbar background to bg-nebula; add toolbar backdrop blur

This commit is contained in:
2026-02-15 09:24:43 +01:00
parent 79192345e3
commit 9dbe848412
28 changed files with 736 additions and 110 deletions

View File

@@ -2,8 +2,8 @@
namespace App\Http\Resources;
use Illuminate\Http\Resources\Json\JsonResource;
use Illuminate\Support\Facades\Storage;
use Illuminate\Http\Resources\MissingValue;
use App\Services\ThumbnailService;
class ArtworkListResource extends JsonResource
{
@@ -48,6 +48,8 @@ class ArtworkListResource extends JsonResource
$categoryPath = $primaryCategory->full_slug_path ?? null;
}
$slugVal = $get('slug');
$hash = (string) ($get('hash') ?? '');
$thumbExt = (string) ($get('thumb_ext') ?? '');
$webUrl = $contentTypeSlug && $categoryPath && $slugVal
? '/' . strtolower($contentTypeSlug) . '/' . strtolower($categoryPath) . '/' . $slugVal
: null;
@@ -60,7 +62,7 @@ class ArtworkListResource extends JsonResource
'width' => $get('width'),
'height' => $get('height'),
],
'thumbnail_url' => $this->when(! empty($get('file_path')), fn() => Storage::url($get('file_path'))),
'thumbnail_url' => $this->when(! empty($hash) && ! empty($thumbExt), fn() => ThumbnailService::fromHash($hash, $thumbExt, 'md')),
'author' => $this->whenLoaded('user', function () {
return [
'name' => $this->user->name ?? null,