@jimp/plugin-threshold 0.21.2 → 0.21.4--canary.1163.a26f5b300ee88c2fadb9909dd390cb4380b32a42.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +9 -9
- package/test/threshold.test.js +4 -4
package/package.json
CHANGED
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@jimp/plugin-threshold",
|
|
3
|
-
"version": "0.21.
|
|
3
|
+
"version": "0.21.4--canary.1163.a26f5b300ee88c2fadb9909dd390cb4380b32a42.0",
|
|
4
4
|
"description": "Lightens an image.",
|
|
5
5
|
"main": "dist/index.js",
|
|
6
6
|
"module": "es/index.js",
|
|
7
7
|
"repository": "jimp-dev/jimp",
|
|
8
8
|
"types": "index.d.ts",
|
|
9
9
|
"scripts": {
|
|
10
|
-
"test": "cross-env BABEL_ENV=test mocha --require @babel/register",
|
|
10
|
+
"test": "cross-env BABEL_ENV=test mocha --require @babel/register --recursive test --extension js",
|
|
11
11
|
"test:watch": "npm run test -- --reporter min --watch",
|
|
12
12
|
"test:coverage": "nyc npm run test",
|
|
13
13
|
"build": "npm run build:node:production && npm run build:module",
|
|
@@ -21,7 +21,7 @@
|
|
|
21
21
|
"author": "",
|
|
22
22
|
"license": "MIT",
|
|
23
23
|
"dependencies": {
|
|
24
|
-
"@jimp/utils": "
|
|
24
|
+
"@jimp/utils": "0.21.4--canary.1163.a26f5b300ee88c2fadb9909dd390cb4380b32a42.0"
|
|
25
25
|
},
|
|
26
26
|
"peerDependencies": {
|
|
27
27
|
"@jimp/custom": ">=0.3.5",
|
|
@@ -29,14 +29,14 @@
|
|
|
29
29
|
"@jimp/plugin-resize": ">=0.8.0"
|
|
30
30
|
},
|
|
31
31
|
"devDependencies": {
|
|
32
|
-
"@jimp/custom": "
|
|
33
|
-
"@jimp/jpeg": "
|
|
34
|
-
"@jimp/plugin-color": "
|
|
35
|
-
"@jimp/plugin-resize": "
|
|
36
|
-
"@jimp/test-utils": "
|
|
32
|
+
"@jimp/custom": "0.21.4--canary.1163.a26f5b300ee88c2fadb9909dd390cb4380b32a42.0",
|
|
33
|
+
"@jimp/jpeg": "0.21.4--canary.1163.a26f5b300ee88c2fadb9909dd390cb4380b32a42.0",
|
|
34
|
+
"@jimp/plugin-color": "0.21.4--canary.1163.a26f5b300ee88c2fadb9909dd390cb4380b32a42.0",
|
|
35
|
+
"@jimp/plugin-resize": "0.21.4--canary.1163.a26f5b300ee88c2fadb9909dd390cb4380b32a42.0",
|
|
36
|
+
"@jimp/test-utils": "0.21.4--canary.1163.a26f5b300ee88c2fadb9909dd390cb4380b32a42.0"
|
|
37
37
|
},
|
|
38
38
|
"publishConfig": {
|
|
39
39
|
"access": "public"
|
|
40
40
|
},
|
|
41
|
-
"gitHead": "
|
|
41
|
+
"gitHead": "a26f5b300ee88c2fadb9909dd390cb4380b32a42"
|
|
42
42
|
}
|
package/test/threshold.test.js
CHANGED
|
@@ -3,6 +3,7 @@ import configure from "@jimp/custom";
|
|
|
3
3
|
import jpeg from "@jimp/jpeg";
|
|
4
4
|
import color from "@jimp/plugin-color";
|
|
5
5
|
import resize from "@jimp/plugin-resize";
|
|
6
|
+
import expect from "@storybook/expect";
|
|
6
7
|
|
|
7
8
|
import threshold from "../src";
|
|
8
9
|
|
|
@@ -22,9 +23,8 @@ describe("Threshold", function () {
|
|
|
22
23
|
getTestDir(__dirname) + "/images/hands.jpg"
|
|
23
24
|
);
|
|
24
25
|
|
|
25
|
-
testImage
|
|
26
|
-
.
|
|
27
|
-
|
|
28
|
-
.should.be.equal(expectedImage.hash());
|
|
26
|
+
expect(testImage.threshold({ max: 200, replace: 255 }).hash()).toBe(
|
|
27
|
+
expectedImage.hash()
|
|
28
|
+
);
|
|
29
29
|
});
|
|
30
30
|
});
|