diff --git a/CHANGELOG.md b/CHANGELOG.md index ee4fa367fc..d99c674d66 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -36,6 +36,9 @@ - Update back-link example to show default usage doesn't need `text` parameter ([PR #819](https://github.com/alphagov/govuk-frontend/pull/819)) + +- Lowercase component names + ([PR #822](https://github.com/alphagov/govuk-frontend/pull/822)) ## 1.0.0 (Major release) diff --git a/app/views/examples/template-block-areas/index.njk b/app/views/examples/template-block-areas/index.njk index e66766c979..519293d4f4 100644 --- a/app/views/examples/template-block-areas/index.njk +++ b/app/views/examples/template-block-areas/index.njk @@ -115,7 +115,7 @@

Set this block to add content before to appear outside <main> element.
- For example: The Back link component, Phase banner component. + For example: The back link component, phase banner component.

{% from 'back-link/macro.njk' import govukBackLink %} diff --git a/app/views/layouts/component.njk b/app/views/layouts/component.njk index f484a8df81..4d8f89a19e 100644 --- a/app/views/layouts/component.njk +++ b/app/views/layouts/component.njk @@ -8,7 +8,7 @@ {% endset %} {% set componentName = componentPath %} -{% set componentNameHuman = componentName | replace("-", " ") | capitalize %} +{% set componentNameHuman = componentName | replace("-", " ") %} {% set componentGuidanceLink = componentGuidanceLink | default('https://design-system.service.gov.uk/components/' + componentName)%} {% set htmlMarkup %} {% include componentName +"/"+ componentName +".njk" ignore missing %} @@ -27,7 +27,7 @@

{% block componentName %} - {{ componentNameHuman }} + {{ componentNameHuman | capitalize }} {% endblock %}

diff --git a/app/views/layouts/readme.njk b/app/views/layouts/readme.njk index f8fdaa89c1..f7bc1966c4 100644 --- a/app/views/layouts/readme.njk +++ b/app/views/layouts/readme.njk @@ -1,10 +1,10 @@ {% set nunjucksHtmlUsageMessage = '**If you’re using Nunjucks macros in production be aware that using `html` arguments, or ones ending with `Html` can be a [security risk](https://en.wikipedia.org/wiki/Cross-site_scripting). More about it in the [Nunjucks documentation](https://mozilla.github.io/nunjucks/api.html#user-defined-templates-warning).**' %} {% set componentName = componentPath %} -{% set componentNameHuman = componentName | replace("-", " ") | capitalize %} +{% set componentNameHuman = componentName | replace("-", " ") %} {% set componentGuidanceLink = componentGuidanceLink | default('https://design-system.service.gov.uk/components/' + componentName)%}

{% block componentName %} -{{ componentNameHuman }} +{{ componentNameHuman | capitalize }} {% endblock %}

diff --git a/src/components/back-link/README.md b/src/components/back-link/README.md index 0f9ad7cb8a..4dba7f8779 100644 --- a/src/components/back-link/README.md +++ b/src/components/back-link/README.md @@ -6,7 +6,7 @@ Link back component, to go back a page. ## Guidance -Find out when to use the Back link component in your service in the [GOV.UK Design System](https://design-system.service.gov.uk/components/back-link). +Find out when to use the back link component in your service in the [GOV.UK Design System](https://design-system.service.gov.uk/components/back-link). ## Quick start examples diff --git a/src/components/breadcrumbs/README.md b/src/components/breadcrumbs/README.md index 1d6e128acf..466d0c6e9f 100644 --- a/src/components/breadcrumbs/README.md +++ b/src/components/breadcrumbs/README.md @@ -6,7 +6,7 @@ The Breadcrumbs component helps users to understand where they are within a webs ## Guidance -Find out when to use the Breadcrumbs component in your service in the [GOV.UK Design System](https://design-system.service.gov.uk/components/breadcrumbs). +Find out when to use the breadcrumbs component in your service in the [GOV.UK Design System](https://design-system.service.gov.uk/components/breadcrumbs). ## Quick start examples diff --git a/src/components/button/README.md b/src/components/button/README.md index cc27af3b99..6908d3a0b2 100644 --- a/src/components/button/README.md +++ b/src/components/button/README.md @@ -6,7 +6,7 @@ A button is an element that allows users to carry out an action on a GOV.UK page ## Guidance -Find out when to use the Button component in your service in the [GOV.UK Design System](https://design-system.service.gov.uk/components/button). +Find out when to use the button component in your service in the [GOV.UK Design System](https://design-system.service.gov.uk/components/button). ## Quick start examples diff --git a/src/components/checkboxes/README.md b/src/components/checkboxes/README.md index 02a55a973c..47ec3e7cbd 100644 --- a/src/components/checkboxes/README.md +++ b/src/components/checkboxes/README.md @@ -6,7 +6,7 @@ Let users select one or more options. ## Guidance -Find out when to use the Checkboxes component in your service in the [GOV.UK Design System](https://design-system.service.gov.uk/components/checkboxes). +Find out when to use the checkboxes component in your service in the [GOV.UK Design System](https://design-system.service.gov.uk/components/checkboxes). ## Quick start examples diff --git a/src/components/date-input/README.md b/src/components/date-input/README.md index fd572018fc..d78e96f4a8 100644 --- a/src/components/date-input/README.md +++ b/src/components/date-input/README.md @@ -6,7 +6,7 @@ A component for entering dates, for example - date of birth. ## Guidance -Find out when to use the Date input component in your service in the [GOV.UK Design System](https://design-system.service.gov.uk/components/date-input). +Find out when to use the date input component in your service in the [GOV.UK Design System](https://design-system.service.gov.uk/components/date-input). ## Quick start examples diff --git a/src/components/details/README.md b/src/components/details/README.md index 01326718b4..3ed41c3e54 100644 --- a/src/components/details/README.md +++ b/src/components/details/README.md @@ -6,7 +6,7 @@ Component for conditionally revealing content, using the details HTML element. ## Guidance -Find out when to use the Details component in your service in the [GOV.UK Design System](https://design-system.service.gov.uk/components/details). +Find out when to use the details component in your service in the [GOV.UK Design System](https://design-system.service.gov.uk/components/details). ## Quick start examples diff --git a/src/components/error-message/README.md b/src/components/error-message/README.md index c6fd34d99e..885ceba5c3 100644 --- a/src/components/error-message/README.md +++ b/src/components/error-message/README.md @@ -6,7 +6,7 @@ Component to show a red error message - used for form validation. Use inside a l ## Guidance -Find out when to use the Error message component in your service in the [GOV.UK Design System](https://design-system.service.gov.uk/components/error-message). +Find out when to use the error message component in your service in the [GOV.UK Design System](https://design-system.service.gov.uk/components/error-message). ## Quick start examples diff --git a/src/components/error-summary/README.md b/src/components/error-summary/README.md index 68e23bff6e..f213652a35 100644 --- a/src/components/error-summary/README.md +++ b/src/components/error-summary/README.md @@ -6,7 +6,7 @@ Component to show an error summary box - used at the top of the page, to summari ## Guidance -Find out when to use the Error summary component in your service in the [GOV.UK Design System](https://design-system.service.gov.uk/components/error-summary). +Find out when to use the error summary component in your service in the [GOV.UK Design System](https://design-system.service.gov.uk/components/error-summary). ## Quick start examples diff --git a/src/components/fieldset/README.md b/src/components/fieldset/README.md index 33c6f07277..81510089e1 100644 --- a/src/components/fieldset/README.md +++ b/src/components/fieldset/README.md @@ -6,7 +6,7 @@ The fieldset element is used to group several controls within a web form. The le ## Guidance -Find out when to use the Fieldset component in your service in the [GOV.UK Design System](https://design-system.service.gov.uk/components/fieldset). +Find out when to use the fieldset component in your service in the [GOV.UK Design System](https://design-system.service.gov.uk/components/fieldset). ## Quick start examples diff --git a/src/components/file-upload/README.md b/src/components/file-upload/README.md index f9b692a0d9..0f200e9f69 100644 --- a/src/components/file-upload/README.md +++ b/src/components/file-upload/README.md @@ -6,7 +6,7 @@ The HTML `` element with type="file" lets a user pick one or more files, ## Guidance -Find out when to use the File upload component in your service in the [GOV.UK Design System](https://design-system.service.gov.uk/components/file-upload). +Find out when to use the file upload component in your service in the [GOV.UK Design System](https://design-system.service.gov.uk/components/file-upload). ## Quick start examples diff --git a/src/components/footer/README.md b/src/components/footer/README.md index 27752b6a58..b3799dff35 100644 --- a/src/components/footer/README.md +++ b/src/components/footer/README.md @@ -6,7 +6,7 @@ The footer component is used at the bottom of every GOV.UK page, to help users n ## Guidance -Find out when to use the Footer component in your service in the [GOV.UK Design System](https://design-system.service.gov.uk/components/footer). +Find out when to use the footer component in your service in the [GOV.UK Design System](https://design-system.service.gov.uk/components/footer). ## Quick start examples diff --git a/src/components/header/README.md b/src/components/header/README.md index 57d580d5a0..d63216c83c 100644 --- a/src/components/header/README.md +++ b/src/components/header/README.md @@ -6,7 +6,7 @@ The header component is used at the top of every GOV.UK page, to help users navi ## Guidance -Find out when to use the Header component in your service in the [GOV.UK Design System](https://design-system.service.gov.uk/components/header). +Find out when to use the header component in your service in the [GOV.UK Design System](https://design-system.service.gov.uk/components/header). ## Quick start examples diff --git a/src/components/input/README.md b/src/components/input/README.md index 6e9df69483..42d5e5be3e 100644 --- a/src/components/input/README.md +++ b/src/components/input/README.md @@ -6,7 +6,7 @@ A single-line text field. ## Guidance -Find out when to use the Input component in your service in the [GOV.UK Design System](https://govuk-design-system-production.cloudapps.digital/components/text-input). +Find out when to use the input component in your service in the [GOV.UK Design System](https://govuk-design-system-production.cloudapps.digital/components/text-input). ## Quick start examples diff --git a/src/components/panel/README.md b/src/components/panel/README.md index 45f85ad5a3..8a4f9e1c4d 100644 --- a/src/components/panel/README.md +++ b/src/components/panel/README.md @@ -6,7 +6,7 @@ The confirmation panel has a turquoise background and white text. Used for trans ## Guidance -Find out when to use the Panel component in your service in the [GOV.UK Design System](https://design-system.service.gov.uk/components/panel). +Find out when to use the panel component in your service in the [GOV.UK Design System](https://design-system.service.gov.uk/components/panel). ## Quick start examples diff --git a/src/components/phase-banner/README.md b/src/components/phase-banner/README.md index 0f2fefbe44..70448dc588 100644 --- a/src/components/phase-banner/README.md +++ b/src/components/phase-banner/README.md @@ -6,7 +6,7 @@ A banner that indicates content is in alpha or beta phase with a description. ## Guidance -Find out when to use the Phase banner component in your service in the [GOV.UK Design System](https://design-system.service.gov.uk/components/phase-banner). +Find out when to use the phase banner component in your service in the [GOV.UK Design System](https://design-system.service.gov.uk/components/phase-banner). ## Quick start examples diff --git a/src/components/radios/README.md b/src/components/radios/README.md index 620ef8ccb7..9af707aa23 100644 --- a/src/components/radios/README.md +++ b/src/components/radios/README.md @@ -6,7 +6,7 @@ Let users select a single option from a list. ## Guidance -Find out when to use the Radios component in your service in the [GOV.UK Design System](https://design-system.service.gov.uk/components/radios). +Find out when to use the radios component in your service in the [GOV.UK Design System](https://design-system.service.gov.uk/components/radios). ## Quick start examples diff --git a/src/components/select/README.md b/src/components/select/README.md index 87c1d156d3..91c87c0484 100644 --- a/src/components/select/README.md +++ b/src/components/select/README.md @@ -6,7 +6,7 @@ The HTML `