From 2f4db8def2ed21f7d5cd984f4370564ba0cd517d Mon Sep 17 00:00:00 2001 From: Andy Sellick Date: Thu, 3 May 2018 14:48:38 +0000 Subject: [PATCH] Add colours to document list component --- .../components/_document_list.html.erb | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/app/views/govuk_publishing_components/components/_document_list.html.erb b/app/views/govuk_publishing_components/components/_document_list.html.erb index 07e72f1d6b..f5b47f83f6 100644 --- a/app/views/govuk_publishing_components/components/_document_list.html.erb +++ b/app/views/govuk_publishing_components/components/_document_list.html.erb @@ -2,17 +2,20 @@ items ||= [] margin_top_class = " gem-c-document-list--top-margin" if local_assigns[:margin_top] margin_bottom_class = " gem-c-document-list--bottom-margin" if local_assigns[:margin_bottom] + + brand ||= false + brand_helper = GovukPublishingComponents::Presenters::BrandHelper.new(brand) %> <% if items.any? %> -
    +
      <% items.each do |item| %> -
    1. +
    2. ">

      <%= link_to( item[:link][:text], item[:link][:path], - data: item[:link][:data_attributes] + data: item[:link][:data_attributes], ) %>