"use strict";var e=require("@gem-sdk/core"),t=require("@gem-sdk/system"),r=require("../../../common/helpers.js");exports.getStyle=(a,o)=>{let{style:s,contentType:n,parentStyle:d,parentSettings:i,background:l,customStyle:c}=a,k=e.makeGlobalSize(d?.itemPadding),u=e.DEVICES.reduce((t,r)=>{if("edit"===o)return{};let a=i?.rtl,s=e.getResponsiveValueByScreen(d?.spacing,r);return s?{...t,[`--${a?"ml":"mr"}${"desktop"!==r?`-${r}`:""}`]:s+"px"}:{...t}},{}),g={...c,...k&&k.padding,...r.getInitialWidthForCarouselItem({spacing:d?.spacing,slidesToShow:i?.itemNumber??i?.slidesToShow,sneakPeak:i?.sneakPeak,sneakPeakType:i?.sneakPeakType,sneakPeakOffsetCenter:i?.sneakPeakOffsetCenter,sneakPeakOffsetForward:i?.sneakPeakOffsetForward,vertical:i?.vertical}),...e.getStyleBackgroundByDevice(l),...e.getGradientBgrStyleByDevice(l,{desktop:!0,tablet:!0,mobile:!0})},S=t.createStyle({...e.getStyleShadow({value:d?.carouselShadow,styleAppliedFor:"box-shadow",isEnableShadow:d?.hasActiveShadow})}),m=t.createStyle({...g,...(["--radius"].forEach(e=>{delete s?.[e]}),"productImage"===n)?s:{...s,...e.makeStyle({bs:d?.borderContent?.border,bw:d?.borderContent?.width,bc:e.getSingleColorVariable(d?.borderContent?.color)}),...e.getRadiusStyleActiveState({...d?.roundedContent,active:{...d?.roundedContent||{},radiusType:"custom"}})},...u});return{carouselItemStyle:m,carouselItemInnerStyle:S}};
