chunk-cookies-48f59dde.js 1.2 KB

12
  1. System.register([],function(f){"use strict";return{execute:function(){f({d:m,g:u,s:d});var h=Object.defineProperty,r=(o,t)=>h(o,"name",{value:t,configurable:!0});function u(o){const t=[];for(const e of a()){const[i,c]=e.trim().split("=");o===i&&typeof c!="undefined"&&t.push({key:i,value:c})}return t}r(u,"getCookies");function a(){try{return document.cookie.split(";")}catch(o){return[]}}r(a,"readCookies");function d(o,t,e=null,i=!1,c="lax"){let n=document.domain;if(n==null)throw new Error("Unable to get document domain");n.endsWith(".github.com")&&(n="github.com");const s=location.protocol==="https:"?"; secure":"",l=e?`; expires=${e}`:"";i===!1&&(n=`.${n}`);try{document.cookie=`${o}=${t}; path=/; domain=${n}${l}${s}; samesite=${c}`}catch(p){}}r(d,"setCookie");function m(o,t=!1){let e=document.domain;if(e==null)throw new Error("Unable to get document domain");e.endsWith(".github.com")&&(e="github.com");const i=new Date().getTime(),c=new Date(i-1).toUTCString(),n=location.protocol==="https:"?"; secure":"",s=`; expires=${c}`;t===!1&&(e=`.${e}`);try{document.cookie=`${o}=''; path=/; domain=${e}${s}${n}`}catch(l){}}r(m,"deleteCookie")}}});
  2. //# sourceMappingURL=chunk-cookies-01679a10.js.map