Skip to content

Commit 6ecdd9f

Browse files
committed
Fixed filter function
1 parent 706019b commit 6ecdd9f

File tree

4 files changed

+7
-4
lines changed

4 files changed

+7
-4
lines changed

addon/codemirror-colorpicker.js

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2267,6 +2267,9 @@ function grayscale(amount) {
22672267
});
22682268
}
22692269

2270+
/*
2271+
* @param {Number} amount 0..360
2272+
*/
22702273
function hue() {
22712274
var amount = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : 360;
22722275

@@ -2276,7 +2279,7 @@ function hue() {
22762279

22772280
// 0 ~ 360
22782281
var h = hsv.h;
2279-
h += Math.abs($amount);
2282+
h += Math.abs($C);
22802283
h = h % 360;
22812284
hsv.h = h;
22822285

dist/codemirror-colorpicker.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2330,7 +2330,7 @@ function hue() {
23302330

23312331
// 0 ~ 360
23322332
var h = hsv.h;
2333-
h += Math.abs($amount);
2333+
h += Math.abs($C);
23342334
h = h % 360;
23352335
hsv.h = h;
23362336

dist/codemirror-colorpicker.min.js

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

src/util/filter/pixel/hue.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ export default function hue (amount = 360) {
1313

1414
// 0 ~ 360
1515
var h = hsv.h;
16-
h += Math.abs($amount)
16+
h += Math.abs($C)
1717
h = h % 360
1818
hsv.h = h
1919

0 commit comments

Comments
 (0)