1(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[3369],{3369:(e,o,l)=>{"use strict";l.r(o),l.d(o,{default:()=>f});var n=l(85893),t=l(67294),s=l(49380),i=l(74939),a=l(96431),c=l(81917),r=l.n(c),d=l(70819),_=l(22100),p=l(43948),u=l(9130),m=l(11163),C=l(94172),h=l(3262),D=l(2493),w=l(80152),N=l(67748),v=l(85923),x=l(97029),g=l(25141);let j=e=>{var o,l;let{list:i,position:a,recircLabel:c,currentListId:d,collectionId:_,isBottomCollection:p=!1}=e,{trackListRecirc:j}=(0,w.Z)(),[b,f]=(0,u.YD)({triggerOnce:!0,rootMargin:N.aw}),k=(0,m.useRouter)(),{listId:T,labelD:I}=i,y=v.x.includes(null==k?void 0:null===(o=k.query)||void 0===o?void 0:o.ref)&&(null==k?void 0:null===(l=k.query)||void 0===l?void 0:l.l)?parseInt(k.query.l,10):null,O=(0,g.S5)(i.relUrl,c,d,_,y),B=(0,x.Z)(O),L=(0,t.useMemo)(()=>({componentName:c,type:D._T,typeId:T,typeUrl:B,collectionId:_,childPosition:a}),[a,B,_,T,c]),P=(0,t.useCallback)(e=>{e.preventDefault(),j({eventType:s.PW,...L}),p&&(0,h.ZP)("bottom_collection_clicked",{collectionId:_},{destinations:h.B0,isImmediate:!0}),(0,C.Z)(B)},[_,p,B,L,j]);return(0,t.useEffect)(()=>{f&&j({eventType:s.R6,...L})},[f]),(0,n.jsx)("li",{ref:b,children:(0,n.jsx)("a",{href:B,className:r().itemLink,onClick:e=>{P(e)},children:I})})},b=[{useTrackedState:_.oP,mapStateToProps:e=>{let{pageData:{collection:o},listData:{id:l}}=e;return{collection:o,currentListId:l}}}],f=(0,p.Z)({mapStateToProps:b})(e=>{let{collection:o,isBottomCollection:l=!1,currentListId:c}=e,[_,p]=(0,t.useState)(!1);if(!o)return null;let{collection:{id:u,lists:m,nameD:C,descriptionD:h}}=o;if(!m)return null;let D=l?s._p.COLLECTIONS_BOTTOM_DROPDOWN:s._p.COLLECTIONS_TOP_DROPDOWN;return(0,n.jsxs)(n.Fragment,{children:[(0,n.jsx)(a.default,{className:r().outerContainer,children:(0,n.jsxs)("button",{type:"button",className:r().dropdownButton,onClick:()=>{p(!0),(0,i.Q)()},children:[(0,n.jsxs)("div",{className:r().lengthTag,children:[m.length,(0,n.jsx)(d.default,{iconId:"rsvg__listType--collection",className:r().icon})]}),(0,n.jsx)("span",{className:r().name,children:l?"Choose a list":C}),(0,n.jsx)(d.default,{iconId:"rsvg__ui--roundedTriangle",className:r().chevron})]})}),_?(0,n.jsxs)("div",{className:r().dropdownModal,children:[(0,n.jsxs)("div",{className:r().modalHead,children:[(0,n.jsx)("button",{type:"button",onClick:()=>{p(!1),(0,i.t)()},className:r().closeButton,"aria-label":"Close collections dropdown",children:(0,n.jsx)(d.default,{iconId:"rsvg__ui--close",className:r().closeIcon})}),(0,n.jsx)("div",{className:r().modalName,children:C}),(0,n.jsx)("div",{className:r().description,children:h})]}),(0,n.jsx)("div",{className:r().scrollableWrapper,children:(0,n.jsx)("ul",{className:r().items,children:m.map((e,o)=>(0,n.jsx)(j,{list:e,position:o+1,recircLabel:D,collectionId:u,currentListId:c,isBottomCollection:l},e.listId))})})]}):null]})})},81917:e=>{e.exports={outerContainer:"CollectionsDropdown_outerContainer__dLQcl",dropdownButton:"CollectionsDropdown_dropdownButton__XQYca",lengthTag:"CollectionsDropdown_lengthTag__VkcZ9",icon:"CollectionsDropdown_icon__a_23b",name:"CollectionsDropdown_name__Am_o1",chevron:"CollectionsDropdown_chevron__RuZGA",dropdownModal:"CollectionsDropdown_dropdownModal__YkcZv",modalHead:"CollectionsDropdown_modalHead___ACy1",closeButton:"CollectionsDropdown_closeButton__81PqW",closeIcon:"CollectionsDropdown_closeIcon__GFSxp",modalName:"CollectionsDropdown_modalName__XQBmn",description:"CollectionsDropdown_description__OgJlx",scrollableWrapper:"CollectionsDropdown_scrollableWrapper__y8lpo",items:"CollectionsDropdown_items__eaVKx",itemLink:"CollectionsDropdown_itemLink__gDo_q"}}}]); 2//# sourceMappingURL=3369.bb26c72ebbed0a29.js.map
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.