{"id":18709098,"url":"https://github.com/jojoee/grayscale-body-js","last_synced_at":"2025-06-18T07:33:37.870Z","repository":{"id":57253838,"uuid":"71627814","full_name":"jojoee/grayscale-body-js","owner":"jojoee","description":":pray: Automatically turn the site to grayscale (may be used for some purpose)","archived":false,"fork":false,"pushed_at":"2018-12-18T09:08:52.000Z","size":341,"stargazers_count":3,"open_issues_count":1,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-05-19T08:11:30.355Z","etag":null,"topics":["grayscale"],"latest_commit_sha":null,"homepage":"https://jojoee.github.io/grayscale-body-js/","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/jojoee.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2016-10-22T08:53:10.000Z","updated_at":"2021-11-08T10:16:15.000Z","dependencies_parsed_at":"2022-08-31T00:01:35.894Z","dependency_job_id":null,"html_url":"https://github.com/jojoee/grayscale-body-js","commit_stats":null,"previous_names":[],"tags_count":1,"template":false,"template_full_name":null,"purl":"pkg:github/jojoee/grayscale-body-js","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jojoee%2Fgrayscale-body-js","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jojoee%2Fgrayscale-body-js/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jojoee%2Fgrayscale-body-js/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jojoee%2Fgrayscale-body-js/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/jojoee","download_url":"https://codeload.github.com/jojoee/grayscale-body-js/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jojoee%2Fgrayscale-body-js/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":260511873,"owners_count":23020292,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["grayscale"],"created_at":"2024-11-07T12:26:16.749Z","updated_at":"2025-06-18T07:33:32.856Z","avatar_url":"https://github.com/jojoee.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# grayscaleBody.js\n[![Bower Version](https://img.shields.io/bower/v/grayscale-body-js.svg)](https://bower.io/search/?q=grayscale-body-js) [![Npm Version](https://img.shields.io/npm/v/grayscale-body-js.svg)](https://www.npmjs.com/package/grayscale-body-js) [![Release Version](https://img.shields.io/github/release/jojoee/grayscale-body-js.svg)](https://github.com/jojoee/grayscale-body-js/releases) [![Downloads](https://img.shields.io/npm/dt/grayscale-body-js.svg)](https://github.com/jojoee/grayscale-body-js/archive/master.zip)\n\nAutomatically turn the site to grayscale (may be used for some purpose)\n\n[![grayscaleBody.js - screenshot 1](https://raw.githubusercontent.com/jojoee/grayscale-body-js/master/screenshot/screenshot-1.gif \"grayscaleBody.js - screenshot 1\")](http://jojoee.github.io/grayscale-body-js/)\n\n## Install\n1: npm\n```\n1.1 Install npm\n1.2 Install package: `npm install --save grayscale-body-js`\n```\n2: bower\n```\n2.1 Install npm\n2.2 Install bower: `npm install -g bower`\n2.3 Install package: `bower install --save grayscale-body-js`\n```\n\n## Getting Started for dev\n1. Install [Node.js](https://nodejs.org/en/)\n2. Set path (e.g. `cd C:\\xampp\\htdocs\\jojoee.com\\grayscale-body-js`)\n3. Install global: `npm install -g gulp bower browser-sync`\n4. Install dependencies: `bower install \u0026\u0026 npm install`\n5. Start: `gulp` to build and `gulp watch` to dev\n\n## Usage\n```\n// init\nvar option = {\n  switcherPosition: 'bottom-right', // string: top-left, top-right, bottom-left, bottom-right\n  isEnableSwitcher: true,           // boolean\n  isDebug: true,                    // boolean\n};\n\nvar gsb = new GrayscaleBody(option);\n\n// event\ngsb.on('onSwitchersClicked', function() {\n  console.log('onSwitchersClicked - callback 1');\n});\n```\n\n## Feature\n- Grayscale / Color switcher (for non-IE)\n- 4 switcher positions\n- Compatible with all browsers:\n  - [Google Chrome](https://www.google.com/chrome/) 19+\n  - [Mozilla Firefox](https://www.mozilla.org/firefox/) 3.5+\n  - [Safari](http://www.apple.com/safari/) 6+\n  - [Internet Explorer](https://www.microsoft.com/en-us/download/internet-explorer.aspx) 8-9\n  - [Opera](http://www.opera.com/) 11.5\n\n## Note\n- 2 spaces for indent\n\n# TODO\n- [ ] Support IE edge\n- [ ] DocBlockr\n- [ ] Grayscale opacity customizer\n- [ ] Unit test\n- [ ] Separate utilities function into another files\n- [ ] Add callback event when switcher button's triggered\n- [ ] Add [.npmignore](https://docs.npmjs.com/misc/developers)\n- [ ] Implement [ci.testling.com](https://ci.testling.com/)\n- [ ] Add E2E testing script by [Nightwatch.js](http://nightwatchjs.org/)\n- [ ] Localization\n- [ ] Update `demo` page\n\n## Thank you\n- [ ] [Unsplash It](https://unsplash.it/)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjojoee%2Fgrayscale-body-js","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fjojoee%2Fgrayscale-body-js","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjojoee%2Fgrayscale-body-js/lists"}