Pular para o conteúdo principal

Radio

Import

import { Radio } from '@resultadosdigitais/tangram-components'

Properties

name

Typestring

Description

Sets the input name.

value

Typeany
Default'on'

Description

Sets the input value.

label

Typenode

Description

Sets the label for Radio.

checked

Typebool

Description

Sets if is checked

defaultChecked

Typebool

Description

Sets the value. Used for Uncontrolled component.

disabled

Typebool
Defaultfalse

Description

Sets if Radio is disabled.

required

Typebool
Defaultfalse

Description

Sets if Radio is required.

size

Type
Enum of:
  • Radio.sizes.md
  • Radio.sizes.lg
DefaultRadio.sizes.md

Description

Sets the Radio size.

inverted

Typebool
Defaultfalse

Description

Switch Radio style for inverted mode.

rootRef

Typefunc | shape

Description

Pass a ref to the element wrapper.

onChange

Typefunc
Paramevent React.SyntheticEvent - The event source of the callback.

Description

Callback fired when the Radio is changed.

onFocus

Typefunc
Paramevent React.SyntheticEvent - The event source of the callback.

Description

Callback fired when the Radio is focused.

onBlur

Typefunc
Paramevent React.SyntheticEvent - The event source of the callback.

Description

Callback fired when the Radio is blurred.

<RadioGroup />

Import

import { RadioGroup } from '@resultadosdigitais/tangram-components'

Properties

children

Typenode | func
Description

Sets the children.

defaultValue

Typeany
Description

Sets the value. Used for Uncontrolled component.

value

Typeany
Description

Used for Controlled component. Set to an empty string '' if you don't want any of the available options to be selected.

name 📍

Concerns
📍 Required
Typestring
Description

The name used to get the value as reference.

onChange

Typefunc
Paramevent React.SyntheticEvent - The event source of the callback.
Description

Callback fired when some option is checked.

row

Typebool
Defaultfalse
Description

Sets the alignment in the row direction. By default is false (column direction).

Feedback