@depict-ai/ui 4.8.12 → 4.8.13
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/ES10/index.cjs +6 -6
- package/ES10/index.d.ts +5 -1
- package/ES10/index.js +6 -6
- package/latest/index.cjs +5 -6
- package/latest/index.d.ts +5 -1
- package/latest/index.js +5 -6
- package/package.json +1 -1
- package/server/ES10/index.cjs +6 -3
- package/server/ES10/index.d.ts +5 -1
- package/server/ES10/index.js +6 -3
- package/server/latest/index.cjs +5 -3
- package/server/latest/index.d.ts +5 -1
- package/server/latest/index.js +5 -3
package/ES10/index.cjs
CHANGED
|
@@ -114,7 +114,7 @@ $parcel$export(module.exports, "BreadCrumbs", () => $335c02c1241a9ca8$export$5b7
|
|
|
114
114
|
$parcel$export(module.exports, "QuickLinks", () => $335c02c1241a9ca8$export$de035477d6fef996);
|
|
115
115
|
$parcel$export(module.exports, "CategoryPage", () => $c10e33c4681f8c9b$export$e2bf8ce7779e827e);
|
|
116
116
|
/*! Depict.ai search and product listing SDK */
|
|
117
|
-
const $aa1938dec50d6c12$export$83d89fbfd8236492 = "4.8.
|
|
117
|
+
const $aa1938dec50d6c12$export$83d89fbfd8236492 = "4.8.13";
|
|
118
118
|
function $054b1113e4897051$export$54c6d6ff54e72743(whatToWatch) {
|
|
119
119
|
const [width, setWidth] = $52FdA$solidjs.createSignal(0);
|
|
120
120
|
const [height, setHeight] = $52FdA$solidjs.createSignal(0);
|
|
@@ -259,7 +259,7 @@ function $858fdcf73148519f$export$6e5611bc7e57e477(props) {
|
|
|
259
259
|
};
|
|
260
260
|
});
|
|
261
261
|
// Work around https://github.com/solidjs/solid/issues/1828
|
|
262
|
-
const [, otherAttributes] = $52FdA$solidjs.splitProps(props, ["resolutions", "size", "src", "srcSet", "loading", "keyRatioUpdating", "sizeHeight", "customUrls" // Can't have properties ending on underscore because the property name mangling will get confused by this <-
|
|
262
|
+
const [, otherAttributes] = $52FdA$solidjs.splitProps(props, ["resolutions", "size", "src", "srcSet", "loading", "keyRatioUpdating", "sizeHeight", "onDecoded", "customUrls" // Can't have properties ending on underscore because the property name mangling will get confused by this <-
|
|
263
263
|
]);
|
|
264
264
|
|
|
265
265
|
const [hasSetSize, setHasSetSize] = $52FdA$solidjs.createSignal(false);
|
|
@@ -388,11 +388,13 @@ function $858fdcf73148519f$export$6e5611bc7e57e477(props) {
|
|
|
388
388
|
}
|
|
389
389
|
img.decode().catch(e => $52FdA$depictaiutilishared.dwarn("Failed to decode image", e, img)) // Display the image also if loading failed so webdev can debug and doesn't get "no image"
|
|
390
390
|
.then(async () => {
|
|
391
|
+
var _props$onDecoded;
|
|
391
392
|
// Also wait with inserting image (i.e. paint) until browser is idle
|
|
392
393
|
await new Promise(r => executeWhenIdleBatched(r, false));
|
|
393
394
|
if (gotCleanedUp) return;
|
|
394
395
|
setHasDecoded(true);
|
|
395
396
|
hasDecodedFastPath = true;
|
|
397
|
+
(_props$onDecoded = props.onDecoded) === null || _props$onDecoded === void 0 || _props$onDecoded.call(props);
|
|
396
398
|
});
|
|
397
399
|
});
|
|
398
400
|
$52FdA$solidjs.createEffect(() => hasDecoded() && requestAnimationFrame($52FdA$depictaiutilishared.catchify(() => setRAFSinceReturned(prev => !prev))));
|
|
@@ -16104,10 +16106,8 @@ function $c19709057a32b2e7$export$780a853d15174484(_ref) {
|
|
|
16104
16106
|
},
|
|
16105
16107
|
src: mediaUrl_,
|
|
16106
16108
|
"class": "d-standard-content",
|
|
16107
|
-
|
|
16108
|
-
|
|
16109
|
-
setHasLoaded(true);
|
|
16110
|
-
}))
|
|
16109
|
+
onDecoded: () => setHasLoaded(true),
|
|
16110
|
+
ref: el => el.addEventListener("load", $52FdA$depictaiutilisharedlatest.catchify(() => setAspectRatio(el.naturalWidth / el.naturalHeight)))
|
|
16111
16111
|
});
|
|
16112
16112
|
}
|
|
16113
16113
|
}), $52FdA$solidjsweb.createComponent((0, $52FdA$solidjs.Match), {
|
package/ES10/index.d.ts
CHANGED
|
@@ -11,7 +11,7 @@ import { GetListingRequest } from "@depict-ai/types/api/GetListingRequest";
|
|
|
11
11
|
import { BaseSearchRequestV3 } from "@depict-ai/types/api/BaseSearchRequestV3";
|
|
12
12
|
import { FeaturedInDisplay } from "@depict-ai/types/api/FeaturedInResponseV3";
|
|
13
13
|
import { SearchFilter as _SearchFilter3 } from "@depict-ai/types/api/SearchRequestV2";
|
|
14
|
-
export const version = "4.8.
|
|
14
|
+
export const version = "4.8.13";
|
|
15
15
|
/**
|
|
16
16
|
* Returns two accessors (one width and one height) that will update when the size of the provided element changes, to be used with ResponsiveImg
|
|
17
17
|
*/
|
|
@@ -127,6 +127,10 @@ export function ShopifyResponsiveImg(props: {
|
|
|
127
127
|
*/
|
|
128
128
|
sizeHeight?: Accessor<number>;
|
|
129
129
|
src: string;
|
|
130
|
+
/**
|
|
131
|
+
* When image is not lazy loaded this callback will be called every time the image has been decoded
|
|
132
|
+
*/
|
|
133
|
+
onDecoded?: VoidFunction;
|
|
130
134
|
loading?: "eager" | "lazy" | "force-lazy";
|
|
131
135
|
customUrls?: (url: string, width: number) => string;
|
|
132
136
|
/**
|
package/ES10/index.js
CHANGED
|
@@ -10,7 +10,7 @@ import $8tj43$babelruntimehelpersclassPrivateFieldGet from "@babel/runtime/helpe
|
|
|
10
10
|
/*! Depict.ai search and product listing SDK */
|
|
11
11
|
import { register_es_version } from "../multi_import_deduplicator.mjs";
|
|
12
12
|
register_es_version("ui", "ES10");
|
|
13
|
-
const $8db9a15135765c11$export$83d89fbfd8236492 = "4.8.
|
|
13
|
+
const $8db9a15135765c11$export$83d89fbfd8236492 = "4.8.13";
|
|
14
14
|
function $4be619ec2cd7bba3$export$54c6d6ff54e72743(whatToWatch) {
|
|
15
15
|
const [width, setWidth] = $8tj43$createSignal(0);
|
|
16
16
|
const [height, setHeight] = $8tj43$createSignal(0);
|
|
@@ -155,7 +155,7 @@ function $56047603f9d212b6$export$6e5611bc7e57e477(props) {
|
|
|
155
155
|
};
|
|
156
156
|
});
|
|
157
157
|
// Work around https://github.com/solidjs/solid/issues/1828
|
|
158
|
-
const [, otherAttributes] = $8tj43$splitProps(props, ["resolutions", "size", "src", "srcSet", "loading", "keyRatioUpdating", "sizeHeight", "customUrls" // Can't have properties ending on underscore because the property name mangling will get confused by this <-
|
|
158
|
+
const [, otherAttributes] = $8tj43$splitProps(props, ["resolutions", "size", "src", "srcSet", "loading", "keyRatioUpdating", "sizeHeight", "onDecoded", "customUrls" // Can't have properties ending on underscore because the property name mangling will get confused by this <-
|
|
159
159
|
]);
|
|
160
160
|
|
|
161
161
|
const [hasSetSize, setHasSetSize] = $8tj43$createSignal(false);
|
|
@@ -284,11 +284,13 @@ function $56047603f9d212b6$export$6e5611bc7e57e477(props) {
|
|
|
284
284
|
}
|
|
285
285
|
img.decode().catch(e => $8tj43$dwarn("Failed to decode image", e, img)) // Display the image also if loading failed so webdev can debug and doesn't get "no image"
|
|
286
286
|
.then(async () => {
|
|
287
|
+
var _props$onDecoded;
|
|
287
288
|
// Also wait with inserting image (i.e. paint) until browser is idle
|
|
288
289
|
await new Promise(r => executeWhenIdleBatched(r, false));
|
|
289
290
|
if (gotCleanedUp) return;
|
|
290
291
|
setHasDecoded(true);
|
|
291
292
|
hasDecodedFastPath = true;
|
|
293
|
+
(_props$onDecoded = props.onDecoded) === null || _props$onDecoded === void 0 || _props$onDecoded.call(props);
|
|
292
294
|
});
|
|
293
295
|
});
|
|
294
296
|
$8tj43$createEffect(() => hasDecoded() && requestAnimationFrame($8tj43$catchify(() => setRAFSinceReturned(prev => !prev))));
|
|
@@ -16000,10 +16002,8 @@ function $3b772ef9a35560fe$export$780a853d15174484(_ref) {
|
|
|
16000
16002
|
},
|
|
16001
16003
|
src: mediaUrl_,
|
|
16002
16004
|
"class": "d-standard-content",
|
|
16003
|
-
|
|
16004
|
-
|
|
16005
|
-
setHasLoaded(true);
|
|
16006
|
-
}))
|
|
16005
|
+
onDecoded: () => setHasLoaded(true),
|
|
16006
|
+
ref: el => el.addEventListener("load", $8tj43$catchify1(() => setAspectRatio(el.naturalWidth / el.naturalHeight)))
|
|
16007
16007
|
});
|
|
16008
16008
|
}
|
|
16009
16009
|
}), $8tj43$createComponent((0, $8tj43$Match), {
|
package/latest/index.cjs
CHANGED
|
@@ -108,7 +108,7 @@ $parcel$export(module.exports, "BreadCrumbs", () => $1f4925833f07df29$export$5b7
|
|
|
108
108
|
$parcel$export(module.exports, "QuickLinks", () => $1f4925833f07df29$export$de035477d6fef996);
|
|
109
109
|
$parcel$export(module.exports, "CategoryPage", () => $14f289047713d67a$export$e2bf8ce7779e827e);
|
|
110
110
|
/*! Depict.ai search and product listing SDK */
|
|
111
|
-
const $b757f75811f3261f$export$83d89fbfd8236492 = "4.8.
|
|
111
|
+
const $b757f75811f3261f$export$83d89fbfd8236492 = "4.8.13";
|
|
112
112
|
function $128302ab61dab8f1$export$54c6d6ff54e72743(whatToWatch) {
|
|
113
113
|
const [width, setWidth] = $gVhhF$solidjs.createSignal(0);
|
|
114
114
|
const [height, setHeight] = $gVhhF$solidjs.createSignal(0);
|
|
@@ -248,7 +248,7 @@ function $19950faaac026e09$export$6e5611bc7e57e477(props) {
|
|
|
248
248
|
};
|
|
249
249
|
});
|
|
250
250
|
// Work around https://github.com/solidjs/solid/issues/1828
|
|
251
|
-
const [, otherAttributes] = $gVhhF$solidjs.splitProps(props, ["resolutions", "size", "src", "srcSet", "loading", "keyRatioUpdating", "sizeHeight", "customUrls" // Can't have properties ending on underscore because the property name mangling will get confused by this <-
|
|
251
|
+
const [, otherAttributes] = $gVhhF$solidjs.splitProps(props, ["resolutions", "size", "src", "srcSet", "loading", "keyRatioUpdating", "sizeHeight", "onDecoded", "customUrls" // Can't have properties ending on underscore because the property name mangling will get confused by this <-
|
|
252
252
|
]);
|
|
253
253
|
|
|
254
254
|
const [hasSetSize, setHasSetSize] = $gVhhF$solidjs.createSignal(false);
|
|
@@ -379,6 +379,7 @@ function $19950faaac026e09$export$6e5611bc7e57e477(props) {
|
|
|
379
379
|
if (gotCleanedUp) return;
|
|
380
380
|
setHasDecoded(true);
|
|
381
381
|
hasDecodedFastPath = true;
|
|
382
|
+
props.onDecoded?.();
|
|
382
383
|
});
|
|
383
384
|
});
|
|
384
385
|
$gVhhF$solidjs.createEffect(() => hasDecoded() && requestAnimationFrame($gVhhF$depictaiutilishared.catchify(() => setRAFSinceReturned(prev => !prev))));
|
|
@@ -15051,10 +15052,8 @@ function $32c662f618f5d80d$export$780a853d15174484({
|
|
|
15051
15052
|
sizeHeight: () => wrapperSize()?.[1]?.() || 0,
|
|
15052
15053
|
src: mediaUrl_,
|
|
15053
15054
|
"class": "d-standard-content",
|
|
15054
|
-
|
|
15055
|
-
|
|
15056
|
-
setHasLoaded(true);
|
|
15057
|
-
}))
|
|
15055
|
+
onDecoded: () => setHasLoaded(true),
|
|
15056
|
+
ref: el => el.addEventListener("load", $gVhhF$depictaiutilisharedlatest.catchify(() => setAspectRatio(el.naturalWidth / el.naturalHeight)))
|
|
15058
15057
|
});
|
|
15059
15058
|
}
|
|
15060
15059
|
}), $gVhhF$solidjsweb.createComponent((0, $gVhhF$solidjs.Match), {
|
package/latest/index.d.ts
CHANGED
|
@@ -11,7 +11,7 @@ import { GetListingRequest } from "@depict-ai/types/api/GetListingRequest";
|
|
|
11
11
|
import { BaseSearchRequestV3 } from "@depict-ai/types/api/BaseSearchRequestV3";
|
|
12
12
|
import { FeaturedInDisplay } from "@depict-ai/types/api/FeaturedInResponseV3";
|
|
13
13
|
import { SearchFilter as _SearchFilter3 } from "@depict-ai/types/api/SearchRequestV2";
|
|
14
|
-
export const version = "4.8.
|
|
14
|
+
export const version = "4.8.13";
|
|
15
15
|
/**
|
|
16
16
|
* Returns two accessors (one width and one height) that will update when the size of the provided element changes, to be used with ResponsiveImg
|
|
17
17
|
*/
|
|
@@ -127,6 +127,10 @@ export function ShopifyResponsiveImg(props: {
|
|
|
127
127
|
*/
|
|
128
128
|
sizeHeight?: Accessor<number>;
|
|
129
129
|
src: string;
|
|
130
|
+
/**
|
|
131
|
+
* When image is not lazy loaded this callback will be called every time the image has been decoded
|
|
132
|
+
*/
|
|
133
|
+
onDecoded?: VoidFunction;
|
|
130
134
|
loading?: "eager" | "lazy" | "force-lazy";
|
|
131
135
|
customUrls?: (url: string, width: number) => string;
|
|
132
136
|
/**
|
package/latest/index.js
CHANGED
|
@@ -7,7 +7,7 @@ import { dlog as $9HbP8$dlog, catchify as $9HbP8$catchify1, ListenableSet as $9H
|
|
|
7
7
|
/*! Depict.ai search and product listing SDK */
|
|
8
8
|
import { register_es_version } from "../multi_import_deduplicator.mjs";
|
|
9
9
|
register_es_version("ui", "latest");
|
|
10
|
-
const $ec291e0010116877$export$83d89fbfd8236492 = "4.8.
|
|
10
|
+
const $ec291e0010116877$export$83d89fbfd8236492 = "4.8.13";
|
|
11
11
|
function $a444a52bafa0dacc$export$54c6d6ff54e72743(whatToWatch) {
|
|
12
12
|
const [width, setWidth] = $9HbP8$createSignal(0);
|
|
13
13
|
const [height, setHeight] = $9HbP8$createSignal(0);
|
|
@@ -147,7 +147,7 @@ function $e8ffe11ed01df0fe$export$6e5611bc7e57e477(props) {
|
|
|
147
147
|
};
|
|
148
148
|
});
|
|
149
149
|
// Work around https://github.com/solidjs/solid/issues/1828
|
|
150
|
-
const [, otherAttributes] = $9HbP8$splitProps(props, ["resolutions", "size", "src", "srcSet", "loading", "keyRatioUpdating", "sizeHeight", "customUrls" // Can't have properties ending on underscore because the property name mangling will get confused by this <-
|
|
150
|
+
const [, otherAttributes] = $9HbP8$splitProps(props, ["resolutions", "size", "src", "srcSet", "loading", "keyRatioUpdating", "sizeHeight", "onDecoded", "customUrls" // Can't have properties ending on underscore because the property name mangling will get confused by this <-
|
|
151
151
|
]);
|
|
152
152
|
|
|
153
153
|
const [hasSetSize, setHasSetSize] = $9HbP8$createSignal(false);
|
|
@@ -278,6 +278,7 @@ function $e8ffe11ed01df0fe$export$6e5611bc7e57e477(props) {
|
|
|
278
278
|
if (gotCleanedUp) return;
|
|
279
279
|
setHasDecoded(true);
|
|
280
280
|
hasDecodedFastPath = true;
|
|
281
|
+
props.onDecoded?.();
|
|
281
282
|
});
|
|
282
283
|
});
|
|
283
284
|
$9HbP8$createEffect(() => hasDecoded() && requestAnimationFrame($9HbP8$catchify(() => setRAFSinceReturned(prev => !prev))));
|
|
@@ -14950,10 +14951,8 @@ function $f916989c4b1be9f7$export$780a853d15174484({
|
|
|
14950
14951
|
sizeHeight: () => wrapperSize()?.[1]?.() || 0,
|
|
14951
14952
|
src: mediaUrl_,
|
|
14952
14953
|
"class": "d-standard-content",
|
|
14953
|
-
|
|
14954
|
-
|
|
14955
|
-
setHasLoaded(true);
|
|
14956
|
-
}))
|
|
14954
|
+
onDecoded: () => setHasLoaded(true),
|
|
14955
|
+
ref: el => el.addEventListener("load", $9HbP8$catchify1(() => setAspectRatio(el.naturalWidth / el.naturalHeight)))
|
|
14957
14956
|
});
|
|
14958
14957
|
}
|
|
14959
14958
|
}), $9HbP8$createComponent((0, $9HbP8$Match), {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@depict-ai/ui",
|
|
3
|
-
"version": "4.8.
|
|
3
|
+
"version": "4.8.13",
|
|
4
4
|
"description": "Base package containing the actual UI of Depict UI along with translations, with a not-simplified API. We recommend using @depict-ai/js-ui or @depict-ai/react-ui instead.",
|
|
5
5
|
"packageManager": "yarn@3.2.2",
|
|
6
6
|
"sass": "styles.scss",
|
package/server/ES10/index.cjs
CHANGED
|
@@ -114,7 +114,7 @@ $parcel$export(module.exports, "BreadCrumbs", () => $335c02c1241a9ca8$export$5b7
|
|
|
114
114
|
$parcel$export(module.exports, "QuickLinks", () => $335c02c1241a9ca8$export$de035477d6fef996);
|
|
115
115
|
$parcel$export(module.exports, "CategoryPage", () => $c10e33c4681f8c9b$export$e2bf8ce7779e827e);
|
|
116
116
|
/*! Depict.ai search and product listing SDK */
|
|
117
|
-
const $aa1938dec50d6c12$export$83d89fbfd8236492 = "4.8.
|
|
117
|
+
const $aa1938dec50d6c12$export$83d89fbfd8236492 = "4.8.13";
|
|
118
118
|
function $054b1113e4897051$export$54c6d6ff54e72743(whatToWatch) {
|
|
119
119
|
const [width, setWidth] = $3hooq$solidjs.createSignal(0);
|
|
120
120
|
const [height, setHeight] = $3hooq$solidjs.createSignal(0);
|
|
@@ -245,7 +245,7 @@ function $858fdcf73148519f$export$6e5611bc7e57e477(props) {
|
|
|
245
245
|
};
|
|
246
246
|
});
|
|
247
247
|
// Work around https://github.com/solidjs/solid/issues/1828
|
|
248
|
-
const [, otherAttributes] = $3hooq$solidjs.splitProps(props, ["resolutions", "size", "src", "srcSet", "loading", "keyRatioUpdating", "sizeHeight", "customUrls" // Can't have properties ending on underscore because the property name mangling will get confused by this <-
|
|
248
|
+
const [, otherAttributes] = $3hooq$solidjs.splitProps(props, ["resolutions", "size", "src", "srcSet", "loading", "keyRatioUpdating", "sizeHeight", "onDecoded", "customUrls" // Can't have properties ending on underscore because the property name mangling will get confused by this <-
|
|
249
249
|
]);
|
|
250
250
|
|
|
251
251
|
const [hasSetSize, setHasSetSize] = $3hooq$solidjs.createSignal(false);
|
|
@@ -374,11 +374,13 @@ function $858fdcf73148519f$export$6e5611bc7e57e477(props) {
|
|
|
374
374
|
}
|
|
375
375
|
img.decode().catch(e => $3hooq$depictaiutilishared.dwarn("Failed to decode image", e, img)) // Display the image also if loading failed so webdev can debug and doesn't get "no image"
|
|
376
376
|
.then(async () => {
|
|
377
|
+
var _props$onDecoded;
|
|
377
378
|
// Also wait with inserting image (i.e. paint) until browser is idle
|
|
378
379
|
await new Promise(r => executeWhenIdleBatched(r, false));
|
|
379
380
|
if (gotCleanedUp) return;
|
|
380
381
|
setHasDecoded(true);
|
|
381
382
|
hasDecodedFastPath = true;
|
|
383
|
+
(_props$onDecoded = props.onDecoded) === null || _props$onDecoded === void 0 || _props$onDecoded.call(props);
|
|
382
384
|
});
|
|
383
385
|
});
|
|
384
386
|
$3hooq$solidjs.createEffect(() => hasDecoded() && requestAnimationFrame($3hooq$depictaiutilishared.catchify(() => setRAFSinceReturned(prev => !prev))));
|
|
@@ -13463,7 +13465,8 @@ function $c19709057a32b2e7$export$780a853d15174484(_ref) {
|
|
|
13463
13465
|
return ((_wrapperSize2 = wrapperSize()) === null || _wrapperSize2 === void 0 ? void 0 : (_wrapperSize2$ = _wrapperSize2[1]) === null || _wrapperSize2$ === void 0 ? void 0 : _wrapperSize2$.call(_wrapperSize2)) || 0;
|
|
13464
13466
|
},
|
|
13465
13467
|
src: mediaUrl_,
|
|
13466
|
-
"class": "d-standard-content"
|
|
13468
|
+
"class": "d-standard-content",
|
|
13469
|
+
onDecoded: () => setHasLoaded(true)
|
|
13467
13470
|
});
|
|
13468
13471
|
}
|
|
13469
13472
|
}), $3hooq$solidjsweb.createComponent((0, $3hooq$solidjs.Match), {
|
package/server/ES10/index.d.ts
CHANGED
|
@@ -11,7 +11,7 @@ import { GetListingRequest } from "@depict-ai/types/api/GetListingRequest";
|
|
|
11
11
|
import { BaseSearchRequestV3 } from "@depict-ai/types/api/BaseSearchRequestV3";
|
|
12
12
|
import { FeaturedInDisplay } from "@depict-ai/types/api/FeaturedInResponseV3";
|
|
13
13
|
import { SearchFilter as _SearchFilter3 } from "@depict-ai/types/api/SearchRequestV2";
|
|
14
|
-
export const version = "4.8.
|
|
14
|
+
export const version = "4.8.13";
|
|
15
15
|
/**
|
|
16
16
|
* Returns two accessors (one width and one height) that will update when the size of the provided element changes, to be used with ResponsiveImg
|
|
17
17
|
*/
|
|
@@ -127,6 +127,10 @@ export function ShopifyResponsiveImg(props: {
|
|
|
127
127
|
*/
|
|
128
128
|
sizeHeight?: Accessor<number>;
|
|
129
129
|
src: string;
|
|
130
|
+
/**
|
|
131
|
+
* When image is not lazy loaded this callback will be called every time the image has been decoded
|
|
132
|
+
*/
|
|
133
|
+
onDecoded?: VoidFunction;
|
|
130
134
|
loading?: "eager" | "lazy" | "force-lazy";
|
|
131
135
|
customUrls?: (url: string, width: number) => string;
|
|
132
136
|
/**
|
package/server/ES10/index.js
CHANGED
|
@@ -10,7 +10,7 @@ import $b8hua$babelruntimehelpersclassPrivateFieldGet from "@babel/runtime/helpe
|
|
|
10
10
|
/*! Depict.ai search and product listing SDK */
|
|
11
11
|
import { register_es_version } from "../../multi_import_deduplicator.mjs";
|
|
12
12
|
register_es_version("ui", "ES10");
|
|
13
|
-
const $8db9a15135765c11$export$83d89fbfd8236492 = "4.8.
|
|
13
|
+
const $8db9a15135765c11$export$83d89fbfd8236492 = "4.8.13";
|
|
14
14
|
function $4be619ec2cd7bba3$export$54c6d6ff54e72743(whatToWatch) {
|
|
15
15
|
const [width, setWidth] = $b8hua$createSignal(0);
|
|
16
16
|
const [height, setHeight] = $b8hua$createSignal(0);
|
|
@@ -141,7 +141,7 @@ function $56047603f9d212b6$export$6e5611bc7e57e477(props) {
|
|
|
141
141
|
};
|
|
142
142
|
});
|
|
143
143
|
// Work around https://github.com/solidjs/solid/issues/1828
|
|
144
|
-
const [, otherAttributes] = $b8hua$splitProps(props, ["resolutions", "size", "src", "srcSet", "loading", "keyRatioUpdating", "sizeHeight", "customUrls" // Can't have properties ending on underscore because the property name mangling will get confused by this <-
|
|
144
|
+
const [, otherAttributes] = $b8hua$splitProps(props, ["resolutions", "size", "src", "srcSet", "loading", "keyRatioUpdating", "sizeHeight", "onDecoded", "customUrls" // Can't have properties ending on underscore because the property name mangling will get confused by this <-
|
|
145
145
|
]);
|
|
146
146
|
|
|
147
147
|
const [hasSetSize, setHasSetSize] = $b8hua$createSignal(false);
|
|
@@ -270,11 +270,13 @@ function $56047603f9d212b6$export$6e5611bc7e57e477(props) {
|
|
|
270
270
|
}
|
|
271
271
|
img.decode().catch(e => $b8hua$dwarn("Failed to decode image", e, img)) // Display the image also if loading failed so webdev can debug and doesn't get "no image"
|
|
272
272
|
.then(async () => {
|
|
273
|
+
var _props$onDecoded;
|
|
273
274
|
// Also wait with inserting image (i.e. paint) until browser is idle
|
|
274
275
|
await new Promise(r => executeWhenIdleBatched(r, false));
|
|
275
276
|
if (gotCleanedUp) return;
|
|
276
277
|
setHasDecoded(true);
|
|
277
278
|
hasDecodedFastPath = true;
|
|
279
|
+
(_props$onDecoded = props.onDecoded) === null || _props$onDecoded === void 0 || _props$onDecoded.call(props);
|
|
278
280
|
});
|
|
279
281
|
});
|
|
280
282
|
$b8hua$createEffect(() => hasDecoded() && requestAnimationFrame($b8hua$catchify(() => setRAFSinceReturned(prev => !prev))));
|
|
@@ -13359,7 +13361,8 @@ function $3b772ef9a35560fe$export$780a853d15174484(_ref) {
|
|
|
13359
13361
|
return ((_wrapperSize2 = wrapperSize()) === null || _wrapperSize2 === void 0 ? void 0 : (_wrapperSize2$ = _wrapperSize2[1]) === null || _wrapperSize2$ === void 0 ? void 0 : _wrapperSize2$.call(_wrapperSize2)) || 0;
|
|
13360
13362
|
},
|
|
13361
13363
|
src: mediaUrl_,
|
|
13362
|
-
"class": "d-standard-content"
|
|
13364
|
+
"class": "d-standard-content",
|
|
13365
|
+
onDecoded: () => setHasLoaded(true)
|
|
13363
13366
|
});
|
|
13364
13367
|
}
|
|
13365
13368
|
}), $b8hua$createComponent((0, $b8hua$Match), {
|
package/server/latest/index.cjs
CHANGED
|
@@ -108,7 +108,7 @@ $parcel$export(module.exports, "BreadCrumbs", () => $1f4925833f07df29$export$5b7
|
|
|
108
108
|
$parcel$export(module.exports, "QuickLinks", () => $1f4925833f07df29$export$de035477d6fef996);
|
|
109
109
|
$parcel$export(module.exports, "CategoryPage", () => $14f289047713d67a$export$e2bf8ce7779e827e);
|
|
110
110
|
/*! Depict.ai search and product listing SDK */
|
|
111
|
-
const $b757f75811f3261f$export$83d89fbfd8236492 = "4.8.
|
|
111
|
+
const $b757f75811f3261f$export$83d89fbfd8236492 = "4.8.13";
|
|
112
112
|
function $128302ab61dab8f1$export$54c6d6ff54e72743(whatToWatch) {
|
|
113
113
|
const [width, setWidth] = $5vyXB$solidjs.createSignal(0);
|
|
114
114
|
const [height, setHeight] = $5vyXB$solidjs.createSignal(0);
|
|
@@ -234,7 +234,7 @@ function $19950faaac026e09$export$6e5611bc7e57e477(props) {
|
|
|
234
234
|
};
|
|
235
235
|
});
|
|
236
236
|
// Work around https://github.com/solidjs/solid/issues/1828
|
|
237
|
-
const [, otherAttributes] = $5vyXB$solidjs.splitProps(props, ["resolutions", "size", "src", "srcSet", "loading", "keyRatioUpdating", "sizeHeight", "customUrls" // Can't have properties ending on underscore because the property name mangling will get confused by this <-
|
|
237
|
+
const [, otherAttributes] = $5vyXB$solidjs.splitProps(props, ["resolutions", "size", "src", "srcSet", "loading", "keyRatioUpdating", "sizeHeight", "onDecoded", "customUrls" // Can't have properties ending on underscore because the property name mangling will get confused by this <-
|
|
238
238
|
]);
|
|
239
239
|
|
|
240
240
|
const [hasSetSize, setHasSetSize] = $5vyXB$solidjs.createSignal(false);
|
|
@@ -365,6 +365,7 @@ function $19950faaac026e09$export$6e5611bc7e57e477(props) {
|
|
|
365
365
|
if (gotCleanedUp) return;
|
|
366
366
|
setHasDecoded(true);
|
|
367
367
|
hasDecodedFastPath = true;
|
|
368
|
+
props.onDecoded?.();
|
|
368
369
|
});
|
|
369
370
|
});
|
|
370
371
|
$5vyXB$solidjs.createEffect(() => hasDecoded() && requestAnimationFrame($5vyXB$depictaiutilishared.catchify(() => setRAFSinceReturned(prev => !prev))));
|
|
@@ -12491,7 +12492,8 @@ function $32c662f618f5d80d$export$780a853d15174484({
|
|
|
12491
12492
|
size: () => wrapperSize()?.[0]?.() || 0,
|
|
12492
12493
|
sizeHeight: () => wrapperSize()?.[1]?.() || 0,
|
|
12493
12494
|
src: mediaUrl_,
|
|
12494
|
-
"class": "d-standard-content"
|
|
12495
|
+
"class": "d-standard-content",
|
|
12496
|
+
onDecoded: () => setHasLoaded(true)
|
|
12495
12497
|
});
|
|
12496
12498
|
}
|
|
12497
12499
|
}), $5vyXB$solidjsweb.createComponent((0, $5vyXB$solidjs.Match), {
|
package/server/latest/index.d.ts
CHANGED
|
@@ -11,7 +11,7 @@ import { GetListingRequest } from "@depict-ai/types/api/GetListingRequest";
|
|
|
11
11
|
import { BaseSearchRequestV3 } from "@depict-ai/types/api/BaseSearchRequestV3";
|
|
12
12
|
import { FeaturedInDisplay } from "@depict-ai/types/api/FeaturedInResponseV3";
|
|
13
13
|
import { SearchFilter as _SearchFilter3 } from "@depict-ai/types/api/SearchRequestV2";
|
|
14
|
-
export const version = "4.8.
|
|
14
|
+
export const version = "4.8.13";
|
|
15
15
|
/**
|
|
16
16
|
* Returns two accessors (one width and one height) that will update when the size of the provided element changes, to be used with ResponsiveImg
|
|
17
17
|
*/
|
|
@@ -127,6 +127,10 @@ export function ShopifyResponsiveImg(props: {
|
|
|
127
127
|
*/
|
|
128
128
|
sizeHeight?: Accessor<number>;
|
|
129
129
|
src: string;
|
|
130
|
+
/**
|
|
131
|
+
* When image is not lazy loaded this callback will be called every time the image has been decoded
|
|
132
|
+
*/
|
|
133
|
+
onDecoded?: VoidFunction;
|
|
130
134
|
loading?: "eager" | "lazy" | "force-lazy";
|
|
131
135
|
customUrls?: (url: string, width: number) => string;
|
|
132
136
|
/**
|
package/server/latest/index.js
CHANGED
|
@@ -7,7 +7,7 @@ import { dlog as $i7OB2$dlog, catchify as $i7OB2$catchify1, ListenableSet as $i7
|
|
|
7
7
|
/*! Depict.ai search and product listing SDK */
|
|
8
8
|
import { register_es_version } from "../../multi_import_deduplicator.mjs";
|
|
9
9
|
register_es_version("ui", "latest");
|
|
10
|
-
const $ec291e0010116877$export$83d89fbfd8236492 = "4.8.
|
|
10
|
+
const $ec291e0010116877$export$83d89fbfd8236492 = "4.8.13";
|
|
11
11
|
function $a444a52bafa0dacc$export$54c6d6ff54e72743(whatToWatch) {
|
|
12
12
|
const [width, setWidth] = $i7OB2$createSignal(0);
|
|
13
13
|
const [height, setHeight] = $i7OB2$createSignal(0);
|
|
@@ -133,7 +133,7 @@ function $e8ffe11ed01df0fe$export$6e5611bc7e57e477(props) {
|
|
|
133
133
|
};
|
|
134
134
|
});
|
|
135
135
|
// Work around https://github.com/solidjs/solid/issues/1828
|
|
136
|
-
const [, otherAttributes] = $i7OB2$splitProps(props, ["resolutions", "size", "src", "srcSet", "loading", "keyRatioUpdating", "sizeHeight", "customUrls" // Can't have properties ending on underscore because the property name mangling will get confused by this <-
|
|
136
|
+
const [, otherAttributes] = $i7OB2$splitProps(props, ["resolutions", "size", "src", "srcSet", "loading", "keyRatioUpdating", "sizeHeight", "onDecoded", "customUrls" // Can't have properties ending on underscore because the property name mangling will get confused by this <-
|
|
137
137
|
]);
|
|
138
138
|
|
|
139
139
|
const [hasSetSize, setHasSetSize] = $i7OB2$createSignal(false);
|
|
@@ -264,6 +264,7 @@ function $e8ffe11ed01df0fe$export$6e5611bc7e57e477(props) {
|
|
|
264
264
|
if (gotCleanedUp) return;
|
|
265
265
|
setHasDecoded(true);
|
|
266
266
|
hasDecodedFastPath = true;
|
|
267
|
+
props.onDecoded?.();
|
|
267
268
|
});
|
|
268
269
|
});
|
|
269
270
|
$i7OB2$createEffect(() => hasDecoded() && requestAnimationFrame($i7OB2$catchify(() => setRAFSinceReturned(prev => !prev))));
|
|
@@ -12390,7 +12391,8 @@ function $f916989c4b1be9f7$export$780a853d15174484({
|
|
|
12390
12391
|
size: () => wrapperSize()?.[0]?.() || 0,
|
|
12391
12392
|
sizeHeight: () => wrapperSize()?.[1]?.() || 0,
|
|
12392
12393
|
src: mediaUrl_,
|
|
12393
|
-
"class": "d-standard-content"
|
|
12394
|
+
"class": "d-standard-content",
|
|
12395
|
+
onDecoded: () => setHasLoaded(true)
|
|
12394
12396
|
});
|
|
12395
12397
|
}
|
|
12396
12398
|
}), $i7OB2$createComponent((0, $i7OB2$Match), {
|