Skip to content

Field radio ​

The field is used to select a single value from the provided set.

Params ​

options Required ​

The set of possible field values.


Also, all parameters common to all FormField. Information about them can be viewed on this page.

Value ​

When clicking or selecting the corresponding radio element, the value will be set to according to the value in the value field of the passed options.

Specification ​

  • The object is available for access via Tab and Shift + Tab.
  • Moving around the object is possible using ArrowDown and ArrowUp. Moving this way changes the value of a field.
  • Selecting an element is possible by clicking on the corresponding element.
  • Cannot select an element using Enter or Space.
  • Blocking fields cancels navigation using Tab. There is also a change in the style of radio.
  • If the validation fails, the field should change the radio style.

Examples ​

To connect a widget, you need to specify type and options:

html
<form-field :options = "companies" type = "radio"/>
<form-field :options = "companies" type = "radio"/>
ts
import {FormField} from "jenesius-vue-form";

const companies = {
	'a': "Apple",
	'h': "Huawei",
	's': "Samsung"
};
import {FormField} from "jenesius-vue-form";

const companies = {
	'a': "Apple",
	'h': "Huawei",
	's': "Samsung"
};

By default:

Select one

Apple

Huawei

Samsung


In disabled state

Disabled

Apple

Huawei

Samsung


Field not validated:

With error

Apple

Huawei

Samsung

Seleact this fields



The current state of the form:

ts
{}
{}

Released under the MIT License.