Images can be uploaded with alt text

This means associating images to notes via a pivot table, we also finish
off the migration of medai from S3.
This commit is contained in:
Jonny Barnes 2026-01-04 10:07:25 +00:00
commit 9e788e0fe8
Signed by: jonny
SSH key fingerprint: SHA256:CTuSlns5U7qlD9jqHvtnVmfYV3Zwl2Z7WnJ4/dqOaL8
9 changed files with 200 additions and 19 deletions

View file

@ -12,7 +12,7 @@
@foreach($note->media as $media)
@if($media->type === 'image')
<a class="naked-link" href="{{ $media->url }}">
<img class="u-photo" src="{{ $media->url }}" alt="" @if($media->image_widths !== null) srcset="{{ $media->url }} {{ $media->image_widths }}w, {{ $media->mediumurl }} 1000w, {{ $media->smallurl }} 500w" sizes="80vh"@endif>
<img class="u-photo" alt="{{ $media->pivot->alt_text }}" @if($media->image_widths !== null) srcset="{{ $media->url }} {{ $media->image_widths }}w, {{ $media->mediumurl }} 1000w, {{ $media->smallurl }} 500w" sizes="min(80ch,80vw)" @else src="{{ $media->url }}" @endif>
</a>
@endif
@if($media->type === 'audio')