Important: This documentation covers Yarn 1 (Classic).
For Yarn 2+ docs and migration guide, see yarnpkg.com.

Package detail

@futurejj/react-native-checkbox

JairajJangle924MIT1.0.3TypeScript support: included

A papery checkbox for react native

react-native, checkbox, animated-checkbox, react-native-component, ui-component, cross-platform, accessibility, typescript, expo, react-native-ui, mobile-ui, customizable-checkbox, animation, ios, android, web, material-design, form-component, react-native-paper, vector-icons

readme

@futurejj/react-native-checkbox

A papery checkbox for react native

npm version GitHub license Workflow Status Android iOS Web GitHub issues TS Expo Snack npm bundle size

A beautiful, customizable, and animated checkbox component for React Native applications. This component works across iOS, Android, and Web platforms with smooth animations and accessibility support.

React Native Animated Checkbox Demo

Features

  • ✨ Beautiful animations on state changes
  • 🎨 Fully customizable colors and styling
  • 📱 Cross-platform (iOS, Android, Web)
  • 🔄 Three states: checked, unchecked, and indeterminate
  • ♿ Accessibility support built-in
  • 📏 Customizable size for various design needs
  • 🔌 Works with Expo and standard React Native
  • 🔍 TypeScript support with full type definitions

Installation

yarn add @futurejj/react-native-checkbox
# or
npm install @futurejj/react-native-checkbox

Icon Dependencies

This component uses Material Community Icons. You'll need to install either:

  • @expo/vector-icons (if using Expo - built-in)
  • react-native-vector-icons (if using React Native CLI - follow the installation instructions for react-native-vector-icons)

Usage

Basic Example

import React, { useState } from 'react';
import { View } from 'react-native';
import { Checkbox } from '@futurejj/react-native-checkbox';

export default function CheckboxExample() {
  const [checked, setChecked] = useState(false);

  const toggleCheckbox = () => {
    setChecked(!checked);
  };

  return (
    <View style={{ padding: 20 }}>
      <Checkbox
        status={checked ? 'checked' : 'unchecked'}
        onPress={toggleCheckbox}
      />
    </View>
  );
}

Customization

<Checkbox
  status="checked" // 'checked', 'unchecked', or 'indeterminate'
  disabled={false} // disable the checkbox
  onPress={() => {}} // handle press events
  color="#6200ee" // color when checked
  uncheckedColor="#757575" // color when unchecked
  size={32} // customize size (default: 24)
  style={{ marginRight: 8 }} // additional styles for the container
/>

API Reference

Props

Prop Type Default Description
status 'checked' OR 'unchecked' OR 'indeterminate' Required Current status of the checkbox
disabled boolean false Whether the checkbox is disabled
onPress (e: GestureResponderEvent) => void Required Callback when checkbox is pressed
color string '#2196F3' Color of the checkbox when checked
uncheckedColor string '#757575' Color of the checkbox when unchecked
size number 24 Size of the checkbox icon
testID string - Test ID for testing frameworks
style StyleProp<ViewStyle> - Additional styles for container

Animation

The checkbox includes smooth animations:

  • Scale animation when transitioning between states
  • Custom border animation for a more engaging interaction

Accessibility

This component is built with accessibility in mind:

  • Proper role assignment (checkbox)
  • Correct states reported to screen readers
  • Live region updates for dynamic changes

Contributing

See the contributing guide to learn how to contribute to the repository and the development workflow.

License

MIT


🙏 Support the project

LiberPay_Donation_Button           Paypal_Donation_Button           Paypal_Donation_Button

❤️ Thanks to

changelog

1.0.3 (2025-05-26)

Bug Fixes

  • improper yarn package manager installation for contrib (46adcb5)

1.0.2 (2025-05-11)

Bug Fixes

  • replaced old package name in readme (82cfbf3)

1.0.1 (2025-05-10)

Bug Fixes

  • updated package keyword list (ef5af44)

1.0.0 (2025-05-10)

  • feat!: major release BREAKING CHANGE: version bump (013f7cf)

BREAKING CHANGES

  • version bump

0.4.0 (2025-05-10)

Features

0.3.0 (2025-05-10)

Features

  • setup ci based npm publish job (07ca078)