test-ui-component

4.0.1 • Public • Published

@stackbyhq/stackby-apps-ui

Made with create-react-library

NPM JavaScript Style Guide

Features

  • configurable via props
  • Controllable state props and modular architecture
  • Flexible approach to data, with customisable functions
  • auto position
  • small bundle size

Installation and usage

npm install --save @stackbyhq/stackby-apps-ui

Select Usage

import React from 'react';
import { Toggle } from '@stackbyhq/stackby-apps-ui';

class App extends React.Components {
  state = {
    toggle: false,
  };

  handleChange = val => {
    this.setState({ toggle: val });
  };

  render() {
    const { toggle } = this.state;

    return (
       <Toggle
          isDisable={false}
          onchange={handleChange}
          value={toggle}
          variant='Primary' //Danger, Success
          size="L" // X, M
          label="my react toggle"
          isBackGround={true}
       />
    );
  }
}

Props

Common props you may want to specify include:

  • onChange - subscribe to change events
  • value - control the current value
  • isDisable - set disable
  • variant - set different variant EX: Primary, Danger and Success
  • size - set different size EX: X, M and L
  • label - set label
  • isBackGround - set backGround

License

MIT © Stackbydev

Readme

Keywords

none

Package Sidebar

Install

npm i test-ui-component

Weekly Downloads

0

Version

4.0.1

License

MIT

Unpacked Size

32.9 kB

Total Files

6

Last publish

Collaborators

  • hardik_jayani