Skip to content

Commit

Permalink
Initial commit with contributors
Browse files Browse the repository at this point in the history
v0.1.3

lintfix

tests

ready

test-watch
  • Loading branch information
usulpro committed Sep 9, 2016
1 parent bac0298 commit ccf1f53
Show file tree
Hide file tree
Showing 21 changed files with 1,029 additions and 84 deletions.
1 change: 1 addition & 0 deletions .eslintignore
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
colors.js
17 changes: 0 additions & 17 deletions .eslintrc

This file was deleted.

3 changes: 3 additions & 0 deletions .npmignore
Original file line number Diff line number Diff line change
@@ -1,2 +1,5 @@
.scripts
.storybook
src
.babelrc
*.log
3 changes: 3 additions & 0 deletions .scripts/lint.cmd
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
@echo off
call .\node_modules\.bin\eslint %1 --ext .jsx --ext .js %2
rem Please no errors
9 changes: 9 additions & 0 deletions .scripts/prepublish.cmd
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
@echo off
echo Transpiling 'src' into ES5 ...
echo ...
if exist dist (
rem rmdir /S /Q dist
)
call .\node_modules\.bin\babel --ignore tests,stories --plugins "transform-runtime" ./src --out-dir ./dist
echo ...
echo Transpiling completed.
43 changes: 43 additions & 0 deletions .scripts/publish_storybook.cmd
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
@echo off

setlocal enabledelayedexpansion

set GIT_URL_CMD=git config --get remote.origin.url
for /F "usebackq delims=" %%v in (`%GIT_URL_CMD%`) do set GIT_URL=%%v

if %GIT_URL%=="" (
echo This project is not configured with a remote git repo
exit 1
)

if exist .out (
rmdir /S /Q .out
)

md .out

call build-storybook -o .out

cd .out

git init
git config user.name "GH Pages Bot"
git config user.email "[email protected]"
git add .
git commit -m "Deploy Storybook to GitHub Pages"
git push --force --quiet !GIT_URL! master:gh-pages

cd ..
rmdir /S /Q .out

set GHP_URL_CMD=node .scripts/get_gh_pages_url.js !GIT_URL!
for /F "usebackq delims=" %%w in (`%GHP_URL_CMD%`) do set GHP_URL=%%w

echo ## Deploy >storybook.md
echo Storybook deployed to: [!GHP_URL!](!GHP_URL!)>>storybook.md

echo .
echo Storybook deployed to: !GHP_URL!
echo See the %cd%\storybook.md

endlocal
1 change: 1 addition & 0 deletions .scripts/test-watch.cmd
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
e:\Develop\NodeJS\cmder\vendor\git-for-windows\usr\bin\mintty.exe /bin/bash -l
4 changes: 4 additions & 0 deletions .scripts/test-watch.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
#!/bin/bash

./node_modules/.bin/mocha --require .scripts/mocha_runner src/**/tests/**/*.js --watch --watch-extensions jsx

4 changes: 4 additions & 0 deletions .scripts/test.cmd
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
@echo off
call .\node_modules\.bin\mocha --require .scripts/mocha_runner src/**/tests/**/*.js
rem Please no errors

16 changes: 16 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,19 @@
# React Material Color Picker Component

React Material Color Picker Component

## Install

$ npm i react-material-color-picker --save

## Usage

~~~
import React from 'react';
import MaterialColorPicker from 'react-material-color-picker';
<div>
<MaterialColorPicker />
</div>
~~~

1 change: 1 addition & 0 deletions mochacfg.js
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
require.extensions['.png'] = function(){ return null; }
28 changes: 19 additions & 9 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,21 +1,31 @@
{
"name": "react-material-color-picker",
"version": "0.0.0",
"version": "0.9.2",
"description": "React Material Color Picker Component",
"repository": {
"type": "git",
"url": "https://github.com/you/repo.git"
"url": "https://[email protected]/sm-artlight/react-material-color-picker.git"
},
"keywords": [
"React",
"Material",
"Color",
"Picker",
"Component"
],
"author": "UsulPro",
"license": "MIT",
"homepage": "https://bitbucket.org/sm-artlight/react-material-color-picker#readme",
"scripts": {
"prepublish": ". ./.scripts/prepublish.sh",
"lint": "eslint src",
"lintfix": "eslint src --fix",
"testonly": "mocha --require .scripts/mocha_runner src/**/tests/**/*.js",
"publish-storybook": ".scripts\\publish_storybook.cmd",
"prepublish": ".scripts\\prepublish.cmd",
"lint": ".scripts\\lint.cmd src",
"lintfix": ".scripts\\lint.cmd src --fix",
"testonly": ".scripts\\test.cmd",
"test": "npm run lint && npm run testonly",
"test-watch": "npm run testonly -- --watch --watch-extensions js",
"test-watch": "bash .scripts\\test-watch.sh",
"storybook": "start-storybook -p 9010",
"publish-storybook": "bash .scripts/publish_storybook.sh"
"start": "start-storybook -p 9001"
},
"devDependencies": {
"react": "^15.0.0",
Expand Down Expand Up @@ -53,7 +63,7 @@
"dependencies": {
"babel-runtime": "^6.5.0"
},
"main": "dist/index.js",
"main": "dist/MaterialColorPicker.js",
"engines": {
"npm": "^3.0.0"
}
Expand Down
Loading

0 comments on commit ccf1f53

Please sign in to comment.