"use strict";var e=require("@gem-sdk/core");const t=["mobile","tablet","desktop"],l=e=>({desktop:e?.desktop?.width,tablet:e?.tablet?.width,mobile:e?.mobile?.width}),o=e=>({desktop:e?.desktop?.height,tablet:e?.tablet?.height,mobile:e?.mobile?.height});exports.convertUnitToNumber=(e,t)=>{if(!e)return t;if("number"==typeof e)return e;let l="string"==typeof e?e.replaceAll("px","").replaceAll("%","").replaceAll("rem","").replaceAll("em",""):t;return isNaN(Number(l))?t:Number(l)},exports.getFeatureImageAspectRatio=(t,r)=>e.makeAspectRatio(r,l(t),o(t)),exports.getStyleFeatureImageJustify=t=>{let l={desktop:"flex-start",mobile:"flex-start",tablet:"flex-start"};return["desktop","mobile","tablet"].forEach(o=>{let r=e.getResponsiveValueByScreen(t,o);l={...l,[`${o}`]:"bottom-left"===r?"flex-start":"bottom-center"===r?"center":"left"===r?"flex-start":"flex-end"}}),e.makeStyleResponsive("jc",l)},exports.getStyleFeaturedImageWidth=l=>{let o=l?.ftWidth;return t.forEach(t=>{let r=e.getResponsiveValueByScreen(l?.position,t),s=e.getResponsiveValueByScreen(l?.galleryVisible,t);o={...o,[t]:("left"===r||"right"===r)&&s?e.getResponsiveValueByScreen(l?.ftWidthHorizontalLayout,t):e.getResponsiveValueByScreen(l?.ftWidth,t)}}),{...e.makeStyleResponsive("w",e.makeWidth(o,{desktop:!1,tablet:!1,mobile:!1}))}},exports.getZoomImageClass=()=>"gp-absolute gp-left-0 gp-top-0 gp-opacity-0 gp-transition-opacity gp-bg-white",exports.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",exports.isFeatureMedia=e=>!!e&&["EXTERNAL_VIDEO","MODEL_3D","VIDEO"].includes(e);
