DocSpace-client/packages/components/radio-button
2023-04-24 13:59:20 +05:00
..
svg Web:Common/Client/Components: add PUBLIC_DIR alias 2023-01-27 17:08:30 +03:00
index.js Web: Components: RadioButton - added description 2023-04-24 13:59:20 +05:00
radio-button.stories.js Web: Moved all clients app to packages directory 2022-07-22 22:01:25 +03:00
radio-button.test.js Web: Moved all clients app to packages directory 2022-07-22 22:01:25 +03:00
README.md Web: Moved all clients app to packages directory 2022-07-22 22:01:25 +03:00
styled-radio-button.js Web: Moved all clients app to packages directory 2022-07-22 22:01:25 +03:00

RadioButton

RadioButton allow you to add radiobutton

Usage

import RadioButton from "@docspace/components/radio-button";
<RadioButton name="fruits" value="apple" label="Sweet apple" />

Properties

<RadioButtonGroup /> props supersede RadioButton props

Props Type Required Values Default Description
className string - - - Accepts class
id string - - - Accepts id
isChecked bool - - false Used as HTML checked property for each <input> tag
isDisabled bool - - false Used as HTML disabled property for each <input> tag
label string - - - Name of the radiobutton. If missed, value will be used
fontSize string - - - Font size of link
fontWeight number, string - - - Font weight of link
name string - - Used as HTML name property for <input> tag.
onClick func - - - Allow you to handle clicking events on component
orientation oneOf - vertical, horizontal horizontal Position of radiobuttons
spacing string - - 15px Margin between radiobutton. If orientation horizontal, it is margin-left(apply for all radiobuttons, except first), if orientation vertical, it is margin-bottom(apply for all radiobuttons, except last)
style obj, array - - - Accepts css style
value string - - Used as HTML value property for <input> tag. Used for identification each radiobutton
width string - - 100% Width of RadioButtonGroup container