@nonphoto/sanity-image 2.0.0 → 2.0.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/dist/index.js +1 -1
- package/package.json +8 -13
- package/src/index.ts +1 -1
package/dist/index.js
CHANGED
|
@@ -54,7 +54,7 @@ function isHotspot(x) {
|
|
|
54
54
|
return x != null && typeof x == "object" && "width" in x && typeof x.width === "number" && "height" in x && typeof x.height === "number" && "x" in x && typeof x.x === "number" && "y" in x && typeof x.y === "number" && ("_type" in x ? typeof x._type === "undefined" || typeof x._type === "string" : true);
|
|
55
55
|
}
|
|
56
56
|
function isImageObjectLike(x) {
|
|
57
|
-
return x != null && typeof x === "object" && "asset" in x && (isAsset(x) || isReference(x));
|
|
57
|
+
return x != null && typeof x === "object" && "asset" in x && (isAsset(x.asset) || isReference(x.asset));
|
|
58
58
|
}
|
|
59
59
|
function isImageObject(x) {
|
|
60
60
|
return isImageObjectLike(x) && ("crop" in x ? typeof x.crop === "undefined" || isCrop(x.crop) : true) && ("hotspot" in x ? typeof x.hotspot === "undefined" || isHotspot(x.hotspot) : true);
|
package/package.json
CHANGED
|
@@ -1,6 +1,8 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@nonphoto/sanity-image",
|
|
3
|
-
"version": "2.0.
|
|
3
|
+
"version": "2.0.1",
|
|
4
|
+
"author": "Jonas Luebbers <jonas@jonasluebbers.com> (https://www.jonasluebbers.com)",
|
|
5
|
+
"license": "MIT",
|
|
4
6
|
"type": "module",
|
|
5
7
|
"sideEffects": false,
|
|
6
8
|
"publishConfig": {
|
|
@@ -26,23 +28,16 @@
|
|
|
26
28
|
"build": "tsup ./src/index.ts --dts --format esm --clean",
|
|
27
29
|
"release": "semantic-release"
|
|
28
30
|
},
|
|
29
|
-
"
|
|
30
|
-
"
|
|
31
|
-
|
|
32
|
-
"animation"
|
|
33
|
-
],
|
|
34
|
-
"author": "Jonas Luebbers <jonas@jonasluebbers.com> (https://www.jonasluebbers.com)",
|
|
35
|
-
"license": "MIT",
|
|
31
|
+
"dependencies": {
|
|
32
|
+
"@sanity/image-url": "^1.1.0"
|
|
33
|
+
},
|
|
36
34
|
"devDependencies": {
|
|
37
35
|
"semantic-release": "24.2.7",
|
|
38
36
|
"tsup": "8.5.0",
|
|
39
37
|
"typescript": "5.9.2"
|
|
40
38
|
},
|
|
41
39
|
"engines": {
|
|
42
|
-
"node": ">=20"
|
|
43
|
-
"pnpm": ">=9"
|
|
40
|
+
"node": ">=20"
|
|
44
41
|
},
|
|
45
|
-
"
|
|
46
|
-
"@sanity/image-url": "^1.1.0"
|
|
47
|
-
}
|
|
42
|
+
"packageManager": "pnpm@10.12.1"
|
|
48
43
|
}
|
package/src/index.ts
CHANGED