JSPM

react-scratch-easy

0.1.4
  • ESM via JSPM
  • ES Module Entrypoint
  • Export Map
  • Keywords
  • License
  • Repository URL
  • TypeScript Types
  • README
  • Created
  • Published
  • Downloads 11
  • Score
    100M100P100Q48931F
  • License MIT

Package Exports

  • react-scratch-easy

This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (react-scratch-easy) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.

Readme

Installation

$ npm install react-scratch-easy

import { ScratchImage } from 'react-scratch-easy';

<ScratchImage
    showReset={true}
    showConfirmText={true}
    showResetText={true}
    finishPercent={35}
    // onComplete={}
    //outerImageSrc='image src'
/>;

Props

Required Props

No Props Description Default
1 outerImageSrc image url for scratching area
2 onComplete requires a callback function none
2 finishPercent requires a number between 1 - 100 35

Optional Props

No Props Description Default
1 resetText can pass any text value Reset
2 confirmText can pass any text value Confirm
3 outerImageWH scratch image width and height width=100%, height=300px
4 innerImageWH inner image width and height width=200px, height=200px
5 showResetText Boolean true
6 showConfirmText Boolean true
7 confirmBtn can pass any button css none
8 resetBtn can pass any button css none