1import{z as y,f as n,E as k,av as v,a as i,u as D,e as w,m as C,S as d,n as g,T as _,bQ as E,o as c,bR as F,W as m,O as x,b1 as M,p as I,t as f,bk as S,s as T,v as L}from"./index-D5gHkNn-.js";import{C as $}from"./ContentTrack-CbEI3md9.js";import{f as u}from"./index-CgokGjYA.js";import{c as N,g as O,d as z}from"./store-CbLsPlo8.js";import{F as A,c as P,d as B,g as R}from"./tracking-BLN9Li8H.js";import"./vip-service-KVoGc22m.js";import"./index-BZcJr2o1.js";(function(){try{var e=typeof window!="undefined"?window:typeof global!="undefined"?global:typeof globalThis!="undefined"?globalThis:typeof self!="undefined"?self:{};e.SENTRY_RELEASE={id:"8c3b9aa2b95acaad15d7da0cf7f36f5b8cfcd6d1"},e._sentryModuleMetadata=e._sentryModuleMetadata||{},e._sentryModuleMetadata[new e.Error().stack]=(function(t){for(var r=1;r<arguments.length;r++){var s=arguments[r];if(s!=null)for(var l in s)s.hasOwnProperty(l)&&(t[l]=s[l])}return t})({},e._sentryModuleMetadata[new e.Error().stack],{"_sentryBundlerPluginAppKey:playsmart-ai":!0})}catch(t){}})();const Q="/assets/float-entry-fUh7Qp4d.svg";function p(e){const t=new Date(e);return Date.UTC(t.getFullYear(),t.getMonth(),t.getDate())/864e5}function U(e){const t=JSON.parse(e);if(t&&Number.isInteger(t.day)&&(t.count===1||t.count===2))return{day:t.day,count:t.count}}function W(e,t){return!!e&&(e.count>=2||e.day===p(t))}function Y(e,t){const r=p(t);return e&&(e.count>=2||e.day===r)?e:{day:r,count:e?2:1}}var j=f('<img alt class="pointer-events-none block h-auto w-full">'),H=f('<span class="draw-float-count absolute end-2.5 top-7 rounded-md bg-warning px-2 text-center text-xs font-extrabold leading-4 text-primary_brand"aria-live=polite>'),J=f('<aside class="draw-float fixed bottom-sf end-1.5 z-20 mb-6 w-28">');function K(){const e=N(),t=()=>e.data,[r,s]=g(Date.now()),[l,b]=_(g(),{name:`${i.userId}-lucky-draw-float-dismissal`,deserialize:U});E(()=>s(Date.now()),1e3,setInterval);const h=()=>{const o=t();if(e.isError||!o||W(l(),r()))return!1;const a=z(o,r());return o.visible&&(a==="active"||a==="exhausted"||a==="ended")};return n(d,{get when(){return h()},get children(){return n($,{showEvent:A,showData:()=>R(t().ticketCount),get children(){var o=J();return c(o,n(F,{href:"/events/lucky-draw",class:"relative block w-full",get"aria-label"(){return u("Million Card Draw")},onClick:()=>P(t().ticketCount),get children(){return[(()=>{var a=j();return m(a,"src",Q),a})(),n(d,{get when(){return t().ticketCount>0},get children(){var a=H();return c(a,()=>O(t().ticketCount)),a}})]}}),null),c(o,n(x,{class:"draw-float-close absolute end-2 top-2 flex size-4 items-center justify-center rounded bg-layer4 p-0 text-primary after:absolute after:-inset-1.5",get"aria-label"(){return u("Close")},onClick:()=>{const a=Y(l(),Date.now());b(a),B(a.count)},get children(){return n(M,{class:"draw-float-close-icon size-2.5 fill-current"})}}),null),I(()=>m(o,"aria-label",u("Million Card Draw"))),o}})}})}function V(e){const t=y();return n(d,{get when(){return D(()=>!!(w.mobile&&i.login&&!i._isStale&&C(t.pathname)==="/"))()&&i.userId},keyed:!0,get children(){return n(k,{fallback:null,get children(){return n(v,{fallback:null,get children(){return n(K,{})}})}})}})}const ne={trigger:e=>{!w.mobile||T.bcgh||L().then(()=>e(!0))},when:!0};function re(){S.once(V)}export{re as default,ne as event};
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.