Reset - Reset the input

This function makes it possible to reset the data entered by the user. The value must be bound so that the value can be reset. The status of the form is then the same as it was before the user entered anything. The reset function can be used, for example, via a Button button.

Example

reset.json
{
  "$schema": "http://bpc.virtimo.net/forms/1/schema",
  "metaData": {
    "id": 0,
    "version": 0
  },
  "configuration": {
  },
  "components": [
    {
      "type": "container",
      "label": "Reset Example",
      "components": [
        {
          "type": "checkbox",
          "label": "False After Reset",
          "value": "/data/0"
        },
        {
          "type": "checkbox",
          "label": "True After Reset",
          "value": "/data/1"
        },
        {
          "type": "textfield",
          "label": "Empty After Reset",
          "value": "/data/2"
        },
        {
          "type": "textfield",
          "label": "Hello After Reset",
          "value": "/data/3"
        },
        {
          "type": "button",
          "action": "reset",
          "label": "Reset Button"
        }
      ]
    }
  ],
  "state": {
    "data": {
      "0": false,
      "1": true,
      "2": "",
      "3": "Hello"
    }
  }
}
Embedded preview

Keywords: