{
    "component": "question-number",
    "fixtures": [
        {
            "name": "default",
            "options": {
                "question": {
                    "id": "example",
                    "question": "Here is the service question"
                }
            },
            "hidden": false,
            "description": "",
            "previewLayoutModifiers": [],
            "html": "<div class=\"govuk-form-group\">\n  <label class=\"govuk-label govuk-label--m\" for=\"input-example\">\n    Here is the service question\n  </label>\n  <input class=\"govuk-input govuk-input--width-5\" id=\"input-example\" name=\"example\" type=\"text\">\n</div>"
        },
        {
            "name": "with hint",
            "options": {
                "question": {
                    "id": "example",
                    "question": "Here is the service question",
                    "hint": "This is a hint for the question"
                }
            },
            "hidden": false,
            "description": "",
            "previewLayoutModifiers": [],
            "html": "<div class=\"govuk-form-group\">\n  <label class=\"govuk-label govuk-label--m\" for=\"input-example\">\n    Here is the service question\n  </label>\n  <div id=\"input-example-hint\" class=\"govuk-hint\">\n    This is a hint for the question\n  </div>\n  <input class=\"govuk-input govuk-input--width-5\" id=\"input-example\" name=\"example\" type=\"text\" aria-describedby=\"input-example-hint\">\n</div>"
        },
        {
            "name": "with question advice",
            "options": {
                "question": {
                    "id": "example",
                    "question": "Here is the service question",
                    "question_advice": "Here is the question advice"
                }
            },
            "hidden": false,
            "description": "",
            "previewLayoutModifiers": [],
            "html": "<div class=\"govuk-form-group\">\n  <label class=\"govuk-label govuk-label--m\" for=\"input-example\">\n    Here is the service question\n  </label>\n  <div id=\"input-example-hint\" class=\"govuk-hint\">\n    <div class=\"govuk-body\">\n          Here is the question advice\n        </div>\n  </div>\n  <input class=\"govuk-input govuk-input--width-5\" id=\"input-example\" name=\"example\" type=\"text\" aria-describedby=\"input-example-hint\">\n</div>"
        },
        {
            "name": "with hidden",
            "options": {
                "question": {
                    "id": "example",
                    "question": "Here is the service question",
                    "hidden": true
                }
            },
            "hidden": false,
            "description": "",
            "previewLayoutModifiers": [],
            "html": "<div class=\"govuk-form-group\">\n  <label class=\"govuk-label govuk-label--m\" for=\"input-example\">\n    Here is the service question\n  </label>\n  <input class=\"govuk-input govuk-input--width-5\" id=\"input-example\" name=\"example\" type=\"text\">\n</div>"
        },
        {
            "name": "with data",
            "options": {
                "question": {
                    "id": "example",
                    "question": "Here is the service question"
                },
                "data": {
                    "example": 25
                }
            },
            "hidden": false,
            "description": "",
            "previewLayoutModifiers": [],
            "html": "<div class=\"govuk-form-group\">\n  <label class=\"govuk-label govuk-label--m\" for=\"input-example\">\n    Here is the service question\n  </label>\n  <input class=\"govuk-input govuk-input--width-5\" id=\"input-example\" name=\"example\" type=\"text\" value=\"25\">\n</div>"
        },
        {
            "name": "with optional",
            "options": {
                "question": {
                    "id": "example",
                    "question": "Here is the service question",
                    "optional": true
                }
            },
            "hidden": false,
            "description": "",
            "previewLayoutModifiers": [],
            "html": "<div class=\"govuk-form-group\">\n  <label class=\"govuk-label govuk-label--m\" for=\"input-example\">\n    Here is the service question (optional)\n  </label>\n  <input class=\"govuk-input govuk-input--width-5\" id=\"input-example\" name=\"example\" type=\"text\">\n</div>"
        },
        {
            "name": "with optional text",
            "options": {
                "question": {
                    "id": "example",
                    "question": "Here is the service question",
                    "optional": true,
                    "optional_text": "if applicable"
                }
            },
            "hidden": false,
            "description": "",
            "previewLayoutModifiers": [],
            "html": "<div class=\"govuk-form-group\">\n  <label class=\"govuk-label govuk-label--m\" for=\"input-example\">\n    Here is the service question (if applicable)\n  </label>\n  <input class=\"govuk-input govuk-input--width-5\" id=\"input-example\" name=\"example\" type=\"text\">\n</div>"
        },
        {
            "name": "with error message",
            "options": {
                "question": {
                    "id": "example",
                    "question": "Here is the service question"
                },
                "errors": {
                    "example": {
                        "message": "You must enter into the number field"
                    }
                }
            },
            "hidden": false,
            "description": "",
            "previewLayoutModifiers": [],
            "html": "<div class=\"govuk-form-group govuk-form-group--error\">\n  <label class=\"govuk-label govuk-label--m\" for=\"input-example\">\n    Here is the service question\n  </label>\n  <p id=\"input-example-error\" class=\"govuk-error-message\">\n    <span class=\"govuk-visually-hidden\">Error:</span> You must enter into the number field\n  </p>\n  <input class=\"govuk-input govuk-input--width-5 govuk-input--error\" id=\"input-example\" name=\"example\" type=\"text\" aria-describedby=\"input-example-error\">\n</div>"
        },
        {
            "name": "with hint and error message",
            "options": {
                "question": {
                    "id": "example",
                    "question": "Here is the service question",
                    "hint": "This is a hint for the question"
                },
                "errors": {
                    "example": {
                        "message": "You must enter into the number field"
                    }
                }
            },
            "hidden": false,
            "description": "",
            "previewLayoutModifiers": [],
            "html": "<div class=\"govuk-form-group govuk-form-group--error\">\n  <label class=\"govuk-label govuk-label--m\" for=\"input-example\">\n    Here is the service question\n  </label>\n  <div id=\"input-example-hint\" class=\"govuk-hint\">\n    This is a hint for the question\n  </div>\n  <p id=\"input-example-error\" class=\"govuk-error-message\">\n    <span class=\"govuk-visually-hidden\">Error:</span> You must enter into the number field\n  </p>\n  <input class=\"govuk-input govuk-input--width-5 govuk-input--error\" id=\"input-example\" name=\"example\" type=\"text\" aria-describedby=\"input-example-hint input-example-error\">\n</div>"
        },
        {
            "name": "with previous framework",
            "options": {
                "question": {
                    "id": "example",
                    "question": "Here is the service question"
                },
                "data": {
                    "example": 25
                },
                "frameworkReusedFrom": "G-Cloud 12"
            },
            "hidden": false,
            "description": "",
            "previewLayoutModifiers": [],
            "html": "<div class=\"govuk-form-group govuk-form-group--error dm-form-group--declaration-reuse\">\n  <label class=\"govuk-label govuk-label--m\" for=\"input-example\">\n    Here is the service question\n  </label>\n  <p id=\"input-example-error\" class=\"govuk-error-message\">\n    <span class=\"govuk-visually-hidden\">Notice:</span> This answer is from your G-Cloud 12 declaration\n  </p>\n  <input class=\"govuk-input govuk-input--width-5 govuk-input--error\" id=\"input-example\" name=\"example\" type=\"text\" value=\"25\" aria-describedby=\"input-example-error\">\n</div>"
        },
        {
            "name": "with previous framework without data",
            "options": {
                "question": {
                    "id": "example",
                    "question": "Here is the service question"
                },
                "frameworkReusedFrom": "G-Cloud 12"
            },
            "hidden": false,
            "description": "",
            "previewLayoutModifiers": [],
            "html": "<div class=\"govuk-form-group\">\n  <label class=\"govuk-label govuk-label--m\" for=\"input-example\">\n    Here is the service question\n  </label>\n  <input class=\"govuk-input govuk-input--width-5\" id=\"input-example\" name=\"example\" type=\"text\">\n</div>"
        },
        {
            "name": "with previous framework and error message",
            "options": {
                "question": {
                    "id": "example",
                    "question": "Here is the service question"
                },
                "data": {
                    "example": 25
                },
                "errors": {
                    "example": {
                        "message": "You must enter into the number field"
                    }
                },
                "frameworkReusedFrom": "G-Cloud 12"
            },
            "hidden": false,
            "description": "",
            "previewLayoutModifiers": [],
            "html": "<div class=\"govuk-form-group govuk-form-group--error\">\n  <label class=\"govuk-label govuk-label--m\" for=\"input-example\">\n    Here is the service question\n  </label>\n  <p id=\"input-example-error\" class=\"govuk-error-message\">\n    <span class=\"govuk-visually-hidden\">Error:</span> You must enter into the number field\n  </p>\n  <input class=\"govuk-input govuk-input--width-5 govuk-input--error\" id=\"input-example\" name=\"example\" type=\"text\" value=\"25\" aria-describedby=\"input-example-error\">\n</div>"
        },
        {
            "name": "with prefix",
            "options": {
                "question": {
                    "id": "example",
                    "question": "Here is the service question",
                    "unit": "£",
                    "unit_position": "before"
                }
            },
            "hidden": false,
            "description": "",
            "previewLayoutModifiers": [],
            "html": "<div class=\"govuk-form-group\">\n  <label class=\"govuk-label govuk-label--m\" for=\"input-example\">\n    Here is the service question\n  </label>\n  <div class=\"govuk-input__wrapper\">\n    <div class=\"govuk-input__prefix\" aria-hidden=\"true\">£</div>\n    <input class=\"govuk-input govuk-input--width-5\" id=\"input-example\" name=\"example\" type=\"text\">\n  </div>\n</div>"
        },
        {
            "name": "with suffix",
            "options": {
                "question": {
                    "id": "example",
                    "question": "Here is the service question",
                    "unit": "%",
                    "unit_position": "after"
                }
            },
            "hidden": false,
            "description": "",
            "previewLayoutModifiers": [],
            "html": "<div class=\"govuk-form-group\">\n  <label class=\"govuk-label govuk-label--m\" for=\"input-example\">\n    Here is the service question\n  </label>\n  <div class=\"govuk-input__wrapper\">\n    <input class=\"govuk-input govuk-input--width-5\" id=\"input-example\" name=\"example\" type=\"text\">\n    <div class=\"govuk-input__suffix\" aria-hidden=\"true\">%</div>\n  </div>\n</div>"
        }
    ]
}
