Skip to content

Commit

Permalink
update example id to remove all duplicates (#2776)
Browse files Browse the repository at this point in the history
  • Loading branch information
precious-onyenaucheya-ons authored Aug 14, 2023
1 parent 6f3fed4 commit b4bdeaa
Show file tree
Hide file tree
Showing 87 changed files with 403 additions and 403 deletions.
2 changes: 1 addition & 1 deletion src/components/access-code/example-access-code-error.njk
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ layout: ~
{% endset %}

{% call onsDetails({
"id": "details",
"id": "details-access-code-error",
"title": "Need to answer separately from your household?",
"button": {
"close": "Hide this",
Expand Down
2 changes: 1 addition & 1 deletion src/components/access-code/example-access-code.njk
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ layout: ~
<h1 class="ons-u-mt-l">Start study</h1>

{{ onsAccessCode({
"id": "access-code",
"id": "access-code-example",
"name": "access-code",
"postTextboxLinkText": "Where to find your access code",
"postTextboxLinkUrl": "#0",
Expand Down
20 changes: 10 additions & 10 deletions src/components/accordion/example-accordion-open.njk
Original file line number Diff line number Diff line change
Expand Up @@ -13,14 +13,14 @@
"name": "dietary",
"checkboxes": [
{
"id": "data",
"id": "data-checkbox",
"label": {
"text": "Data (309)"
},
"value": "data"
},
{
"id": "publications",
"id": "publications-checkbox",
"label": {
"text": "Publications (137)"
},
Expand All @@ -33,21 +33,21 @@
"name": "name",
"checkboxes": [
{
"id": "datasets",
"id": "datasets-checkbox",
"label": {
"text": "Datasets (100)"
},
"value": "datasets"
},
{
"id": "timeseries",
"id": "timeseries-checkbox",
"label": {
"text": "Timeseries (20)"
},
"value": "timeseries"
},
{
"id": "requested",
"id": "requested-checkbox",
"label": {
"text": "User requested data (16)"
},
Expand All @@ -57,7 +57,7 @@
}
},
{
"id": "areas",
"id": "areas-checkbox",
"label": {
"text": "Areas (0)"
},
Expand All @@ -78,22 +78,22 @@
"name": "dietary",
"checkboxes": [
{
"id": "crime",
"id": "crime-checkbox",
"label": {
"text": "Crime (200)"
},
"value": "crime",
"checked": true
},
{
"id": "education",
"id": "education-checkbox",
"label": {
"text": "Education (55)"
},
"value": "education"
"value": "education-checkbox"
},
{
"id": "disability",
"id": "disability-checkbox",
"label": {
"text": "Disability (67)"
},
Expand Down
2 changes: 1 addition & 1 deletion src/components/accordion/example-accordion.njk
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

{{
onsAccordion({
"id": "accordion",
"id": "accordion-example",
"allButton": {
"open": "Show all",
"close": "Hide all"
Expand Down
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
{% from "components/address-input/_macro.njk" import onsAddressInput %}

{{ onsAddressInput({
"id": "address",
"id": "address-input-editable",
"dontWrap": true,
"label": {
"text": "Enter address or postcode and select from results",
"id": "address-label"
"id": "address-label-input-editable"
},
"isEditable": true,
"mandatory": true,
Expand Down
6 changes: 3 additions & 3 deletions src/components/address-input/example-address-input-manual.njk
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
{% from "components/address-input/_macro.njk" import onsAddressInput %}

{{ onsAddressInput({
"id": "address",
"id": "address-input-manual",
"dontWrap": true,
"manualEntry": true,
"label": {
"text": "Enter address or postcode and select from results",
"id": "address-label"
"id": "address-label-input-manual"
},
"line1": {
"label": "Address line 1"
Expand All @@ -20,4 +20,4 @@
"postcode": {
"label": "Postcode"
}
}) }}
}) }}
4 changes: 2 additions & 2 deletions src/components/address-input/example-address-input.njk
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
{% from "components/address-input/_macro.njk" import onsAddressInput %}

{{ onsAddressInput({
"id": "address",
"id": "address-input",
"dontWrap": true,
"label": {
"text": "Enter address or postcode and select from results",
"id": "address-label"
"id": "address-label-input"
},
"isEditable": false,
"mandatory": true,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,10 +4,10 @@
<div class="ons-grid__col ons-col-8@m">

{{ onsAutosuggest({
"id": "country-of-birth",
"id": "country-of-birth-autosuggest-multiple",
"label": {
"text": "Passport",
"id": "country-of-birth-label",
"id": "country-of-birth-label-multiple",
"description": "Enter your own answer or select from suggestions. You can enter multiple countries if you have a passport for more than one."
},
"autocomplete": "off",
Expand Down
2 changes: 1 addition & 1 deletion src/components/autosuggest/example-autosuggest-country.njk
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
<div class="ons-grid__col ons-col-8@m">

{{ onsAutosuggest({
"id": "country-of-birth",
"id": "country-of-birth-autosuggest",
"label": {
"text": "Current name of country",
"description": "Enter your own answer or select from suggestions",
Expand Down
2 changes: 1 addition & 1 deletion src/components/back-link/example-back-link.njk
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
"itemsList": [
{
"url": '/',
"id": "back",
"id": "backlink",
"text": 'Back',
"attributes": {
"data-attribute": "Example attribute"
Expand Down
6 changes: 3 additions & 3 deletions src/components/card/example-card-set-with-images.njk
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@

<div class="ons-grid__col ons-col-4@m">
{{ onsCard({
"id": 'title1',
"id": 'card-with-image-1',
"textId": 'text1',
"title": 'About the census',
"url": '#0',
Expand All @@ -16,7 +16,7 @@

<div class="ons-grid__col ons-col-4@m">
{{ onsCard({
"id": 'title2',
"id": 'card-with-image-2',
"textId": 'text2',
"title": 'Working on the census',
"url": '#0',
Expand All @@ -27,7 +27,7 @@

<div class="ons-grid__col ons-col-4@m">
{{ onsCard({
"id": 'title3',
"id": 'card-with-image-3',
"textId": 'text3',
"title": 'Your data and security',
"url": '#0',
Expand Down
6 changes: 3 additions & 3 deletions src/components/card/example-card-set-with-lists.njk
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@

<div class="ons-grid__col ons-col-4@m">
{{ onsCard({
"id": 'title1',
"id": 'card-with-list-1',
"textId": 'text1',
"title": 'About the census',
"url": '#0',
Expand All @@ -25,7 +25,7 @@

<div class="ons-grid__col ons-col-4@m">
{{ onsCard({
"id": 'title2',
"id": 'card-with-list-2',
"textId": 'text2',
"title": 'Working on the census',
"url": '#0',
Expand All @@ -45,7 +45,7 @@

<div class="ons-grid__col ons-col-4@m">
{{ onsCard({
"id": 'title3',
"id": 'card-with-list-3',
"textId": 'text3',
"title": 'Your data and security',
"url": '#0',
Expand Down
6 changes: 3 additions & 3 deletions src/components/card/example-card-set.njk
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@

<div class="ons-grid__col ons-col-4@m">
{{ onsCard({
"id": 'title1',
"id": 'card-set-1',
"textId": 'text1',
"title": 'About the census',
"url": '#0',
Expand All @@ -15,7 +15,7 @@

<div class="ons-grid__col ons-col-4@m">
{{ onsCard({
"id": 'title2',
"id": 'card-set-2',
"textId": 'text2',
"title": 'Working on the census',
"url": '#0',
Expand All @@ -25,7 +25,7 @@

<div class="ons-grid__col ons-col-4@m">
{{ onsCard({
"id": 'title3',
"id": 'card-set-3',
"textId": 'text3',
"title": 'Your data and security',
"url": '#0',
Expand Down
2 changes: 1 addition & 1 deletion src/components/card/example-card.njk
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{% from "components/card/_macro.njk" import onsCard %}

{{ onsCard({
"id": 'title',
"id": 'card-example',
"textId": 'text',
"title": 'Your data and security',
"url": '#0',
Expand Down
6 changes: 3 additions & 3 deletions src/components/checkboxes/example-checkboxes-disabled.njk
Original file line number Diff line number Diff line change
Expand Up @@ -8,21 +8,21 @@
"name": "dietary",
"checkboxes": [
{
"id": "data",
"id": "data-checkbox-disabled",
"label": {
"text": "Data (309)"
},
"value": "data"
},
{
"id": "publications",
"id": "publications-checkbox-disabled",
"label": {
"text": "Publications (137)"
},
"value": "publications"
},
{
"id": "areas",
"id": "areas-checkbox-disabled",
"label": {
"text": "Areas (0)"
},
Expand Down
14 changes: 7 additions & 7 deletions src/components/checkboxes/example-checkboxes-error.njk
Original file line number Diff line number Diff line change
Expand Up @@ -8,42 +8,42 @@
"dontWrap": true,
"checkboxes": [
{
"id": "gluten-free",
"id": "gluten-free-checkbox-error",
"label": {
"text": "Gluten free"
},
"value": "gluten-free"
},
{
"id": "lactose-intolerant",
"id": "lactose-intolerant-checkbox-error",
"label": {
"text": "Lactose intolerant"
},
"value": "lactose-intolerant"
},
{
"id": "vegan",
"id": "vegan-checkbox-error",
"label": {
"text": "Vegan"
},
"value": "vegan"
},
{
"id": "vegetarian",
"id": "vegetarian-checkbox-error",
"label": {
"text": "Vegetarian"
},
"value": "vegetarian"
},
{
"id": "other-checkbox",
"id": "other-checkbox-error",
"label": {
"text": "Other"
},
"checked": true,
"value": "other",
"other": {
"id": "other-textbox",
"id": "other-textbox-checbox-error",
"name": "other-answer",
"label": {
"text": "Enter dietary requirements"
Expand All @@ -53,7 +53,7 @@
],
"error": {
"classes": "test",
"id": "dietary-error",
"id": "dietary-error-checkbox",
"text": "Enter your dietary requirements"
}
})
Expand Down
Loading

0 comments on commit b4bdeaa

Please sign in to comment.