@xyo-network/image-thumbnail-plugin 2.70.8 → 2.70.10
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/dist/cjs/Witness/Witness.js +159 -12
- package/dist/cjs/Witness/Witness.js.map +1 -1
- package/dist/docs.json +2978 -1705
- package/dist/esm/Witness/Witness.js +153 -12
- package/dist/esm/Witness/Witness.js.map +1 -1
- package/dist/types/Plugin.d.ts +5 -0
- package/dist/types/Plugin.d.ts.map +1 -1
- package/dist/types/Witness/Config.d.ts +5 -0
- package/dist/types/Witness/Config.d.ts.map +1 -1
- package/dist/types/Witness/Witness.d.ts +17 -2
- package/dist/types/Witness/Witness.d.ts.map +1 -1
- package/package.json +12 -10
- package/src/Witness/Config.ts +5 -0
- package/src/Witness/Witness.ts +170 -16
|
@@ -5,12 +5,17 @@ const tslib_1 = require("tslib");
|
|
|
5
5
|
const axios_1 = require("@xyo-network/axios");
|
|
6
6
|
const core_1 = require("@xyo-network/core");
|
|
7
7
|
const image_thumbnail_payload_plugin_1 = require("@xyo-network/image-thumbnail-payload-plugin");
|
|
8
|
+
const payload_model_1 = require("@xyo-network/payload-model");
|
|
8
9
|
const witness_1 = require("@xyo-network/witness");
|
|
9
10
|
const gm_1 = require("gm");
|
|
10
11
|
const hash_wasm_1 = require("hash-wasm");
|
|
11
12
|
const compact_1 = tslib_1.__importDefault(require("lodash/compact"));
|
|
13
|
+
const isBuffer_1 = tslib_1.__importDefault(require("lodash/isBuffer"));
|
|
14
|
+
const lru_cache_1 = require("lru-cache");
|
|
12
15
|
const sha_js_1 = tslib_1.__importDefault(require("sha.js"));
|
|
16
|
+
const url_parse_1 = tslib_1.__importDefault(require("url-parse"));
|
|
13
17
|
const Config_1 = require("./Config");
|
|
18
|
+
//TODO: Break this into two Witnesses?
|
|
14
19
|
const gm = (0, gm_1.subClass)({ imageMagick: '7+' });
|
|
15
20
|
const binaryToSha256 = (data) => tslib_1.__awaiter(void 0, void 0, void 0, function* () {
|
|
16
21
|
yield core_1.PayloadHasher.wasmInitialized;
|
|
@@ -26,23 +31,155 @@ const binaryToSha256 = (data) => tslib_1.__awaiter(void 0, void 0, void 0, funct
|
|
|
26
31
|
return (0, sha_js_1.default)('sha256').update(data).digest().toString();
|
|
27
32
|
});
|
|
28
33
|
exports.binaryToSha256 = binaryToSha256;
|
|
34
|
+
const checkIpfsUrl = (urlToCheck) => {
|
|
35
|
+
const url = new url_parse_1.default(urlToCheck);
|
|
36
|
+
let protocol = url.protocol;
|
|
37
|
+
let host = url.host;
|
|
38
|
+
let path = url.pathname;
|
|
39
|
+
const query = url.query;
|
|
40
|
+
if (protocol === 'ipfs:') {
|
|
41
|
+
protocol = 'https:';
|
|
42
|
+
host = 'cloudflare-ipfs.com';
|
|
43
|
+
path = url.host === 'ipfs' ? `ipfs${path}` : `ipfs/${url.host}${path}`;
|
|
44
|
+
const root = `${protocol}//${host}/${path}`;
|
|
45
|
+
return (query === null || query === void 0 ? void 0 : query.length) > 0 ? `root?${query}` : root;
|
|
46
|
+
}
|
|
47
|
+
else {
|
|
48
|
+
return urlToCheck;
|
|
49
|
+
}
|
|
50
|
+
};
|
|
51
|
+
const checkDataUrl = (url) => {
|
|
52
|
+
if (url.startsWith('data:image')) {
|
|
53
|
+
const data = url.split(',')[1];
|
|
54
|
+
if (data) {
|
|
55
|
+
const buffer = Buffer.from(Uint8Array.from(atob(data), (c) => c.charCodeAt(0)));
|
|
56
|
+
console.log(`data buffer: ${buffer.length}`);
|
|
57
|
+
return [buffer, undefined];
|
|
58
|
+
}
|
|
59
|
+
else {
|
|
60
|
+
const error = {
|
|
61
|
+
message: 'Invalid data Url',
|
|
62
|
+
schema: payload_model_1.ModuleErrorSchema,
|
|
63
|
+
url,
|
|
64
|
+
};
|
|
65
|
+
return [undefined, error];
|
|
66
|
+
}
|
|
67
|
+
}
|
|
68
|
+
else {
|
|
69
|
+
return [undefined, undefined];
|
|
70
|
+
}
|
|
71
|
+
};
|
|
29
72
|
class ImageThumbnailWitness extends witness_1.AbstractWitness {
|
|
73
|
+
get cache() {
|
|
74
|
+
var _a;
|
|
75
|
+
this._cache = (_a = this._cache) !== null && _a !== void 0 ? _a : new lru_cache_1.LRUCache({ max: this.maxCacheEntries });
|
|
76
|
+
return this._cache;
|
|
77
|
+
}
|
|
78
|
+
get encoding() {
|
|
79
|
+
var _a;
|
|
80
|
+
return (_a = this.config.encoding) !== null && _a !== void 0 ? _a : 'PNG';
|
|
81
|
+
}
|
|
82
|
+
get height() {
|
|
83
|
+
var _a;
|
|
84
|
+
return (_a = this.config.height) !== null && _a !== void 0 ? _a : 128;
|
|
85
|
+
}
|
|
86
|
+
get maxCacheEntries() {
|
|
87
|
+
var _a;
|
|
88
|
+
return (_a = this.config.maxCacheEntries) !== null && _a !== void 0 ? _a : 5000;
|
|
89
|
+
}
|
|
90
|
+
get quality() {
|
|
91
|
+
var _a;
|
|
92
|
+
return (_a = this.config.quality) !== null && _a !== void 0 ? _a : 50;
|
|
93
|
+
}
|
|
94
|
+
get width() {
|
|
95
|
+
var _a;
|
|
96
|
+
return (_a = this.config.width) !== null && _a !== void 0 ? _a : 128;
|
|
97
|
+
}
|
|
30
98
|
observeHandler(payloads = []) {
|
|
31
99
|
return tslib_1.__awaiter(this, void 0, void 0, function* () {
|
|
32
|
-
|
|
100
|
+
const responsePairs = (0, compact_1.default)(yield Promise.all(payloads.map(({ url }) => tslib_1.__awaiter(this, void 0, void 0, function* () {
|
|
101
|
+
const cachedResult = this.cache.get(url);
|
|
102
|
+
if (cachedResult) {
|
|
103
|
+
return [url, cachedResult];
|
|
104
|
+
}
|
|
105
|
+
//if it is a data URL, return a Buffer
|
|
106
|
+
const [dataBuffer, dataError] = checkDataUrl(url);
|
|
107
|
+
if (dataBuffer) {
|
|
108
|
+
return [url, dataBuffer];
|
|
109
|
+
}
|
|
110
|
+
if (dataError) {
|
|
111
|
+
return [url, dataError];
|
|
112
|
+
}
|
|
33
113
|
//if it is ipfs, go through cloud flair
|
|
34
|
-
const mutatedUrl = url
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
114
|
+
const mutatedUrl = checkIpfsUrl(url);
|
|
115
|
+
try {
|
|
116
|
+
return [
|
|
117
|
+
url,
|
|
118
|
+
yield axios_1.axios.get(mutatedUrl, {
|
|
119
|
+
responseType: 'arraybuffer',
|
|
120
|
+
}),
|
|
121
|
+
];
|
|
122
|
+
}
|
|
123
|
+
catch (ex) {
|
|
124
|
+
const axiosError = ex;
|
|
125
|
+
if (axiosError.isAxiosError) {
|
|
126
|
+
//selectively pick fields from AxiosError
|
|
127
|
+
const errorPayload = {
|
|
128
|
+
code: axiosError.code,
|
|
129
|
+
message: axiosError.message,
|
|
130
|
+
schema: payload_model_1.ModuleErrorSchema,
|
|
131
|
+
status: axiosError.status,
|
|
132
|
+
url,
|
|
133
|
+
};
|
|
134
|
+
return [url, errorPayload];
|
|
135
|
+
}
|
|
136
|
+
else {
|
|
137
|
+
throw ex;
|
|
138
|
+
}
|
|
139
|
+
}
|
|
140
|
+
}))));
|
|
141
|
+
return (0, compact_1.default)(yield Promise.all(responsePairs.map(([url, urlResult]) => tslib_1.__awaiter(this, void 0, void 0, function* () {
|
|
142
|
+
var _a;
|
|
143
|
+
if ((0, payload_model_1.isPayload)(urlResult)) {
|
|
144
|
+
this.cache.set(url, urlResult);
|
|
145
|
+
return urlResult;
|
|
146
|
+
}
|
|
147
|
+
let sourceBuffer;
|
|
148
|
+
if ((0, isBuffer_1.default)(urlResult)) {
|
|
149
|
+
sourceBuffer = urlResult;
|
|
150
|
+
}
|
|
151
|
+
else {
|
|
152
|
+
const response = urlResult;
|
|
153
|
+
if (response.status >= 200 && response.status < 300) {
|
|
154
|
+
const contentType = (_a = response.headers['content-type']) === null || _a === void 0 ? void 0 : _a.toString();
|
|
155
|
+
if (contentType.split('/')[0] !== 'image') {
|
|
156
|
+
const error = {
|
|
157
|
+
message: `Invalid file type: ${contentType}`,
|
|
158
|
+
schema: payload_model_1.ModuleErrorSchema,
|
|
159
|
+
url,
|
|
160
|
+
};
|
|
161
|
+
this.cache.set(url, error);
|
|
162
|
+
return error;
|
|
163
|
+
}
|
|
164
|
+
sourceBuffer = Buffer.from(response.data, 'binary');
|
|
165
|
+
}
|
|
166
|
+
else {
|
|
167
|
+
const error = {
|
|
168
|
+
schema: payload_model_1.ModuleErrorSchema,
|
|
169
|
+
status: response.status,
|
|
170
|
+
url,
|
|
171
|
+
};
|
|
172
|
+
this.cache.set(url, error);
|
|
173
|
+
return error;
|
|
174
|
+
}
|
|
175
|
+
}
|
|
176
|
+
try {
|
|
40
177
|
const thumb = yield new Promise((resolve, reject) => {
|
|
41
|
-
gm(
|
|
42
|
-
.quality(
|
|
43
|
-
.resize(
|
|
178
|
+
gm(sourceBuffer)
|
|
179
|
+
.quality(this.quality)
|
|
180
|
+
.resize(this.width, this.height)
|
|
44
181
|
.flatten()
|
|
45
|
-
.toBuffer(
|
|
182
|
+
.toBuffer(this.encoding, (error, buffer) => {
|
|
46
183
|
if (error) {
|
|
47
184
|
reject(error);
|
|
48
185
|
}
|
|
@@ -53,12 +190,22 @@ class ImageThumbnailWitness extends witness_1.AbstractWitness {
|
|
|
53
190
|
});
|
|
54
191
|
const result = {
|
|
55
192
|
schema: image_thumbnail_payload_plugin_1.ImageThumbnailSchema,
|
|
56
|
-
sourceHash: yield (0, exports.binaryToSha256)(
|
|
193
|
+
sourceHash: yield (0, exports.binaryToSha256)(sourceBuffer),
|
|
57
194
|
sourceUrl: url,
|
|
58
195
|
url: `data:image/png;base64,${thumb.toString('base64')}`,
|
|
59
196
|
};
|
|
197
|
+
this.cache.set(url, result);
|
|
60
198
|
return result;
|
|
61
199
|
}
|
|
200
|
+
catch (ex) {
|
|
201
|
+
const error = {
|
|
202
|
+
message: 'Failed to resize image',
|
|
203
|
+
schema: payload_model_1.ModuleErrorSchema,
|
|
204
|
+
url,
|
|
205
|
+
};
|
|
206
|
+
this.cache.set(url, error);
|
|
207
|
+
return error;
|
|
208
|
+
}
|
|
62
209
|
}))));
|
|
63
210
|
});
|
|
64
211
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Witness.js","sourceRoot":"","sources":["../../../src/Witness/Witness.ts"],"names":[],"mappings":";;;;AAAA,
|
|
1
|
+
{"version":3,"file":"Witness.js","sourceRoot":"","sources":["../../../src/Witness/Witness.ts"],"names":[],"mappings":";;;;AAAA,8CAAqE;AACrE,4CAAiD;AACjD,gGAAqI;AACrI,8DAAsF;AAEtF,kDAAsD;AACtD,2BAA6B;AAC7B,yCAAkC;AAClC,qEAAoC;AACpC,uEAAsC;AACtC,yCAAoC;AACpC,4DAA0B;AAC1B,kEAA2B;AAE3B,qCAA4D;AAG5D,sCAAsC;AAEtC,MAAM,EAAE,GAAG,IAAA,aAAQ,EAAC,EAAE,WAAW,EAAE,IAAI,EAAE,CAAC,CAAA;AAEnC,MAAM,cAAc,GAAG,CAAO,IAAgB,EAAE,EAAE;IACvD,MAAM,oBAAa,CAAC,eAAe,CAAA;IACnC,IAAI,oBAAa,CAAC,WAAW,CAAC,UAAU,EAAE;QACxC,IAAI;YACF,OAAO,MAAM,IAAA,kBAAM,EAAC,IAAI,CAAC,CAAA;SAC1B;QAAC,OAAO,EAAE,EAAE;YACX,oBAAa,CAAC,WAAW,CAAC,SAAS,GAAG,KAAK,CAAA;SAC5C;KACF;IACD,mDAAmD;IACnD,OAAO,IAAA,gBAAK,EAAC,QAAQ,CAAC,CAAC,MAAM,CAAC,IAAI,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE,CAAA;AACzD,CAAC,CAAA,CAAA;AAXY,QAAA,cAAc,kBAW1B;AAED,MAAM,YAAY,GAAG,CAAC,UAAkB,EAAE,EAAE;IAC1C,MAAM,GAAG,GAAG,IAAI,mBAAG,CAAC,UAAU,CAAC,CAAA;IAC/B,IAAI,QAAQ,GAAG,GAAG,CAAC,QAAQ,CAAA;IAC3B,IAAI,IAA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