Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(autocomplete): réutilisation du composant autocomplete sur la home, accentuation du contraste quand on parcours les suggestions au clavier #6429

Open
wants to merge 9 commits into
base: dev
Choose a base branch
from

Conversation

carolineBda
Copy link
Contributor

Fix #6403

…e, accentuation du contraste quand on parcours les suggestions au clavier
@tokenbureau tokenbureau bot temporarily deployed to review-carolinebda-rgaa-combobox-3v16cz January 21, 2025 16:21 Destroyed
@tokenbureau tokenbureau bot temporarily deployed to review-carolinebda-rgaa-combobox-3v16cz January 21, 2025 16:30 Destroyed
@tokenbureau tokenbureau bot temporarily deployed to review-carolinebda-rgaa-combobox-3v16cz January 21, 2025 16:38 Destroyed
@tokenbureau tokenbureau bot temporarily deployed to review-carolinebda-rgaa-combobox-3v16cz January 27, 2025 08:54 Destroyed
@tokenbureau tokenbureau bot temporarily deployed to review-carolinebda-rgaa-combobox-3v16cz January 27, 2025 10:31 Destroyed
{displayLabel(item)}
</Button>
{lineAsLink ? (
<Link href={lineAsLink(item)} className={link}>
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

j'ai transformé le bouton en Link directement pour que le style soit uniforme partout

@@ -52,6 +52,7 @@ describe("<HomeSearch />", () => {
expect(getByText("congés payés et maladie")).toBeInTheDocument();

userAction.click(congesSansSolde);
fireEvent.submit(byTestId("search-input").get());
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Plutôt qu'un testid, ca pourrait être cool de récupérer l'input par son label

Suggested change
fireEvent.submit(byTestId("search-input").get());
fireEvent.submit(byLabelText("Recherchez par mots-clés").get());

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

j'ai essayer mais ça marche pas. Je penses que c'est parce que le label est comme ça :

  <label
      class="fr-label"
      for="input-:r1:"
   >
      Recherchez par mots-clés
      <span
        class="fr-hint-text"
      >
        par exemple : congés payés, durée de préavis
      </span>
    </label>

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ah oui en effet, peut être mettre en regex dans ce cas

@tokenbureau tokenbureau bot temporarily deployed to review-carolinebda-rgaa-combobox-3v16cz January 27, 2025 11:04 Destroyed
@tokenbureau tokenbureau bot temporarily deployed to review-carolinebda-rgaa-combobox-3v16cz January 27, 2025 11:09 Destroyed
@@ -61,7 +65,7 @@ export const SearchInput = (props: Props) => {
/>
<ul
{...getMenuProps({
className: list,
className: autocompleteListContainer,
Copy link
Contributor Author

@carolineBda carolineBda Jan 27, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

je réutilise les même styles

@carolineBda carolineBda requested a review from m-maillot January 27, 2025 11:13
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Visibilité du focus clavier sur les listbox des combobox
2 participants