workerd 1.20260615.1 → 1.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/bin/workerd +1 -1
- package/install.js +4 -4
- package/lib/main.js +3 -3
- package/package.json +6 -6
- package/worker.mjs +215 -180
package/bin/workerd
CHANGED
|
@@ -122,7 +122,7 @@ by workerd to install the correct binary executable for your current platform.`)
|
|
|
122
122
|
"node_modules",
|
|
123
123
|
".cache",
|
|
124
124
|
"workerd",
|
|
125
|
-
`pnpapi-${pkg.replace("/", "-")}-${"1.
|
|
125
|
+
`pnpapi-${pkg.replace("/", "-")}-${"1.20260617.1"}-${import_path.default.basename(subpath)}`
|
|
126
126
|
);
|
|
127
127
|
if (!import_fs.default.existsSync(binTargetPath)) {
|
|
128
128
|
import_fs.default.mkdirSync(import_path.default.dirname(binTargetPath), { recursive: true });
|
package/install.js
CHANGED
|
@@ -94,10 +94,10 @@ operating system, or missing some shared libraries.`;
|
|
|
94
94
|
console.error(msg);
|
|
95
95
|
return;
|
|
96
96
|
}
|
|
97
|
-
if (stdout !== `workerd ${"2026-06-
|
|
97
|
+
if (stdout !== `workerd ${"2026-06-17"}`) {
|
|
98
98
|
throw new Error(
|
|
99
99
|
`Expected ${JSON.stringify(
|
|
100
|
-
"2026-06-
|
|
100
|
+
"2026-06-17"
|
|
101
101
|
)} but got ${JSON.stringify(stdout)}`
|
|
102
102
|
);
|
|
103
103
|
}
|
|
@@ -152,7 +152,7 @@ function installUsingNPM(pkg, subpath, binPath) {
|
|
|
152
152
|
try {
|
|
153
153
|
import_fs.default.writeFileSync(import_path2.default.join(installDir, "package.json"), "{}");
|
|
154
154
|
import_child_process.default.execSync(
|
|
155
|
-
`npm install --loglevel=error --prefer-offline --no-audit --progress=false ${pkg}@${"1.
|
|
155
|
+
`npm install --loglevel=error --prefer-offline --no-audit --progress=false ${pkg}@${"1.20260617.1"}`,
|
|
156
156
|
{ cwd: installDir, stdio: "pipe", env }
|
|
157
157
|
);
|
|
158
158
|
const installedBinPath = import_path2.default.join(
|
|
@@ -197,7 +197,7 @@ function maybeOptimizePackage(binPath) {
|
|
|
197
197
|
}
|
|
198
198
|
async function downloadDirectlyFromNPM(pkg, subpath, binPath) {
|
|
199
199
|
const unscopedPkg = pkg.substring(pkg.indexOf("/") + 1);
|
|
200
|
-
const url = `https://registry.npmjs.org/${pkg}/-/${unscopedPkg}-${"1.
|
|
200
|
+
const url = `https://registry.npmjs.org/${pkg}/-/${unscopedPkg}-${"1.20260617.1"}.tgz`;
|
|
201
201
|
console.error(`[workerd] Trying to download ${JSON.stringify(url)}`);
|
|
202
202
|
try {
|
|
203
203
|
import_fs.default.writeFileSync(
|
package/lib/main.js
CHANGED
|
@@ -136,7 +136,7 @@ by workerd to install the correct binary executable for your current platform.`)
|
|
|
136
136
|
"node_modules",
|
|
137
137
|
".cache",
|
|
138
138
|
"workerd",
|
|
139
|
-
`pnpapi-${pkg.replace("/", "-")}-${"1.
|
|
139
|
+
`pnpapi-${pkg.replace("/", "-")}-${"1.20260617.1"}-${import_path.default.basename(subpath)}`
|
|
140
140
|
);
|
|
141
141
|
if (!import_fs.default.existsSync(binTargetPath)) {
|
|
142
142
|
import_fs.default.mkdirSync(import_path.default.dirname(binTargetPath), { recursive: true });
|
|
@@ -151,8 +151,8 @@ by workerd to install the correct binary executable for your current platform.`)
|
|
|
151
151
|
// npm/lib/node-path.ts
|
|
152
152
|
var { binPath } = generateBinPath();
|
|
153
153
|
var node_path_default = binPath;
|
|
154
|
-
var compatibilityDate = "2026-06-
|
|
155
|
-
var version = "1.
|
|
154
|
+
var compatibilityDate = "2026-06-17";
|
|
155
|
+
var version = "1.20260617.1";
|
|
156
156
|
// Annotate the CommonJS export names for ESM import in node:
|
|
157
157
|
0 && (module.exports = {
|
|
158
158
|
compatibilityDate,
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "workerd",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.20260617.1",
|
|
4
4
|
"description": "👷 workerd, Cloudflare's JavaScript/Wasm Runtime",
|
|
5
5
|
"repository": "https://github.com/cloudflare/workerd",
|
|
6
6
|
"scripts": {
|
|
@@ -14,11 +14,11 @@
|
|
|
14
14
|
"workerd": "bin/workerd"
|
|
15
15
|
},
|
|
16
16
|
"optionalDependencies": {
|
|
17
|
-
"@cloudflare/workerd-darwin-arm64": "1.
|
|
18
|
-
"@cloudflare/workerd-darwin-64": "1.
|
|
19
|
-
"@cloudflare/workerd-linux-arm64": "1.
|
|
20
|
-
"@cloudflare/workerd-linux-64": "1.
|
|
21
|
-
"@cloudflare/workerd-windows-64": "1.
|
|
17
|
+
"@cloudflare/workerd-darwin-arm64": "1.20260617.1",
|
|
18
|
+
"@cloudflare/workerd-darwin-64": "1.20260617.1",
|
|
19
|
+
"@cloudflare/workerd-linux-arm64": "1.20260617.1",
|
|
20
|
+
"@cloudflare/workerd-linux-64": "1.20260617.1",
|
|
21
|
+
"@cloudflare/workerd-windows-64": "1.20260617.1"
|
|
22
22
|
},
|
|
23
23
|
"license": "Apache-2.0"
|
|
24
24
|
}
|
package/worker.mjs
CHANGED
|
@@ -8695,89 +8695,6 @@ declare abstract class BrowserRun {
|
|
|
8695
8695
|
): Promise<Response>;
|
|
8696
8696
|
}
|
|
8697
8697
|
|
|
8698
|
-
interface BasicImageTransformations {
|
|
8699
|
-
/**
|
|
8700
|
-
* Maximum width in image pixels. The value must be an integer.
|
|
8701
|
-
*/
|
|
8702
|
-
width?: number;
|
|
8703
|
-
/**
|
|
8704
|
-
* Maximum height in image pixels. The value must be an integer.
|
|
8705
|
-
*/
|
|
8706
|
-
height?: number;
|
|
8707
|
-
/**
|
|
8708
|
-
* Resizing mode as a string. It affects interpretation of width and height
|
|
8709
|
-
* options:
|
|
8710
|
-
* - scale-down: Similar to contain, but the image is never enlarged. If
|
|
8711
|
-
* the image is larger than given width or height, it will be resized.
|
|
8712
|
-
* Otherwise its original size will be kept.
|
|
8713
|
-
* - contain: Resizes to maximum size that fits within the given width and
|
|
8714
|
-
* height. If only a single dimension is given (e.g. only width), the
|
|
8715
|
-
* image will be shrunk or enlarged to exactly match that dimension.
|
|
8716
|
-
* Aspect ratio is always preserved.
|
|
8717
|
-
* - cover: Resizes (shrinks or enlarges) to fill the entire area of width
|
|
8718
|
-
* and height. If the image has an aspect ratio different from the ratio
|
|
8719
|
-
* of width and height, it will be cropped to fit.
|
|
8720
|
-
* - crop: The image will be shrunk and cropped to fit within the area
|
|
8721
|
-
* specified by width and height. The image will not be enlarged. For images
|
|
8722
|
-
* smaller than the given dimensions it's the same as scale-down. For
|
|
8723
|
-
* images larger than the given dimensions, it's the same as cover.
|
|
8724
|
-
* See also trim.
|
|
8725
|
-
* - pad: Resizes to the maximum size that fits within the given width and
|
|
8726
|
-
* height, and then fills the remaining area with a background color
|
|
8727
|
-
* (white by default). Use of this mode is not recommended, as the same
|
|
8728
|
-
* effect can be more efficiently achieved with the contain mode and the
|
|
8729
|
-
* CSS object-fit: contain property.
|
|
8730
|
-
* - squeeze: Stretches and deforms to the width and height given, even if it
|
|
8731
|
-
* breaks aspect ratio
|
|
8732
|
-
*/
|
|
8733
|
-
fit?: "scale-down" | "contain" | "cover" | "crop" | "pad" | "squeeze";
|
|
8734
|
-
/**
|
|
8735
|
-
* Image segmentation using artificial intelligence models. Sets pixels not
|
|
8736
|
-
* within selected segment area to transparent e.g "foreground" sets every
|
|
8737
|
-
* background pixel as transparent.
|
|
8738
|
-
*/
|
|
8739
|
-
segment?: "foreground";
|
|
8740
|
-
/**
|
|
8741
|
-
* When cropping with fit: "cover", this defines the side or point that should
|
|
8742
|
-
* be left uncropped. The value is either a string
|
|
8743
|
-
* "left", "right", "top", "bottom", "auto", or "center" (the default),
|
|
8744
|
-
* or an object {x, y} containing focal point coordinates in the original
|
|
8745
|
-
* image expressed as fractions ranging from 0.0 (top or left) to 1.0
|
|
8746
|
-
* (bottom or right), 0.5 being the center. {fit: "cover", gravity: "top"} will
|
|
8747
|
-
* crop bottom or left and right sides as necessary, but won\u2019t crop anything
|
|
8748
|
-
* from the top. {fit: "cover", gravity: {x:0.5, y:0.2}} will crop each side to
|
|
8749
|
-
* preserve as much as possible around a point at 20% of the height of the
|
|
8750
|
-
* source image.
|
|
8751
|
-
*/
|
|
8752
|
-
gravity?:
|
|
8753
|
-
| 'face'
|
|
8754
|
-
| 'left'
|
|
8755
|
-
| 'right'
|
|
8756
|
-
| 'top'
|
|
8757
|
-
| 'bottom'
|
|
8758
|
-
| 'center'
|
|
8759
|
-
| 'auto'
|
|
8760
|
-
| 'entropy'
|
|
8761
|
-
| BasicImageTransformationsGravityCoordinates;
|
|
8762
|
-
/**
|
|
8763
|
-
* Background color to add underneath the image. Applies only to images with
|
|
8764
|
-
* transparency (such as PNG). Accepts any CSS color (#RRGGBB, rgba(\u2026),
|
|
8765
|
-
* hsl(\u2026), etc.)
|
|
8766
|
-
*/
|
|
8767
|
-
background?: string;
|
|
8768
|
-
/**
|
|
8769
|
-
* Number of degrees (90, 180, 270) to rotate the image by. width and height
|
|
8770
|
-
* options refer to axes after rotation.
|
|
8771
|
-
*/
|
|
8772
|
-
rotate?: 0 | 90 | 180 | 270 | 360;
|
|
8773
|
-
}
|
|
8774
|
-
|
|
8775
|
-
interface BasicImageTransformationsGravityCoordinates {
|
|
8776
|
-
x?: number;
|
|
8777
|
-
y?: number;
|
|
8778
|
-
mode?: 'remainder' | 'box-center';
|
|
8779
|
-
}
|
|
8780
|
-
|
|
8781
8698
|
/**
|
|
8782
8699
|
* In addition to the properties you can set in the RequestInit dict
|
|
8783
8700
|
* that you pass as an argument to the Request constructor, you can
|
|
@@ -8874,6 +8791,209 @@ interface RequestInitCfProperties extends Record<string, unknown> {
|
|
|
8874
8791
|
resolveOverride?: string;
|
|
8875
8792
|
}
|
|
8876
8793
|
|
|
8794
|
+
interface BasicImageTransformations {
|
|
8795
|
+
/**
|
|
8796
|
+
* Maximum width in image pixels. The value must be an integer.
|
|
8797
|
+
*/
|
|
8798
|
+
width?: number;
|
|
8799
|
+
/**
|
|
8800
|
+
* Maximum height in image pixels. The value must be an integer.
|
|
8801
|
+
*/
|
|
8802
|
+
height?: number;
|
|
8803
|
+
/**
|
|
8804
|
+
* When cropping with fit: "cover", this defines the side or point that should
|
|
8805
|
+
* be left uncropped. The value is either a string
|
|
8806
|
+
* "left", "right", "top", "bottom", "auto", or "center" (the default),
|
|
8807
|
+
* or an object {x, y} containing focal point coordinates in the original
|
|
8808
|
+
* image expressed as fractions ranging from 0.0 (top or left) to 1.0
|
|
8809
|
+
* (bottom or right), 0.5 being the center. {fit: "cover", gravity: "top"} will
|
|
8810
|
+
* crop bottom or left and right sides as necessary, but won\u2019t crop anything
|
|
8811
|
+
* from the top. {fit: "cover", gravity: {x:0.5, y:0.2}} will crop each side to
|
|
8812
|
+
* preserve as much as possible around a point at 20% of the height of the
|
|
8813
|
+
* source image.
|
|
8814
|
+
*/
|
|
8815
|
+
gravity?:
|
|
8816
|
+
| 'face'
|
|
8817
|
+
| 'left'
|
|
8818
|
+
| 'right'
|
|
8819
|
+
| 'top'
|
|
8820
|
+
| 'bottom'
|
|
8821
|
+
| 'center'
|
|
8822
|
+
| 'auto'
|
|
8823
|
+
| 'entropy'
|
|
8824
|
+
| BasicImageTransformationsGravityCoordinates;
|
|
8825
|
+
/**
|
|
8826
|
+
* Specifies how closely the image is cropped toward detected faces when combined
|
|
8827
|
+
* with the gravity=face option. Accepts a valid range between 0.0 (includes as much
|
|
8828
|
+
* of the background as possible) and 1.0 (crops the image as closely to the face as
|
|
8829
|
+
* possible). The default is 0.
|
|
8830
|
+
*/
|
|
8831
|
+
zoom?: number;
|
|
8832
|
+
/**
|
|
8833
|
+
* Resizing mode as a string. It affects interpretation of width and height
|
|
8834
|
+
* options:
|
|
8835
|
+
* - scale-down: Similar to contain, but the image is never enlarged. If
|
|
8836
|
+
* the image is larger than given width or height, it will be resized.
|
|
8837
|
+
* Otherwise its original size will be kept.
|
|
8838
|
+
* - scale-up: Similar to contain, but the image is never shrunk. If the
|
|
8839
|
+
* image is smaller than the given width or height, it will be resized.
|
|
8840
|
+
* Otherwise its original size will be kept.
|
|
8841
|
+
* - contain: Resizes to maximum size that fits within the given width and
|
|
8842
|
+
* height. If only a single dimension is given (e.g. only width), the
|
|
8843
|
+
* image will be shrunk or enlarged to exactly match that dimension.
|
|
8844
|
+
* Aspect ratio is always preserved.
|
|
8845
|
+
* - cover: Resizes (shrinks or enlarges) to fill the entire area of width
|
|
8846
|
+
* and height. If the image has an aspect ratio different from the ratio
|
|
8847
|
+
* of width and height, it will be cropped to fit.
|
|
8848
|
+
* - crop: The image will be shrunk and cropped to fit within the area
|
|
8849
|
+
* specified by width and height. The image will not be enlarged. For images
|
|
8850
|
+
* smaller than the given dimensions it's the same as scale-down. For
|
|
8851
|
+
* images larger than the given dimensions, it's the same as cover.
|
|
8852
|
+
* See also trim.
|
|
8853
|
+
* - pad: Resizes to the maximum size that fits within the given width and
|
|
8854
|
+
* height, and then fills the remaining area with a background color
|
|
8855
|
+
* (white by default). Use of this mode is not recommended, as the same
|
|
8856
|
+
* effect can be more efficiently achieved with the contain mode and the
|
|
8857
|
+
* CSS object-fit: contain property.
|
|
8858
|
+
* - squeeze: Stretches and deforms to the width and height given, even if it
|
|
8859
|
+
* breaks aspect ratio
|
|
8860
|
+
*/
|
|
8861
|
+
fit?:
|
|
8862
|
+
| "scale-down"
|
|
8863
|
+
| "scale-up"
|
|
8864
|
+
| "contain"
|
|
8865
|
+
| "cover"
|
|
8866
|
+
| "crop"
|
|
8867
|
+
| "pad"
|
|
8868
|
+
| "squeeze";
|
|
8869
|
+
/**
|
|
8870
|
+
* Allows you to trim your image. Takes dpr into account and is performed before
|
|
8871
|
+
* resizing or rotation.
|
|
8872
|
+
*
|
|
8873
|
+
* It can be used as:
|
|
8874
|
+
* - left, top, right, bottom - it will specify the number of pixels to cut
|
|
8875
|
+
* off each side
|
|
8876
|
+
* - width, height - the width/height you'd like to end up with - can be used
|
|
8877
|
+
* in combination with the properties above
|
|
8878
|
+
* - border - this will automatically trim the surroundings of an image based on
|
|
8879
|
+
* it's color. It consists of three properties:
|
|
8880
|
+
* - color: rgb or hex representation of the color you wish to trim (todo: verify the rgba bit)
|
|
8881
|
+
* - tolerance: difference from color to treat as color
|
|
8882
|
+
* - keep: the number of pixels of border to keep
|
|
8883
|
+
*/
|
|
8884
|
+
trim?: "border" | {
|
|
8885
|
+
top?: number;
|
|
8886
|
+
bottom?: number;
|
|
8887
|
+
left?: number;
|
|
8888
|
+
right?: number;
|
|
8889
|
+
width?: number;
|
|
8890
|
+
height?: number;
|
|
8891
|
+
border?:
|
|
8892
|
+
| boolean
|
|
8893
|
+
| {
|
|
8894
|
+
color?: string;
|
|
8895
|
+
tolerance?: number;
|
|
8896
|
+
keep?: number;
|
|
8897
|
+
};
|
|
8898
|
+
};
|
|
8899
|
+
/**
|
|
8900
|
+
* Background color to add underneath the image. Applies only to images with
|
|
8901
|
+
* transparency (such as PNG). Accepts any CSS color (#RRGGBB, rgba(\u2026),
|
|
8902
|
+
* hsl(\u2026), etc.)
|
|
8903
|
+
*/
|
|
8904
|
+
background?: string;
|
|
8905
|
+
/**
|
|
8906
|
+
* Flips the images horizontally, vertically, or both. Flipping is applied before
|
|
8907
|
+
* rotation, so if you apply flip=h,rotate=90 then the image will be flipped
|
|
8908
|
+
* horizontally, then rotated by 90 degrees.
|
|
8909
|
+
*/
|
|
8910
|
+
flip?: 'h' | 'v' | 'hv';
|
|
8911
|
+
/**
|
|
8912
|
+
* Number of degrees (90, 180, 270) to rotate the image by. width and height
|
|
8913
|
+
* options refer to axes after rotation.
|
|
8914
|
+
*/
|
|
8915
|
+
rotate?: 0 | 90 | 180 | 270 | 360;
|
|
8916
|
+
/**
|
|
8917
|
+
* Strength of sharpening filter to apply to the image. Floating-point
|
|
8918
|
+
* number between 0 (no sharpening, default) and 10 (maximum). 1.0 is a
|
|
8919
|
+
* recommended value for downscaled images.
|
|
8920
|
+
*/
|
|
8921
|
+
sharpen?: number;
|
|
8922
|
+
/**
|
|
8923
|
+
* Radius of a blur filter (approximate gaussian). Maximum supported radius
|
|
8924
|
+
* is 250.
|
|
8925
|
+
*/
|
|
8926
|
+
blur?: number;
|
|
8927
|
+
/**
|
|
8928
|
+
* Increase contrast by a factor. A value of 1.0 equals no change, a value of
|
|
8929
|
+
* 0.5 equals low contrast, and a value of 2.0 equals high contrast. 0 is
|
|
8930
|
+
* ignored.
|
|
8931
|
+
*/
|
|
8932
|
+
contrast?: number;
|
|
8933
|
+
/**
|
|
8934
|
+
* Increase brightness by a factor. A value of 1.0 equals no change, a value
|
|
8935
|
+
* of 0.5 equals half brightness, and a value of 2.0 equals twice as bright.
|
|
8936
|
+
* 0 is ignored.
|
|
8937
|
+
*/
|
|
8938
|
+
brightness?: number;
|
|
8939
|
+
/**
|
|
8940
|
+
* Increase exposure by a factor. A value of 1.0 equals no change, a value of
|
|
8941
|
+
* 0.5 darkens the image, and a value of 2.0 lightens the image. 0 is ignored.
|
|
8942
|
+
*/
|
|
8943
|
+
gamma?: number;
|
|
8944
|
+
/**
|
|
8945
|
+
* Increase contrast by a factor. A value of 1.0 equals no change, a value of
|
|
8946
|
+
* 0.5 equals low contrast, and a value of 2.0 equals high contrast. 0 is
|
|
8947
|
+
* ignored.
|
|
8948
|
+
*/
|
|
8949
|
+
saturation?: number;
|
|
8950
|
+
/**
|
|
8951
|
+
* Device Pixel Ratio. Default 1. Multiplier for width/height that makes it
|
|
8952
|
+
* easier to specify higher-DPI sizes in <img srcset>.
|
|
8953
|
+
*/
|
|
8954
|
+
dpr?: number;
|
|
8955
|
+
/**
|
|
8956
|
+
* Adds a border around the image. The border is added after resizing. Border
|
|
8957
|
+
* width takes dpr into account, and can be specified either using a single
|
|
8958
|
+
* width property, or individually for each side.
|
|
8959
|
+
*/
|
|
8960
|
+
border?:
|
|
8961
|
+
| {
|
|
8962
|
+
color: string;
|
|
8963
|
+
width: number;
|
|
8964
|
+
}
|
|
8965
|
+
| {
|
|
8966
|
+
color: string;
|
|
8967
|
+
top: number;
|
|
8968
|
+
right: number;
|
|
8969
|
+
bottom: number;
|
|
8970
|
+
left: number;
|
|
8971
|
+
};
|
|
8972
|
+
/**
|
|
8973
|
+
* Image segmentation using artificial intelligence models. Sets pixels not
|
|
8974
|
+
* within selected segment area to transparent e.g "foreground" sets every
|
|
8975
|
+
* background pixel as transparent.
|
|
8976
|
+
*/
|
|
8977
|
+
segment?: "foreground";
|
|
8978
|
+
/**
|
|
8979
|
+
* Controls the algorithm used when an image needs to be enlarged. This
|
|
8980
|
+
* parameter works with any fit mode that upscales, such as \`contain\`,
|
|
8981
|
+
* \`cover\`, and \`scale-up\`. It has no effect when \`fit=scale-down\` or when
|
|
8982
|
+
* the target dimensions are smaller than the source.
|
|
8983
|
+
* - interpolate: Uses bicubic interpolation, which may reduce image quality.
|
|
8984
|
+
* This is the default behavior when \`upscale\` is not specified.
|
|
8985
|
+
* - generate: Uses AI upscaling to produce sharper, more detailed results
|
|
8986
|
+
* when enlarging images.
|
|
8987
|
+
*/
|
|
8988
|
+
upscale?: "interpolate" | "generate";
|
|
8989
|
+
}
|
|
8990
|
+
|
|
8991
|
+
interface BasicImageTransformationsGravityCoordinates {
|
|
8992
|
+
x?: number;
|
|
8993
|
+
y?: number;
|
|
8994
|
+
mode?: 'remainder' | 'box-center';
|
|
8995
|
+
}
|
|
8996
|
+
|
|
8877
8997
|
interface RequestInitCfPropertiesImageDraw extends BasicImageTransformations {
|
|
8878
8998
|
/**
|
|
8879
8999
|
* Absolute URL of the image file to use for the drawing. It can be any of
|
|
@@ -8930,41 +9050,6 @@ interface RequestInitCfPropertiesImageDraw extends BasicImageTransformations {
|
|
|
8930
9050
|
}
|
|
8931
9051
|
|
|
8932
9052
|
interface RequestInitCfPropertiesImage extends BasicImageTransformations {
|
|
8933
|
-
/**
|
|
8934
|
-
* Device Pixel Ratio. Default 1. Multiplier for width/height that makes it
|
|
8935
|
-
* easier to specify higher-DPI sizes in <img srcset>.
|
|
8936
|
-
*/
|
|
8937
|
-
dpr?: number;
|
|
8938
|
-
/**
|
|
8939
|
-
* Allows you to trim your image. Takes dpr into account and is performed before
|
|
8940
|
-
* resizing or rotation.
|
|
8941
|
-
*
|
|
8942
|
-
* It can be used as:
|
|
8943
|
-
* - left, top, right, bottom - it will specify the number of pixels to cut
|
|
8944
|
-
* off each side
|
|
8945
|
-
* - width, height - the width/height you'd like to end up with - can be used
|
|
8946
|
-
* in combination with the properties above
|
|
8947
|
-
* - border - this will automatically trim the surroundings of an image based on
|
|
8948
|
-
* it's color. It consists of three properties:
|
|
8949
|
-
* - color: rgb or hex representation of the color you wish to trim (todo: verify the rgba bit)
|
|
8950
|
-
* - tolerance: difference from color to treat as color
|
|
8951
|
-
* - keep: the number of pixels of border to keep
|
|
8952
|
-
*/
|
|
8953
|
-
trim?: "border" | {
|
|
8954
|
-
top?: number;
|
|
8955
|
-
bottom?: number;
|
|
8956
|
-
left?: number;
|
|
8957
|
-
right?: number;
|
|
8958
|
-
width?: number;
|
|
8959
|
-
height?: number;
|
|
8960
|
-
border?:
|
|
8961
|
-
| boolean
|
|
8962
|
-
| {
|
|
8963
|
-
color?: string;
|
|
8964
|
-
tolerance?: number;
|
|
8965
|
-
keep?: number;
|
|
8966
|
-
};
|
|
8967
|
-
};
|
|
8968
9053
|
/**
|
|
8969
9054
|
* Quality setting from 1-100 (useful values are in 60-90 range). Lower values
|
|
8970
9055
|
* make images look worse, but load faster. The default is 85. It applies only
|
|
@@ -9006,17 +9091,6 @@ interface RequestInitCfPropertiesImage extends BasicImageTransformations {
|
|
|
9006
9091
|
* output formats always discard metadata.
|
|
9007
9092
|
*/
|
|
9008
9093
|
metadata?: "keep" | "copyright" | "none";
|
|
9009
|
-
/**
|
|
9010
|
-
* Strength of sharpening filter to apply to the image. Floating-point
|
|
9011
|
-
* number between 0 (no sharpening, default) and 10 (maximum). 1.0 is a
|
|
9012
|
-
* recommended value for downscaled images.
|
|
9013
|
-
*/
|
|
9014
|
-
sharpen?: number;
|
|
9015
|
-
/**
|
|
9016
|
-
* Radius of a blur filter (approximate gaussian). Maximum supported radius
|
|
9017
|
-
* is 250.
|
|
9018
|
-
*/
|
|
9019
|
-
blur?: number;
|
|
9020
9094
|
/**
|
|
9021
9095
|
* Overlays are drawn in the order they appear in the array (last array
|
|
9022
9096
|
* entry is the topmost layer).
|
|
@@ -9028,55 +9102,6 @@ interface RequestInitCfPropertiesImage extends BasicImageTransformations {
|
|
|
9028
9102
|
* the origin.
|
|
9029
9103
|
*/
|
|
9030
9104
|
"origin-auth"?: "share-publicly";
|
|
9031
|
-
/**
|
|
9032
|
-
* Adds a border around the image. The border is added after resizing. Border
|
|
9033
|
-
* width takes dpr into account, and can be specified either using a single
|
|
9034
|
-
* width property, or individually for each side.
|
|
9035
|
-
*/
|
|
9036
|
-
border?:
|
|
9037
|
-
| {
|
|
9038
|
-
color: string;
|
|
9039
|
-
width: number;
|
|
9040
|
-
}
|
|
9041
|
-
| {
|
|
9042
|
-
color: string;
|
|
9043
|
-
top: number;
|
|
9044
|
-
right: number;
|
|
9045
|
-
bottom: number;
|
|
9046
|
-
left: number;
|
|
9047
|
-
};
|
|
9048
|
-
/**
|
|
9049
|
-
* Increase brightness by a factor. A value of 1.0 equals no change, a value
|
|
9050
|
-
* of 0.5 equals half brightness, and a value of 2.0 equals twice as bright.
|
|
9051
|
-
* 0 is ignored.
|
|
9052
|
-
*/
|
|
9053
|
-
brightness?: number;
|
|
9054
|
-
/**
|
|
9055
|
-
* Increase contrast by a factor. A value of 1.0 equals no change, a value of
|
|
9056
|
-
* 0.5 equals low contrast, and a value of 2.0 equals high contrast. 0 is
|
|
9057
|
-
* ignored.
|
|
9058
|
-
*/
|
|
9059
|
-
contrast?: number;
|
|
9060
|
-
/**
|
|
9061
|
-
* Increase exposure by a factor. A value of 1.0 equals no change, a value of
|
|
9062
|
-
* 0.5 darkens the image, and a value of 2.0 lightens the image. 0 is ignored.
|
|
9063
|
-
*/
|
|
9064
|
-
gamma?: number;
|
|
9065
|
-
|
|
9066
|
-
/**
|
|
9067
|
-
* Increase contrast by a factor. A value of 1.0 equals no change, a value of
|
|
9068
|
-
* 0.5 equals low contrast, and a value of 2.0 equals high contrast. 0 is
|
|
9069
|
-
* ignored.
|
|
9070
|
-
*/
|
|
9071
|
-
saturation?: number;
|
|
9072
|
-
|
|
9073
|
-
/**
|
|
9074
|
-
* Flips the images horizontally, vertically, or both. Flipping is applied before
|
|
9075
|
-
* rotation, so if you apply flip=h,rotate=90 then the image will be flipped
|
|
9076
|
-
* horizontally, then rotated by 90 degrees.
|
|
9077
|
-
*/
|
|
9078
|
-
flip?: 'h' | 'v' | 'hv',
|
|
9079
|
-
|
|
9080
9105
|
/**
|
|
9081
9106
|
* Slightly reduces latency on a cache miss by selecting a
|
|
9082
9107
|
* quickest-to-compress file format, at a cost of increased file size and
|
|
@@ -9086,6 +9111,9 @@ interface RequestInitCfPropertiesImage extends BasicImageTransformations {
|
|
|
9086
9111
|
* images.
|
|
9087
9112
|
*/
|
|
9088
9113
|
compression?: "fast";
|
|
9114
|
+
|
|
9115
|
+
// You probably want to add new properties to BasicImageTransformations, unless
|
|
9116
|
+
// you are absolutely sure they are only valid on the top level request
|
|
9089
9117
|
}
|
|
9090
9118
|
|
|
9091
9119
|
interface RequestInitCfPropertiesImageMinify {
|
|
@@ -11121,6 +11149,11 @@ declare namespace CloudflareWorkersModule {
|
|
|
11121
11149
|
sensitive?: WorkflowStepSensitivity;
|
|
11122
11150
|
};
|
|
11123
11151
|
|
|
11152
|
+
export type WorkflowStepRollbackConfig = Pick<
|
|
11153
|
+
WorkflowStepConfig,
|
|
11154
|
+
'retries' | 'timeout'
|
|
11155
|
+
>;
|
|
11156
|
+
|
|
11124
11157
|
export type WorkflowCronSchedule = {
|
|
11125
11158
|
/** Cron expression that triggered this event. */
|
|
11126
11159
|
cron: string;
|
|
@@ -11153,8 +11186,10 @@ declare namespace CloudflareWorkersModule {
|
|
|
11153
11186
|
};
|
|
11154
11187
|
|
|
11155
11188
|
export type WorkflowRollbackContext<T = unknown> = {
|
|
11189
|
+
ctx: WorkflowStepContext;
|
|
11156
11190
|
error: Error;
|
|
11157
11191
|
output: T | undefined;
|
|
11192
|
+
/** @deprecated Use \`ctx.step.name\` and \`ctx.step.count\` instead. */
|
|
11158
11193
|
stepName: string;
|
|
11159
11194
|
};
|
|
11160
11195
|
|
|
@@ -11163,8 +11198,8 @@ declare namespace CloudflareWorkersModule {
|
|
|
11163
11198
|
) => Promise<void>;
|
|
11164
11199
|
|
|
11165
11200
|
export type WorkflowStepRollbackOptions<T = unknown> = {
|
|
11166
|
-
rollback
|
|
11167
|
-
rollbackConfig?:
|
|
11201
|
+
rollback: WorkflowRollbackHandler<T>;
|
|
11202
|
+
rollbackConfig?: WorkflowStepRollbackConfig;
|
|
11168
11203
|
};
|
|
11169
11204
|
|
|
11170
11205
|
export abstract class WorkflowStep {
|