Socket
Socket
Sign inDemoInstall

signature_pad

Package Overview
Dependencies
Maintainers
1
Versions
57
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

signature_pad - npm Package Compare versions

Comparing version 1.6.0-beta.9 to 1.6.0

52

CHANGELOG.md
## Changelog
### 1.6.0-beta.1
* Added support for returning signature as SVG using `#fromDataURL('image/svg+xml')`. [jackspirou](https://github.com/jackspirou) [mymattcarroll](https://github.com/mymattcarroll) [szimek](https://github.com/szimek)
* Added `#toData` method that returns data points.
* Added `#fromData` method that draws signature from data points.
* Moved `signature_pad.js` and `signature_pad.min.js` files to `dist` folder.
### 1.6.0
* Added support for returning signature as SVG using `#fromDataURL('image/svg+xml')`. [jackspirou](https://github.com/jackspirou) [mymattcarroll](https://github.com/mymattcarroll) [szimek](https://github.com/szimek)
* Added `#toData` method that returns data points.
* Added `#fromData` method that draws signature from data points.
* Moved `signature_pad.js` and `signature_pad.min.js` files to `dist` folder.
### 1.5.3
* Fix `touchend` event on touch devices. (#150) [mtomic](https://github.com/mtomic)
* Fix handling touch events in Egde browser. (#134) [dideldum73](https://github.com/dideldum73)
* Fix `touchend` event on touch devices. (#150) [mtomic](https://github.com/mtomic)
* Fix handling touch events in Egde browser. (#134) [dideldum73](https://github.com/dideldum73)
### 1.5.2
* Prevent loading an empty string in `fromDataURL`. (#108) [Remo](https://github.com/Remo)
* Reject points generated by resting hand (better handling of multi touch). (#48 and #57) [jurreantonisse](https://github.com/jurreantonisse)
* Prevent loading an empty string in `fromDataURL`. (#108) [Remo](https://github.com/Remo)
* Reject points generated by resting hand (better handling of multi touch). (#48 and #57) [jurreantonisse](https://github.com/jurreantonisse)
### 1.5.1
* Prevent duplicate events on tap in iOS Safari. [PerfectPixel](https://github.com/PerfectPixel)
* Prevent duplicate events on tap in iOS Safari. [PerfectPixel](https://github.com/PerfectPixel)
### 1.5.0
* Add `on` method that rebinds all event handlers. [Alplob](https://github.com/Alplob)
* Add `on` method that rebinds all event handlers. [Alplob](https://github.com/Alplob)
### 1.4.0
* Add `off` method that unbinds all event handlers. [Rob-ot](https://github.com/Rob-ot)
* Add `off` method that unbinds all event handlers. [Rob-ot](https://github.com/Rob-ot)
### 1.3.6
* Fix support for Browserify. [chevett](https://github.com/chevett)
* Fix support for Browserify. [chevett](https://github.com/chevett)
### 1.3.5
* Add support for CommonJS/AMD/UMD.
* Add support for CommonJS/AMD/UMD.
### 1.3.4
* Really fix `fromDataURL` on HiDPI screens.
* Really fix `fromDataURL` on HiDPI screens.
### 1.3.3
* Fix `fromDataURL` on HiDPI screens.
* Fix `fromDataURL` on HiDPI screens.
### 1.3.2
* Fix `onBegin` and `onEnd` callbacks when passed as options to constructor. [yinsee](https://github.com/yinsee)
* Fix `onBegin` and `onEnd` callbacks when passed as options to constructor. [yinsee](https://github.com/yinsee)
### 1.3.1
* Fix handling touch events on mobile IE. [tocsoft](https://github.com/tocsoft)
* Fix handling touch events on mobile IE. [tocsoft](https://github.com/tocsoft)
### 1.3.0
* Add `onBegin` and `onEnd` callbacks. [rogerz](https://github.com/rogerz)
* Add `onBegin` and `onEnd` callbacks. [rogerz](https://github.com/rogerz)
### 1.2.4
* Fix bug where stroke becomes very thin. [mvirkkunen](https://github.com/mvirkkunen)
* Fix bug where stroke becomes very thin. [mvirkkunen](https://github.com/mvirkkunen)
### 1.2.3
* Fix `SignaturePad#fromDataURL` on Firefox. [Fr3nzzy](https://github.com/Fr3nzzy)
* Fix `SignaturePad#fromDataURL` on Firefox. [Fr3nzzy](https://github.com/Fr3nzzy)
### 1.2.2
* Make `SignaturePad#isEmpty` return false after loading an image using `SignaturePad#fromDataURL`. [krisivanov](https://github.com/krisivanov)
* Make `SignaturePad#isEmpty` return false after loading an image using `SignaturePad#fromDataURL`. [krisivanov](https://github.com/krisivanov)
### 1.2.1
* Fixed `SignaturePad#clear()`.
* Fixed `SignaturePad#clear()`.
### 1.2.0
* Add `backgroundColor` option to set custom color of the background on `SignaturePad#clear()`.
* Rename `color` option to `penColor`.
* Fix passing arguments to canvas element on `SignaturePad#toDataURL()`.
* Add `backgroundColor` option to set custom color of the background on `SignaturePad#clear()`.
* Rename `color` option to `penColor`.
* Fix passing arguments to canvas element on `SignaturePad#toDataURL()`.
/*!
* Signature Pad v1.6.0-beta.9
* Signature Pad v1.6.0
* https://github.com/szimek/signature_pad

@@ -4,0 +4,0 @@ *

/*!
* Signature Pad v1.6.0-beta.9
* Signature Pad v1.6.0
* https://github.com/szimek/signature_pad

@@ -4,0 +4,0 @@ *

{
"name": "signature_pad",
"description": "Library for drawing smooth signatures.",
"version": "1.6.0-beta.9",
"version": "1.6.0",
"homepage": "https://github.com/szimek/signature_pad",

@@ -6,0 +6,0 @@ "author": {

@@ -1,4 +0,4 @@

Signature Pad [![Code Climate](https://d25lcipzij17d.cloudfront.net/badge.svg?id=js&type=6&v=1.5.3&x2=0)](https://www.npmjs.com/package/signature_pad) [![Code Climate](https://codeclimate.com/github/szimek/signature_pad.png)](https://codeclimate.com/github/szimek/signature_pad)
=============
# Signature Pad [![Code Climate](https://d25lcipzij17d.cloudfront.net/badge.svg?id=js&type=6&v=1.5.3&x2=0)](https://www.npmjs.com/package/signature_pad) [![Code Climate](https://codeclimate.com/github/szimek/signature_pad.png)](https://codeclimate.com/github/szimek/signature_pad)
Signature Pad is a JavaScript library for drawing smooth signatures. It's HTML5 canvas based and uses variable width Bézier curve interpolation based on [Smoother Signatures](http://corner.squareup.com/2012/07/smoother-signatures.html) post by [Square](https://squareup.com).

@@ -162,8 +162,8 @@ It works in all modern desktop and mobile browsers and doesn't depend on any external libraries.

#### Removing empty space around a signature
If you'd like to remove (trim) empty space around a signature, you can do it on the server side or the client side. On the server side you can use e.g. ImageMagic and its `trim` option: `convert -trim input.jpg output.jpg`. If you don't have access to the server, or just want to trim the image before submitting it to the server, you can do it on the client side as well. There are a few examples how to do it, e.g. [here](https://github.com/szimek/signature_pad/issues/49#issue-29108215) or [here](https://github.com/szimek/signature_pad/issues/49#issuecomment-260976909) and there's also a tiny library https://github.com/agilgur5/trim-canvas that provides this functionality.
If you'd like to remove (trim) empty space around a signature, you can do it on the server side or the client side. On the server side you can use e.g. ImageMagic and its `trim` option: `convert -trim input.jpg output.jpg`. If you don't have access to the server, or just want to trim the image before submitting it to the server, you can do it on the client side as well. There are a few examples how to do it, e.g. [here](https://github.com/szimek/signature_pad/issues/49#issue-29108215) or [here](https://github.com/szimek/signature_pad/issues/49#issuecomment-260976909) and there's also a tiny library [trim-canvas](https://github.com/agilgur5/trim-canvas) that provides this functionality.
#### Drawing over an image
Demo: https://jsfiddle.net/szimek/d6a78gwq/
Demo: <https://jsfiddle.net/szimek/d6a78gwq/>
## License
Released under the [MIT License](http://www.opensource.org/licenses/MIT).

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc