Skip to content

Commit

Permalink
Merge pull request #12 from synapsestudios/prop-types-update
Browse files Browse the repository at this point in the history
Update React.PropTypes to standalone prop-types package
  • Loading branch information
chrisheninger authored Apr 28, 2017
2 parents 37612a1 + 4eb7fc0 commit 5e37d69
Show file tree
Hide file tree
Showing 5 changed files with 368 additions and 309 deletions.
4 changes: 2 additions & 2 deletions .lintstagedrc
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"{src, storybook}/**/*.js": [
"precommit-lint",
"precommit-prettier",
"eslint",
"prettier --single-quote --trailing-comma es5 --write",
"git add"
]
}
75 changes: 40 additions & 35 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@synapsestudios/react-drop-n-crop",
"version": "0.1.0",
"version": "0.2.0",
"description": "A combined implementation of react-dropzone and react-cropper",
"repository": {
"type": "git",
Expand All @@ -12,52 +12,57 @@
"author": "Synapse Studios",
"license": "MIT",
"main": "lib/index.js",
"keywords": [
"react",
"javascript",
"drop-n-crop",
"dropzone",
"cropper",
"react-cropper",
"image-cropper"
],
"scripts": {
"clean": "rm -rf lib && rm -rf .out",
"build": "npm run clean && babel src -d lib && npm run build-stylus",
"build-stylus": "stylus styles/index.styl -o lib/react-drop-n-crop.css && stylus styles/index.styl -c -u autoprefixer-stylus -o lib/react-drop-n-crop.min.css && cp styles/index.styl lib/react-drop-n-crop.styl",
"precommit": "lint-staged",
"prepublish": "eslint src && npm run build",
"start": "npm run storybook",
"storybook": "stylus -w styles/index.styl -u autoprefixer-stylus -c -o styles/index.css & start-storybook -p 5000 -s storybook",
"storybook-build": "stylus styles/index.styl -u autoprefixer-stylus -c -o styles/index.css && build-storybook -s storybook -o .out",
"storybook-deploy": "npm run storybook-build && storybook-to-ghpages"
},
"dependencies": {
"classnames": "2.2.5",
"lodash.includes": "4.3.0",
"react-cropper": "0.10.0",
"react-dropzone": "3.12.2"
"classnames": "^2.2.5",
"lodash.includes": "^4.3.0",
"prop-types": "^15.5.8",
"react-cropper": "^0.12.0",
"react-dropzone": "^3.13.0"
},
"devDependencies": {
"@kadira/storybook": "^2.35.3",
"@kadira/storybook-deployer": "^1.2.0",
"autoprefixer-stylus": "^0.13.0",
"babel-cli": "^6.24.0",
"babel-eslint": "^7.1.1",
"babel-plugin-transform-class-properties": "^6.23.0",
"babel-cli": "^6.24.1",
"babel-eslint": "^7.2.3",
"babel-plugin-transform-class-properties": "^6.24.1",
"babel-plugin-transform-object-rest-spread": "^6.23.0",
"babel-plugin-transform-react-jsx": "^6.23.0",
"babel-preset-es2015": "^6.24.0",
"eslint": "^3.16.1",
"babel-plugin-transform-react-jsx": "^6.24.1",
"babel-preset-es2015": "^6.24.1",
"eslint": "^3.19.0",
"eslint-config-react-app": "^0.6.2",
"eslint-loader": "^1.6.3",
"eslint-plugin-flowtype": "^2.21.0",
"eslint-plugin-import": "^2.0.1",
"eslint-loader": "^1.7.1",
"eslint-plugin-flowtype": "^2.32.1",
"eslint-plugin-import": "^2.2.0",
"eslint-plugin-jsx-a11y": "^4.0.0",
"eslint-plugin-react": "^6.4.1",
"husky": "^0.13.2",
"eslint-plugin-react": "^6.10.3",
"husky": "^0.13.3",
"lint-staged": "^3.4.0",
"prettier": "^0.22.0",
"prettier": "^1.2.2",
"stylus": "^0.54.5"
},
"peerDependencies": {
"react": "^15.0.0",
"react-dom": "^15.0.0"
},
"scripts": {
"clean": "rm -rf lib && rm -rf .out",
"build": "npm run clean && babel src -d lib && npm run build-stylus",
"build-stylus": "stylus styles/index.styl -o lib/react-drop-n-crop.css && stylus styles/index.styl -c -u autoprefixer-stylus -o lib/react-drop-n-crop.min.css && cp styles/index.styl lib/react-drop-n-crop.styl",
"lint": "eslint src",
"precommit": "lint-staged",
"precommit-lint": "eslint",
"precommit-prettier": "prettier --single-quote --trailing-comma all --write",
"prepublish": "npm run lint && npm run build",
"start": "npm run storybook",
"storybook": "npm run storybook-watch-stylus & start-storybook -p 5000 -s storybook",
"storybook-watch-stylus": "stylus -w styles/index.styl -u autoprefixer-stylus -c -o styles/index.css",
"storybook-build": "npm run storybook-build-stylus && build-storybook -s storybook -o .out",
"storybook-build-stylus": "stylus styles/index.styl -u autoprefixer-stylus -c -o styles/index.css",
"storybook-deploy": "npm run storybook-build && storybook-to-ghpages"
"react": "^15.3.0",
"react-dom": "^15.3.0"
}
}
3 changes: 2 additions & 1 deletion src/DropNCrop.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
/* global FileReader */
import React, { Component, PropTypes } from 'react';
import React, { Component } from 'react';
import PropTypes from 'prop-types';
import classNames from 'classnames';
import Cropper from 'react-cropper';
import Dropzone from 'react-dropzone';
Expand Down
17 changes: 11 additions & 6 deletions storybook/stories/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -8,12 +8,17 @@ storiesOf('<DropNCrop />', module).add('setState Example (default)', () => (
<div>
<style>
{
`html {
box-sizing: border-box;
}
*, *:before, *:after {
box-sizing: inherit;
}`
`
html {
box-sizing: border-box;
}
*, *:before, *:after {
box-sizing: inherit;
}
body {
font-family: -apple-system, ".SFNSText-Regular", "San Francisco", "Roboto", "Segoe UI", "Helvetica Neue", "Lucida Grande", sans-serif;
}
`
}
</style>
<SetStateExample />
Expand Down
Loading

0 comments on commit 5e37d69

Please sign in to comment.