From 41ff1dd41229054d9c1acc8de0a829888037999d Mon Sep 17 00:00:00 2001 From: Xavier Leune Date: Tue, 17 Nov 2026 18:35:26 +0100 Subject: [PATCH] Sert les pages speaker en HTML sur /talks/speakers/ MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Les speakers n'avaient pas de page : seule la facette Algolia /talks/?fR[speakers.label][0]=… les listait, vide sans JavaScript, et indexée sous autant de libellés que de variantes du nom. Chaque personne regroupée par SpeakerProfileResolver a désormais sa page /talks/speakers/{slug}, rendue côté serveur : nom en H1, bio, photo, liens sociaux et talks publiés du plus récent au plus ancien, avec un JSON-LD Person encodé avec JSON_HEX_TAG. Un slug inconnu ou sans talk publié répond 404 ; un speaker non rattaché à une personne n'a pas de page. L'index /talks/speakers/ liste toutes ces pages par initiale du nom, accents retirés. Les anciennes URLs de facette (facette speaker seule, sans autre paramètre) redirigent en 301 vers la page du speaker ; le lien « Voir tous ses talks » de la page talk et le sitemap pointent vers les nouvelles pages. talks_show exige un id numérique pour ne jamais capturer ces routes. getSpeakersByTalk lit désormais person_id : sans lui, la page talk ne retrouve pas la personne de ses speakers. --- assets/icons/mdi/github.svg | 1 + config/routing/talks.yml | 14 ++++ .../Controller/Website/Talks/ListAction.php | 29 +++++++ .../Controller/Website/Talks/ShowAction.php | 13 +++ .../Website/Talks/SpeakerListAction.php | 31 +++++++ .../Website/Talks/SpeakerShowAction.php | 45 +++++++++++ .../Model/Repository/SpeakerRepository.php | 2 +- .../AppBundle/Event/Speaker/PersonJsonLd.php | 45 +++++++++++ .../Event/Speaker/SpeakerIdentity.php | 11 +++ .../Subscriber/SitemapXmlSubscriber.php | 22 ++--- templates/site/talks/show.html.twig | 6 +- templates/site/talks/speaker.html.twig | 80 +++++++++++++++++++ templates/site/talks/speakers.html.twig | 45 +++++++++++ tests/behat/bootstrap/FeatureContext.php | 74 +++++++++++++++++ .../features/PublicSite/Sitemaps.feature | 4 +- tests/behat/features/PublicSite/Talks.feature | 65 +++++++++++++++ .../Event/Speaker/PersonJsonLdTest.php | 79 ++++++++++++++++++ .../Event/Speaker/SpeakerIdentityTest.php | 30 +++++++ 18 files changed, 582 insertions(+), 14 deletions(-) create mode 100644 assets/icons/mdi/github.svg create mode 100644 sources/AppBundle/Controller/Website/Talks/SpeakerListAction.php create mode 100644 sources/AppBundle/Controller/Website/Talks/SpeakerShowAction.php create mode 100644 sources/AppBundle/Event/Speaker/PersonJsonLd.php create mode 100644 templates/site/talks/speaker.html.twig create mode 100644 templates/site/talks/speakers.html.twig create mode 100644 tests/unit/AppBundle/Event/Speaker/PersonJsonLdTest.php create mode 100644 tests/unit/AppBundle/Event/Speaker/SpeakerIdentityTest.php diff --git a/assets/icons/mdi/github.svg b/assets/icons/mdi/github.svg new file mode 100644 index 000000000..4a52b0269 --- /dev/null +++ b/assets/icons/mdi/github.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/config/routing/talks.yml b/config/routing/talks.yml index cb538d36f..0d4633546 100644 --- a/config/routing/talks.yml +++ b/config/routing/talks.yml @@ -6,9 +6,23 @@ talks_list: section: talks changefreq: monthly +# Avant talks_show (dont l'id est numérique) : /{id}-{slug} ne doit jamais capturer une page speaker. +talks_speakers: + path: /speakers/ + defaults: { _controller: AppBundle\Controller\Website\Talks\SpeakerListAction } + options: + sitemap: + section: talks + changefreq: monthly + +talks_speaker: + path: /speakers/{slug} + defaults: { _controller: AppBundle\Controller\Website\Talks\SpeakerShowAction } + talks_show: path: /{id}-{slug} defaults: { _controller: AppBundle\Controller\Website\Talks\ShowAction } + requirements: { id: '\d+' } talks_joindin: path: /{id}-{slug}/joindin diff --git a/sources/AppBundle/Controller/Website/Talks/ListAction.php b/sources/AppBundle/Controller/Website/Talks/ListAction.php index f2a90c3ba..d1488378a 100644 --- a/sources/AppBundle/Controller/Website/Talks/ListAction.php +++ b/sources/AppBundle/Controller/Website/Talks/ListAction.php @@ -5,9 +5,11 @@ namespace AppBundle\Controller\Website\Talks; use AppBundle\Antennes\AntenneRepository; +use AppBundle\Event\Speaker\SpeakerProfileResolver; use AppBundle\Twig\ViewRenderer; use Symfony\Bundle\FrameworkBundle\Controller\AbstractController; use Symfony\Component\DependencyInjection\Attribute\Autowire; +use Symfony\Component\HttpFoundation\RedirectResponse; use Symfony\Component\HttpFoundation\Request; use Symfony\Component\HttpFoundation\Response; use Symfony\Component\Routing\Generator\UrlGeneratorInterface; @@ -21,10 +23,16 @@ public function __construct( #[Autowire(env: 'ALGOLIA_FRONTEND_API_KEY')] private readonly string $algoliaFrontendApikey, private readonly AntenneRepository $antennesRepository, + private readonly SpeakerProfileResolver $speakerProfileResolver, ) {} public function __invoke(Request $request): Response { + $speakerRedirect = $this->redirectSpeakerFacet($request); + if (null !== $speakerRedirect) { + return $speakerRedirect; + } + $title = 'Historique des conférences de l\'AFUP'; $canonical = $this->generateUrl('talks_list', referenceType: UrlGeneratorInterface::ABSOLUTE_URL); if (isset($request->query->all('fR')['speakers.label'][0])) { @@ -49,4 +57,25 @@ public function __invoke(Request $request): Response 'algolia_api_key' => $this->algoliaFrontendApikey, ]); } + + /** + * L'ancienne URL d'un speaker, `/talks/?fR[speakers.label][0]=…` sans aucun autre paramètre, + * redirige vers sa page. Une facette combinée à d'autres filtres reste une recherche. + */ + private function redirectSpeakerFacet(Request $request): ?RedirectResponse + { + $labels = $request->query->all('fR')['speakers.label'] ?? null; + $label = is_array($labels) ? $labels[0] ?? null : null; + + if (!is_string($label) || $request->query->all() !== ['fR' => ['speakers.label' => [$label]]]) { + return null; + } + + $identity = $this->speakerProfileResolver->getIdentityByLabel($label); + if (null === $identity) { + return null; + } + + return $this->redirectToRoute('talks_speaker', ['slug' => $identity->slug], Response::HTTP_MOVED_PERMANENTLY); + } } diff --git a/sources/AppBundle/Controller/Website/Talks/ShowAction.php b/sources/AppBundle/Controller/Website/Talks/ShowAction.php index deda565b9..d25b8f281 100644 --- a/sources/AppBundle/Controller/Website/Talks/ShowAction.php +++ b/sources/AppBundle/Controller/Website/Talks/ShowAction.php @@ -8,6 +8,8 @@ use AppBundle\Event\Model\Repository\EventRepository; use AppBundle\Event\Model\Repository\SpeakerRepository; use AppBundle\Event\Model\Repository\TalkRepository; +use AppBundle\Event\Model\Speaker; +use AppBundle\Event\Speaker\SpeakerProfileResolver; use AppBundle\Joindin\JoindinComments; use AppBundle\Subtitles\Parser; use AppBundle\Twig\ViewRenderer; @@ -23,6 +25,7 @@ public function __construct( private readonly SpeakerRepository $speakerRepository, private readonly PlanningRepository $planningRepository, private readonly EventRepository $eventRepository, + private readonly SpeakerProfileResolver $speakerProfileResolver, ) {} public function __invoke(int $id, string $slug): Response @@ -34,6 +37,15 @@ public function __invoke(int $id, string $slug): Response } $speakers = $this->speakerRepository->getSpeakersByTalk($talk); + // Slug de la page de chaque speaker, par ID de ligne speaker : un seul index, chargé une fois pour tous. + $speakerSlugs = []; + /** @var Speaker $speaker */ + foreach ($speakers as $speaker) { + $identity = $this->speakerProfileResolver->getIdentityForSpeaker($speaker); + if (null !== $identity && null !== $speaker->getId()) { + $speakerSlugs[$speaker->getId()] = $identity->slug; + } + } $planning = $this->planningRepository->getByTalk($talk); if ($planning === null) { throw $this->createNotFoundException(); @@ -48,6 +60,7 @@ public function __invoke(int $id, string $slug): Response 'talk' => $talk, 'event' => $event, 'speakers' => $speakers, + 'speaker_slugs' => $speakerSlugs, 'comments' => $comments, 'transcript' => $parsedContent, ]); diff --git a/sources/AppBundle/Controller/Website/Talks/SpeakerListAction.php b/sources/AppBundle/Controller/Website/Talks/SpeakerListAction.php new file mode 100644 index 000000000..fa2bdc332 --- /dev/null +++ b/sources/AppBundle/Controller/Website/Talks/SpeakerListAction.php @@ -0,0 +1,31 @@ +speakerProfileResolver->getIdentities() as $identity) { + $speakersByInitial[$identity->getInitial()][] = $identity; + } + + return $this->view->render('site/talks/speakers.html.twig', [ + 'speakers_by_initial' => $speakersByInitial, + ]); + } +} diff --git a/sources/AppBundle/Controller/Website/Talks/SpeakerShowAction.php b/sources/AppBundle/Controller/Website/Talks/SpeakerShowAction.php new file mode 100644 index 000000000..e2113cdee --- /dev/null +++ b/sources/AppBundle/Controller/Website/Talks/SpeakerShowAction.php @@ -0,0 +1,45 @@ +speakerProfileResolver->getProfileBySlug($slug); + + if (null === $profile) { + throw $this->createNotFoundException(); + } + + $photoUrl = null !== $profile->photoSpeaker ? $this->photoStorage->getUrl($profile->photoSpeaker) : null; + + return $this->view->render('site/talks/speaker.html.twig', [ + 'profile' => $profile, + 'photo_url' => $photoUrl, + 'person' => $this->personJsonLd->getData( + $profile, + $this->generateUrl('talks_speaker', ['slug' => $profile->identity->slug], UrlGeneratorInterface::ABSOLUTE_URL), + null !== $photoUrl ? $request->getSchemeAndHttpHost() . $photoUrl : null, + ), + ]); + } +} diff --git a/sources/AppBundle/Event/Model/Repository/SpeakerRepository.php b/sources/AppBundle/Event/Model/Repository/SpeakerRepository.php index 97ab31978..ea5d8deac 100644 --- a/sources/AppBundle/Event/Model/Repository/SpeakerRepository.php +++ b/sources/AppBundle/Event/Model/Repository/SpeakerRepository.php @@ -54,7 +54,7 @@ class SpeakerRepository extends Repository implements MetadataInitializer public function getSpeakersByTalk(Talk $talk) { $query = $this->getPreparedQuery('SELECT c.conferencier_id, c.id_forum, c.genre, c.nom, c.prenom, c.email,c.societe, - c.biographie, c.twitter, c.user_github, c.photo, c.bluesky, c.mastodon, c.linkedin + c.biographie, c.twitter, c.user_github, c.person_id, c.photo, c.bluesky, c.mastodon, c.linkedin FROM afup_conferenciers c LEFT JOIN afup_conferenciers_sessions cs ON cs.conferencier_id = c.conferencier_id WHERE cs.session_id = :talkId diff --git a/sources/AppBundle/Event/Speaker/PersonJsonLd.php b/sources/AppBundle/Event/Speaker/PersonJsonLd.php new file mode 100644 index 000000000..81d3d0a30 --- /dev/null +++ b/sources/AppBundle/Event/Speaker/PersonJsonLd.php @@ -0,0 +1,45 @@ + : + * JSON_HEX_TAG encode < et >, si bien qu'un texte contenant « » ne peut pas fermer la balise. + */ + public const int JSON_FLAGS = JSON_HEX_TAG | JSON_UNESCAPED_SLASHES | JSON_UNESCAPED_UNICODE | JSON_INVALID_UTF8_SUBSTITUTE; + + /** + * @param string $url l'URL absolue de la page du speaker + * @param string|null $imageUrl l'URL absolue de sa photo + * + * @return array> + */ + public function getData(SpeakerProfile $profile, string $url, ?string $imageUrl): array + { + $data = [ + '@context' => 'https://schema.org', + '@type' => 'Person', + 'name' => $profile->identity->getName(), + 'url' => $url, + ]; + + if (null !== $imageUrl) { + $data['image'] = $imageUrl; + } + + if ($profile->socialLinks !== []) { + $data['sameAs'] = array_values($profile->socialLinks); + } + + return $data; + } +} diff --git a/sources/AppBundle/Event/Speaker/SpeakerIdentity.php b/sources/AppBundle/Event/Speaker/SpeakerIdentity.php index eef403050..3392dc266 100644 --- a/sources/AppBundle/Event/Speaker/SpeakerIdentity.php +++ b/sources/AppBundle/Event/Speaker/SpeakerIdentity.php @@ -37,6 +37,17 @@ public function getLabel(): string return self::cleanSpaces($this->firstname . ' ' . mb_strtoupper($this->lastname)); } + /** + * La lettre de l'index A–Z : initiale du nom (du prénom à défaut), sans accent, en majuscule ; + * « # » si ce n'est pas une lettre. Cohérente avec le tri de SpeakerProfileResolver::getIdentities(). + */ + public function getInitial(): string + { + $initial = strtoupper(substr(SpeakerProfileResolver::normalizeLabel($this->lastname . ' ' . $this->firstname), 0, 1)); + + return ctype_upper($initial) ? $initial : '#'; + } + private static function cleanSpaces(string $value): string { return trim((string) preg_replace('/\s+/u', ' ', $value)); diff --git a/sources/AppBundle/Subscriber/SitemapXmlSubscriber.php b/sources/AppBundle/Subscriber/SitemapXmlSubscriber.php index 49bc304bc..50fc30188 100644 --- a/sources/AppBundle/Subscriber/SitemapXmlSubscriber.php +++ b/sources/AppBundle/Subscriber/SitemapXmlSubscriber.php @@ -10,10 +10,9 @@ use AppBundle\Controller\Website\News\ListAction; use AppBundle\Event\Model\Event; use AppBundle\Event\Model\Repository\EventRepository; -use AppBundle\Event\Model\Repository\SpeakerRepository; use AppBundle\Event\Model\Repository\TalkRepository; -use AppBundle\Event\Model\Speaker; use AppBundle\Event\Model\Talk; +use AppBundle\Event\Speaker\SpeakerProfileResolver; use AppBundle\Site\Entity\Repository\FeuilleRepository; use AppBundle\Site\Entity\Repository\ArticleRepository; use Presta\SitemapBundle\Event\SitemapPopulateEvent; @@ -29,7 +28,7 @@ class SitemapXmlSubscriber implements EventSubscriberInterface public function __construct( private readonly UrlGeneratorInterface $urlGenerator, private readonly TalkRepository $talkRepository, - private readonly SpeakerRepository $speakerRepository, + private readonly SpeakerProfileResolver $speakerProfileResolver, private readonly EventRepository $eventRepository, private readonly ArticleRepository $articleRepository, private readonly CompanyMemberRepository $companyMemberRepository, @@ -46,7 +45,7 @@ public static function getSubscribedEvents(): array public function populate(SitemapPopulateEvent $event): void { $this->registerTalksUrls($event->getUrlContainer()); - $this->registerSpeakersTalksUrls($event->getUrlContainer()); + $this->registerSpeakersUrls($event->getUrlContainer()); $this->registerEventsTalksUrls($event->getUrlContainer()); $this->registerNewsUrls($event->getUrlContainer()); $this->registerMembers($event->getUrlContainer()); @@ -87,17 +86,20 @@ public function registerTalksUrls(UrlContainerInterface $urls): void } } - public function registerSpeakersTalksUrls(UrlContainerInterface $urls): void + /** + * La page de chaque speaker ayant au moins un talk publié ; l'index des speakers + * est déclaré par l'option sitemap de sa route. + */ + public function registerSpeakersUrls(UrlContainerInterface $urls): void { - /** @var Speaker[] $speakers */ - $speakers = $this->speakerRepository->getAll(); - foreach ($speakers as $speaker) { + foreach ($this->speakerProfileResolver->getIdentities() as $identity) { $url = new UrlConcrete( $this->urlGenerator->generate( - 'talks_list', - ['fR' => ['speakers.label' => [$speaker->getLabel()]]], + 'talks_speaker', + ['slug' => $identity->slug], UrlGeneratorInterface::ABSOLUTE_URL, ), + $identity->latestTalkAt, ); $urls->addUrl($url, 'talks'); } diff --git a/templates/site/talks/show.html.twig b/templates/site/talks/show.html.twig index 70432bbe8..4582cae77 100644 --- a/templates/site/talks/show.html.twig +++ b/templates/site/talks/show.html.twig @@ -115,8 +115,10 @@ {% endif %}

{{ speaker.biography }}

- Voir tous ses talks + {% if speaker_slugs[speaker.id] is defined %} + Voir tous ses talks + {% endif %} {% endfor %} diff --git a/templates/site/talks/speaker.html.twig b/templates/site/talks/speaker.html.twig new file mode 100644 index 000000000..3f8df467c --- /dev/null +++ b/templates/site/talks/speaker.html.twig @@ -0,0 +1,80 @@ +{% extends 'layouts/site.html.twig' %} + +{% set name = profile.identity.name %} +{% set latest_talk = profile.talks|first %} + +{% block title %}Talks de {{ name }} – AFUP{% endblock %} + +{% block description %}{{ name }} : {{ profile.talks|length }} talk{{ profile.talks|length > 1 ? 's' }} aux conférences de l'AFUP, dont « {{ latest_talk.talk.title }} » ({{ latest_talk.event.title }}). {{ profile.biography }}{% endblock %} + +{% block metas %} + {{ parent() }} + +{% endblock %} + +{% block content %} + {% set social_networks = { + twitter: { icon: 'fa:twitter', label: 'X (Twitter)' }, + mastodon: { icon: 'mdi:mastodon', label: 'Mastodon' }, + bluesky: { icon: 'simple-icons:bluesky', label: 'Bluesky' }, + linkedin: { icon: 'mdi:linkedin', label: 'LinkedIn' }, + github: { icon: 'mdi:github', label: 'GitHub' }, + } %} + +
+ {# La photo est facultative : elle ne doit pas laisser de colonne vide quand elle manque. #} + {% if photo_url %} + {{ name }} + {% endif %} +
+

+ Speakers +

+

{{ name }}

+ {% if profile.biography %} +

{{ profile.biography }}

+ {% endif %} + {% if profile.socialLinks|length %} + + {% endif %} +
+
+ +
+ {{ profile.talks|length > 1 ? 'Ses talks' : 'Son talk' }} + +
    + {% for speaker_talk in profile.talks %} + {% set talk = speaker_talk.talk %} + {% set talk_url = path('talks_show', {id: talk.id, slug: talk.slug}) %} +
  • +
    + +
    +

    + {{ talk.title }} +

    +

    + {{ speaker_talk.event.title }} · +

    +
    +
    +
  • + {% endfor %} +
+
+{% endblock %} diff --git a/templates/site/talks/speakers.html.twig b/templates/site/talks/speakers.html.twig new file mode 100644 index 000000000..640f66b45 --- /dev/null +++ b/templates/site/talks/speakers.html.twig @@ -0,0 +1,45 @@ +{% extends 'layouts/site.html.twig' %} + +{% block title %}Speakers des conférences – AFUP{% endblock %} + +{% block description %}Tous les speakers des conférences de l'AFUP, de A à Z : retrouvez les talks, vidéos et slides de chacun.{% endblock %} + +{% block content %} +
+

+ Vidéos +

+

Les speakers des conférences de l'AFUP

+ + {% if speakers_by_initial|length > 1 %} + + {% endif %} +
+ +
+ {% for initial, speakers in speakers_by_initial %} +
+ {{ initial }} + +
+ {% else %} +

Aucun speaker pour le moment.

+ {% endfor %} +
+{% endblock %} diff --git a/tests/behat/bootstrap/FeatureContext.php b/tests/behat/bootstrap/FeatureContext.php index db30917c9..bbae0f62a 100644 --- a/tests/behat/bootstrap/FeatureContext.php +++ b/tests/behat/bootstrap/FeatureContext.php @@ -8,6 +8,7 @@ use Behat\Behat\Context\Context; use Behat\Behat\Hook\Scope\BeforeScenarioScope; use Behat\Gherkin\Node\PyStringNode; +use Behat\Gherkin\Node\TableNode; use Behat\Hook\AfterScenario; use Behat\Hook\BeforeScenario; use Behat\Mink\Driver\BrowserKitDriver; @@ -362,4 +363,77 @@ public function openMenu(string $text): void $node->click(); } + + #[Then('the JSON-LD :type should have the following properties:')] + public function assertJsonLdHasProperties(string $type, TableNode $expectedProperties): void + { + $data = $this->findJsonLd($type); + + if (null === $data) { + throw new ExpectationException(sprintf('No JSON-LD of type "%s" found', $type), $this->minkContext->getSession()->getDriver()); + } + + foreach ($expectedProperties->getRowsHash() as $property => $expectedValue) { + $actualValue = $data[$property] ?? null; + if (!is_scalar($actualValue) || (string) $actualValue !== $expectedValue) { + throw new ExpectationException( + sprintf('JSON-LD "%s" property "%s" is %s, "%s" expected', $type, $property, json_encode($actualValue, JSON_UNESCAPED_SLASHES | JSON_UNESCAPED_UNICODE), $expectedValue), + $this->minkContext->getSession()->getDriver(), + ); + } + } + } + + #[Then('the JSON-LD :type property :property should match :regex')] + public function assertJsonLdPropertyMatches(string $type, string $property, string $regex): void + { + $actualValue = $this->findJsonLd($type)[$property] ?? null; + + if (!is_string($actualValue) || !preg_match($regex, $actualValue)) { + throw new ExpectationException( + sprintf('JSON-LD "%s" property "%s" is %s, it does not match "%s"', $type, $property, json_encode($actualValue, JSON_UNESCAPED_SLASHES | JSON_UNESCAPED_UNICODE), $regex), + $this->minkContext->getSession()->getDriver(), + ); + } + } + + #[Then('the response should not contain a JSON-LD :type')] + public function assertNoJsonLd(string $type): void + { + if (null !== $this->findJsonLd($type)) { + throw new ExpectationException(sprintf('A JSON-LD of type "%s" was found', $type), $this->minkContext->getSession()->getDriver()); + } + } + + /** + * Décode chaque ', 'Doe', [1], new \DateTimeImmutable()), + new Speaker(), + null, + null, + [], + [new SpeakerTalk(new Speaker(), new Talk(), new Event(), new \DateTimeImmutable())], + ); + + $json = json_encode(new PersonJsonLd()->getData($profile, 'https://afup.org/talks/speakers/x', null), PersonJsonLd::JSON_FLAGS); + + self::assertIsString($json); + self::assertStringNotContainsString('<', $json); + self::assertSame(' Doe', json_decode($json, true)['name']); + } + + /** + * @param array<'twitter'|'mastodon'|'bluesky'|'linkedin'|'github', string> $socialLinks + */ + private static function profile(array $socialLinks): SpeakerProfile + { + $speaker = new Speaker()->setId(1)->setFirstname('Geoffrey')->setLastname('Bachelet'); + + return new SpeakerProfile( + new SpeakerIdentity('geoffrey-bachelet', 'Geoffrey', 'Bachelet', [1], new \DateTimeImmutable()), + $speaker, + null, + null, + $socialLinks, + [new SpeakerTalk($speaker, new Talk()->setId(1), new Event(), new \DateTimeImmutable())], + ); + } +} diff --git a/tests/unit/AppBundle/Event/Speaker/SpeakerIdentityTest.php b/tests/unit/AppBundle/Event/Speaker/SpeakerIdentityTest.php new file mode 100644 index 000000000..1f6cdd639 --- /dev/null +++ b/tests/unit/AppBundle/Event/Speaker/SpeakerIdentityTest.php @@ -0,0 +1,30 @@ +getInitial()); + } + + public static function initials(): \Generator + { + yield 'initiale du nom en majuscule' => ['Geoffrey', 'bachelet', 'B']; + yield 'accent retiré' => ['Élodie', 'Évrard', 'E']; + yield 'espaces en tête' => ['Cyrille', ' Grandval', 'G']; + yield 'prénom quand le nom est vide' => ['Ödile', '', 'O']; + yield 'chiffre' => ['Team', '42', '#']; + yield 'nom et prénom vides' => ['', '', '#']; + } +}