With aria attributes
Aria attributes can be applied to the summary element of the component.
How it looks (preview)
Attorney General's office
Works with 2 agencies and public bodies
- Department 1
- Department 2
How to call this example
<div>
<p class="govuk-body">Attorney General's office</p>
<%= render "govuk_publishing_components/components/details", {
title: "Works with 2 agencies and public bodies",
summary_aria_attributes: {
label: "Attorney General's office"
}
} do %>
<ul>
<li>Department 1</li>
<li>Department 2</li>
</ul>
<% end %>
</div>