From 5311acf7a56e8e89a7232582b11fcf7dbdb6ad26 Mon Sep 17 00:00:00 2001 From: Dan Boscaro Date: Mon, 10 Dec 2018 14:58:51 +0000 Subject: [PATCH] add error message attributes to components --- CHANGELOG.md | 4 ++++ src/components/checkboxes/template.njk | 1 + src/components/date-input/template.njk | 1 + src/components/file-upload/template.njk | 1 + src/components/input/template.njk | 1 + src/components/radios/template.njk | 1 + src/components/select/template.njk | 1 + src/components/textarea/template.njk | 1 + 8 files changed, 11 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index acb7b891ea..387b0bebd9 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -31,6 +31,10 @@ ([PR #1078](https://github.com/alphagov/govuk-frontend/pull/1078)) +- Add error message attributes to all components + + ([PR #1086](https://github.com/alphagov/govuk-frontend/pull/1086)) + ## 2.4.0 (Feature release) 🆕 New features: diff --git a/src/components/checkboxes/template.njk b/src/components/checkboxes/template.njk index 1ee7a9e373..fb5c788f29 100644 --- a/src/components/checkboxes/template.njk +++ b/src/components/checkboxes/template.njk @@ -40,6 +40,7 @@ {{ govukErrorMessage({ id: errorId, classes: params.errorMessage.classes, + attributes: params.errorMessage.attributes, html: params.errorMessage.html, text: params.errorMessage.text }) | indent(2) | trim }} diff --git a/src/components/date-input/template.njk b/src/components/date-input/template.njk index 630eaf353b..af874d4f37 100644 --- a/src/components/date-input/template.njk +++ b/src/components/date-input/template.njk @@ -45,6 +45,7 @@ {{ govukErrorMessage({ id: errorId, classes: params.errorMessage.classes, + attributes: params.errorMessage.attributes, html: params.errorMessage.html, text: params.errorMessage.text }) | indent(2) | trim }} diff --git a/src/components/file-upload/template.njk b/src/components/file-upload/template.njk index cb71ef0584..24d945e1ea 100644 --- a/src/components/file-upload/template.njk +++ b/src/components/file-upload/template.njk @@ -31,6 +31,7 @@ {{ govukErrorMessage({ id: errorId, classes: params.errorMessage.classes, + attributes: params.errorMessage.attributes, html: params.errorMessage.html, text: params.errorMessage.text }) | indent(2) | trim }} diff --git a/src/components/input/template.njk b/src/components/input/template.njk index de6d4b2458..7a62792353 100644 --- a/src/components/input/template.njk +++ b/src/components/input/template.njk @@ -31,6 +31,7 @@ {{ govukErrorMessage({ id: errorId, classes: params.errorMessage.classes, + attributes: params.errorMessage.attributes, html: params.errorMessage.html, text: params.errorMessage.text }) | indent(2) | trim }} diff --git a/src/components/radios/template.njk b/src/components/radios/template.njk index 0241d30fdd..20a79b6174 100644 --- a/src/components/radios/template.njk +++ b/src/components/radios/template.njk @@ -37,6 +37,7 @@ {{ govukErrorMessage({ id: errorId, classes: params.errorMessage.classes, + attributes: params.errorMessage.attributes, html: params.errorMessage.html, text: params.errorMessage.text }) | indent(2) | trim }} diff --git a/src/components/select/template.njk b/src/components/select/template.njk index 2261c87341..a1cac51652 100644 --- a/src/components/select/template.njk +++ b/src/components/select/template.njk @@ -31,6 +31,7 @@ {{ govukErrorMessage({ id: errorId, classes: params.errorMessage.classes, + attributes: params.errorMessage.attributes, html: params.errorMessage.html, text: params.errorMessage.text }) | indent(2) | trim }} diff --git a/src/components/textarea/template.njk b/src/components/textarea/template.njk index 5b463f91c7..ab505dc7f5 100644 --- a/src/components/textarea/template.njk +++ b/src/components/textarea/template.njk @@ -31,6 +31,7 @@ {{ govukErrorMessage({ id: errorId, classes: params.errorMessage.classes, + attributes: params.errorMessage.attributes, html: params.errorMessage.html, text: params.errorMessage.text }) | indent(2) | trim }}