style(reader): améliorer la toolbar et l'UI du mode scroll
- Corriger la troncature de la toolbar (max-height 4rem → 5rem) - Animer la toolbar en translateY pour un effet "bloc uni" avec le header - Corriger le bug d'auto-hide du header après switch simple → scroll - Augmenter la taille du titre de chapitre dans la toolbar (text-sm font-medium) - Harmoniser le bouton scroll-to-top avec le style des ToolbarButtons - Ajouter support de prop `class` sur les labels de ToolbarSection
This commit is contained in:
parent
cc702cff19
commit
9c47c717d0
@@ -23,12 +23,13 @@ final readonly class GetChapterContextHandler
|
||||
$context = $this->chapterRepository->getChapterContext($chapterId);
|
||||
|
||||
return new ChapterContextResponse(
|
||||
$query->getChapterId(),
|
||||
$context->getChapterTitle(),
|
||||
$context->getNumber(),
|
||||
$context->getTotalPages(),
|
||||
$context->getPreviousChapterId()?->getValue(),
|
||||
$context->getNextChapterId()?->getValue(),
|
||||
id: $query->getChapterId(),
|
||||
mangaId: $context->getMangaId(),
|
||||
title: $context->getChapterTitle(),
|
||||
number: $context->getNumber(),
|
||||
totalPages: $context->getTotalPages(),
|
||||
previousChapterId: $context->getPreviousChapterId()?->getValue(),
|
||||
nextChapterId: $context->getNextChapterId()?->getValue(),
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -8,6 +8,7 @@ final readonly class ChapterContextResponse
|
||||
{
|
||||
public function __construct(
|
||||
private string $id,
|
||||
private string $mangaId,
|
||||
private string $title,
|
||||
private float $number,
|
||||
private int $totalPages,
|
||||
@@ -21,6 +22,11 @@ final readonly class ChapterContextResponse
|
||||
return $this->id;
|
||||
}
|
||||
|
||||
public function getMangaId(): string
|
||||
{
|
||||
return $this->mangaId;
|
||||
}
|
||||
|
||||
public function getTitle(): string
|
||||
{
|
||||
return $this->title;
|
||||
|
||||
@@ -12,6 +12,7 @@ readonly class ChapterContext
|
||||
private ChapterId $id,
|
||||
private ?ChapterId $previousChapterId,
|
||||
private ?ChapterId $nextChapterId,
|
||||
private string $mangaId,
|
||||
private string $mangaTitle,
|
||||
private float $number,
|
||||
private ?string $chapterTitle,
|
||||
@@ -39,6 +40,11 @@ readonly class ChapterContext
|
||||
return $this->nextChapterId;
|
||||
}
|
||||
|
||||
public function getMangaId(): string
|
||||
{
|
||||
return $this->mangaId;
|
||||
}
|
||||
|
||||
public function getMangaTitle(): string
|
||||
{
|
||||
return $this->mangaTitle;
|
||||
|
||||
@@ -27,6 +27,7 @@ final readonly class ChapterContextProvider implements ProviderInterface
|
||||
|
||||
return new ChapterContextResponse(
|
||||
id: $response->getId(),
|
||||
mangaId: $response->getMangaId(),
|
||||
title: $response->getTitle(),
|
||||
number: $response->getNumber(),
|
||||
totalPages: $response->getTotalPages(),
|
||||
|
||||
@@ -49,6 +49,7 @@ readonly class LegacyChapterRepository implements ChapterRepositoryInterface
|
||||
id: $chapterId,
|
||||
previousChapterId: $this->getPreviousChapterId($chapterId),
|
||||
nextChapterId: $this->getNextChapterId($chapterId),
|
||||
mangaId: (string) $chapter->getManga()->getId(),
|
||||
mangaTitle: $chapter->getManga()->getTitle(),
|
||||
number: $chapter->getNumber(),
|
||||
chapterTitle: $chapter->getTitle(),
|
||||
|
||||
Reference in New Issue
Block a user