1import{Ht as e,g as t}from"./CoKk4mC0.js";import{t as n}from"./CV1ffuEZ.js";var r=()=>{let r=n(`consent`,()=>({rawConsentDetail:null,isConsentInitialized:!1,acceptAnalytics:!1,acceptMarketing:!1,acceptFunctional:!1,acceptEssential:!1})),i=t(()=>!!r.value.rawConsentDetail),a=t(()=>r.value.acceptAnalytics),o=t(()=>r.value.acceptMarketing),s=t(()=>r.value.acceptFunctional),c=t(()=>r.value.acceptEssential),l=t(()=>{if(!r.value.rawConsentDetail)return null;let e={},t={};return Object.entries(r.value.rawConsentDetail.services).forEach(([t,n])=>{e[t]=n.consent.given}),Object.entries(r.value.rawConsentDetail.categories).forEach(([e,n])=>{t[e]=n.state===`ALL_ACCEPTED`}),{consents:e,categories:t,controllerId:r.value.rawConsentDetail.consent.controllerId}}),u=t(()=>r.value.rawConsentDetail?.services?Object.entries(r.value.rawConsentDetail.services).filter(([e,t])=>t.consent.given).map(([e,t])=>({id:e,...t})):[]),d=t(()=>r.value.rawConsentDetail?.services?Object.entries(r.value.rawConsentDetail.services).filter(([e,t])=>!t.consent.given&&!t.essential).map(([e,t])=>({id:e,...t})):[]);function f(e){return r.value.rawConsentDetail?.services[e]?.consent.given??!1}function p(e){let t=r.value.rawConsentDetail?.categories[e];return t?t.state===`ALL_ACCEPTED`:!1}function m(e){r.value.rawConsentDetail=e,r.value.isConsentInitialized=!0,r.value.acceptAnalytics=p(`analytics`),r.value.acceptMarketing=p(`marketing`),r.value.acceptFunctional=p(`functional`),r.value.acceptEssential=p(`essential`)}let h=t=>{e(()=>l,e=>{e&&t(e)},{immediate:!0})};function g(){window.UC_UI&&window.UC_UI.showFirstLayer()}function _(e){return r.value.rawConsentDetail?.services[e]||null}function v(e){return r.value.rawConsentDetail?.categories[e]||null}return{rawConsentDetail:r.value.rawConsentDetail,consentDetail:l,isConsentGiven:i,isConsentInitialized:r.value.isConsentInitialized,allAcceptedServices:u,allDeniedServices:d,hasAnalyticsConsent:a,hasMarketingConsent:o,hasFunctionalConsent:s,hasEssentialConsent:c,updateConsent:m,hasConsent:f,hasCategoryConsent:p,onConsentChange:h,openConsentManager:g,getServiceInfo:_,getCategoryInfo:v}};export{r as t};
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.