Socket
Book a DemoInstallSign in
Socket

@axa-fr/react-toolkit-form-input-choice

Package Overview
Dependencies
Maintainers
0
Versions
87
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@axa-fr/react-toolkit-form-input-choice

1. [ChoiceInput](#choiceinput) 2. [ChoiceInput Required](#choiceinput-required) 3. [Choice](#choice)

latest
Source
npmnpm
Version
3.0.2
Version published
Maintainers
0
Created
Source

@axa-fr/react-toolkit-form-input-choice

  • ChoiceInput
  • ChoiceInput Required
  • Choice

ChoiceInput

Installation

npm i @axa-fr/react-toolkit-form-input-choice
npm i @axa-fr/react-toolkit-form-core

Import

import { ChoiceInput } from '@axa-fr/react-toolkit-form-input-choice';
import '@axa-fr/react-toolkit-form-input-choice/dist/af-radio.css';
import { MessageTypes } from '@axa-fr/react-toolkit-form-core';
import '@axa-fr/react-toolkit-form-core/dist/af-form.css';

Use

const ChoiceInputForm = () => (
  <form className="af-form" name="myform">
    <ChoiceInput
      id="uniqueid"
      name="choiceInputName"
      label="Place type"
      messageType={MessageTypes.error}
      classNameContainerLabel="col-md-2"
      classNameContainerInput="col-md-10"
      onChange={(e) => {
        console.log(e);
      }}
      onClick={(e) => {
        console.log(e);
      }}
    />
  </form>
);
export default ChoiceInputForm;

ChoiceInput Required

To achieve CheckboxInputRequired, you need to add this :

classModifier = 'required';

to the ChoiceInput component

Choice

Installation

npm i @axa-fr/react-toolkit-form-input-choice

Import

import { Choice } from '@axa-fr/react-toolkit-form-input-choice';
import '@axa-fr/react-toolkit-form-input-choice/dist/af-radio.css';

Use

const ChoiceInput = () => (
  <form className="af-form" name="myform">
    <Choice
      name="placeName"
      onChange={(e) => {
        console.log(e);
      }}
    />
  </form>
);
export default ChoiceInput;

FAQs

Package last updated on 15 Nov 2024

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts