a-simple-switch
Advanced tools
Comparing version 0.8.0 to 0.9.0
{ | ||
"name": "a-simple-switch", | ||
"version": "0.8.0", | ||
"version": "0.9.0", | ||
"description": "Vanilla JS/CSS Switch UI element", | ||
"main": "src/javascript/index.js", | ||
"files": [ | ||
"release", | ||
"src", | ||
"readme.md" | ||
], | ||
"scripts": { | ||
"test": "medusa", | ||
"test": "karma start --single-run", | ||
"manualTest": "http-server", | ||
"build": "gulp", | ||
@@ -34,11 +40,18 @@ "clean": "gulp clean", | ||
"gulp-sass": "^5.1.0", | ||
"gulp-typescript": "^6.0.0-alpha.1", | ||
"gulp-uglify": "^3.0.2", | ||
"gulp-webpack": "^1.5.0", | ||
"gulp-zip": "^5.1.0", | ||
"medusa-cli": "^0.5.5", | ||
"http-server": "^14.1.1", | ||
"jasmine-core": "^4.5.0", | ||
"karma": "^6.4.1", | ||
"karma-chrome-launcher": "^3.1.1", | ||
"karma-jasmine": "^5.1.0", | ||
"node-sass": "^7.0.1", | ||
"really-simple-args": "^1.1.1", | ||
"webpack": "^2.7.0", | ||
"webpack-stream": "^3.2.0" | ||
"ts-loader": "^9.3.0", | ||
"typescript": "^4.6.4", | ||
"webpack": "^5.72.0", | ||
"webpack-stream": "^7.0.0" | ||
} | ||
} |
@@ -13,16 +13,18 @@ # Simple Switch | ||
- Vanilla JS/CSS: doesn't require any outside library to function | ||
- Accessible: works properly with screenreaders and the ARIA spec | ||
- Performant: uses proper layering and transitioning to ensure high performance | ||
- Vanilla JS/CSS: doesn't require any outside library to function | ||
- Accessible: works properly with screenreaders and the ARIA spec | ||
- Performant: uses proper layering and transitioning to ensure high performance | ||
--- | ||
- [Installation](#installation) | ||
- [Installing the Javascript](#installing-the-javascript) | ||
- [Installing the CSS](#installing-the-css) | ||
- [Installing the SASS](#installing-the-sass) | ||
- [Creating a Simple Switch](#creating-a-simple-switch) | ||
- [Automatically Creating Switches](#automatically-creating-switches) | ||
- [Manually Creating Switches](#manually-creating-switches) | ||
- [SASS Variables](#sass-variables) | ||
- [Installation](#installation) | ||
- [Installing the Javascript](#installing-the-javascript) | ||
- [Installing the CSS](#installing-the-css) | ||
- [Installing the SASS](#installing-the-sass) | ||
- [Creating a Simple Switch](#creating-a-simple-switch) | ||
- [Automatically Creating Switches](#automatically-creating-switches) | ||
- [Manually Creating Switches](#manually-creating-switches) | ||
- [SASS Variables](#sass-variables) | ||
- [Controlling the switch via JavaScript](#controlling-the-switch-via-javascript) | ||
- [Contributing](#contributing) | ||
@@ -99,2 +101,3 @@ ## Installation | ||
Standard Switch: | ||
```HTML | ||
@@ -105,2 +108,3 @@ <input type="checkbox" name="my-checkbox" data-type="simple-switch" /> | ||
Material Switch: | ||
```HTML | ||
@@ -143,2 +147,3 @@ <input type="checkbox" name="my-checkbox" data-type="simple-switch" data-material="true" /> | ||
HTML: | ||
```HTML | ||
@@ -149,2 +154,3 @@ <input type="checkbox" name="my-checkbox" id="my-checkbox" /> | ||
Javascript: | ||
```Javascript | ||
@@ -177,5 +183,5 @@ let myCheckbox = document.getElementById("my-checkbox"); | ||
## Controlling the switch via Javascript | ||
## Controlling the switch via JavaScript | ||
The switch can be toggled via Javascript: | ||
The switch can be toggled via JavaScript: | ||
@@ -193,1 +199,14 @@ ```js | ||
``` | ||
## Contributing | ||
Feel free to send pull requests, issues, feature requests, etc. There is no | ||
SLA for responses on this repo, but I trying to respond to issues and PRs in a | ||
timely manner. | ||
When sending PRs please follow the Google TypeScript style guide | ||
([style guide link](https://google.github.io/styleguide/tsguide.html)) and try | ||
to add test coverage where possible. | ||
Most of the codebase and NPM commands (like `npm test`) should work | ||
out-of-the-box, but you will need Chrome installed to run headless tests. |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
Major refactor
Supply chain riskPackage has recently undergone a major refactor. It may be unstable or indicate significant internal changes. Use caution when updating to versions that include significant changes.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
36792
206
22
10
267
1