Art: full-image thumbnails, detail page with copy-to-clipboard
- gallery thumbnails now object-fit: contain (whole image, letterboxed),
and a card links to the new detail page instead of the raw file
- /art/{id} detail page: large uncropped image, "Open full size",
"Delete" (moved here from the gallery), and "Copy image"
- clipboard Stimulus controller copies the image to the OS clipboard
(converts non-PNG via canvas) for pasting into WhatsApp etc.
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
This commit is contained in:
@@ -74,6 +74,12 @@ class ArtController extends AbstractController
|
||||
return $this->render('art/upload.html.twig', ['form' => $form]);
|
||||
}
|
||||
|
||||
#[Route('/art/{id}', name: 'app_art_show', requirements: ['id' => '\d+'], methods: ['GET'])]
|
||||
public function show(Artwork $artwork): Response
|
||||
{
|
||||
return $this->render('art/show.html.twig', ['art' => $artwork]);
|
||||
}
|
||||
|
||||
#[Route('/art/{id}/file', name: 'app_art_file', requirements: ['id' => '\d+'], methods: ['GET'])]
|
||||
public function serve(Artwork $artwork): BinaryFileResponse
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user