From 949775022da6ffd6082324a85832640870aa3a55 Mon Sep 17 00:00:00 2001 From: Colin Rotherham Date: Thu, 9 Nov 2023 07:53:45 +0000 Subject: [PATCH] Indent HTML for Table --- .../src/govuk/components/table/template.njk | 42 +++++++++---------- 1 file changed, 21 insertions(+), 21 deletions(-) diff --git a/packages/govuk-frontend/src/govuk/components/table/template.njk b/packages/govuk-frontend/src/govuk/components/table/template.njk index b6006e9f5e..3e84551a92 100644 --- a/packages/govuk-frontend/src/govuk/components/table/template.njk +++ b/packages/govuk-frontend/src/govuk/components/table/template.njk @@ -18,28 +18,28 @@ {% endif %} - {% for row in params.rows %} - {% if row %} - - {% for cell in row %} - {% set commonAttributes %} - {%- if cell.colspan %} colspan="{{ cell.colspan }}"{% endif %} - {%- if cell.rowspan %} rowspan="{{ cell.rowspan }}"{% endif %}{% for attribute, value in cell.attributes %} {{ attribute }}="{{ value }}"{% endfor %} - {% endset %} - {% if loop.first and params.firstCellIsHeader %} - {{ cell.html | safe if cell.html else cell.text }} - {% else %} - {{ cell.html | safe if cell.html else cell.text }} - {% endif %} - {% endfor %} - + {% for row in params.rows %} + {% if row %} + + {% for cell in row %} + {% set commonAttributes %} + {%- if cell.colspan %} colspan="{{ cell.colspan }}"{% endif %} + {%- if cell.rowspan %} rowspan="{{ cell.rowspan }}"{% endif %}{% for attribute, value in cell.attributes %} {{ attribute }}="{{ value }}"{% endfor %} + {% endset %} + {% if loop.first and params.firstCellIsHeader %} + {{ cell.html | safe if cell.html else cell.text }} + {% else %} + {{ cell.html | safe if cell.html else cell.text }} {% endif %} {% endfor %} + + {% endif %} + {% endfor %}