@cloudflare/workers-types 4.20260615.1 → 4.20260617.1
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/2021-11-03/index.d.ts +211 -177
- package/2021-11-03/index.ts +211 -177
- package/2022-01-31/index.d.ts +211 -177
- package/2022-01-31/index.ts +211 -177
- package/2022-03-21/index.d.ts +211 -177
- package/2022-03-21/index.ts +211 -177
- package/2022-08-04/index.d.ts +211 -177
- package/2022-08-04/index.ts +211 -177
- package/2022-10-31/index.d.ts +211 -177
- package/2022-10-31/index.ts +211 -177
- package/2022-11-30/index.d.ts +211 -177
- package/2022-11-30/index.ts +211 -177
- package/2023-03-01/index.d.ts +211 -177
- package/2023-03-01/index.ts +211 -177
- package/2023-07-01/index.d.ts +211 -177
- package/2023-07-01/index.ts +211 -177
- package/experimental/index.d.ts +211 -177
- package/experimental/index.ts +211 -177
- package/index.d.ts +211 -177
- package/index.ts +211 -177
- package/latest/index.d.ts +211 -177
- package/latest/index.ts +211 -177
- package/oldest/index.d.ts +211 -177
- package/oldest/index.ts +211 -177
- package/package.json +1 -1
package/2022-10-31/index.ts
CHANGED
|
@@ -12183,87 +12183,6 @@ export declare abstract class BrowserRun {
|
|
|
12183
12183
|
options: BrowserRunMarkdownOptions,
|
|
12184
12184
|
): Promise<Response>;
|
|
12185
12185
|
}
|
|
12186
|
-
export interface BasicImageTransformations {
|
|
12187
|
-
/**
|
|
12188
|
-
* Maximum width in image pixels. The value must be an integer.
|
|
12189
|
-
*/
|
|
12190
|
-
width?: number;
|
|
12191
|
-
/**
|
|
12192
|
-
* Maximum height in image pixels. The value must be an integer.
|
|
12193
|
-
*/
|
|
12194
|
-
height?: number;
|
|
12195
|
-
/**
|
|
12196
|
-
* Resizing mode as a string. It affects interpretation of width and height
|
|
12197
|
-
* options:
|
|
12198
|
-
* - scale-down: Similar to contain, but the image is never enlarged. If
|
|
12199
|
-
* the image is larger than given width or height, it will be resized.
|
|
12200
|
-
* Otherwise its original size will be kept.
|
|
12201
|
-
* - contain: Resizes to maximum size that fits within the given width and
|
|
12202
|
-
* height. If only a single dimension is given (e.g. only width), the
|
|
12203
|
-
* image will be shrunk or enlarged to exactly match that dimension.
|
|
12204
|
-
* Aspect ratio is always preserved.
|
|
12205
|
-
* - cover: Resizes (shrinks or enlarges) to fill the entire area of width
|
|
12206
|
-
* and height. If the image has an aspect ratio different from the ratio
|
|
12207
|
-
* of width and height, it will be cropped to fit.
|
|
12208
|
-
* - crop: The image will be shrunk and cropped to fit within the area
|
|
12209
|
-
* specified by width and height. The image will not be enlarged. For images
|
|
12210
|
-
* smaller than the given dimensions it's the same as scale-down. For
|
|
12211
|
-
* images larger than the given dimensions, it's the same as cover.
|
|
12212
|
-
* See also trim.
|
|
12213
|
-
* - pad: Resizes to the maximum size that fits within the given width and
|
|
12214
|
-
* height, and then fills the remaining area with a background color
|
|
12215
|
-
* (white by default). Use of this mode is not recommended, as the same
|
|
12216
|
-
* effect can be more efficiently achieved with the contain mode and the
|
|
12217
|
-
* CSS object-fit: contain property.
|
|
12218
|
-
* - squeeze: Stretches and deforms to the width and height given, even if it
|
|
12219
|
-
* breaks aspect ratio
|
|
12220
|
-
*/
|
|
12221
|
-
fit?: "scale-down" | "contain" | "cover" | "crop" | "pad" | "squeeze";
|
|
12222
|
-
/**
|
|
12223
|
-
* Image segmentation using artificial intelligence models. Sets pixels not
|
|
12224
|
-
* within selected segment area to transparent e.g "foreground" sets every
|
|
12225
|
-
* background pixel as transparent.
|
|
12226
|
-
*/
|
|
12227
|
-
segment?: "foreground";
|
|
12228
|
-
/**
|
|
12229
|
-
* When cropping with fit: "cover", this defines the side or point that should
|
|
12230
|
-
* be left uncropped. The value is either a string
|
|
12231
|
-
* "left", "right", "top", "bottom", "auto", or "center" (the default),
|
|
12232
|
-
* or an object {x, y} containing focal point coordinates in the original
|
|
12233
|
-
* image expressed as fractions ranging from 0.0 (top or left) to 1.0
|
|
12234
|
-
* (bottom or right), 0.5 being the center. {fit: "cover", gravity: "top"} will
|
|
12235
|
-
* crop bottom or left and right sides as necessary, but won’t crop anything
|
|
12236
|
-
* from the top. {fit: "cover", gravity: {x:0.5, y:0.2}} will crop each side to
|
|
12237
|
-
* preserve as much as possible around a point at 20% of the height of the
|
|
12238
|
-
* source image.
|
|
12239
|
-
*/
|
|
12240
|
-
gravity?:
|
|
12241
|
-
| "face"
|
|
12242
|
-
| "left"
|
|
12243
|
-
| "right"
|
|
12244
|
-
| "top"
|
|
12245
|
-
| "bottom"
|
|
12246
|
-
| "center"
|
|
12247
|
-
| "auto"
|
|
12248
|
-
| "entropy"
|
|
12249
|
-
| BasicImageTransformationsGravityCoordinates;
|
|
12250
|
-
/**
|
|
12251
|
-
* Background color to add underneath the image. Applies only to images with
|
|
12252
|
-
* transparency (such as PNG). Accepts any CSS color (#RRGGBB, rgba(…),
|
|
12253
|
-
* hsl(…), etc.)
|
|
12254
|
-
*/
|
|
12255
|
-
background?: string;
|
|
12256
|
-
/**
|
|
12257
|
-
* Number of degrees (90, 180, 270) to rotate the image by. width and height
|
|
12258
|
-
* options refer to axes after rotation.
|
|
12259
|
-
*/
|
|
12260
|
-
rotate?: 0 | 90 | 180 | 270 | 360;
|
|
12261
|
-
}
|
|
12262
|
-
export interface BasicImageTransformationsGravityCoordinates {
|
|
12263
|
-
x?: number;
|
|
12264
|
-
y?: number;
|
|
12265
|
-
mode?: "remainder" | "box-center";
|
|
12266
|
-
}
|
|
12267
12186
|
/**
|
|
12268
12187
|
* In addition to the properties you can set in the RequestInit dict
|
|
12269
12188
|
* that you pass as an argument to the Request constructor, you can
|
|
@@ -12359,6 +12278,209 @@ export interface RequestInitCfProperties extends Record<string, unknown> {
|
|
|
12359
12278
|
*/
|
|
12360
12279
|
resolveOverride?: string;
|
|
12361
12280
|
}
|
|
12281
|
+
export interface BasicImageTransformations {
|
|
12282
|
+
/**
|
|
12283
|
+
* Maximum width in image pixels. The value must be an integer.
|
|
12284
|
+
*/
|
|
12285
|
+
width?: number;
|
|
12286
|
+
/**
|
|
12287
|
+
* Maximum height in image pixels. The value must be an integer.
|
|
12288
|
+
*/
|
|
12289
|
+
height?: number;
|
|
12290
|
+
/**
|
|
12291
|
+
* When cropping with fit: "cover", this defines the side or point that should
|
|
12292
|
+
* be left uncropped. The value is either a string
|
|
12293
|
+
* "left", "right", "top", "bottom", "auto", or "center" (the default),
|
|
12294
|
+
* or an object {x, y} containing focal point coordinates in the original
|
|
12295
|
+
* image expressed as fractions ranging from 0.0 (top or left) to 1.0
|
|
12296
|
+
* (bottom or right), 0.5 being the center. {fit: "cover", gravity: "top"} will
|
|
12297
|
+
* crop bottom or left and right sides as necessary, but won’t crop anything
|
|
12298
|
+
* from the top. {fit: "cover", gravity: {x:0.5, y:0.2}} will crop each side to
|
|
12299
|
+
* preserve as much as possible around a point at 20% of the height of the
|
|
12300
|
+
* source image.
|
|
12301
|
+
*/
|
|
12302
|
+
gravity?:
|
|
12303
|
+
| "face"
|
|
12304
|
+
| "left"
|
|
12305
|
+
| "right"
|
|
12306
|
+
| "top"
|
|
12307
|
+
| "bottom"
|
|
12308
|
+
| "center"
|
|
12309
|
+
| "auto"
|
|
12310
|
+
| "entropy"
|
|
12311
|
+
| BasicImageTransformationsGravityCoordinates;
|
|
12312
|
+
/**
|
|
12313
|
+
* Specifies how closely the image is cropped toward detected faces when combined
|
|
12314
|
+
* with the gravity=face option. Accepts a valid range between 0.0 (includes as much
|
|
12315
|
+
* of the background as possible) and 1.0 (crops the image as closely to the face as
|
|
12316
|
+
* possible). The default is 0.
|
|
12317
|
+
*/
|
|
12318
|
+
zoom?: number;
|
|
12319
|
+
/**
|
|
12320
|
+
* Resizing mode as a string. It affects interpretation of width and height
|
|
12321
|
+
* options:
|
|
12322
|
+
* - scale-down: Similar to contain, but the image is never enlarged. If
|
|
12323
|
+
* the image is larger than given width or height, it will be resized.
|
|
12324
|
+
* Otherwise its original size will be kept.
|
|
12325
|
+
* - scale-up: Similar to contain, but the image is never shrunk. If the
|
|
12326
|
+
* image is smaller than the given width or height, it will be resized.
|
|
12327
|
+
* Otherwise its original size will be kept.
|
|
12328
|
+
* - contain: Resizes to maximum size that fits within the given width and
|
|
12329
|
+
* height. If only a single dimension is given (e.g. only width), the
|
|
12330
|
+
* image will be shrunk or enlarged to exactly match that dimension.
|
|
12331
|
+
* Aspect ratio is always preserved.
|
|
12332
|
+
* - cover: Resizes (shrinks or enlarges) to fill the entire area of width
|
|
12333
|
+
* and height. If the image has an aspect ratio different from the ratio
|
|
12334
|
+
* of width and height, it will be cropped to fit.
|
|
12335
|
+
* - crop: The image will be shrunk and cropped to fit within the area
|
|
12336
|
+
* specified by width and height. The image will not be enlarged. For images
|
|
12337
|
+
* smaller than the given dimensions it's the same as scale-down. For
|
|
12338
|
+
* images larger than the given dimensions, it's the same as cover.
|
|
12339
|
+
* See also trim.
|
|
12340
|
+
* - pad: Resizes to the maximum size that fits within the given width and
|
|
12341
|
+
* height, and then fills the remaining area with a background color
|
|
12342
|
+
* (white by default). Use of this mode is not recommended, as the same
|
|
12343
|
+
* effect can be more efficiently achieved with the contain mode and the
|
|
12344
|
+
* CSS object-fit: contain property.
|
|
12345
|
+
* - squeeze: Stretches and deforms to the width and height given, even if it
|
|
12346
|
+
* breaks aspect ratio
|
|
12347
|
+
*/
|
|
12348
|
+
fit?:
|
|
12349
|
+
| "scale-down"
|
|
12350
|
+
| "scale-up"
|
|
12351
|
+
| "contain"
|
|
12352
|
+
| "cover"
|
|
12353
|
+
| "crop"
|
|
12354
|
+
| "pad"
|
|
12355
|
+
| "squeeze";
|
|
12356
|
+
/**
|
|
12357
|
+
* Allows you to trim your image. Takes dpr into account and is performed before
|
|
12358
|
+
* resizing or rotation.
|
|
12359
|
+
*
|
|
12360
|
+
* It can be used as:
|
|
12361
|
+
* - left, top, right, bottom - it will specify the number of pixels to cut
|
|
12362
|
+
* off each side
|
|
12363
|
+
* - width, height - the width/height you'd like to end up with - can be used
|
|
12364
|
+
* in combination with the properties above
|
|
12365
|
+
* - border - this will automatically trim the surroundings of an image based on
|
|
12366
|
+
* it's color. It consists of three properties:
|
|
12367
|
+
* - color: rgb or hex representation of the color you wish to trim (todo: verify the rgba bit)
|
|
12368
|
+
* - tolerance: difference from color to treat as color
|
|
12369
|
+
* - keep: the number of pixels of border to keep
|
|
12370
|
+
*/
|
|
12371
|
+
trim?:
|
|
12372
|
+
| "border"
|
|
12373
|
+
| {
|
|
12374
|
+
top?: number;
|
|
12375
|
+
bottom?: number;
|
|
12376
|
+
left?: number;
|
|
12377
|
+
right?: number;
|
|
12378
|
+
width?: number;
|
|
12379
|
+
height?: number;
|
|
12380
|
+
border?:
|
|
12381
|
+
| boolean
|
|
12382
|
+
| {
|
|
12383
|
+
color?: string;
|
|
12384
|
+
tolerance?: number;
|
|
12385
|
+
keep?: number;
|
|
12386
|
+
};
|
|
12387
|
+
};
|
|
12388
|
+
/**
|
|
12389
|
+
* Background color to add underneath the image. Applies only to images with
|
|
12390
|
+
* transparency (such as PNG). Accepts any CSS color (#RRGGBB, rgba(…),
|
|
12391
|
+
* hsl(…), etc.)
|
|
12392
|
+
*/
|
|
12393
|
+
background?: string;
|
|
12394
|
+
/**
|
|
12395
|
+
* Flips the images horizontally, vertically, or both. Flipping is applied before
|
|
12396
|
+
* rotation, so if you apply flip=h,rotate=90 then the image will be flipped
|
|
12397
|
+
* horizontally, then rotated by 90 degrees.
|
|
12398
|
+
*/
|
|
12399
|
+
flip?: "h" | "v" | "hv";
|
|
12400
|
+
/**
|
|
12401
|
+
* Number of degrees (90, 180, 270) to rotate the image by. width and height
|
|
12402
|
+
* options refer to axes after rotation.
|
|
12403
|
+
*/
|
|
12404
|
+
rotate?: 0 | 90 | 180 | 270 | 360;
|
|
12405
|
+
/**
|
|
12406
|
+
* Strength of sharpening filter to apply to the image. Floating-point
|
|
12407
|
+
* number between 0 (no sharpening, default) and 10 (maximum). 1.0 is a
|
|
12408
|
+
* recommended value for downscaled images.
|
|
12409
|
+
*/
|
|
12410
|
+
sharpen?: number;
|
|
12411
|
+
/**
|
|
12412
|
+
* Radius of a blur filter (approximate gaussian). Maximum supported radius
|
|
12413
|
+
* is 250.
|
|
12414
|
+
*/
|
|
12415
|
+
blur?: number;
|
|
12416
|
+
/**
|
|
12417
|
+
* Increase contrast by a factor. A value of 1.0 equals no change, a value of
|
|
12418
|
+
* 0.5 equals low contrast, and a value of 2.0 equals high contrast. 0 is
|
|
12419
|
+
* ignored.
|
|
12420
|
+
*/
|
|
12421
|
+
contrast?: number;
|
|
12422
|
+
/**
|
|
12423
|
+
* Increase brightness by a factor. A value of 1.0 equals no change, a value
|
|
12424
|
+
* of 0.5 equals half brightness, and a value of 2.0 equals twice as bright.
|
|
12425
|
+
* 0 is ignored.
|
|
12426
|
+
*/
|
|
12427
|
+
brightness?: number;
|
|
12428
|
+
/**
|
|
12429
|
+
* Increase exposure by a factor. A value of 1.0 equals no change, a value of
|
|
12430
|
+
* 0.5 darkens the image, and a value of 2.0 lightens the image. 0 is ignored.
|
|
12431
|
+
*/
|
|
12432
|
+
gamma?: number;
|
|
12433
|
+
/**
|
|
12434
|
+
* Increase contrast by a factor. A value of 1.0 equals no change, a value of
|
|
12435
|
+
* 0.5 equals low contrast, and a value of 2.0 equals high contrast. 0 is
|
|
12436
|
+
* ignored.
|
|
12437
|
+
*/
|
|
12438
|
+
saturation?: number;
|
|
12439
|
+
/**
|
|
12440
|
+
* Device Pixel Ratio. Default 1. Multiplier for width/height that makes it
|
|
12441
|
+
* easier to specify higher-DPI sizes in <img srcset>.
|
|
12442
|
+
*/
|
|
12443
|
+
dpr?: number;
|
|
12444
|
+
/**
|
|
12445
|
+
* Adds a border around the image. The border is added after resizing. Border
|
|
12446
|
+
* width takes dpr into account, and can be specified either using a single
|
|
12447
|
+
* width property, or individually for each side.
|
|
12448
|
+
*/
|
|
12449
|
+
border?:
|
|
12450
|
+
| {
|
|
12451
|
+
color: string;
|
|
12452
|
+
width: number;
|
|
12453
|
+
}
|
|
12454
|
+
| {
|
|
12455
|
+
color: string;
|
|
12456
|
+
top: number;
|
|
12457
|
+
right: number;
|
|
12458
|
+
bottom: number;
|
|
12459
|
+
left: number;
|
|
12460
|
+
};
|
|
12461
|
+
/**
|
|
12462
|
+
* Image segmentation using artificial intelligence models. Sets pixels not
|
|
12463
|
+
* within selected segment area to transparent e.g "foreground" sets every
|
|
12464
|
+
* background pixel as transparent.
|
|
12465
|
+
*/
|
|
12466
|
+
segment?: "foreground";
|
|
12467
|
+
/**
|
|
12468
|
+
* Controls the algorithm used when an image needs to be enlarged. This
|
|
12469
|
+
* parameter works with any fit mode that upscales, such as `contain`,
|
|
12470
|
+
* `cover`, and `scale-up`. It has no effect when `fit=scale-down` or when
|
|
12471
|
+
* the target dimensions are smaller than the source.
|
|
12472
|
+
* - interpolate: Uses bicubic interpolation, which may reduce image quality.
|
|
12473
|
+
* This is the default behavior when `upscale` is not specified.
|
|
12474
|
+
* - generate: Uses AI upscaling to produce sharper, more detailed results
|
|
12475
|
+
* when enlarging images.
|
|
12476
|
+
*/
|
|
12477
|
+
upscale?: "interpolate" | "generate";
|
|
12478
|
+
}
|
|
12479
|
+
export interface BasicImageTransformationsGravityCoordinates {
|
|
12480
|
+
x?: number;
|
|
12481
|
+
y?: number;
|
|
12482
|
+
mode?: "remainder" | "box-center";
|
|
12483
|
+
}
|
|
12362
12484
|
export interface RequestInitCfPropertiesImageDraw extends BasicImageTransformations {
|
|
12363
12485
|
/**
|
|
12364
12486
|
* Absolute URL of the image file to use for the drawing. It can be any of
|
|
@@ -12412,43 +12534,6 @@ export interface RequestInitCfPropertiesImageDraw extends BasicImageTransformati
|
|
|
12412
12534
|
right?: number;
|
|
12413
12535
|
}
|
|
12414
12536
|
export interface RequestInitCfPropertiesImage extends BasicImageTransformations {
|
|
12415
|
-
/**
|
|
12416
|
-
* Device Pixel Ratio. Default 1. Multiplier for width/height that makes it
|
|
12417
|
-
* easier to specify higher-DPI sizes in <img srcset>.
|
|
12418
|
-
*/
|
|
12419
|
-
dpr?: number;
|
|
12420
|
-
/**
|
|
12421
|
-
* Allows you to trim your image. Takes dpr into account and is performed before
|
|
12422
|
-
* resizing or rotation.
|
|
12423
|
-
*
|
|
12424
|
-
* It can be used as:
|
|
12425
|
-
* - left, top, right, bottom - it will specify the number of pixels to cut
|
|
12426
|
-
* off each side
|
|
12427
|
-
* - width, height - the width/height you'd like to end up with - can be used
|
|
12428
|
-
* in combination with the properties above
|
|
12429
|
-
* - border - this will automatically trim the surroundings of an image based on
|
|
12430
|
-
* it's color. It consists of three properties:
|
|
12431
|
-
* - color: rgb or hex representation of the color you wish to trim (todo: verify the rgba bit)
|
|
12432
|
-
* - tolerance: difference from color to treat as color
|
|
12433
|
-
* - keep: the number of pixels of border to keep
|
|
12434
|
-
*/
|
|
12435
|
-
trim?:
|
|
12436
|
-
| "border"
|
|
12437
|
-
| {
|
|
12438
|
-
top?: number;
|
|
12439
|
-
bottom?: number;
|
|
12440
|
-
left?: number;
|
|
12441
|
-
right?: number;
|
|
12442
|
-
width?: number;
|
|
12443
|
-
height?: number;
|
|
12444
|
-
border?:
|
|
12445
|
-
| boolean
|
|
12446
|
-
| {
|
|
12447
|
-
color?: string;
|
|
12448
|
-
tolerance?: number;
|
|
12449
|
-
keep?: number;
|
|
12450
|
-
};
|
|
12451
|
-
};
|
|
12452
12537
|
/**
|
|
12453
12538
|
* Quality setting from 1-100 (useful values are in 60-90 range). Lower values
|
|
12454
12539
|
* make images look worse, but load faster. The default is 85. It applies only
|
|
@@ -12498,17 +12583,6 @@ export interface RequestInitCfPropertiesImage extends BasicImageTransformations
|
|
|
12498
12583
|
* output formats always discard metadata.
|
|
12499
12584
|
*/
|
|
12500
12585
|
metadata?: "keep" | "copyright" | "none";
|
|
12501
|
-
/**
|
|
12502
|
-
* Strength of sharpening filter to apply to the image. Floating-point
|
|
12503
|
-
* number between 0 (no sharpening, default) and 10 (maximum). 1.0 is a
|
|
12504
|
-
* recommended value for downscaled images.
|
|
12505
|
-
*/
|
|
12506
|
-
sharpen?: number;
|
|
12507
|
-
/**
|
|
12508
|
-
* Radius of a blur filter (approximate gaussian). Maximum supported radius
|
|
12509
|
-
* is 250.
|
|
12510
|
-
*/
|
|
12511
|
-
blur?: number;
|
|
12512
12586
|
/**
|
|
12513
12587
|
* Overlays are drawn in the order they appear in the array (last array
|
|
12514
12588
|
* entry is the topmost layer).
|
|
@@ -12520,52 +12594,6 @@ export interface RequestInitCfPropertiesImage extends BasicImageTransformations
|
|
|
12520
12594
|
* the origin.
|
|
12521
12595
|
*/
|
|
12522
12596
|
"origin-auth"?: "share-publicly";
|
|
12523
|
-
/**
|
|
12524
|
-
* Adds a border around the image. The border is added after resizing. Border
|
|
12525
|
-
* width takes dpr into account, and can be specified either using a single
|
|
12526
|
-
* width property, or individually for each side.
|
|
12527
|
-
*/
|
|
12528
|
-
border?:
|
|
12529
|
-
| {
|
|
12530
|
-
color: string;
|
|
12531
|
-
width: number;
|
|
12532
|
-
}
|
|
12533
|
-
| {
|
|
12534
|
-
color: string;
|
|
12535
|
-
top: number;
|
|
12536
|
-
right: number;
|
|
12537
|
-
bottom: number;
|
|
12538
|
-
left: number;
|
|
12539
|
-
};
|
|
12540
|
-
/**
|
|
12541
|
-
* Increase brightness by a factor. A value of 1.0 equals no change, a value
|
|
12542
|
-
* of 0.5 equals half brightness, and a value of 2.0 equals twice as bright.
|
|
12543
|
-
* 0 is ignored.
|
|
12544
|
-
*/
|
|
12545
|
-
brightness?: number;
|
|
12546
|
-
/**
|
|
12547
|
-
* Increase contrast by a factor. A value of 1.0 equals no change, a value of
|
|
12548
|
-
* 0.5 equals low contrast, and a value of 2.0 equals high contrast. 0 is
|
|
12549
|
-
* ignored.
|
|
12550
|
-
*/
|
|
12551
|
-
contrast?: number;
|
|
12552
|
-
/**
|
|
12553
|
-
* Increase exposure by a factor. A value of 1.0 equals no change, a value of
|
|
12554
|
-
* 0.5 darkens the image, and a value of 2.0 lightens the image. 0 is ignored.
|
|
12555
|
-
*/
|
|
12556
|
-
gamma?: number;
|
|
12557
|
-
/**
|
|
12558
|
-
* Increase contrast by a factor. A value of 1.0 equals no change, a value of
|
|
12559
|
-
* 0.5 equals low contrast, and a value of 2.0 equals high contrast. 0 is
|
|
12560
|
-
* ignored.
|
|
12561
|
-
*/
|
|
12562
|
-
saturation?: number;
|
|
12563
|
-
/**
|
|
12564
|
-
* Flips the images horizontally, vertically, or both. Flipping is applied before
|
|
12565
|
-
* rotation, so if you apply flip=h,rotate=90 then the image will be flipped
|
|
12566
|
-
* horizontally, then rotated by 90 degrees.
|
|
12567
|
-
*/
|
|
12568
|
-
flip?: "h" | "v" | "hv";
|
|
12569
12597
|
/**
|
|
12570
12598
|
* Slightly reduces latency on a cache miss by selecting a
|
|
12571
12599
|
* quickest-to-compress file format, at a cost of increased file size and
|
|
@@ -14464,6 +14492,10 @@ export declare namespace CloudflareWorkersModule {
|
|
|
14464
14492
|
timeout?: WorkflowTimeoutDuration | number;
|
|
14465
14493
|
sensitive?: WorkflowStepSensitivity;
|
|
14466
14494
|
};
|
|
14495
|
+
export type WorkflowStepRollbackConfig = Pick<
|
|
14496
|
+
WorkflowStepConfig,
|
|
14497
|
+
"retries" | "timeout"
|
|
14498
|
+
>;
|
|
14467
14499
|
export type WorkflowCronSchedule = {
|
|
14468
14500
|
/** Cron expression that triggered this event. */
|
|
14469
14501
|
cron: string;
|
|
@@ -14492,16 +14524,18 @@ export declare namespace CloudflareWorkersModule {
|
|
|
14492
14524
|
config: WorkflowStepConfig;
|
|
14493
14525
|
};
|
|
14494
14526
|
export type WorkflowRollbackContext<T = unknown> = {
|
|
14527
|
+
ctx: WorkflowStepContext;
|
|
14495
14528
|
error: Error;
|
|
14496
14529
|
output: T | undefined;
|
|
14530
|
+
/** @deprecated Use `ctx.step.name` and `ctx.step.count` instead. */
|
|
14497
14531
|
stepName: string;
|
|
14498
14532
|
};
|
|
14499
14533
|
export type WorkflowRollbackHandler<T = unknown> = (
|
|
14500
14534
|
ctx: WorkflowRollbackContext<T>,
|
|
14501
14535
|
) => Promise<void>;
|
|
14502
14536
|
export type WorkflowStepRollbackOptions<T = unknown> = {
|
|
14503
|
-
rollback
|
|
14504
|
-
rollbackConfig?:
|
|
14537
|
+
rollback: WorkflowRollbackHandler<T>;
|
|
14538
|
+
rollbackConfig?: WorkflowStepRollbackConfig;
|
|
14505
14539
|
};
|
|
14506
14540
|
export abstract class WorkflowStep {
|
|
14507
14541
|
do<T extends Rpc.Serializable<T>>(
|