@snowcone-app/ui 0.10.7 → 0.10.9

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 CHANGED
@@ -11095,6 +11095,15 @@ var HeroProductImage = memo3(function HeroProductImage2({
11095
11095
  const [firstImageLoaded, setFirstImageLoaded] = useState31(false);
11096
11096
  const [loaderMounted, setLoaderMounted] = useState31(true);
11097
11097
  const [imgFailed, setImgFailed] = useState31(false);
11098
+ const failedSrc = (() => {
11099
+ if (!imgFailed || !renderedUrl) return void 0;
11100
+ try {
11101
+ const u = new URL(renderedUrl, typeof location !== "undefined" ? location.href : "https://x");
11102
+ return u.protocol === "blob:" ? "blob" : u.host + u.pathname;
11103
+ } catch {
11104
+ return "?";
11105
+ }
11106
+ })();
11098
11107
  const [retryNonce, setRetryNonce] = useState31(0);
11099
11108
  const retriedUrlRef = useRef23(null);
11100
11109
  const prevDisplayUrlRef = useRef23(displayUrl);
@@ -11185,6 +11194,8 @@ var HeroProductImage = memo3(function HeroProductImage2({
11185
11194
  style,
11186
11195
  "data-hero-image": "true",
11187
11196
  "data-fit": fit,
11197
+ "data-picture-failed": imgFailed ? "E_PICTURE_UNDISPLAYED" : void 0,
11198
+ "data-picture-failed-src": failedSrc,
11188
11199
  "data-mockup-unavailable": unavailable ? unavailable.code : void 0,
11189
11200
  children: [
11190
11201
  unavailable && /* @__PURE__ */ jsx61(