import{getResponsiveValueByScreen as e,makeStyleResponsive as t,makeWidth as a,makeAspectRatio as l}from"@gem-sdk/core";let DEVICES=["mobile","tablet","desktop"],isFeatureMedia=e=>!!e&&["EXTERNAL_VIDEO","MODEL_3D","VIDEO"].includes(e),getStyleFeaturedImageWidth=l=>{let o={desktop:!1,tablet:!1,mobile:!1},r=l?.ftWidth;return DEVICES.forEach(t=>{let a=e(l?.position,t),o=e(l?.galleryVisible,t),g=("left"===a||"right"===a)&&o;r={...r,[t]:g?e(l?.ftWidthHorizontalLayout,t):e(l?.ftWidth,t)}}),{...t("w",a(r,o))}},convertUnitToNumber=(e,t)=>{if(!e)return t;if("number"==typeof e)return e;let a="string"==typeof e?e.replaceAll("px","").replaceAll("%","").replaceAll("rem","").replaceAll("em",""):t;return isNaN(Number(a))?t:Number(a)},getFeatureImageAspectWidth=e=>({desktop:e?.desktop?.width,tablet:e?.tablet?.width,mobile:e?.mobile?.width}),getFeatureImageAspectHeight=e=>({desktop:e?.desktop?.height,tablet:e?.tablet?.height,mobile:e?.mobile?.height}),getFeatureImageAspectRatio=(e,t)=>l(t,getFeatureImageAspectWidth(e),getFeatureImageAspectHeight(e)),getStyleFeatureImageJustify=a=>{let l={desktop:"flex-start",mobile:"flex-start",tablet:"flex-start"},o=["desktop","mobile","tablet"];return o.forEach(t=>{let o=e(a,t);l={...l,[`${t}`]:"bottom-left"===o?"flex-start":"bottom-center"===o?"center":"left"===o?"flex-start":"flex-end"}}),t("jc",l)},getZoomLenClass=()=>"!gp-flex gp-absolute gp-z-1 gp-h-[150px] gp-w-[150px] gp-cursor-none gp-rounded-full gp-bg-no-repeat gp-shadow-glasses gp-bg-white",getZoomImageClass=()=>"gp-absolute gp-left-0 gp-top-0 gp-opacity-0 gp-transition-opacity gp-bg-white";export{convertUnitToNumber,getFeatureImageAspectRatio,getStyleFeatureImageJustify,getStyleFeaturedImageWidth,getZoomImageClass,getZoomLenClass,isFeatureMedia};
