Options for trim op must be an Object, add lineArt #2363

This commit is contained in:
Lovell Fuller
2023-11-04 14:09:50 +00:00
parent 2e7c60675b
commit 0bd1715f36
12 changed files with 118 additions and 125 deletions

View File

@@ -572,8 +572,8 @@ const nohalo: string = sharp.interpolators.nohalo;
const vertexSplitQuadraticBasisSpline: string = sharp.interpolators.vertexSplitQuadraticBasisSpline;
// Triming
sharp(input).trim('#000').toBuffer();
sharp(input).trim(10).toBuffer();
sharp(input).trim({ background: '#000' }).toBuffer();
sharp(input).trim({ threshold: 10, lineArt: true }).toBuffer();
sharp(input).trim({ background: '#bf1942', threshold: 30 }).toBuffer();
// Text input