"use strict";var e=require("@gem-sdk/core"),s=require("../utils/renderBadgeILP.js"),t=require("../utils/common.js");exports.getContainerClasses=({mode:t,isInstant:p,product:o,currentVariant:r,props:l,isSameHeightInProductList:g})=>{let{setting:a,builderProps:i}=l,n="gp-shrink-0 product-badge ",u=!t&&p?s.toggleBadge({triggers:a?.displayTrigger,productDetail:o,productVariant:r,isSameHeightInProductList:g}):`${i?.uid}`,d=i?.builderData?.advanced?.cssClass||"";return u&&(n+=`${u} `),d&&(n+=`${d} `),i?.uid&&(n+=`${i?.uid} `),a?.positionWithImage==="inside"&&(n+="inside-image "),{...e.composeClasses(n)}},exports.getImageClasses=()=>({...e.composeClasses("gp-object-cover gp-w-full gp-h-full gp-pointer-events-none")}),exports.getImageContainerClasses=()=>({...e.composeClasses("product-badge-item gp-w-full gp-h-full gp-overflow-hidden")}),exports.getSubWrapperClass=(s,p)=>{let{setting:o,style:r}=s,l=o?.positionWithImage==="inside",g=!l&&p?t.getShapePlacementClass(l,r,p):"gp-h-full";return{...e.composeClasses(g)}},exports.getTextContainerClasses=()=>({...e.composeClasses("gp-w-full gp-h-full gp-overflow-hidden product-badge-item")}),exports.getTextContentClasses=s=>{let t="gp-break-words gp-text-center ",p=e.composeTypographyClassName(s?.typo);return p&&(t+=`${p} `),{...e.composeClasses(t)}},exports.getTextWrapperClasses=()=>({...e.composeClasses("gp-w-full gp-h-full gp-flex gp-items-center gp-justify-center gp-overflow-hidden")}),exports.getWrapperClasses=s=>{let{styles:p,setting:o}=s,{align:r}=p??{},l=o?.positionWithImage==="outside",g=l?"gp-flex ":"gp-h-full",a=t.getAlignShape(r);return l&&a&&(g+=`${a} `),{...e.composeClasses(g)}};
