grayscaleBody.js
Automatically turn the site to grayscale (may be used for some purpose)
Install
1: npm
1.1 Install npm
1.2 Install package: `npm install --save grayscale-body-js`
2: bower
2.1 Install npm
2.2 Install bower: `npm install -g bower`
2.3 Install package: `bower install --save grayscale-body-js`
Getting Started for dev
- Install Node.js
- Set path (e.g.
cd C:\xampp\htdocs\jojoee.com\grayscale-body-js
) - Install global:
npm install -g gulp bower browser-sync
- Install dependencies:
bower install && npm install
- Start:
gulp
to build and gulp watch
to dev
Usage
// init
var option = {
switcherPosition: 'bottom-right', // string: top-left, top-right, bottom-left, bottom-right
isEnableSwitcher: true, // boolean
isDebug: true, // boolean
};
var gsb = new GrayscaleBody(option);
// event
gsb.on('onSwitchersClicked', function() {
console.log('onSwitchersClicked - callback 1');
});
Feature
- Grayscale / Color switcher (for non-IE)
- 4 switcher positions
- Compatible with all browsers:
Note
TODO
Thank you