text: !function(e){var t={};function n(r){if(t[r])return t[r].exports;var o=t[r]={i:r,l:!1,exports:{}};return e[r].call(o.exports,o,o.exports,n),o.l=!0,o.exports}n.m=e,n.c=t,n.d=function(e,t,r){n.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:r})},n.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},n.t=function(e,t){if(1&t&&(e=n(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var r=Object.create(null);if(n.r(r),Object.defineProperty(r,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var o in e)n.d(r,o,function(t){return e[t]}.bind(null,o));return r},n.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return n.d(t,"a",t),t},n.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},n.p="",n(n.s=0)}([function(e,t){const n="https://cfw-takehome.developers.workers.dev/api/variants";let r,o;addEventListener("fetch",e=>{e.request=n,e.respondWith(async function(e){let t=(new HTMLRewriter).on("title",new a).on("h1#title",new a).on("p#description",new a).on("a#url",new i("href"));await fetch(n).then(e=>e.json()).then(e=>{r=e.variants}).catch(e=>console.log("Unable to fetch: ",e));let u=await async function(e){const t=await fetch(r[0]),n=await fetch(r[1]),a=e.headers.get("cookie");if(a&&a.includes("user-group=group_one"))return o=0,t;if(a&&a.includes("user-group=group_two"))return o=1,n;{o=Math.floor(100*Math.random()%2);let e=await fetch(r[o]);e=new Response(e.body,e);let t=0===o?"group_one":"group_two";return e.headers.append("Set-Cookie",`user-group=${t}; path=/`),e}}(e);return t.transform(u)}(e.request))});class a{element(e){"title"===e.tagName&&e.setInnerContent("Paridhi's Take-Home"),"h1"===e.tagName&&(0===o?e.setInnerContent("I'm Paridhi, Student @UCSD"):e.setInnerContent("I'm Paridhi, an advocate for diversity")),"p"===e.tagName&&(0===o?e.setInnerContent("I'm really passionate about the intersection of Computer Science and Design and want to better the world one line of code at a time."):e.setInnerContent("I work with WIC (Women in Computing), ABLE (Anita B. Org Leadership) and GWC (Girls' Who Code) to promote representation in CS."))}}class i{constructor(e){this.attributeName=e}element(e){const t=e.getAttribute(this.attributeName);t&&(e.setInnerContent("Visit My Website :)"),e.setAttribute(this.attributeName,t.replace("https://cloudflare.com","https://www.paridhikhaitan.me")))}}}]);