Merge pull request #10879 from demarches-simplifiees/a11y-fix-process-home-connected

Corrige les défaut d'accessibilité de l'étape 1 d'une démarche
This commit is contained in:
Corinne Durrmeyer 2024-10-03 08:37:31 +00:00 committed by GitHub
commit 19cd42ac8c
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
12 changed files with 30 additions and 17 deletions

View file

@ -283,7 +283,7 @@ ul.dropdown-items {
}
dd {
word-break: break-all;
word-break: break-word;
}
}

View file

@ -46,11 +46,17 @@
%label.fr-label{ for: "identite_champ_radio_#{Individual::GENDER_MALE}" }
= Individual.human_attribute_name('gender.male')
.fr-fieldset__element.fr-mb-0
%fieldset.fr-fieldset.width-100
.fr-fieldset.width-100
.fr-fieldset__element.fr-fieldset__element--short-text
= render Dsfr::InputComponent.new(form: individual, attribute: :prenom, opts: { autocomplete: (for_tiers? ? false : 'given-name') })
- if for_tiers?
= render Dsfr::InputComponent.new(form: individual, attribute: :prenom)
- else
= render Dsfr::InputComponent.new(form: individual, attribute: :prenom, opts: { autocomplete: 'given-name' })
.fr-fieldset__element.fr-fieldset__element--short-text
= render Dsfr::InputComponent.new(form: individual, attribute: :nom, opts: { autocomplete: (for_tiers? ? false : 'family-name') })
- if for_tiers?
= render Dsfr::InputComponent.new(form: individual, attribute: :nom)
- else
= render Dsfr::InputComponent.new(form: individual, attribute: :nom, opts: { autocomplete: 'family-name' })
- if @dossier.procedure.ask_birthday?
.fr-fieldset__element

View file

@ -1,4 +1,4 @@
= form_with(url: dossiers_path, method: :get ) do |f|
= form_with(url: dossiers_path, method: :get, class: "fr-mb-5w") do |f|
= f.hidden_field :q, value: params[:q], id: nil
= f.label :procedure_id, t('.procedures.label'), class: 'fr-label fr-mb-1w', for: 'procedure_select'
.flex

View file

@ -6,7 +6,7 @@
- is_administrateur_context = nav_bar_profile == :administrateur && administrateur_signed_in?
- is_expert_context = nav_bar_profile == :expert && expert_signed_in?
- is_user_context = nav_bar_profile == :user
- is_search_enabled = [params[:controller] == 'recherche', is_instructeur_context, is_expert_context, is_user_context && current_user.dossiers.count].any?
- is_search_enabled = [params[:controller] == 'recherche', is_instructeur_context, is_expert_context].any?
%header{ class: ["fr-header", content_for?(:notice_info) && "fr-header__with-notice-info"], role: "banner", "data-controller": "dsfr-header" }
%nav{ :role => "navigation", "aria-label" => t('layouts.header.main_menu') }
.fr-header__body

View file

@ -1,5 +1,5 @@
.center
= image_tag "landing/hero/dematerialiser.svg", class: "fr-responsive-img fr-mb-1v", alt: ""
= image_tag "landing/hero/dematerialiser.svg", class: "fr-responsive-img fr-mb-1v", alt: "", "aria-hidden": "true"
%p.fr-m-4w= t('.text')
%hr
%p= t('.are_you_new', app_name: Current.application_name)

View file

@ -11,7 +11,7 @@
= t(".promise")
.hero-illustration
%img{ :src => image_url("landing/hero/dematerialiser.svg"), alt: '', width: 499, height: 280, loading: 'lazy' }
%img{ :src => image_url("landing/hero/dematerialiser.svg"), alt: '', width: 499, height: 280, loading: 'lazy', 'aria-hidden': 'true' }
.fr-background-alt--blue-france.fr-py-6w
.container

View file

@ -2,11 +2,11 @@
%ul.fr-nav__list
- if params[:controller] == 'users/commencer'
%li.fr-nav__item
= link_to t('back', scope: [:layouts, :header]), url_for(:back), title: t('back_title', scope: [:layouts, :header]), class: 'fr-nav__link', "aria-controls" => "modal-header__menu"
= link_to t('back', scope: [:layouts, :header]), url_for(:back), title: t('back_title', scope: [:layouts, :header]), class: 'fr-nav__link'
%li.fr-nav__item
= link_to t('files', scope: [:layouts, :header]), dossiers_path, class: 'fr-nav__link', aria: { current: (controller_name == 'dossiers' && action_name != 'deleted_dossiers') ? 'true' : nil, controls: "modal-header__menu" }
= link_to t('files', scope: [:layouts, :header]), dossiers_path, class: 'fr-nav__link', aria: { current: (controller_name == 'dossiers' && action_name != 'deleted_dossiers') ? 'true' : nil }
- if current_user.deleted_dossiers.present?
%li.fr-nav__item
= link_to 'Historique des dossiers supprimés', deleted_dossiers_path(), class: 'fr-nav__link', aria: { current: action_name == 'deleted_dossiers' ? 'true' : nil, controls: "modal-header__menu" }
= link_to 'Historique des dossiers supprimés', deleted_dossiers_path(), class: 'fr-nav__link', aria: { current: action_name == 'deleted_dossiers' ? 'true' : nil }

View file

@ -1,4 +1,4 @@
- content_for(:title, "Nouveau dossier (#{@dossier.procedure.libelle})")
- content_for(:title, t(".title", scope: :metas, procedure_label: @dossier.procedure.libelle))
= render partial: "shared/dossiers/submit_is_over", locals: { dossier: @dossier }
@ -6,9 +6,12 @@
- if @dossier.procedure.for_tiers_enabled?
= form_for @dossier, url: identite_dossier_path(@dossier), method: :patch, html: { class: "form" }, data: {turbo: true, controller: :autosubmit} do |f|
%fieldset#radio-rich-hint.fr-fieldset{ "aria-labelledby" => "radio-rich-hint-legend radio-rich-hint-messages" }
%legend#radio-rich-hint-legend.fr-fieldset__legend--regular.fr-fieldset__legend
%p.fr-text--sm= t('utils.asterisk_html')
%fieldset#radio-rich-hint.fr-fieldset
%legend.fr-fieldset__legend--regular.fr-fieldset__legend
= t('views.users.dossiers.identite.legend')
= render EditableChamp::AsteriskMandatoryComponent.new
.fr-fieldset__element
.fr-radio-group.fr-radio-rich
@ -25,6 +28,6 @@
.fr-radio-rich__img
%span.fr-icon-parent-fill
= f.submit t('views.users.dossiers.identite.continue'), class: 'visually-hidden'
= f.submit t('views.users.dossiers.identite.continue'), class: 'hidden'
= render Dossiers::IndividualFormComponent.new(dossier: @dossier)

View file

@ -82,7 +82,7 @@ en:
header:
close_modal: 'Close'
back: "Back"
back_title: "Revenir sur le site de mon administration"
back_title: "Back to my administration's website"
main_menu: "Main menu"
locale_dropdown:
select_locale: "Choose a language"

View file

@ -73,7 +73,7 @@ fr:
header:
close_modal: 'Fermer'
back: "Revenir en arrière"
back_title: "Revenir sur le site de mon administration"
back_title: "Revenir en arrière, sur le site de mon administration"
main_menu: "Menu principal"
locale_dropdown:
select_locale: "Sélectionner une langue"

View file

@ -9,6 +9,8 @@ en:
index:
title: Files
title_search: "Search: %{terms}"
identite:
title: "New file (%{procedure_label}) - Step 1: Identity"
show:
title: "Summary · File nº %{number} (%{procedure_label})"
demande:

View file

@ -9,6 +9,8 @@ fr:
index:
title: Dossiers
title_search: "Recherche : %{terms}"
identite:
title: "Nouveau dossier (%{procedure_label}) - Étape 1 : Identité"
show:
title: "Résumé · Dossier nº %{number} (%{procedure_label})"
demande: