{"_id":"@bkbaalkrshna/switch-theme","_rev":"2-76c030de0a4fbc0a36fa8651c3617d87","name":"@bkbaalkrshna/switch-theme","dist-tags":{"latest":"0.1.3"},"versions":{"0.1.3":{"name":"@bkbaalkrshna/switch-theme","version":"0.1.3","description":"Easily handle themes in your website","browser":"./src/switch.js","repository":{"type":"git","url":"git+https://github.com/PuneetGopinath/switch-theme-js.git"},"keywords":["javascript","css","theme"],"author":{"name":"Puneet Gopinath"},"license":"LGPL-2.1-only","scripts":{"format:check":"prettier --check .","format":"prettier --write ."},"bugs":{"url":"https://github.com/PuneetGopinath/switch-theme-js/issues"},"homepage":"https://github.com/PuneetGopinath/switch-theme-js#readme","devDependencies":{"prettier":"^2.3.0"},"gitHead":"5d55876ea4d588b9dab12755befbef41c4dc5e9d","_id":"@bkbaalkrshna/switch-theme@0.1.3","_nodeVersion":"14.15.4","_npmVersion":"7.12.1","dist":{"integrity":"sha512-KD33bNeJVVpua/8zX1hknbZj4zjGdQwraFI1Y8PnhVuYgmnuyZuSWJNbT9l1KzMec0Nd4LpZWgE8eYOddeHNYA==","shasum":"674f85bd62684eec2a863fe2970f6498d0fac900","tarball":"https://registry.npmjs.org/@bkbaalkrshna/switch-theme/-/switch-theme-0.1.3.tgz","fileCount":8,"unpackedSize":39085,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.13\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJgr0fjCRA9TVsSAnZWagAADccP/2NCk6ZdsPRRq4RLdqKx\ncplzhrQpWm1cZ3Alszx5lbivcvC3fmOsUy74jg0DXnPccJ764Cb6t3+gr2uS\nyoiL35sOS60I99mrJiEYpQyFKYXFCBXeW3udZ0ERRoTVq2uHs7AlRvkkGaT+\nw/+0KOxK9ukov9FZMy3ksQNMGmH5A6zh8LGvScBRtUlQvub18d0C4yfhnfk/\nBm9Rs4CEKCKDLRQyfkh4tj52ETkv5KD9LVD/PWX0E1fKun74R4Dcs5qhrdfy\nwjcPBdR4fQtI35BI3DDnc48uvh2v5UEzoTbYsn/WQENOfZlRJe0aCfNWUzbA\nd1w2aumGElrfV3MXHGvpw30YluZZYKgQ6Col/nl6xLj9+8jPJsU6KPEXK07U\nvZ0+uXW1L5q1k6IrAKUIO7ZNVpg04wQeQ/YJrP+M2rWbwmMHeiYkh3+Z3njT\noFUVGUvgMD12DE3frt5ZHaeAsA1trCJHyWXbbqE6WMbo5sgT5vR4hBo78+bj\nHB1PM5UYlPxrmvnoefxcQWbamgkIPwZ6S1il3CY3nUpRCFDvfOV6dCRmxM6+\nOrjLO75dRKiJKvkdnNQ86f0U3gTQgXe1OHqIH5dciu/pr+EUaozxKf+Z95Fg\nILqGGrVX9RhQgydgeWyTwsEctDTHhJqWY1lbGWiEbJWuhoPGCUOWLZqYp9/s\nFQAw\r\n=TF+D\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIEYtbZwC00R+HMPfYf2Nl+/1MgZRQ5tsmVm/70S6ZR4kAiEApyRFJ9cSh5pHCKlwHfFLoWnSVRjZky8TJ/ampv0Ddxg="}]},"_npmUser":{"name":"puneetgopinath","email":"baalkrshna@gmail.com"},"directories":{},"maintainers":[{"name":"puneetgopinath","email":"baalkrshna@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/switch-theme_0.1.3_1622099939432_0.13669448170303533"},"_hasShrinkwrap":false}},"time":{"created":"2021-05-27T07:18:59.022Z","0.1.3":"2021-05-27T07:18:59.568Z","modified":"2022-04-04T19:18:40.853Z"},"maintainers":[{"name":"puneetgopinath","email":"baalkrshna@gmail.com"}],"description":"Easily handle themes in your website","homepage":"https://github.com/PuneetGopinath/switch-theme-js#readme","keywords":["javascript","css","theme"],"repository":{"type":"git","url":"git+https://github.com/PuneetGopinath/switch-theme-js.git"},"author":{"name":"Puneet Gopinath"},"bugs":{"url":"https://github.com/PuneetGopinath/switch-theme-js/issues"},"license":"LGPL-2.1-only","readme":"# switch-theme-js\n> Easily switch themes in your website\n\n[![GitHub stars](https://img.shields.io/github/stars/PuneetGopinath/switch-theme-js)](https://github.com/PuneetGopinath/switch-theme-js/stargazers)\n[![GitHub forks](https://img.shields.io/github/forks/PuneetGopinath/switch-theme-js)](https://github.com/PuneetGopinath/switch-theme-js/network)\n[![GitHub issues](https://img.shields.io/github/issues/PuneetGopinath/switch-theme-js)](https://github.com/PuneetGopinath/switch-theme-js/issues)\n![GitHub repo size](https://img.shields.io/github/repo-size/PuneetGopinath/switch-theme-js)\n![Lines of code](https://img.shields.io/tokei/lines/github/PuneetGopinath/switch-theme-js?label=total%20lines%20of%20code)\n[![Contributor Covenant](https://img.shields.io/badge/Contributor%20Covenant-2.0-4baaaa.svg)](https://github.com/PuneetGopinath/switch-theme-js/blob/main/.github/CODE_OF_CONDUCT.md)\n\n## Features\n- Themes switch without page reload\n- Many more features coming\n\n## Live demo\nSee [live demo](https://puneetgopinath.github.io/switch-theme-js/)\n\nClick on \"Dark theme\" refresh the page, you see the page is default now set to dark theme.\n\n## Contributing\nYou can find the contributing guidelines [here](https://github.com/PuneetGopinath/switch-theme-js/blob/main/.github/CONTRIBUTING.md)\n\n## FAQs\nThese are the frequently asked questions:\n\n### 1. What happens actually\nThis is a basic JS code, that stores the theme name in a cookie that stays for 10 days and adds the theme name to the class list of the body.\n\n### 2. How to design a theme?\nYou need to know CSS for that.\n\n1. Think of a cool theme name\n2. To select the theme in CSS, use `.theme_name` where `theme_name` is your theme name\n3. To add a button for user to switch the theme, use the html `a` tag e.g. `<a href=\"javascript:switchTheme('dark', 'white');\">Dark theme</a>`\n4. Add `onload=\"getTheme();\"` to your `body` tag\n5. Add `<script async defer src=\"https://cdn.jsdelivr.net/gh/PuneetGopinath/switch-theme-js@main/src/switch.js\"></script>` in the head tag.\n6. That's all, test it out in your website, or submit a bug report for us to Analyse it.\n\n### 3. Example html file\nThe [index.html](https://github.com/PuneetGopinath/switch-theme-js/blob/gh-pages/index.html) file shows an example.\n\n## Supporters\n👏 A big thank you goes to all the supporters of this project!\n\nYou prove that the switch-theme-js Action has some value for you!\n\n### Stargazers\n[![Stargazers for @PuneetGopinath/switch-theme-js](https://reporoster.com/stars/PuneetGopinath/switch-theme-js)](https://github.com/PuneetGopinath/switch-theme-js/stargazers)\n\n### Contributors\nThanks to all contributors again!\n\n[![GitHub Contributors Image](https://contrib.rocks/image?repo=PuneetGopinath/switch-theme-js)](https://github.com/PuneetGopinath/switch-theme-js/contributors)\n","readmeFilename":"README.md","users":{"puneetgopinath":true}}