Skip to content

Commit

Permalink
Fix bug in the setColor method and bump to v1.2.3.
Browse files Browse the repository at this point in the history
  • Loading branch information
recurser committed Aug 29, 2020
1 parent ebe0b2c commit a78212b
Show file tree
Hide file tree
Showing 6 changed files with 12 additions and 12 deletions.
4 changes: 2 additions & 2 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
node_modules

/node_modules
/package-lock.json
2 changes: 2 additions & 0 deletions README.markdown
Original file line number Diff line number Diff line change
Expand Up @@ -147,6 +147,8 @@ Use `npm install` to install the dependencies, and `grunt` to run the build.
Change history
-----------

* **Version 1.2.3 (2020-08-29)** :
* Fix bug in the `setColor` method (thanks [al42and](https://github.com/al42and)).
* **Version 1.2.2 (2017-08-19)** :
* Add adaptive text color (thanks [Fulligan](https://github.com/Fulligan)).
* Add hideInput and inputCSS options (thanks [graredcr](https://github.com/graredcr)).
Expand Down
4 changes: 2 additions & 2 deletions jquery.simple-color.js
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
* Licensed under the MIT license:
* http://www.opensource.org/licenses/mit-license.php
*
* Version: 1.2.2 (Sat, 19 Aug 2017 10:03:14 GMT)
* Version: 1.2.3 (Sat, 29 Aug 2020 11:55:25 GMT)
*/
(function($) {
/**
Expand Down Expand Up @@ -375,7 +375,7 @@
$.fn.setColor = function(color) {
this.each( function(index) {
var displayBox = $(this).data('container').find('.simpleColorDisplay');
setColor(displayBox, color, options);
setColor(displayBox, color, { displayColorCode: displayBox.data('displayColorCode') });
});

return this;
Expand Down
2 changes: 1 addition & 1 deletion jquery.simple-color.min.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

10 changes: 4 additions & 6 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,16 +2,14 @@
"name": "jquery-simple-color",
"description": "A dead-simple jQuery color picker.",
"repository": "[email protected]:recurser/jquery-simple-color.git",
"version": "1.2.2",
"version": "1.2.3",
"main": "Gruntfile.js",
"dependencies": {
},
"dependencies": {},
"devDependencies": {
"grunt-contrib-uglify": "~0.2.0",
"grunt": "~0.4.0"
"grunt": "^1.3.0",
"grunt-contrib-uglify": "^5.0.0"
},
"peerDependencies": {
"grunt": "~0.4.0"
}
}

2 changes: 1 addition & 1 deletion src/jquery.simple-color.js
Original file line number Diff line number Diff line change
Expand Up @@ -375,7 +375,7 @@
$.fn.setColor = function(color) {
this.each( function(index) {
var displayBox = $(this).data('container').find('.simpleColorDisplay');
setColor(displayBox, color, options);
setColor(displayBox, color, { displayColorCode: displayBox.data('displayColorCode') });
});

return this;
Expand Down

0 comments on commit a78212b

Please sign in to comment.