"use strict";var React=require("react"),helper=require("../../common/helper.js");const useProductImagePostPurchase=e=>{let{imageList:t,setting:r}=e,{layoutType:c="bottom-center",spacingVertical:o,spacingHoz:s,ratioLayoutLeft:u,ratioLayoutRight:n,displayType:a}=r||{},l=React.useMemo(()=>t.length>1,[t.length]),m=React.useMemo(()=>"bottom-center"===c?helper.postPurchaseSpacing[o||"none"]:s,[c,s,o]),i=React.useMemo(()=>{let e={"--gtc":"minmax(0, 12fr)"};if(!l)return e;let t="left"===c?u:n,r=["left","right"].includes(c);return r&&t?{"--gtc":`minmax(0, ${t[0]}fr) minmax(0, ${t[1]}fr)`,"--gtr":"fit-content(0)"}:e},[l,c,u,n]),g=React.useMemo(()=>!["two-col","one-col"].includes(c)&&(["left","right"].includes(c)||"slider"===a),[c,a]);return{itemGap:m,gridLayout:i,isShowGalleryImages:l,isImageListCarousel:g}};exports.useProductImagePostPurchase=useProductImagePostPurchase;
