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