# react-custom-radio-buttons-group

> Simple Radio-buttons group Component

Latest version **1.0.5** (published 2021-07-25) · 0 weekly downloads

## Install

```sh
npm install react-custom-radio-buttons-group
pnpm add react-custom-radio-buttons-group
yarn add react-custom-radio-buttons-group
bun add react-custom-radio-buttons-group
```

## Health

**Score 20/100 (F)** — status: abandoned.

Positive: esm support; no vulnerabilities.

Warnings: low downloads; no types.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 1.0.5 |
| Published | 2021-07-25 |
| First published | 2021-07-24 |
| Weekly downloads | 0 |
| TypeScript types | none |
| Module format | ESM + CommonJS |
| Node | >=10 |
| Dependencies | 6 |
| Unpacked size | 9.8 KB |
| Known vulnerabilities | 0 (+1 in 1 direct dependencies) |
| Install scripts | no |
| GitHub stars | 2 |
| Author | L7aj |
| Maintainers | l7aje |
| Keywords | react, component, radio-buttons, custom, react radio buttons, react-radio-buttons |

## Links

- npm: https://www.npmjs.com/package/react-custom-radio-buttons-group
- Repository: https://github.com/l7aje/react-custom-radio-buttons-group
- Homepage: https://github.com/l7aje/react-custom-radio-buttons-group#readme
- Issues: https://github.com/l7aje/react-custom-radio-buttons-group/issues
- npm.io page: https://npm.io/package/react-custom-radio-buttons-group

## Dependencies (6)

- [uuid](https://npm.io/package/uuid.md) ^3.4.0
- [react](https://npm.io/package/react.md) ^17.0.2
- [react-dom](https://npm.io/package/react-dom.md) ^17.0.2
- [web-vitals](https://npm.io/package/web-vitals.md) ^1.0.1
- [react-scripts](https://npm.io/package/react-scripts.md) 4.0.3
- [styled-components](https://npm.io/package/styled-components.md) ^5.3.0

## Alternatives

- [mobx-react](https://npm.io/package/mobx-react.md) — 2.8M weekly downloads
- [rc-tree](https://npm.io/package/rc-tree.md) — 2.6M weekly downloads
- [@react-oauth/google](https://npm.io/package/@react-oauth/google.md) — 1.3M weekly downloads
- [@wagmi/connectors](https://npm.io/package/@wagmi/connectors.md) — 877.0K weekly downloads
- [vee-validate](https://npm.io/package/vee-validate.md) — 836.4K weekly downloads

## Recent versions

- 1.0.5 (latest) — 2021-07-25
- 1.0.4 — 2021-07-25
- 1.0.3 — 2021-07-25
- 1.0.2 — 2021-07-25
- 1.0.1 — 2021-07-24
- 1.0.0 — 2021-07-24

## README

react-custom-radio-buttons-group is a well designed single react component that helps you create radio-buttons group.

![react-custom-radio-buttons-group](https://user-images.githubusercontent.com/26367467/126909507-c9b89633-cec7-4b60-bbcd-764e5885f8c9.gif)

## Installing / Getting started

This package is available in NPM repository as react-custom-radio-buttons-group. It will work correctly with all popular bundlers.

```bash
npm install react-custom-radio-buttons-group --save
```

Using yarn

```bash
yarn add react-custom-radio-buttons-group
```

## Include the Component

To start using react-custom-radio-buttons-group you just need to import the component RadioButtonGroup from the package.

```jsx
import React from 'react';
import RadioButtonGroup from 'react-custom-radio-buttons-group';
const handleChange = (e)=>{
    doSomething(e.target.value)
}
export default () => (
  <RadioButtonGroup
    onChange={handleChange}
    hide={false}
    values={[...]}
    />
);
```
# Documentation

### RadioButtonGroup
| name     | description    |
|----------|----------------|
|onChange|called when select a value from `values` |
|values|Array of radio-buttons|
|hide|if `true` it hides radio button input |

### Values

- Values can be an array of text:
```jsx
  <RadioButtonGroup
    onChange={handleChange}
    hide={false}
    values={["Apple","Banana","Orange"]}
    />
```
- Or a react component
```jsx
  <RadioButtonGroup
    onChange={handleChange}
    hide={true}
    values={[<Especes/>,<Paypal/>,<Credit/>,<Tpe/>]}
    />
```
![custom](https://user-images.githubusercontent.com/26367467/126910114-a4e6f2dd-dd41-43ef-973d-e002991bf9d3.JPG)

### Custom styles

To edit radio-buttons default change you have to override the css properties of classes bellow:
```css
/* radio-button default style */
  .radio-button {
}
/* radio-button active style */
.radio-button.active {
}
/* radio-button input default style */
.dot{
}
.dot::before{
}
/* radio-button input active style */
.dot.active{
}
.dot.active::before{
}
```

---
_Source: https://npm.io/package/react-custom-radio-buttons-group · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
