@design-edito/tools 0.2.15 → 0.2.16
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/agnostic/arrays/index.js +10 -10
- package/agnostic/arrays/random-pick/index.js +6 -6
- package/agnostic/colors/channels/index.d.ts +5 -0
- package/agnostic/colors/channels/index.js +18 -0
- package/agnostic/colors/contrast/index.d.ts +2 -0
- package/agnostic/colors/contrast/index.js +13 -0
- package/agnostic/colors/convert/index.d.ts +20 -0
- package/agnostic/colors/convert/index.js +45 -0
- package/agnostic/colors/distance/index.d.ts +2 -0
- package/agnostic/colors/distance/index.js +12 -0
- package/agnostic/colors/grayscale/index.d.ts +2 -0
- package/agnostic/colors/grayscale/index.js +12 -0
- package/agnostic/colors/index.d.ts +14 -16
- package/agnostic/colors/index.js +95 -27
- package/agnostic/colors/invert/index.d.ts +2 -0
- package/agnostic/colors/invert/index.js +12 -0
- package/agnostic/colors/lerp/index.d.ts +2 -0
- package/agnostic/colors/lerp/index.js +12 -0
- package/agnostic/colors/luminance/index.d.ts +2 -0
- package/agnostic/colors/luminance/index.js +12 -0
- package/agnostic/colors/palette/index.d.ts +2 -0
- package/agnostic/colors/palette/index.js +14 -0
- package/agnostic/colors/rotate/index.d.ts +2 -0
- package/agnostic/colors/rotate/index.js +13 -0
- package/agnostic/colors/tidy/index.d.ts +2 -0
- package/agnostic/colors/tidy/index.js +11 -0
- package/agnostic/colors/typechecks/index.d.ts +11 -0
- package/agnostic/colors/typechecks/index.js +26 -0
- package/agnostic/colors/types.d.ts +82 -0
- package/agnostic/css/index.js +10 -10
- package/agnostic/css/styles-set/index.js +8 -8
- package/agnostic/errors/index.js +2 -2
- package/agnostic/html/hyper-json/cast/index.js +6 -6
- package/agnostic/html/hyper-json/index.js +7 -7
- package/agnostic/html/hyper-json/smart-tags/coalesced/add/index.js +6 -6
- package/agnostic/html/hyper-json/smart-tags/coalesced/addclass/index.js +6 -6
- package/agnostic/html/hyper-json/smart-tags/coalesced/and/index.js +6 -6
- package/agnostic/html/hyper-json/smart-tags/coalesced/append/index.js +6 -6
- package/agnostic/html/hyper-json/smart-tags/coalesced/at/index.js +6 -6
- package/agnostic/html/hyper-json/smart-tags/coalesced/call/index.js +6 -6
- package/agnostic/html/hyper-json/smart-tags/coalesced/clone/index.js +6 -6
- package/agnostic/html/hyper-json/smart-tags/coalesced/deleteproperties/index.js +6 -6
- package/agnostic/html/hyper-json/smart-tags/coalesced/equals/index.js +6 -6
- package/agnostic/html/hyper-json/smart-tags/coalesced/getattribute/index.js +6 -6
- package/agnostic/html/hyper-json/smart-tags/coalesced/getproperties/index.js +6 -6
- package/agnostic/html/hyper-json/smart-tags/coalesced/getproperty/index.js +6 -6
- package/agnostic/html/hyper-json/smart-tags/coalesced/if/index.js +6 -6
- package/agnostic/html/hyper-json/smart-tags/coalesced/initialize/index.js +6 -6
- package/agnostic/html/hyper-json/smart-tags/coalesced/join/index.js +6 -6
- package/agnostic/html/hyper-json/smart-tags/coalesced/length/index.js +6 -6
- package/agnostic/html/hyper-json/smart-tags/coalesced/map/index.js +6 -6
- package/agnostic/html/hyper-json/smart-tags/coalesced/negate/index.js +6 -6
- package/agnostic/html/hyper-json/smart-tags/coalesced/notrailing/index.js +6 -6
- package/agnostic/html/hyper-json/smart-tags/coalesced/or/index.js +6 -6
- package/agnostic/html/hyper-json/smart-tags/coalesced/pickrandom/index.js +6 -6
- package/agnostic/html/hyper-json/smart-tags/coalesced/populate/index.js +6 -6
- package/agnostic/html/hyper-json/smart-tags/coalesced/print/index.js +6 -6
- package/agnostic/html/hyper-json/smart-tags/coalesced/push/index.js +6 -6
- package/agnostic/html/hyper-json/smart-tags/coalesced/pusheach/index.js +6 -6
- package/agnostic/html/hyper-json/smart-tags/coalesced/recordtoarray/index.js +6 -6
- package/agnostic/html/hyper-json/smart-tags/coalesced/removeattribute/index.js +6 -6
- package/agnostic/html/hyper-json/smart-tags/coalesced/removeclass/index.js +6 -6
- package/agnostic/html/hyper-json/smart-tags/coalesced/renameproperty/index.js +6 -6
- package/agnostic/html/hyper-json/smart-tags/coalesced/replace/index.js +6 -6
- package/agnostic/html/hyper-json/smart-tags/coalesced/select/index.js +6 -6
- package/agnostic/html/hyper-json/smart-tags/coalesced/set/index.js +6 -6
- package/agnostic/html/hyper-json/smart-tags/coalesced/setattribute/index.js +6 -6
- package/agnostic/html/hyper-json/smart-tags/coalesced/setproperty/index.js +6 -6
- package/agnostic/html/hyper-json/smart-tags/coalesced/sorton/index.js +6 -6
- package/agnostic/html/hyper-json/smart-tags/coalesced/split/index.js +6 -6
- package/agnostic/html/hyper-json/smart-tags/coalesced/spread/index.js +6 -6
- package/agnostic/html/hyper-json/smart-tags/coalesced/toarray/index.js +6 -6
- package/agnostic/html/hyper-json/smart-tags/coalesced/toboolean/index.js +6 -6
- package/agnostic/html/hyper-json/smart-tags/coalesced/toelement/index.js +6 -6
- package/agnostic/html/hyper-json/smart-tags/coalesced/toggleclass/index.js +6 -6
- package/agnostic/html/hyper-json/smart-tags/coalesced/tonodelist/index.js +6 -6
- package/agnostic/html/hyper-json/smart-tags/coalesced/tonull/index.js +6 -6
- package/agnostic/html/hyper-json/smart-tags/coalesced/tonumber/index.js +6 -6
- package/agnostic/html/hyper-json/smart-tags/coalesced/torecord/index.js +6 -6
- package/agnostic/html/hyper-json/smart-tags/coalesced/toref/index.js +6 -6
- package/agnostic/html/hyper-json/smart-tags/coalesced/tostring/index.js +6 -6
- package/agnostic/html/hyper-json/smart-tags/coalesced/totext/index.js +6 -6
- package/agnostic/html/hyper-json/smart-tags/coalesced/transformselected/index.js +6 -6
- package/agnostic/html/hyper-json/smart-tags/coalesced/trim/index.js +6 -6
- package/agnostic/html/hyper-json/smart-tags/isolated/boolean/index.js +6 -6
- package/agnostic/html/hyper-json/smart-tags/isolated/element/index.js +6 -6
- package/agnostic/html/hyper-json/smart-tags/isolated/get/index.js +6 -6
- package/agnostic/html/hyper-json/smart-tags/isolated/global/index.js +6 -6
- package/agnostic/html/hyper-json/smart-tags/isolated/guess/index.js +6 -6
- package/agnostic/html/hyper-json/smart-tags/isolated/nodelist/index.js +6 -6
- package/agnostic/html/hyper-json/smart-tags/isolated/number/index.js +6 -6
- package/agnostic/html/hyper-json/smart-tags/isolated/record/index.js +6 -6
- package/agnostic/html/hyper-json/smart-tags/isolated/ref/index.js +6 -6
- package/agnostic/html/hyper-json/smart-tags/isolated/string/index.js +6 -6
- package/agnostic/html/hyper-json/smart-tags/isolated/text/index.js +6 -6
- package/agnostic/html/hyper-json/tree/index.js +6 -6
- package/agnostic/html/hyper-json/utils/index.js +6 -6
- package/agnostic/html/index.js +22 -22
- package/agnostic/html/sanitize/index.js +6 -6
- package/agnostic/html/selector-to-element/index.js +6 -6
- package/agnostic/html/string-to-nodes/index.js +7 -7
- package/agnostic/index.d.ts +1 -1
- package/agnostic/misc/assert/index.js +3 -3
- package/agnostic/misc/crossenv/index.js +2 -2
- package/agnostic/misc/index.js +25 -25
- package/agnostic/misc/lorem-ipsum/index.js +13 -13
- package/agnostic/numbers/index.js +6 -6
- package/agnostic/objects/index.js +15 -15
- package/agnostic/random/index.js +2 -2
- package/agnostic/strings/index.js +11 -11
- package/agnostic/time/index.js +6 -6
- package/chunks/chunk-2EHYEUX4.js +21 -0
- package/chunks/chunk-5LK2YLTK.js +21 -0
- package/chunks/chunk-65NTXENV.js +157 -0
- package/chunks/{chunk-XDITZ5QN.js → chunk-AF2NAJS2.js} +2 -2
- package/chunks/chunk-ALMK24GK.js +0 -0
- package/chunks/chunk-BKIF2ELV.js +47 -0
- package/chunks/{chunk-B446JIN3.js → chunk-C7SRAQMW.js} +1 -1
- package/chunks/{chunk-36CTYZYA.js → chunk-CQEDNACN.js} +2 -2
- package/chunks/chunk-D7SXHHU3.js +47 -0
- package/chunks/{chunk-IWDIKDYR.js → chunk-E33DCHHS.js} +13 -13
- package/chunks/{chunk-WAMSK4A3.js → chunk-E4FJHD5R.js} +1 -1
- package/chunks/chunk-GUBFCOBT.js +98 -0
- package/chunks/{chunk-Q6DUKZU6.js → chunk-I2HTBYNO.js} +6 -6
- package/chunks/chunk-IDXUS2IO.js +296 -0
- package/chunks/chunk-JHUOMGOX.js +81 -0
- package/chunks/{chunk-EDJ3TVNV.js → chunk-KDOMQ4LM.js} +15 -6
- package/chunks/chunk-MN4FVOU2.js +28 -0
- package/chunks/{chunk-2M33FCDG.js → chunk-O7VFJHQX.js} +11 -5
- package/chunks/{chunk-2UAVBQI5.js → chunk-OD2XVVE2.js} +4 -4
- package/chunks/{chunk-CHUOCTRP.js → chunk-P2H6PV4O.js} +2 -2
- package/chunks/chunk-P4YT4RBG.js +51 -0
- package/chunks/{chunk-CYUEPBUN.js → chunk-PX4DPCZM.js} +2 -2
- package/chunks/{chunk-YIZODJC7.js → chunk-QRS3G3YD.js} +5 -5
- package/chunks/{chunk-FQ4UTWMP.js → chunk-QTA7ZEVX.js} +3 -1
- package/chunks/chunk-QW34TQCS.js +48 -0
- package/chunks/{chunk-HMAK6VAF.js → chunk-RBCZWVQH.js} +11 -5
- package/chunks/{chunk-JWF5EKM2.js → chunk-RDQJSWRC.js} +1 -1
- package/chunks/{chunk-AI6AGF4I.js → chunk-S7637BQZ.js} +8 -5
- package/chunks/{chunk-GVQVGFAA.js → chunk-TQXFC6OS.js} +4 -4
- package/chunks/chunk-UG5EMKGN.js +265 -0
- package/chunks/chunk-VA67YLZL.js +26 -0
- package/chunks/{chunk-TSZAQ3RQ.js → chunk-VKNQ7MVZ.js} +86 -87
- package/chunks/{chunk-SA2IY5LN.js → chunk-X5HMM3LD.js} +1 -1
- package/chunks/chunk-XAYMIITK.js +103 -0
- package/chunks/chunk-YZVZKBVJ.js +631 -0
- package/chunks/chunk-ZJ63OCMA.js +207 -0
- package/node/@aws-s3/index.js +8 -8
- package/node/@aws-s3/storage/directory/index.js +7 -7
- package/node/@aws-s3/storage/file/index.js +10 -10
- package/node/@aws-s3/storage/index.js +10 -10
- package/node/@google-cloud/index.js +11 -11
- package/node/@google-cloud/storage/bucket/index.js +4 -4
- package/node/@google-cloud/storage/directory/index.js +7 -7
- package/node/@google-cloud/storage/file/index.js +14 -14
- package/node/@google-cloud/storage/file/revoke-signed-urls/index.js +2 -2
- package/node/@google-cloud/storage/index.js +13 -13
- package/node/cloud-storage/index.js +26 -26
- package/node/cloud-storage/operations/index.js +36 -36
- package/node/encryption/index.js +3 -3
- package/node/files/index.js +3 -3
- package/node/ftps/directory/index.js +7 -7
- package/node/ftps/file/index.js +10 -10
- package/node/ftps/index.js +9 -9
- package/node/images/create/index.d.ts +3 -0
- package/node/images/create/index.js +23 -0
- package/node/images/format/index.d.ts +17 -51
- package/node/images/format/index.js +30 -4
- package/node/images/index.d.ts +4 -2
- package/node/images/index.js +41 -21
- package/node/images/metadata/index.d.ts +3 -0
- package/node/images/metadata/index.js +23 -0
- package/node/images/transform/index.d.ts +2 -97
- package/node/images/transform/index.js +27 -16
- package/node/images/transform/operations/blur/index.d.ts +1 -3
- package/node/images/transform/operations/brighten/index.d.ts +1 -3
- package/node/images/transform/operations/extend/index.d.ts +1 -8
- package/node/images/transform/operations/extend/index.js +17 -2
- package/node/images/transform/operations/extract/index.d.ts +1 -6
- package/node/images/transform/operations/flatten/index.d.ts +1 -3
- package/node/images/transform/operations/flatten/index.js +17 -2
- package/node/images/transform/operations/hue/index.d.ts +1 -3
- package/node/images/transform/operations/level/index.d.ts +1 -4
- package/node/images/transform/operations/lighten/index.d.ts +1 -3
- package/node/images/transform/operations/normalize/index.d.ts +1 -4
- package/node/images/transform/operations/overlay/index.d.ts +5 -0
- package/node/images/transform/operations/overlay/index.js +27 -0
- package/node/images/transform/operations/resize/index.d.ts +1 -11
- package/node/images/transform/operations/resize/index.js +17 -2
- package/node/images/transform/operations/rotate/index.d.ts +1 -4
- package/node/images/transform/operations/rotate/index.js +17 -2
- package/node/images/transform/operations/saturate/index.d.ts +1 -3
- package/node/images/transform/operations/saturate/index.js +1 -1
- package/node/images/types.d.ts +252 -0
- package/node/images/utils/index.d.ts +7 -0
- package/node/images/utils/index.js +28 -0
- package/node/sftp/directory/index.js +7 -7
- package/node/sftp/file/index.js +10 -10
- package/node/sftp/index.js +9 -9
- package/package.json +1 -1
- package/agnostic/colors/complement-color/index.d.ts +0 -1
- package/agnostic/colors/complement-color/index.js +0 -7
- package/agnostic/colors/hex-to-rgb/index.d.ts +0 -1
- package/agnostic/colors/hex-to-rgb/index.js +0 -7
- package/agnostic/colors/hsl-to-rgb/index.d.ts +0 -1
- package/agnostic/colors/hsl-to-rgb/index.js +0 -7
- package/agnostic/colors/lighten-color/index.d.ts +0 -2
- package/agnostic/colors/lighten-color/index.js +0 -11
- package/agnostic/colors/rgb-to-hex/index.d.ts +0 -1
- package/agnostic/colors/rgb-to-hex/index.js +0 -7
- package/agnostic/colors/rgb-to-hsl/index.d.ts +0 -1
- package/agnostic/colors/rgb-to-hsl/index.js +0 -7
- package/agnostic/colors/saturate-color/index.d.ts +0 -2
- package/agnostic/colors/saturate-color/index.js +0 -11
- package/chunks/chunk-2POD3TAX.js +0 -11
- package/chunks/chunk-2TJCB6IM.js +0 -12
- package/chunks/chunk-7EDDWSWS.js +0 -123
- package/chunks/chunk-FAXNZG5C.js +0 -10
- package/chunks/chunk-IFQA5PWI.js +0 -112
- package/chunks/chunk-MB7HWF22.js +0 -23
- package/chunks/chunk-MFYNJMVM.js +0 -18
- package/chunks/chunk-NYVARFI7.js +0 -20
- package/chunks/chunk-QLC3A6PC.js +0 -17
- package/chunks/chunk-U57Q62IN.js +0 -23
- package/chunks/chunk-YVLJKJV2.js +0 -17
- package/node/images/get-metadata/index.d.ts +0 -4
- package/node/images/get-metadata/index.js +0 -7
- package/node/images/transform/operations/composite/index.d.ts +0 -7
- package/node/images/transform/operations/composite/index.js +0 -12
- package/node/images/transform/utils/index.d.ts +0 -2
- package/node/images/transform/utils/index.js +0 -8
- package/chunks/{chunk-WH6BPDAC.js → chunk-2KT7AKRW.js} +3 -3
- package/chunks/{chunk-JSW6R3ZH.js → chunk-6QFELK4E.js} +9 -9
- package/chunks/{chunk-LAVXHKKR.js → chunk-73FF7HWQ.js} +9 -9
- package/chunks/{chunk-74CFPDKM.js → chunk-A7K5DUP7.js} +6 -6
- package/chunks/{chunk-7KSMK42F.js → chunk-CNMP2GU4.js} +6 -6
- package/chunks/{chunk-DEQWCMAL.js → chunk-EXPVRDPR.js} +9 -9
- package/chunks/{chunk-UFKH5WD2.js → chunk-FR5H2OCV.js} +3 -3
- package/chunks/{chunk-G5RRNREY.js → chunk-LSZVKXDZ.js} +3 -3
- package/chunks/{chunk-QCMBG5LN.js → chunk-MLLP7YSK.js} +13 -13
- package/chunks/{chunk-IOJTC6CN.js → chunk-PJSPZGT2.js} +15 -15
- package/chunks/{chunk-OVG5RGI3.js → chunk-S32K7POB.js} +4 -4
- package/chunks/{chunk-UXEKCYL7.js → chunk-UEAMPAHK.js} +3 -3
- package/chunks/{chunk-AIC5YAJU.js → chunk-X5F6XGEP.js} +6 -6
- package/chunks/{chunk-4OK2UH4M.js → chunk-ZBAKY6DB.js} +6 -6
|
@@ -1,32 +1,43 @@
|
|
|
1
1
|
import {
|
|
2
|
-
OpName,
|
|
3
|
-
TransformErrCodes,
|
|
4
2
|
isOperationDescriptor,
|
|
5
3
|
transform
|
|
6
|
-
} from "../../../chunks/chunk-
|
|
7
|
-
import "../../../chunks/chunk-FQ4UTWMP.js";
|
|
8
|
-
import "../../../chunks/chunk-YA2YCZUF.js";
|
|
9
|
-
import "../../../chunks/chunk-WNDMYNDU.js";
|
|
10
|
-
import "../../../chunks/chunk-QSU3CVGF.js";
|
|
4
|
+
} from "../../../chunks/chunk-VKNQ7MVZ.js";
|
|
11
5
|
import "../../../chunks/chunk-2HJPX7E3.js";
|
|
12
|
-
import "../../../chunks/chunk-3G6FOHII.js";
|
|
13
|
-
import "../../../chunks/chunk-EDJ3TVNV.js";
|
|
14
|
-
import "../../../chunks/chunk-AI6AGF4I.js";
|
|
15
6
|
import "../../../chunks/chunk-RHKFMXM3.js";
|
|
7
|
+
import "../../../chunks/chunk-3G6FOHII.js";
|
|
8
|
+
import "../../../chunks/chunk-KDOMQ4LM.js";
|
|
9
|
+
import "../../../chunks/chunk-S7637BQZ.js";
|
|
10
|
+
import "../../../chunks/chunk-QTA7ZEVX.js";
|
|
11
|
+
import "../../../chunks/chunk-JHUOMGOX.js";
|
|
16
12
|
import "../../../chunks/chunk-P26Y7YUA.js";
|
|
17
13
|
import "../../../chunks/chunk-SRXNICSE.js";
|
|
18
|
-
import "../../../chunks/chunk-
|
|
19
|
-
import "../../../chunks/chunk-
|
|
20
|
-
import "../../../chunks/chunk-
|
|
14
|
+
import "../../../chunks/chunk-RBCZWVQH.js";
|
|
15
|
+
import "../../../chunks/chunk-O7VFJHQX.js";
|
|
16
|
+
import "../../../chunks/chunk-QSU3CVGF.js";
|
|
17
|
+
import "../../../chunks/chunk-WNDMYNDU.js";
|
|
18
|
+
import "../../../chunks/chunk-YA2YCZUF.js";
|
|
21
19
|
import "../../../chunks/chunk-HFZGH6V2.js";
|
|
22
|
-
import "../../../chunks/chunk-MFYNJMVM.js";
|
|
23
20
|
import "../../../chunks/chunk-DZ2T5DTY.js";
|
|
21
|
+
import "../../../chunks/chunk-BKIF2ELV.js";
|
|
24
22
|
import "../../../chunks/chunk-JMU5PDBD.js";
|
|
23
|
+
import "../../../chunks/chunk-ALMK24GK.js";
|
|
24
|
+
import "../../../chunks/chunk-65NTXENV.js";
|
|
25
|
+
import "../../../chunks/chunk-D7SXHHU3.js";
|
|
26
|
+
import "../../../chunks/chunk-GUBFCOBT.js";
|
|
27
|
+
import "../../../chunks/chunk-XAYMIITK.js";
|
|
28
|
+
import "../../../chunks/chunk-QW34TQCS.js";
|
|
29
|
+
import "../../../chunks/chunk-ZJ63OCMA.js";
|
|
30
|
+
import "../../../chunks/chunk-MN4FVOU2.js";
|
|
31
|
+
import "../../../chunks/chunk-VA67YLZL.js";
|
|
32
|
+
import "../../../chunks/chunk-P4YT4RBG.js";
|
|
33
|
+
import "../../../chunks/chunk-YZVZKBVJ.js";
|
|
34
|
+
import "../../../chunks/chunk-DNIOWD7K.js";
|
|
35
|
+
import "../../../chunks/chunk-OSAXBA7G.js";
|
|
36
|
+
import "../../../chunks/chunk-UG5EMKGN.js";
|
|
37
|
+
import "../../../chunks/chunk-HQLRJ7XW.js";
|
|
25
38
|
import "../../../chunks/chunk-FENXVJYO.js";
|
|
26
39
|
import "../../../chunks/chunk-WSFCRVEQ.js";
|
|
27
40
|
export {
|
|
28
|
-
OpName,
|
|
29
|
-
TransformErrCodes,
|
|
30
41
|
isOperationDescriptor,
|
|
31
42
|
transform
|
|
32
43
|
};
|
|
@@ -1,7 +1,5 @@
|
|
|
1
1
|
import sharp from 'sharp';
|
|
2
2
|
import { Outcome } from '../../../../../agnostic/misc/outcome/index.js';
|
|
3
|
-
|
|
4
|
-
sigma: number;
|
|
5
|
-
};
|
|
3
|
+
import type { BlurOperationParams } from '../../../types.js';
|
|
6
4
|
export declare function isBlurOperationParams(obj: unknown): Outcome.Either<BlurOperationParams, string>;
|
|
7
5
|
export declare function blur(sharpInstance: sharp.Sharp, params: BlurOperationParams): Promise<sharp.Sharp>;
|
|
@@ -1,7 +1,5 @@
|
|
|
1
1
|
import sharp from 'sharp';
|
|
2
2
|
import { Outcome } from '../../../../../agnostic/misc/outcome/index.js';
|
|
3
|
-
|
|
4
|
-
factor: number;
|
|
5
|
-
};
|
|
3
|
+
import type { BrightenOperationParams } from '../../../types.js';
|
|
6
4
|
export declare function isBrightenOperationParams(obj: unknown): Outcome.Either<BrightenOperationParams, string>;
|
|
7
5
|
export declare function brighten(sharpInstance: sharp.Sharp, params: BrightenOperationParams): Promise<sharp.Sharp>;
|
|
@@ -1,12 +1,5 @@
|
|
|
1
1
|
import sharp from 'sharp';
|
|
2
2
|
import { Outcome } from '../../../../../agnostic/misc/outcome/index.js';
|
|
3
|
-
|
|
4
|
-
left?: number;
|
|
5
|
-
right?: number;
|
|
6
|
-
top?: number;
|
|
7
|
-
bottom?: number;
|
|
8
|
-
extendWith?: sharp.ExtendWith;
|
|
9
|
-
background?: sharp.Color;
|
|
10
|
-
};
|
|
3
|
+
import type { ExtendOperationParams } from '../../../types.js';
|
|
11
4
|
export declare function isExtendOperationParams(obj: unknown): Outcome.Either<ExtendOperationParams, string>;
|
|
12
5
|
export declare function extend(sharpInstance: sharp.Sharp, params: ExtendOperationParams): Promise<sharp.Sharp>;
|
|
@@ -1,10 +1,25 @@
|
|
|
1
1
|
import {
|
|
2
2
|
extend,
|
|
3
3
|
isExtendOperationParams
|
|
4
|
-
} from "../../../../../chunks/chunk-
|
|
5
|
-
import "../../../../../chunks/chunk-MFYNJMVM.js";
|
|
4
|
+
} from "../../../../../chunks/chunk-RBCZWVQH.js";
|
|
6
5
|
import "../../../../../chunks/chunk-DZ2T5DTY.js";
|
|
6
|
+
import "../../../../../chunks/chunk-BKIF2ELV.js";
|
|
7
7
|
import "../../../../../chunks/chunk-JMU5PDBD.js";
|
|
8
|
+
import "../../../../../chunks/chunk-ALMK24GK.js";
|
|
9
|
+
import "../../../../../chunks/chunk-65NTXENV.js";
|
|
10
|
+
import "../../../../../chunks/chunk-D7SXHHU3.js";
|
|
11
|
+
import "../../../../../chunks/chunk-GUBFCOBT.js";
|
|
12
|
+
import "../../../../../chunks/chunk-XAYMIITK.js";
|
|
13
|
+
import "../../../../../chunks/chunk-QW34TQCS.js";
|
|
14
|
+
import "../../../../../chunks/chunk-ZJ63OCMA.js";
|
|
15
|
+
import "../../../../../chunks/chunk-MN4FVOU2.js";
|
|
16
|
+
import "../../../../../chunks/chunk-VA67YLZL.js";
|
|
17
|
+
import "../../../../../chunks/chunk-P4YT4RBG.js";
|
|
18
|
+
import "../../../../../chunks/chunk-YZVZKBVJ.js";
|
|
19
|
+
import "../../../../../chunks/chunk-DNIOWD7K.js";
|
|
20
|
+
import "../../../../../chunks/chunk-OSAXBA7G.js";
|
|
21
|
+
import "../../../../../chunks/chunk-UG5EMKGN.js";
|
|
22
|
+
import "../../../../../chunks/chunk-HQLRJ7XW.js";
|
|
8
23
|
import "../../../../../chunks/chunk-WSFCRVEQ.js";
|
|
9
24
|
export {
|
|
10
25
|
extend,
|
|
@@ -1,10 +1,5 @@
|
|
|
1
1
|
import sharp from 'sharp';
|
|
2
2
|
import { Outcome } from '../../../../../agnostic/misc/outcome/index.js';
|
|
3
|
-
|
|
4
|
-
left: number;
|
|
5
|
-
top: number;
|
|
6
|
-
width: number;
|
|
7
|
-
height: number;
|
|
8
|
-
};
|
|
3
|
+
import type { ExtractOperationParams } from '../../../types.js';
|
|
9
4
|
export declare function isExtractOperationParams(obj: unknown): Outcome.Either<ExtractOperationParams, string>;
|
|
10
5
|
export declare function extract(sharpInstance: sharp.Sharp, params: ExtractOperationParams): Promise<sharp.Sharp>;
|
|
@@ -1,7 +1,5 @@
|
|
|
1
1
|
import sharp from 'sharp';
|
|
2
2
|
import { Outcome } from '../../../../../agnostic/misc/outcome/index.js';
|
|
3
|
-
|
|
4
|
-
background?: sharp.Color;
|
|
5
|
-
};
|
|
3
|
+
import type { FlattenOperationParams } from '../../../types.js';
|
|
6
4
|
export declare function isFlattenOperationParams(obj: unknown): Outcome.Either<FlattenOperationParams, string>;
|
|
7
5
|
export declare function flatten(sharpInstance: sharp.Sharp, params: FlattenOperationParams): Promise<sharp.Sharp>;
|
|
@@ -1,10 +1,25 @@
|
|
|
1
1
|
import {
|
|
2
2
|
flatten,
|
|
3
3
|
isFlattenOperationParams
|
|
4
|
-
} from "../../../../../chunks/chunk-
|
|
5
|
-
import "../../../../../chunks/chunk-MFYNJMVM.js";
|
|
4
|
+
} from "../../../../../chunks/chunk-O7VFJHQX.js";
|
|
6
5
|
import "../../../../../chunks/chunk-DZ2T5DTY.js";
|
|
6
|
+
import "../../../../../chunks/chunk-BKIF2ELV.js";
|
|
7
7
|
import "../../../../../chunks/chunk-JMU5PDBD.js";
|
|
8
|
+
import "../../../../../chunks/chunk-ALMK24GK.js";
|
|
9
|
+
import "../../../../../chunks/chunk-65NTXENV.js";
|
|
10
|
+
import "../../../../../chunks/chunk-D7SXHHU3.js";
|
|
11
|
+
import "../../../../../chunks/chunk-GUBFCOBT.js";
|
|
12
|
+
import "../../../../../chunks/chunk-XAYMIITK.js";
|
|
13
|
+
import "../../../../../chunks/chunk-QW34TQCS.js";
|
|
14
|
+
import "../../../../../chunks/chunk-ZJ63OCMA.js";
|
|
15
|
+
import "../../../../../chunks/chunk-MN4FVOU2.js";
|
|
16
|
+
import "../../../../../chunks/chunk-VA67YLZL.js";
|
|
17
|
+
import "../../../../../chunks/chunk-P4YT4RBG.js";
|
|
18
|
+
import "../../../../../chunks/chunk-YZVZKBVJ.js";
|
|
19
|
+
import "../../../../../chunks/chunk-DNIOWD7K.js";
|
|
20
|
+
import "../../../../../chunks/chunk-OSAXBA7G.js";
|
|
21
|
+
import "../../../../../chunks/chunk-UG5EMKGN.js";
|
|
22
|
+
import "../../../../../chunks/chunk-HQLRJ7XW.js";
|
|
8
23
|
import "../../../../../chunks/chunk-WSFCRVEQ.js";
|
|
9
24
|
export {
|
|
10
25
|
flatten,
|
|
@@ -1,7 +1,5 @@
|
|
|
1
1
|
import sharp from 'sharp';
|
|
2
2
|
import { Outcome } from '../../../../../agnostic/misc/outcome/index.js';
|
|
3
|
-
|
|
4
|
-
rotateDeg?: number;
|
|
5
|
-
};
|
|
3
|
+
import type { HueOperationParams } from '../../../types.js';
|
|
6
4
|
export declare function isHueOperationParams(obj: unknown): Outcome.Either<HueOperationParams, string>;
|
|
7
5
|
export declare function hue(sharpInstance: sharp.Sharp, params: HueOperationParams): Promise<sharp.Sharp>;
|
|
@@ -1,8 +1,5 @@
|
|
|
1
1
|
import sharp from 'sharp';
|
|
2
2
|
import { Outcome } from '../../../../../agnostic/misc/outcome/index.js';
|
|
3
|
-
|
|
4
|
-
multiplier?: number;
|
|
5
|
-
offset?: number;
|
|
6
|
-
};
|
|
3
|
+
import type { LevelOperationParams } from '../../../types.js';
|
|
7
4
|
export declare function isLevelOperationParams(obj: unknown): Outcome.Either<LevelOperationParams, string>;
|
|
8
5
|
export declare function level(sharpInstance: sharp.Sharp, params: LevelOperationParams): Promise<sharp.Sharp>;
|
|
@@ -1,7 +1,5 @@
|
|
|
1
1
|
import sharp from 'sharp';
|
|
2
2
|
import { Outcome } from '../../../../../agnostic/misc/outcome/index.js';
|
|
3
|
-
|
|
4
|
-
amount?: number;
|
|
5
|
-
};
|
|
3
|
+
import type { LightenOperationParams } from '../../../types.js';
|
|
6
4
|
export declare function isLightenOperationParams(obj: unknown): Outcome.Either<LightenOperationParams, string>;
|
|
7
5
|
export declare function lighten(sharpInstance: sharp.Sharp, params: LightenOperationParams): Promise<sharp.Sharp>;
|
|
@@ -1,8 +1,5 @@
|
|
|
1
1
|
import sharp from 'sharp';
|
|
2
2
|
import { Outcome } from '../../../../../agnostic/misc/outcome/index.js';
|
|
3
|
-
|
|
4
|
-
lower?: number;
|
|
5
|
-
upper?: number;
|
|
6
|
-
};
|
|
3
|
+
import type { NormalizeOperationParams } from '../../../types.js';
|
|
7
4
|
export declare function isNormalizeOperationParams(obj: unknown): Outcome.Either<NormalizeOperationParams, string>;
|
|
8
5
|
export declare function normalize(sharpInstance: sharp.Sharp, params: NormalizeOperationParams): Promise<sharp.Sharp>;
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
import sharp from 'sharp';
|
|
2
|
+
import { Outcome } from '../../../../../agnostic/misc/outcome/index.js';
|
|
3
|
+
import type { OverlayOperationParams } from '../../../types.js';
|
|
4
|
+
export declare function isOverlayOperationParams(obj: unknown): Outcome.Either<OverlayOperationParams, string>;
|
|
5
|
+
export declare function overlay(sharpInstance: sharp.Sharp, params: OverlayOperationParams): Promise<sharp.Sharp>;
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
import {
|
|
2
|
+
isOverlayOperationParams,
|
|
3
|
+
overlay
|
|
4
|
+
} from "../../../../../chunks/chunk-JHUOMGOX.js";
|
|
5
|
+
import "../../../../../chunks/chunk-DZ2T5DTY.js";
|
|
6
|
+
import "../../../../../chunks/chunk-BKIF2ELV.js";
|
|
7
|
+
import "../../../../../chunks/chunk-JMU5PDBD.js";
|
|
8
|
+
import "../../../../../chunks/chunk-ALMK24GK.js";
|
|
9
|
+
import "../../../../../chunks/chunk-65NTXENV.js";
|
|
10
|
+
import "../../../../../chunks/chunk-D7SXHHU3.js";
|
|
11
|
+
import "../../../../../chunks/chunk-GUBFCOBT.js";
|
|
12
|
+
import "../../../../../chunks/chunk-XAYMIITK.js";
|
|
13
|
+
import "../../../../../chunks/chunk-QW34TQCS.js";
|
|
14
|
+
import "../../../../../chunks/chunk-ZJ63OCMA.js";
|
|
15
|
+
import "../../../../../chunks/chunk-MN4FVOU2.js";
|
|
16
|
+
import "../../../../../chunks/chunk-VA67YLZL.js";
|
|
17
|
+
import "../../../../../chunks/chunk-P4YT4RBG.js";
|
|
18
|
+
import "../../../../../chunks/chunk-YZVZKBVJ.js";
|
|
19
|
+
import "../../../../../chunks/chunk-DNIOWD7K.js";
|
|
20
|
+
import "../../../../../chunks/chunk-OSAXBA7G.js";
|
|
21
|
+
import "../../../../../chunks/chunk-UG5EMKGN.js";
|
|
22
|
+
import "../../../../../chunks/chunk-HQLRJ7XW.js";
|
|
23
|
+
import "../../../../../chunks/chunk-WSFCRVEQ.js";
|
|
24
|
+
export {
|
|
25
|
+
isOverlayOperationParams,
|
|
26
|
+
overlay
|
|
27
|
+
};
|
|
@@ -1,15 +1,5 @@
|
|
|
1
1
|
import sharp from 'sharp';
|
|
2
2
|
import { Outcome } from '../../../../../agnostic/misc/outcome/index.js';
|
|
3
|
-
|
|
4
|
-
width?: number;
|
|
5
|
-
height?: number;
|
|
6
|
-
fit?: keyof sharp.FitEnum;
|
|
7
|
-
position?: number | string;
|
|
8
|
-
background?: sharp.Color;
|
|
9
|
-
kernel?: keyof sharp.KernelEnum;
|
|
10
|
-
withoutEnlargement?: boolean;
|
|
11
|
-
withoutReduction?: boolean;
|
|
12
|
-
fastShrinkOnLoad?: boolean;
|
|
13
|
-
};
|
|
3
|
+
import type { ResizeOperationParams } from '../../../types.js';
|
|
14
4
|
export declare function isResizeOperationParams(obj: unknown): Outcome.Either<ResizeOperationParams, string>;
|
|
15
5
|
export declare function resize(sharpInstance: sharp.Sharp, params: ResizeOperationParams): Promise<sharp.Sharp>;
|
|
@@ -1,10 +1,25 @@
|
|
|
1
1
|
import {
|
|
2
2
|
isResizeOperationParams,
|
|
3
3
|
resize
|
|
4
|
-
} from "../../../../../chunks/chunk-
|
|
5
|
-
import "../../../../../chunks/chunk-MFYNJMVM.js";
|
|
4
|
+
} from "../../../../../chunks/chunk-KDOMQ4LM.js";
|
|
6
5
|
import "../../../../../chunks/chunk-DZ2T5DTY.js";
|
|
6
|
+
import "../../../../../chunks/chunk-BKIF2ELV.js";
|
|
7
7
|
import "../../../../../chunks/chunk-JMU5PDBD.js";
|
|
8
|
+
import "../../../../../chunks/chunk-ALMK24GK.js";
|
|
9
|
+
import "../../../../../chunks/chunk-65NTXENV.js";
|
|
10
|
+
import "../../../../../chunks/chunk-D7SXHHU3.js";
|
|
11
|
+
import "../../../../../chunks/chunk-GUBFCOBT.js";
|
|
12
|
+
import "../../../../../chunks/chunk-XAYMIITK.js";
|
|
13
|
+
import "../../../../../chunks/chunk-QW34TQCS.js";
|
|
14
|
+
import "../../../../../chunks/chunk-ZJ63OCMA.js";
|
|
15
|
+
import "../../../../../chunks/chunk-MN4FVOU2.js";
|
|
16
|
+
import "../../../../../chunks/chunk-VA67YLZL.js";
|
|
17
|
+
import "../../../../../chunks/chunk-P4YT4RBG.js";
|
|
18
|
+
import "../../../../../chunks/chunk-YZVZKBVJ.js";
|
|
19
|
+
import "../../../../../chunks/chunk-DNIOWD7K.js";
|
|
20
|
+
import "../../../../../chunks/chunk-OSAXBA7G.js";
|
|
21
|
+
import "../../../../../chunks/chunk-UG5EMKGN.js";
|
|
22
|
+
import "../../../../../chunks/chunk-HQLRJ7XW.js";
|
|
8
23
|
import "../../../../../chunks/chunk-WSFCRVEQ.js";
|
|
9
24
|
export {
|
|
10
25
|
isResizeOperationParams,
|
|
@@ -1,8 +1,5 @@
|
|
|
1
1
|
import sharp from 'sharp';
|
|
2
2
|
import { Outcome } from '../../../../../agnostic/misc/outcome/index.js';
|
|
3
|
-
|
|
4
|
-
angleDeg?: number;
|
|
5
|
-
background?: sharp.Color;
|
|
6
|
-
};
|
|
3
|
+
import type { RotateOperationParams } from '../../../types.js';
|
|
7
4
|
export declare function isRotateOperationParams(obj: unknown): Outcome.Either<RotateOperationParams, string>;
|
|
8
5
|
export declare function rotate(sharpInstance: sharp.Sharp, params: RotateOperationParams): Promise<sharp.Sharp>;
|
|
@@ -1,10 +1,25 @@
|
|
|
1
1
|
import {
|
|
2
2
|
isRotateOperationParams,
|
|
3
3
|
rotate
|
|
4
|
-
} from "../../../../../chunks/chunk-
|
|
5
|
-
import "../../../../../chunks/chunk-MFYNJMVM.js";
|
|
4
|
+
} from "../../../../../chunks/chunk-S7637BQZ.js";
|
|
6
5
|
import "../../../../../chunks/chunk-DZ2T5DTY.js";
|
|
6
|
+
import "../../../../../chunks/chunk-BKIF2ELV.js";
|
|
7
7
|
import "../../../../../chunks/chunk-JMU5PDBD.js";
|
|
8
|
+
import "../../../../../chunks/chunk-ALMK24GK.js";
|
|
9
|
+
import "../../../../../chunks/chunk-65NTXENV.js";
|
|
10
|
+
import "../../../../../chunks/chunk-D7SXHHU3.js";
|
|
11
|
+
import "../../../../../chunks/chunk-GUBFCOBT.js";
|
|
12
|
+
import "../../../../../chunks/chunk-XAYMIITK.js";
|
|
13
|
+
import "../../../../../chunks/chunk-QW34TQCS.js";
|
|
14
|
+
import "../../../../../chunks/chunk-ZJ63OCMA.js";
|
|
15
|
+
import "../../../../../chunks/chunk-MN4FVOU2.js";
|
|
16
|
+
import "../../../../../chunks/chunk-VA67YLZL.js";
|
|
17
|
+
import "../../../../../chunks/chunk-P4YT4RBG.js";
|
|
18
|
+
import "../../../../../chunks/chunk-YZVZKBVJ.js";
|
|
19
|
+
import "../../../../../chunks/chunk-DNIOWD7K.js";
|
|
20
|
+
import "../../../../../chunks/chunk-OSAXBA7G.js";
|
|
21
|
+
import "../../../../../chunks/chunk-UG5EMKGN.js";
|
|
22
|
+
import "../../../../../chunks/chunk-HQLRJ7XW.js";
|
|
8
23
|
import "../../../../../chunks/chunk-WSFCRVEQ.js";
|
|
9
24
|
export {
|
|
10
25
|
isRotateOperationParams,
|
|
@@ -1,7 +1,5 @@
|
|
|
1
1
|
import sharp from 'sharp';
|
|
2
2
|
import { Outcome } from '../../../../../agnostic/misc/outcome/index.js';
|
|
3
|
-
|
|
4
|
-
saturation?: number;
|
|
5
|
-
};
|
|
3
|
+
import type { SaturateOperationParams } from '../../../types.js';
|
|
6
4
|
export declare function isSaturateOperationParams(obj: unknown): Outcome.Either<SaturateOperationParams, string>;
|
|
7
5
|
export declare function saturate(sharpInstance: sharp.Sharp, params: SaturateOperationParams): Promise<sharp.Sharp>;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import {
|
|
2
2
|
isSaturateOperationParams,
|
|
3
3
|
saturate
|
|
4
|
-
} from "../../../../../chunks/chunk-
|
|
4
|
+
} from "../../../../../chunks/chunk-QTA7ZEVX.js";
|
|
5
5
|
import "../../../../../chunks/chunk-DZ2T5DTY.js";
|
|
6
6
|
import "../../../../../chunks/chunk-JMU5PDBD.js";
|
|
7
7
|
import "../../../../../chunks/chunk-WSFCRVEQ.js";
|
|
@@ -0,0 +1,252 @@
|
|
|
1
|
+
import type { Sharp } from 'sharp';
|
|
2
|
+
import type { Color } from '../../agnostic/colors/types.js';
|
|
3
|
+
export type CreateOptions = {
|
|
4
|
+
width?: number;
|
|
5
|
+
height?: number;
|
|
6
|
+
channels?: 3 | 4;
|
|
7
|
+
background?: Color;
|
|
8
|
+
noise?: {
|
|
9
|
+
mean?: number;
|
|
10
|
+
sigma?: number;
|
|
11
|
+
};
|
|
12
|
+
pageHeight?: number;
|
|
13
|
+
};
|
|
14
|
+
export type ImageLike = Sharp | Buffer | CreateOptions | string;
|
|
15
|
+
export type FormatCommonOptions = {
|
|
16
|
+
width?: number;
|
|
17
|
+
height?: number;
|
|
18
|
+
fit?: 'contain' | 'cover' | 'fill' | 'inside' | 'outside';
|
|
19
|
+
position?: number | string;
|
|
20
|
+
background?: Color;
|
|
21
|
+
kernel?: 'nearest' | 'cubic' | 'linear' | 'mitchell' | 'lanczos2' | 'lanczos3' | 'mks2013' | 'mks2021';
|
|
22
|
+
withoutEnlargement?: boolean;
|
|
23
|
+
withoutReduction?: boolean;
|
|
24
|
+
fastShrinkOnLoad?: boolean;
|
|
25
|
+
};
|
|
26
|
+
export type FormatJpgOptions = FormatCommonOptions & {
|
|
27
|
+
type: 'jpg' | 'jpeg';
|
|
28
|
+
quality?: number;
|
|
29
|
+
force?: boolean;
|
|
30
|
+
progressive?: boolean;
|
|
31
|
+
chromaSubsampling?: string;
|
|
32
|
+
trellisQuantisation?: boolean;
|
|
33
|
+
overshootDeringing?: boolean;
|
|
34
|
+
optimizeScans?: boolean;
|
|
35
|
+
optimizeCoding?: boolean;
|
|
36
|
+
quantizationTable?: number;
|
|
37
|
+
mozjpeg?: boolean;
|
|
38
|
+
};
|
|
39
|
+
export type FormatPngOptions = FormatCommonOptions & {
|
|
40
|
+
type: 'png';
|
|
41
|
+
quality?: number;
|
|
42
|
+
force?: boolean;
|
|
43
|
+
progressive?: boolean;
|
|
44
|
+
compressionLevel?: number;
|
|
45
|
+
adaptiveFiltering?: boolean;
|
|
46
|
+
effort?: number;
|
|
47
|
+
palette?: boolean;
|
|
48
|
+
colors?: number;
|
|
49
|
+
dither?: number;
|
|
50
|
+
};
|
|
51
|
+
export type FormatWebpOptions = FormatCommonOptions & {
|
|
52
|
+
type: 'webp';
|
|
53
|
+
quality?: number;
|
|
54
|
+
force?: boolean;
|
|
55
|
+
alphaQuality?: number;
|
|
56
|
+
lossless?: boolean;
|
|
57
|
+
nearLossless?: boolean;
|
|
58
|
+
smartSubsample?: boolean;
|
|
59
|
+
smartDeblock?: boolean;
|
|
60
|
+
effort?: number;
|
|
61
|
+
minSize?: boolean;
|
|
62
|
+
mixed?: boolean;
|
|
63
|
+
preset?: 'default' | 'picture' | 'photo' | 'drawing' | 'icon' | 'text';
|
|
64
|
+
loop?: number;
|
|
65
|
+
delay?: number | number[];
|
|
66
|
+
};
|
|
67
|
+
export type FormatAvifOptions = FormatCommonOptions & {
|
|
68
|
+
type: 'avif';
|
|
69
|
+
quality?: number;
|
|
70
|
+
force?: boolean;
|
|
71
|
+
lossless?: boolean;
|
|
72
|
+
effort?: number;
|
|
73
|
+
chromaSubsampling?: string;
|
|
74
|
+
bitdepth?: 8 | 10 | 12;
|
|
75
|
+
};
|
|
76
|
+
export type FormatTiffOptions = FormatCommonOptions & {
|
|
77
|
+
type: 'tiff';
|
|
78
|
+
quality?: number;
|
|
79
|
+
force?: boolean;
|
|
80
|
+
compression?: 'none' | 'jpeg' | 'deflate' | 'packbits' | 'ccittfax4' | 'lzw' | 'webp' | 'zstd' | 'jp2k';
|
|
81
|
+
predictor?: 'none' | 'horizontal' | 'float';
|
|
82
|
+
pyramid?: boolean;
|
|
83
|
+
tile?: boolean;
|
|
84
|
+
tileWidth?: number;
|
|
85
|
+
tileHeight?: number;
|
|
86
|
+
xres?: number;
|
|
87
|
+
yres?: number;
|
|
88
|
+
bitdepth?: 1 | 2 | 4 | 8;
|
|
89
|
+
miniswhite?: boolean;
|
|
90
|
+
resolutionUnit?: 'inch' | 'cm';
|
|
91
|
+
};
|
|
92
|
+
export type FormatHeifOptions = FormatCommonOptions & {
|
|
93
|
+
type: 'heif';
|
|
94
|
+
quality?: number;
|
|
95
|
+
force?: boolean;
|
|
96
|
+
compression?: 'av1' | 'hevc';
|
|
97
|
+
lossless?: boolean;
|
|
98
|
+
effort?: number;
|
|
99
|
+
chromaSubsampling?: string;
|
|
100
|
+
bitdepth?: 8 | 10 | 12;
|
|
101
|
+
};
|
|
102
|
+
export type FormatOptions = FormatJpgOptions | FormatPngOptions | FormatWebpOptions | FormatAvifOptions | FormatTiffOptions | FormatHeifOptions | FormatCommonOptions;
|
|
103
|
+
export declare enum OpName {
|
|
104
|
+
BLUR = "blur",
|
|
105
|
+
BRIGHTEN = "brighten",
|
|
106
|
+
EXTEND = "extend",
|
|
107
|
+
EXTRACT = "extract",
|
|
108
|
+
FLATTEN = "flatten",
|
|
109
|
+
FLIP = "flip",
|
|
110
|
+
FLOP = "flop",
|
|
111
|
+
HUE = "hue",
|
|
112
|
+
LEVEL = "level",
|
|
113
|
+
LIGHTEN = "lighten",
|
|
114
|
+
NORMALIZE = "normalize",
|
|
115
|
+
OVERLAY = "overlay",
|
|
116
|
+
RESIZE = "resize",
|
|
117
|
+
ROTATE = "rotate",
|
|
118
|
+
SATURATE = "saturate"
|
|
119
|
+
}
|
|
120
|
+
export type BlurOperationParams = {
|
|
121
|
+
sigma: number;
|
|
122
|
+
};
|
|
123
|
+
export type BrightenOperationParams = {
|
|
124
|
+
factor: number;
|
|
125
|
+
};
|
|
126
|
+
export type ExtendOperationParams = {
|
|
127
|
+
left?: number;
|
|
128
|
+
right?: number;
|
|
129
|
+
top?: number;
|
|
130
|
+
bottom?: number;
|
|
131
|
+
extendWith?: 'background' | 'copy' | 'repeat' | 'mirror';
|
|
132
|
+
background?: Color;
|
|
133
|
+
};
|
|
134
|
+
export type ExtractOperationParams = {
|
|
135
|
+
left: number;
|
|
136
|
+
top: number;
|
|
137
|
+
width: number;
|
|
138
|
+
height: number;
|
|
139
|
+
};
|
|
140
|
+
export type FlattenOperationParams = {
|
|
141
|
+
background?: Color;
|
|
142
|
+
};
|
|
143
|
+
export type HueOperationParams = {
|
|
144
|
+
rotateDeg?: number;
|
|
145
|
+
};
|
|
146
|
+
export type LevelOperationParams = {
|
|
147
|
+
multiplier?: number;
|
|
148
|
+
offset?: number;
|
|
149
|
+
};
|
|
150
|
+
export type LightenOperationParams = {
|
|
151
|
+
amount?: number;
|
|
152
|
+
};
|
|
153
|
+
export type NormalizeOperationParams = {
|
|
154
|
+
lower?: number;
|
|
155
|
+
upper?: number;
|
|
156
|
+
};
|
|
157
|
+
export type OverlayOperationParams = {
|
|
158
|
+
input: Sharp;
|
|
159
|
+
top?: number;
|
|
160
|
+
left?: number;
|
|
161
|
+
tile?: boolean;
|
|
162
|
+
premultiplied?: boolean;
|
|
163
|
+
density?: number;
|
|
164
|
+
animated?: boolean;
|
|
165
|
+
autoOrient?: boolean;
|
|
166
|
+
ignoreIcc?: boolean;
|
|
167
|
+
pages?: number;
|
|
168
|
+
page?: number;
|
|
169
|
+
blend?: 'clear' | 'source' | 'over' | 'in' | 'out' | 'atop' | 'dest' | 'dest-over' | 'dest-in' | 'dest-out' | 'dest-atop' | 'xor' | 'add' | 'saturate' | 'multiply' | 'screen' | 'overlay' | 'darken' | 'lighten' | 'color-dodge' | 'colour-dodge' | 'color-burn' | 'colour-burn' | 'hard-light' | 'soft-light' | 'difference' | 'exclusion';
|
|
170
|
+
gravity?: 'north' | 'northeast' | 'southeast' | 'south' | 'southwest' | 'west' | 'northwest' | 'east' | 'center' | 'centre';
|
|
171
|
+
};
|
|
172
|
+
export type ResizeOperationParams = {
|
|
173
|
+
width?: number;
|
|
174
|
+
height?: number;
|
|
175
|
+
fit?: 'contain' | 'cover' | 'fill' | 'inside' | 'outside';
|
|
176
|
+
position?: number | string;
|
|
177
|
+
background?: Color;
|
|
178
|
+
kernel?: 'nearest' | 'cubic' | 'linear' | 'mitchell' | 'lanczos2' | 'lanczos3' | 'mks2013' | 'mks2021';
|
|
179
|
+
withoutEnlargement?: boolean;
|
|
180
|
+
withoutReduction?: boolean;
|
|
181
|
+
fastShrinkOnLoad?: boolean;
|
|
182
|
+
};
|
|
183
|
+
export type RotateOperationParams = {
|
|
184
|
+
angleDeg?: number;
|
|
185
|
+
background?: Color;
|
|
186
|
+
};
|
|
187
|
+
export type SaturateOperationParams = {
|
|
188
|
+
saturation?: number;
|
|
189
|
+
};
|
|
190
|
+
export type BlurOperationDescriptor = {
|
|
191
|
+
name: OpName.BLUR;
|
|
192
|
+
} & BlurOperationParams;
|
|
193
|
+
export type BrightenOperationDescriptor = {
|
|
194
|
+
name: OpName.BRIGHTEN;
|
|
195
|
+
} & BrightenOperationParams;
|
|
196
|
+
export type ExtendOperationDescriptor = {
|
|
197
|
+
name: OpName.EXTEND;
|
|
198
|
+
} & ExtendOperationParams;
|
|
199
|
+
export type ExtractOperationDescriptor = {
|
|
200
|
+
name: OpName.EXTRACT;
|
|
201
|
+
} & ExtractOperationParams;
|
|
202
|
+
export type FlattenOperationDescriptor = {
|
|
203
|
+
name: OpName.FLATTEN;
|
|
204
|
+
} & FlattenOperationParams;
|
|
205
|
+
export type FlipOperationDescriptor = {
|
|
206
|
+
name: OpName.FLIP;
|
|
207
|
+
};
|
|
208
|
+
export type FlopOperationDescriptor = {
|
|
209
|
+
name: OpName.FLOP;
|
|
210
|
+
};
|
|
211
|
+
export type HueOperationDescriptor = {
|
|
212
|
+
name: OpName.HUE;
|
|
213
|
+
} & HueOperationParams;
|
|
214
|
+
export type LevelOperationDescriptor = {
|
|
215
|
+
name: OpName.LEVEL;
|
|
216
|
+
} & LevelOperationParams;
|
|
217
|
+
export type LightenOperationDescriptor = {
|
|
218
|
+
name: OpName.LIGHTEN;
|
|
219
|
+
} & LightenOperationParams;
|
|
220
|
+
export type NormalizeOperationDescriptor = {
|
|
221
|
+
name: OpName.NORMALIZE;
|
|
222
|
+
} & NormalizeOperationParams;
|
|
223
|
+
export type OverlayOperationDescriptor = {
|
|
224
|
+
name: OpName.OVERLAY;
|
|
225
|
+
} & OverlayOperationParams;
|
|
226
|
+
export type ResizeOperationDescriptor = {
|
|
227
|
+
name: OpName.RESIZE;
|
|
228
|
+
} & ResizeOperationParams;
|
|
229
|
+
export type RotateOperationDescriptor = {
|
|
230
|
+
name: OpName.ROTATE;
|
|
231
|
+
} & RotateOperationParams;
|
|
232
|
+
export type SaturateOperationDescriptor = {
|
|
233
|
+
name: OpName.SATURATE;
|
|
234
|
+
} & SaturateOperationParams;
|
|
235
|
+
export type OperationDescriptor = BlurOperationDescriptor | BrightenOperationDescriptor | ExtendOperationDescriptor | ExtractOperationDescriptor | FlattenOperationDescriptor | FlipOperationDescriptor | FlopOperationDescriptor | HueOperationDescriptor | LevelOperationDescriptor | LightenOperationDescriptor | NormalizeOperationDescriptor | OverlayOperationDescriptor | ResizeOperationDescriptor | RotateOperationDescriptor | SaturateOperationDescriptor;
|
|
236
|
+
export type TransformLimits = {
|
|
237
|
+
timeoutMs?: number;
|
|
238
|
+
opTimeoutMs?: number;
|
|
239
|
+
width?: number;
|
|
240
|
+
height?: number;
|
|
241
|
+
};
|
|
242
|
+
export declare enum TransformErrCodes {
|
|
243
|
+
PROCESS_TIMEOUT = "process-timeout",
|
|
244
|
+
OP_TIMEOUT = "op-timeout",
|
|
245
|
+
WIDTH_LIMIT_EXCEEDED = "width-limit-exceeded",
|
|
246
|
+
HEIGHT_LIMIT_EXCEEDED = "height-limit-exceeded",
|
|
247
|
+
UNKNOWN_ERROR = "unknown-error"
|
|
248
|
+
}
|
|
249
|
+
export type TransformErr = {
|
|
250
|
+
code: TransformErrCodes;
|
|
251
|
+
details: string;
|
|
252
|
+
};
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import sharp from 'sharp';
|
|
2
|
+
import type { Color } from '../../../agnostic/colors/types.js';
|
|
3
|
+
import type { CreateOptions, ImageLike } from '../types.js';
|
|
4
|
+
export declare function toSharpColor(color: Color): sharp.RGBA;
|
|
5
|
+
export declare function isDuckTypedSharpInstance(obj: unknown): obj is sharp.Sharp;
|
|
6
|
+
export declare function toCreateOptions(options: CreateOptions): sharp.SharpOptions['create'];
|
|
7
|
+
export declare function toSharpInstance(imageLike: ImageLike, clone?: boolean): Promise<sharp.Sharp>;
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
import {
|
|
2
|
+
isDuckTypedSharpInstance,
|
|
3
|
+
toCreateOptions,
|
|
4
|
+
toSharpColor,
|
|
5
|
+
toSharpInstance
|
|
6
|
+
} from "../../../chunks/chunk-BKIF2ELV.js";
|
|
7
|
+
import "../../../chunks/chunk-ALMK24GK.js";
|
|
8
|
+
import "../../../chunks/chunk-65NTXENV.js";
|
|
9
|
+
import "../../../chunks/chunk-D7SXHHU3.js";
|
|
10
|
+
import "../../../chunks/chunk-GUBFCOBT.js";
|
|
11
|
+
import "../../../chunks/chunk-XAYMIITK.js";
|
|
12
|
+
import "../../../chunks/chunk-QW34TQCS.js";
|
|
13
|
+
import "../../../chunks/chunk-ZJ63OCMA.js";
|
|
14
|
+
import "../../../chunks/chunk-MN4FVOU2.js";
|
|
15
|
+
import "../../../chunks/chunk-VA67YLZL.js";
|
|
16
|
+
import "../../../chunks/chunk-P4YT4RBG.js";
|
|
17
|
+
import "../../../chunks/chunk-YZVZKBVJ.js";
|
|
18
|
+
import "../../../chunks/chunk-DNIOWD7K.js";
|
|
19
|
+
import "../../../chunks/chunk-OSAXBA7G.js";
|
|
20
|
+
import "../../../chunks/chunk-UG5EMKGN.js";
|
|
21
|
+
import "../../../chunks/chunk-HQLRJ7XW.js";
|
|
22
|
+
import "../../../chunks/chunk-WSFCRVEQ.js";
|
|
23
|
+
export {
|
|
24
|
+
isDuckTypedSharpInstance,
|
|
25
|
+
toCreateOptions,
|
|
26
|
+
toSharpColor,
|
|
27
|
+
toSharpInstance
|
|
28
|
+
};
|