@wix/form-public 0.496.0 → 0.497.0
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.cjs +7 -6
- package/dist/index.cjs.map +1 -1
- package/dist/index.js +7 -6
- package/dist/index.js.map +1 -1
- package/package.json +2 -2
package/dist/index.cjs
CHANGED
|
@@ -56127,12 +56127,13 @@ var OptionImage = ({ className, ...internal }) => {
|
|
|
56127
56127
|
const { option: option2 } = internal;
|
|
56128
56128
|
const { choiceImageResize, choiceImageAlignment } = useFieldPropsV2();
|
|
56129
56129
|
const image = option2.media?.image;
|
|
56130
|
-
|
|
56131
|
-
|
|
56132
|
-
|
|
56133
|
-
|
|
56134
|
-
|
|
56135
|
-
|
|
56130
|
+
const imageURL = image && getImageURL(image, image.width, image.height);
|
|
56131
|
+
if (!image || !imageURL) {
|
|
56132
|
+
return /* @__PURE__ */ React172__default.default.createElement("div", {
|
|
56133
|
+
className,
|
|
56134
|
+
"data-placeholder": true,
|
|
56135
|
+
"data-hook": "image-choice-option-image"
|
|
56136
|
+
});
|
|
56136
56137
|
}
|
|
56137
56138
|
const imageAlt = option2.media?.altText || option2.altText || image.altText || "";
|
|
56138
56139
|
return /* @__PURE__ */ React172__default.default.createElement("img", {
|