{
  "name": "Character count",
  "component": "character-count",
  "fixtures": [
    {
      "name": "default",
      "context": {
        "label": {
          "text": "Can you provide more detail?",
          "size": "l",
          "isPageHeading": true
        },
        "hint": {
          "text": "Do not include personal information like your name, date of birth or NHS number"
        },
        "name": "example",
        "maxlength": 200
      },
      "screenshot": {
        "states": [
          "focus"
        ],
        "selector": ".nhsuk-textarea"
      },
      "options": {},
      "html": "<div class=\"nhsuk-form-group nhsuk-character-count\" data-module=\"nhsuk-character-count\" data-maxlength=\"200\">\n  <h1 class=\"nhsuk-label-wrapper\">\n    <label class=\"nhsuk-label nhsuk-label--l\" for=\"example\">\n      Can you provide more detail?\n    </label>\n  </h1>\n  <div class=\"nhsuk-hint\" id=\"example-hint\">\n    Do not include personal information like your name, date of birth or NHS number\n  </div>\n  <textarea class=\"nhsuk-textarea nhsuk-js-character-count\" id=\"example\" name=\"example\" rows=\"5\" aria-describedby=\"example-info example-hint\"></textarea>\n  <div class=\"nhsuk-hint nhsuk-character-count__message\" id=\"example-info\">\n    You can enter up to 200 characters\n  </div>\n</div>"
    },
    {
      "name": "disabled",
      "context": {
        "label": {
          "text": "Can you provide more detail?",
          "size": "l",
          "isPageHeading": true
        },
        "hint": {
          "text": "Do not include personal information like your name, date of birth or NHS number"
        },
        "name": "example",
        "maxlength": 200,
        "disabled": true
      },
      "screenshot": true,
      "options": {},
      "html": "<div class=\"nhsuk-form-group nhsuk-character-count\" data-module=\"nhsuk-character-count\" data-maxlength=\"200\">\n  <h1 class=\"nhsuk-label-wrapper\">\n    <label class=\"nhsuk-label nhsuk-label--l\" for=\"example\">\n      Can you provide more detail?\n    </label>\n  </h1>\n  <div class=\"nhsuk-hint\" id=\"example-hint\">\n    Do not include personal information like your name, date of birth or NHS number\n  </div>\n  <textarea class=\"nhsuk-textarea nhsuk-js-character-count\" id=\"example\" name=\"example\" rows=\"5\" disabled aria-describedby=\"example-info example-hint\"></textarea>\n  <div class=\"nhsuk-hint nhsuk-character-count__message\" id=\"example-info\">\n    You can enter up to 200 characters\n  </div>\n</div>"
    },
    {
      "name": "label",
      "description": "with size S",
      "context": {
        "label": {
          "text": "Can you provide more detail?",
          "size": "s",
          "isPageHeading": true
        },
        "id": "custom-size",
        "name": "example",
        "maxlength": 200
      },
      "screenshot": false,
      "options": {},
      "html": "<div class=\"nhsuk-form-group nhsuk-character-count\" data-module=\"nhsuk-character-count\" data-maxlength=\"200\">\n  <h1 class=\"nhsuk-label-wrapper\">\n    <label class=\"nhsuk-label nhsuk-label--s\" for=\"custom-size\">\n      Can you provide more detail?\n    </label>\n  </h1>\n  <textarea class=\"nhsuk-textarea nhsuk-js-character-count\" id=\"custom-size\" name=\"example\" rows=\"5\" aria-describedby=\"custom-size-info\"></textarea>\n  <div class=\"nhsuk-hint nhsuk-character-count__message\" id=\"custom-size-info\">\n    You can enter up to 200 characters\n  </div>\n</div>"
    },
    {
      "name": "label",
      "description": "with size M",
      "context": {
        "label": {
          "text": "Can you provide more detail?",
          "size": "m",
          "isPageHeading": true
        },
        "id": "custom-size",
        "name": "example",
        "maxlength": 200
      },
      "screenshot": false,
      "options": {},
      "html": "<div class=\"nhsuk-form-group nhsuk-character-count\" data-module=\"nhsuk-character-count\" data-maxlength=\"200\">\n  <h1 class=\"nhsuk-label-wrapper\">\n    <label class=\"nhsuk-label nhsuk-label--m\" for=\"custom-size\">\n      Can you provide more detail?\n    </label>\n  </h1>\n  <textarea class=\"nhsuk-textarea nhsuk-js-character-count\" id=\"custom-size\" name=\"example\" rows=\"5\" aria-describedby=\"custom-size-info\"></textarea>\n  <div class=\"nhsuk-hint nhsuk-character-count__message\" id=\"custom-size-info\">\n    You can enter up to 200 characters\n  </div>\n</div>"
    },
    {
      "name": "label",
      "description": "with size L",
      "context": {
        "label": {
          "text": "Can you provide more detail?",
          "size": "l",
          "isPageHeading": true
        },
        "id": "custom-size",
        "name": "example",
        "maxlength": 200
      },
      "screenshot": false,
      "options": {},
      "html": "<div class=\"nhsuk-form-group nhsuk-character-count\" data-module=\"nhsuk-character-count\" data-maxlength=\"200\">\n  <h1 class=\"nhsuk-label-wrapper\">\n    <label class=\"nhsuk-label nhsuk-label--l\" for=\"custom-size\">\n      Can you provide more detail?\n    </label>\n  </h1>\n  <textarea class=\"nhsuk-textarea nhsuk-js-character-count\" id=\"custom-size\" name=\"example\" rows=\"5\" aria-describedby=\"custom-size-info\"></textarea>\n  <div class=\"nhsuk-hint nhsuk-character-count__message\" id=\"custom-size-info\">\n    You can enter up to 200 characters\n  </div>\n</div>"
    },
    {
      "name": "label",
      "description": "with size XL",
      "context": {
        "label": {
          "text": "Can you provide more detail?",
          "size": "xl",
          "isPageHeading": true
        },
        "id": "custom-size",
        "name": "example",
        "maxlength": 200
      },
      "screenshot": false,
      "options": {},
      "html": "<div class=\"nhsuk-form-group nhsuk-character-count\" data-module=\"nhsuk-character-count\" data-maxlength=\"200\">\n  <h1 class=\"nhsuk-label-wrapper\">\n    <label class=\"nhsuk-label nhsuk-label--xl\" for=\"custom-size\">\n      Can you provide more detail?\n    </label>\n  </h1>\n  <textarea class=\"nhsuk-textarea nhsuk-js-character-count\" id=\"custom-size\" name=\"example\" rows=\"5\" aria-describedby=\"custom-size-info\"></textarea>\n  <div class=\"nhsuk-hint nhsuk-character-count__message\" id=\"custom-size-info\">\n    You can enter up to 200 characters\n  </div>\n</div>"
    },
    {
      "name": "to configure in JavaScript",
      "context": {
        "label": {
          "text": "Can you provide more detail?",
          "size": "l",
          "isPageHeading": true
        },
        "id": "to-configure-in-javascript",
        "name": "example"
      },
      "screenshot": false,
      "options": {
        "hidden": true,
        "throwOnError": false
      },
      "html": "<div class=\"nhsuk-form-group nhsuk-character-count\" data-module=\"nhsuk-character-count\">\n  <h1 class=\"nhsuk-label-wrapper\">\n    <label class=\"nhsuk-label nhsuk-label--l\" for=\"to-configure-in-javascript\">\n      Can you provide more detail?\n    </label>\n  </h1>\n  <textarea class=\"nhsuk-textarea nhsuk-js-character-count\" id=\"to-configure-in-javascript\" name=\"example\" rows=\"5\" aria-describedby=\"to-configure-in-javascript-info\"></textarea>\n  <div class=\"nhsuk-hint nhsuk-character-count__message\" id=\"to-configure-in-javascript-info\" hidden>\n    \n  </div>\n</div>"
    },
    {
      "name": "with count type 'characters'",
      "context": {
        "label": {
          "text": "Enter a job description",
          "size": "l",
          "isPageHeading": true
        },
        "id": "with-characters-count-type",
        "name": "example",
        "countType": "characters",
        "maxlength": 200
      },
      "screenshot": false,
      "options": {},
      "html": "<div class=\"nhsuk-form-group nhsuk-character-count\" data-module=\"nhsuk-character-count\" data-maxlength=\"200\" data-count-type=\"characters\">\n  <h1 class=\"nhsuk-label-wrapper\">\n    <label class=\"nhsuk-label nhsuk-label--l\" for=\"with-characters-count-type\">\n      Enter a job description\n    </label>\n  </h1>\n  <textarea class=\"nhsuk-textarea nhsuk-js-character-count\" id=\"with-characters-count-type\" name=\"example\" rows=\"5\" aria-describedby=\"with-characters-count-type-info\"></textarea>\n  <div class=\"nhsuk-hint nhsuk-character-count__message\" id=\"with-characters-count-type-info\">\n    You can enter up to 200 characters\n  </div>\n</div>"
    },
    {
      "name": "with count type 'characters' and error message",
      "context": {
        "label": {
          "text": "Enter a job description",
          "size": "l",
          "isPageHeading": true
        },
        "errorMessage": {
          "text": "Job description must be 200 characters or less"
        },
        "id": "with-characters-count-type-error-message",
        "name": "example",
        "countType": "characters",
        "maxlength": 350,
        "value": "👩🏻‍🚀 A content designer works on the end-to-end journey of a service to help users complete their goal and government deliver a policy intent. Their work may involve the creation of, or change to, a transaction, product or single piece of content that stretches across digital and offline channels. They make sure appropriate content is shown to a user in the right place and in the best format."
      },
      "screenshot": false,
      "options": {},
      "html": "<div class=\"nhsuk-form-group nhsuk-form-group--error nhsuk-character-count\" data-module=\"nhsuk-character-count\" data-maxlength=\"350\" data-count-type=\"characters\">\n  <h1 class=\"nhsuk-label-wrapper\">\n    <label class=\"nhsuk-label nhsuk-label--l\" for=\"with-characters-count-type-error-message\">\n      Enter a job description\n    </label>\n  </h1>\n  <span class=\"nhsuk-error-message\" id=\"with-characters-count-type-error-message-error\">\n    <span class=\"nhsuk-u-visually-hidden\">Error:</span> Job description must be 200 characters or less\n  </span>\n  <textarea class=\"nhsuk-textarea nhsuk-textarea--error nhsuk-js-character-count\" id=\"with-characters-count-type-error-message\" name=\"example\" rows=\"5\" aria-describedby=\"with-characters-count-type-error-message-info with-characters-count-type-error-message-error\">👩🏻‍🚀 A content designer works on the end-to-end journey of a service to help users complete their goal and government deliver a policy intent. Their work may involve the creation of, or change to, a transaction, product or single piece of content that stretches across digital and offline channels. They make sure appropriate content is shown to a user in the right place and in the best format.</textarea>\n  <div class=\"nhsuk-hint nhsuk-character-count__message\" id=\"with-characters-count-type-error-message-info\">\n    You can enter up to 350 characters\n  </div>\n</div>"
    },
    {
      "name": "with count type 'characters' and threshold",
      "context": {
        "label": {
          "text": "Enter a job description",
          "size": "l",
          "isPageHeading": true
        },
        "id": "with-characters-count-type-threshold",
        "name": "example",
        "countType": "characters",
        "value": "Type another letter into this field after this message to see the threshold feature",
        "maxlength": 112,
        "threshold": 75
      },
      "screenshot": false,
      "options": {},
      "html": "<div class=\"nhsuk-form-group nhsuk-character-count\" data-module=\"nhsuk-character-count\" data-maxlength=\"112\" data-threshold=\"75\" data-count-type=\"characters\">\n  <h1 class=\"nhsuk-label-wrapper\">\n    <label class=\"nhsuk-label nhsuk-label--l\" for=\"with-characters-count-type-threshold\">\n      Enter a job description\n    </label>\n  </h1>\n  <textarea class=\"nhsuk-textarea nhsuk-js-character-count\" id=\"with-characters-count-type-threshold\" name=\"example\" rows=\"5\" aria-describedby=\"with-characters-count-type-threshold-info\">Type another letter into this field after this message to see the threshold feature</textarea>\n  <div class=\"nhsuk-hint nhsuk-character-count__message\" id=\"with-characters-count-type-threshold-info\">\n    You can enter up to 112 characters\n  </div>\n</div>"
    },
    {
      "name": "with count type 'characters' and value",
      "context": {
        "label": {
          "text": "Enter a job description",
          "size": "l",
          "isPageHeading": true
        },
        "id": "with-characters-count-type-value",
        "name": "example",
        "countType": "characters",
        "maxlength": 350,
        "value": "👩🏻‍🚀 A content designer works on the end-to-end journey of a service to help users complete their goal and government deliver a policy intent. Their work may involve the creation of, or change to, a transaction, product or single piece of content that stretches across digital and offline channels."
      },
      "screenshot": false,
      "options": {},
      "html": "<div class=\"nhsuk-form-group nhsuk-character-count\" data-module=\"nhsuk-character-count\" data-maxlength=\"350\" data-count-type=\"characters\">\n  <h1 class=\"nhsuk-label-wrapper\">\n    <label class=\"nhsuk-label nhsuk-label--l\" for=\"with-characters-count-type-value\">\n      Enter a job description\n    </label>\n  </h1>\n  <textarea class=\"nhsuk-textarea nhsuk-js-character-count\" id=\"with-characters-count-type-value\" name=\"example\" rows=\"5\" aria-describedby=\"with-characters-count-type-value-info\">👩🏻‍🚀 A content designer works on the end-to-end journey of a service to help users complete their goal and government deliver a policy intent. Their work may involve the creation of, or change to, a transaction, product or single piece of content that stretches across digital and offline channels.</textarea>\n  <div class=\"nhsuk-hint nhsuk-character-count__message\" id=\"with-characters-count-type-value-info\">\n    You can enter up to 350 characters\n  </div>\n</div>"
    },
    {
      "name": "with count type 'length'",
      "context": {
        "label": {
          "text": "Enter a job description",
          "size": "l",
          "isPageHeading": true
        },
        "id": "with-length-count-type",
        "name": "example",
        "countType": "length",
        "maxlength": 200
      },
      "screenshot": false,
      "options": {},
      "html": "<div class=\"nhsuk-form-group nhsuk-character-count\" data-module=\"nhsuk-character-count\" data-maxlength=\"200\" data-count-type=\"length\">\n  <h1 class=\"nhsuk-label-wrapper\">\n    <label class=\"nhsuk-label nhsuk-label--l\" for=\"with-length-count-type\">\n      Enter a job description\n    </label>\n  </h1>\n  <textarea class=\"nhsuk-textarea nhsuk-js-character-count\" id=\"with-length-count-type\" name=\"example\" rows=\"5\" aria-describedby=\"with-length-count-type-info\"></textarea>\n  <div class=\"nhsuk-hint nhsuk-character-count__message\" id=\"with-length-count-type-info\">\n    You can enter up to 200 characters\n  </div>\n</div>"
    },
    {
      "name": "with count type 'words'",
      "context": {
        "label": {
          "text": "Enter a job description",
          "size": "l",
          "isPageHeading": true
        },
        "id": "with-words-count-type",
        "name": "example",
        "countType": "words",
        "maxlength": 50
      },
      "screenshot": {
        "viewports": [
          "tablet"
        ]
      },
      "options": {},
      "html": "<div class=\"nhsuk-form-group nhsuk-character-count\" data-module=\"nhsuk-character-count\" data-maxlength=\"50\" data-count-type=\"words\">\n  <h1 class=\"nhsuk-label-wrapper\">\n    <label class=\"nhsuk-label nhsuk-label--l\" for=\"with-words-count-type\">\n      Enter a job description\n    </label>\n  </h1>\n  <textarea class=\"nhsuk-textarea nhsuk-js-character-count\" id=\"with-words-count-type\" name=\"example\" rows=\"5\" aria-describedby=\"with-words-count-type-info\"></textarea>\n  <div class=\"nhsuk-hint nhsuk-character-count__message\" id=\"with-words-count-type-info\">\n    You can enter up to 50 words\n  </div>\n</div>"
    },
    {
      "name": "with count type 'words' and error message",
      "context": {
        "label": {
          "text": "Enter a job description",
          "size": "l",
          "isPageHeading": true
        },
        "errorMessage": {
          "text": "Job description must be 40 words or less"
        },
        "id": "with-words-count-type-error-message",
        "name": "example",
        "countType": "words",
        "maxlength": 51,
        "value": "👩🏻‍🚀 A content designer works on the end-to-end journey of a service to help users complete their goal and government deliver a policy intent. Their work may involve the creation of, or change to, a transaction, product or single piece of content that stretches across digital and offline channels. They make sure appropriate content is shown to a user in the right place and in the best format."
      },
      "screenshot": false,
      "options": {},
      "html": "<div class=\"nhsuk-form-group nhsuk-form-group--error nhsuk-character-count\" data-module=\"nhsuk-character-count\" data-maxlength=\"51\" data-count-type=\"words\">\n  <h1 class=\"nhsuk-label-wrapper\">\n    <label class=\"nhsuk-label nhsuk-label--l\" for=\"with-words-count-type-error-message\">\n      Enter a job description\n    </label>\n  </h1>\n  <span class=\"nhsuk-error-message\" id=\"with-words-count-type-error-message-error\">\n    <span class=\"nhsuk-u-visually-hidden\">Error:</span> Job description must be 40 words or less\n  </span>\n  <textarea class=\"nhsuk-textarea nhsuk-textarea--error nhsuk-js-character-count\" id=\"with-words-count-type-error-message\" name=\"example\" rows=\"5\" aria-describedby=\"with-words-count-type-error-message-info with-words-count-type-error-message-error\">👩🏻‍🚀 A content designer works on the end-to-end journey of a service to help users complete their goal and government deliver a policy intent. Their work may involve the creation of, or change to, a transaction, product or single piece of content that stretches across digital and offline channels. They make sure appropriate content is shown to a user in the right place and in the best format.</textarea>\n  <div class=\"nhsuk-hint nhsuk-character-count__message\" id=\"with-words-count-type-error-message-info\">\n    You can enter up to 51 words\n  </div>\n</div>"
    },
    {
      "name": "with count type 'words' and threshold",
      "context": {
        "label": {
          "text": "Enter a job description",
          "size": "l",
          "isPageHeading": true
        },
        "id": "with-words-count-type-threshold",
        "name": "example",
        "countType": "words",
        "value": "Type another word into this field after this message to see the threshold feature",
        "maxlength": 51,
        "threshold": 30
      },
      "screenshot": false,
      "options": {},
      "html": "<div class=\"nhsuk-form-group nhsuk-character-count\" data-module=\"nhsuk-character-count\" data-maxlength=\"51\" data-threshold=\"30\" data-count-type=\"words\">\n  <h1 class=\"nhsuk-label-wrapper\">\n    <label class=\"nhsuk-label nhsuk-label--l\" for=\"with-words-count-type-threshold\">\n      Enter a job description\n    </label>\n  </h1>\n  <textarea class=\"nhsuk-textarea nhsuk-js-character-count\" id=\"with-words-count-type-threshold\" name=\"example\" rows=\"5\" aria-describedby=\"with-words-count-type-threshold-info\">Type another word into this field after this message to see the threshold feature</textarea>\n  <div class=\"nhsuk-hint nhsuk-character-count__message\" id=\"with-words-count-type-threshold-info\">\n    You can enter up to 51 words\n  </div>\n</div>"
    },
    {
      "name": "with count type 'words' and value",
      "context": {
        "label": {
          "text": "Enter a job description",
          "size": "l",
          "isPageHeading": true
        },
        "id": "with-words-count-type-value",
        "name": "example",
        "countType": "words",
        "maxlength": 51,
        "value": "👩🏻‍🚀 A content designer works on the end-to-end journey of a service to help users complete their goal and government deliver a policy intent. Their work may involve the creation of, or change to, a transaction, product or single piece of content that stretches across digital and offline channels."
      },
      "screenshot": false,
      "options": {},
      "html": "<div class=\"nhsuk-form-group nhsuk-character-count\" data-module=\"nhsuk-character-count\" data-maxlength=\"51\" data-count-type=\"words\">\n  <h1 class=\"nhsuk-label-wrapper\">\n    <label class=\"nhsuk-label nhsuk-label--l\" for=\"with-words-count-type-value\">\n      Enter a job description\n    </label>\n  </h1>\n  <textarea class=\"nhsuk-textarea nhsuk-js-character-count\" id=\"with-words-count-type-value\" name=\"example\" rows=\"5\" aria-describedby=\"with-words-count-type-value-info\">👩🏻‍🚀 A content designer works on the end-to-end journey of a service to help users complete their goal and government deliver a policy intent. Their work may involve the creation of, or change to, a transaction, product or single piece of content that stretches across digital and offline channels.</textarea>\n  <div class=\"nhsuk-hint nhsuk-character-count__message\" id=\"with-words-count-type-value-info\">\n    You can enter up to 51 words\n  </div>\n</div>"
    },
    {
      "name": "with custom rows",
      "context": {
        "label": {
          "text": "Can you provide more detail?",
          "size": "l",
          "isPageHeading": true
        },
        "id": "custom-rows",
        "name": "example",
        "maxlength": 350,
        "rows": 15
      },
      "screenshot": false,
      "options": {},
      "html": "<div class=\"nhsuk-form-group nhsuk-character-count\" data-module=\"nhsuk-character-count\" data-maxlength=\"350\">\n  <h1 class=\"nhsuk-label-wrapper\">\n    <label class=\"nhsuk-label nhsuk-label--l\" for=\"custom-rows\">\n      Can you provide more detail?\n    </label>\n  </h1>\n  <textarea class=\"nhsuk-textarea nhsuk-js-character-count\" id=\"custom-rows\" name=\"example\" rows=\"15\" aria-describedby=\"custom-rows-info\"></textarea>\n  <div class=\"nhsuk-hint nhsuk-character-count__message\" id=\"custom-rows-info\">\n    You can enter up to 350 characters\n  </div>\n</div>"
    },
    {
      "name": "with error message",
      "context": {
        "label": {
          "text": "Enter a job description",
          "size": "l",
          "isPageHeading": true
        },
        "errorMessage": {
          "text": "Job description must be 350 characters or less"
        },
        "id": "with-error-message",
        "name": "example",
        "maxlength": 350,
        "value": "👩🏻‍🚀 A content designer works on the end-to-end journey of a service to help users complete their goal and government deliver a policy intent. Their work may involve the creation of, or change to, a transaction, product or single piece of content that stretches across digital and offline channels. They make sure appropriate content is shown to a user in the right place and in the best format."
      },
      "screenshot": false,
      "options": {},
      "html": "<div class=\"nhsuk-form-group nhsuk-form-group--error nhsuk-character-count\" data-module=\"nhsuk-character-count\" data-maxlength=\"350\">\n  <h1 class=\"nhsuk-label-wrapper\">\n    <label class=\"nhsuk-label nhsuk-label--l\" for=\"with-error-message\">\n      Enter a job description\n    </label>\n  </h1>\n  <span class=\"nhsuk-error-message\" id=\"with-error-message-error\">\n    <span class=\"nhsuk-u-visually-hidden\">Error:</span> Job description must be 350 characters or less\n  </span>\n  <textarea class=\"nhsuk-textarea nhsuk-textarea--error nhsuk-js-character-count\" id=\"with-error-message\" name=\"example\" rows=\"5\" aria-describedby=\"with-error-message-info with-error-message-error\">👩🏻‍🚀 A content designer works on the end-to-end journey of a service to help users complete their goal and government deliver a policy intent. Their work may involve the creation of, or change to, a transaction, product or single piece of content that stretches across digital and offline channels. They make sure appropriate content is shown to a user in the right place and in the best format.</textarea>\n  <div class=\"nhsuk-hint nhsuk-character-count__message\" id=\"with-error-message-info\">\n    You can enter up to 350 characters\n  </div>\n</div>"
    },
    {
      "name": "with error message and hint",
      "context": {
        "label": {
          "text": "Enter a job description",
          "size": "l",
          "isPageHeading": true
        },
        "hint": {
          "text": "Do not include personal information like your name, date of birth or NHS number"
        },
        "errorMessage": {
          "text": "Job description must be 350 characters or less"
        },
        "id": "with-error-message",
        "name": "example",
        "maxlength": 350,
        "value": "👩🏻‍🚀 A content designer works on the end-to-end journey of a service to help users complete their goal and government deliver a policy intent. Their work may involve the creation of, or change to, a transaction, product or single piece of content that stretches across digital and offline channels. They make sure appropriate content is shown to a user in the right place and in the best format."
      },
      "screenshot": {
        "states": [
          "focus"
        ],
        "selector": ".nhsuk-textarea"
      },
      "options": {},
      "html": "<div class=\"nhsuk-form-group nhsuk-form-group--error nhsuk-character-count\" data-module=\"nhsuk-character-count\" data-maxlength=\"350\">\n  <h1 class=\"nhsuk-label-wrapper\">\n    <label class=\"nhsuk-label nhsuk-label--l\" for=\"with-error-message\">\n      Enter a job description\n    </label>\n  </h1>\n  <div class=\"nhsuk-hint\" id=\"with-error-message-hint\">\n    Do not include personal information like your name, date of birth or NHS number\n  </div>\n  <span class=\"nhsuk-error-message\" id=\"with-error-message-error\">\n    <span class=\"nhsuk-u-visually-hidden\">Error:</span> Job description must be 350 characters or less\n  </span>\n  <textarea class=\"nhsuk-textarea nhsuk-textarea--error nhsuk-js-character-count\" id=\"with-error-message\" name=\"example\" rows=\"5\" aria-describedby=\"with-error-message-info with-error-message-hint with-error-message-error\">👩🏻‍🚀 A content designer works on the end-to-end journey of a service to help users complete their goal and government deliver a policy intent. Their work may involve the creation of, or change to, a transaction, product or single piece of content that stretches across digital and offline channels. They make sure appropriate content is shown to a user in the right place and in the best format.</textarea>\n  <div class=\"nhsuk-hint nhsuk-character-count__message\" id=\"with-error-message-info\">\n    You can enter up to 350 characters\n  </div>\n</div>"
    },
    {
      "name": "with hint",
      "context": {
        "label": {
          "text": "Enter a job description",
          "size": "l",
          "isPageHeading": true
        },
        "hint": {
          "text": "Do not include personal information like your name, date of birth or NHS number"
        },
        "id": "with-hint",
        "name": "example",
        "maxlength": 200
      },
      "screenshot": false,
      "options": {},
      "html": "<div class=\"nhsuk-form-group nhsuk-character-count\" data-module=\"nhsuk-character-count\" data-maxlength=\"200\">\n  <h1 class=\"nhsuk-label-wrapper\">\n    <label class=\"nhsuk-label nhsuk-label--l\" for=\"with-hint\">\n      Enter a job description\n    </label>\n  </h1>\n  <div class=\"nhsuk-hint\" id=\"with-hint-hint\">\n    Do not include personal information like your name, date of birth or NHS number\n  </div>\n  <textarea class=\"nhsuk-textarea nhsuk-js-character-count\" id=\"with-hint\" name=\"example\" rows=\"5\" aria-describedby=\"with-hint-info with-hint-hint\"></textarea>\n  <div class=\"nhsuk-hint nhsuk-character-count__message\" id=\"with-hint-info\">\n    You can enter up to 200 characters\n  </div>\n</div>"
    },
    {
      "name": "with maxlength attribute",
      "context": {
        "label": {
          "text": "Enter a job description"
        },
        "id": "maxlength-attribute",
        "name": "example",
        "maxlength": 11,
        "attributes": {
          "maxlength": 11
        }
      },
      "screenshot": false,
      "options": {
        "hidden": true
      },
      "html": "<div class=\"nhsuk-form-group nhsuk-character-count\" data-module=\"nhsuk-character-count\" data-maxlength=\"11\">\n  <label class=\"nhsuk-label\" for=\"maxlength-attribute\">\n    Enter a job description\n  </label>\n  <textarea class=\"nhsuk-textarea nhsuk-js-character-count\" id=\"maxlength-attribute\" name=\"example\" rows=\"5\" aria-describedby=\"maxlength-attribute-info\" maxlength=\"11\"></textarea>\n  <div class=\"nhsuk-hint nhsuk-character-count__message\" id=\"maxlength-attribute-info\">\n    You can enter up to 11 characters\n  </div>\n</div>"
    },
    {
      "name": "with maxwords",
      "context": {
        "label": {
          "text": "Enter a job description",
          "size": "l",
          "isPageHeading": true
        },
        "id": "with-word-count",
        "name": "example",
        "maxwords": 150
      },
      "screenshot": false,
      "options": {},
      "html": "<div class=\"nhsuk-form-group nhsuk-character-count\" data-module=\"nhsuk-character-count\" data-maxwords=\"150\" data-count-type=\"words\">\n  <h1 class=\"nhsuk-label-wrapper\">\n    <label class=\"nhsuk-label nhsuk-label--l\" for=\"with-word-count\">\n      Enter a job description\n    </label>\n  </h1>\n  <textarea class=\"nhsuk-textarea nhsuk-js-character-count\" id=\"with-word-count\" name=\"example\" rows=\"5\" aria-describedby=\"with-word-count-info\"></textarea>\n  <div class=\"nhsuk-hint nhsuk-character-count__message\" id=\"with-word-count-info\">\n    You can enter up to 150 words\n  </div>\n</div>"
    },
    {
      "name": "with neither maxlength, maxwords nor textarea description set",
      "context": {
        "label": {
          "text": "Can you provide more detail?",
          "size": "l",
          "isPageHeading": true
        },
        "id": "no-maximum",
        "name": "example",
        "value": "This textarea has no maximum character or word count.",
        "rows": 8
      },
      "screenshot": false,
      "options": {
        "hidden": true,
        "throwOnError": false
      },
      "html": "<div class=\"nhsuk-form-group nhsuk-character-count\" data-module=\"nhsuk-character-count\">\n  <h1 class=\"nhsuk-label-wrapper\">\n    <label class=\"nhsuk-label nhsuk-label--l\" for=\"no-maximum\">\n      Can you provide more detail?\n    </label>\n  </h1>\n  <textarea class=\"nhsuk-textarea nhsuk-js-character-count\" id=\"no-maximum\" name=\"example\" rows=\"8\" aria-describedby=\"no-maximum-info\">This textarea has no maximum character or word count.</textarea>\n  <div class=\"nhsuk-hint nhsuk-character-count__message\" id=\"no-maximum-info\" hidden>\n    \n  </div>\n</div>"
    },
    {
      "name": "with neither maxlength nor maxwords set",
      "context": {
        "label": {
          "text": "Can you provide more detail?",
          "size": "l",
          "isPageHeading": true
        },
        "textareaDescriptionText": "No more than %{count} characters",
        "id": "no-maximum-description",
        "name": "example",
        "value": "This textarea has no maximum character or word count.",
        "rows": 8
      },
      "screenshot": false,
      "options": {
        "hidden": true,
        "throwOnError": false
      },
      "html": "<div class=\"nhsuk-form-group nhsuk-character-count\" data-module=\"nhsuk-character-count\" data-i18n.textarea-description.other=\"No more than %{count} characters\">\n  <h1 class=\"nhsuk-label-wrapper\">\n    <label class=\"nhsuk-label nhsuk-label--l\" for=\"no-maximum-description\">\n      Can you provide more detail?\n    </label>\n  </h1>\n  <textarea class=\"nhsuk-textarea nhsuk-js-character-count\" id=\"no-maximum-description\" name=\"example\" rows=\"8\" aria-describedby=\"no-maximum-description-info\">This textarea has no maximum character or word count.</textarea>\n  <div class=\"nhsuk-hint nhsuk-character-count__message\" id=\"no-maximum-description-info\" hidden>\n    \n  </div>\n</div>"
    },
    {
      "name": "without page heading",
      "context": {
        "label": {
          "text": "Tell us more about what happened"
        },
        "id": "without-heading",
        "name": "example",
        "maxlength": 150
      },
      "screenshot": false,
      "options": {},
      "html": "<div class=\"nhsuk-form-group nhsuk-character-count\" data-module=\"nhsuk-character-count\" data-maxlength=\"150\">\n  <label class=\"nhsuk-label\" for=\"without-heading\">\n    Tell us more about what happened\n  </label>\n  <textarea class=\"nhsuk-textarea nhsuk-js-character-count\" id=\"without-heading\" name=\"example\" rows=\"5\" aria-describedby=\"without-heading-info\"></textarea>\n  <div class=\"nhsuk-hint nhsuk-character-count__message\" id=\"without-heading-info\">\n    You can enter up to 150 characters\n  </div>\n</div>"
    },
    {
      "name": "with threshold",
      "context": {
        "label": {
          "text": "Can you provide more detail?",
          "size": "l",
          "isPageHeading": true
        },
        "id": "with-threshold",
        "name": "example",
        "value": "Type another letter into this field after this message to see the threshold feature",
        "maxlength": 112,
        "threshold": 75
      },
      "screenshot": {
        "viewports": [
          "tablet"
        ]
      },
      "options": {},
      "html": "<div class=\"nhsuk-form-group nhsuk-character-count\" data-module=\"nhsuk-character-count\" data-maxlength=\"112\" data-threshold=\"75\">\n  <h1 class=\"nhsuk-label-wrapper\">\n    <label class=\"nhsuk-label nhsuk-label--l\" for=\"with-threshold\">\n      Can you provide more detail?\n    </label>\n  </h1>\n  <textarea class=\"nhsuk-textarea nhsuk-js-character-count\" id=\"with-threshold\" name=\"example\" rows=\"5\" aria-describedby=\"with-threshold-info\">Type another letter into this field after this message to see the threshold feature</textarea>\n  <div class=\"nhsuk-hint nhsuk-character-count__message\" id=\"with-threshold-info\">\n    You can enter up to 112 characters\n  </div>\n</div>"
    },
    {
      "name": "with translations",
      "context": {
        "label": {
          "text": "Allwch chi roi mwy o fanylion?",
          "size": "l",
          "isPageHeading": true
        },
        "hint": {
          "text": "Peidiwch â chynnwys gwybodaeth bersonol, fel eich enw, dyddiad geni na rhif y GIG"
        },
        "id": "with-translations",
        "name": "example",
        "maxlength": 200,
        "textareaDescriptionText": "Gallwch ddefnyddio hyd at %{count} nod",
        "charactersUnderLimitText": {
          "one": "Mae gennych %{count} nod ar ôl",
          "two": "Mae gennych %{count} nod ar ôl",
          "few": "Mae gennych %{count} nod ar ôl",
          "many": "Mae gennych %{count} nod ar ôl",
          "other": "Mae gennych %{count} nod ar ôl"
        },
        "charactersAtLimitText": "Mae gennych 0 nod ar ôl",
        "charactersOverLimitText": {
          "one": "Mae gennych %{count} nod yn ormod",
          "two": "Mae gennych %{count} nod yn ormod",
          "few": "Mae gennych %{count} nod yn ormod",
          "many": "Mae gennych %{count} nod yn ormod",
          "other": "Mae gennych chi %{count} nod yn ormod"
        }
      },
      "screenshot": false,
      "options": {},
      "html": "<div class=\"nhsuk-form-group nhsuk-character-count\" data-module=\"nhsuk-character-count\" data-maxlength=\"200\" data-i18n.characters-under-limit.one=\"Mae gennych %{count} nod ar ôl\" data-i18n.characters-under-limit.two=\"Mae gennych %{count} nod ar ôl\" data-i18n.characters-under-limit.few=\"Mae gennych %{count} nod ar ôl\" data-i18n.characters-under-limit.many=\"Mae gennych %{count} nod ar ôl\" data-i18n.characters-under-limit.other=\"Mae gennych %{count} nod ar ôl\" data-i18n.characters-at-limit=\"Mae gennych 0 nod ar ôl\" data-i18n.characters-over-limit.one=\"Mae gennych %{count} nod yn ormod\" data-i18n.characters-over-limit.two=\"Mae gennych %{count} nod yn ormod\" data-i18n.characters-over-limit.few=\"Mae gennych %{count} nod yn ormod\" data-i18n.characters-over-limit.many=\"Mae gennych %{count} nod yn ormod\" data-i18n.characters-over-limit.other=\"Mae gennych chi %{count} nod yn ormod\">\n  <h1 class=\"nhsuk-label-wrapper\">\n    <label class=\"nhsuk-label nhsuk-label--l\" for=\"with-translations\">\n      Allwch chi roi mwy o fanylion?\n    </label>\n  </h1>\n  <div class=\"nhsuk-hint\" id=\"with-translations-hint\">\n    Peidiwch â chynnwys gwybodaeth bersonol, fel eich enw, dyddiad geni na rhif y GIG\n  </div>\n  <textarea class=\"nhsuk-textarea nhsuk-js-character-count\" id=\"with-translations\" name=\"example\" rows=\"5\" aria-describedby=\"with-translations-info with-translations-hint\"></textarea>\n  <div class=\"nhsuk-hint nhsuk-character-count__message\" id=\"with-translations-info\">\n    Gallwch ddefnyddio hyd at 200 nod\n  </div>\n</div>"
    },
    {
      "name": "with value",
      "context": {
        "label": {
          "text": "Enter a job description",
          "size": "l",
          "isPageHeading": true
        },
        "id": "with-value",
        "name": "example",
        "maxlength": 350,
        "value": "👩🏻‍🚀 A content designer works on the end-to-end journey of a service to help users complete their goal and government deliver a policy intent. Their work may involve the creation of, or change to, a transaction, product or single piece of content that stretches across digital and offline channels."
      },
      "screenshot": false,
      "options": {},
      "html": "<div class=\"nhsuk-form-group nhsuk-character-count\" data-module=\"nhsuk-character-count\" data-maxlength=\"350\">\n  <h1 class=\"nhsuk-label-wrapper\">\n    <label class=\"nhsuk-label nhsuk-label--l\" for=\"with-value\">\n      Enter a job description\n    </label>\n  </h1>\n  <textarea class=\"nhsuk-textarea nhsuk-js-character-count\" id=\"with-value\" name=\"example\" rows=\"5\" aria-describedby=\"with-value-info\">👩🏻‍🚀 A content designer works on the end-to-end journey of a service to help users complete their goal and government deliver a policy intent. Their work may involve the creation of, or change to, a transaction, product or single piece of content that stretches across digital and offline channels.</textarea>\n  <div class=\"nhsuk-hint nhsuk-character-count__message\" id=\"with-value-info\">\n    You can enter up to 350 characters\n  </div>\n</div>"
    }
  ]
}
