mirror of
https://github.com/lovell/sharp.git
synced 2025-12-19 07:15:08 +01:00
Docs: lint JSDoc annotations when building docs
This commit is contained in:
@@ -190,8 +190,8 @@ function isRotationExpected (options) {
|
||||
* .toBuffer()
|
||||
* );
|
||||
*
|
||||
* @param {Number} [width] - pixels wide the resultant image should be. Use `null` or `undefined` to auto-scale the width to match the height.
|
||||
* @param {Number} [height] - pixels high the resultant image should be. Use `null` or `undefined` to auto-scale the height to match the width.
|
||||
* @param {number} [width] - pixels wide the resultant image should be. Use `null` or `undefined` to auto-scale the width to match the height.
|
||||
* @param {number} [height] - pixels high the resultant image should be. Use `null` or `undefined` to auto-scale the height to match the width.
|
||||
* @param {Object} [options]
|
||||
* @param {String} [options.width] - alternative means of specifying `width`. If both are present this take priority.
|
||||
* @param {String} [options.height] - alternative means of specifying `height`. If both are present this take priority.
|
||||
@@ -302,11 +302,11 @@ function resize (width, height, options) {
|
||||
* })
|
||||
* ...
|
||||
*
|
||||
* @param {(Number|Object)} extend - single pixel count to add to all edges or an Object with per-edge counts
|
||||
* @param {Number} [extend.top]
|
||||
* @param {Number} [extend.left]
|
||||
* @param {Number} [extend.bottom]
|
||||
* @param {Number} [extend.right]
|
||||
* @param {(number|Object)} extend - single pixel count to add to all edges or an Object with per-edge counts
|
||||
* @param {number} [extend.top]
|
||||
* @param {number} [extend.left]
|
||||
* @param {number} [extend.bottom]
|
||||
* @param {number} [extend.right]
|
||||
* @param {String|Object} [extend.background={r: 0, g: 0, b: 0, alpha: 1}] - background colour, parsed by the [color](https://www.npmjs.org/package/color) module, defaults to black without transparency.
|
||||
* @returns {Sharp}
|
||||
* @throws {Error} Invalid parameters
|
||||
@@ -358,10 +358,10 @@ function extend (extend) {
|
||||
* });
|
||||
*
|
||||
* @param {Object} options - describes the region to extract using integral pixel values
|
||||
* @param {Number} options.left - zero-indexed offset from left edge
|
||||
* @param {Number} options.top - zero-indexed offset from top edge
|
||||
* @param {Number} options.width - width of region to extract
|
||||
* @param {Number} options.height - height of region to extract
|
||||
* @param {number} options.left - zero-indexed offset from left edge
|
||||
* @param {number} options.top - zero-indexed offset from top edge
|
||||
* @param {number} options.width - width of region to extract
|
||||
* @param {number} options.height - height of region to extract
|
||||
* @returns {Sharp}
|
||||
* @throws {Error} Invalid parameters
|
||||
*/
|
||||
@@ -388,7 +388,7 @@ function extract (options) {
|
||||
*
|
||||
* The `info` response Object will contain `trimOffsetLeft` and `trimOffsetTop` properties.
|
||||
*
|
||||
* @param {Number} [threshold=10] the allowed difference from the top-left pixel, a number greater than zero.
|
||||
* @param {number} [threshold=10] the allowed difference from the top-left pixel, a number greater than zero.
|
||||
* @returns {Sharp}
|
||||
* @throws {Error} Invalid parameters
|
||||
*/
|
||||
|
||||
Reference in New Issue
Block a user