signature_pad
Advanced tools
Comparing version 4.0.9 to 4.0.10
/*! | ||
* Signature Pad v4.0.9 | https://github.com/szimek/signature_pad | ||
* Signature Pad v4.0.10 | https://github.com/szimek/signature_pad | ||
* (c) 2022 Szymon Nowak | Released under the MIT license | ||
@@ -4,0 +4,0 @@ */ |
/*! | ||
* Signature Pad v4.0.9 | https://github.com/szimek/signature_pad | ||
* Signature Pad v4.0.10 | https://github.com/szimek/signature_pad | ||
* (c) 2022 Szymon Nowak | Released under the MIT license | ||
@@ -4,0 +4,0 @@ */ |
/*! | ||
* Signature Pad v4.0.9 | https://github.com/szimek/signature_pad | ||
* Signature Pad v4.0.10 | https://github.com/szimek/signature_pad | ||
* (c) 2022 Szymon Nowak | Released under the MIT license | ||
@@ -4,0 +4,0 @@ */ |
/*! | ||
* Signature Pad v4.0.9 | https://github.com/szimek/signature_pad | ||
* Signature Pad v4.0.10 | https://github.com/szimek/signature_pad | ||
* (c) 2022 Szymon Nowak | Released under the MIT license | ||
@@ -4,0 +4,0 @@ */ |
@@ -1,2 +0,2 @@ | ||
export declare class SignatureEventTarget implements EventTarget { | ||
export declare class SignatureEventTarget { | ||
private _et; | ||
@@ -3,0 +3,0 @@ constructor(); |
const wrapper = document.getElementById("signature-pad"); | ||
const clearButton = wrapper.querySelector("[data-action=clear]"); | ||
const changeColorButton = wrapper.querySelector("[data-action=change-color]"); | ||
const changeWidthButton = wrapper.querySelector("[data-action=change-width]"); | ||
const undoButton = wrapper.querySelector("[data-action=undo]"); | ||
@@ -99,2 +100,10 @@ const savePNGButton = wrapper.querySelector("[data-action=save-png]"); | ||
changeWidthButton.addEventListener("click", () => { | ||
const min = Math.round(Math.random() * 100) / 10; | ||
const max = Math.round(Math.random() * 100) / 10; | ||
signaturePad.minWidth = Math.min(min, max); | ||
signaturePad.maxWidth = Math.max(min, max); | ||
}); | ||
savePNGButton.addEventListener("click", () => { | ||
@@ -101,0 +110,0 @@ if (signaturePad.isEmpty()) { |
/*! | ||
* Signature Pad v4.0.9 | https://github.com/szimek/signature_pad | ||
* Signature Pad v4.0.10 | https://github.com/szimek/signature_pad | ||
* (c) 2022 Szymon Nowak | Released under the MIT license | ||
@@ -4,0 +4,0 @@ */ |
{ | ||
"name": "signature_pad", | ||
"description": "Library for drawing smooth signatures.", | ||
"version": "4.0.9", | ||
"version": "4.0.10", | ||
"homepage": "https://github.com/szimek/signature_pad", | ||
@@ -39,31 +39,31 @@ "author": { | ||
"devDependencies": { | ||
"@rollup/plugin-typescript": "^8.3.4", | ||
"@rollup/plugin-typescript": "^9.0.1", | ||
"@semantic-release/changelog": "^6.0.1", | ||
"@semantic-release/commit-analyzer": "^9.0.2", | ||
"@semantic-release/git": "^10.0.1", | ||
"@semantic-release/github": "^8.0.5", | ||
"@semantic-release/github": "^8.0.6", | ||
"@semantic-release/npm": "^9.0.1", | ||
"@semantic-release/release-notes-generator": "^10.0.3", | ||
"@types/jest": "^28.1.6", | ||
"@types/node": "^18.6.2", | ||
"@typescript-eslint/eslint-plugin": "^5.31.0", | ||
"@typescript-eslint/parser": "^5.31.0", | ||
"@types/jest": "^29.1.2", | ||
"@types/node": "^18.8.4", | ||
"@typescript-eslint/eslint-plugin": "^5.40.0", | ||
"@typescript-eslint/parser": "^5.40.0", | ||
"cp-cli": "^2.0.0", | ||
"del": "^7.0.0", | ||
"del-cli": "^5.0.0", | ||
"eslint": "^8.20.0", | ||
"eslint": "^8.25.0", | ||
"eslint-config-prettier": "^8.5.0", | ||
"husky": "^8.0.1", | ||
"jest": "^28.1.3", | ||
"jest": "^29.1.2", | ||
"jest-canvas-mock": "^2.4.0", | ||
"jest-environment-jsdom": "^28.1.3", | ||
"jest-environment-jsdom": "^29.1.2", | ||
"lint-staged": "^13.0.3", | ||
"prettier": "^2.7.1", | ||
"rollup": "^2.77.2", | ||
"rollup": "^3.0.0", | ||
"rollup-plugin-terser": "^7.0.2", | ||
"semantic-release": "^19.0.3", | ||
"semantic-release": "^19.0.5", | ||
"serve": "^14.0.1", | ||
"ts-jest": "^28.0.7", | ||
"ts-jest": "^29.0.3", | ||
"tslib": "^2.4.0", | ||
"typescript": "^4.7.4" | ||
"typescript": "~4.8.4" | ||
}, | ||
@@ -70,0 +70,0 @@ "lint-staged": { |
@@ -1,2 +0,2 @@ | ||
export class SignatureEventTarget implements EventTarget { | ||
export class SignatureEventTarget { | ||
/* tslint:disable: variable-name */ | ||
@@ -3,0 +3,0 @@ private _et: EventTarget; |
Sorry, the diff of this file is not supported yet
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
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
234897
2937