1import{j as e}from"../chunks/vendor-react-DdEP1kCQ.js";import{D as b}from"../chunks/DefaultLayout-n0x-WG_8.js";import{j as f}from"../chunks/core-DTFOJR-b.js";import{s as j}from"../chunks/style.module-CJb7qyJt.js";import"../chunks/Header-CvZfB-VC.js";import"../chunks/sciam-BnjwuU5W.js";import"../chunks/sciam-DxVNerXk.js";import"../chunks/vendor-shared-ShLQKC4n.js";(function(){try{var n=typeof window<"u"?window:typeof global<"u"?global:typeof globalThis<"u"?globalThis:typeof self<"u"?self:{},i=new n.Error().stack;i&&(n._sentryDebugIds=n._sentryDebugIds||{},n._sentryDebugIds[i]="25fb951f-58e0-4e20-96b9-7078845db1c1",n._sentryDebugIdIdentifier="sentry-dbid-25fb951f-58e0-4e20-96b9-7078845db1c1")}catch{}})();const y={essential:"Essential (always on)",analytics:"Analytics",marketing:"Marketing / Targeted Ads",personalization:"Personalization (experience, not ads)",storage:"Storage (TCFv2)",optOut:"Opt out of sale/sharing (IAB CCPA)"};function g(){const{consent:n,embedConsent:i,consentReady:t,consentRequired:d,consentUiVisible:a,consentError:l,consentFallback:r,showConsentUi:c,hideConsentUi:h,showDoNotSell:x,grantEmbedConsent:p,revokeEmbedConsent:u}=f(),s=t?window.Osano?.cm:null;return e.jsxs("div",{style:{display:"flex",flexDirection:"column wrap",justifyContent:"space-between",gap:"1.5rem",maxWidth:"1200px",margin:"1rem auto"},children:[e.jsxs("section",{children:[e.jsx("h2",{children:"Status"}),e.jsxs("div",{style:{display:"flex",flexDirection:"column",width:"300px"},children:[e.jsx("span",{children:t?"CMP ready":"Waiting for CMP..."}),r&&e.jsx("span",{style:{color:"orange"},children:"Running on the read-only fallback shim"}),l&&e.jsxs("span",{style:{color:"red"},children:["Error: ",l.message]}),a&&e.jsx("span",{children:"CMP UI is visible"}),d===!0&&e.jsx("span",{children:"User interaction required"}),d===!1&&e.jsx("span",{children:"User has made a choice"}),s&&!s.shim&&e.jsxs(e.Fragment,{children:[e.jsxs("span",{children:["Jurisdiction: ",s.jurisdiction]}),e.jsxs("span",{children:["Consent model: ",s.consentModel]}),e.jsxs("span",{children:["Compliance mode: ",s.mode]}),e.jsxs("span",{children:["CMP v",s.cmpVersion," (revision ",s.revision,")"]})]})]})]}),e.jsxs("section",{children:[e.jsx("h2",{children:"Preferences"}),e.jsxs("div",{style:{display:"flex",flexDirection:"column",gap:"0.5rem",width:"300px"},children:[e.jsx("button",{onClick:c,disabled:r,children:"Show preferences drawer"}),e.jsx("button",{onClick:h,disabled:r,children:"Hide preferences drawer"}),e.jsx("button",{onClick:x,disabled:r,children:'Show "Do not sell" modal'}),e.jsx("button",{onClick:p,disabled:i,children:"Grant embed consent"}),e.jsx("button",{onClick:u,disabled:!i,children:"Revoke embed consent"})]}),e.jsxs("div",{style:{marginBlock:"1rem"},children:[Object.entries(y).map(([o,m])=>e.jsxs("div",{children:[e.jsx("input",{type:"checkbox",readOnly:!0,checked:!!n[o]})," ",m,n[o]===null&&" (unknown)"]},o)),e.jsxs("div",{children:[e.jsx("input",{type:"checkbox",readOnly:!0,checked:i})," Third-party embeds"]})]})]}),e.jsxs("section",{children:[e.jsx("h2",{children:"Consent State"}),e.jsx("pre",{style:{width:"100%",minWidth:"40ch",maxWidth:"100ch",background:"#f4f4f4",border:"1px solid #ddd",borderRadius:"4px",padding:"1rem",overflowX:"auto"},children:JSON.stringify({consent:n,embedConsent:i,osano:s?.getConsent()},null,2)})]})]})}function S(){return e.jsx(b,{children:e.jsx("div",{className:j.playground,children:e.jsx(g,{})})})}export{S 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.