"use strict";var core=require("@gem-sdk/core"),productGallery=require("./productGallery.js"),productFeaturedImage=require("./productFeaturedImage.js");const DEVICES=["desktop","mobile","tablet"],getGalleryCarouselSettingAttr=o=>{let e=productGallery.getShapeByLayout({shape:o.shape,shapeForBottom:o.shapeForBottom,shapeFor1Col:o.shapeFor1Col,shapeFor2Col:o.shapeFor2Col,shapeForFtOnly:o.shapeForFtOnly,shapeForInsideBottom:o.shapeForInsideBottom,shapeForInside:o.shapeForInside},o.position),t=productGallery.getSliderPerShowConfig(e,o.position),r={desktop:"inside"===core.getResponsiveValueByScreen(o.navigationPosition,"desktop"),tablet:"inside"===core.getResponsiveValueByScreen(o.navigationPosition,"tablet"),mobile:"inside"===core.getResponsiveValueByScreen(o.navigationPosition,"mobile")},a=DEVICES.reduce((e,t)=>(o.navigationPosition?.[t]&&(e[t]="none"!==o.navigationPosition[t]),e),{});return{...o?.loop&&{loop:o.loop},itemNumber:t,dot:{desktop:!1,tablet:!1,mobile:!1},dotStyle:productGallery.getDotStyleConfig(),controlOverContent:r,...o?.dragToScroll&&{enableDrag:{desktop:o.dragToScroll,tablet:o.dragToScroll,mobile:o.dragToScroll}},vertical:productGallery.getCarouselVerticalConfigByPosition(o.position),...o?.arrowIcon&&{arrowCustom:o.arrowIcon},arrowIconSize:o.arrowIconSize||{desktop:24},...o?.arrowIconColor&&{arrowCustomColor:o.arrowIconColor},...o?.arrowNavColor&&{arrowBackgroundColor:o.arrowNavColor},...o?.arrowNavBorder&&{arrowBorder:{desktop:o.arrowNavBorder}},...o?.arrowNavRadius&&{roundedArrow:{desktop:o.arrowNavRadius}},...o?.arrowNavShadow&&{arrowShadow:{desktop:o.arrowNavShadow}},sneakPeakType:{desktop:"center"},arrowGapToEachSide:"16",navigationStyle:o.navigationPosition,navigationEnable:a,arrowButtonSize:{desktop:{width:void 0,height:void 0}},animationMode:o?.ftAnimationMode,enableAction:{desktop:!0}}},getFeaturedCarouselSettingAttr=o=>{let e={desktop:"inside"===core.getResponsiveValueByScreen(o.ftNavigationPosition,"desktop"),tablet:"inside"===core.getResponsiveValueByScreen(o.ftNavigationPosition,"tablet"),mobile:"inside"===core.getResponsiveValueByScreen(o.ftNavigationPosition,"mobile")},t=DEVICES.reduce((e,t)=>(o.ftNavigationPosition?.[t]&&(e[t]="none"!==o.ftNavigationPosition[t]),e),{});return{...o?.ftLoop&&{loop:o.ftLoop},itemNumber:{desktop:1},dot:productGallery.getAllowDotConfig(),dotStyle:productFeaturedImage.getDotStyleForOnlyFeaturedImage({position:o.position,dotStyle:o.ftDotStyle}),dotSize:o.ftDotSize??{desktop:12},dotGapToCarousel:o.ftDotGapToCarousel??{desktop:16},dotColor:o.ftDotColor??{desktop:"bg-1"},dotActiveColor:o.ftDotActiveColor??{desktop:"line-3"},controlOverContent:e,...o?.ftDragToScroll&&{enableDrag:{desktop:o.ftDragToScroll,tablet:o.ftDragToScroll,mobile:o.ftDragToScroll}},...o?.ftArrowIcon&&{arrowCustom:o.ftArrowIcon},arrowIconSize:o.ftArrowIconSize||{desktop:24},...o?.ftArrowIconColor&&{arrowCustomColor:o.ftArrowIconColor},...o?.ftArrowNavColor&&{arrowBackgroundColor:o.ftArrowNavColor},...o?.ftArrowNavBorder&&{arrowBorder:{desktop:o.ftArrowNavBorder}},...o?.ftArrowNavRadius&&{roundedArrow:{desktop:o.ftArrowNavRadius}},...o?.ftArrowNavShadow&&{arrowShadow:{desktop:o.ftArrowNavShadow}},sneakPeakType:{desktop:"center"},arrowGapToEachSide:"16",animationMode:o?.ftAnimationMode,...o?.ftNavigationPosition&&{navigationStyle:o.ftNavigationPosition},navigationEnable:t,arrowButtonSize:{desktop:{width:void 0,height:void 0}},enableAction:{desktop:!0}}};exports.getFeaturedCarouselSettingAttr=getFeaturedCarouselSettingAttr,exports.getGalleryCarouselSettingAttr=getGalleryCarouselSettingAttr;
