@types/sharp
Advanced tools
Comparing version 0.28.6 to 0.29.0
@@ -1,2 +0,2 @@ | ||
// Type definitions for sharp 0.28 | ||
// Type definitions for sharp 0.29 | ||
// Project: https://github.com/lovell/sharp | ||
@@ -9,2 +9,3 @@ // Definitions by: François Nguyen <https://github.com/lith-light-g> | ||
// Billy Kwok <https://github.com/billykwok> | ||
// Espen Hovlandsdal <https://github.com/rexxars> | ||
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped | ||
@@ -203,2 +204,22 @@ // TypeScript Version: 2.1 | ||
/** | ||
* Set the pipeline colourspace. | ||
* The input image will be converted to the provided colourspace at the start of the pipeline. | ||
* All operations will use this colourspace before converting to the output colourspace, as defined by toColourspace. | ||
* This feature is experimental and has not yet been fully-tested with all operations. | ||
* | ||
* @param colourspace pipeline colourspace e.g. rgb16, scrgb, lab, grey16 ... | ||
* @throws {Error} Invalid parameters | ||
* @returns A sharp instance that can be used to chain operations | ||
*/ | ||
pipelineColourspace(colourspace?: string): Sharp; | ||
/** | ||
* Alternative spelling of pipelineColourspace | ||
* @param colorspace pipeline colourspace e.g. rgb16, scrgb, lab, grey16 ... | ||
* @throws {Error} Invalid parameters | ||
* @returns A sharp instance that can be used to chain operations | ||
*/ | ||
pipelineColorspace(colorspace?: string): Sharp; | ||
/** | ||
* Set the output colourspace. | ||
@@ -361,6 +382,6 @@ * By default output image will be web-friendly sRGB, with additional channels interpreted as alpha channels. | ||
* Produce the "negative" of the image. | ||
* @param negate true to enable and false to disable (defaults to true) | ||
* @param negate true to enable and false to disable, or an object of options (defaults to true) | ||
* @returns A sharp instance that can be used to chain operations | ||
*/ | ||
negate(negate?: boolean): Sharp; | ||
negate(negate?: boolean | NegateOptions): Sharp; | ||
@@ -569,5 +590,7 @@ /** | ||
* Force output to be raw, uncompressed uint8 pixel data. | ||
* @param options Raw output options. | ||
* @throws {Error} Invalid options | ||
* @returns A sharp instance that can be used to chain operations | ||
*/ | ||
raw(): Sharp; | ||
raw(options?: RawOptions): Sharp; | ||
@@ -810,2 +833,6 @@ /** | ||
tifftagPhotoshop?: Buffer | undefined; | ||
/** The encoder used to compress an HEIF file, `av1` (AVIF) or `hevc` (HEIC) */ | ||
compression?: 'av1' | 'hevc'; | ||
/** Default background colour, if present, for PNG (bKGD) and GIF images, either an RGB Object or a single greyscale value */ | ||
background?: { r: number; g: number; b: number } | number; | ||
} | ||
@@ -986,2 +1013,7 @@ | ||
interface NegateOptions { | ||
/** whether or not to negate any alpha channel. (optional, default true) */ | ||
alpha?: boolean | undefined; | ||
} | ||
interface ResizeOptions { | ||
@@ -1030,2 +1062,6 @@ /** Alternative means of specifying width. If both are present this take priority. */ | ||
interface RawOptions { | ||
depth?: 'char' | 'uchar' | 'short' | 'ushort' | 'int' | 'uint' | 'float' | 'complex' | 'double' | 'dpcomplex'; | ||
} | ||
/** 3 for sRGB, 4 for CMYK */ | ||
@@ -1032,0 +1068,0 @@ type Channels = 3 | 4; |
{ | ||
"name": "@types/sharp", | ||
"version": "0.28.6", | ||
"version": "0.29.0", | ||
"description": "TypeScript definitions for sharp", | ||
@@ -37,2 +37,7 @@ "homepage": "https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/sharp", | ||
"githubUsername": "billykwok" | ||
}, | ||
{ | ||
"name": "Espen Hovlandsdal", | ||
"url": "https://github.com/rexxars", | ||
"githubUsername": "rexxars" | ||
} | ||
@@ -51,4 +56,4 @@ ], | ||
}, | ||
"typesPublisherContentHash": "a315c36a18cf02b96e85a6a1830e4674cbda31c25b4538b02c718c71e5902c78", | ||
"typesPublisherContentHash": "729c225b3050c241dcf32ddcf369b82cfd1e37bda2a90b2627759277825b6905", | ||
"typeScriptVersion": "3.7" | ||
} |
@@ -11,3 +11,3 @@ # Installation | ||
### Additional Details | ||
* Last updated: Wed, 01 Sep 2021 09:31:20 GMT | ||
* Last updated: Tue, 07 Sep 2021 19:31:24 GMT | ||
* Dependencies: [@types/node](https://npmjs.com/package/@types/node) | ||
@@ -17,2 +17,2 @@ * Global values: none | ||
# Credits | ||
These definitions were written by [François Nguyen](https://github.com/lith-light-g), [Wooseop Kim](https://github.com/wooseopkim), [Bradley Odell](https://github.com/BTOdell), [Jamie Woodbury](https://github.com/JamieWoodbury), [Floris de Bijl](https://github.com/Fdebijl), and [Billy Kwok](https://github.com/billykwok). | ||
These definitions were written by [François Nguyen](https://github.com/lith-light-g), [Wooseop Kim](https://github.com/wooseopkim), [Bradley Odell](https://github.com/BTOdell), [Jamie Woodbury](https://github.com/JamieWoodbury), [Floris de Bijl](https://github.com/Fdebijl), [Billy Kwok](https://github.com/billykwok), and [Espen Hovlandsdal](https://github.com/rexxars). |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
63441
1157