Skip to content

Commit

Permalink
Move defendant details into the accordion to create consistency with …
Browse files Browse the repository at this point in the history
…headings and spacing;

Add accordion panel to additional information to create consistent spacing;
  • Loading branch information
Katy600 committed Jan 15, 2025
1 parent bea4b09 commit 96d93e7
Show file tree
Hide file tree
Showing 4 changed files with 20 additions and 19 deletions.
15 changes: 0 additions & 15 deletions app/views/shared/_new_claim.html.haml
Original file line number Diff line number Diff line change
Expand Up @@ -31,18 +31,3 @@

- if claim.main_hearing_date
= render partial: 'shared/new_main_hearing_date_details', locals: { claim: claim }


- if claim.defendants.any?
%h2.govuk-heading-l
= t('.defendant_details_heading')
= render partial: 'shared/new_claim_defendants', locals: { defendants: claim.defendants }

- else
.govuk-grid-row
.govuk-grid-column-two-thirds
%p.govuk-body
= t('.no_defendant')

- unless claim.fixed_fee_case?
= render partial: 'shared/offence_details/new_summary', locals: { claim: claim }
10 changes: 9 additions & 1 deletion app/views/shared/_new_claim_accordion.html.haml
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,14 @@
.js-accordion__panel
= render partial: 'shared/new_claim', locals: { claim: claim, hide_totals: true }

- if claim.defendants.any?
%h2.govuk-heading-l
= t('.h2_defendant_details')
.js-accordion__panel
= render partial: 'shared/new_claim_defendants', locals: { defendants: claim.defendants }
-else
= render partial: 'shared/new_defendant_details', locals: { claim: claim }

%h2.govuk-heading-l
= t('.h2_evidence')
.js-accordion__panel
Expand All @@ -37,5 +45,5 @@
- if claim.additional_information.present?
%h2.govuk-heading-l
= t('.additional_information')

.js-accordion__panel.fees-summary
= render partial: 'shared/new_additional_information', locals: { claim: claim }
7 changes: 7 additions & 0 deletions app/views/shared/_new_defendant_details.html.haml
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
.govuk-grid-row
.govuk-grid-column-two-thirds
%p.govuk-body
= t('.no_defendant')

- unless claim.fixed_fee_case?
= render partial: 'shared/offence_details/new_summary', locals: { claim: claim }
7 changes: 4 additions & 3 deletions config/locales/en.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2097,7 +2097,7 @@ en:
defendant: Defendant names
defendants: Defendants
j_a: Judicial apportionment
no_defendant: No defendant details have been supplied for this claim
no_defendant: &no_defendant 'No defendant details have been supplied for this claim'
offence: Offence
offence_class: Offence class
q:
Expand Down Expand Up @@ -2144,20 +2144,21 @@ en:
claim_type: Claim and case type
defendant: Defendant names
defendants: Defendants
defendant_details_heading: Defendant details
j_a: Judicial apportionment
no_defendant: No defendant details have been supplied for this claim
offence: Offence
offence_class: Offence class
new_claim_accordion:
additional_information: Additional claim information
created_by: 'Created by:'
h2_basic_info: Basic claim information
h2_defendant_details: Defendant details
h2_evidence: Evidence
h2_messages: Messages and claim status
h2_status: Status
h2_summary: Fees
heading: Claim
new_defendant_details:
no_defendant: *no_defendant
new_claim_and_case_type_details:
provider_reference: Provider reference number
claim_submitted: Claim submitted on
Expand Down

0 comments on commit 96d93e7

Please sign in to comment.