Giter Club home page Giter Club logo

react-icheck's Introduction

React-iCheck

NPM version Build Status

Dependency Status devDependency Status peerDependency Status

iCheck components built with React. No jQuery and Zepto

Online demo: http://luqin.github.io/react-icheck

Note: React-iCheck still in development

Skins

Features

  • Identical inputs across different browsers and devices — both desktop and mobile
  • Touch devices support — iOS, Android, BlackBerry, Windows Phone, Amazon Kindle
  • Keyboard accessible inputsTab, Spacebar, Arrow up/down and other shortcuts
  • Customization freedom — use any HTML and CSS to style inputs (try 6 Retina-ready skins)
  • No jQuery and Zepto
  • Screenreader accessible inputsARIA attributes for VoiceOver and others
  • Lightweight size

By default, iCheck doesn't provide any CSS styles for wrapper divs (if you don't use skins).

Usage

npm install react-icheck icheck --save
import 'icheck/skins/all.css'; // or single skin css

import {Checkbox, Radio} from 'react-icheck';

// Checkbox with label
<Checkbox
  checkboxClass="icheckbox_square-blue"
  increaseArea="20%"
  label="Checkbox"
/>

// without label
<Checkbox
  id="checkbox1"
  checkboxClass="icheckbox_square-blue"
  increaseArea="20%"
/>
<label htmlFor="checkbox1">First name</label>

// Radio
<Radio
  name="aa"
  radioClass="iradio_square-blue"
  increaseArea="20%"
  label="Radio"
/>
import {Radio, RadioGroup} from 'react-icheck';

<RadioGroup name="radio" value="3">
    <Radio
      value="3"
      radioClass="iradio_square-blue"
      increaseArea="20%"
      label="Radio, <span class='label1'>#input-3</span>"
    />
    <Radio
      value="4"
      radioClass="iradio_square-blue"
      increaseArea="20%"
      label="Radio, <span class='label1'>#input-4</span>"
    />
    <Radio
      value="5"
      radioClass="iradio_square-blue"
      increaseArea="20%"
      label="Radio, <span class='label1'>#disabled</span>"
      disabled
    />
</RadioGroup>

More examples: Online demo, Source

Browser support

iCheck is verified to work in Internet Explorer 6+, Firefox 2+, Opera 9+, Google Chrome and Safari browsers. Should also work in many others.

Mobile browsers (like Opera mini, Chrome mobile, Safari mobile, Android browser, Silk and others) are also supported. Tested on iOS (iPad, iPhone, iPod), Android, BlackBerry and Windows Phone devices.

Contribute

Dev base on react-component-tools

$ git clone https://github.com/luqin/react-icheck.git
$ cd react-icheck
$ npm install
$ npm start # Run the docs site in development mode. This will watch for file changes as you work. And auto refresh the page to see the updates.

react-icheck's People

Contributors

alex-e-leon avatar digital-flowers avatar emmaysebaert avatar isomoar avatar janpieterz avatar jooj123 avatar luqin avatar manosim avatar oliverlaz avatar omgaz avatar vramana avatar zagitta avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.