@planning-inspectorate/dynamic-forms 1.15.0 → 1.16.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@planning-inspectorate/dynamic-forms",
3
- "version": "1.15.0",
3
+ "version": "1.16.0",
4
4
  "description": "This package is for building GDS forms using a configuration-based approach.",
5
5
  "main": "./src/index.js",
6
6
  "type": "module",
@@ -44,6 +44,9 @@
44
44
  classes: "govuk-label--l",
45
45
  isPageHeading: true
46
46
  },
47
+ hint: {
48
+ text: question.hint
49
+ },
47
50
  errorMessage: errors[question.fieldName] and {
48
51
  text: errors[question.fieldName].msg
49
52
  },
@@ -16,7 +16,10 @@
16
16
  Which class do you want to travel in?
17
17
  </label>
18
18
  </h1>
19
- <select class="govuk-select" id="travelClass" name="travelClass">
19
+ <div id="travelClass-hint" class="govuk-hint">
20
+
21
+ </div>
22
+ <select class="govuk-select" id="travelClass" name="travelClass" aria-describedby="travelClass-hint">
20
23
  <option value="economy" data-cy="answer-economy">Economy</option>
21
24
  <option value="business" data-cy="answer-business">Business</option>
22
25
  <option value="first" data-cy="answer-first">First Class</option>