1import{aE as e,i_ as t,i$ as i,E as a,F as r,V as n,k as o,j0 as s,ca as c,z as d,j1 as l,y as u,bS as m,az as p,a9 as g,aC as f,U as x}from"./index-Db6MqYYx.js";import{r as h}from"./vendor-Cqib3ghv.js";import{u as b,R as y}from"./RecommendSection-LOhaam8v.js";const v=e("section",{target:"efdn5l50"})(".layerProdSticky{position:fixed;left:0;width:100%;z-index:5000;.layerDim{display:none;}.prodStickyBox{position:relative;transform:translateY(100%);z-index:1000;}&.on{bottom:0;.layerDim{display:block;}.prodStickyBox{transform:translateY(0);transition:all 0.3s linear;.btnStickyCtl{width:69px;height:22px;background-size:cover;background-image:url(",t,");}}}.btnStickyCtl{display:block;font-size:0;margin:0 auto;text-align:center;width:69px;height:22px;background-size:cover;background-image:url(",i,");}.cartInfoBox{position:relative;overflow:hidden;padding:20px 16px 16px;background:#f6f6f6;border-radius:10px 10px 0 0;border-bottom:1px solid #eee;}.cartInfoBoxInner{display:flex;align-items:center;justify-content:space-between;gap:10px;}.addMessageText{font-size:14px;font-weight:500;line-height:19px;letter-spacing:-0.14px;white-space:pre-line;word-break:keep-all;color:#222;.highlight{color:#df0011;}.subMsg{font-size:12px;color:#888;}}.cartLink{display:inline-block;font-size:12px;font-weight:500;line-height:28px;padding:0 10px;color:#222;border:1px solid #ddd;border-radius:3px;background:#fff;white-space:nowrap;}.recommendItemLayerRecommendBox{background-color:#f6f6f6;padding:30px 0;.recommend-title{strong{display:block;margin-bottom:20px;padding:0px 20px;font-size:18px;font-weight:bold;line-height:1.2;letter-spacing:-0.9px;color:rgb(34, 34, 34);}}.unitItemWrap{&:not(.scroll){.priceQtyWrap{text-overflow:ellipsis;overflow:hidden;white-space:nowrap;}}}}}"),k=({itemNo:e,storeId:t})=>{var i;const{addCartSuccess:k,cartAddMsg:S,cartAddSubMsg:w,isLogin:T}=a(({itemDetail:e,auth:t})=>({addCartSuccess:e.addCartSuccess,cartAddMsg:e.cartAddMsg,cartAddSubMsg:e.cartAddSubMsg,isLogin:t.isLogin}),r),C=n().app,I=o(),M=h.useRef(null),N=h.useRef(null),z=h.useRef(null),{toCart:L}=s("mart"),A=h.useCallback(()=>{N.current&&clearTimeout(N.current),z.current&&clearTimeout(z.current),I.itemDetail.setRecommendLayerOpen({addCartSuccess:!1,cartAddMsg:"",cartAddSubMsg:""}),N.current=setTimeout(()=>{(null==M?void 0:M.current)&&(M.current.style.bottom="0"),z.current=setTimeout(()=>{(null==M?void 0:M.current)&&(M.current.style.bottom="auto")},100)},300)},[I.itemDetail]);h.useEffect(()=>()=>{N.current&&clearTimeout(N.current),z.current&&clearTimeout(z.current)},[]),h.useEffect(()=>{A();const e=()=>{C&&"visible"===document.visibilityState&&A()};return document.addEventListener("visibilitychange",e),()=>{document.removeEventListener("visibilitychange",e)}},[C,e]),h.useEffect(()=>{if(k)return document.body.style.cssText="touch-action: none;overflow:hidden",()=>{document.body.style.cssText=""};document.body.style.cssText=""},[k]);const B={storeId:t,itemNo:e,pageCode:"PD"},D=!!k&&!!t&&!!e,{data:R,isFetched:E}=b(B,D);if(h.useEffect(()=>{k&&E&&((null==R?void 0:R.itemDetailInfos)||(I.itemDetail.setRecommendLayerOpen({addCartSuccess:!1,cartAddMsg:"",cartAddSubMsg:""}),c(S?S+(w&&"<br/>".concat(w)):f.T001+(T?"":f.T045))))},[k,E,R]),!E||!(null==R?void 0:R.itemDetailInfos))return null;return d(v,{children:d(l,{className:"floatingBtnBox",children:u("div",{className:"layerProdSticky ".concat(k?"on":""),style:{bottom:k?"0":"auto"},ref:M,children:[d(m,{zIndex:1e3,onClick:A}),u("div",{className:"prodStickyBox",children:[d("button",{type:"button",className:"btnStickyCtl",onClick:A,children:d("span",{css:p,children:k?"ë«ê¸°":"ì´ê¸°"})}),d("div",{className:"cartInfoBox",children:u("div",{className:"cartInfoBoxInner",children:[d("div",{className:"addMessageText",children:S?u(x,{children:[d("p",{children:S.split(/(\d+ê°)/g).map((e,t)=>/\d+ê°/.test(e)?d("span",{className:"highlight",children:e},t):e)}),w&&d("p",{className:"subMsg",children:w})]}):d("p",{children:f.T001+(T?"":f.T045)})}),d(g,{to:"",unusedAppScheme:!0,onClick:e=>{e.preventDefault(),A(),L()},className:"cartLink",children:"ë°ë¡ê°ê¸°"})]})}),d("div",{className:"recommendItemLayerRecommendBox",children:d(y,{dataList:null==(i=null==R?void 0:R.itemDetailInfos)?void 0:i.map((e,t)=>({...e,recommendCode:"TTS01",groupIndex:t,itemSection:"ì´ë°ìíìì´ëì?"})),title:"ì´ë° ìíì ì´ëì?",itemSection:"ì´ë°ìíìì´ëì?"})})]})]})})})};export{k as default};
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.