forked from demarches-simplifiees/demarches-simplifiees.fr
-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'feature/import-2023-07-10-02'
- Loading branch information
Showing
71 changed files
with
1,111 additions
and
360 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
5 changes: 3 additions & 2 deletions
5
app/components/dsfr/alert_component/alert_component.html.haml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,5 @@ | ||
%div{ class: alert_class(state) } | ||
= content_tag(heading_level, class: 'fr-alert__title') do | ||
= "#{prefix_for_state}#{title}" | ||
- if size != :sm | ||
= content_tag(heading_level, class: 'fr-alert__title') do | ||
= "#{prefix_for_state}#{title}" | ||
= body |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
class EditableChamp::COJOComponent < EditableChamp::EditableChampBaseComponent | ||
def input_group_class | ||
if @champ.accreditation_success? | ||
'fr-input-group--valid' | ||
elsif @champ.accreditation_error? | ||
'fr-input-group--error' | ||
end | ||
end | ||
end |
7 changes: 7 additions & 0 deletions
7
app/components/editable_champ/cojo_component/cojo_component.en.yml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
--- | ||
en: | ||
accreditation_number_label: Accreditation number | ||
accreditation_number_notice: Identification number issued by Paris 2024 | ||
accreditation_birthdate_label: Date of birth | ||
accreditation_number_error: Invalid accreditation number | ||
accreditation_number_verification_pending: Accreditation number verification in progress |
7 changes: 7 additions & 0 deletions
7
app/components/editable_champ/cojo_component/cojo_component.fr.yml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
--- | ||
fr: | ||
accreditation_number_label: Numéro d‘accréditation | ||
accreditation_number_notice: Numéro d‘identification délivré par Paris 2024 | ||
accreditation_birthdate_label: Date de naissance | ||
accreditation_number_error: Le numéro d‘accréditation est incorrect | ||
accreditation_number_verification_pending: Vérification du numéro d‘accréditation en cours |
23 changes: 23 additions & 0 deletions
23
app/components/editable_champ/cojo_component/cojo_component.html.haml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
|
||
.fr-input-group{ class: input_group_class } | ||
= @form.label :accreditation_number, for: @champ.accreditation_number_input_id, class: 'fr-label' do | ||
- safe_join [t('.accreditation_number_label'), @champ.required? ? render(EditableChamp::AsteriskMandatoryComponent.new) : ''], ' ' | ||
%p.fr-hint-text{ id: dom_id(@champ, :accreditation_number_notice) }= t('.accreditation_number_notice') | ||
= @form.text_field :accreditation_number, | ||
required: @champ.required?, | ||
aria: { describedby: [dom_id(@champ, :accreditation_number_notice), @champ.accreditation_error? ? dom_id(@champ, :accreditation_number_error) : nil].compact.join(' ') }, | ||
data: { controller: 'format', format: 'integer' }, | ||
class: "width-33-desktop fr-input small-margin", id: @champ.accreditation_number_input_id | ||
|
||
- if @champ.accreditation_error? | ||
%p.fr-error-text{ id: dom_id(@champ, :accreditation_number_error) }= t('.accreditation_number_error') | ||
- elsif @champ.fetch_external_data_pending? | ||
%p.fr-info-text= t('.accreditation_number_verification_pending') | ||
|
||
.fr-input-group{ class: input_group_class } | ||
= @form.label :accreditation_birthdate, for: @champ.accreditation_birthdate_input_id, class: 'fr-label' do | ||
- safe_join [t('.accreditation_birthdate_label'), @champ.required? ? render(EditableChamp::AsteriskMandatoryComponent.new) : ''], ' ' | ||
= @form.date_field :accreditation_birthdate, | ||
required: @champ.required?, | ||
aria: { describedby: dom_id(@champ, :accreditation_birthdate) }, | ||
class: "width-33-desktop fr-input small-margin", id: @champ.accreditation_birthdate_input_id |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.