@adactive/arc-qrcode
Adsum QrCode Component
Last updated a year ago by clientadactive .
UNLISENCED · Repository · Bugs · Original npm · Tarball · package.json
$ cnpm install @adactive/arc-qrcode 
SYNC missed versions from official npm registry.

QrCode component

Getting started

    npm i --save @adactive/arc-qrcode

OR

    yarn add @adactive/arc-qrcode

Usage

    import AdsumQrCode, { modes, ecLevel } from '@adactive/arc-qrcode';
    ...
    state = {
        openModal: false
    }
    
    onOpenModal = () => {
        this.setState({ openModal: true });
    };
    
    onCloseModal = () => {
        this.setState({ openModal: false });
    };
    
    const qrCodeOptions = {
        size: 400,
        ecLevel: ecLevel.QUARTILE,
        minVersion: 8,
        background: '#fff',
        mode: modes.DRAW_WITH_IMAGE_BOX,
        radius: 0.5,
        image: 'https://raw.githubusercontent.com/AdactiveSAS/adsum-react-components/master/logo.jpg',
        mSize: 0.15,
    };
    
    <button onClick={this.onOpenModal}>Open QrCode Modal</button>
    
    <AdsumQrCode
        isOpen={this.state.openModal}
        onClose={this.onCloseModal}
        qrCodeOptions={qrCodeOptions}
        text="https://adactive.com"
    />

Props

type PropsType = {|
    +isOpen: boolean,
    +onClose: () => null,
    +text: string,
    +qrCodeOptions: Object,
    +ModalProps?: Object,
    +qrCodeCSS?: CSSStyleDeclaration
|};

static defaultProps = {
    isOpen: false,
    onClose: () => null,
    text: '',
    qrCodeOptions: {},
    ModalProps: {},
};

isOpen -> To show or hide qrCode component

onClose -> A callback function to close the qrCode component

text -> Url value to be embedded into qrcode

qrCodeOptions -> Refer to qrcode.es for more information

ModalProps -> Refer to react-responsive-modal for more information

qrCodeCSS -> To customise CSS for the qrCode canvas

Copy component inside your project src folder

Less only

`npx @adactive/arc-qrCode copy --less-only`

Full copy

`npx @adactive/arc-qrCode copy`

Current Tags

  • 2.5.3                                ...           latest (a year ago)

68 Versions

  • 2.5.3                                ...           a year ago
  • 2.5.1                                ...           a year ago
  • 2.5.0                                ...           a year ago
  • 2.4.0                                ...           a year ago
  • 2.3.0                                ...           a year ago
  • 2.2.0                                ...           a year ago
  • 2.2.0-rc.4                                ...           a year ago
  • 2.2.0-rc.3                                ...           a year ago
  • 2.2.0-rc.2                                ...           a year ago
  • 2.2.0-rc.1                                ...           a year ago
  • 2.2.0-rc.0                                ...           a year ago
  • 2.2.0-alpha.1                                ...           a year ago
  • 2.2.0-alpha.0                                ...           a year ago
  • 2.1.0                                ...           2 years ago
  • 2.1.0-rc.1                                ...           2 years ago
  • 2.1.0-rc.0                                ...           2 years ago
  • 2.1.0-alpha.1                                ...           2 years ago
  • 2.1.0-alpha.0                                ...           2 years ago
  • 2.0.0                                ...           2 years ago
  • 2.0.0-rc.0                                ...           2 years ago
  • 2.0.0-alpha.6                                ...           2 years ago
  • 2.0.0-alpha.5                                ...           2 years ago
  • 2.0.0-alpha.4                                ...           2 years ago
  • 2.0.0-alpha.3                                ...           2 years ago
  • 2.0.0-alpha.2                                ...           2 years ago
  • 2.0.0-alpha.1                                ...           2 years ago
  • 2.0.0-alpha.0                                ...           2 years ago
  • 1.1.0                                ...           2 years ago
  • 1.1.0-rc2                                ...           2 years ago
  • 1.1.0-alpha.0                                ...           2 years ago
  • 1.0.0                                ...           2 years ago
  • 0.0.2-y.44.59                                ...           2 years ago
  • 0.0.2-y.44.58                                ...           2 years ago
  • 0.0.2-y.44.57                                ...           2 years ago
  • 0.0.2-y.44.56                                ...           2 years ago
  • 0.0.2-y.44.55                                ...           2 years ago
  • 0.0.2-y.44.54                                ...           2 years ago
  • 0.0.2-y.44.53                                ...           2 years ago
  • 0.0.2-y.44.52                                ...           2 years ago
  • 0.0.2-y.44.51                                ...           2 years ago
  • 0.0.2-y.44.50                                ...           2 years ago
  • 0.0.2-y.44.49                                ...           2 years ago
  • 0.0.2-y.44.48                                ...           2 years ago
  • 0.0.2-y.44.47                                ...           2 years ago
  • 0.0.2-y.44.46                                ...           2 years ago
  • 0.0.2-y.44.45                                ...           2 years ago
  • 0.0.2-y.44.44                                ...           2 years ago
  • 0.0.2-y.44.43                                ...           2 years ago
  • 0.0.2-y.44.42                                ...           2 years ago
  • 0.0.2-y.44.41                                ...           2 years ago
  • 0.0.2-y.44.40                                ...           2 years ago
  • 0.0.2-y.44.39                                ...           2 years ago
  • 0.0.2-y.44.37                                ...           2 years ago
  • 0.0.2-y.44.36                                ...           2 years ago
  • 0.0.2-y.44.35                                ...           2 years ago
  • 0.0.2-y.44.34                                ...           2 years ago
  • 0.0.2-y.44.33                                ...           2 years ago
  • 0.0.2-y.44.32                                ...           2 years ago
  • 0.0.2-y.44.31                                ...           2 years ago
  • 0.0.2-y.44.30                                ...           2 years ago
  • 0.0.2-y.44.29                                ...           2 years ago
  • 0.0.2-y.44.28                                ...           2 years ago
  • 0.0.2-y.44.27                                ...           2 years ago
  • 0.0.2-y.44.26                                ...           2 years ago
  • 0.0.2-y.44.25                                ...           2 years ago
  • 0.0.2-y.44.24                                ...           2 years ago
  • 0.0.2-y.44.23                                ...           2 years ago
  • 0.0.2-y.44.22                                ...           2 years ago
Downloads
Today 0
This Week 0
This Month 0
Last Day 0
Last Week 68
Last Month 205
Dependencies (4)
Dev Dependencies (2)
Dependents (0)
None

Copyright 2014 - 2016 © taobao.org |