1try{!function(){var e="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:{},t=(new e.Error).stack;t&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[t]="4c452bdb-5bfa-43a8-89ee-ad8c1151a860",e._sentryDebugIdIdentifier="sentry-dbid-4c452bdb-5bfa-43a8-89ee-ad8c1151a860")}()}catch(e){}"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[8482,5116,3163],{78482:function(e,t,i){i.d(t,{t:function(){return _}});var n=i(69087),l=i(72947),r=i(47465),o=i(10909),a=i(89195),d=i(77728),u=i(68937),s=i(77363),c=i(31818),p=i(31877),f=i(99198),v=i(91757),g=i(85333),h=i(44964),m=i(23329),y=i(98409),b=i(94459),w=i(38117);let x=(e,t,i,n)=>({id:String(e.id),href:e.full_url,pollKey:e.key,title:e.title,options:e.options.map(e=>({id:String(e.id),text:e.name,voteCount:e.votes_count,votePercentage:e.votes_percentage})),totalVotes:e.total_voters,endAt:e.end_at,voteUrl:window.location.href,selectedOptionId:e.voted?String(e.voted.option_id):void 0,hasVoted:!!e.voted,isExpired:1e3*e.end_at<Date.now(),publisher:t,slug:e.slug,startAt:e.start_at,createdBy:e.created_by,pageName:n,screenName:i}),S=(0,r.Z)("div",{target:"erankhe0"})("display:grid;grid-template-columns:1fr;gap:1.25rem;width:100%;@media (min-width:768px){grid-template-columns:repeat(",e=>{let{columns:t}=e;return t||3},",1fr);}"),_=e=>{var t,i,r;let{title:_,type:Z,slug:k,publisher:C,skeletonCount:L=3,sectionIndex:F=0,loadMoreMode:T=!1,gridColumns:I,apiUrl:D,seeMoreUrl:P,pageName:$="",screenName:O}=e,{isMobile:W}=(0,v.F)(),M=(0,l.u)(),j=(0,m.useRef)(null),z=(0,m.useId)(),B=_?`section-title-${z}`:void 0,[X,K]=(0,m.useState)(1),[E,q]=(0,m.useState)([]),[A,R]=(0,m.useState)(1),[V,N]=(0,m.useState)(0),[H,Y]=(0,m.useState)(!1),{data:U,isLoading:J}=(0,h.a)({queryKey:["/api/poll/trending",C,k,F],queryFn:()=>g.Z.getTrendingPolling({publisher:C}),refetchOnWindowFocus:!1,enabled:"trending-poll"===k&&!D}),{data:Q,isLoading:G}=(0,h.a)({queryKey:["/api/poll/latest",C,k,F,X],queryFn:()=>g.Z.getLatestPolling({publisher:C,page:X,limit:20}),refetchOnWindowFocus:!1,enabled:"latest-poll"===k&&!T&&!D}),{isLoading:ee}=(0,h.a)({queryKey:["/api/poll/latest/load-more-init",C,k,F],queryFn:async()=>{let e=await g.Z.getLatestPolling({publisher:C,page:1,limit:20});if(null==e?void 0:e.data){var t,i,n;q(null!==(i=e.data.data)&&void 0!==i?i:[]),N(null!==(n=null===(t=e.data.meta)||void 0===t?void 0:t.total_page)&&void 0!==n?n:0),R(1)}return e},refetchOnWindowFocus:!1,enabled:"latest-poll"===k&&T&&!D}),{data:et,isLoading:ei}=(0,h.a)({queryKey:["poll-section-api-url",D,F],queryFn:async()=>{var e,t;let i=new URL(D,window.location.origin),n=Number(i.searchParams.get("page"))||1,l=Number(i.searchParams.get("limit"))||4,r=await g.Z.getLatestPolling({publisher:C,page:n,limit:l});return null!==(t=null==r?void 0:null===(e=r.data)||void 0===e?void 0:e.data)&&void 0!==t?t:[]},refetchOnWindowFocus:!1,enabled:!!D}),en=D?ei:"trending-poll"===k?J:T?ee:G,el=(0,m.useMemo)(()=>{var e,t,i;return D?null!=et?et:[]:"trending-poll"===k?null!==(t=null==U?void 0:U.data)&&void 0!==t?t:[]:T?E:null!==(i=null==Q?void 0:null===(e=Q.data)||void 0===e?void 0:e.data)&&void 0!==i?i:[]},[k,U,Q,T,E,D,et]),er=(0,m.useMemo)(()=>{var e,t,i;return D||"latest-poll"!==k?0:T?V:null!==(i=null==Q?void 0:null===(t=Q.data)||void 0===t?void 0:null===(e=t.meta)||void 0===e?void 0:e.total_page)&&void 0!==i?i:0},[k,Q,T,V,D]),eo=(0,m.useCallback)(async()=>{if(!H&&!(A>=V)){Y(!0);try{var e,t,i;let n=A+1,l=await g.Z.getLatestPolling({publisher:C,page:n,limit:20});(null==l?void 0:null===(e=l.data)||void 0===e?void 0:e.data)&&(q(e=>[...e,...l.data.data]),R(n),N(null!==(i=null===(t=l.data.meta)||void 0===t?void 0:t.total_page)&&void 0!==i?i:V))}catch{}finally{Y(!1)}}},[H,A,V,C]);if(en){let e=Array.from({length:L},(e,t)=>t);return(0,n.BX)(o.x,{width:"full",boxSizing:"border-box",children:[(0,n.tZ)(c.O,{width:"48",height:"6",borderRadius:"md"}),(0,n.tZ)(o.x,{marginTop:"4",padding:"2",children:"carousel"===Z?(0,n.tZ)(a.Carousel,{itemsToShow:W?1.3:4.2,itemSpacing:"4",arrow:!W,dots:W,children:e.map(e=>(0,n.tZ)(o.x,{children:(0,n.tZ)(b.I,{})},e))}):(0,n.tZ)(S,{columns:I,children:e.map(e=>(0,n.tZ)(b.I,{},e))})})]})}if(!el.length)return null;let ea=null!=O?O:"undefined"!=typeof document?document.title:_,ed=el.map(e=>x(e,C,ea,$));return(0,n.BX)(o.x,{width:"full",ref:j,gap:"4",as:_?"section":"div","aria-labelledby":B,children:[(0,n.BX)(u.k,{alignItems:"center",marginBottom:"4",justifyContent:"space-between",children:[(0,n.tZ)(u.k,{dataCy:"ds-title",gap:"2",children:(0,n.tZ)(e=>{var t,i,r;let{title:o,prefix:a,suffix:d,as:s,titleId:c}=e,v=(0,l.u)();return(0,n.BX)(u.k,{gap:"2",children:[a&&(0,n.tZ)(f.p,{icon:a.icon,size:a.size,id:`prefix-icon-${o}`,dataTestId:`prefix-icon-${o}`}),(0,n.tZ)(p.x,{as:s,fontSize:{sm:"md",md:"2xl"}
1,color:null===(t=v.sectionTitle)||void 0===t?void 0:t.title.color,fontFamily:null===(i=v.sectionTitle)||void 0===i?void 0:i.title.fontFamily,fontWeight:null===(r=v.sectionTitle)||void 0===r?void 0:r.title.fontWeight,id:c,children:o}),d&&(0,n.tZ)(f.p,{icon:d.icon,size:d.size,id:`suffix-icon-${o}`,dataTestId:`suffix-icon-${o}`})]})},{titleId:B,title:_,as:"h2"})}),P&&(0,n.tZ)(d.x,{href:P,passHref:!0,children:(0,n.tZ)(p.x,{dataCy:"ds-seemore",fontSize:"xs",color:null===(t=M.sectionTitle)||void 0===t?void 0:t.seeMoreLabel.color,fontFamily:null===(i=M.sectionTitle)||void 0===i?void 0:i.seeMoreLabel.fontFamily,fontWeight:null===(r=M.sectionTitle)||void 0===r?void 0:r.seeMoreLabel.fontWeight,children:"See More"})})]}),"carousel"===Z?(0,n.tZ)(a.Carousel,{itemsToShow:W?1.3:4.2,itemSpacing:"1",arrow:!W,dots:W,children:ed.map(e=>(0,n.tZ)(o.x,{padding:"2",children:(0,n.tZ)(w.F,{...e})},e.id))}):(0,n.BX)(n.HY,{children:[(0,n.tZ)(S,{columns:I,children:ed.map(e=>(0,n.tZ)(w.F,{...e},e.id))}),T?A<er&&(0,n.tZ)(u.k,{justifyContent:"center",marginTop:"6",children:(0,n.tZ)(o.x,{width:"full",children:(0,n.tZ)(y.a,{isLoading:H,onClick:eo,children:"Load More"})})}):er>1&&(0,n.tZ)(u.k,{justifyContent:"center",marginTop:"6",children:(0,n.tZ)(s.t,{currentPage:X,totalPages:er,onPageChange:e=>{if(K(e),j.current){let e=j.current.getBoundingClientRect().top+window.scrollY-80;window.scrollTo({top:e,behavior:"smooth"})}}})})]})]})}},38117:function(e,t,i){i.d(t,{F:function(){return E}});var n=i(69087),l=i(72947),r=i(47465),o=i(10909),a=i(77728),d=i(68937),u=i(31877),s=i(61378),c=i(35116),p=i(8512),f=i(33168),v=i(91757),g=i(72222),h=i(93419),m=i(48762),y=i(14512),b=i(38108),w=i(85333),x=i(53362),S=i(82268),_=i(47336),Z=i(44964),k=i(73570),C=i(23329),L=i(63642);let F=["Arka","Bima","Citra","Daffa","Elya","Fahri","Gia","Hana","Irfan","Jasmine"],T=e=>{let t=e.split(/[\s']/)[0];return t.length<=1?t:t[0].toUpperCase()+"*".repeat(t.length-1)},I=(e,t)=>t>=3&&e.length>=3?e.slice(0,3).map(e=>e.name_masked?e.name_masked:T(e.name)):[...F].sort(()=>Math.random()-.5).slice(0,3).map(T),D=(0,r.Z)("div",{target:"e1db8ujj0"})("position:relative;width:100%;height:0;overflow:visible;"),P=(0,r.Z)(o.x,{target:"e1db8ujj1"})("position:absolute;top:80%;left:-2%;width:104%;z-index:10;pointer-events:none;"),$=(0,r.Z)("div",{target:"e1db8ujj2"})("z-index:999;position:absolute;display:inline-flex;align-items:center;justify-content:center;padding:0.375rem 0.75rem;border-radius:1rem;background-color:",e=>{let{bgColor:t}=e;return t},";white-space:nowrap;transition:all ",400,"ms ease;",e=>{let{animState:t,isOlder:i}=e;switch(t){case"enter-left":return` 2 top: 0; 3 left: 0; 4 transform: translateX(-110%); 5 opacity: 0; 6 `;case"visible":return` 7 top: 0; 8 left: 0; 9 transform: translateX(0); 10 opacity: ${i?.4:1}; 11 `;case"shift-up":return` 12 top: -1.75rem; 13 left: 0; 14 transform: translateX(0); 15 opacity: 0.4; 16 `;case"exit-up":return` 17 top: -3.5rem; 18 left: 0; 19 transform: translateX(0); 20 opacity: 0; 21 `;default:return""}}),O=e=>{var t,i;let{voters:r,totalVoters:o}=e,a=(0,l.u)(),[d,c]=(0,C.useState)([]),p=(0,C.useRef)(0),f=(0,C.useRef)(0),v=(0,C.useRef)(null),g=(0,C.useRef)(null),[h,m]=(0,C.useState)(!1),y=(0,C.useMemo)(()=>I(r,o),[r.length,o]),b=s.O9[null===(t=a.color)||void 0===t?void 0:t.secondary]||s.O9[null===(i=a.brand)||void 0===i?void 0:i.color]||"#e0e0e0";return((0,C.useEffect)(()=>{let e=g.current;if(!e)return;let t=new IntersectionObserver(e=>{let[t]=e;m(t.isIntersecting)},{threshold:.1});return t.observe(e),()=>t.disconnect()},[]),(0,C.useEffect)(()=>{h||(v.current&&(clearTimeout(v.current),v.current=null),c([]))},[h]),(0,C.useEffect)(()=>{if(!h||0===y.length)return;p.current=0,f.current=0,c([]);let e=Math.min(y.length,3),t=()=>{if(p.current>=e)return null;let t=y[p.current];return p.current++,t},i=()=>{let n=t();if(!n)return;let l=++f.current;c(e=>[...e.map(e=>({...e,animState:"shift-up"})),{name:n,id:l,animState:"enter-left"}]),requestAnimationFrame(()=>{requestAnimationFrame(()=>{c(e=>e.map(e=>e.id===l?{...e,animState:"visible"}:e))})}),setTimeout(()=>{c(e=>{if(e.length<=1)return e;let[t,...i]=e;return[{...t,animState:"exit-up"},...i]})},400),setTimeout(()=>{c(e=>e.filter(e=>"exit-up"!==e.animState))},800),p.current<e?v.current=setTimeout(i,2400):v.current=setTimeout(()=>{c(e=>e.map(e=>({...e,animState:"exit-up"}))),setTimeout(()=>{c([])},400)},2e3)},n=t();if(!n)return;let l=++f.current;return c([{name:n,id:l,animState:"enter-left"}]),requestAnimationFrame(()=>{requestAnimationFrame(()=>{c(e=>e.map(e=>e.id===l?{...e,animState:"visible"}:e))})}),p.current<e?v.current=setTimeout(i,2e3):v.current=setTimeout(()=>{c(e=>e.map(e=>({...e,animState:"exit-up"}))),setTimeout(()=>{c([])},400)},2e3),()=>{v.current&&clearTimeout(v.current)}},[h,y,b]),0===y.length)?null:(0,n.tZ)(P,{ref:g,children:(0,n.tZ)(D,{"data-cy":"polling-toast-container",children:d.map((e,t)=>{var i;return(0,n.tZ)($,{bgColor:b,animState:e.animState,isOlder:d.length>1&&0===t,"data-cy":`polling-toast-${e.id}`,children:(0,n.BX)(u.x,{fontSize:"xs",fontWeight:"semibold",color:"greyscale0",fontFamily:null===(i=a.articleListCard)||void 0===i?void 0:i.category.fontFamily,children:[e.name," has voted"]})},e.id)})})})},W=e=>
21e.toLocaleString("id-ID"),M=e=>{let t=1e3*e-Date.now();if(t<=0)return"Ended";let i=Math.floor(t/864e5),n=Math.floor(t%864e5/36e5);return i>0?`${i} Days Left`:n>0?`${n} Hours Left`:"Less than 1 hour"},j=e=>({options:e.options.map(e=>({id:String(e.id),text:e.name,voteCount:e.votes_count,votePercentage:e.votes_percentage})),totalVotes:e.total_voters,endAt:e.end_at,selectedOptionId:e.voted?String(e.voted.option_id):void 0}),z=(0,r.Z)(o.x,{target:"e1j29myr0"})("border-color:transparent;transition:border-color 0.2s ease;&:hover{border-color:",e=>{let{hoverBorderColor:t}=e;return t},";}"),B=(0,r.Z)("div",{target:"e1j29myr1"})("position:relative;width:100%;border-radius:20px;overflow:hidden;min-height:2.5rem;display:flex;align-items:center;border:1px solid ",e=>{let{brandColor:t}=e;return t},";transition:opacity 0.2s ease,border-color 0.2s ease;opacity:",e=>{let{isDisabled:t,showResult:i}=e;return t&&!i?.55:1},";pointer-events:",e=>{let{isDisabled:t,showResult:i}=e;return t&&!i?"none":"auto"},";&:hover{background:",e=>{let{hoverColor:t}=e;return t},";",e=>{let{showResult:t,hoverColor:i}=e;return!t&&`border: 1px solid ${i};`},"}"),X=(0,r.Z)("div",{target:"e1j29myr2"})("position:absolute;top:0;left:0;height:100%;width:",e=>{let{percentage:t}=e;return t},"%;background-color:",e=>{let{fillColor:t}=e;return t},";border-radius:0px;transition:width 1s cubic-bezier(0.25,0.46,0.45,0.94);will-change:width;"),K=(0,r.Z)(d.k,{target:"e1j29myr3"})("position:relative;z-index:1;display:flex;align-items:center;width:100%;padding:0.5rem 1rem;min-width:0;overflow:hidden;word-break:break-word;"),E=e=>{var t,r,F,T,I,D,P,$,E,q,A,R,V,N,H,Y,U,J,Q,G,ee,et,ei;let{id:en,title:el,options:er,totalVotes:eo,endAt:ea,voteUrl:ed,selectedOptionId:eu,hasVoted:es=!1,isExpired:ec=!1,pollKey:ep,publisher:ef,titleSection:ev=!1,isDisabled:eg=!1,href:eh,seeMoreHref:em,slug:ey,startAt:eb,createdBy:ew,pageName:ex,screenName:eS}=e,e_=(0,k.usePathname)(),[eZ]=(0,C.useState)(e_.endsWith("/preview")),ek=(0,l.u)(),{isLogin:eC}=(0,f.a)(),{isMobile:eL}=(0,v.F)(),eF=(0,S.NL)(),{handleArticleClick:eT}=(0,c.u)(),[eI,eD]=(0,C.useState)(es),[eP,e$]=(0,C.useState)(ec),[eO,eW]=(0,C.useState)(eh),[eM,ej]=(0,C.useState)(er),[ez,eB]=(0,C.useState)(eo),[eX,eK]=(0,C.useState)(ea),[eE,eq]=(0,C.useState)(eu),[eA,eR]=(0,C.useState)([]),eV=eI||eP,[eN,eH]=(0,C.useState)(eV),[eY,eU]=(0,C.useState)(eV),eJ=(0,C.useRef)(eV),[eQ,eG]=(0,C.useState)(null),[e0,e1]=(0,C.useState)(!1),[e3,e2]=(0,C.useState)(null),[e4,e8]=(0,C.useState)(!1),e9=(0,p.V)();(0,C.useEffect)(()=>{if(!(null==er?void 0:er.length))return;ej(er),eB(eo),eK(ea),eq(eu);let e=!!ea&&1e3*ea<Date.now();e$(e),es&&(eD(!0),eJ.current=!0,eU(!0),eH(!0)),e&&(eJ.current=!0,eU(!0),eH(!0))},[es,ec,eu,eo,ea]),(0,C.useEffect)(()=>{if(eN&&!eY){if(eJ.current){eU(!0);return}let e=setTimeout(()=>{eU(!0),eJ.current=!0},50);return()=>clearTimeout(e)}},[eN,eY]);let{mutate:e5,isPending:e7}=(0,_.D)({mutationKey:[`/vote/${ep}/poll`],mutationFn:async e=>{let{data:t}=await w.Z.PostPoll({body:{option_id:parseInt(e),publisher:ef,vote_url:ed},key:ep});return t},onSuccess:e=>{if(e){let t=j(e);ej(t.options),eB(t.totalVotes),eK(t.endAt),t.selectedOptionId&&eq(t.selectedOptionId),eH(!0),eF.invalidateQueries({queryKey:["/api/poll/trending"]}),eF.invalidateQueries({queryKey:["/api/poll/latest"]})}},onError:async()=>{eq(void 0),eH(!1),eU(!1),eJ.current=!1;let{PollingReloadModal:e}=await i.e(8968).then(i.bind(i,78968));e2(()=>e),e8(!0)}}),e6=!eI&&!eP&&!eN&&!e7,te=async e=>{if(e6){if((async()=>{try{let t=await (0,g.M)();if(!t)return;let i="";try{let e=localStorage.getItem("userData");if(e){let t=JSON.parse(e);i=(null==t?void 0:t.uuid)||""}}catch{}let n=(0,b.Yo)({pollKey:ep,optionId:e,isLogin:eC,currentUrl:window.location.href,fingerprintId:t,userId:i});n&&x.Z.postTracker({pollKey:n.pollKey,optionId:n.optionId,isLogin:n.isLogin,currentUrl:n.currentUrl,clickedAt:n.clickAt,fingerprintId:n.fingerprintId,userId:n.userId})}catch{}})(),!eC){let{PollingLoginModal:e}=await i.e(4016).then(i.bind(i,34016));eG(()=>e),e1(!0);return}eq(e),e5(e)}},tt=e=>{var t;return e===eE&&(null===(t=ek.color)||void 0===t?void 0:t.primaryLight)||"greyscale20"},{data:ti,isPending:tn}=(0,Z.a)({queryKey:[`/poll/${ep}/public`,ep],queryFn:async()=>await w.Z.getDetailPolling({key:ep,publisher:e9.publisher||"idntimes"}),enabled:!!ep&&!(null==er?void 0:er.length)});(0,C.useEffect)(()=>{var e;if(!(null==ti?void 0:ti.data))return;let{options:t,end_at:i,total_voters:n,voters:l,voted:r,url:o}=ti.data,a=1e3*i<Date.now();ej(t.map(e=>({id:e.id,text:e.name,voteCount:e.votes_count,votePercentage:e.votes_percentage}
21))),eq(null===(e=ti.data.voted)||void 0===e?void 0:e.option_id),eK(i),eB(n),e$(a),eh||eW(o),l&&eR(l),r&&eD(!0),(r||a)&&eH(!0)},[ti]);let tl=null==ti?void 0:ti.data,tr=(0,C.useMemo)(()=>{var e;let t=null!==(e=null!=ey?ey:null==tl?void 0:tl.slug)&&void 0!==e?e:"",i=null!=eb?eb:null==tl?void 0:tl.start_at,n=null!=ew?ew:(null==tl?void 0:tl.author)?{id:tl.author.uuid,name:tl.author.name,key:tl.author.key}:void 0;return{event:"click_article",property:ef,platform:"web",device:eL?"mobile":"desktop",page_type:ex||"",page_type_var:"",screen_name:eS||("undefined"!=typeof document?document.title:el),content_type:"poll",content_type_var:(0,h.T)(),content_title:el,content_id:ep,content_slug:t,content_publisher:ef,content_tag:"",content_published_date:i&&(0,m.$4)(i,"YYYY-MM-DD HH:mm:ss")||"",content_updated_date:"",content_category:"",content_category_id:"",content_subcategory:"",content_subcategory_id:"",content_creator_id:(null==n?void 0:n.id)||"",content_creator_username:n?`${(0,y.Uu)(n.name)}-${n.key}`:"",content_creator_fullname:(null==n?void 0:n.name)||"",content_creator_role:n?"writer":""}},[ef,eL,ex,eS,el,ep,ey,eb,ew,tl]),to=e=>{eT(tr,e,{tier:"free",articleKey:ep,publisher:ef,href:eO})};return tn&&ep&&!(null==er?void 0:er.length)?(0,n.tZ)(L.I,{}):(0,n.BX)(C.Fragment,{children:[ev&&(0,n.tZ)(o.x,{children:(0,n.tZ)(u.x,{as:"h2",color:"greyscale70",fontFamily:null===(t=ek.articleListCard)||void 0===t?void 0:t.title.fontFamily,fontWeight:null===(r=ek.articleListCard)||void 0===r?void 0:r.title.fontWeight,fontSize:"lg",children:null==ti?void 0:null===(F=ti.data)||void 0===F?void 0:F.subtitle})}),(0,n.BX)(z,{width:"full",borderRadius:"xl",padding:"4",boxShadow:"3xl",boxSizing:"border-box",dataCy:`polling-card-${en}`,border:"1",hoverBorderColor:(null===(T=ek.brand)||void 0===T?void 0:T.color)?s.O9[ek.brand.color]:"transparent",children:[(0,n.tZ)("div",{id:en,style:{display:"block",position:"relative",top:"-120px",visibility:"hidden"}}),(0,n.BX)(d.k,{direction:"column",gap:"3",width:"full",children:[eO?(0,n.BX)(d.k,{alignItems:"center",justifyContent:"space-between",width:"full",gap:"2",children:[(0,n.tZ)(a.x,{href:eO,passHref:!0,onClick:to,children:(0,n.tZ)(u.x,{as:"h3",fontFamily:null===(I=ek.articleListCard)||void 0===I?void 0:I.title.fontFamily,fontWeight:null===(D=ek.articleListCard)||void 0===D?void 0:D.title.fontWeight,color:null===(P=ek.articleListCard)||void 0===P?void 0:P.title.color,fontSize:"md",letterSpacing:"wide",dataCy:"polling-title",children:el})}),em&&(0,n.tZ)(a.x,{href:em,passHref:!0,children:(0,n.tZ)(u.x,{dataCy:"ds-seemore",fontSize:"xs",color:null===($=ek.sectionTitle)||void 0===$?void 0:$.seeMoreLabel.color,fontFamily:null===(E=ek.sectionTitle)||void 0===E?void 0:E.seeMoreLabel.fontFamily,fontWeight:null===(q=ek.sectionTitle)||void 0===q?void 0:q.seeMoreLabel.fontWeight,whiteSpace:"nowrap",children:"See More"})})]}):(0,n.BX)(d.k,{alignItems:"center",justifyContent:"space-between",width:"full",children:[(0,n.tZ)(o.x,{cursor:"pointer",onClick:()=>to(),children:(0,n.tZ)(u.x,{as:"h3",fontFamily:null===(A=ek.articleListCard)||void 0===A?void 0:A.title.fontFamily,fontWeight:null===(R=ek.articleListCard)||void 0===R?void 0:R.title.fontWeight,color:null===(V=ek.articleListCard)||void 0===V?void 0:V.title.color,fontSize:"md",letterSpacing:"wide",dataCy:"polling-title",children:el})}),em&&(0,n.tZ)(a.x,{href:em,passHref:!0,children:(0,n.tZ)(u.x,{dataCy:"ds-seemore",fontSize:"xs",color:null===(N=ek.sectionTitle)||void 0===N?void 0:N.seeMoreLabel.color,fontFamily:null===(H=ek.sectionTitle)||void 0===H?void 0:H.seeMoreLabel.fontFamily,fontWeight:null===(Y=ek.sectionTitle)||void 0===Y?void 0:Y.seeMoreLabel.fontWeight,children:"See More"})})]}),(0,n.tZ)(d.k,{direction:"column",gap:"2",boxSizing:"border-box",width:"full",children:null==eM?void 0:eM.map((e,t)=>{var i,l,r,a,c,p;let f=e.votePercentage,v=tt(e.id),g=0===t&&!!ep&&!(null==er?void 0:er.length),h=(0,n.BX)(B,{brandColor:eN&&e.id===eE?s.O9[null===(i=ek.brand)||void 0===i?void 0:i.color]:eN&&e.id!==eE?s.O9.greyscale80:s.O9[null===(l=ek.brand)||void 0===l?void 0:l.color],showResult:eN,isDisabled:e7||eP,onClick:()=>eZ?null:te(e.id),role:"button","aria-label":`Vote for ${e.text}`,tabIndex:e6?0:-1,onKeyDown:t=>{("Enter"===t.key||" "===t.key)&&(t.preventDefault(),te(e.id))},style:{cursor:e6?"pointer":"default"},"data-cy":`polling-option-${e.id}`,hoverColor:eN?void 0:s.O9[null===(r=ek.color)||void 0===r?void 0:r.primaryLight],children:[eN&&(0,n.tZ)(X,{percentage:eY?f:0,fillColor:s.O9[v]}),!eN&&(0,n.tZ)(X,{percentage:100,fillColor:"transparent"}),(0,n.BX)(K,{width:"full",justifyContent:eN?"space-between":"center",gap:"2",children:[(0,n.tZ)(d.k,{alignItems:"center",textAlign:eN?"left":"center",gap:"2",minWidth:"0",children:(0,n.tZ)(u.x,{fontFamily:null===(a=ek.articleListCard)||void 0===a?void 0:a.category.fontFamily,fontWeight:eN?"normal":"bold",color:eN&&e.id===eE?"black":eN&&e.id!==eE?"greyscale60":eN||eP?"greyscale60":null===(c=ek.brand)||void 0===c?void 0:c.color,fontSize:"sm",children:e.text})}),eN&&(0,n.tZ)(o.x,{display:"flex",children:(0,n.BX)(u.x,{fontFamily:null===(p=ek.articleListCard)||void 0===p?void 0:p.category.fontFamily,fontWeight:"bold",color:eN&&e.id===eE?"black":(eN&&e.id,"greyscale50"),fontSize:"sm",dataCy:`polling-percentage-${e.id}`,wordBreak:"normal",children:[f,"%"]})})]})]},e.id);return!eg&&g?(0,n.BX)(o.x,{position:"relative",width:"full",children:[h,(0,n.tZ)(O,{voters:eA,totalVoters:ez||0})]},e.id):h})}),(0,n.BX)(d.k,{justifyContent:"space-between",alignItems:"center",width:"full",children:[(0,n.BX)(u.x,{fontFamily:null===(U=ek.articleListCard)||void 0===U?void 0:U.publishDate.fontFamily,fontWeight:null===(J=ek.articleListCard)||void 0===J?void 0:J.publishDate.fontWeight,color:null===(Q=ek.articleListCard)||void 0===Q?void 0:Q.publishDate.color,fontSize:"xs",dataCy:"polling-vote-count",children:[!ez||ez<50?"< 50":W(ez)," ","Voters"]}
21),(0,n.tZ)(u.x,{fontFamily:null===(G=ek.articleListCard)||void 0===G?void 0:G.publishDate.fontFamily,fontWeight:null===(ee=ek.articleListCard)||void 0===ee?void 0:ee.publishDate.fontWeight,color:eP?null===(et=ek.articleListCard)||void 0===et?void 0:et.publishDate.color:null===(ei=ek.articleListCard)||void 0===ei?void 0:ei.publishDate.color,fontSize:"xs",dataCy:"polling-expiry",children:eX&&M(eX)})]})]}),e0&&eQ&&(0,n.tZ)(eQ,{alert:{title:"Your vote matters",message:"Log in to submit your vote and help shape the results."},onClose:()=>e1(!1)})]}),e4&&e3&&(0,n.tZ)(e3,{open:e4,onClose:()=>e8(!1)})]})}},35116:function(e,t,i){i.d(t,{u:function(){return s}});var n=i(93419),l=i(27096),r=i(82268),o=i(73570),a=i(23329),d=i(64217),u=i(33168);function s(){let{isLogin:e}=(0,u.a)(),t=(0,o.useRouter)(),i=(0,r.NL)(),s=(0,a.useCallback)(async(e,t)=>{if(!e)return!1;try{return!!await i.fetchQuery({queryKey:["paid-article-content",e,t],queryFn:()=>(0,l.$)(e,t),staleTime:3e5,retry:!1})}catch{return!1}},[i]),c=(0,a.useCallback)(async(t,i)=>{if("paid"===t&&e){var l,r;let e=await s(null!==(l=i.articleKey)&&void 0!==l?l:"",null!==(r=i.publisher)&&void 0!==r?r:"");return(0,n.tb)({tier:t,isLoggedIn:!0,isPurchased:e})}return(0,n.tb)({tier:t,isLoggedIn:e})},[e,s]);return{handleArticleClick:(0,a.useCallback)((e,i,n)=>{var l;let r=null!==(l=null==n?void 0:n.tier)&&void 0!==l?l:"free";if("free"===r){(0,d.e)(e);return}let o=null==n?void 0:n.href;if(!o){c(r,null!=n?n:{}).then(t=>(0,d.e)({...e,content_type_var:`${e.content_type_var}${t}`}));return}if(i&&(i.metaKey||i.ctrlKey||i.shiftKey||i.altKey||1===i.button)){(0,d.e)(e);return}null==i||i.preventDefault(),c(r,null!=n?n:{}).then(t=>{(0,d.e)({...e,content_type_var:`${e.content_type_var}${t}`})}).finally(()=>{t.push(o)})},[c,t])}}},72222:function(e,t,i){i.d(t,{M:function(){return r}}),i(23329);let n=null,l=null;async function r(){return n||(l||(l=(async()=>{try{let e=await i.e(4991).then(i.bind(i,64991)).then(e=>e.default),t=await e.load();return n=(await t.get()).visitorId}catch(e){return console.error("Failed to generate fingerprint:",e),l=null,null}})()),l)}},38108:function(e,t,i){i.d(t,{Yo:function(){return r}});let n="vote_poll_tracker";function l(){if("undefined"==typeof localStorage)return{};try{let e=localStorage.getItem(n);return e?JSON.parse(e):{}}catch(e){return console.error("Failed to parse poll tracker storage:",e),{}}}function r(e){let{pollKey:t,optionId:i,isLogin:r,currentUrl:o,fingerprintId:a,userId:d}=e;if(!function(e,t){let i=l()[`${e}_${t}`];return!i||Date.now()-i.clickAt>=15e3}(t,a))return null;let u={pollKey:t,optionId:i,isLogin:r,currentUrl:o,clickAt:Date.now(),fingerprintId:a,userId:d};return!function(e){var t,i;let r=l();r[t=e.pollKey,i=e.fingerprintId,`${t}_${i}`]=e,function e(t){if("undefined"!=typeof localStorage)try{localStorage.setItem(n,JSON.stringify(t))}catch(i){if(console.error("Failed to save poll tracker storage:",i),i instanceof Error&&"QuotaExceededError"===i.name){!function(){let t=l(),i=Date.now(),n=!1;Object.keys(t).forEach(e=>{i-t[e].clickAt>=15e3&&(delete t[e],n=!0)}),n&&e(t)}();try{localStorage.setItem(n,JSON.stringify(t))}catch(e){console.error("Failed to save poll tracker storage after cleanup:",e)}}}}(r)}(u),u}},53362:function(e,t,i){var n=i(71544),l=i(59497);class r{async postTracker(e){try{let t=(0,n.VD)(e),{data:i}=await (0,l.Z)({method:"POST",url:"/poll-tracker",data:t});return{status:i.status,data:i.data}}catch(e){return null}}async readExperienceTracker(e){try{let t=(0,n.VD)(e),{data:i}=await (0,l.Z)({method:"POST",url:"/analytic-read-experience",data:t});return i}catch(e){return null}}}t.Z=new r},85333:function(e,t,i){var n=i(71544),l=i(80880),r=i(504);class o{async PostPoll(e){let{body:t,key:i}=e,l=(0,n.VD)(t);try{let{data:e}=await r.Z.post("/poll/vote",l,{params:{key:i}});return e}catch(e){return Promise.reject(e)}}async getLatestPolling(e){let{publisher:t,page:i,limit:n}=e;try{let{data:e}=await r.Z.get("/poll/latest",{params:{publisher:t,page:i,limit:n}});return e}catch(e){return Promise.reject(e)}}async getTrendingPolling(e){let{publisher:t}=e;try{let{data:e}=await r.Z.get("/poll/trending",{params:{publisher:t}});return e}catch(e){return Promise.reject(e)}}async getDetailPolling(e){let{key:t,publisher:i}=e;try{let{data:e}=await r.Z.get("/poll/public",{params:{key:t,publisher:i}});return{status:e.status,data:e.data}}catch(e){return Promise.reject(e)}}async getPublicPolling(e){let{key:t,publisher:i}=e;try{let{data:e}=await l.Z.get(`/v1/poll/${t}/public`,{params:{publisher:i}});return{status:e.status,data:e.data}}catch(e){return Promise.reject(e)}}}t.Z=new o}}]);
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.