splashy 5.1.12 → 5.1.13-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/LICENSE +0 -0
- package/package.json +17 -16
- package/src/index.js +3 -2
package/LICENSE
CHANGED
|
File without changes
|
package/package.json
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
"name": "splashy",
|
|
3
3
|
"description": "Given an image, extract predominant & palette colors",
|
|
4
4
|
"homepage": "https://nicedoc.io/microlinkhq/splashy",
|
|
5
|
-
"version": "5.1.
|
|
5
|
+
"version": "5.1.13-0",
|
|
6
6
|
"main": "src/index.js",
|
|
7
7
|
"author": {
|
|
8
8
|
"name": "Kiko Beats",
|
|
@@ -43,6 +43,7 @@
|
|
|
43
43
|
"dependencies": {
|
|
44
44
|
"debug-logfmt": "~1.0.4",
|
|
45
45
|
"node-vibrant": "~3.2.1-alpha.1",
|
|
46
|
+
"serialize-error": "~8.1.0",
|
|
46
47
|
"sharp": "0.31.1"
|
|
47
48
|
},
|
|
48
49
|
"devDependencies": {
|
|
@@ -68,20 +69,6 @@
|
|
|
68
69
|
"files": [
|
|
69
70
|
"src"
|
|
70
71
|
],
|
|
71
|
-
"scripts": {
|
|
72
|
-
"clean": "rm -rf node_modules",
|
|
73
|
-
"contributors": "(npx git-authors-cli && npx finepack && git add package.json && git commit -m 'build: contributors' --no-verify) || true",
|
|
74
|
-
"dev": "nodemon --exec \"npm start\" -e \"js\"",
|
|
75
|
-
"lint": "standard-markdown README.md && standard",
|
|
76
|
-
"postrelease": "npm run release:tags && npm run release:github && (ci-publish || npm publish --access=public)",
|
|
77
|
-
"preinstall": "npx bin-version-check-cli magick \">=7\"",
|
|
78
|
-
"pretest": "npm run lint",
|
|
79
|
-
"release": "standard-version -a",
|
|
80
|
-
"release:github": "conventional-github-releaser -p angular",
|
|
81
|
-
"release:tags": "git push --follow-tags origin HEAD:master",
|
|
82
|
-
"start": "node index.js",
|
|
83
|
-
"test": "c8 ava"
|
|
84
|
-
},
|
|
85
72
|
"license": "MIT",
|
|
86
73
|
"commitlint": {
|
|
87
74
|
"extends": [
|
|
@@ -102,5 +89,19 @@
|
|
|
102
89
|
"simple-git-hooks": {
|
|
103
90
|
"commit-msg": "npx commitlint --edit",
|
|
104
91
|
"pre-commit": "npx nano-staged"
|
|
92
|
+
},
|
|
93
|
+
"scripts": {
|
|
94
|
+
"clean": "rm -rf node_modules",
|
|
95
|
+
"contributors": "(npx git-authors-cli && npx finepack && git add package.json && git commit -m 'build: contributors' --no-verify) || true",
|
|
96
|
+
"dev": "nodemon --exec \"npm start\" -e \"js\"",
|
|
97
|
+
"lint": "standard-markdown README.md && standard",
|
|
98
|
+
"postrelease": "npm run release:tags && npm run release:github && (ci-publish || npm publish --access=public)",
|
|
99
|
+
"preinstall": "npx bin-version-check-cli magick \">=7\"",
|
|
100
|
+
"pretest": "npm run lint",
|
|
101
|
+
"release": "standard-version -a",
|
|
102
|
+
"release:github": "conventional-github-releaser -p angular",
|
|
103
|
+
"release:tags": "git push --follow-tags origin HEAD:master",
|
|
104
|
+
"start": "node index.js",
|
|
105
|
+
"test": "c8 ava"
|
|
105
106
|
}
|
|
106
|
-
}
|
|
107
|
+
}
|
package/src/index.js
CHANGED
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
'use strict'
|
|
2
2
|
|
|
3
|
+
const { serializeError } = require('serialize-error')
|
|
3
4
|
const debug = require('debug-logfmt')('splashy')
|
|
4
5
|
const createVibrant = require('./vibrant')
|
|
5
6
|
|
|
@@ -24,8 +25,8 @@ module.exports = async input => {
|
|
|
24
25
|
try {
|
|
25
26
|
const vibrant = createVibrant(input)
|
|
26
27
|
swatch = await vibrant.getPalette()
|
|
27
|
-
} catch (
|
|
28
|
-
debug.error(
|
|
28
|
+
} catch (error) {
|
|
29
|
+
debug.error(serializeError(error))
|
|
29
30
|
swatch = {}
|
|
30
31
|
}
|
|
31
32
|
|