<% section["sub_sections"].each do |sub_section| %>
  <% if sub_section["title"] %>
    <%= render "govuk_publishing_components/components/heading", {
      text: sub_section["title"],
      heading_level: 4,
      font_size: "s",
      margin_bottom: 4,
    } %>
  <% end %>
  <ul class="covid__list covid__list--accordion">
    <% sub_section["list"].each do | item | %>
      <li class="covid__list-item">
        <% if item["featured_link"] %>
          <%= render 'govuk_publishing_components/components/action_link', {
            simple: true,
            href: item["url"],
            text: item["label"],
            margin_bottom: 1
          }%>
          <% item_description = item["description"] %>
          <% if item_description %>
            <p class="govuk-body covid__list-item-description">
              <%= item_description %>
            </p>
          <% end %>
        <% else %>
          <%= link_to(
            item["label"],
            item["url"],
            class: "govuk-link covid__accordion-link"
          ) %>
        <% end %>
      </li>
    <% end %>
  </ul>
<% end %>

<% section["sub_sections"].each do |sub_section| %>
  <% if sub_section["title"] %>
    <%= render "govuk_publishing_components/components/heading", {
      text: sub_section["title"],
      heading_level: 4,
      font_size: "s",
      margin_bottom: 4,
    } %>
  <% end %>
  <ul class="covid__list covid__list--accordion">
    <% sub_section["list"].each do | item | %>
      <li class="covid__list-item">
        <% if item["featured_link"] %>
          <%= render 'govuk_publishing_components/components/action_link', {
            simple: true,
            href: item["url"],
            text: item["label"],
            margin_bottom: 1
          }%>
          <% item_description = item["description"] %>
          <% if item_description %>
            <p class="govuk-body covid__list-item-description">
              <%= item_description %>
            </p>
          <% end %>
        <% else %>
          <%= link_to(
            item["label"],
            item["url"],
            class: "govuk-link covid__accordion-link",
            data: {
              track_category: "pageElementInteraction",
              track_action: "AccordionClick",
              track_label: item["url"],
            }
          ) %>
        <% end %>
      </li>
    <% end %>
  </ul>
<% end %>

Add tracking for accordion links
Add tracking for accordion links

The data-module="track-click" is already applied on the parent therefore is not required here.
