-
+
Important information
-
+
You have 7 days left to send your application.
View application .
diff --git a/src/GovUk.Frontend.AspNetCore.DocSamples/Pages/Pagination/Pagination.cshtml b/src/GovUk.Frontend.AspNetCore.DocSamples/Pages/Pagination/Pagination.cshtml
index 9c8e861f..7608c946 100644
--- a/src/GovUk.Frontend.AspNetCore.DocSamples/Pages/Pagination/Pagination.cshtml
+++ b/src/GovUk.Frontend.AspNetCore.DocSamples/Pages/Pagination/Pagination.cshtml
@@ -1,9 +1,9 @@
@page
-
- 1
- 2
- 3
-
+
+ 1
+ 2
+ 3
+
diff --git a/src/GovUk.Frontend.AspNetCore.DocSamples/Pages/Pagination/Stacked.cshtml b/src/GovUk.Frontend.AspNetCore.DocSamples/Pages/Pagination/Stacked.cshtml
index f78f0ce9..f55e0b59 100644
--- a/src/GovUk.Frontend.AspNetCore.DocSamples/Pages/Pagination/Stacked.cshtml
+++ b/src/GovUk.Frontend.AspNetCore.DocSamples/Pages/Pagination/Stacked.cshtml
@@ -1,6 +1,6 @@
@page
-
-
+
+
diff --git a/src/GovUk.Frontend.AspNetCore.DocSamples/Pages/Pagination/WithEllipsis.cshtml b/src/GovUk.Frontend.AspNetCore.DocSamples/Pages/Pagination/WithEllipsis.cshtml
index 9d3c7cc9..39df38a6 100644
--- a/src/GovUk.Frontend.AspNetCore.DocSamples/Pages/Pagination/WithEllipsis.cshtml
+++ b/src/GovUk.Frontend.AspNetCore.DocSamples/Pages/Pagination/WithEllipsis.cshtml
@@ -1,13 +1,13 @@
@page
-
- 1
-
- 6
- 7
- 8
-
- 42
-
+
+ 1
+
+ 6
+ 7
+ 8
+
+ 42
+
diff --git a/src/GovUk.Frontend.AspNetCore.DocSamples/Pages/Panel/Panel.cshtml b/src/GovUk.Frontend.AspNetCore.DocSamples/Pages/Panel/Panel.cshtml
index 11550ce4..d0395cf6 100644
--- a/src/GovUk.Frontend.AspNetCore.DocSamples/Pages/Panel/Panel.cshtml
+++ b/src/GovUk.Frontend.AspNetCore.DocSamples/Pages/Panel/Panel.cshtml
@@ -1,8 +1,8 @@
@page
- Application complete
-
+ Application complete
+
Your reference numberHDJ2123F
-
+
diff --git a/src/GovUk.Frontend.AspNetCore.DocSamples/Pages/PhaseBanner/PhaseBanner.cshtml b/src/GovUk.Frontend.AspNetCore.DocSamples/Pages/PhaseBanner/PhaseBanner.cshtml
index 90a2e7c0..13877c18 100644
--- a/src/GovUk.Frontend.AspNetCore.DocSamples/Pages/PhaseBanner/PhaseBanner.cshtml
+++ b/src/GovUk.Frontend.AspNetCore.DocSamples/Pages/PhaseBanner/PhaseBanner.cshtml
@@ -1,6 +1,6 @@
@page
- Alpha
+ Alpha
This is a new service - your feedback will help us to improve it.
diff --git a/src/GovUk.Frontend.AspNetCore.DocSamples/Pages/Radios/Radios.cshtml b/src/GovUk.Frontend.AspNetCore.DocSamples/Pages/Radios/Radios.cshtml
index abcb259a..a7f16d82 100644
--- a/src/GovUk.Frontend.AspNetCore.DocSamples/Pages/Radios/Radios.cshtml
+++ b/src/GovUk.Frontend.AspNetCore.DocSamples/Pages/Radios/Radios.cshtml
@@ -1,20 +1,20 @@
@page
-
-
+
+
Where do you live?
-
+
-
+
Select one option.
-
+
- England
- Scotland
- Wales
- Northern Ireland
- or
- I am a British citizen living abroad
-
+ England
+ Scotland
+ Wales
+ Northern Ireland
+ or
+ I am a British citizen living abroad
+
diff --git a/src/GovUk.Frontend.AspNetCore.DocSamples/Pages/Radios/RadiosWithConditional.cshtml b/src/GovUk.Frontend.AspNetCore.DocSamples/Pages/Radios/RadiosWithConditional.cshtml
index 02a8ecdc..49dc73c5 100644
--- a/src/GovUk.Frontend.AspNetCore.DocSamples/Pages/Radios/RadiosWithConditional.cshtml
+++ b/src/GovUk.Frontend.AspNetCore.DocSamples/Pages/Radios/RadiosWithConditional.cshtml
@@ -1,41 +1,41 @@
@page
-
-
+
+
How would you prefer to be contacted?
-
+
-
+
Select one option.
-
+
-
+
Email
-
+
- Email address
- Email address cannot be blank
+ Email address
+ Email address cannot be blank
-
-
+
+
-
+
Phone
-
+
- Phone number
+ Phone number
-
-
+
+
-
+
Text message
-
+
- Mobile phone number
+ Mobile phone number
-
-
-
+
+
+
diff --git a/src/GovUk.Frontend.AspNetCore.DocSamples/Pages/Radios/RadiosWithError.cshtml b/src/GovUk.Frontend.AspNetCore.DocSamples/Pages/Radios/RadiosWithError.cshtml
index 224ed325..a37aac6b 100644
--- a/src/GovUk.Frontend.AspNetCore.DocSamples/Pages/Radios/RadiosWithError.cshtml
+++ b/src/GovUk.Frontend.AspNetCore.DocSamples/Pages/Radios/RadiosWithError.cshtml
@@ -1,22 +1,22 @@
@page
-
-
+
+
Where do you live?
-
+
-
+
Select one option.
-
+
-
+
Select the country where you live
-
+
- England
- Scotland
- Wales
- Northern Ireland
-
+ England
+ Scotland
+ Wales
+ Northern Ireland
+
diff --git a/src/GovUk.Frontend.AspNetCore.DocSamples/Pages/Select/Select.cshtml b/src/GovUk.Frontend.AspNetCore.DocSamples/Pages/Select/Select.cshtml
index 4f761faf..48d88518 100644
--- a/src/GovUk.Frontend.AspNetCore.DocSamples/Pages/Select/Select.cshtml
+++ b/src/GovUk.Frontend.AspNetCore.DocSamples/Pages/Select/Select.cshtml
@@ -1,9 +1,9 @@
@page
- Sort by
- Recently published
- Recently updated
- Most views
- Most comments
+ Sort by
+ Recently published
+ Recently updated
+ Most views
+ Most comments
diff --git a/src/GovUk.Frontend.AspNetCore.DocSamples/Pages/SummaryList/SummaryListWithActions.cshtml b/src/GovUk.Frontend.AspNetCore.DocSamples/Pages/SummaryList/SummaryListWithActions.cshtml
index a18da139..0f46c479 100644
--- a/src/GovUk.Frontend.AspNetCore.DocSamples/Pages/SummaryList/SummaryListWithActions.cshtml
+++ b/src/GovUk.Frontend.AspNetCore.DocSamples/Pages/SummaryList/SummaryListWithActions.cshtml
@@ -1,48 +1,48 @@
@page
-
-
+
+
Name
-
-
+
+
Sarah Philips
-
-
- Change
-
-
-
-
+
+
+ Change
+
+
+
+
Date of birth
-
-
+
+
5 January 1978
-
-
- Change
-
-
-
-
+
+
+ Change
+
+
+
+
Contact information
-
-
+
+
72 Guild Street London SE23 6FH
-
-
- Change
-
-
-
-
+
+
+ Change
+
+
+
+
Contact details
-
-
+
+
07700 900457
sarah.phillips@example.com
-
-
- Change
-
-
+
+
+ Change
+
+
diff --git a/src/GovUk.Frontend.AspNetCore.DocSamples/Pages/SummaryList/SummaryListWithoutActions.cshtml b/src/GovUk.Frontend.AspNetCore.DocSamples/Pages/SummaryList/SummaryListWithoutActions.cshtml
index 6f56e876..4d8c801b 100644
--- a/src/GovUk.Frontend.AspNetCore.DocSamples/Pages/SummaryList/SummaryListWithoutActions.cshtml
+++ b/src/GovUk.Frontend.AspNetCore.DocSamples/Pages/SummaryList/SummaryListWithoutActions.cshtml
@@ -1,36 +1,36 @@
@page
-
-
+
+
Name
-
-
+
+
Sarah Philips
-
-
-
-
+
+
+
+
Date of birth
-
-
+
+
5 January 1978
-
-
-
-
+
+
+
+
Contact information
-
-
+
+
72 Guild Street London SE23 6FH
-
-
-
-
+
+
+
+
Contact details
-
-
+
+
07700 900457
sarah.phillips@example.com
-
-
+
+
diff --git a/src/GovUk.Frontend.AspNetCore.DocSamples/Pages/TextArea/TextArea.cshtml b/src/GovUk.Frontend.AspNetCore.DocSamples/Pages/TextArea/TextArea.cshtml
index cb561c74..5fb8578b 100644
--- a/src/GovUk.Frontend.AspNetCore.DocSamples/Pages/TextArea/TextArea.cshtml
+++ b/src/GovUk.Frontend.AspNetCore.DocSamples/Pages/TextArea/TextArea.cshtml
@@ -1,10 +1,10 @@
@page
-
+
Can you provide more detail?
-
-
+
+
Do not include personal or financial information like your National Insurance number or credit card details.
-
+
diff --git a/src/GovUk.Frontend.AspNetCore.DocSamples/Pages/TextInput/TextInput.cshtml b/src/GovUk.Frontend.AspNetCore.DocSamples/Pages/TextInput/TextInput.cshtml
index 88f2e13c..665c58de 100644
--- a/src/GovUk.Frontend.AspNetCore.DocSamples/Pages/TextInput/TextInput.cshtml
+++ b/src/GovUk.Frontend.AspNetCore.DocSamples/Pages/TextInput/TextInput.cshtml
@@ -1,6 +1,6 @@
@page
- What is your account number?
- Must be between 6 and 8 digits long
+ What is your account number?
+ Must be between 6 and 8 digits long
diff --git a/src/GovUk.Frontend.AspNetCore.DocSamples/Pages/TextInput/TextInputWithError.cshtml b/src/GovUk.Frontend.AspNetCore.DocSamples/Pages/TextInput/TextInputWithError.cshtml
index dc40252a..bc6944c0 100644
--- a/src/GovUk.Frontend.AspNetCore.DocSamples/Pages/TextInput/TextInputWithError.cshtml
+++ b/src/GovUk.Frontend.AspNetCore.DocSamples/Pages/TextInput/TextInputWithError.cshtml
@@ -1,7 +1,7 @@
@page
- What is the name of the event?
- The name you’ll use on promotional material.
- Enter an event name
+ What is the name of the event?
+ The name you’ll use on promotional material.
+ Enter an event name
diff --git a/src/GovUk.Frontend.AspNetCore.DocSamples/Pages/TextInput/TextInputWithPrefixAndSuffix.cshtml b/src/GovUk.Frontend.AspNetCore.DocSamples/Pages/TextInput/TextInputWithPrefixAndSuffix.cshtml
index 65053a73..a0824c8c 100644
--- a/src/GovUk.Frontend.AspNetCore.DocSamples/Pages/TextInput/TextInputWithPrefixAndSuffix.cshtml
+++ b/src/GovUk.Frontend.AspNetCore.DocSamples/Pages/TextInput/TextInputWithPrefixAndSuffix.cshtml
@@ -1,7 +1,7 @@
@page
- What is the cost per item, in pounds?
- £
- per item
+ What is the cost per item, in pounds?
+ £
+ per item
diff --git a/src/GovUk.Frontend.AspNetCore/TagHelpers/AccordionItemHeadingTagHelper.cs b/src/GovUk.Frontend.AspNetCore/TagHelpers/AccordionItemHeadingTagHelper.cs
index b5ab717e..ab2b9df6 100644
--- a/src/GovUk.Frontend.AspNetCore/TagHelpers/AccordionItemHeadingTagHelper.cs
+++ b/src/GovUk.Frontend.AspNetCore/TagHelpers/AccordionItemHeadingTagHelper.cs
@@ -7,9 +7,13 @@ namespace GovUk.Frontend.AspNetCore.TagHelpers
/// Represents the heading in a GDS accordion component item.
///
[HtmlTargetElement(TagName, ParentTag = AccordionItemTagHelper.TagName)]
+ [HtmlTargetElement(TagName, ParentTag = AccordionItemTagHelper.ShortTagName)]
+ [HtmlTargetElement(ShortTagName, ParentTag = AccordionItemTagHelper.TagName)]
+ [HtmlTargetElement(ShortTagName, ParentTag = AccordionItemTagHelper.ShortTagName)]
public class AccordionItemHeadingTagHelper : TagHelper
{
internal const string TagName = "govuk-accordion-item-heading";
+ internal const string ShortTagName = "heading";
///
public override async Task ProcessAsync(TagHelperContext context, TagHelperOutput output)
diff --git a/src/GovUk.Frontend.AspNetCore/TagHelpers/AccordionItemSummaryTagHelper.cs b/src/GovUk.Frontend.AspNetCore/TagHelpers/AccordionItemSummaryTagHelper.cs
index 53fdfb7e..480ee51d 100644
--- a/src/GovUk.Frontend.AspNetCore/TagHelpers/AccordionItemSummaryTagHelper.cs
+++ b/src/GovUk.Frontend.AspNetCore/TagHelpers/AccordionItemSummaryTagHelper.cs
@@ -8,10 +8,14 @@ namespace GovUk.Frontend.AspNetCore.TagHelpers
/// Represents the summary in a GDS accordion component item.
///
[HtmlTargetElement(TagName, ParentTag = AccordionItemTagHelper.TagName)]
+ [HtmlTargetElement(TagName, ParentTag = AccordionItemTagHelper.ShortTagName)]
+ [HtmlTargetElement(ShortTagName, ParentTag = AccordionItemTagHelper.TagName)]
+ [HtmlTargetElement(ShortTagName, ParentTag = AccordionItemTagHelper.ShortTagName)]
[OutputElementHint(ComponentGenerator.AccordionItemSummaryElement)]
public class AccordionItemSummaryTagHelper : TagHelper
{
internal const string TagName = "govuk-accordion-item-summary";
+ internal const string ShortTagName = "summary";
///
public override async Task ProcessAsync(TagHelperContext context, TagHelperOutput output)
diff --git a/src/GovUk.Frontend.AspNetCore/TagHelpers/AccordionItemTagHelper.cs b/src/GovUk.Frontend.AspNetCore/TagHelpers/AccordionItemTagHelper.cs
index df464f7c..bb710d6d 100644
--- a/src/GovUk.Frontend.AspNetCore/TagHelpers/AccordionItemTagHelper.cs
+++ b/src/GovUk.Frontend.AspNetCore/TagHelpers/AccordionItemTagHelper.cs
@@ -9,10 +9,12 @@ namespace GovUk.Frontend.AspNetCore.TagHelpers
/// Represents an item in a GDS accordion component.
///
[HtmlTargetElement(TagName, ParentTag = AccordionTagHelper.TagName)]
+ [HtmlTargetElement(ShortTagName, ParentTag = AccordionTagHelper.TagName)]
[OutputElementHint(ComponentGenerator.AccordionItemElement)]
public class AccordionItemTagHelper : TagHelper
{
internal const string TagName = "govuk-accordion-item";
+ internal const string ShortTagName = "accordion-item";
private const string ExpandedAttributeName = "expanded";
diff --git a/src/GovUk.Frontend.AspNetCore/TagHelpers/AccordionTagHelper.cs b/src/GovUk.Frontend.AspNetCore/TagHelpers/AccordionTagHelper.cs
index 2264a341..08fde41a 100644
--- a/src/GovUk.Frontend.AspNetCore/TagHelpers/AccordionTagHelper.cs
+++ b/src/GovUk.Frontend.AspNetCore/TagHelpers/AccordionTagHelper.cs
@@ -12,7 +12,7 @@ namespace GovUk.Frontend.AspNetCore.TagHelpers
///
[HtmlTargetElement(TagName)]
[OutputElementHint(ComponentGenerator.AccordionElement)]
- [RestrictChildren(AccordionItemTagHelper.TagName)]
+ [RestrictChildren(AccordionItemTagHelper.TagName, AccordionItemTagHelper.ShortTagName)]
public class AccordionTagHelper : TagHelper
{
internal const string TagName = "govuk-accordion";
diff --git a/src/GovUk.Frontend.AspNetCore/TagHelpers/BreadcrumbsItemTagHelper.cs b/src/GovUk.Frontend.AspNetCore/TagHelpers/BreadcrumbsItemTagHelper.cs
index 33126243..6e39bf36 100644
--- a/src/GovUk.Frontend.AspNetCore/TagHelpers/BreadcrumbsItemTagHelper.cs
+++ b/src/GovUk.Frontend.AspNetCore/TagHelpers/BreadcrumbsItemTagHelper.cs
@@ -9,10 +9,12 @@ namespace GovUk.Frontend.AspNetCore.TagHelpers
/// Represents an item in a GDS breadcrumbs component.
///
[HtmlTargetElement(TagName, ParentTag = BreadcrumbsTagHelper.TagName)]
+ [HtmlTargetElement(ShortTagName, ParentTag = BreadcrumbsTagHelper.TagName)]
//[OutputElementHint(ComponentGenerator.BreadcrumbsItemElement)] // Omitted since it produces intellisense warnings
public class BreadcrumbsItemTagHelper : TagHelper
{
internal const string TagName = "govuk-breadcrumbs-item";
+ internal const string ShortTagName = "breadcrumbs-item";
private const string LinkAttributesPrefix = "link-";
diff --git a/src/GovUk.Frontend.AspNetCore/TagHelpers/BreadcrumbsTagHelper.cs b/src/GovUk.Frontend.AspNetCore/TagHelpers/BreadcrumbsTagHelper.cs
index 4a8645f2..11a4bb1b 100644
--- a/src/GovUk.Frontend.AspNetCore/TagHelpers/BreadcrumbsTagHelper.cs
+++ b/src/GovUk.Frontend.AspNetCore/TagHelpers/BreadcrumbsTagHelper.cs
@@ -9,7 +9,7 @@ namespace GovUk.Frontend.AspNetCore.TagHelpers
/// Generates a GDS breadcrumbs component.
///
[HtmlTargetElement(TagName)]
- [RestrictChildren(BreadcrumbsItemTagHelper.TagName)]
+ [RestrictChildren(BreadcrumbsItemTagHelper.TagName, BreadcrumbsItemTagHelper.ShortTagName)]
[OutputElementHint(ComponentGenerator.BreadcrumbsElement)]
public class BreadcrumbsTagHelper : TagHelper
{
diff --git a/src/GovUk.Frontend.AspNetCore/TagHelpers/CharacterCountTagHelper.cs b/src/GovUk.Frontend.AspNetCore/TagHelpers/CharacterCountTagHelper.cs
index fc247fa8..bb81b8e4 100644
--- a/src/GovUk.Frontend.AspNetCore/TagHelpers/CharacterCountTagHelper.cs
+++ b/src/GovUk.Frontend.AspNetCore/TagHelpers/CharacterCountTagHelper.cs
@@ -11,7 +11,15 @@ namespace GovUk.Frontend.AspNetCore.TagHelpers
/// Generates a GDS character count component.
///
[HtmlTargetElement(TagName)]
- [RestrictChildren(LabelTagName, HintTagName, ErrorMessageTagName, CharacterCountValueTagHelper.TagName)]
+ [RestrictChildren(
+ LabelTagName,
+ FormGroupLabelTagHelper.ShortTagName,
+ HintTagName,
+ FormGroupHintTagHelper.ShortTagName,
+ ErrorMessageTagName,
+ FormGroupErrorMessageTagHelper.ShortTagName,
+ CharacterCountValueTagHelper.TagName,
+ CharacterCountValueTagHelper.ShortTagName)]
[OutputElementHint(ComponentGenerator.CharacterCountElement)]
public class CharacterCountTagHelper : FormGroupTagHelperBase
{
diff --git a/src/GovUk.Frontend.AspNetCore/TagHelpers/CharacterCountValueTagHelper.cs b/src/GovUk.Frontend.AspNetCore/TagHelpers/CharacterCountValueTagHelper.cs
index fdbe4e92..e7c79967 100644
--- a/src/GovUk.Frontend.AspNetCore/TagHelpers/CharacterCountValueTagHelper.cs
+++ b/src/GovUk.Frontend.AspNetCore/TagHelpers/CharacterCountValueTagHelper.cs
@@ -10,6 +10,7 @@ namespace GovUk.Frontend.AspNetCore.TagHelpers
public class CharacterCountValueTagHelper : TagHelper
{
internal const string TagName = "govuk-character-count-value";
+ internal const string ShortTagName = "value";
///
public override async Task ProcessAsync(TagHelperContext context, TagHelperOutput output)
diff --git a/src/GovUk.Frontend.AspNetCore/TagHelpers/CheckboxesFieldsetLegendTagHelper.cs b/src/GovUk.Frontend.AspNetCore/TagHelpers/CheckboxesFieldsetLegendTagHelper.cs
index 2d41b881..f65d1a6b 100644
--- a/src/GovUk.Frontend.AspNetCore/TagHelpers/CheckboxesFieldsetLegendTagHelper.cs
+++ b/src/GovUk.Frontend.AspNetCore/TagHelpers/CheckboxesFieldsetLegendTagHelper.cs
@@ -8,10 +8,14 @@ namespace GovUk.Frontend.AspNetCore.TagHelpers
/// Represents the legend in a GDS checkboxes component fieldset.
///
[HtmlTargetElement(TagName, ParentTag = CheckboxesFieldsetTagHelper.TagName)]
+ [HtmlTargetElement(ShortTagName, ParentTag = CheckboxesFieldsetTagHelper.TagName)]
+ [HtmlTargetElement(TagName, ParentTag = CheckboxesFieldsetTagHelper.ShortTagName)]
+ [HtmlTargetElement(ShortTagName, ParentTag = CheckboxesFieldsetTagHelper.ShortTagName)]
[OutputElementHint(ComponentGenerator.FieldsetLegendElement)]
public class CheckboxesFieldsetLegendTagHelper : TagHelper
{
internal const string TagName = "govuk-checkboxes-fieldset-legend";
+ internal const string ShortTagName = "legend";
private const string IsPageHeadingAttributeName = "is-page-heading";
diff --git a/src/GovUk.Frontend.AspNetCore/TagHelpers/CheckboxesFieldsetTagHelper.cs b/src/GovUk.Frontend.AspNetCore/TagHelpers/CheckboxesFieldsetTagHelper.cs
index 6ab5ca12..8850dc8b 100644
--- a/src/GovUk.Frontend.AspNetCore/TagHelpers/CheckboxesFieldsetTagHelper.cs
+++ b/src/GovUk.Frontend.AspNetCore/TagHelpers/CheckboxesFieldsetTagHelper.cs
@@ -8,11 +8,23 @@ namespace GovUk.Frontend.AspNetCore.TagHelpers
/// Represents the fieldset in a GDS checkboxes component.
///
[HtmlTargetElement(TagName, ParentTag = CheckboxesTagHelper.TagName)]
- [RestrictChildren(CheckboxesFieldsetLegendTagHelper.TagName, CheckboxesItemTagHelper.TagName, CheckboxesItemDividerTagHelper.TagName, CheckboxesTagHelper.HintTagName, CheckboxesTagHelper.ErrorMessageTagName)]
+ [HtmlTargetElement(ShortTagName, ParentTag = CheckboxesTagHelper.TagName)]
+ [RestrictChildren(
+ CheckboxesFieldsetLegendTagHelper.TagName,
+ CheckboxesFieldsetLegendTagHelper.ShortTagName,
+ CheckboxesItemTagHelper.TagName,
+ CheckboxesItemTagHelper.ShortTagName,
+ CheckboxesItemDividerTagHelper.TagName,
+ CheckboxesItemDividerTagHelper.ShortTagName,
+ CheckboxesTagHelper.HintTagName,
+ FormGroupHintTagHelper.ShortTagName,
+ CheckboxesTagHelper.ErrorMessageTagName,
+ FormGroupErrorMessageTagHelper.ShortTagName)]
[OutputElementHint(ComponentGenerator.FieldsetElement)]
public class CheckboxesFieldsetTagHelper : TagHelper
{
internal const string TagName = "govuk-checkboxes-fieldset";
+ internal const string ShortTagName = "checkboxes-fieldset"; // 'fieldset' clashes with FieldsetTagHelper
///
public override async Task ProcessAsync(TagHelperContext context, TagHelperOutput output)
diff --git a/src/GovUk.Frontend.AspNetCore/TagHelpers/CheckboxesItemConditionalTagHelper.cs b/src/GovUk.Frontend.AspNetCore/TagHelpers/CheckboxesItemConditionalTagHelper.cs
index 0ce7616a..16db1145 100644
--- a/src/GovUk.Frontend.AspNetCore/TagHelpers/CheckboxesItemConditionalTagHelper.cs
+++ b/src/GovUk.Frontend.AspNetCore/TagHelpers/CheckboxesItemConditionalTagHelper.cs
@@ -7,9 +7,13 @@ namespace GovUk.Frontend.AspNetCore.TagHelpers
/// Represents the conditional reveal of a checkbox item in a GDS checkboxes component.
///
[HtmlTargetElement(TagName, ParentTag = CheckboxesItemTagHelper.TagName)]
+ [HtmlTargetElement(ShortTagName, ParentTag = CheckboxesItemTagHelper.TagName)]
+ [HtmlTargetElement(TagName, ParentTag = CheckboxesItemTagHelper.ShortTagName)]
+ [HtmlTargetElement(ShortTagName, ParentTag = CheckboxesItemTagHelper.ShortTagName)]
public class CheckboxesItemConditionalTagHelper : TagHelper
{
internal const string TagName = "govuk-checkboxes-item-conditional";
+ internal const string ShortTagName = "conditional";
///
public override async Task ProcessAsync(TagHelperContext context, TagHelperOutput output)
diff --git a/src/GovUk.Frontend.AspNetCore/TagHelpers/CheckboxesItemDividerTagHelper.cs b/src/GovUk.Frontend.AspNetCore/TagHelpers/CheckboxesItemDividerTagHelper.cs
index 29e6c2c1..f9262a98 100644
--- a/src/GovUk.Frontend.AspNetCore/TagHelpers/CheckboxesItemDividerTagHelper.cs
+++ b/src/GovUk.Frontend.AspNetCore/TagHelpers/CheckboxesItemDividerTagHelper.cs
@@ -9,10 +9,15 @@ namespace GovUk.Frontend.AspNetCore.TagHelpers
///
[HtmlTargetElement(TagName, ParentTag = CheckboxesTagHelper.TagName)]
[HtmlTargetElement(TagName, ParentTag = CheckboxesFieldsetTagHelper.TagName)]
+ [HtmlTargetElement(TagName, ParentTag = CheckboxesFieldsetTagHelper.ShortTagName)]
+ [HtmlTargetElement(ShortTagName, ParentTag = CheckboxesTagHelper.TagName)]
+ [HtmlTargetElement(ShortTagName, ParentTag = CheckboxesFieldsetTagHelper.TagName)]
+ [HtmlTargetElement(ShortTagName, ParentTag = CheckboxesFieldsetTagHelper.ShortTagName)]
[OutputElementHint(ComponentGenerator.CheckboxesDividerItemElement)]
public class CheckboxesItemDividerTagHelper : TagHelper
{
internal const string TagName = "govuk-checkboxes-divider";
+ internal const string ShortTagName = "checkboxes-divider";
///
public override async Task ProcessAsync(TagHelperContext context, TagHelperOutput output)
diff --git a/src/GovUk.Frontend.AspNetCore/TagHelpers/CheckboxesItemHintTagHelper.cs b/src/GovUk.Frontend.AspNetCore/TagHelpers/CheckboxesItemHintTagHelper.cs
index 4919b48f..ec722f7b 100644
--- a/src/GovUk.Frontend.AspNetCore/TagHelpers/CheckboxesItemHintTagHelper.cs
+++ b/src/GovUk.Frontend.AspNetCore/TagHelpers/CheckboxesItemHintTagHelper.cs
@@ -8,10 +8,14 @@ namespace GovUk.Frontend.AspNetCore.TagHelpers
/// Represents the hint of a checkbox item in a GDS checkboxes component.
///
[HtmlTargetElement(TagName, ParentTag = CheckboxesItemTagHelper.TagName)]
+ [HtmlTargetElement(TagName, ParentTag = CheckboxesItemTagHelper.ShortTagName)]
+ [HtmlTargetElement(ShortTagName, ParentTag = CheckboxesItemTagHelper.TagName)]
+ [HtmlTargetElement(ShortTagName, ParentTag = CheckboxesItemTagHelper.ShortTagName)]
[OutputElementHint(ComponentGenerator.HintElement)]
public class CheckboxesItemHintTagHelper : TagHelper
{
internal const string TagName = "govuk-checkboxes-item-hint";
+ internal const string ShortTagName = "hint";
///
public override async Task ProcessAsync(TagHelperContext context, TagHelperOutput output)
diff --git a/src/GovUk.Frontend.AspNetCore/TagHelpers/CheckboxesItemTagHelper.cs b/src/GovUk.Frontend.AspNetCore/TagHelpers/CheckboxesItemTagHelper.cs
index 68f7eab0..4f3377e7 100644
--- a/src/GovUk.Frontend.AspNetCore/TagHelpers/CheckboxesItemTagHelper.cs
+++ b/src/GovUk.Frontend.AspNetCore/TagHelpers/CheckboxesItemTagHelper.cs
@@ -16,10 +16,15 @@ namespace GovUk.Frontend.AspNetCore.TagHelpers
///
[HtmlTargetElement(TagName, ParentTag = CheckboxesTagHelper.TagName)]
[HtmlTargetElement(TagName, ParentTag = CheckboxesFieldsetTagHelper.TagName)]
+ [HtmlTargetElement(TagName, ParentTag = CheckboxesFieldsetTagHelper.ShortTagName)]
+ [HtmlTargetElement(ShortTagName, ParentTag = CheckboxesTagHelper.TagName)]
+ [HtmlTargetElement(ShortTagName, ParentTag = CheckboxesFieldsetTagHelper.TagName)]
+ [HtmlTargetElement(ShortTagName, ParentTag = CheckboxesFieldsetTagHelper.ShortTagName)]
[OutputElementHint(ComponentGenerator.CheckboxesItemElement)]
public class CheckboxesItemTagHelper : TagHelper
{
internal const string TagName = "govuk-checkboxes-item";
+ internal const string ShortTagName = "checkboxes-item";
private const string CheckedAttributeName = "checked";
private const string DisabledAttributeName = "disabled";
diff --git a/src/GovUk.Frontend.AspNetCore/TagHelpers/CheckboxesTagHelper.cs b/src/GovUk.Frontend.AspNetCore/TagHelpers/CheckboxesTagHelper.cs
index 49f78ad5..34105952 100644
--- a/src/GovUk.Frontend.AspNetCore/TagHelpers/CheckboxesTagHelper.cs
+++ b/src/GovUk.Frontend.AspNetCore/TagHelpers/CheckboxesTagHelper.cs
@@ -1,4 +1,3 @@
-using System;
using System.Collections.Generic;
using System.Diagnostics;
using System.Diagnostics.CodeAnalysis;
@@ -13,7 +12,17 @@ namespace GovUk.Frontend.AspNetCore.TagHelpers
/// Generates a GDS checkboxes component.
///
[HtmlTargetElement(TagName)]
- [RestrictChildren(CheckboxesFieldsetTagHelper.TagName, CheckboxesItemTagHelper.TagName, CheckboxesItemDividerTagHelper.TagName, HintTagName, ErrorMessageTagName)]
+ [RestrictChildren(
+ CheckboxesFieldsetTagHelper.TagName,
+ CheckboxesFieldsetTagHelper.ShortTagName,
+ CheckboxesItemTagHelper.TagName,
+ CheckboxesItemTagHelper.ShortTagName,
+ CheckboxesItemDividerTagHelper.TagName,
+ CheckboxesItemDividerTagHelper.ShortTagName,
+ HintTagName,
+ FormGroupHintTagHelper.ShortTagName,
+ ErrorMessageTagName,
+ FormGroupErrorMessageTagHelper.ShortTagName)]
[OutputElementHint(ComponentGenerator.FormGroupElement)]
public class CheckboxesTagHelper : FormGroupTagHelperBase
{
diff --git a/src/GovUk.Frontend.AspNetCore/TagHelpers/DateInputContext.cs b/src/GovUk.Frontend.AspNetCore/TagHelpers/DateInputContext.cs
index b02d8102..d8ec101b 100644
--- a/src/GovUk.Frontend.AspNetCore/TagHelpers/DateInputContext.cs
+++ b/src/GovUk.Frontend.AspNetCore/TagHelpers/DateInputContext.cs
@@ -165,8 +165,11 @@ public override void SetLabel(
internal static DateInputItemType GetItemTypeFromTagName(string tagName) => tagName switch
{
DateInputItemTagHelper.DayTagName => DateInputItemType.Day,
+ DateInputItemTagHelper.ShortDayTagName => DateInputItemType.Day,
DateInputItemTagHelper.MonthTagName => DateInputItemType.Month,
+ DateInputItemTagHelper.ShortMonthTagName => DateInputItemType.Month,
DateInputItemTagHelper.YearTagName => DateInputItemType.Year,
+ DateInputItemTagHelper.ShortYearTagName => DateInputItemType.Year,
_ => throw new ArgumentException($"Unknown tag name: '{tagName}'.", nameof(tagName))
};
diff --git a/src/GovUk.Frontend.AspNetCore/TagHelpers/DateInputErrorMessageTagHelper.cs b/src/GovUk.Frontend.AspNetCore/TagHelpers/DateInputErrorMessageTagHelper.cs
index 7938e58b..97bec4e1 100644
--- a/src/GovUk.Frontend.AspNetCore/TagHelpers/DateInputErrorMessageTagHelper.cs
+++ b/src/GovUk.Frontend.AspNetCore/TagHelpers/DateInputErrorMessageTagHelper.cs
@@ -6,6 +6,10 @@ namespace GovUk.Frontend.AspNetCore.TagHelpers
///
[HtmlTargetElement(DateInputTagHelper.ErrorMessageTagName, ParentTag = DateInputTagHelper.TagName)]
[HtmlTargetElement(DateInputTagHelper.ErrorMessageTagName, ParentTag = DateInputFieldsetTagHelper.TagName)]
+ [HtmlTargetElement(DateInputTagHelper.ErrorMessageTagName, ParentTag = DateInputFieldsetTagHelper.ShortTagName)]
+ [HtmlTargetElement(ShortTagName, ParentTag = DateInputTagHelper.TagName)]
+ [HtmlTargetElement(ShortTagName, ParentTag = DateInputFieldsetTagHelper.TagName)]
+ [HtmlTargetElement(ShortTagName, ParentTag = DateInputFieldsetTagHelper.ShortTagName)]
[OutputElementHint(ComponentGenerator.ErrorMessageElement)]
public class DateInputErrorMessageTagHelper : FormGroupErrorMessageTagHelper
{
diff --git a/src/GovUk.Frontend.AspNetCore/TagHelpers/DateInputFieldsetLegendTagHelper.cs b/src/GovUk.Frontend.AspNetCore/TagHelpers/DateInputFieldsetLegendTagHelper.cs
index 76c1e453..b33dfa2a 100644
--- a/src/GovUk.Frontend.AspNetCore/TagHelpers/DateInputFieldsetLegendTagHelper.cs
+++ b/src/GovUk.Frontend.AspNetCore/TagHelpers/DateInputFieldsetLegendTagHelper.cs
@@ -8,10 +8,14 @@ namespace GovUk.Frontend.AspNetCore.TagHelpers
/// Represents the legend in a GDS date input component's fieldset.
///
[HtmlTargetElement(TagName, ParentTag = DateInputFieldsetTagHelper.TagName)]
+ [HtmlTargetElement(TagName, ParentTag = DateInputFieldsetTagHelper.ShortTagName)]
+ [HtmlTargetElement(ShortTagName, ParentTag = DateInputFieldsetTagHelper.TagName)]
+ [HtmlTargetElement(ShortTagName, ParentTag = DateInputFieldsetTagHelper.ShortTagName)]
[OutputElementHint(ComponentGenerator.FieldsetLegendElement)]
public class DateInputFieldsetLegendTagHelper : TagHelper
{
internal const string TagName = "govuk-date-input-fieldset-legend";
+ internal const string ShortTagName = "legend";
private const string IsPageHeadingAttributeName = "is-page-heading";
diff --git a/src/GovUk.Frontend.AspNetCore/TagHelpers/DateInputFieldsetTagHelper.cs b/src/GovUk.Frontend.AspNetCore/TagHelpers/DateInputFieldsetTagHelper.cs
index a886116d..ad05d00b 100644
--- a/src/GovUk.Frontend.AspNetCore/TagHelpers/DateInputFieldsetTagHelper.cs
+++ b/src/GovUk.Frontend.AspNetCore/TagHelpers/DateInputFieldsetTagHelper.cs
@@ -8,17 +8,25 @@ namespace GovUk.Frontend.AspNetCore.TagHelpers
/// Represents the fieldset in a GDS date input component.
///
[HtmlTargetElement(TagName, ParentTag = DateInputTagHelper.TagName)]
+ [HtmlTargetElement(ShortTagName, ParentTag = DateInputTagHelper.TagName)]
[RestrictChildren(
DateInputFieldsetLegendTagHelper.TagName,
+ DateInputFieldsetLegendTagHelper.ShortTagName,
DateInputTagHelper.HintTagName,
+ FormGroupHintTagHelper.ShortTagName,
DateInputTagHelper.ErrorMessageTagName,
+ FormGroupErrorMessageTagHelper.ShortTagName,
DateInputItemTagHelper.DayTagName,
+ DateInputItemTagHelper.ShortDayTagName,
DateInputItemTagHelper.MonthTagName,
- DateInputItemTagHelper.YearTagName)]
+ DateInputItemTagHelper.ShortMonthTagName,
+ DateInputItemTagHelper.YearTagName,
+ DateInputItemTagHelper.ShortYearTagName)]
[OutputElementHint(ComponentGenerator.FieldsetElement)]
public class DateInputFieldsetTagHelper : TagHelper
{
internal const string TagName = "govuk-date-input-fieldset";
+ internal const string ShortTagName = "date-input-fieldset";
private const string DescribedByAttributeName = "described-by";
diff --git a/src/GovUk.Frontend.AspNetCore/TagHelpers/DateInputItemLabelTagHelper.cs b/src/GovUk.Frontend.AspNetCore/TagHelpers/DateInputItemLabelTagHelper.cs
index df6c29ef..5f108396 100644
--- a/src/GovUk.Frontend.AspNetCore/TagHelpers/DateInputItemLabelTagHelper.cs
+++ b/src/GovUk.Frontend.AspNetCore/TagHelpers/DateInputItemLabelTagHelper.cs
@@ -8,14 +8,24 @@ namespace GovUk.Frontend.AspNetCore.TagHelpers
/// Represents the label in a GDS date input component item.
///
[HtmlTargetElement(DayTagName, ParentTag = DateInputItemTagHelper.DayTagName)]
+ [HtmlTargetElement(DayTagName, ParentTag = DateInputItemTagHelper.ShortDayTagName)]
[HtmlTargetElement(MonthTagName, ParentTag = DateInputItemTagHelper.MonthTagName)]
+ [HtmlTargetElement(MonthTagName, ParentTag = DateInputItemTagHelper.ShortMonthTagName)]
[HtmlTargetElement(YearTagName, ParentTag = DateInputItemTagHelper.YearTagName)]
+ [HtmlTargetElement(YearTagName, ParentTag = DateInputItemTagHelper.ShortYearTagName)]
+ [HtmlTargetElement(ShortTagName, ParentTag = DateInputItemTagHelper.DayTagName)]
+ [HtmlTargetElement(ShortTagName, ParentTag = DateInputItemTagHelper.ShortDayTagName)]
+ [HtmlTargetElement(ShortTagName, ParentTag = DateInputItemTagHelper.MonthTagName)]
+ [HtmlTargetElement(ShortTagName, ParentTag = DateInputItemTagHelper.ShortMonthTagName)]
+ [HtmlTargetElement(ShortTagName, ParentTag = DateInputItemTagHelper.YearTagName)]
+ [HtmlTargetElement(ShortTagName, ParentTag = DateInputItemTagHelper.ShortYearTagName)]
[OutputElementHint(ComponentGenerator.LabelElement)]
public class DateInputItemLabelTagHelper : TagHelper
{
internal const string DayTagName = "govuk-date-input-day-label";
internal const string MonthTagName = "govuk-date-input-month-label";
internal const string YearTagName = "govuk-date-input-year-label";
+ internal const string ShortTagName = "label";
///
/// Creates a .
diff --git a/src/GovUk.Frontend.AspNetCore/TagHelpers/DateInputItemTagHelper.cs b/src/GovUk.Frontend.AspNetCore/TagHelpers/DateInputItemTagHelper.cs
index ebd383f0..1bf5057f 100644
--- a/src/GovUk.Frontend.AspNetCore/TagHelpers/DateInputItemTagHelper.cs
+++ b/src/GovUk.Frontend.AspNetCore/TagHelpers/DateInputItemTagHelper.cs
@@ -12,17 +12,36 @@ namespace GovUk.Frontend.AspNetCore.TagHelpers
///
[HtmlTargetElement(DayTagName, ParentTag = DateInputTagHelper.TagName)]
[HtmlTargetElement(DayTagName, ParentTag = DateInputFieldsetTagHelper.TagName)]
+ [HtmlTargetElement(DayTagName, ParentTag = DateInputFieldsetTagHelper.ShortTagName)]
+ [HtmlTargetElement(ShortDayTagName, ParentTag = DateInputTagHelper.TagName)]
+ [HtmlTargetElement(ShortDayTagName, ParentTag = DateInputFieldsetTagHelper.TagName)]
+ [HtmlTargetElement(ShortDayTagName, ParentTag = DateInputFieldsetTagHelper.ShortTagName)]
[HtmlTargetElement(MonthTagName, ParentTag = DateInputTagHelper.TagName)]
[HtmlTargetElement(MonthTagName, ParentTag = DateInputFieldsetTagHelper.TagName)]
+ [HtmlTargetElement(MonthTagName, ParentTag = DateInputFieldsetTagHelper.ShortTagName)]
+ [HtmlTargetElement(ShortMonthTagName, ParentTag = DateInputTagHelper.TagName)]
+ [HtmlTargetElement(ShortMonthTagName, ParentTag = DateInputFieldsetTagHelper.TagName)]
+ [HtmlTargetElement(ShortMonthTagName, ParentTag = DateInputFieldsetTagHelper.ShortTagName)]
[HtmlTargetElement(YearTagName, ParentTag = DateInputTagHelper.TagName)]
[HtmlTargetElement(YearTagName, ParentTag = DateInputFieldsetTagHelper.TagName)]
+ [HtmlTargetElement(YearTagName, ParentTag = DateInputFieldsetTagHelper.ShortTagName)]
+ [HtmlTargetElement(ShortYearTagName, ParentTag = DateInputTagHelper.TagName)]
+ [HtmlTargetElement(ShortYearTagName, ParentTag = DateInputFieldsetTagHelper.TagName)]
+ [HtmlTargetElement(ShortYearTagName, ParentTag = DateInputFieldsetTagHelper.ShortTagName)]
[OutputElementHint(ComponentGenerator.FormGroupElement)]
- [RestrictChildren(DateInputItemLabelTagHelper.DayTagName, DateInputItemLabelTagHelper.MonthTagName, DateInputItemLabelTagHelper.YearTagName)]
+ [RestrictChildren(
+ DateInputItemLabelTagHelper.DayTagName,
+ DateInputItemLabelTagHelper.MonthTagName,
+ DateInputItemLabelTagHelper.YearTagName,
+ DateInputItemLabelTagHelper.ShortTagName)]
public class DateInputItemTagHelper : TagHelper
{
internal const string DayTagName = "govuk-date-input-day";
+ internal const string ShortDayTagName = "day";
internal const string MonthTagName = "govuk-date-input-month";
+ internal const string ShortMonthTagName = "month";
internal const string YearTagName = "govuk-date-input-year";
+ internal const string ShortYearTagName = "year";
private const string AutocompleteAttributeName = "autocomplete";
private const string IdAttributeName = "id";
diff --git a/src/GovUk.Frontend.AspNetCore/TagHelpers/DateInputTagHelper.cs b/src/GovUk.Frontend.AspNetCore/TagHelpers/DateInputTagHelper.cs
index 5f32aa4c..076f1270 100644
--- a/src/GovUk.Frontend.AspNetCore/TagHelpers/DateInputTagHelper.cs
+++ b/src/GovUk.Frontend.AspNetCore/TagHelpers/DateInputTagHelper.cs
@@ -4,7 +4,6 @@
using GovUk.Frontend.AspNetCore.HtmlGeneration;
using GovUk.Frontend.AspNetCore.ModelBinding;
using Microsoft.AspNetCore.Html;
-using Microsoft.AspNetCore.Mvc.ModelBinding;
using Microsoft.AspNetCore.Mvc.Rendering;
using Microsoft.AspNetCore.Razor.TagHelpers;
using Microsoft.Extensions.Options;
@@ -17,11 +16,17 @@ namespace GovUk.Frontend.AspNetCore.TagHelpers
[HtmlTargetElement(TagName)]
[RestrictChildren(
DateInputFieldsetTagHelper.TagName,
+ DateInputFieldsetTagHelper.ShortTagName,
HintTagName,
+ FormGroupHintTagHelper.ShortTagName,
ErrorMessageTagName,
+ FormGroupErrorMessageTagHelper.ShortTagName,
DateInputItemTagHelper.DayTagName,
+ DateInputItemTagHelper.ShortDayTagName,
DateInputItemTagHelper.MonthTagName,
- DateInputItemTagHelper.YearTagName)]
+ DateInputItemTagHelper.ShortMonthTagName,
+ DateInputItemTagHelper.YearTagName,
+ DateInputItemTagHelper.ShortYearTagName)]
[OutputElementHint(ComponentGenerator.FormGroupElement)]
public class DateInputTagHelper : FormGroupTagHelperBase
{
diff --git a/src/GovUk.Frontend.AspNetCore/TagHelpers/DetailsSummaryTagHelper.cs b/src/GovUk.Frontend.AspNetCore/TagHelpers/DetailsSummaryTagHelper.cs
index 1dac420e..020aa31b 100644
--- a/src/GovUk.Frontend.AspNetCore/TagHelpers/DetailsSummaryTagHelper.cs
+++ b/src/GovUk.Frontend.AspNetCore/TagHelpers/DetailsSummaryTagHelper.cs
@@ -8,10 +8,12 @@ namespace GovUk.Frontend.AspNetCore.TagHelpers
/// Represents the summary in a GDS details component.
///
[HtmlTargetElement(TagName, ParentTag = DetailsTagHelper.TagName)]
+ [HtmlTargetElement(ShortTagName, ParentTag = DetailsTagHelper.TagName)]
[OutputElementHint(ComponentGenerator.DetailsSummaryElement)]
public class DetailsSummaryTagHelper : TagHelper
{
internal const string TagName = "govuk-details-summary";
+ internal const string ShortTagName = "summary";
///
public override async Task ProcessAsync(TagHelperContext context, TagHelperOutput output)
diff --git a/src/GovUk.Frontend.AspNetCore/TagHelpers/DetailsTagHelper.cs b/src/GovUk.Frontend.AspNetCore/TagHelpers/DetailsTagHelper.cs
index 31152fc4..9009d30e 100644
--- a/src/GovUk.Frontend.AspNetCore/TagHelpers/DetailsTagHelper.cs
+++ b/src/GovUk.Frontend.AspNetCore/TagHelpers/DetailsTagHelper.cs
@@ -9,7 +9,11 @@ namespace GovUk.Frontend.AspNetCore.TagHelpers
/// Generates a GDS details component.
///
[HtmlTargetElement(TagName)]
- [RestrictChildren(DetailsSummaryTagHelper.TagName, DetailsTextTagHelper.TagName)]
+ [RestrictChildren(
+ DetailsSummaryTagHelper.TagName,
+ DetailsSummaryTagHelper.ShortTagName,
+ DetailsTextTagHelper.TagName,
+ DetailsTextTagHelper.ShortTagName)]
[OutputElementHint(ComponentGenerator.DetailsElement)]
public class DetailsTagHelper : TagHelper
{
diff --git a/src/GovUk.Frontend.AspNetCore/TagHelpers/DetailsTextTagHelper.cs b/src/GovUk.Frontend.AspNetCore/TagHelpers/DetailsTextTagHelper.cs
index d730d73e..52a2c85b 100644
--- a/src/GovUk.Frontend.AspNetCore/TagHelpers/DetailsTextTagHelper.cs
+++ b/src/GovUk.Frontend.AspNetCore/TagHelpers/DetailsTextTagHelper.cs
@@ -8,10 +8,12 @@ namespace GovUk.Frontend.AspNetCore.TagHelpers
/// Represents the text in a GDS details component.
///
[HtmlTargetElement(TagName, ParentTag = DetailsTagHelper.TagName)]
+ [HtmlTargetElement(ShortTagName, ParentTag = DetailsTagHelper.TagName)]
[OutputElementHint(ComponentGenerator.DetailsTextElement)]
public class DetailsTextTagHelper : TagHelper
{
internal const string TagName = "govuk-details-text";
+ internal const string ShortTagName = "text";
///
public override async Task ProcessAsync(TagHelperContext context, TagHelperOutput output)
diff --git a/src/GovUk.Frontend.AspNetCore/TagHelpers/ErrorSummaryDescriptionTagHelper.cs b/src/GovUk.Frontend.AspNetCore/TagHelpers/ErrorSummaryDescriptionTagHelper.cs
index 920398b0..106d7564 100644
--- a/src/GovUk.Frontend.AspNetCore/TagHelpers/ErrorSummaryDescriptionTagHelper.cs
+++ b/src/GovUk.Frontend.AspNetCore/TagHelpers/ErrorSummaryDescriptionTagHelper.cs
@@ -7,9 +7,11 @@ namespace GovUk.Frontend.AspNetCore.TagHelpers
/// Represents the description in a GDS error summary component.
///
[HtmlTargetElement(TagName, ParentTag = ErrorSummaryTagHelper.TagName)]
+ [HtmlTargetElement(ShortTagName, ParentTag = ErrorSummaryTagHelper.TagName)]
public class ErrorSummaryDescriptionTagHelper : TagHelper
{
internal const string TagName = "govuk-error-summary-description";
+ internal const string ShortTagName = "description";
///
public override async Task ProcessAsync(TagHelperContext context, TagHelperOutput output)
diff --git a/src/GovUk.Frontend.AspNetCore/TagHelpers/ErrorSummaryItemTagHelper.cs b/src/GovUk.Frontend.AspNetCore/TagHelpers/ErrorSummaryItemTagHelper.cs
index e0289b67..484880df 100644
--- a/src/GovUk.Frontend.AspNetCore/TagHelpers/ErrorSummaryItemTagHelper.cs
+++ b/src/GovUk.Frontend.AspNetCore/TagHelpers/ErrorSummaryItemTagHelper.cs
@@ -17,9 +17,11 @@ namespace GovUk.Frontend.AspNetCore.TagHelpers
/// Represents an error item in a GDS error summary component.
///
[HtmlTargetElement(TagName, ParentTag = ErrorSummaryTagHelper.TagName)]
+ [HtmlTargetElement(ShortTagName, ParentTag = ErrorSummaryTagHelper.TagName)]
public class ErrorSummaryItemTagHelper : TagHelper
{
internal const string TagName = "govuk-error-summary-item";
+ internal const string ShortTagName = "error-item";
private const string AspForAttributeName = "asp-for";
private const string LinkAttributesPrefix = "link-";
diff --git a/src/GovUk.Frontend.AspNetCore/TagHelpers/ErrorSummaryTagHelper.cs b/src/GovUk.Frontend.AspNetCore/TagHelpers/ErrorSummaryTagHelper.cs
index ae851b74..3602390d 100644
--- a/src/GovUk.Frontend.AspNetCore/TagHelpers/ErrorSummaryTagHelper.cs
+++ b/src/GovUk.Frontend.AspNetCore/TagHelpers/ErrorSummaryTagHelper.cs
@@ -10,7 +10,13 @@ namespace GovUk.Frontend.AspNetCore.TagHelpers
/// Generates a GDS error summary component.
///
[HtmlTargetElement(TagName)]
- [RestrictChildren(ErrorSummaryTitleTagHelper.TagName, ErrorSummaryDescriptionTagHelper.TagName, "govuk-error-summary-item")]
+ [RestrictChildren(
+ ErrorSummaryTitleTagHelper.TagName,
+ ErrorSummaryTitleTagHelper.ShortTagName,
+ ErrorSummaryDescriptionTagHelper.TagName,
+ ErrorSummaryDescriptionTagHelper.ShortTagName,
+ ErrorSummaryItemTagHelper.TagName,
+ ErrorSummaryItemTagHelper.ShortTagName)]
[OutputElementHint(ComponentGenerator.ErrorSummaryElement)]
public class ErrorSummaryTagHelper : TagHelper
{
diff --git a/src/GovUk.Frontend.AspNetCore/TagHelpers/ErrorSummaryTitleTagHelper.cs b/src/GovUk.Frontend.AspNetCore/TagHelpers/ErrorSummaryTitleTagHelper.cs
index 70187f7c..6e7b0667 100644
--- a/src/GovUk.Frontend.AspNetCore/TagHelpers/ErrorSummaryTitleTagHelper.cs
+++ b/src/GovUk.Frontend.AspNetCore/TagHelpers/ErrorSummaryTitleTagHelper.cs
@@ -7,9 +7,11 @@ namespace GovUk.Frontend.AspNetCore.TagHelpers
/// Represents the title in the GDS error summary component.
///
[HtmlTargetElement(TagName, ParentTag = ErrorSummaryTagHelper.TagName)]
+ [HtmlTargetElement(ShortTagName, ParentTag = ErrorSummaryTagHelper.TagName)]
public class ErrorSummaryTitleTagHelper : TagHelper
{
internal const string TagName = "govuk-error-summary-title";
+ internal const string ShortTagName = "title";
///
public override async Task ProcessAsync(TagHelperContext context, TagHelperOutput output)
diff --git a/src/GovUk.Frontend.AspNetCore/TagHelpers/FieldsetLegendTagHelper.cs b/src/GovUk.Frontend.AspNetCore/TagHelpers/FieldsetLegendTagHelper.cs
index 8b70e4ae..1bbb0343 100644
--- a/src/GovUk.Frontend.AspNetCore/TagHelpers/FieldsetLegendTagHelper.cs
+++ b/src/GovUk.Frontend.AspNetCore/TagHelpers/FieldsetLegendTagHelper.cs
@@ -8,10 +8,12 @@ namespace GovUk.Frontend.AspNetCore.TagHelpers
/// Represents the legend in a GDS fieldset component.
///
[HtmlTargetElement(TagName, ParentTag = FieldsetTagHelper.TagName)]
+ [HtmlTargetElement(ShortTagName, ParentTag = FieldsetTagHelper.TagName)]
[OutputElementHint(ComponentGenerator.FieldsetLegendElement)]
public class FieldsetLegendTagHelper : TagHelper
{
internal const string TagName = "govuk-fieldset-legend";
+ internal const string ShortTagName = "legend";
private const string IsPageHeadingAttributeName = "is-page-heading";
diff --git a/src/GovUk.Frontend.AspNetCore/TagHelpers/FileUploadTagHelper.cs b/src/GovUk.Frontend.AspNetCore/TagHelpers/FileUploadTagHelper.cs
index 8d6cf715..69e42ecb 100644
--- a/src/GovUk.Frontend.AspNetCore/TagHelpers/FileUploadTagHelper.cs
+++ b/src/GovUk.Frontend.AspNetCore/TagHelpers/FileUploadTagHelper.cs
@@ -10,7 +10,13 @@ namespace GovUk.Frontend.AspNetCore.TagHelpers
/// Generates a GDS File upload component.
///
[HtmlTargetElement(TagName)]
- [RestrictChildren(LabelTagName, HintTagName, ErrorMessageTagName)]
+ [RestrictChildren(
+ LabelTagName,
+ FormGroupLabelTagHelper.ShortTagName,
+ HintTagName,
+ FormGroupHintTagHelper.ShortTagName,
+ ErrorMessageTagName,
+ FormGroupErrorMessageTagHelper.ShortTagName)]
public class FileUploadTagHelper : FormGroupTagHelperBase
{
internal const string ErrorMessageTagName = "govuk-file-upload-error-message";
diff --git a/src/GovUk.Frontend.AspNetCore/TagHelpers/FormGroupErrorMessageTagHelper.cs b/src/GovUk.Frontend.AspNetCore/TagHelpers/FormGroupErrorMessageTagHelper.cs
index fcaa22e7..27b1b1b9 100644
--- a/src/GovUk.Frontend.AspNetCore/TagHelpers/FormGroupErrorMessageTagHelper.cs
+++ b/src/GovUk.Frontend.AspNetCore/TagHelpers/FormGroupErrorMessageTagHelper.cs
@@ -8,17 +8,32 @@ namespace GovUk.Frontend.AspNetCore.TagHelpers
/// Represents the error message in a GDS form group component.
///
[HtmlTargetElement(CheckboxesTagHelper.ErrorMessageTagName, ParentTag = CheckboxesTagHelper.TagName)]
+ [HtmlTargetElement(ShortTagName, ParentTag = CheckboxesTagHelper.TagName)]
[HtmlTargetElement(CheckboxesTagHelper.ErrorMessageTagName, ParentTag = CheckboxesFieldsetTagHelper.TagName)]
+ [HtmlTargetElement(ShortTagName, ParentTag = CheckboxesFieldsetTagHelper.TagName)]
+ [HtmlTargetElement(CheckboxesTagHelper.ErrorMessageTagName, ParentTag = CheckboxesFieldsetTagHelper.ShortTagName)]
+ [HtmlTargetElement(ShortTagName, ParentTag = CheckboxesFieldsetTagHelper.ShortTagName)]
[HtmlTargetElement(CharacterCountTagHelper.ErrorMessageTagName, ParentTag = CharacterCountTagHelper.TagName)]
+ [HtmlTargetElement(ShortTagName, ParentTag = CharacterCountTagHelper.TagName)]
[HtmlTargetElement(FileUploadTagHelper.ErrorMessageTagName, ParentTag = FileUploadTagHelper.TagName)]
+ [HtmlTargetElement(ShortTagName, ParentTag = FileUploadTagHelper.TagName)]
[HtmlTargetElement(RadiosTagHelper.ErrorMessageTagName, ParentTag = RadiosTagHelper.TagName)]
+ [HtmlTargetElement(ShortTagName, ParentTag = RadiosTagHelper.TagName)]
[HtmlTargetElement(RadiosTagHelper.ErrorMessageTagName, ParentTag = RadiosFieldsetTagHelper.TagName)]
+ [HtmlTargetElement(ShortTagName, ParentTag = RadiosFieldsetTagHelper.TagName)]
+ [HtmlTargetElement(RadiosTagHelper.ErrorMessageTagName, ParentTag = RadiosFieldsetTagHelper.ShortTagName)]
+ [HtmlTargetElement(ShortTagName, ParentTag = RadiosFieldsetTagHelper.ShortTagName)]
[HtmlTargetElement(SelectTagHelper.ErrorMessageTagName, ParentTag = SelectTagHelper.TagName)]
+ [HtmlTargetElement(ShortTagName, ParentTag = SelectTagHelper.TagName)]
[HtmlTargetElement(TextAreaTagHelper.ErrorMessageTagName, ParentTag = TextAreaTagHelper.TagName)]
+ [HtmlTargetElement(ShortTagName, ParentTag = TextAreaTagHelper.TagName)]
[HtmlTargetElement(TextInputTagHelper.ErrorMessageTagName, ParentTag = TextInputTagHelper.TagName)]
+ [HtmlTargetElement(ShortTagName, ParentTag = TextInputTagHelper.TagName)]
[OutputElementHint(ComponentGenerator.ErrorMessageElement)]
public class FormGroupErrorMessageTagHelper : TagHelper
{
+ internal const string ShortTagName = "error-message";
+
private const string VisuallyHiddenTextAttributeName = "visually-hidden-text";
///
diff --git a/src/GovUk.Frontend.AspNetCore/TagHelpers/FormGroupHintTagHelper.cs b/src/GovUk.Frontend.AspNetCore/TagHelpers/FormGroupHintTagHelper.cs
index 6d43fa21..b8fc39bc 100644
--- a/src/GovUk.Frontend.AspNetCore/TagHelpers/FormGroupHintTagHelper.cs
+++ b/src/GovUk.Frontend.AspNetCore/TagHelpers/FormGroupHintTagHelper.cs
@@ -8,19 +8,38 @@ namespace GovUk.Frontend.AspNetCore.TagHelpers
/// Represents the hint in a GDS form group component.
///
[HtmlTargetElement(CheckboxesTagHelper.HintTagName, ParentTag = CheckboxesTagHelper.TagName)]
+ [HtmlTargetElement(ShortTagName, ParentTag = CheckboxesTagHelper.TagName)]
[HtmlTargetElement(CheckboxesTagHelper.HintTagName, ParentTag = CheckboxesFieldsetTagHelper.TagName)]
+ [HtmlTargetElement(ShortTagName, ParentTag = CheckboxesFieldsetTagHelper.TagName)]
+ [HtmlTargetElement(CheckboxesTagHelper.HintTagName, ParentTag = CheckboxesFieldsetTagHelper.ShortTagName)]
+ [HtmlTargetElement(ShortTagName, ParentTag = CheckboxesFieldsetTagHelper.ShortTagName)]
[HtmlTargetElement(CharacterCountTagHelper.HintTagName, ParentTag = CharacterCountTagHelper.TagName)]
+ [HtmlTargetElement(ShortTagName, ParentTag = CharacterCountTagHelper.TagName)]
[HtmlTargetElement(DateInputTagHelper.HintTagName, ParentTag = DateInputTagHelper.TagName)]
+ [HtmlTargetElement(ShortTagName, ParentTag = DateInputTagHelper.TagName)]
[HtmlTargetElement(DateInputTagHelper.HintTagName, ParentTag = DateInputFieldsetTagHelper.TagName)]
+ [HtmlTargetElement(ShortTagName, ParentTag = DateInputFieldsetTagHelper.TagName)]
+ [HtmlTargetElement(DateInputTagHelper.HintTagName, ParentTag = DateInputFieldsetTagHelper.ShortTagName)]
+ [HtmlTargetElement(ShortTagName, ParentTag = DateInputFieldsetTagHelper.ShortTagName)]
[HtmlTargetElement(FileUploadTagHelper.HintTagName, ParentTag = FileUploadTagHelper.TagName)]
+ [HtmlTargetElement(ShortTagName, ParentTag = FileUploadTagHelper.TagName)]
[HtmlTargetElement(RadiosTagHelper.HintTagName, ParentTag = RadiosTagHelper.TagName)]
+ [HtmlTargetElement(ShortTagName, ParentTag = RadiosTagHelper.TagName)]
[HtmlTargetElement(RadiosTagHelper.HintTagName, ParentTag = RadiosFieldsetTagHelper.TagName)]
+ [HtmlTargetElement(ShortTagName, ParentTag = RadiosFieldsetTagHelper.TagName)]
+ [HtmlTargetElement(RadiosTagHelper.HintTagName, ParentTag = RadiosFieldsetTagHelper.ShortTagName)]
+ [HtmlTargetElement(ShortTagName, ParentTag = RadiosFieldsetTagHelper.ShortTagName)]
[HtmlTargetElement(SelectTagHelper.HintTagName, ParentTag = SelectTagHelper.TagName)]
+ [HtmlTargetElement(ShortTagName, ParentTag = SelectTagHelper.TagName)]
[HtmlTargetElement(TextAreaTagHelper.HintTagName, ParentTag = TextAreaTagHelper.TagName)]
+ [HtmlTargetElement(ShortTagName, ParentTag = TextAreaTagHelper.TagName)]
[HtmlTargetElement(TextInputTagHelper.HintTagName, ParentTag = TextInputTagHelper.TagName)]
+ [HtmlTargetElement(ShortTagName, ParentTag = TextInputTagHelper.TagName)]
[OutputElementHint(ComponentGenerator.HintElement)]
public class FormGroupHintTagHelper : TagHelper
{
+ internal const string ShortTagName = "hint";
+
///
/// Creates a .
///
diff --git a/src/GovUk.Frontend.AspNetCore/TagHelpers/FormGroupLabelTagHelper.cs b/src/GovUk.Frontend.AspNetCore/TagHelpers/FormGroupLabelTagHelper.cs
index 3cb6cdc8..af4a644d 100644
--- a/src/GovUk.Frontend.AspNetCore/TagHelpers/FormGroupLabelTagHelper.cs
+++ b/src/GovUk.Frontend.AspNetCore/TagHelpers/FormGroupLabelTagHelper.cs
@@ -8,13 +8,20 @@ namespace GovUk.Frontend.AspNetCore.TagHelpers
/// Represents the label in a GDS form group component.
///
[HtmlTargetElement(CharacterCountTagHelper.LabelTagName, ParentTag = CharacterCountTagHelper.TagName)]
+ [HtmlTargetElement(ShortTagName, ParentTag = CharacterCountTagHelper.TagName)]
[HtmlTargetElement(FileUploadTagHelper.LabelTagName, ParentTag = FileUploadTagHelper.TagName)]
+ [HtmlTargetElement(ShortTagName, ParentTag = FileUploadTagHelper.TagName)]
[HtmlTargetElement(SelectTagHelper.LabelTagName, ParentTag = SelectTagHelper.TagName)]
+ [HtmlTargetElement(ShortTagName, ParentTag = SelectTagHelper.TagName)]
[HtmlTargetElement(TextAreaTagHelper.LabelTagName, ParentTag = TextAreaTagHelper.TagName)]
+ [HtmlTargetElement(ShortTagName, ParentTag = TextAreaTagHelper.TagName)]
[HtmlTargetElement(TextInputTagHelper.LabelTagName, ParentTag = TextInputTagHelper.TagName)]
+ [HtmlTargetElement(ShortTagName, ParentTag = TextInputTagHelper.TagName)]
[OutputElementHint(ComponentGenerator.LabelElement)]
public class FormGroupLabelTagHelper : TagHelper
{
+ internal const string ShortTagName = "label";
+
private const string IsPageHeadingAttributeName = "is-page-heading";
///
diff --git a/src/GovUk.Frontend.AspNetCore/TagHelpers/NotificationBannerTitleTagHelper.cs b/src/GovUk.Frontend.AspNetCore/TagHelpers/NotificationBannerTitleTagHelper.cs
index 53dbba0e..c37a4412 100644
--- a/src/GovUk.Frontend.AspNetCore/TagHelpers/NotificationBannerTitleTagHelper.cs
+++ b/src/GovUk.Frontend.AspNetCore/TagHelpers/NotificationBannerTitleTagHelper.cs
@@ -9,9 +9,11 @@ namespace GovUk.Frontend.AspNetCore.TagHelpers
/// Represents the title in a GDS notification banner component.
///
[HtmlTargetElement(TagName, ParentTag = NotificationBannerTagHelper.TagName)]
+ [HtmlTargetElement(ShortTagName, ParentTag = NotificationBannerTagHelper.TagName)]
public class NotificationBannerTitleTagHelper : TagHelper
{
internal const string TagName = "govuk-notification-banner-title";
+ internal const string ShortTagName = "title";
private const string HeadingLevelAttributeName = "heading-level";
private const string IdAttributeName = "heading-level";
diff --git a/src/GovUk.Frontend.AspNetCore/TagHelpers/PaginationEllipsisItemTagHelper.cs b/src/GovUk.Frontend.AspNetCore/TagHelpers/PaginationEllipsisItemTagHelper.cs
index 599d77e4..60ffb8f2 100644
--- a/src/GovUk.Frontend.AspNetCore/TagHelpers/PaginationEllipsisItemTagHelper.cs
+++ b/src/GovUk.Frontend.AspNetCore/TagHelpers/PaginationEllipsisItemTagHelper.cs
@@ -7,10 +7,12 @@ namespace GovUk.Frontend.AspNetCore.TagHelpers
/// Represents an ellipsis item in a GDS pagination component.
///
[HtmlTargetElement(TagName, ParentTag = PaginationTagHelper.TagName)]
+ [HtmlTargetElement(ShortTagName, ParentTag = PaginationTagHelper.TagName)]
[OutputElementHint(ComponentGenerator.PaginationEllipsisElement)]
public class PaginationEllipsisItemTagHelper : TagHelper
{
internal const string TagName = "govuk-pagination-ellipsis";
+ internal const string ShortTagName = "ellipsis";
///
public override void Process(TagHelperContext context, TagHelperOutput output)
diff --git a/src/GovUk.Frontend.AspNetCore/TagHelpers/PaginationItemTagHelper.cs b/src/GovUk.Frontend.AspNetCore/TagHelpers/PaginationItemTagHelper.cs
index 4eae9960..fdf25c73 100644
--- a/src/GovUk.Frontend.AspNetCore/TagHelpers/PaginationItemTagHelper.cs
+++ b/src/GovUk.Frontend.AspNetCore/TagHelpers/PaginationItemTagHelper.cs
@@ -12,10 +12,12 @@ namespace GovUk.Frontend.AspNetCore.TagHelpers
/// Represents an item in a GDS pagination component.
///
[HtmlTargetElement(TagName, ParentTag = PaginationTagHelper.TagName)]
+ [HtmlTargetElement(ShortTagName, ParentTag = PaginationTagHelper.TagName)]
[OutputElementHint(ComponentGenerator.PaginationItemElement)]
public class PaginationItemTagHelper : TagHelper
{
internal const string TagName = "govuk-pagination-item";
+ internal const string ShortTagName = "pagination-item";
private const string IsCurrentAttributeName = "is-current";
private const string VisuallyHiddenTextAttributeName = "visually-hidden-text";
diff --git a/src/GovUk.Frontend.AspNetCore/TagHelpers/PaginationNextTagHelper.cs b/src/GovUk.Frontend.AspNetCore/TagHelpers/PaginationNextTagHelper.cs
index 28dcfb96..7e4052c2 100644
--- a/src/GovUk.Frontend.AspNetCore/TagHelpers/PaginationNextTagHelper.cs
+++ b/src/GovUk.Frontend.AspNetCore/TagHelpers/PaginationNextTagHelper.cs
@@ -9,10 +9,12 @@ namespace GovUk.Frontend.AspNetCore.TagHelpers
/// Represents the link to the next page in a GDS pagination component.
///
[HtmlTargetElement(TagName, ParentTag = PaginationTagHelper.TagName)]
+ [HtmlTargetElement(ShortTagName, ParentTag = PaginationTagHelper.TagName)]
[OutputElementHint(ComponentGenerator.PaginationNextElement)]
public class PaginationNextTagHelper : TagHelper
{
internal const string TagName = "govuk-pagination-next";
+ internal const string ShortTagName = "next";
private const string LabelTextAttributeName = "label-text";
private const string LinkAttributesPrefix = "link-";
diff --git a/src/GovUk.Frontend.AspNetCore/TagHelpers/PaginationPreviousTagHelper.cs b/src/GovUk.Frontend.AspNetCore/TagHelpers/PaginationPreviousTagHelper.cs
index 703eddbc..fa3d40e5 100644
--- a/src/GovUk.Frontend.AspNetCore/TagHelpers/PaginationPreviousTagHelper.cs
+++ b/src/GovUk.Frontend.AspNetCore/TagHelpers/PaginationPreviousTagHelper.cs
@@ -9,10 +9,12 @@ namespace GovUk.Frontend.AspNetCore.TagHelpers
/// Represents the link to the previous page in a GDS pagination component.
///
[HtmlTargetElement(TagName, ParentTag = PaginationTagHelper.TagName)]
+ [HtmlTargetElement(ShortTagName, ParentTag = PaginationTagHelper.TagName)]
[OutputElementHint(ComponentGenerator.PaginationPreviousElement)]
public class PaginationPreviousTagHelper : TagHelper
{
internal const string TagName = "govuk-pagination-previous";
+ internal const string ShortTagName = "previous";
private const string LabelTextAttributeName = "label-text";
private const string LinkAttributesPrefix = "link-";
diff --git a/src/GovUk.Frontend.AspNetCore/TagHelpers/PaginationTagHelper.cs b/src/GovUk.Frontend.AspNetCore/TagHelpers/PaginationTagHelper.cs
index c38347ca..89aa2306 100644
--- a/src/GovUk.Frontend.AspNetCore/TagHelpers/PaginationTagHelper.cs
+++ b/src/GovUk.Frontend.AspNetCore/TagHelpers/PaginationTagHelper.cs
@@ -12,9 +12,13 @@ namespace GovUk.Frontend.AspNetCore.TagHelpers
[HtmlTargetElement(TagName)]
[RestrictChildren(
PaginationPreviousTagHelper.TagName,
+ PaginationPreviousTagHelper.ShortTagName,
PaginationItemTagHelper.TagName,
+ PaginationItemTagHelper.ShortTagName,
PaginationEllipsisItemTagHelper.TagName,
- PaginationNextTagHelper.TagName)]
+ PaginationEllipsisItemTagHelper.ShortTagName,
+ PaginationNextTagHelper.TagName,
+ PaginationNextTagHelper.ShortTagName)]
[OutputElementHint(ComponentGenerator.PaginationElement)]
public class PaginationTagHelper : TagHelper
{
diff --git a/src/GovUk.Frontend.AspNetCore/TagHelpers/PanelBodyTagHelper.cs b/src/GovUk.Frontend.AspNetCore/TagHelpers/PanelBodyTagHelper.cs
index 5fa23bcf..4e1d813a 100644
--- a/src/GovUk.Frontend.AspNetCore/TagHelpers/PanelBodyTagHelper.cs
+++ b/src/GovUk.Frontend.AspNetCore/TagHelpers/PanelBodyTagHelper.cs
@@ -7,9 +7,11 @@ namespace GovUk.Frontend.AspNetCore.TagHelpers
/// Represents the body in a GDS panel component.
///
[HtmlTargetElement(TagName, ParentTag = PanelTagHelper.TagName)]
+ [HtmlTargetElement(ShortTagName, ParentTag = PanelTagHelper.TagName)]
public class PanelBodyTagHelper : TagHelper
{
internal const string TagName = "govuk-panel-body";
+ internal const string ShortTagName = "body";
///
public override async Task ProcessAsync(TagHelperContext context, TagHelperOutput output)
diff --git a/src/GovUk.Frontend.AspNetCore/TagHelpers/PanelTagHelper.cs b/src/GovUk.Frontend.AspNetCore/TagHelpers/PanelTagHelper.cs
index 08965db1..9939e72d 100644
--- a/src/GovUk.Frontend.AspNetCore/TagHelpers/PanelTagHelper.cs
+++ b/src/GovUk.Frontend.AspNetCore/TagHelpers/PanelTagHelper.cs
@@ -11,7 +11,11 @@ namespace GovUk.Frontend.AspNetCore.TagHelpers
///
[HtmlTargetElement(TagName)]
[OutputElementHint(ComponentGenerator.PanelElement)]
- [RestrictChildren(PanelTitleTagHelper.TagName, PanelBodyTagHelper.TagName)]
+ [RestrictChildren(
+ PanelTitleTagHelper.TagName,
+ PanelTitleTagHelper.ShortTagName,
+ PanelBodyTagHelper.TagName,
+ PanelBodyTagHelper.ShortTagName)]
public class PanelTagHelper : TagHelper
{
internal const string TagName = "govuk-panel";
diff --git a/src/GovUk.Frontend.AspNetCore/TagHelpers/PanelTitleTagHelper.cs b/src/GovUk.Frontend.AspNetCore/TagHelpers/PanelTitleTagHelper.cs
index 457843f8..1593c4db 100644
--- a/src/GovUk.Frontend.AspNetCore/TagHelpers/PanelTitleTagHelper.cs
+++ b/src/GovUk.Frontend.AspNetCore/TagHelpers/PanelTitleTagHelper.cs
@@ -7,9 +7,11 @@ namespace GovUk.Frontend.AspNetCore.TagHelpers
/// Represents the title in a GDS panel component.
///
[HtmlTargetElement(TagName, ParentTag = PanelTagHelper.TagName)]
+ [HtmlTargetElement(ShortTagName, ParentTag = PanelTagHelper.TagName)]
public class PanelTitleTagHelper : TagHelper
{
internal const string TagName = "govuk-panel-title";
+ internal const string ShortTagName = "title";
///
public override async Task ProcessAsync(TagHelperContext context, TagHelperOutput output)
diff --git a/src/GovUk.Frontend.AspNetCore/TagHelpers/PhaseBannerTagTagHelper.cs b/src/GovUk.Frontend.AspNetCore/TagHelpers/PhaseBannerTagTagHelper.cs
index 4bbdc3d8..e049f6b9 100644
--- a/src/GovUk.Frontend.AspNetCore/TagHelpers/PhaseBannerTagTagHelper.cs
+++ b/src/GovUk.Frontend.AspNetCore/TagHelpers/PhaseBannerTagTagHelper.cs
@@ -8,10 +8,12 @@ namespace GovUk.Frontend.AspNetCore.TagHelpers
/// Represents the tag in a GDS phase banner component.
///
[HtmlTargetElement(TagName, ParentTag = PhaseBannerTagHelper.TagName)]
+ [HtmlTargetElement(ShortTagName, ParentTag = PhaseBannerTagHelper.TagName)]
[OutputElementHint(ComponentGenerator.TagElement)]
public class PhaseBannerTagTagHelper : TagHelper
{
internal const string TagName = "govuk-phase-banner-tag";
+ internal const string ShortTagName = "tag";
///
/// Creates a .
diff --git a/src/GovUk.Frontend.AspNetCore/TagHelpers/RadiosFieldsetLegendTagHelper.cs b/src/GovUk.Frontend.AspNetCore/TagHelpers/RadiosFieldsetLegendTagHelper.cs
index 48f7cdaa..e378526a 100644
--- a/src/GovUk.Frontend.AspNetCore/TagHelpers/RadiosFieldsetLegendTagHelper.cs
+++ b/src/GovUk.Frontend.AspNetCore/TagHelpers/RadiosFieldsetLegendTagHelper.cs
@@ -8,10 +8,14 @@ namespace GovUk.Frontend.AspNetCore.TagHelpers
/// Represents the legend in a GDS radios component fieldset.
///
[HtmlTargetElement(TagName, ParentTag = RadiosFieldsetTagHelper.TagName)]
+ [HtmlTargetElement(TagName, ParentTag = RadiosFieldsetTagHelper.ShortTagName)]
+ [HtmlTargetElement(ShortTagName, ParentTag = RadiosFieldsetTagHelper.TagName)]
+ [HtmlTargetElement(ShortTagName, ParentTag = RadiosFieldsetTagHelper.ShortTagName)]
[OutputElementHint(ComponentGenerator.FieldsetLegendElement)]
public class RadiosFieldsetLegendTagHelper : TagHelper
{
internal const string TagName = "govuk-radios-fieldset-legend";
+ internal const string ShortTagName = "legend";
private const string IsPageHeadingAttributeName = "is-page-heading";
diff --git a/src/GovUk.Frontend.AspNetCore/TagHelpers/RadiosFieldsetTagHelper.cs b/src/GovUk.Frontend.AspNetCore/TagHelpers/RadiosFieldsetTagHelper.cs
index 7d690896..60bb284c 100644
--- a/src/GovUk.Frontend.AspNetCore/TagHelpers/RadiosFieldsetTagHelper.cs
+++ b/src/GovUk.Frontend.AspNetCore/TagHelpers/RadiosFieldsetTagHelper.cs
@@ -8,11 +8,23 @@ namespace GovUk.Frontend.AspNetCore.TagHelpers
/// Represents the fieldset in a GDS radios component.
///
[HtmlTargetElement(TagName, ParentTag = RadiosTagHelper.TagName)]
- [RestrictChildren(RadiosFieldsetLegendTagHelper.TagName, RadiosItemTagHelper.TagName, RadiosItemDividerTagHelper.TagName, RadiosTagHelper.HintTagName, RadiosTagHelper.ErrorMessageTagName)]
+ [HtmlTargetElement(ShortTagName, ParentTag = RadiosTagHelper.TagName)]
+ [RestrictChildren(
+ RadiosFieldsetLegendTagHelper.TagName,
+ RadiosFieldsetLegendTagHelper.ShortTagName,
+ RadiosItemTagHelper.TagName,
+ RadiosItemTagHelper.ShortTagName,
+ RadiosItemDividerTagHelper.TagName,
+ RadiosItemDividerTagHelper.ShortTagName,
+ RadiosTagHelper.HintTagName,
+ FormGroupHintTagHelper.ShortTagName,
+ RadiosTagHelper.ErrorMessageTagName,
+ FormGroupErrorMessageTagHelper.ShortTagName)]
[OutputElementHint(ComponentGenerator.FieldsetElement)]
public class RadiosFieldsetTagHelper : TagHelper
{
internal const string TagName = "govuk-radios-fieldset";
+ internal const string ShortTagName = "radios-fieldset";
///
public override async Task ProcessAsync(TagHelperContext context, TagHelperOutput output)
diff --git a/src/GovUk.Frontend.AspNetCore/TagHelpers/RadiosItemConditionalTagHelper.cs b/src/GovUk.Frontend.AspNetCore/TagHelpers/RadiosItemConditionalTagHelper.cs
index 1f7b87bf..0cba85bf 100644
--- a/src/GovUk.Frontend.AspNetCore/TagHelpers/RadiosItemConditionalTagHelper.cs
+++ b/src/GovUk.Frontend.AspNetCore/TagHelpers/RadiosItemConditionalTagHelper.cs
@@ -7,9 +7,13 @@ namespace GovUk.Frontend.AspNetCore.TagHelpers
/// Represents the conditional reveal of a radios item in a GDS radios component.
///
[HtmlTargetElement(TagName, ParentTag = RadiosItemTagHelper.TagName)]
+ [HtmlTargetElement(TagName, ParentTag = RadiosItemTagHelper.ShortTagName)]
+ [HtmlTargetElement(ShortTagName, ParentTag = RadiosItemTagHelper.TagName)]
+ [HtmlTargetElement(ShortTagName, ParentTag = RadiosItemTagHelper.ShortTagName)]
public class RadiosItemConditionalTagHelper : TagHelper
{
internal const string TagName = "govuk-radios-item-conditional";
+ internal const string ShortTagName = "conditional";
///
public override async Task ProcessAsync(TagHelperContext context, TagHelperOutput output)
diff --git a/src/GovUk.Frontend.AspNetCore/TagHelpers/RadiosItemDividerTagHelper.cs b/src/GovUk.Frontend.AspNetCore/TagHelpers/RadiosItemDividerTagHelper.cs
index 7bd3e8e3..f043c6bd 100644
--- a/src/GovUk.Frontend.AspNetCore/TagHelpers/RadiosItemDividerTagHelper.cs
+++ b/src/GovUk.Frontend.AspNetCore/TagHelpers/RadiosItemDividerTagHelper.cs
@@ -9,10 +9,15 @@ namespace GovUk.Frontend.AspNetCore.TagHelpers
///
[HtmlTargetElement(TagName, ParentTag = RadiosTagHelper.TagName)]
[HtmlTargetElement(TagName, ParentTag = RadiosFieldsetTagHelper.TagName)]
+ [HtmlTargetElement(TagName, ParentTag = RadiosFieldsetTagHelper.ShortTagName)]
+ [HtmlTargetElement(ShortTagName, ParentTag = RadiosTagHelper.TagName)]
+ [HtmlTargetElement(ShortTagName, ParentTag = RadiosFieldsetTagHelper.TagName)]
+ [HtmlTargetElement(ShortTagName, ParentTag = RadiosFieldsetTagHelper.ShortTagName)]
[OutputElementHint(ComponentGenerator.RadiosDividerItemElement)]
public class RadiosItemDividerTagHelper : TagHelper
{
internal const string TagName = "govuk-radios-divider";
+ internal const string ShortTagName = "radios-divider";
///
public override async Task ProcessAsync(TagHelperContext context, TagHelperOutput output)
diff --git a/src/GovUk.Frontend.AspNetCore/TagHelpers/RadiosItemHintTagHelper.cs b/src/GovUk.Frontend.AspNetCore/TagHelpers/RadiosItemHintTagHelper.cs
index 1343b220..f42198f9 100644
--- a/src/GovUk.Frontend.AspNetCore/TagHelpers/RadiosItemHintTagHelper.cs
+++ b/src/GovUk.Frontend.AspNetCore/TagHelpers/RadiosItemHintTagHelper.cs
@@ -8,10 +8,14 @@ namespace GovUk.Frontend.AspNetCore.TagHelpers
/// Represents the hint of a radios item in a GDS radios component.
///
[HtmlTargetElement(TagName, ParentTag = RadiosItemTagHelper.TagName)]
+ [HtmlTargetElement(TagName, ParentTag = RadiosItemTagHelper.ShortTagName)]
+ [HtmlTargetElement(ShortTagName, ParentTag = RadiosItemTagHelper.TagName)]
+ [HtmlTargetElement(ShortTagName, ParentTag = RadiosItemTagHelper.ShortTagName)]
[OutputElementHint(ComponentGenerator.HintElement)]
public class RadiosItemHintTagHelper : TagHelper
{
internal const string TagName = "govuk-radios-item-hint";
+ internal const string ShortTagName = "hint";
///
public override async Task ProcessAsync(TagHelperContext context, TagHelperOutput output)
diff --git a/src/GovUk.Frontend.AspNetCore/TagHelpers/RadiosItemTagHelper.cs b/src/GovUk.Frontend.AspNetCore/TagHelpers/RadiosItemTagHelper.cs
index b8c1d1d8..773bb33e 100644
--- a/src/GovUk.Frontend.AspNetCore/TagHelpers/RadiosItemTagHelper.cs
+++ b/src/GovUk.Frontend.AspNetCore/TagHelpers/RadiosItemTagHelper.cs
@@ -11,10 +11,15 @@ namespace GovUk.Frontend.AspNetCore.TagHelpers
///
[HtmlTargetElement(TagName, ParentTag = RadiosTagHelper.TagName)]
[HtmlTargetElement(TagName, ParentTag = RadiosFieldsetTagHelper.TagName)]
+ [HtmlTargetElement(TagName, ParentTag = RadiosFieldsetTagHelper.ShortTagName)]
+ [HtmlTargetElement(ShortTagName, ParentTag = RadiosTagHelper.TagName)]
+ [HtmlTargetElement(ShortTagName, ParentTag = RadiosFieldsetTagHelper.TagName)]
+ [HtmlTargetElement(ShortTagName, ParentTag = RadiosFieldsetTagHelper.ShortTagName)]
[OutputElementHint(ComponentGenerator.RadiosItemElement)]
public class RadiosItemTagHelper : TagHelper
{
internal const string TagName = "govuk-radios-item";
+ internal const string ShortTagName = "radios-item";
private const string CheckedAttributeName = "checked";
private const string DisabledAttributeName = "disabled";
diff --git a/src/GovUk.Frontend.AspNetCore/TagHelpers/RadiosTagHelper.cs b/src/GovUk.Frontend.AspNetCore/TagHelpers/RadiosTagHelper.cs
index 62325913..3c022c00 100644
--- a/src/GovUk.Frontend.AspNetCore/TagHelpers/RadiosTagHelper.cs
+++ b/src/GovUk.Frontend.AspNetCore/TagHelpers/RadiosTagHelper.cs
@@ -1,7 +1,6 @@
using System.Collections.Generic;
using System.Diagnostics;
using System.Diagnostics.CodeAnalysis;
-using System.Threading.Tasks;
using GovUk.Frontend.AspNetCore.HtmlGeneration;
using Microsoft.AspNetCore.Html;
using Microsoft.AspNetCore.Mvc.Rendering;
@@ -13,7 +12,17 @@ namespace GovUk.Frontend.AspNetCore.TagHelpers
/// Generates a GDS checkboxes component.
///
[HtmlTargetElement(TagName)]
- [RestrictChildren(RadiosFieldsetTagHelper.TagName, RadiosItemTagHelper.TagName, RadiosItemDividerTagHelper.TagName, HintTagName, ErrorMessageTagName)]
+ [RestrictChildren(
+ RadiosFieldsetTagHelper.TagName,
+ RadiosFieldsetTagHelper.ShortTagName,
+ RadiosItemTagHelper.TagName,
+ RadiosItemTagHelper.ShortTagName,
+ RadiosItemDividerTagHelper.TagName,
+ RadiosItemDividerTagHelper.ShortTagName,
+ HintTagName,
+ FormGroupHintTagHelper.ShortTagName,
+ ErrorMessageTagName,
+ FormGroupErrorMessageTagHelper.ShortTagName)]
[OutputElementHint(ComponentGenerator.RadiosElement)]
public class RadiosTagHelper : FormGroupTagHelperBase
{
diff --git a/src/GovUk.Frontend.AspNetCore/TagHelpers/SelectItemTagHelper.cs b/src/GovUk.Frontend.AspNetCore/TagHelpers/SelectItemTagHelper.cs
index b6a46702..8443febf 100644
--- a/src/GovUk.Frontend.AspNetCore/TagHelpers/SelectItemTagHelper.cs
+++ b/src/GovUk.Frontend.AspNetCore/TagHelpers/SelectItemTagHelper.cs
@@ -11,9 +11,11 @@ namespace GovUk.Frontend.AspNetCore.TagHelpers
/// Represents an item in a GDS select component.
///
[HtmlTargetElement(TagName, ParentTag = SelectTagHelper.TagName)]
+ [HtmlTargetElement(ShortTagName, ParentTag = SelectTagHelper.TagName)]
public class SelectItemTagHelper : TagHelper
{
internal const string TagName = "govuk-select-item";
+ internal const string ShortTagName = "select-item";
private const string DisabledAttributeName = "disabled";
private const string SelectedAttributeName = "selected";
diff --git a/src/GovUk.Frontend.AspNetCore/TagHelpers/SelectTagHelper.cs b/src/GovUk.Frontend.AspNetCore/TagHelpers/SelectTagHelper.cs
index 95cbf530..ad67ac67 100644
--- a/src/GovUk.Frontend.AspNetCore/TagHelpers/SelectTagHelper.cs
+++ b/src/GovUk.Frontend.AspNetCore/TagHelpers/SelectTagHelper.cs
@@ -10,7 +10,15 @@ namespace GovUk.Frontend.AspNetCore.TagHelpers
/// Generates a GDS select component.
///
[HtmlTargetElement(TagName)]
- [RestrictChildren(SelectItemTagHelper.TagName, LabelTagName, HintTagName, ErrorMessageTagName)]
+ [RestrictChildren(
+ SelectItemTagHelper.TagName,
+ SelectItemTagHelper.ShortTagName,
+ LabelTagName,
+ FormGroupLabelTagHelper.ShortTagName,
+ HintTagName,
+ FormGroupHintTagHelper.ShortTagName,
+ ErrorMessageTagName,
+ FormGroupErrorMessageTagHelper.ShortTagName)]
[OutputElementHint(ComponentGenerator.FormGroupElement)]
public class SelectTagHelper : FormGroupTagHelperBase
{
diff --git a/src/GovUk.Frontend.AspNetCore/TagHelpers/SummaryListRowActionTagHelper.cs b/src/GovUk.Frontend.AspNetCore/TagHelpers/SummaryListRowActionTagHelper.cs
index 91b7e61f..040de82a 100644
--- a/src/GovUk.Frontend.AspNetCore/TagHelpers/SummaryListRowActionTagHelper.cs
+++ b/src/GovUk.Frontend.AspNetCore/TagHelpers/SummaryListRowActionTagHelper.cs
@@ -8,10 +8,14 @@ namespace GovUk.Frontend.AspNetCore.TagHelpers
/// Represents an action in a GDS summary list row.
///
[HtmlTargetElement(TagName, ParentTag = SummaryListRowActionsTagHelper.TagName)]
+ [HtmlTargetElement(TagName, ParentTag = SummaryListRowActionsTagHelper.ShortTagName)]
+ [HtmlTargetElement(ShortTagName, ParentTag = SummaryListRowActionsTagHelper.TagName)]
+ [HtmlTargetElement(ShortTagName, ParentTag = SummaryListRowActionsTagHelper.ShortTagName)]
[OutputElementHint(ComponentGenerator.SummaryListRowActionElement)]
public class SummaryListRowActionTagHelper : TagHelper
{
internal const string TagName = "govuk-summary-list-row-action";
+ internal const string ShortTagName = "action";
private const string VisuallyHiddenTextAttributeName = "visually-hidden-text";
diff --git a/src/GovUk.Frontend.AspNetCore/TagHelpers/SummaryListRowActionsTagHelper.cs b/src/GovUk.Frontend.AspNetCore/TagHelpers/SummaryListRowActionsTagHelper.cs
index 8b2ed044..cfa8b5ac 100644
--- a/src/GovUk.Frontend.AspNetCore/TagHelpers/SummaryListRowActionsTagHelper.cs
+++ b/src/GovUk.Frontend.AspNetCore/TagHelpers/SummaryListRowActionsTagHelper.cs
@@ -8,11 +8,15 @@ namespace GovUk.Frontend.AspNetCore.TagHelpers
/// Represents the actions wrapper in a GDS summary list component row.
///
[HtmlTargetElement(TagName, ParentTag = SummaryListRowTagHelper.TagName)]
- [RestrictChildren(SummaryListRowActionTagHelper.TagName)]
+ [HtmlTargetElement(TagName, ParentTag = SummaryListRowTagHelper.ShortTagName)]
+ [HtmlTargetElement(ShortTagName, ParentTag = SummaryListRowTagHelper.TagName)]
+ [HtmlTargetElement(ShortTagName, ParentTag = SummaryListRowTagHelper.ShortTagName)]
+ [RestrictChildren(SummaryListRowActionTagHelper.TagName, SummaryListRowActionTagHelper.ShortTagName)]
[OutputElementHint(ComponentGenerator.SummaryListRowActionsElement)]
public class SummaryListRowActionsTagHelper : TagHelper
{
internal const string TagName = "govuk-summary-list-row-actions";
+ internal const string ShortTagName = "actions";
///
/// Creates a new .
diff --git a/src/GovUk.Frontend.AspNetCore/TagHelpers/SummaryListRowKeyTagHelper.cs b/src/GovUk.Frontend.AspNetCore/TagHelpers/SummaryListRowKeyTagHelper.cs
index 0b43915d..dc107985 100644
--- a/src/GovUk.Frontend.AspNetCore/TagHelpers/SummaryListRowKeyTagHelper.cs
+++ b/src/GovUk.Frontend.AspNetCore/TagHelpers/SummaryListRowKeyTagHelper.cs
@@ -8,10 +8,14 @@ namespace GovUk.Frontend.AspNetCore.TagHelpers
/// Represents the value in a GDS summary list component row.
///
[HtmlTargetElement(TagName, ParentTag = SummaryListRowTagHelper.TagName)]
+ [HtmlTargetElement(TagName, ParentTag = SummaryListRowTagHelper.ShortTagName)]
+ [HtmlTargetElement(ShortTagName, ParentTag = SummaryListRowTagHelper.TagName)]
+ [HtmlTargetElement(ShortTagName, ParentTag = SummaryListRowTagHelper.ShortTagName)]
[OutputElementHint(ComponentGenerator.SummaryListRowKeyElement)]
public class SummaryListRowKeyTagHelper : TagHelper
{
internal const string TagName = "govuk-summary-list-row-key";
+ internal const string ShortTagName = "key";
///
public override async Task ProcessAsync(TagHelperContext context, TagHelperOutput output)
diff --git a/src/GovUk.Frontend.AspNetCore/TagHelpers/SummaryListRowTagHelper.cs b/src/GovUk.Frontend.AspNetCore/TagHelpers/SummaryListRowTagHelper.cs
index 424f601b..ded0ee18 100644
--- a/src/GovUk.Frontend.AspNetCore/TagHelpers/SummaryListRowTagHelper.cs
+++ b/src/GovUk.Frontend.AspNetCore/TagHelpers/SummaryListRowTagHelper.cs
@@ -8,11 +8,19 @@ namespace GovUk.Frontend.AspNetCore.TagHelpers
/// Represents a row in a GDS summary list component.
///
[HtmlTargetElement(TagName, ParentTag = SummaryListTagHelper.TagName)]
- [RestrictChildren(SummaryListRowKeyTagHelper.TagName, SummaryListRowValueTagHelper.TagName, SummaryListRowActionsTagHelper.TagName)]
+ [HtmlTargetElement(ShortTagName, ParentTag = SummaryListTagHelper.TagName)]
+ [RestrictChildren(
+ SummaryListRowKeyTagHelper.TagName,
+ SummaryListRowKeyTagHelper.ShortTagName,
+ SummaryListRowValueTagHelper.TagName,
+ SummaryListRowValueTagHelper.ShortTagName,
+ SummaryListRowActionsTagHelper.TagName,
+ SummaryListRowActionsTagHelper.ShortTagName)]
[OutputElementHint(ComponentGenerator.SummaryListRowElement)]
public class SummaryListRowTagHelper : TagHelper
{
internal const string TagName = "govuk-summary-list-row";
+ internal const string ShortTagName = "summary-list-row";
///
public override async Task ProcessAsync(TagHelperContext context, TagHelperOutput output)
diff --git a/src/GovUk.Frontend.AspNetCore/TagHelpers/SummaryListRowValueTagHelper.cs b/src/GovUk.Frontend.AspNetCore/TagHelpers/SummaryListRowValueTagHelper.cs
index 6db1ffc7..f298be4f 100644
--- a/src/GovUk.Frontend.AspNetCore/TagHelpers/SummaryListRowValueTagHelper.cs
+++ b/src/GovUk.Frontend.AspNetCore/TagHelpers/SummaryListRowValueTagHelper.cs
@@ -8,10 +8,14 @@ namespace GovUk.Frontend.AspNetCore.TagHelpers
/// Represents the value in a GDS summary list component row.
///
[HtmlTargetElement(TagName, ParentTag = SummaryListRowTagHelper.TagName)]
+ [HtmlTargetElement(TagName, ParentTag = SummaryListRowTagHelper.ShortTagName)]
+ [HtmlTargetElement(ShortTagName, ParentTag = SummaryListRowTagHelper.TagName)]
+ [HtmlTargetElement(ShortTagName, ParentTag = SummaryListRowTagHelper.ShortTagName)]
[OutputElementHint(ComponentGenerator.SummaryListRowValueElement)]
public class SummaryListRowValueTagHelper : TagHelper
{
internal const string TagName = "govuk-summary-list-row-value";
+ internal const string ShortTagName = "value";
///
public override async Task ProcessAsync(TagHelperContext context, TagHelperOutput output)
diff --git a/src/GovUk.Frontend.AspNetCore/TagHelpers/SummaryListTagHelper.cs b/src/GovUk.Frontend.AspNetCore/TagHelpers/SummaryListTagHelper.cs
index c729201c..d0cbe1c2 100644
--- a/src/GovUk.Frontend.AspNetCore/TagHelpers/SummaryListTagHelper.cs
+++ b/src/GovUk.Frontend.AspNetCore/TagHelpers/SummaryListTagHelper.cs
@@ -9,7 +9,7 @@ namespace GovUk.Frontend.AspNetCore.TagHelpers
/// Generates a GDS summary list component.
///
[HtmlTargetElement(TagName)]
- [RestrictChildren(SummaryListRowTagHelper.TagName)]
+ [RestrictChildren(SummaryListRowTagHelper.TagName, SummaryListRowTagHelper.ShortTagName)]
[OutputElementHint(ComponentGenerator.SummaryListElement)]
public class SummaryListTagHelper : TagHelper
{
diff --git a/src/GovUk.Frontend.AspNetCore/TagHelpers/TabsTagHelper.cs b/src/GovUk.Frontend.AspNetCore/TagHelpers/TabsTagHelper.cs
index 77cc68ee..a4d8e0f1 100644
--- a/src/GovUk.Frontend.AspNetCore/TagHelpers/TabsTagHelper.cs
+++ b/src/GovUk.Frontend.AspNetCore/TagHelpers/TabsTagHelper.cs
@@ -10,7 +10,7 @@
namespace GovUk.Frontend.AspNetCore.TagHelpers
{
[HtmlTargetElement("govuk-tabs", TagStructure = TagStructure.NormalOrSelfClosing)]
- [RestrictChildren("govuk-tabs-item")]
+ [RestrictChildren("govuk-tabs-item", "item")]
public class TabsTagHelper : TagHelper
{
internal const string IdPrefixAttributeName = "id-prefix";
@@ -59,6 +59,7 @@ public override async Task ProcessAsync(TagHelperContext context, TagHelperOutpu
}
[HtmlTargetElement("govuk-tabs-item", ParentTag = "govuk-tabs", TagStructure = TagStructure.NormalOrSelfClosing)]
+ [HtmlTargetElement("item", ParentTag = "govuk-tabs", TagStructure = TagStructure.NormalOrSelfClosing)]
public class TabsItemTagHelper : TagHelper
{
private const string IdAttributeName = "id";
diff --git a/src/GovUk.Frontend.AspNetCore/TagHelpers/TextAreaTagHelper.cs b/src/GovUk.Frontend.AspNetCore/TagHelpers/TextAreaTagHelper.cs
index d2476cc6..6814ec46 100644
--- a/src/GovUk.Frontend.AspNetCore/TagHelpers/TextAreaTagHelper.cs
+++ b/src/GovUk.Frontend.AspNetCore/TagHelpers/TextAreaTagHelper.cs
@@ -10,7 +10,15 @@ namespace GovUk.Frontend.AspNetCore.TagHelpers
/// Generates a GDS textarea component.
///
[HtmlTargetElement(TagName)]
- [RestrictChildren(LabelTagName, HintTagName, ErrorMessageTagName, TextAreaValueTagHelper.TagName)]
+ [RestrictChildren(
+ LabelTagName,
+ FormGroupLabelTagHelper.ShortTagName,
+ HintTagName,
+ FormGroupHintTagHelper.ShortTagName,
+ ErrorMessageTagName,
+ FormGroupErrorMessageTagHelper.ShortTagName,
+ TextAreaValueTagHelper.TagName,
+ TextAreaValueTagHelper.ShortTagName)]
[OutputElementHint(ComponentGenerator.FormGroupElement)]
public class TextAreaTagHelper : FormGroupTagHelperBase
{
diff --git a/src/GovUk.Frontend.AspNetCore/TagHelpers/TextAreaValueTagHelper.cs b/src/GovUk.Frontend.AspNetCore/TagHelpers/TextAreaValueTagHelper.cs
index 1804a8c3..f5c621c4 100644
--- a/src/GovUk.Frontend.AspNetCore/TagHelpers/TextAreaValueTagHelper.cs
+++ b/src/GovUk.Frontend.AspNetCore/TagHelpers/TextAreaValueTagHelper.cs
@@ -7,9 +7,11 @@ namespace GovUk.Frontend.AspNetCore.TagHelpers
/// Represents the value of a GDS character count component.
///
[HtmlTargetElement(TagName, ParentTag = TextAreaTagHelper.TagName)]
+ [HtmlTargetElement(ShortTagName, ParentTag = TextAreaTagHelper.TagName)]
public class TextAreaValueTagHelper : TagHelper
{
internal const string TagName = "govuk-textarea-value";
+ internal const string ShortTagName = "value";
///
public override async Task ProcessAsync(TagHelperContext context, TagHelperOutput output)
diff --git a/src/GovUk.Frontend.AspNetCore/TagHelpers/TextInputPrefixTagHelper.cs b/src/GovUk.Frontend.AspNetCore/TagHelpers/TextInputPrefixTagHelper.cs
index 2f323a11..0098991d 100644
--- a/src/GovUk.Frontend.AspNetCore/TagHelpers/TextInputPrefixTagHelper.cs
+++ b/src/GovUk.Frontend.AspNetCore/TagHelpers/TextInputPrefixTagHelper.cs
@@ -8,10 +8,12 @@ namespace GovUk.Frontend.AspNetCore.TagHelpers
/// Represents the prefix element in a GDS input component.
///
[HtmlTargetElement(TagName, ParentTag = TextInputTagHelper.TagName)]
+ [HtmlTargetElement(ShortTagName, ParentTag = TextInputTagHelper.TagName)]
[OutputElementHint(ComponentGenerator.InputPrefixElement)]
public class TextInputPrefixTagHelper : TagHelper
{
internal const string TagName = "govuk-input-prefix";
+ internal const string ShortTagName = "prefix";
///
/// Creates an .
diff --git a/src/GovUk.Frontend.AspNetCore/TagHelpers/TextInputSuffixTagHelper.cs b/src/GovUk.Frontend.AspNetCore/TagHelpers/TextInputSuffixTagHelper.cs
index 58046ea8..681a0338 100644
--- a/src/GovUk.Frontend.AspNetCore/TagHelpers/TextInputSuffixTagHelper.cs
+++ b/src/GovUk.Frontend.AspNetCore/TagHelpers/TextInputSuffixTagHelper.cs
@@ -8,10 +8,12 @@ namespace GovUk.Frontend.AspNetCore.TagHelpers
/// Represents the prefix suffix in a GDS input component.
///
[HtmlTargetElement(TagName, ParentTag = TextInputTagHelper.TagName)]
+ [HtmlTargetElement(ShortTagName, ParentTag = TextInputTagHelper.TagName)]
[OutputElementHint(ComponentGenerator.InputSuffixElement)]
public class TextInputSuffixTagHelper : TagHelper
{
internal const string TagName = "govuk-input-suffix";
+ internal const string ShortTagName = "suffix";
///
/// Creates an .
diff --git a/src/GovUk.Frontend.AspNetCore/TagHelpers/TextInputTagHelper.cs b/src/GovUk.Frontend.AspNetCore/TagHelpers/TextInputTagHelper.cs
index be6c86ee..e9f16a68 100644
--- a/src/GovUk.Frontend.AspNetCore/TagHelpers/TextInputTagHelper.cs
+++ b/src/GovUk.Frontend.AspNetCore/TagHelpers/TextInputTagHelper.cs
@@ -11,7 +11,17 @@ namespace GovUk.Frontend.AspNetCore.TagHelpers
/// Generates a GDS input component.
///
[HtmlTargetElement(TagName)]
- [RestrictChildren(LabelTagName, HintTagName, ErrorMessageTagName, TextInputPrefixTagHelper.TagName, TextInputSuffixTagHelper.TagName)]
+ [RestrictChildren(
+ LabelTagName,
+ FormGroupLabelTagHelper.ShortTagName,
+ HintTagName,
+ FormGroupHintTagHelper.ShortTagName,
+ ErrorMessageTagName,
+ FormGroupErrorMessageTagHelper.ShortTagName,
+ TextInputPrefixTagHelper.TagName,
+ TextInputPrefixTagHelper.ShortTagName,
+ TextInputSuffixTagHelper.TagName,
+ TextInputSuffixTagHelper.ShortTagName)]
[OutputElementHint(ComponentGenerator.FormGroupElement)]
public class TextInputTagHelper : FormGroupTagHelperBase
{