+
-
+
+ // Night particles (fireflies)
+ const fireflies = [];
+ function initFireflies(){
+ fireflies.length = 0;
+ const horizonY = (H/dpr) - 40;
+ const maxY = Math.max(horizonY - 24, (H/dpr) * 0.85);
+ for(let i=0;i<40;i++){
+ fireflies.push({x: rand(20, W/dpr-20), y: rand(20, maxY), r: rand(0.6,1.8), phase: Math.random()*Math.PI*2});
+ }
+ }
+
+ // Croco agent
+ class Croco{
+ constructor(){
+ this.r = rand(12,28) * 2; // visual size (2x larger)
+ this.x = rand(this.r+20, W/dpr - this.r - 20);
+ // place croco near ground initially
+ this.y = (H/dpr - 40 - this.r*0.5) + rand(-4,4);
+ // gentler initial velocities
+ // reduce initial velocities to slow movement (factor 1/5)
+ this.vx = rand(-0.3,0.3) * 0.2;
+ this.vy = rand(-0.05,0.05) * 0.2;
+ this.angle = 0;
+ // much lower maximum speed to keep movement calm
+ this.speedCap = rand(0.15,0.45) * 0.2;
+ this.state = 'awake'; // 'awake' | 'sleep'
+ this.sleepTimer = 0;
+ // visual animation states
+ this.blinkTimer = rand(2,6) * 1000; // ms until next blink
+ this.blinkProgress = 0; // when blinking >0 indicates closing/opening
+ this.tailPhase = Math.random() * Math.PI * 2;
+ // facing: 1 = right, -1 = left
+ this.facing = this.vx < 0 ? -1 : 1;
+ // movement timer for sustained motion and target velocity (ms)
+ this.moveTimer = rand(3000, 12000);
+ this.targetVx = this.vx;
+ this.locked = false; // if true, croco won't move
+ this.lockTimer = 0;
+ this.nextIdle = rand(3000,15000);
+ // pick a sprite index (if sprites loaded later, this index will be used)
+ this.spriteIndex = Math.floor(Math.random() * 3); // 0..2
+ // DOM lottie player element (created on demand)
+ this._lottiePlayer = null;
+ this._lottieLoaded = false;
+ }
+
+ step(dt, timeOfDay){
+ // if locked (user chose no-move) or sleeping, reduce movement
+ if(this.locked || this.state === 'sleep'){
+ // idle: locked for a while, slight breathing
+ this.vx *= 0.92;
+ this.vy = 0;
+ if(this.lockTimer){ this.lockTimer -= dt; if(this.lockTimer <= 0) { this.lockTimer = 0; this.locked = false; } }
+ } else {
+ // decide occasionally to pause (idle)
+ this.nextIdle -= dt;
+ if(this.nextIdle <= 0 && Math.random() < 0.45){
+ this.locked = true;
+ this.lockTimer = rand(2000, 9000); // idle 2-9s
+ this.nextIdle = rand(8000, 30000); // schedule next idle
+ }
+
+ // sustained movement: keep a target velocity for a while to avoid twitching
+ this.moveTimer -= dt * (simSpeed || 1);
+ if(this.moveTimer <= 0){
+ // choose a sustained movement duration much longer to avoid twitching
+ this.moveTimer = rand(8000, 35000); // 8-35s
+ // pick a horizontal direction with a guaranteed minimal speed
+ const dir = Math.random() < 0.5 ? -1 : 1;
+ // choose slower sustained speeds
+ // choose slower sustained speeds (scaled down by 1/5)
+ const speed = rand(0.08, 0.35) * 0.2;
+ this.targetVx = dir * speed;
+ this.targetVy = 0; // keep on ground
+ }
+ // smoothly approach target velocity
+ this.vx += (this.targetVx - this.vx) * 0.06;
+ this.vy += (0 - this.vy) * 0.25; // quickly damp vertical
+ }
+ // limit speed
+ const sp = Math.hypot(this.vx, this.vy);
+ if(sp > this.speedCap){ this.vx *= this.speedCap/sp; this.vy *= this.speedCap/sp; }
+
+ // note: wrap-around is used, avoid forcing steering at edges which can cancel wrap
+
+ // apply velocity (horizontal only for main movement)
+ this.x += this.vx;
+ // y is handled by ground lock later
+
+ // wrap-around horizontally: preserve overflow so movement is continuous
+ const buffer = Math.max(30, this.r*1.5);
+ const width = W/dpr;
+ const span = width + buffer * 2;
+ if(this.x > width + buffer) this.x -= span;
+ else if(this.x < -buffer) this.x += span;
+
+ // small damping
+ this.vx *= 0.992; this.vy *= 0.99;
+
+ // face based on horizontal velocity
+ if(this.vx > 0.05) this.facing = 1;
+ else if(this.vx < -0.05) this.facing = -1;
+
+ // ensure crocos stay grounded (no flying)
+ const groundY = H/dpr - 40 - this.r*0.5;
+ // gently move toward groundY (prevents sudden teleport)
+ const dy = groundY - this.y;
+ this.y += dy * 0.12;
+ // remove vertical drift
+ this.vy = 0;
+
+ // blink animation timing
+ if(this.blinkProgress > 0){
+ this.blinkProgress -= dt;
+ if(this.blinkProgress < 0) this.blinkProgress = 0;
+ } else {
+ this.blinkTimer -= dt;
+ if(this.blinkTimer <= 0){ this.blinkProgress = 180; this.blinkTimer = rand(2,6) * 1000; }
+ }
+
+ // tail sway phase advances
+ this.tailPhase += dt * 0.004;
+
+ // Sleep logic: at night, crocos can sleep
+ if(timeOfDay.isNight){
+ if(this.state !== 'sleep' && Math.random() < 0.008){
+ // enter sleep: gently come to rest on the soil
+ this.state = 'sleep';
+ // place on ground (soil starts at H - 40)
+ this.y = Math.min(this.y, H/dpr - 40 - this.r*0.4);
+ this.vx = 0; this.vy = 0;
+ this.sleepTimer = rand(4000, 15000);
+ }
+ } else {
+ // wake up during day when timer passes or randomly
+ if(this.state === 'sleep'){
+ this.sleepTimer -= dt * (simSpeed || 1);
+ if(this.sleepTimer <= 0 || Math.random() < 0.01) this.state = 'awake';
+ else {
+ // while sleeping, small breathing bob
+ this.y += Math.sin(performance.now()*0.002 + this.tailPhase) * 0.15;
+ // make sure they stay on ground
+ this.y = Math.min(this.y, H/dpr - 40 - this.r*0.4);
+ }
+ }
+ }
+ }
+
+ draw(ctx){
+ // prefer trimmed frame PNGs (guaranteed transparent) from frames_trimmed/
+ try{
+ if(!window.__trimmedFrameCache) window.__trimmedFrameCache = {};
+ const base = 'EasterEggs/animations/crocodile/frames_trimmed/';
+ const frameCount = 40; // known number of frames extracted
+ const idx = Math.max(0, Math.floor((this.tailPhase*10) % frameCount));
+ const name = base + 'frame_' + String(idx).padStart(3,'0') + '.png';
+ let img = window.__trimmedFrameCache[name];
+ if(!img){ img = new Image(); img.src = name; window.__trimmedFrameCache[name] = img; }
+ if(img && img.complete && img.naturalWidth){
+ const drawW = this.r * 3.2;
+ const drawH = (img.height / img.width) * drawW;
+ ctx.save(); ctx.translate(this.x, this.y); ctx.scale(-this.facing,1);
+ ctx.drawImage(img, -drawW/2, -drawH/2, drawW, drawH);
+ ctx.restore();
+ return;
+ }
+ } catch(e){ /* ignore and continue to canvas fallback */ }
+ // Restored detailed vector crocodile: gradient body, snout, teeth, scutes, tail, eye
+ ctx.save();
+ ctx.translate(this.x, this.y);
+ ctx.scale(-this.facing, 1);
+ const s = this.r;
+
+ // prefer sprites if preloaded
+ if(window.__crocoSprites && Array.isArray(window.__crocoSprites)){
+ const sp = window.__crocoSprites[this.spriteIndex];
+ if(sp && sp.complete && sp.naturalWidth){
+ // slight bob/tilt animation
+ const bob = Math.sin(this.tailPhase*0.9) * (s*0.06);
+ const tilt = Math.sin(this.tailPhase*0.003) * 0.06 * this.facing;
+ ctx.save();
+ ctx.translate(0, bob);
+ ctx.rotate(tilt);
+ const img = sp;
+ const drawW = s * 3.2;
+ const drawH = (img.height / img.width) * drawW;
+ ctx.drawImage(img, -drawW/2, -drawH/2, drawW, drawH);
+ ctx.restore();
+ ctx.restore();
+ return;
+ }
+ }
+
+ // if a realistic local image was preloaded, draw it instead for a more natural look
+ if(window.__crocoImg && window.__crocoImg.complete && window.__crocoImg.naturalWidth){
+ const img = window.__crocoImg;
+ const imgW = img.width;
+ const imgH = img.height;
+ const drawW = s * 3.2;
+ const drawH = (imgH / imgW) * drawW;
+ ctx.drawImage(img, -drawW/2, -drawH/2, drawW, drawH);
+ ctx.restore();
+ return;
+ }
+
+ // subtle shadow under the croco
+ ctx.beginPath();
+ ctx.ellipse(0, s*0.65, s*1.8, s*0.45, 0, 0, Math.PI*2);
+ ctx.fillStyle = 'rgba(20,20,20,0.12)';
+ ctx.fill();
+
+ // main body path (slightly elongated oval with snout)
+ ctx.beginPath();
+ ctx.moveTo(-s*1.1, -s*0.1);
+ ctx.quadraticCurveTo(-s*1.6, -s*0.9, -s*1.9, -s*0.2);
+ ctx.quadraticCurveTo(-s*1.95, s*0.5, -s*1.1, s*0.9);
+ ctx.quadraticCurveTo(s*0.9, s*1.05, s*1.6, s*0.25);
+ ctx.quadraticCurveTo(s*1.85, -s*0.35, s*0.6, -s*0.95);
+ ctx.quadraticCurveTo(s*0.2, -s*1.15, -s*1.1, -s*0.1);
+ ctx.closePath();
+
+ // gradient fill
+ const g = ctx.createLinearGradient(-s*1.6, -s, s*1.6, s);
+ g.addColorStop(0, '#79b46a');
+ g.addColorStop(0.45, '#5fa84d');
+ g.addColorStop(1, '#3f7b2f');
+ ctx.fillStyle = g;
+ ctx.fill();
+
+ // belly
+ ctx.beginPath();
+ ctx.ellipse(-s*0.25, s*0.15, s*0.95, s*0.6, 0, 0, Math.PI*2);
+ ctx.fillStyle = '#eaf3d8';
+ ctx.fill();
+
+ // ridged back (a few triangular plates)
+ ctx.fillStyle = '#2f5d20';
+ for(let i=0;i<5;i++){
+ const tx = -s*0.6 + i*(s*0.45);
+ const height = s*0.35*(1 - i*0.08);
+ ctx.beginPath();
+ ctx.moveTo(tx - s*0.18, -s*0.25);
+ ctx.lineTo(tx + s*0.12, -s*0.25 - height);
+ ctx.lineTo(tx + s*0.42, -s*0.25);
+ ctx.closePath();
+ ctx.fill();
+ }
+
+ // snout and jaw
+ ctx.beginPath();
+ ctx.moveTo(s*1.05, -s*0.15);
+ ctx.quadraticCurveTo(s*1.35, -s*0.05, s*1.4, s*0.18);
+ ctx.quadraticCurveTo(s*1.25, s*0.3, s*1.05, s*0.15);
+ ctx.closePath();
+ ctx.fillStyle = '#5ba042';
+ ctx.fill();
+
+ // teeth (small triangles along snout lower edge)
+ ctx.fillStyle = '#fff';
+ for(let i=0;i<4;i++){
+ const tx = s*0.82 + i*(s*0.12);
+ ctx.beginPath();
+ ctx.moveTo(tx, s*0.06);
+ ctx.lineTo(tx + s*0.06, s*0.14);
+ ctx.lineTo(tx - s*0.06, s*0.14);
+ ctx.closePath();
+ ctx.fill();
+ }
+
+ // eye with eyelid and pupil
+ const blink = Math.max(0, 1 - this.blinkProgress);
+ ctx.save();
+ ctx.translate(s*0.85, -s*0.45);
+ ctx.scale(1, 1);
+ // white
+ ctx.beginPath();
+ ctx.ellipse(0,0,s*0.22,s*0.14,0,0,Math.PI*2);
+ ctx.fillStyle = '#fff';
+ ctx.fill();
+ // pupil
+ ctx.beginPath();
+ ctx.arc(0,0,s*0.08,0,Math.PI*2);
+ ctx.fillStyle = '#0b1b10';
+ ctx.fill();
+ // eyelid (blink) overlay
+ if(blink < 1){
+ ctx.beginPath();
+ ctx.fillStyle = 'rgba(80,100,60,0.95)';
+ ctx.rect(-s*0.3, -s*0.14, s*0.6, s*0.28*(1-blink));
+ ctx.fill();
+ }
+ ctx.restore();
+
+ // legs (simple, slightly shaded)
+ ctx.fillStyle = '#4f7a35';
+ for(let i=0;i<4;i++){
+ const lx = -s*0.6 + i*(s*0.5);
+ ctx.beginPath();
+ ctx.ellipse(lx, s*0.9, s*0.22, s*0.16, 0, 0, Math.PI*2);
+ ctx.fill();
+ }
+
+ // tail curl at the left end
+ ctx.beginPath();
+ ctx.moveTo(-s*1.6, s*0.05);
+ ctx.quadraticCurveTo(-s*1.95, s*0.12, -s*2.05, -s*0.12);
+ ctx.quadraticCurveTo(-s*1.9, -s*0.34, -s*1.5, -s*0.18);
+ ctx.fillStyle = '#4c8236';
+ ctx.fill();
+
+ // outline
+ ctx.lineWidth = Math.max(1, s*0.08);
+ ctx.strokeStyle = 'rgba(10,30,10,0.65)';
+ ctx.stroke();
+
+ ctx.restore();
+ }
+ }
+
+ // stars (randomized per session)
+ const stars = [];
+ function initStars(){
+ stars.length = 0;
+ const width = W/dpr, height = H/dpr;
+ const horizonY = height - 40;
+ const maxY = Math.max(horizonY - 24, height * 0.85);
+ // scale star density with canvas area (stars per pixel)
+ const area = width * height;
+ const density = 0.00035; // stars per px (tweakable)
+ let STAR_COUNT = Math.round(area * density);
+ STAR_COUNT = Math.max(120, Math.min(900, STAR_COUNT)); // clamp to reasonable range
+ for(let i=0;i
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ `;
+
+ const img = new Image();
+ img.src = 'data:image/svg+xml;utf8,' + encodeURIComponent(svg);
+ spriteCache.set(key, img);
+ return img;
+ }
+
+ function roundRect(ctx,x,y,w,h,r){
+ ctx.beginPath();
+ ctx.moveTo(x+r,y);
+ ctx.arcTo(x+w,y,x+w,y+h,r);
+ ctx.arcTo(x+w,y+h,x,y+h,r);
+ ctx.arcTo(x,y+h,x,y,r);
+ ctx.arcTo(x,y,x+w,y,r);
+ ctx.closePath();
+ }
+
+ function initCrocos(){
+ crocos.length = 0;
+ for(let i=0;i{ window.__crocoImg = img; };
+ img.onerror = ()=>{ window.__crocoImg = null; };
+
+ // preload sprite variants
+ window.__crocoSprites = [];
+ ['EasterEggs/images/croco_sprite1.svg','EasterEggs/images/croco_sprite2.svg','EasterEggs/images/croco_sprite3.svg'].forEach((p,i)=>{
+ const s = new Image(); s.src = p; s.onload = ()=>{ window.__crocoSprites[i] = s; };
+ s.onerror = ()=>{ /* ignore */ };
+ });
+
+ // preload trimmed frames (from OpenGameArt sprites converted)
+ window.__crocoFrames = [];
+ (function(){
+ const base = 'EasterEggs/animations/crocodile/frames_trimmed/';
+ // assume frames named frame_000.png .. frame_039.png
+ for(let i=0;i<200;i++){
+ const name = 'frame_' + String(i).padStart(3,'0') + '.png';
+ const url = base + name;
+ const img = new Image();
+ img.src = url;
+ img.onload = ()=>{ window.__crocoFrames[i] = img; };
+ img.onerror = ()=>{ /* ignore missing frames */ };
+ }
+ })();
+ } catch(e){ window.__crocoImg = null; }
+ }
+
+ // preload generated frames (PNG sequence) if present
+ function preloadLottieFrames(){
+ // use the trimmed frames (transparent background) by default
+ const dir = 'EasterEggs/animations/crocodile/frames_trimmed/';
+ window.__crocoFrames = [];
+ // try to discover up to 200 frames
+ for(let i=0;i<200;i++){
+ const name = dir + 'frame_' + String(i).padStart(3,'0') + '.png';
+ const img = new Image();
+ img.src = name;
+ img.onload = (()=>{
+ const idx = i;
+ return ()=>{ window.__crocoFrames[idx] = img; };
+ })();
+ img.onerror = ()=>{ /* ignore missing */ };
+ }
+ }
+
+ // audio removed
+
+ // forced time controls
+ let forcedEnabled = false; // whether to use the forced time
+ let forcedTimeValue = {h:12, m:0};
+
+ // time of day helper
+ function getTimeState(){
+ let now = new Date();
+ if(forcedEnabled){
+ // create a Date with today's date but forced hour/min
+ now = new Date();
+ now.setHours(forcedTimeValue.h, forcedTimeValue.m, 0, 0);
+ }
+ const h = now.getHours();
+ const m = now.getMinutes();
+ const isNight = (h < 6 || h >= 20);
+ const isDusk = (h >= 18 && h < 20);
+ const isDawn = (h >=5 && h < 7);
+ return {now, h,m, isNight, isDusk, isDawn, isDay: !isNight && !isDusk && !isDawn};
+ }
+
+ // compute a night factor [0..1] where 0 = day, 1 = full night; fades in/out over twilightWindow hours
+ function computeNightFactor(hour){
+ const sr = 6, ss = 18; // sunrise/sunset
+ const twilight = 1.8; // hours over which stars/lucioles fade in/out
+ let h = (hour + 24) % 24;
+ // deep night (after sunset+twilight or before sunrise-twilight)
+ if(h >= ss + twilight || h <= sr - twilight) return 1;
+ // after sunset, fade in
+ if(h >= ss && h < ss + twilight) return (h - ss) / twilight;
+ // before sunrise, fade out (1 -> 0)
+ if(h >= sr - twilight && h < sr) return (sr - h) / twilight;
+ // daytime
+ return 0;
+ }
+
+ // draw background: sky, sun/moon, soil
+ function drawBackground(ctx, timeState, t){
+ // sky gradient based on time — smooth dawn/dusk transition
+ function lerp(a,b,t){ return a + (b-a)*t; }
+ function lerpColor(c1, c2, t){
+ // c1/c2 '#rrggbb' -> interpolate channels
+ const p1 = parseInt(c1.slice(1),16);
+ const p2 = parseInt(c2.slice(1),16);
+ const r = Math.round(lerp((p1>>16)&255, (p2>>16)&255, t));
+ const g = Math.round(lerp((p1>>8)&255, (p2>>8)&255, t));
+ const b = Math.round(lerp(p1&255, p2&255, t));
+ return '#' + [r,g,b].map(v=>v.toString(16).padStart(2,'0')).join('');
+ }
+
+ // base palettes
+ const dayTop = '#9fe7c6', dayBottom = '#6ad092';
+ const nightTop = '#071724', nightBottom = '#03202b';
+ const dawnWarmTop = '#ffbb88', dawnWarmBottom = '#ff6b4a';
+
+ // compute sun elevation fraction for smooth blending (0..1..0 across sunrise..sunset)
+ const hour = timeState.h + timeState.m/60;
+ const dayPos = (function(){
+ const sr = 6, ss = 18;
+ let h = (hour + 24) % 24;
+ if(h < sr || h > ss) return 0; // night
+ const tt = (h - sr) / (ss - sr);
+ return Math.sin(Math.PI * tt); // 0..1..0
+ })();
+
+ // dawn/dusk intensity based on proximity to sunrise/sunset (peak at edges)
+ const duskDawnIntensity = Math.max(0, 1 - Math.abs((hour - 12) / 6));
+
+ // mix colors: when dayPos is high use day palette, when low use night; add warm overlay near edges
+ let skyTop = lerpColor(nightTop, dayTop, dayPos);
+ let skyBottom = lerpColor(nightBottom, dayBottom, dayPos);
+ // warm tint during dawn/dusk: based on proximity to sunrise/sunset hours (windowed)
+ const sr = 6, ss = 18;
+ function timeDist(h,a){ let d = Math.abs(h-a); if(d > 12) d = 24 - d; return d; }
+ const warmWindow = 2.0; // hours around event where warm tint appears
+ const dist = Math.min(timeDist(hour, sr), timeDist(hour, ss));
+ const warmMix = Math.max(0, (warmWindow - dist) / warmWindow); // 1 at event, 0 beyond window
+ if(warmMix > 0.02){
+ skyTop = lerpColor(skyTop, dawnWarmTop, warmMix * 0.85);
+ skyBottom = lerpColor(skyBottom, dawnWarmBottom, warmMix * 0.95);
+ }
+
+ // gradient
+ const g = ctx.createLinearGradient(0,0,0,H/dpr);
+ g.addColorStop(0, skyTop);
+ g.addColorStop(1, skyBottom);
+ ctx.fillStyle = g; ctx.fillRect(0,0,W/dpr,H/dpr);
+
+ // compute sun/moon positions using a parametric day arc (sunrise -> noon -> sunset)
+ const width = W/dpr, height = H/dpr;
+ const margin = Math.max(40, width * 0.06);
+ const horizonY = height - 40; // top of soil
+ const arcHeight = Math.min(height * 0.6, horizonY - 40); // how high above horizon the sun rises
+
+ const sunrise = 6, sunset = 18;
+ function dayPosForHour(h){
+ // normalize to [0,24)
+ h = (h + 24) % 24;
+ if(h < sunrise || h > sunset) return null; // not in daytime range
+ const t = (h - sunrise) / (sunset - sunrise); // 0..1 across the day
+ // x moves linearly left->right across the sky
+ const cx = margin + t * (width - margin*2);
+ // y follows a semicircular arc: 0 at horizon -> 1 at noon -> 0 at horizon
+ const elevation = Math.sin(Math.PI * t); // 0..1..0
+ const cy = horizonY - elevation * arcHeight;
+ return {cx, cy, t};
+ }
+
+ // sun when daytime
+ const sunPos = dayPosForHour(hour);
+ if(sunPos){
+ const cx = sunPos.cx, cy = sunPos.cy;
+ // sun with glow
+ const rg = ctx.createRadialGradient(cx,cy,8,cx,cy,60);
+ rg.addColorStop(0, 'rgba(255,240,140,1)'); rg.addColorStop(1,'rgba(255,200,80,0)');
+ ctx.fillStyle = rg; ctx.beginPath(); ctx.arc(cx,cy,60,0,Math.PI*2); ctx.fill();
+ ctx.fillStyle = '#fff08a'; ctx.beginPath(); ctx.arc(cx,cy,18,0,Math.PI*2); ctx.fill();
+ }
+
+ // moon is opposite the sun (follow same arc but offset by 12h)
+ const moonHour = (hour + 12) % 24;
+ const moonPos = dayPosForHour(moonHour);
+ if(!sunPos && moonPos){
+ const cx = moonPos.cx, cy = moonPos.cy;
+ ctx.fillStyle = 'rgba(255,255,230,0.97)';
+ ctx.beginPath(); ctx.arc(cx, cy, 24, 0, Math.PI*2); ctx.fill();
+ // small craters
+ ctx.fillStyle = 'rgba(0,0,0,0.06)'; ctx.beginPath(); ctx.arc(cx-6,cy-3,3,0,Math.PI*2); ctx.fill();
+ }
+
+ // soil at bottom
+ ctx.fillStyle = getComputedStyle(document.documentElement).getPropertyValue('--soil') || '#3b2f24';
+ ctx.fillRect(0, H/dpr - 40, W/dpr, 40);
+
+ // stars at night (allow stars lower toward horizon but keep small margin above soil)
+ // compute night factor for gradual appearance of stars
+ const nf = computeNightFactor(timeState.h + timeState.m/60);
+ if(nf > 0.02){
+ for(const s of stars){
+ // twinkle alpha modulated by phase/time and night factor
+ const tw = 0.5 + 0.5 * Math.sin(t*0.001 + s.phase);
+ const alpha = Math.min(1, s.a * tw) * nf;
+ ctx.fillStyle = `rgba(255,255,230,${alpha})`;
+ if(s.w === 2) ctx.fillRect(s.x, s.y, 2, 2);
+ else ctx.fillRect(s.x, s.y, 1, 1);
+ }
+ }
+ }
+
+ // draw plants
+ function drawPlants(ctx, t){
+ for(const p of plants){
+ const sway = Math.sin(t*0.002*p.sway + p.phase) * Math.min(18, p.h*0.03);
+ const baseX = p.x, baseY = H/dpr - 40;
+ // stem (thicker for larger plants)
+ ctx.strokeStyle = '#1e6d3a'; ctx.lineWidth = Math.max(3, p.h * 0.03); ctx.beginPath(); ctx.moveTo(baseX, baseY); ctx.quadraticCurveTo(baseX + sway*0.5, baseY - p.h*0.45, baseX + sway, baseY - p.h); ctx.stroke();
+ // leaf clusters scaled with height
+ const leafW = Math.max(18, p.h * 0.18);
+ const leafH = Math.max(24, p.h * 0.22);
+ ctx.fillStyle = '#2aa05a'; ctx.beginPath(); ctx.ellipse(baseX + sway, baseY - p.h, leafW, leafH, -0.6, 0, Math.PI*2); ctx.fill();
+ ctx.beginPath(); ctx.ellipse(baseX + sway + leafW*0.35, baseY - p.h + leafH*0.35, leafW*0.9, leafH*0.8, 0.3, 0, Math.PI*2); ctx.fill();
+ }
+ }
+
+ // draw floating 'Zzz' for sleeping crocos
+ function drawZzz(ctx, croco, t){
+ if(croco.state !== 'sleep') return;
+ // compute a small rising offset and fade using tailPhase + time
+ const phase = (croco.tailPhase || 0) + t*0.0008;
+ const baseX = croco.x;
+ const baseY = (H/dpr) - 40 - croco.r - 8; // slightly above croco head
+ // three Zs with staggered timing
+ for(let i=0;i<3;i++){
+ const off = i * 14;
+ const y = baseY - (Math.sin(phase + i) * 6 + off*0.12);
+ const alpha = Math.max(0, 1 - (i*0.25) - ((Math.sin(phase + i)+1)/2)*0.4);
+ ctx.save();
+ ctx.translate(baseX - croco.r*0.2 + i*6, y);
+ ctx.rotate(-0.18 + i*0.06);
+ ctx.font = `${Math.max(12, croco.r*0.35)}px serif`;
+ ctx.fillStyle = `rgba(223,240,255,${alpha})`;
+ ctx.fillText('z', 0, 0);
+ ctx.restore();
+ }
+ }
+
+ function drawFireflies(ctx, t, timeState){
+ // use night factor to fade fireflies in/out
+ const nf = computeNightFactor(timeState.h + timeState.m/60);
+ if(nf <= 0.02) return;
+ for(const f of fireflies){
+ const ax = Math.cos(t*0.001 + f.phase) * 6;
+ const ay = Math.sin(t*0.0015 + f.phase*1.3) * 3;
+ const x = f.x + ax; const y = f.y + ay;
+ const glow = 0.6 + Math.sin(t*0.008 + f.phase)*0.4;
+ ctx.beginPath(); ctx.fillStyle = `rgba(255,245,140,${0.08*glow*nf})`; ctx.arc(x,y,f.r*4,0,Math.PI*2); ctx.fill();
+ ctx.beginPath(); ctx.fillStyle = `rgba(255,245,140,${0.9*glow*nf})`; ctx.arc(x,y,f.r*1.2,0,Math.PI*2); ctx.fill();
+ }
+ }
+
+ // main loop
+ let last = performance.now();
+ // allow forcing day/night for testing
+ let forcedMode = null; // 'day' | 'night' | null
+ function loop(now){
+ const dt = now - last; last = now;
+ const t = now;
+
+ let timeState = getTimeState();
+ if(forcedMode){
+ if(forcedMode === 'day') timeState = {...timeState, isNight:false, isDusk:false, isDawn:false, isDay:true};
+ if(forcedMode === 'night') timeState = {...timeState, isNight:true, isDusk:false, isDawn:false, isDay:false};
+ }
+ document.getElementById('timeText').textContent = timeState.h + ':' + String(timeState.m).padStart(2,'0');
+
+ // set body background color based on time
+ if(timeState.isNight) document.body.style.background = getComputedStyle(document.documentElement).getPropertyValue('--bg-night');
+ else if(timeState.isDusk) document.body.style.background = getComputedStyle(document.documentElement).getPropertyValue('--bg-dusk');
+ else document.body.style.background = getComputedStyle(document.documentElement).getPropertyValue('--bg-day');
+
+ // draw
+ drawBackground(ctx, timeState, t);
+ drawPlants(ctx, t);
+ drawFireflies(ctx, t, timeState);
+
+ // update & draw crocos (respect pause and simSpeed)
+ for(const c of crocos){
+ if(!paused) c.step(dt * simSpeed, timeState);
+ c.draw(ctx);
+ // animated sleeping Zzz
+ drawZzz(ctx, c, t);
+ }
+
+ requestAnimationFrame(loop);
+ }
+
+ // initialize everything
+ function resetAll(){
+ resize();
+ initPlants();
+ initCrocos();
+ initFireflies();
+ initStars();
+ preloadLocalCroco();
+ preloadLottieFrames();
+ }
+
+ resetAll();
+ requestAnimationFrame(loop);
+
+ // NOTE: do NOT auto-enable Lottie. Prefer trimmed PNG frames by default to avoid white boxes.
+
+ // --- Lottie support (lazy) -------------------------------------------------
+ window.__useLottie = false; // default: off
+
+ async function loadLottieRuntime(){
+ if(window.__lottie) return window.__lottie;
+ // load lottie-web from CDN
+ await new Promise((res,rej)=>{
+ const s = document.createElement('script');
+ s.src = 'https://cdnjs.cloudflare.com/ajax/libs/lottie-web/5.10.2/lottie.min.js';
+ s.onload = res; s.onerror = rej; document.head.appendChild(s);
+ });
+ window.__lottie = window.lottie;
+ return window.__lottie;
+ }
+
+ async function loadLottieData(){
+ if(window.__lottieData) return window.__lottieData;
+ try{
+ const resp = await fetch('EasterEggs/animations/crocodile/animations/12345.json');
+ if(!resp.ok) throw new Error('fetch failed');
+ window.__lottieData = await resp.json();
+ return window.__lottieData;
+ }catch(e){ console.warn('Failed to load lottie JSON', e); return null; }
+ }
+
+ // toggle and initialize lottie
+ async function enableLottie(enable){
+ if(enable){
+ await loadLottieRuntime();
+ await loadLottieData();
+ if(!window.__lottieData) return false;
+ window.__useLottie = true;
+ return true;
+ } else {
+ window.__useLottie = false;
+ // remove any existing player DOMs
+ document.querySelectorAll('#lottieLayer > div').forEach(d=>d.remove());
+ return true;
+ }
+ }
+
+ // quick toggle with 'L' key for testing
+ document.addEventListener('keydown', async (e)=>{ if(e.key === 'L' || e.key === 'l'){ if(!window.__useLottie) await enableLottie(true); else await enableLottie(false); } });
+
+ // click/dblclick interactions removed per user request
+
+ // watch for visibility change to pause
+ let paused = false;
+ document.addEventListener('visibilitychange', ()=>{ paused = document.hidden; if(paused) cancelAnimationFrame(loop); else { last = performance.now(); requestAnimationFrame(loop); } });
+
+ // re-init when resizing settles
+ let resizeTimer; window.addEventListener('resize', ()=>{ clearTimeout(resizeTimer); resizeTimer = setTimeout(resetAll, 150); });
+
+ // expose small debug in console
+ window.__terrarium = {crocos, plants, resetAll};
+
+ // controls wiring
+ const btnPause = document.getElementById('btnPause');
+ const btnAdd = document.getElementById('btnAdd');
+ const btnRemove = document.getElementById('btnRemove');
+ const forceCheckbox = document.getElementById('forceCheckbox');
+ const forceTime = document.getElementById('forceTime');
+
+ btnPause.addEventListener('click', ()=>{ paused = !paused; btnPause.textContent = paused ? 'Play' : 'Pause'; if(!paused){ last = performance.now(); requestAnimationFrame(loop); } });
+ btnAdd.addEventListener('click', ()=>{ if(crocos.length < 60) crocos.push(new Croco()); });
+ btnRemove.addEventListener('click', ()=>{ if(crocos.length) crocos.pop(); });
+
+ // wire forced time inputs
+ forceCheckbox.addEventListener('change', ()=>{
+ forcedEnabled = !!forceCheckbox.checked;
+ });
+ // remember last input to detect minute wrap when using arrow keys
+ let lastForceTime = {h: forcedTimeValue.h, m: forcedTimeValue.m};
+ forceTime.addEventListener('input', ()=>{
+ const v = forceTime.value || '12:00';
+ const parts = v.split(':');
+ let hh = parseInt(parts[0],10);
+ let mm = parseInt(parts[1],10);
+ if(Number.isNaN(hh)) hh = lastForceTime.h;
+ if(Number.isNaN(mm)) mm = lastForceTime.m;
+ // detect minute wrap caused by arrow step
+ if(lastForceTime){
+ if(lastForceTime.m === 59 && mm === 0 && hh === lastForceTime.h){
+ hh = (lastForceTime.h + 1) % 24;
+ } else if(lastForceTime.m === 0 && mm === 59 && hh === lastForceTime.h){
+ hh = (lastForceTime.h + 23) % 24;
+ }
+ }
+ forcedTimeValue.h = Math.max(0, Math.min(23, hh));
+ forcedTimeValue.m = Math.max(0, Math.min(59, mm));
+ lastForceTime = {h: forcedTimeValue.h, m: forcedTimeValue.m};
+ // normalize displayed value
+ forceTime.value = String(forcedTimeValue.h).padStart(2,'0') + ':' + String(forcedTimeValue.m).padStart(2,'0');
+ });
+
+
+ // occasionally have a croco 'yawn' at dusk/dawn
+ // occasional small impulse (yawn) scaled down to keep things slow
+ setInterval(()=>{
+ if(crocos.length){ const c = crocos[Math.floor(Math.random()*crocos.length)]; if(c) { c.vx += rand(-0.8,0.8) * 0.2; c.vy += rand(-0.6,0.6) * 0.2; } }
+ }, 2200);
+
diff --git a/node_modules/.bin/browsers b/node_modules/.bin/browsers
new file mode 120000
index 0000000..645bb71
--- /dev/null
+++ b/node_modules/.bin/browsers
@@ -0,0 +1 @@
+../@puppeteer/browsers/lib/cjs/main-cli.js
\ No newline at end of file
diff --git a/node_modules/.bin/escodegen b/node_modules/.bin/escodegen
new file mode 120000
index 0000000..01a7c32
--- /dev/null
+++ b/node_modules/.bin/escodegen
@@ -0,0 +1 @@
+../escodegen/bin/escodegen.js
\ No newline at end of file
diff --git a/node_modules/.bin/esgenerate b/node_modules/.bin/esgenerate
new file mode 120000
index 0000000..7d0293e
--- /dev/null
+++ b/node_modules/.bin/esgenerate
@@ -0,0 +1 @@
+../escodegen/bin/esgenerate.js
\ No newline at end of file
diff --git a/node_modules/.bin/esparse b/node_modules/.bin/esparse
new file mode 120000
index 0000000..7423b18
--- /dev/null
+++ b/node_modules/.bin/esparse
@@ -0,0 +1 @@
+../esprima/bin/esparse.js
\ No newline at end of file
diff --git a/node_modules/.bin/esvalidate b/node_modules/.bin/esvalidate
new file mode 120000
index 0000000..16069ef
--- /dev/null
+++ b/node_modules/.bin/esvalidate
@@ -0,0 +1 @@
+../esprima/bin/esvalidate.js
\ No newline at end of file
diff --git a/node_modules/.bin/extract-zip b/node_modules/.bin/extract-zip
new file mode 120000
index 0000000..af9b561
--- /dev/null
+++ b/node_modules/.bin/extract-zip
@@ -0,0 +1 @@
+../extract-zip/cli.js
\ No newline at end of file
diff --git a/node_modules/.bin/js-yaml b/node_modules/.bin/js-yaml
new file mode 120000
index 0000000..9dbd010
--- /dev/null
+++ b/node_modules/.bin/js-yaml
@@ -0,0 +1 @@
+../js-yaml/bin/js-yaml.js
\ No newline at end of file
diff --git a/node_modules/.bin/puppeteer b/node_modules/.bin/puppeteer
new file mode 120000
index 0000000..833ff8d
--- /dev/null
+++ b/node_modules/.bin/puppeteer
@@ -0,0 +1 @@
+../puppeteer/lib/cjs/puppeteer/node/cli.js
\ No newline at end of file
diff --git a/node_modules/.bin/semver b/node_modules/.bin/semver
new file mode 120000
index 0000000..5aaadf4
--- /dev/null
+++ b/node_modules/.bin/semver
@@ -0,0 +1 @@
+../semver/bin/semver.js
\ No newline at end of file
diff --git a/node_modules/.package-lock.json b/node_modules/.package-lock.json
new file mode 100644
index 0000000..cfc5e2a
--- /dev/null
+++ b/node_modules/.package-lock.json
@@ -0,0 +1,1112 @@
+{
+ "name": "website",
+ "version": "1.0.0",
+ "lockfileVersion": 3,
+ "requires": true,
+ "packages": {
+ "node_modules/@babel/code-frame": {
+ "version": "7.27.1",
+ "resolved": "https://registry.npmjs.org/@babel/code-frame/-/code-frame-7.27.1.tgz",
+ "integrity": "sha512-cjQ7ZlQ0Mv3b47hABuTevyTuYN4i+loJKGeV9flcCgIK37cCXRh+L1bd3iBHlynerhQ7BhCkn2BPbQUL+rGqFg==",
+ "license": "MIT",
+ "dependencies": {
+ "@babel/helper-validator-identifier": "^7.27.1",
+ "js-tokens": "^4.0.0",
+ "picocolors": "^1.1.1"
+ },
+ "engines": {
+ "node": ">=6.9.0"
+ }
+ },
+ "node_modules/@babel/helper-validator-identifier": {
+ "version": "7.27.1",
+ "resolved": "https://registry.npmjs.org/@babel/helper-validator-identifier/-/helper-validator-identifier-7.27.1.tgz",
+ "integrity": "sha512-D2hP9eA+Sqx1kBZgzxZh0y1trbuU+JoDkiEwqhQ36nodYqJwyEIhPSdMNd7lOm/4io72luTPWH20Yda0xOuUow==",
+ "license": "MIT",
+ "engines": {
+ "node": ">=6.9.0"
+ }
+ },
+ "node_modules/@puppeteer/browsers": {
+ "version": "2.10.10",
+ "resolved": "https://registry.npmjs.org/@puppeteer/browsers/-/browsers-2.10.10.tgz",
+ "integrity": "sha512-3ZG500+ZeLql8rE0hjfhkycJjDj0pI/btEh3L9IkWUYcOrgP0xCNRq3HbtbqOPbvDhFaAWD88pDFtlLv8ns8gA==",
+ "license": "Apache-2.0",
+ "dependencies": {
+ "debug": "^4.4.3",
+ "extract-zip": "^2.0.1",
+ "progress": "^2.0.3",
+ "proxy-agent": "^6.5.0",
+ "semver": "^7.7.2",
+ "tar-fs": "^3.1.0",
+ "yargs": "^17.7.2"
+ },
+ "bin": {
+ "browsers": "lib/cjs/main-cli.js"
+ },
+ "engines": {
+ "node": ">=18"
+ }
+ },
+ "node_modules/@tootallnate/quickjs-emscripten": {
+ "version": "0.23.0",
+ "resolved": "https://registry.npmjs.org/@tootallnate/quickjs-emscripten/-/quickjs-emscripten-0.23.0.tgz",
+ "integrity": "sha512-C5Mc6rdnsaJDjO3UpGW/CQTHtCKaYlScZTly4JIu97Jxo/odCiH0ITnDXSJPTOrEKk/ycSZ0AOgTmkDtkOsvIA==",
+ "license": "MIT"
+ },
+ "node_modules/@types/node": {
+ "version": "24.7.0",
+ "resolved": "https://registry.npmjs.org/@types/node/-/node-24.7.0.tgz",
+ "integrity": "sha512-IbKooQVqUBrlzWTi79E8Fw78l8k1RNtlDDNWsFZs7XonuQSJ8oNYfEeclhprUldXISRMLzBpILuKgPlIxm+/Yw==",
+ "license": "MIT",
+ "optional": true,
+ "dependencies": {
+ "undici-types": "~7.14.0"
+ }
+ },
+ "node_modules/@types/yauzl": {
+ "version": "2.10.3",
+ "resolved": "https://registry.npmjs.org/@types/yauzl/-/yauzl-2.10.3.tgz",
+ "integrity": "sha512-oJoftv0LSuaDZE3Le4DbKX+KS9G36NzOeSap90UIK0yMA/NhKJhqlSGtNDORNRaIbQfzjXDrQa0ytJ6mNRGz/Q==",
+ "license": "MIT",
+ "optional": true,
+ "dependencies": {
+ "@types/node": "*"
+ }
+ },
+ "node_modules/agent-base": {
+ "version": "7.1.4",
+ "resolved": "https://registry.npmjs.org/agent-base/-/agent-base-7.1.4.tgz",
+ "integrity": "sha512-MnA+YT8fwfJPgBx3m60MNqakm30XOkyIoH1y6huTQvC0PwZG7ki8NacLBcrPbNoo8vEZy7Jpuk7+jMO+CUovTQ==",
+ "license": "MIT",
+ "engines": {
+ "node": ">= 14"
+ }
+ },
+ "node_modules/ansi-regex": {
+ "version": "5.0.1",
+ "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-5.0.1.tgz",
+ "integrity": "sha512-quJQXlTSUGL2LH9SUXo8VwsY4soanhgo6LNSm84E1LBcE8s3O0wpdiRzyR9z/ZZJMlMWv37qOOb9pdJlMUEKFQ==",
+ "license": "MIT",
+ "engines": {
+ "node": ">=8"
+ }
+ },
+ "node_modules/ansi-styles": {
+ "version": "4.3.0",
+ "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz",
+ "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==",
+ "license": "MIT",
+ "dependencies": {
+ "color-convert": "^2.0.1"
+ },
+ "engines": {
+ "node": ">=8"
+ },
+ "funding": {
+ "url": "https://github.com/chalk/ansi-styles?sponsor=1"
+ }
+ },
+ "node_modules/argparse": {
+ "version": "2.0.1",
+ "resolved": "https://registry.npmjs.org/argparse/-/argparse-2.0.1.tgz",
+ "integrity": "sha512-8+9WqebbFzpX9OR+Wa6O29asIogeRMzcGtAINdpMHHyAg10f05aSFVBbcEqGf/PXw1EjAZ+q2/bEBg3DvurK3Q==",
+ "license": "Python-2.0"
+ },
+ "node_modules/ast-types": {
+ "version": "0.13.4",
+ "resolved": "https://registry.npmjs.org/ast-types/-/ast-types-0.13.4.tgz",
+ "integrity": "sha512-x1FCFnFifvYDDzTaLII71vG5uvDwgtmDTEVWAxrgeiR8VjMONcCXJx7E+USjDtHlwFmt9MysbqgF9b9Vjr6w+w==",
+ "license": "MIT",
+ "dependencies": {
+ "tslib": "^2.0.1"
+ },
+ "engines": {
+ "node": ">=4"
+ }
+ },
+ "node_modules/b4a": {
+ "version": "1.7.3",
+ "resolved": "https://registry.npmjs.org/b4a/-/b4a-1.7.3.tgz",
+ "integrity": "sha512-5Q2mfq2WfGuFp3uS//0s6baOJLMoVduPYVeNmDYxu5OUA1/cBfvr2RIS7vi62LdNj/urk1hfmj867I3qt6uZ7Q==",
+ "license": "Apache-2.0",
+ "peerDependencies": {
+ "react-native-b4a": "*"
+ },
+ "peerDependenciesMeta": {
+ "react-native-b4a": {
+ "optional": true
+ }
+ }
+ },
+ "node_modules/bare-events": {
+ "version": "2.7.0",
+ "resolved": "https://registry.npmjs.org/bare-events/-/bare-events-2.7.0.tgz",
+ "integrity": "sha512-b3N5eTW1g7vXkw+0CXh/HazGTcO5KYuu/RCNaJbDMPI6LHDi+7qe8EmxKUVe1sUbY2KZOVZFyj62x0OEz9qyAA==",
+ "license": "Apache-2.0"
+ },
+ "node_modules/bare-fs": {
+ "version": "4.4.5",
+ "resolved": "https://registry.npmjs.org/bare-fs/-/bare-fs-4.4.5.tgz",
+ "integrity": "sha512-TCtu93KGLu6/aiGWzMr12TmSRS6nKdfhAnzTQRbXoSWxkbb9eRd53jQ51jG7g1gYjjtto3hbBrrhzg6djcgiKg==",
+ "license": "Apache-2.0",
+ "optional": true,
+ "dependencies": {
+ "bare-events": "^2.5.4",
+ "bare-path": "^3.0.0",
+ "bare-stream": "^2.6.4",
+ "bare-url": "^2.2.2",
+ "fast-fifo": "^1.3.2"
+ },
+ "engines": {
+ "bare": ">=1.16.0"
+ },
+ "peerDependencies": {
+ "bare-buffer": "*"
+ },
+ "peerDependenciesMeta": {
+ "bare-buffer": {
+ "optional": true
+ }
+ }
+ },
+ "node_modules/bare-os": {
+ "version": "3.6.2",
+ "resolved": "https://registry.npmjs.org/bare-os/-/bare-os-3.6.2.tgz",
+ "integrity": "sha512-T+V1+1srU2qYNBmJCXZkUY5vQ0B4FSlL3QDROnKQYOqeiQR8UbjNHlPa+TIbM4cuidiN9GaTaOZgSEgsvPbh5A==",
+ "license": "Apache-2.0",
+ "optional": true,
+ "engines": {
+ "bare": ">=1.14.0"
+ }
+ },
+ "node_modules/bare-path": {
+ "version": "3.0.0",
+ "resolved": "https://registry.npmjs.org/bare-path/-/bare-path-3.0.0.tgz",
+ "integrity": "sha512-tyfW2cQcB5NN8Saijrhqn0Zh7AnFNsnczRcuWODH0eYAXBsJ5gVxAUuNr7tsHSC6IZ77cA0SitzT+s47kot8Mw==",
+ "license": "Apache-2.0",
+ "optional": true,
+ "dependencies": {
+ "bare-os": "^3.0.1"
+ }
+ },
+ "node_modules/bare-stream": {
+ "version": "2.7.0",
+ "resolved": "https://registry.npmjs.org/bare-stream/-/bare-stream-2.7.0.tgz",
+ "integrity": "sha512-oyXQNicV1y8nc2aKffH+BUHFRXmx6VrPzlnaEvMhram0nPBrKcEdcyBg5r08D0i8VxngHFAiVyn1QKXpSG0B8A==",
+ "license": "Apache-2.0",
+ "optional": true,
+ "dependencies": {
+ "streamx": "^2.21.0"
+ },
+ "peerDependencies": {
+ "bare-buffer": "*",
+ "bare-events": "*"
+ },
+ "peerDependenciesMeta": {
+ "bare-buffer": {
+ "optional": true
+ },
+ "bare-events": {
+ "optional": true
+ }
+ }
+ },
+ "node_modules/bare-url": {
+ "version": "2.2.2",
+ "resolved": "https://registry.npmjs.org/bare-url/-/bare-url-2.2.2.tgz",
+ "integrity": "sha512-g+ueNGKkrjMazDG3elZO1pNs3HY5+mMmOet1jtKyhOaCnkLzitxf26z7hoAEkDNgdNmnc1KIlt/dw6Po6xZMpA==",
+ "license": "Apache-2.0",
+ "optional": true,
+ "dependencies": {
+ "bare-path": "^3.0.0"
+ }
+ },
+ "node_modules/basic-ftp": {
+ "version": "5.0.5",
+ "resolved": "https://registry.npmjs.org/basic-ftp/-/basic-ftp-5.0.5.tgz",
+ "integrity": "sha512-4Bcg1P8xhUuqcii/S0Z9wiHIrQVPMermM1any+MX5GeGD7faD3/msQUDGLol9wOcz4/jbg/WJnGqoJF6LiBdtg==",
+ "license": "MIT",
+ "engines": {
+ "node": ">=10.0.0"
+ }
+ },
+ "node_modules/buffer-crc32": {
+ "version": "0.2.13",
+ "resolved": "https://registry.npmjs.org/buffer-crc32/-/buffer-crc32-0.2.13.tgz",
+ "integrity": "sha512-VO9Ht/+p3SN7SKWqcrgEzjGbRSJYTx+Q1pTQC0wrWqHx0vpJraQ6GtHx8tvcg1rlK1byhU5gccxgOgj7B0TDkQ==",
+ "license": "MIT",
+ "engines": {
+ "node": "*"
+ }
+ },
+ "node_modules/callsites": {
+ "version": "3.1.0",
+ "resolved": "https://registry.npmjs.org/callsites/-/callsites-3.1.0.tgz",
+ "integrity": "sha512-P8BjAsXvZS+VIDUI11hHCQEv74YT67YUi5JJFNWIqL235sBmjX4+qx9Muvls5ivyNENctx46xQLQ3aTuE7ssaQ==",
+ "license": "MIT",
+ "engines": {
+ "node": ">=6"
+ }
+ },
+ "node_modules/chromium-bidi": {
+ "version": "9.1.0",
+ "resolved": "https://registry.npmjs.org/chromium-bidi/-/chromium-bidi-9.1.0.tgz",
+ "integrity": "sha512-rlUzQ4WzIAWdIbY/viPShhZU2n21CxDUgazXVbw4Hu1MwaeUSEksSeM6DqPgpRjCLXRk702AVRxJxoOz0dw4OA==",
+ "license": "Apache-2.0",
+ "dependencies": {
+ "mitt": "^3.0.1",
+ "zod": "^3.24.1"
+ },
+ "peerDependencies": {
+ "devtools-protocol": "*"
+ }
+ },
+ "node_modules/cliui": {
+ "version": "8.0.1",
+ "resolved": "https://registry.npmjs.org/cliui/-/cliui-8.0.1.tgz",
+ "integrity": "sha512-BSeNnyus75C4//NQ9gQt1/csTXyo/8Sb+afLAkzAptFuMsod9HFokGNudZpi/oQV73hnVK+sR+5PVRMd+Dr7YQ==",
+ "license": "ISC",
+ "dependencies": {
+ "string-width": "^4.2.0",
+ "strip-ansi": "^6.0.1",
+ "wrap-ansi": "^7.0.0"
+ },
+ "engines": {
+ "node": ">=12"
+ }
+ },
+ "node_modules/color-convert": {
+ "version": "2.0.1",
+ "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz",
+ "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==",
+ "license": "MIT",
+ "dependencies": {
+ "color-name": "~1.1.4"
+ },
+ "engines": {
+ "node": ">=7.0.0"
+ }
+ },
+ "node_modules/color-name": {
+ "version": "1.1.4",
+ "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz",
+ "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==",
+ "license": "MIT"
+ },
+ "node_modules/cosmiconfig": {
+ "version": "9.0.0",
+ "resolved": "https://registry.npmjs.org/cosmiconfig/-/cosmiconfig-9.0.0.tgz",
+ "integrity": "sha512-itvL5h8RETACmOTFc4UfIyB2RfEHi71Ax6E/PivVxq9NseKbOWpeyHEOIbmAw1rs8Ak0VursQNww7lf7YtUwzg==",
+ "license": "MIT",
+ "dependencies": {
+ "env-paths": "^2.2.1",
+ "import-fresh": "^3.3.0",
+ "js-yaml": "^4.1.0",
+ "parse-json": "^5.2.0"
+ },
+ "engines": {
+ "node": ">=14"
+ },
+ "funding": {
+ "url": "https://github.com/sponsors/d-fischer"
+ },
+ "peerDependencies": {
+ "typescript": ">=4.9.5"
+ },
+ "peerDependenciesMeta": {
+ "typescript": {
+ "optional": true
+ }
+ }
+ },
+ "node_modules/data-uri-to-buffer": {
+ "version": "6.0.2",
+ "resolved": "https://registry.npmjs.org/data-uri-to-buffer/-/data-uri-to-buffer-6.0.2.tgz",
+ "integrity": "sha512-7hvf7/GW8e86rW0ptuwS3OcBGDjIi6SZva7hCyWC0yYry2cOPmLIjXAUHI6DK2HsnwJd9ifmt57i8eV2n4YNpw==",
+ "license": "MIT",
+ "engines": {
+ "node": ">= 14"
+ }
+ },
+ "node_modules/debug": {
+ "version": "4.4.3",
+ "resolved": "https://registry.npmjs.org/debug/-/debug-4.4.3.tgz",
+ "integrity": "sha512-RGwwWnwQvkVfavKVt22FGLw+xYSdzARwm0ru6DhTVA3umU5hZc28V3kO4stgYryrTlLpuvgI9GiijltAjNbcqA==",
+ "license": "MIT",
+ "dependencies": {
+ "ms": "^2.1.3"
+ },
+ "engines": {
+ "node": ">=6.0"
+ },
+ "peerDependenciesMeta": {
+ "supports-color": {
+ "optional": true
+ }
+ }
+ },
+ "node_modules/degenerator": {
+ "version": "5.0.1",
+ "resolved": "https://registry.npmjs.org/degenerator/-/degenerator-5.0.1.tgz",
+ "integrity": "sha512-TllpMR/t0M5sqCXfj85i4XaAzxmS5tVA16dqvdkMwGmzI+dXLXnw3J+3Vdv7VKw+ThlTMboK6i9rnZ6Nntj5CQ==",
+ "license": "MIT",
+ "dependencies": {
+ "ast-types": "^0.13.4",
+ "escodegen": "^2.1.0",
+ "esprima": "^4.0.1"
+ },
+ "engines": {
+ "node": ">= 14"
+ }
+ },
+ "node_modules/devtools-protocol": {
+ "version": "0.0.1508733",
+ "resolved": "https://registry.npmjs.org/devtools-protocol/-/devtools-protocol-0.0.1508733.tgz",
+ "integrity": "sha512-QJ1R5gtck6nDcdM+nlsaJXcelPEI7ZxSMw1ujHpO1c4+9l+Nue5qlebi9xO1Z2MGr92bFOQTW7/rrheh5hHxDg==",
+ "license": "BSD-3-Clause",
+ "peer": true
+ },
+ "node_modules/emoji-regex": {
+ "version": "8.0.0",
+ "resolved": "https://registry.npmjs.org/emoji-regex/-/emoji-regex-8.0.0.tgz",
+ "integrity": "sha512-MSjYzcWNOA0ewAHpz0MxpYFvwg6yjy1NG3xteoqz644VCo/RPgnr1/GGt+ic3iJTzQ8Eu3TdM14SawnVUmGE6A==",
+ "license": "MIT"
+ },
+ "node_modules/end-of-stream": {
+ "version": "1.4.5",
+ "resolved": "https://registry.npmjs.org/end-of-stream/-/end-of-stream-1.4.5.tgz",
+ "integrity": "sha512-ooEGc6HP26xXq/N+GCGOT0JKCLDGrq2bQUZrQ7gyrJiZANJ/8YDTxTpQBXGMn+WbIQXNVpyWymm7KYVICQnyOg==",
+ "license": "MIT",
+ "dependencies": {
+ "once": "^1.4.0"
+ }
+ },
+ "node_modules/env-paths": {
+ "version": "2.2.1",
+ "resolved": "https://registry.npmjs.org/env-paths/-/env-paths-2.2.1.tgz",
+ "integrity": "sha512-+h1lkLKhZMTYjog1VEpJNG7NZJWcuc2DDk/qsqSTRRCOXiLjeQ1d1/udrUGhqMxUgAlwKNZ0cf2uqan5GLuS2A==",
+ "license": "MIT",
+ "engines": {
+ "node": ">=6"
+ }
+ },
+ "node_modules/error-ex": {
+ "version": "1.3.4",
+ "resolved": "https://registry.npmjs.org/error-ex/-/error-ex-1.3.4.tgz",
+ "integrity": "sha512-sqQamAnR14VgCr1A618A3sGrygcpK+HEbenA/HiEAkkUwcZIIB/tgWqHFxWgOyDh4nB4JCRimh79dR5Ywc9MDQ==",
+ "license": "MIT",
+ "dependencies": {
+ "is-arrayish": "^0.2.1"
+ }
+ },
+ "node_modules/escalade": {
+ "version": "3.2.0",
+ "resolved": "https://registry.npmjs.org/escalade/-/escalade-3.2.0.tgz",
+ "integrity": "sha512-WUj2qlxaQtO4g6Pq5c29GTcWGDyd8itL8zTlipgECz3JesAiiOKotd8JU6otB3PACgG6xkJUyVhboMS+bje/jA==",
+ "license": "MIT",
+ "engines": {
+ "node": ">=6"
+ }
+ },
+ "node_modules/escodegen": {
+ "version": "2.1.0",
+ "resolved": "https://registry.npmjs.org/escodegen/-/escodegen-2.1.0.tgz",
+ "integrity": "sha512-2NlIDTwUWJN0mRPQOdtQBzbUHvdGY2P1VXSyU83Q3xKxM7WHX2Ql8dKq782Q9TgQUNOLEzEYu9bzLNj1q88I5w==",
+ "license": "BSD-2-Clause",
+ "dependencies": {
+ "esprima": "^4.0.1",
+ "estraverse": "^5.2.0",
+ "esutils": "^2.0.2"
+ },
+ "bin": {
+ "escodegen": "bin/escodegen.js",
+ "esgenerate": "bin/esgenerate.js"
+ },
+ "engines": {
+ "node": ">=6.0"
+ },
+ "optionalDependencies": {
+ "source-map": "~0.6.1"
+ }
+ },
+ "node_modules/esprima": {
+ "version": "4.0.1",
+ "resolved": "https://registry.npmjs.org/esprima/-/esprima-4.0.1.tgz",
+ "integrity": "sha512-eGuFFw7Upda+g4p+QHvnW0RyTX/SVeJBDM/gCtMARO0cLuT2HcEKnTPvhjV6aGeqrCB/sbNop0Kszm0jsaWU4A==",
+ "license": "BSD-2-Clause",
+ "bin": {
+ "esparse": "bin/esparse.js",
+ "esvalidate": "bin/esvalidate.js"
+ },
+ "engines": {
+ "node": ">=4"
+ }
+ },
+ "node_modules/estraverse": {
+ "version": "5.3.0",
+ "resolved": "https://registry.npmjs.org/estraverse/-/estraverse-5.3.0.tgz",
+ "integrity": "sha512-MMdARuVEQziNTeJD8DgMqmhwR11BRQ/cBP+pLtYdSTnf3MIO8fFeiINEbX36ZdNlfU/7A9f3gUw49B3oQsvwBA==",
+ "license": "BSD-2-Clause",
+ "engines": {
+ "node": ">=4.0"
+ }
+ },
+ "node_modules/esutils": {
+ "version": "2.0.3",
+ "resolved": "https://registry.npmjs.org/esutils/-/esutils-2.0.3.tgz",
+ "integrity": "sha512-kVscqXk4OCp68SZ0dkgEKVi6/8ij300KBWTJq32P/dYeWTSwK41WyTxalN1eRmA5Z9UU/LX9D7FWSmV9SAYx6g==",
+ "license": "BSD-2-Clause",
+ "engines": {
+ "node": ">=0.10.0"
+ }
+ },
+ "node_modules/events-universal": {
+ "version": "1.0.1",
+ "resolved": "https://registry.npmjs.org/events-universal/-/events-universal-1.0.1.tgz",
+ "integrity": "sha512-LUd5euvbMLpwOF8m6ivPCbhQeSiYVNb8Vs0fQ8QjXo0JTkEHpz8pxdQf0gStltaPpw0Cca8b39KxvK9cfKRiAw==",
+ "license": "Apache-2.0",
+ "dependencies": {
+ "bare-events": "^2.7.0"
+ }
+ },
+ "node_modules/extract-zip": {
+ "version": "2.0.1",
+ "resolved": "https://registry.npmjs.org/extract-zip/-/extract-zip-2.0.1.tgz",
+ "integrity": "sha512-GDhU9ntwuKyGXdZBUgTIe+vXnWj0fppUEtMDL0+idd5Sta8TGpHssn/eusA9mrPr9qNDym6SxAYZjNvCn/9RBg==",
+ "license": "BSD-2-Clause",
+ "dependencies": {
+ "debug": "^4.1.1",
+ "get-stream": "^5.1.0",
+ "yauzl": "^2.10.0"
+ },
+ "bin": {
+ "extract-zip": "cli.js"
+ },
+ "engines": {
+ "node": ">= 10.17.0"
+ },
+ "optionalDependencies": {
+ "@types/yauzl": "^2.9.1"
+ }
+ },
+ "node_modules/fast-fifo": {
+ "version": "1.3.2",
+ "resolved": "https://registry.npmjs.org/fast-fifo/-/fast-fifo-1.3.2.tgz",
+ "integrity": "sha512-/d9sfos4yxzpwkDkuN7k2SqFKtYNmCTzgfEpz82x34IM9/zc8KGxQoXg1liNC/izpRM/MBdt44Nmx41ZWqk+FQ==",
+ "license": "MIT"
+ },
+ "node_modules/fd-slicer": {
+ "version": "1.1.0",
+ "resolved": "https://registry.npmjs.org/fd-slicer/-/fd-slicer-1.1.0.tgz",
+ "integrity": "sha512-cE1qsB/VwyQozZ+q1dGxR8LBYNZeofhEdUNGSMbQD3Gw2lAzX9Zb3uIU6Ebc/Fmyjo9AWWfnn0AUCHqtevs/8g==",
+ "license": "MIT",
+ "dependencies": {
+ "pend": "~1.2.0"
+ }
+ },
+ "node_modules/get-caller-file": {
+ "version": "2.0.5",
+ "resolved": "https://registry.npmjs.org/get-caller-file/-/get-caller-file-2.0.5.tgz",
+ "integrity": "sha512-DyFP3BM/3YHTQOCUL/w0OZHR0lpKeGrxotcHWcqNEdnltqFwXVfhEBQ94eIo34AfQpo0rGki4cyIiftY06h2Fg==",
+ "license": "ISC",
+ "engines": {
+ "node": "6.* || 8.* || >= 10.*"
+ }
+ },
+ "node_modules/get-stream": {
+ "version": "5.2.0",
+ "resolved": "https://registry.npmjs.org/get-stream/-/get-stream-5.2.0.tgz",
+ "integrity": "sha512-nBF+F1rAZVCu/p7rjzgA+Yb4lfYXrpl7a6VmJrU8wF9I1CKvP/QwPNZHnOlwbTkY6dvtFIzFMSyQXbLoTQPRpA==",
+ "license": "MIT",
+ "dependencies": {
+ "pump": "^3.0.0"
+ },
+ "engines": {
+ "node": ">=8"
+ },
+ "funding": {
+ "url": "https://github.com/sponsors/sindresorhus"
+ }
+ },
+ "node_modules/get-uri": {
+ "version": "6.0.5",
+ "resolved": "https://registry.npmjs.org/get-uri/-/get-uri-6.0.5.tgz",
+ "integrity": "sha512-b1O07XYq8eRuVzBNgJLstU6FYc1tS6wnMtF1I1D9lE8LxZSOGZ7LhxN54yPP6mGw5f2CkXY2BQUL9Fx41qvcIg==",
+ "license": "MIT",
+ "dependencies": {
+ "basic-ftp": "^5.0.2",
+ "data-uri-to-buffer": "^6.0.2",
+ "debug": "^4.3.4"
+ },
+ "engines": {
+ "node": ">= 14"
+ }
+ },
+ "node_modules/http-proxy-agent": {
+ "version": "7.0.2",
+ "resolved": "https://registry.npmjs.org/http-proxy-agent/-/http-proxy-agent-7.0.2.tgz",
+ "integrity": "sha512-T1gkAiYYDWYx3V5Bmyu7HcfcvL7mUrTWiM6yOfa3PIphViJ/gFPbvidQ+veqSOHci/PxBcDabeUNCzpOODJZig==",
+ "license": "MIT",
+ "dependencies": {
+ "agent-base": "^7.1.0",
+ "debug": "^4.3.4"
+ },
+ "engines": {
+ "node": ">= 14"
+ }
+ },
+ "node_modules/https-proxy-agent": {
+ "version": "7.0.6",
+ "resolved": "https://registry.npmjs.org/https-proxy-agent/-/https-proxy-agent-7.0.6.tgz",
+ "integrity": "sha512-vK9P5/iUfdl95AI+JVyUuIcVtd4ofvtrOr3HNtM2yxC9bnMbEdp3x01OhQNnjb8IJYi38VlTE3mBXwcfvywuSw==",
+ "license": "MIT",
+ "dependencies": {
+ "agent-base": "^7.1.2",
+ "debug": "4"
+ },
+ "engines": {
+ "node": ">= 14"
+ }
+ },
+ "node_modules/import-fresh": {
+ "version": "3.3.1",
+ "resolved": "https://registry.npmjs.org/import-fresh/-/import-fresh-3.3.1.tgz",
+ "integrity": "sha512-TR3KfrTZTYLPB6jUjfx6MF9WcWrHL9su5TObK4ZkYgBdWKPOFoSoQIdEuTuR82pmtxH2spWG9h6etwfr1pLBqQ==",
+ "license": "MIT",
+ "dependencies": {
+ "parent-module": "^1.0.0",
+ "resolve-from": "^4.0.0"
+ },
+ "engines": {
+ "node": ">=6"
+ },
+ "funding": {
+ "url": "https://github.com/sponsors/sindresorhus"
+ }
+ },
+ "node_modules/ip-address": {
+ "version": "10.0.1",
+ "resolved": "https://registry.npmjs.org/ip-address/-/ip-address-10.0.1.tgz",
+ "integrity": "sha512-NWv9YLW4PoW2B7xtzaS3NCot75m6nK7Icdv0o3lfMceJVRfSoQwqD4wEH5rLwoKJwUiZ/rfpiVBhnaF0FK4HoA==",
+ "license": "MIT",
+ "engines": {
+ "node": ">= 12"
+ }
+ },
+ "node_modules/is-arrayish": {
+ "version": "0.2.1",
+ "resolved": "https://registry.npmjs.org/is-arrayish/-/is-arrayish-0.2.1.tgz",
+ "integrity": "sha512-zz06S8t0ozoDXMG+ube26zeCTNXcKIPJZJi8hBrF4idCLms4CG9QtK7qBl1boi5ODzFpjswb5JPmHCbMpjaYzg==",
+ "license": "MIT"
+ },
+ "node_modules/is-fullwidth-code-point": {
+ "version": "3.0.0",
+ "resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-3.0.0.tgz",
+ "integrity": "sha512-zymm5+u+sCsSWyD9qNaejV3DFvhCKclKdizYaJUuHA83RLjb7nSuGnddCHGv0hk+KY7BMAlsWeK4Ueg6EV6XQg==",
+ "license": "MIT",
+ "engines": {
+ "node": ">=8"
+ }
+ },
+ "node_modules/js-tokens": {
+ "version": "4.0.0",
+ "resolved": "https://registry.npmjs.org/js-tokens/-/js-tokens-4.0.0.tgz",
+ "integrity": "sha512-RdJUflcE3cUzKiMqQgsCu06FPu9UdIJO0beYbPhHN4k6apgJtifcoCtT9bcxOpYBtpD2kCM6Sbzg4CausW/PKQ==",
+ "license": "MIT"
+ },
+ "node_modules/js-yaml": {
+ "version": "4.1.0",
+ "resolved": "https://registry.npmjs.org/js-yaml/-/js-yaml-4.1.0.tgz",
+ "integrity": "sha512-wpxZs9NoxZaJESJGIZTyDEaYpl0FKSA+FB9aJiyemKhMwkxQg63h4T1KJgUGHpTqPDNRcmmYLugrRjJlBtWvRA==",
+ "license": "MIT",
+ "dependencies": {
+ "argparse": "^2.0.1"
+ },
+ "bin": {
+ "js-yaml": "bin/js-yaml.js"
+ }
+ },
+ "node_modules/json-parse-even-better-errors": {
+ "version": "2.3.1",
+ "resolved": "https://registry.npmjs.org/json-parse-even-better-errors/-/json-parse-even-better-errors-2.3.1.tgz",
+ "integrity": "sha512-xyFwyhro/JEof6Ghe2iz2NcXoj2sloNsWr/XsERDK/oiPCfaNhl5ONfp+jQdAZRQQ0IJWNzH9zIZF7li91kh2w==",
+ "license": "MIT"
+ },
+ "node_modules/lines-and-columns": {
+ "version": "1.2.4",
+ "resolved": "https://registry.npmjs.org/lines-and-columns/-/lines-and-columns-1.2.4.tgz",
+ "integrity": "sha512-7ylylesZQ/PV29jhEDl3Ufjo6ZX7gCqJr5F7PKrqc93v7fzSymt1BpwEU8nAUXs8qzzvqhbjhK5QZg6Mt/HkBg==",
+ "license": "MIT"
+ },
+ "node_modules/lru-cache": {
+ "version": "7.18.3",
+ "resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-7.18.3.tgz",
+ "integrity": "sha512-jumlc0BIUrS3qJGgIkWZsyfAM7NCWiBcCDhnd+3NNM5KbBmLTgHVfWBcg6W+rLUsIpzpERPsvwUP7CckAQSOoA==",
+ "license": "ISC",
+ "engines": {
+ "node": ">=12"
+ }
+ },
+ "node_modules/mitt": {
+ "version": "3.0.1",
+ "resolved": "https://registry.npmjs.org/mitt/-/mitt-3.0.1.tgz",
+ "integrity": "sha512-vKivATfr97l2/QBCYAkXYDbrIWPM2IIKEl7YPhjCvKlG3kE2gm+uBo6nEXK3M5/Ffh/FLpKExzOQ3JJoJGFKBw==",
+ "license": "MIT"
+ },
+ "node_modules/ms": {
+ "version": "2.1.3",
+ "resolved": "https://registry.npmjs.org/ms/-/ms-2.1.3.tgz",
+ "integrity": "sha512-6FlzubTLZG3J2a/NVCAleEhjzq5oxgHyaCU9yYXvcLsvoVaHJq/s5xXI6/XXP6tz7R9xAOtHnSO/tXtF3WRTlA==",
+ "license": "MIT"
+ },
+ "node_modules/netmask": {
+ "version": "2.0.2",
+ "resolved": "https://registry.npmjs.org/netmask/-/netmask-2.0.2.tgz",
+ "integrity": "sha512-dBpDMdxv9Irdq66304OLfEmQ9tbNRFnFTuZiLo+bD+r332bBmMJ8GBLXklIXXgxd3+v9+KUnZaUR5PJMa75Gsg==",
+ "license": "MIT",
+ "engines": {
+ "node": ">= 0.4.0"
+ }
+ },
+ "node_modules/once": {
+ "version": "1.4.0",
+ "resolved": "https://registry.npmjs.org/once/-/once-1.4.0.tgz",
+ "integrity": "sha512-lNaJgI+2Q5URQBkccEKHTQOPaXdUxnZZElQTZY0MFUAuaEqe1E+Nyvgdz/aIyNi6Z9MzO5dv1H8n58/GELp3+w==",
+ "license": "ISC",
+ "dependencies": {
+ "wrappy": "1"
+ }
+ },
+ "node_modules/pac-proxy-agent": {
+ "version": "7.2.0",
+ "resolved": "https://registry.npmjs.org/pac-proxy-agent/-/pac-proxy-agent-7.2.0.tgz",
+ "integrity": "sha512-TEB8ESquiLMc0lV8vcd5Ql/JAKAoyzHFXaStwjkzpOpC5Yv+pIzLfHvjTSdf3vpa2bMiUQrg9i6276yn8666aA==",
+ "license": "MIT",
+ "dependencies": {
+ "@tootallnate/quickjs-emscripten": "^0.23.0",
+ "agent-base": "^7.1.2",
+ "debug": "^4.3.4",
+ "get-uri": "^6.0.1",
+ "http-proxy-agent": "^7.0.0",
+ "https-proxy-agent": "^7.0.6",
+ "pac-resolver": "^7.0.1",
+ "socks-proxy-agent": "^8.0.5"
+ },
+ "engines": {
+ "node": ">= 14"
+ }
+ },
+ "node_modules/pac-resolver": {
+ "version": "7.0.1",
+ "resolved": "https://registry.npmjs.org/pac-resolver/-/pac-resolver-7.0.1.tgz",
+ "integrity": "sha512-5NPgf87AT2STgwa2ntRMr45jTKrYBGkVU36yT0ig/n/GMAa3oPqhZfIQ2kMEimReg0+t9kZViDVZ83qfVUlckg==",
+ "license": "MIT",
+ "dependencies": {
+ "degenerator": "^5.0.0",
+ "netmask": "^2.0.2"
+ },
+ "engines": {
+ "node": ">= 14"
+ }
+ },
+ "node_modules/parent-module": {
+ "version": "1.0.1",
+ "resolved": "https://registry.npmjs.org/parent-module/-/parent-module-1.0.1.tgz",
+ "integrity": "sha512-GQ2EWRpQV8/o+Aw8YqtfZZPfNRWZYkbidE9k5rpl/hC3vtHHBfGm2Ifi6qWV+coDGkrUKZAxE3Lot5kcsRlh+g==",
+ "license": "MIT",
+ "dependencies": {
+ "callsites": "^3.0.0"
+ },
+ "engines": {
+ "node": ">=6"
+ }
+ },
+ "node_modules/parse-json": {
+ "version": "5.2.0",
+ "resolved": "https://registry.npmjs.org/parse-json/-/parse-json-5.2.0.tgz",
+ "integrity": "sha512-ayCKvm/phCGxOkYRSCM82iDwct8/EonSEgCSxWxD7ve6jHggsFl4fZVQBPRNgQoKiuV/odhFrGzQXZwbifC8Rg==",
+ "license": "MIT",
+ "dependencies": {
+ "@babel/code-frame": "^7.0.0",
+ "error-ex": "^1.3.1",
+ "json-parse-even-better-errors": "^2.3.0",
+ "lines-and-columns": "^1.1.6"
+ },
+ "engines": {
+ "node": ">=8"
+ },
+ "funding": {
+ "url": "https://github.com/sponsors/sindresorhus"
+ }
+ },
+ "node_modules/pend": {
+ "version": "1.2.0",
+ "resolved": "https://registry.npmjs.org/pend/-/pend-1.2.0.tgz",
+ "integrity": "sha512-F3asv42UuXchdzt+xXqfW1OGlVBe+mxa2mqI0pg5yAHZPvFmY3Y6drSf/GQ1A86WgWEN9Kzh/WrgKa6iGcHXLg==",
+ "license": "MIT"
+ },
+ "node_modules/picocolors": {
+ "version": "1.1.1",
+ "resolved": "https://registry.npmjs.org/picocolors/-/picocolors-1.1.1.tgz",
+ "integrity": "sha512-xceH2snhtb5M9liqDsmEw56le376mTZkEX/jEb/RxNFyegNul7eNslCXP9FDj/Lcu0X8KEyMceP2ntpaHrDEVA==",
+ "license": "ISC"
+ },
+ "node_modules/progress": {
+ "version": "2.0.3",
+ "resolved": "https://registry.npmjs.org/progress/-/progress-2.0.3.tgz",
+ "integrity": "sha512-7PiHtLll5LdnKIMw100I+8xJXR5gW2QwWYkT6iJva0bXitZKa/XMrSbdmg3r2Xnaidz9Qumd0VPaMrZlF9V9sA==",
+ "license": "MIT",
+ "engines": {
+ "node": ">=0.4.0"
+ }
+ },
+ "node_modules/proxy-agent": {
+ "version": "6.5.0",
+ "resolved": "https://registry.npmjs.org/proxy-agent/-/proxy-agent-6.5.0.tgz",
+ "integrity": "sha512-TmatMXdr2KlRiA2CyDu8GqR8EjahTG3aY3nXjdzFyoZbmB8hrBsTyMezhULIXKnC0jpfjlmiZ3+EaCzoInSu/A==",
+ "license": "MIT",
+ "dependencies": {
+ "agent-base": "^7.1.2",
+ "debug": "^4.3.4",
+ "http-proxy-agent": "^7.0.1",
+ "https-proxy-agent": "^7.0.6",
+ "lru-cache": "^7.14.1",
+ "pac-proxy-agent": "^7.1.0",
+ "proxy-from-env": "^1.1.0",
+ "socks-proxy-agent": "^8.0.5"
+ },
+ "engines": {
+ "node": ">= 14"
+ }
+ },
+ "node_modules/proxy-from-env": {
+ "version": "1.1.0",
+ "resolved": "https://registry.npmjs.org/proxy-from-env/-/proxy-from-env-1.1.0.tgz",
+ "integrity": "sha512-D+zkORCbA9f1tdWRK0RaCR3GPv50cMxcrz4X8k5LTSUD1Dkw47mKJEZQNunItRTkWwgtaUSo1RVFRIG9ZXiFYg==",
+ "license": "MIT"
+ },
+ "node_modules/pump": {
+ "version": "3.0.3",
+ "resolved": "https://registry.npmjs.org/pump/-/pump-3.0.3.tgz",
+ "integrity": "sha512-todwxLMY7/heScKmntwQG8CXVkWUOdYxIvY2s0VWAAMh/nd8SoYiRaKjlr7+iCs984f2P8zvrfWcDDYVb73NfA==",
+ "license": "MIT",
+ "dependencies": {
+ "end-of-stream": "^1.1.0",
+ "once": "^1.3.1"
+ }
+ },
+ "node_modules/puppeteer": {
+ "version": "24.23.0",
+ "resolved": "https://registry.npmjs.org/puppeteer/-/puppeteer-24.23.0.tgz",
+ "integrity": "sha512-BVR1Lg8sJGKXY79JARdIssFWK2F6e1j+RyuJP66w4CUmpaXjENicmA3nNpUXA8lcTdDjAndtP+oNdni3T/qQqA==",
+ "hasInstallScript": true,
+ "license": "Apache-2.0",
+ "dependencies": {
+ "@puppeteer/browsers": "2.10.10",
+ "chromium-bidi": "9.1.0",
+ "cosmiconfig": "^9.0.0",
+ "devtools-protocol": "0.0.1508733",
+ "puppeteer-core": "24.23.0",
+ "typed-query-selector": "^2.12.0"
+ },
+ "bin": {
+ "puppeteer": "lib/cjs/puppeteer/node/cli.js"
+ },
+ "engines": {
+ "node": ">=18"
+ }
+ },
+ "node_modules/puppeteer-core": {
+ "version": "24.23.0",
+ "resolved": "https://registry.npmjs.org/puppeteer-core/-/puppeteer-core-24.23.0.tgz",
+ "integrity": "sha512-yl25C59gb14sOdIiSnJ08XiPP+O2RjuyZmEG+RjYmCXO7au0jcLf7fRiyii96dXGUBW7Zwei/mVKfxMx/POeFw==",
+ "license": "Apache-2.0",
+ "dependencies": {
+ "@puppeteer/browsers": "2.10.10",
+ "chromium-bidi": "9.1.0",
+ "debug": "^4.4.3",
+ "devtools-protocol": "0.0.1508733",
+ "typed-query-selector": "^2.12.0",
+ "webdriver-bidi-protocol": "0.3.6",
+ "ws": "^8.18.3"
+ },
+ "engines": {
+ "node": ">=18"
+ }
+ },
+ "node_modules/require-directory": {
+ "version": "2.1.1",
+ "resolved": "https://registry.npmjs.org/require-directory/-/require-directory-2.1.1.tgz",
+ "integrity": "sha512-fGxEI7+wsG9xrvdjsrlmL22OMTTiHRwAMroiEeMgq8gzoLC/PQr7RsRDSTLUg/bZAZtF+TVIkHc6/4RIKrui+Q==",
+ "license": "MIT",
+ "engines": {
+ "node": ">=0.10.0"
+ }
+ },
+ "node_modules/resolve-from": {
+ "version": "4.0.0",
+ "resolved": "https://registry.npmjs.org/resolve-from/-/resolve-from-4.0.0.tgz",
+ "integrity": "sha512-pb/MYmXstAkysRFx8piNI1tGFNQIFA3vkE3Gq4EuA1dF6gHp/+vgZqsCGJapvy8N3Q+4o7FwvquPJcnZ7RYy4g==",
+ "license": "MIT",
+ "engines": {
+ "node": ">=4"
+ }
+ },
+ "node_modules/semver": {
+ "version": "7.7.3",
+ "resolved": "https://registry.npmjs.org/semver/-/semver-7.7.3.tgz",
+ "integrity": "sha512-SdsKMrI9TdgjdweUSR9MweHA4EJ8YxHn8DFaDisvhVlUOe4BF1tLD7GAj0lIqWVl+dPb/rExr0Btby5loQm20Q==",
+ "license": "ISC",
+ "bin": {
+ "semver": "bin/semver.js"
+ },
+ "engines": {
+ "node": ">=10"
+ }
+ },
+ "node_modules/smart-buffer": {
+ "version": "4.2.0",
+ "resolved": "https://registry.npmjs.org/smart-buffer/-/smart-buffer-4.2.0.tgz",
+ "integrity": "sha512-94hK0Hh8rPqQl2xXc3HsaBoOXKV20MToPkcXvwbISWLEs+64sBq5kFgn2kJDHb1Pry9yrP0dxrCI9RRci7RXKg==",
+ "license": "MIT",
+ "engines": {
+ "node": ">= 6.0.0",
+ "npm": ">= 3.0.0"
+ }
+ },
+ "node_modules/socks": {
+ "version": "2.8.7",
+ "resolved": "https://registry.npmjs.org/socks/-/socks-2.8.7.tgz",
+ "integrity": "sha512-HLpt+uLy/pxB+bum/9DzAgiKS8CX1EvbWxI4zlmgGCExImLdiad2iCwXT5Z4c9c3Eq8rP2318mPW2c+QbtjK8A==",
+ "license": "MIT",
+ "dependencies": {
+ "ip-address": "^10.0.1",
+ "smart-buffer": "^4.2.0"
+ },
+ "engines": {
+ "node": ">= 10.0.0",
+ "npm": ">= 3.0.0"
+ }
+ },
+ "node_modules/socks-proxy-agent": {
+ "version": "8.0.5",
+ "resolved": "https://registry.npmjs.org/socks-proxy-agent/-/socks-proxy-agent-8.0.5.tgz",
+ "integrity": "sha512-HehCEsotFqbPW9sJ8WVYB6UbmIMv7kUUORIF2Nncq4VQvBfNBLibW9YZR5dlYCSUhwcD628pRllm7n+E+YTzJw==",
+ "license": "MIT",
+ "dependencies": {
+ "agent-base": "^7.1.2",
+ "debug": "^4.3.4",
+ "socks": "^2.8.3"
+ },
+ "engines": {
+ "node": ">= 14"
+ }
+ },
+ "node_modules/source-map": {
+ "version": "0.6.1",
+ "resolved": "https://registry.npmjs.org/source-map/-/source-map-0.6.1.tgz",
+ "integrity": "sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g==",
+ "license": "BSD-3-Clause",
+ "optional": true,
+ "engines": {
+ "node": ">=0.10.0"
+ }
+ },
+ "node_modules/streamx": {
+ "version": "2.23.0",
+ "resolved": "https://registry.npmjs.org/streamx/-/streamx-2.23.0.tgz",
+ "integrity": "sha512-kn+e44esVfn2Fa/O0CPFcex27fjIL6MkVae0Mm6q+E6f0hWv578YCERbv+4m02cjxvDsPKLnmxral/rR6lBMAg==",
+ "license": "MIT",
+ "dependencies": {
+ "events-universal": "^1.0.0",
+ "fast-fifo": "^1.3.2",
+ "text-decoder": "^1.1.0"
+ }
+ },
+ "node_modules/string-width": {
+ "version": "4.2.3",
+ "resolved": "https://registry.npmjs.org/string-width/-/string-width-4.2.3.tgz",
+ "integrity": "sha512-wKyQRQpjJ0sIp62ErSZdGsjMJWsap5oRNihHhu6G7JVO/9jIB6UyevL+tXuOqrng8j/cxKTWyWUwvSTriiZz/g==",
+ "license": "MIT",
+ "dependencies": {
+ "emoji-regex": "^8.0.0",
+ "is-fullwidth-code-point": "^3.0.0",
+ "strip-ansi": "^6.0.1"
+ },
+ "engines": {
+ "node": ">=8"
+ }
+ },
+ "node_modules/strip-ansi": {
+ "version": "6.0.1",
+ "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-6.0.1.tgz",
+ "integrity": "sha512-Y38VPSHcqkFrCpFnQ9vuSXmquuv5oXOKpGeT6aGrr3o3Gc9AlVa6JBfUSOCnbxGGZF+/0ooI7KrPuUSztUdU5A==",
+ "license": "MIT",
+ "dependencies": {
+ "ansi-regex": "^5.0.1"
+ },
+ "engines": {
+ "node": ">=8"
+ }
+ },
+ "node_modules/tar-fs": {
+ "version": "3.1.1",
+ "resolved": "https://registry.npmjs.org/tar-fs/-/tar-fs-3.1.1.tgz",
+ "integrity": "sha512-LZA0oaPOc2fVo82Txf3gw+AkEd38szODlptMYejQUhndHMLQ9M059uXR+AfS7DNo0NpINvSqDsvyaCrBVkptWg==",
+ "license": "MIT",
+ "dependencies": {
+ "pump": "^3.0.0",
+ "tar-stream": "^3.1.5"
+ },
+ "optionalDependencies": {
+ "bare-fs": "^4.0.1",
+ "bare-path": "^3.0.0"
+ }
+ },
+ "node_modules/tar-stream": {
+ "version": "3.1.7",
+ "resolved": "https://registry.npmjs.org/tar-stream/-/tar-stream-3.1.7.tgz",
+ "integrity": "sha512-qJj60CXt7IU1Ffyc3NJMjh6EkuCFej46zUqJ4J7pqYlThyd9bO0XBTmcOIhSzZJVWfsLks0+nle/j538YAW9RQ==",
+ "license": "MIT",
+ "dependencies": {
+ "b4a": "^1.6.4",
+ "fast-fifo": "^1.2.0",
+ "streamx": "^2.15.0"
+ }
+ },
+ "node_modules/text-decoder": {
+ "version": "1.2.3",
+ "resolved": "https://registry.npmjs.org/text-decoder/-/text-decoder-1.2.3.tgz",
+ "integrity": "sha512-3/o9z3X0X0fTupwsYvR03pJ/DjWuqqrfwBgTQzdWDiQSm9KitAyz/9WqsT2JQW7KV2m+bC2ol/zqpW37NHxLaA==",
+ "license": "Apache-2.0",
+ "dependencies": {
+ "b4a": "^1.6.4"
+ }
+ },
+ "node_modules/tslib": {
+ "version": "2.8.1",
+ "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.8.1.tgz",
+ "integrity": "sha512-oJFu94HQb+KVduSUQL7wnpmqnfmLsOA/nAh6b6EH0wCEoK0/mPeXU6c3wKDV83MkOuHPRHtSXKKU99IBazS/2w==",
+ "license": "0BSD"
+ },
+ "node_modules/typed-query-selector": {
+ "version": "2.12.0",
+ "resolved": "https://registry.npmjs.org/typed-query-selector/-/typed-query-selector-2.12.0.tgz",
+ "integrity": "sha512-SbklCd1F0EiZOyPiW192rrHZzZ5sBijB6xM+cpmrwDqObvdtunOHHIk9fCGsoK5JVIYXoyEp4iEdE3upFH3PAg==",
+ "license": "MIT"
+ },
+ "node_modules/undici-types": {
+ "version": "7.14.0",
+ "resolved": "https://registry.npmjs.org/undici-types/-/undici-types-7.14.0.tgz",
+ "integrity": "sha512-QQiYxHuyZ9gQUIrmPo3IA+hUl4KYk8uSA7cHrcKd/l3p1OTpZcM0Tbp9x7FAtXdAYhlasd60ncPpgu6ihG6TOA==",
+ "license": "MIT",
+ "optional": true
+ },
+ "node_modules/webdriver-bidi-protocol": {
+ "version": "0.3.6",
+ "resolved": "https://registry.npmjs.org/webdriver-bidi-protocol/-/webdriver-bidi-protocol-0.3.6.tgz",
+ "integrity": "sha512-mlGndEOA9yK9YAbvtxaPTqdi/kaCWYYfwrZvGzcmkr/3lWM+tQj53BxtpVd6qbC6+E5OnHXgCcAhre6AkXzxjA==",
+ "license": "Apache-2.0"
+ },
+ "node_modules/wrap-ansi": {
+ "version": "7.0.0",
+ "resolved": "https://registry.npmjs.org/wrap-ansi/-/wrap-ansi-7.0.0.tgz",
+ "integrity": "sha512-YVGIj2kamLSTxw6NsZjoBxfSwsn0ycdesmc4p+Q21c5zPuZ1pl+NfxVdxPtdHvmNVOQ6XSYG4AUtyt/Fi7D16Q==",
+ "license": "MIT",
+ "dependencies": {
+ "ansi-styles": "^4.0.0",
+ "string-width": "^4.1.0",
+ "strip-ansi": "^6.0.0"
+ },
+ "engines": {
+ "node": ">=10"
+ },
+ "funding": {
+ "url": "https://github.com/chalk/wrap-ansi?sponsor=1"
+ }
+ },
+ "node_modules/wrappy": {
+ "version": "1.0.2",
+ "resolved": "https://registry.npmjs.org/wrappy/-/wrappy-1.0.2.tgz",
+ "integrity": "sha512-l4Sp/DRseor9wL6EvV2+TuQn63dMkPjZ/sp9XkghTEbV9KlPS1xUsZ3u7/IQO4wxtcFB4bgpQPRcR3QCvezPcQ==",
+ "license": "ISC"
+ },
+ "node_modules/ws": {
+ "version": "8.18.3",
+ "resolved": "https://registry.npmjs.org/ws/-/ws-8.18.3.tgz",
+ "integrity": "sha512-PEIGCY5tSlUt50cqyMXfCzX+oOPqN0vuGqWzbcJ2xvnkzkq46oOpz7dQaTDBdfICb4N14+GARUDw2XV2N4tvzg==",
+ "license": "MIT",
+ "engines": {
+ "node": ">=10.0.0"
+ },
+ "peerDependencies": {
+ "bufferutil": "^4.0.1",
+ "utf-8-validate": ">=5.0.2"
+ },
+ "peerDependenciesMeta": {
+ "bufferutil": {
+ "optional": true
+ },
+ "utf-8-validate": {
+ "optional": true
+ }
+ }
+ },
+ "node_modules/y18n": {
+ "version": "5.0.8",
+ "resolved": "https://registry.npmjs.org/y18n/-/y18n-5.0.8.tgz",
+ "integrity": "sha512-0pfFzegeDWJHJIAmTLRP2DwHjdF5s7jo9tuztdQxAhINCdvS+3nGINqPd00AphqJR/0LhANUS6/+7SCb98YOfA==",
+ "license": "ISC",
+ "engines": {
+ "node": ">=10"
+ }
+ },
+ "node_modules/yargs": {
+ "version": "17.7.2",
+ "resolved": "https://registry.npmjs.org/yargs/-/yargs-17.7.2.tgz",
+ "integrity": "sha512-7dSzzRQ++CKnNI/krKnYRV7JKKPUXMEh61soaHKg9mrWEhzFWhFnxPxGl+69cD1Ou63C13NUPCnmIcrvqCuM6w==",
+ "license": "MIT",
+ "dependencies": {
+ "cliui": "^8.0.1",
+ "escalade": "^3.1.1",
+ "get-caller-file": "^2.0.5",
+ "require-directory": "^2.1.1",
+ "string-width": "^4.2.3",
+ "y18n": "^5.0.5",
+ "yargs-parser": "^21.1.1"
+ },
+ "engines": {
+ "node": ">=12"
+ }
+ },
+ "node_modules/yargs-parser": {
+ "version": "21.1.1",
+ "resolved": "https://registry.npmjs.org/yargs-parser/-/yargs-parser-21.1.1.tgz",
+ "integrity": "sha512-tVpsJW7DdjecAiFpbIB1e3qxIQsE6NoPc5/eTdrbbIC4h0LVsWhnoa3g+m2HclBIujHzsxZ4VJVA+GUuc2/LBw==",
+ "license": "ISC",
+ "engines": {
+ "node": ">=12"
+ }
+ },
+ "node_modules/yauzl": {
+ "version": "2.10.0",
+ "resolved": "https://registry.npmjs.org/yauzl/-/yauzl-2.10.0.tgz",
+ "integrity": "sha512-p4a9I6X6nu6IhoGmBqAcbJy1mlC4j27vEPZX9F4L4/vZT3Lyq1VkFHw/V/PUcB9Buo+DG3iHkT0x3Qya58zc3g==",
+ "license": "MIT",
+ "dependencies": {
+ "buffer-crc32": "~0.2.3",
+ "fd-slicer": "~1.1.0"
+ }
+ },
+ "node_modules/zod": {
+ "version": "3.25.76",
+ "resolved": "https://registry.npmjs.org/zod/-/zod-3.25.76.tgz",
+ "integrity": "sha512-gzUt/qt81nXsFGKIFcC3YnfEAx5NkunCfnDlvuBSSFS02bcXu4Lmea0AFIUwbLWxWPx3d9p8S5QoaujKcNQxcQ==",
+ "license": "MIT",
+ "funding": {
+ "url": "https://github.com/sponsors/colinhacks"
+ }
+ }
+ }
+}
diff --git a/node_modules/@babel/code-frame/LICENSE b/node_modules/@babel/code-frame/LICENSE
new file mode 100644
index 0000000..f31575e
--- /dev/null
+++ b/node_modules/@babel/code-frame/LICENSE
@@ -0,0 +1,22 @@
+MIT License
+
+Copyright (c) 2014-present Sebastian McKenzie and other contributors
+
+Permission is hereby granted, free of charge, to any person obtaining
+a copy of this software and associated documentation files (the
+"Software"), to deal in the Software without restriction, including
+without limitation the rights to use, copy, modify, merge, publish,
+distribute, sublicense, and/or sell copies of the Software, and to
+permit persons to whom the Software is furnished to do so, subject to
+the following conditions:
+
+The above copyright notice and this permission notice shall be
+included in all copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
+NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
+LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
+WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
diff --git a/node_modules/@babel/code-frame/README.md b/node_modules/@babel/code-frame/README.md
new file mode 100644
index 0000000..7160755
--- /dev/null
+++ b/node_modules/@babel/code-frame/README.md
@@ -0,0 +1,19 @@
+# @babel/code-frame
+
+> Generate errors that contain a code frame that point to source locations.
+
+See our website [@babel/code-frame](https://babeljs.io/docs/babel-code-frame) for more information.
+
+## Install
+
+Using npm:
+
+```sh
+npm install --save-dev @babel/code-frame
+```
+
+or using yarn:
+
+```sh
+yarn add @babel/code-frame --dev
+```
diff --git a/node_modules/@babel/code-frame/lib/index.js b/node_modules/@babel/code-frame/lib/index.js
new file mode 100644
index 0000000..b409f30
--- /dev/null
+++ b/node_modules/@babel/code-frame/lib/index.js
@@ -0,0 +1,216 @@
+'use strict';
+
+Object.defineProperty(exports, '__esModule', { value: true });
+
+var picocolors = require('picocolors');
+var jsTokens = require('js-tokens');
+var helperValidatorIdentifier = require('@babel/helper-validator-identifier');
+
+function isColorSupported() {
+ return (typeof process === "object" && (process.env.FORCE_COLOR === "0" || process.env.FORCE_COLOR === "false") ? false : picocolors.isColorSupported
+ );
+}
+const compose = (f, g) => v => f(g(v));
+function buildDefs(colors) {
+ return {
+ keyword: colors.cyan,
+ capitalized: colors.yellow,
+ jsxIdentifier: colors.yellow,
+ punctuator: colors.yellow,
+ number: colors.magenta,
+ string: colors.green,
+ regex: colors.magenta,
+ comment: colors.gray,
+ invalid: compose(compose(colors.white, colors.bgRed), colors.bold),
+ gutter: colors.gray,
+ marker: compose(colors.red, colors.bold),
+ message: compose(colors.red, colors.bold),
+ reset: colors.reset
+ };
+}
+const defsOn = buildDefs(picocolors.createColors(true));
+const defsOff = buildDefs(picocolors.createColors(false));
+function getDefs(enabled) {
+ return enabled ? defsOn : defsOff;
+}
+
+const sometimesKeywords = new Set(["as", "async", "from", "get", "of", "set"]);
+const NEWLINE$1 = /\r\n|[\n\r\u2028\u2029]/;
+const BRACKET = /^[()[\]{}]$/;
+let tokenize;
+{
+ const JSX_TAG = /^[a-z][\w-]*$/i;
+ const getTokenType = function (token, offset, text) {
+ if (token.type === "name") {
+ if (helperValidatorIdentifier.isKeyword(token.value) || helperValidatorIdentifier.isStrictReservedWord(token.value, true) || sometimesKeywords.has(token.value)) {
+ return "keyword";
+ }
+ if (JSX_TAG.test(token.value) && (text[offset - 1] === "<" || text.slice(offset - 2, offset) === "")) {
+ return "jsxIdentifier";
+ }
+ if (token.value[0] !== token.value[0].toLowerCase()) {
+ return "capitalized";
+ }
+ }
+ if (token.type === "punctuator" && BRACKET.test(token.value)) {
+ return "bracket";
+ }
+ if (token.type === "invalid" && (token.value === "@" || token.value === "#")) {
+ return "punctuator";
+ }
+ return token.type;
+ };
+ tokenize = function* (text) {
+ let match;
+ while (match = jsTokens.default.exec(text)) {
+ const token = jsTokens.matchToToken(match);
+ yield {
+ type: getTokenType(token, match.index, text),
+ value: token.value
+ };
+ }
+ };
+}
+function highlight(text) {
+ if (text === "") return "";
+ const defs = getDefs(true);
+ let highlighted = "";
+ for (const {
+ type,
+ value
+ } of tokenize(text)) {
+ if (type in defs) {
+ highlighted += value.split(NEWLINE$1).map(str => defs[type](str)).join("\n");
+ } else {
+ highlighted += value;
+ }
+ }
+ return highlighted;
+}
+
+let deprecationWarningShown = false;
+const NEWLINE = /\r\n|[\n\r\u2028\u2029]/;
+function getMarkerLines(loc, source, opts) {
+ const startLoc = Object.assign({
+ column: 0,
+ line: -1
+ }, loc.start);
+ const endLoc = Object.assign({}, startLoc, loc.end);
+ const {
+ linesAbove = 2,
+ linesBelow = 3
+ } = opts || {};
+ const startLine = startLoc.line;
+ const startColumn = startLoc.column;
+ const endLine = endLoc.line;
+ const endColumn = endLoc.column;
+ let start = Math.max(startLine - (linesAbove + 1), 0);
+ let end = Math.min(source.length, endLine + linesBelow);
+ if (startLine === -1) {
+ start = 0;
+ }
+ if (endLine === -1) {
+ end = source.length;
+ }
+ const lineDiff = endLine - startLine;
+ const markerLines = {};
+ if (lineDiff) {
+ for (let i = 0; i <= lineDiff; i++) {
+ const lineNumber = i + startLine;
+ if (!startColumn) {
+ markerLines[lineNumber] = true;
+ } else if (i === 0) {
+ const sourceLength = source[lineNumber - 1].length;
+ markerLines[lineNumber] = [startColumn, sourceLength - startColumn + 1];
+ } else if (i === lineDiff) {
+ markerLines[lineNumber] = [0, endColumn];
+ } else {
+ const sourceLength = source[lineNumber - i].length;
+ markerLines[lineNumber] = [0, sourceLength];
+ }
+ }
+ } else {
+ if (startColumn === endColumn) {
+ if (startColumn) {
+ markerLines[startLine] = [startColumn, 0];
+ } else {
+ markerLines[startLine] = true;
+ }
+ } else {
+ markerLines[startLine] = [startColumn, endColumn - startColumn];
+ }
+ }
+ return {
+ start,
+ end,
+ markerLines
+ };
+}
+function codeFrameColumns(rawLines, loc, opts = {}) {
+ const shouldHighlight = opts.forceColor || isColorSupported() && opts.highlightCode;
+ const defs = getDefs(shouldHighlight);
+ const lines = rawLines.split(NEWLINE);
+ const {
+ start,
+ end,
+ markerLines
+ } = getMarkerLines(loc, lines, opts);
+ const hasColumns = loc.start && typeof loc.start.column === "number";
+ const numberMaxWidth = String(end).length;
+ const highlightedLines = shouldHighlight ? highlight(rawLines) : rawLines;
+ let frame = highlightedLines.split(NEWLINE, end).slice(start, end).map((line, index) => {
+ const number = start + 1 + index;
+ const paddedNumber = ` ${number}`.slice(-numberMaxWidth);
+ const gutter = ` ${paddedNumber} |`;
+ const hasMarker = markerLines[number];
+ const lastMarkerLine = !markerLines[number + 1];
+ if (hasMarker) {
+ let markerLine = "";
+ if (Array.isArray(hasMarker)) {
+ const markerSpacing = line.slice(0, Math.max(hasMarker[0] - 1, 0)).replace(/[^\t]/g, " ");
+ const numberOfMarkers = hasMarker[1] || 1;
+ markerLine = ["\n ", defs.gutter(gutter.replace(/\d/g, " ")), " ", markerSpacing, defs.marker("^").repeat(numberOfMarkers)].join("");
+ if (lastMarkerLine && opts.message) {
+ markerLine += " " + defs.message(opts.message);
+ }
+ }
+ return [defs.marker(">"), defs.gutter(gutter), line.length > 0 ? ` ${line}` : "", markerLine].join("");
+ } else {
+ return ` ${defs.gutter(gutter)}${line.length > 0 ? ` ${line}` : ""}`;
+ }
+ }).join("\n");
+ if (opts.message && !hasColumns) {
+ frame = `${" ".repeat(numberMaxWidth + 1)}${opts.message}\n${frame}`;
+ }
+ if (shouldHighlight) {
+ return defs.reset(frame);
+ } else {
+ return frame;
+ }
+}
+function index (rawLines, lineNumber, colNumber, opts = {}) {
+ if (!deprecationWarningShown) {
+ deprecationWarningShown = true;
+ const message = "Passing lineNumber and colNumber is deprecated to @babel/code-frame. Please use `codeFrameColumns`.";
+ if (process.emitWarning) {
+ process.emitWarning(message, "DeprecationWarning");
+ } else {
+ const deprecationError = new Error(message);
+ deprecationError.name = "DeprecationWarning";
+ console.warn(new Error(message));
+ }
+ }
+ colNumber = Math.max(colNumber, 0);
+ const location = {
+ start: {
+ column: colNumber,
+ line: lineNumber
+ }
+ };
+ return codeFrameColumns(rawLines, location, opts);
+}
+
+exports.codeFrameColumns = codeFrameColumns;
+exports.default = index;
+exports.highlight = highlight;
+//# sourceMappingURL=index.js.map
diff --git a/node_modules/@babel/code-frame/lib/index.js.map b/node_modules/@babel/code-frame/lib/index.js.map
new file mode 100644
index 0000000..46a181d
--- /dev/null
+++ b/node_modules/@babel/code-frame/lib/index.js.map
@@ -0,0 +1 @@
+{"version":3,"file":"index.js","sources":["../src/defs.ts","../src/highlight.ts","../src/index.ts"],"sourcesContent":["import picocolors, { createColors } from \"picocolors\";\nimport type { Colors, Formatter } from \"picocolors/types\";\n\nexport function isColorSupported() {\n return (\n // See https://github.com/alexeyraspopov/picocolors/issues/62\n typeof process === \"object\" &&\n (process.env.FORCE_COLOR === \"0\" || process.env.FORCE_COLOR === \"false\")\n ? false\n : picocolors.isColorSupported\n );\n}\n\nexport type InternalTokenType =\n | \"keyword\"\n | \"capitalized\"\n | \"jsxIdentifier\"\n | \"punctuator\"\n | \"number\"\n | \"string\"\n | \"regex\"\n | \"comment\"\n | \"invalid\";\n\ntype UITokens = \"gutter\" | \"marker\" | \"message\";\n\nexport type Defs = {\n [_ in InternalTokenType | UITokens | \"reset\"]: Formatter;\n};\n\nconst compose: (f: (gv: U) => V, g: (v: T) => U) => (v: T) => V =\n (f, g) => v =>\n f(g(v));\n\n/**\n * Styles for token types.\n */\nfunction buildDefs(colors: Colors): Defs {\n return {\n keyword: colors.cyan,\n capitalized: colors.yellow,\n jsxIdentifier: colors.yellow,\n punctuator: colors.yellow,\n number: colors.magenta,\n string: colors.green,\n regex: colors.magenta,\n comment: colors.gray,\n invalid: compose(compose(colors.white, colors.bgRed), colors.bold),\n\n gutter: colors.gray,\n marker: compose(colors.red, colors.bold),\n message: compose(colors.red, colors.bold),\n\n reset: colors.reset,\n };\n}\n\nconst defsOn = buildDefs(createColors(true));\nconst defsOff = buildDefs(createColors(false));\n\nexport function getDefs(enabled: boolean): Defs {\n return enabled ? defsOn : defsOff;\n}\n","import type { Token as JSToken, JSXToken } from \"js-tokens\";\nimport jsTokens from \"js-tokens\";\n\nimport {\n isStrictReservedWord,\n isKeyword,\n} from \"@babel/helper-validator-identifier\";\n\nimport { getDefs, type InternalTokenType } from \"./defs.ts\";\n\n/**\n * Names that are always allowed as identifiers, but also appear as keywords\n * within certain syntactic productions.\n *\n * https://tc39.es/ecma262/#sec-keywords-and-reserved-words\n *\n * `target` has been omitted since it is very likely going to be a false\n * positive.\n */\nconst sometimesKeywords = new Set([\"as\", \"async\", \"from\", \"get\", \"of\", \"set\"]);\n\ntype Token = {\n type: InternalTokenType | \"uncolored\";\n value: string;\n};\n\n/**\n * RegExp to test for newlines in terminal.\n */\nconst NEWLINE = /\\r\\n|[\\n\\r\\u2028\\u2029]/;\n\n/**\n * RegExp to test for the three types of brackets.\n */\nconst BRACKET = /^[()[\\]{}]$/;\n\nlet tokenize: (\n text: string,\n) => Generator<{ type: InternalTokenType | \"uncolored\"; value: string }>;\n\nif (process.env.BABEL_8_BREAKING) {\n /**\n * Get the type of token, specifying punctuator type.\n */\n const getTokenType = function (\n token: JSToken | JSXToken,\n ): InternalTokenType | \"uncolored\" {\n if (token.type === \"IdentifierName\") {\n if (\n isKeyword(token.value) ||\n isStrictReservedWord(token.value, true) ||\n sometimesKeywords.has(token.value)\n ) {\n return \"keyword\";\n }\n\n if (token.value[0] !== token.value[0].toLowerCase()) {\n return \"capitalized\";\n }\n }\n\n if (token.type === \"Punctuator\" && BRACKET.test(token.value)) {\n return \"uncolored\";\n }\n\n if (token.type === \"Invalid\" && token.value === \"@\") {\n return \"punctuator\";\n }\n\n switch (token.type) {\n case \"NumericLiteral\":\n return \"number\";\n\n case \"StringLiteral\":\n case \"JSXString\":\n case \"NoSubstitutionTemplate\":\n return \"string\";\n\n case \"RegularExpressionLiteral\":\n return \"regex\";\n\n case \"Punctuator\":\n case \"JSXPunctuator\":\n return \"punctuator\";\n\n case \"MultiLineComment\":\n case \"SingleLineComment\":\n return \"comment\";\n\n case \"Invalid\":\n case \"JSXInvalid\":\n return \"invalid\";\n\n case \"JSXIdentifier\":\n return \"jsxIdentifier\";\n\n default:\n return \"uncolored\";\n }\n };\n\n /**\n * Turn a string of JS into an array of objects.\n */\n tokenize = function* (text: string): Generator {\n for (const token of jsTokens(text, { jsx: true })) {\n switch (token.type) {\n case \"TemplateHead\":\n yield { type: \"string\", value: token.value.slice(0, -2) };\n yield { type: \"punctuator\", value: \"${\" };\n break;\n\n case \"TemplateMiddle\":\n yield { type: \"punctuator\", value: \"}\" };\n yield { type: \"string\", value: token.value.slice(1, -2) };\n yield { type: \"punctuator\", value: \"${\" };\n break;\n\n case \"TemplateTail\":\n yield { type: \"punctuator\", value: \"}\" };\n yield { type: \"string\", value: token.value.slice(1) };\n break;\n\n default:\n yield {\n type: getTokenType(token),\n value: token.value,\n };\n }\n }\n };\n} else {\n /**\n * RegExp to test for what seems to be a JSX tag name.\n */\n const JSX_TAG = /^[a-z][\\w-]*$/i;\n\n // The token here is defined in js-tokens@4. However we don't bother\n // typing it since the whole block will be removed in Babel 8\n const getTokenType = function (token: any, offset: number, text: string) {\n if (token.type === \"name\") {\n if (\n isKeyword(token.value) ||\n isStrictReservedWord(token.value, true) ||\n sometimesKeywords.has(token.value)\n ) {\n return \"keyword\";\n }\n\n if (\n JSX_TAG.test(token.value) &&\n (text[offset - 1] === \"<\" || text.slice(offset - 2, offset) === \"\")\n ) {\n return \"jsxIdentifier\";\n }\n\n if (token.value[0] !== token.value[0].toLowerCase()) {\n return \"capitalized\";\n }\n }\n\n if (token.type === \"punctuator\" && BRACKET.test(token.value)) {\n return \"bracket\";\n }\n\n if (\n token.type === \"invalid\" &&\n (token.value === \"@\" || token.value === \"#\")\n ) {\n return \"punctuator\";\n }\n\n return token.type;\n };\n\n tokenize = function* (text: string) {\n let match;\n while ((match = (jsTokens as any).default.exec(text))) {\n const token = (jsTokens as any).matchToToken(match);\n\n yield {\n type: getTokenType(token, match.index, text),\n value: token.value,\n };\n }\n };\n}\n\nexport function highlight(text: string) {\n if (text === \"\") return \"\";\n\n const defs = getDefs(true);\n\n let highlighted = \"\";\n\n for (const { type, value } of tokenize(text)) {\n if (type in defs) {\n highlighted += value\n .split(NEWLINE)\n .map(str => defs[type as InternalTokenType](str))\n .join(\"\\n\");\n } else {\n highlighted += value;\n }\n }\n\n return highlighted;\n}\n","import { getDefs, isColorSupported } from \"./defs.ts\";\nimport { highlight } from \"./highlight.ts\";\n\nexport { highlight };\n\nlet deprecationWarningShown = false;\n\ntype Location = {\n column: number;\n line: number;\n};\n\ntype NodeLocation = {\n end?: Location;\n start: Location;\n};\n\nexport interface Options {\n /** Syntax highlight the code as JavaScript for terminals. default: false */\n highlightCode?: boolean;\n /** The number of lines to show above the error. default: 2 */\n linesAbove?: number;\n /** The number of lines to show below the error. default: 3 */\n linesBelow?: number;\n /**\n * Forcibly syntax highlight the code as JavaScript (for non-terminals);\n * overrides highlightCode.\n * default: false\n */\n forceColor?: boolean;\n /**\n * Pass in a string to be displayed inline (if possible) next to the\n * highlighted location in the code. If it can't be positioned inline,\n * it will be placed above the code frame.\n * default: nothing\n */\n message?: string;\n}\n\n/**\n * RegExp to test for newlines in terminal.\n */\n\nconst NEWLINE = /\\r\\n|[\\n\\r\\u2028\\u2029]/;\n\n/**\n * Extract what lines should be marked and highlighted.\n */\n\ntype MarkerLines = Record;\n\nfunction getMarkerLines(\n loc: NodeLocation,\n source: Array,\n opts: Options,\n): {\n start: number;\n end: number;\n markerLines: MarkerLines;\n} {\n const startLoc: Location = {\n column: 0,\n line: -1,\n ...loc.start,\n };\n const endLoc: Location = {\n ...startLoc,\n ...loc.end,\n };\n const { linesAbove = 2, linesBelow = 3 } = opts || {};\n const startLine = startLoc.line;\n const startColumn = startLoc.column;\n const endLine = endLoc.line;\n const endColumn = endLoc.column;\n\n let start = Math.max(startLine - (linesAbove + 1), 0);\n let end = Math.min(source.length, endLine + linesBelow);\n\n if (startLine === -1) {\n start = 0;\n }\n\n if (endLine === -1) {\n end = source.length;\n }\n\n const lineDiff = endLine - startLine;\n const markerLines: MarkerLines = {};\n\n if (lineDiff) {\n for (let i = 0; i <= lineDiff; i++) {\n const lineNumber = i + startLine;\n\n if (!startColumn) {\n markerLines[lineNumber] = true;\n } else if (i === 0) {\n const sourceLength = source[lineNumber - 1].length;\n\n markerLines[lineNumber] = [startColumn, sourceLength - startColumn + 1];\n } else if (i === lineDiff) {\n markerLines[lineNumber] = [0, endColumn];\n } else {\n const sourceLength = source[lineNumber - i].length;\n\n markerLines[lineNumber] = [0, sourceLength];\n }\n }\n } else {\n if (startColumn === endColumn) {\n if (startColumn) {\n markerLines[startLine] = [startColumn, 0];\n } else {\n markerLines[startLine] = true;\n }\n } else {\n markerLines[startLine] = [startColumn, endColumn - startColumn];\n }\n }\n\n return { start, end, markerLines };\n}\n\nexport function codeFrameColumns(\n rawLines: string,\n loc: NodeLocation,\n opts: Options = {},\n): string {\n const shouldHighlight =\n opts.forceColor || (isColorSupported() && opts.highlightCode);\n const defs = getDefs(shouldHighlight);\n\n const lines = rawLines.split(NEWLINE);\n const { start, end, markerLines } = getMarkerLines(loc, lines, opts);\n const hasColumns = loc.start && typeof loc.start.column === \"number\";\n\n const numberMaxWidth = String(end).length;\n\n const highlightedLines = shouldHighlight ? highlight(rawLines) : rawLines;\n\n let frame = highlightedLines\n .split(NEWLINE, end)\n .slice(start, end)\n .map((line, index) => {\n const number = start + 1 + index;\n const paddedNumber = ` ${number}`.slice(-numberMaxWidth);\n const gutter = ` ${paddedNumber} |`;\n const hasMarker = markerLines[number];\n const lastMarkerLine = !markerLines[number + 1];\n if (hasMarker) {\n let markerLine = \"\";\n if (Array.isArray(hasMarker)) {\n const markerSpacing = line\n .slice(0, Math.max(hasMarker[0] - 1, 0))\n .replace(/[^\\t]/g, \" \");\n const numberOfMarkers = hasMarker[1] || 1;\n\n markerLine = [\n \"\\n \",\n defs.gutter(gutter.replace(/\\d/g, \" \")),\n \" \",\n markerSpacing,\n defs.marker(\"^\").repeat(numberOfMarkers),\n ].join(\"\");\n\n if (lastMarkerLine && opts.message) {\n markerLine += \" \" + defs.message(opts.message);\n }\n }\n return [\n defs.marker(\">\"),\n defs.gutter(gutter),\n line.length > 0 ? ` ${line}` : \"\",\n markerLine,\n ].join(\"\");\n } else {\n return ` ${defs.gutter(gutter)}${line.length > 0 ? ` ${line}` : \"\"}`;\n }\n })\n .join(\"\\n\");\n\n if (opts.message && !hasColumns) {\n frame = `${\" \".repeat(numberMaxWidth + 1)}${opts.message}\\n${frame}`;\n }\n\n if (shouldHighlight) {\n return defs.reset(frame);\n } else {\n return frame;\n }\n}\n\n/**\n * Create a code frame, adding line numbers, code highlighting, and pointing to a given position.\n */\n\nexport default function (\n rawLines: string,\n lineNumber: number,\n colNumber?: number | null,\n opts: Options = {},\n): string {\n if (!deprecationWarningShown) {\n deprecationWarningShown = true;\n\n const message =\n \"Passing lineNumber and colNumber is deprecated to @babel/code-frame. Please use `codeFrameColumns`.\";\n\n if (process.emitWarning) {\n // A string is directly supplied to emitWarning, because when supplying an\n // Error object node throws in the tests because of different contexts\n process.emitWarning(message, \"DeprecationWarning\");\n } else {\n const deprecationError = new Error(message);\n deprecationError.name = \"DeprecationWarning\";\n console.warn(new Error(message));\n }\n }\n\n colNumber = Math.max(colNumber, 0);\n\n const location: NodeLocation = {\n start: { column: colNumber, line: lineNumber },\n };\n\n return codeFrameColumns(rawLines, location, opts);\n}\n"],"names":["isColorSupported","process","env","FORCE_COLOR","picocolors","compose","f","g","v","buildDefs","colors","keyword","cyan","capitalized","yellow","jsxIdentifier","punctuator","number","magenta","string","green","regex","comment","gray","invalid","white","bgRed","bold","gutter","marker","red","message","reset","defsOn","createColors","defsOff","getDefs","enabled","sometimesKeywords","Set","NEWLINE","BRACKET","tokenize","JSX_TAG","getTokenType","token","offset","text","type","isKeyword","value","isStrictReservedWord","has","test","slice","toLowerCase","match","jsTokens","default","exec","matchToToken","index","highlight","defs","highlighted","split","map","str","join","deprecationWarningShown","getMarkerLines","loc","source","opts","startLoc","Object","assign","column","line","start","endLoc","end","linesAbove","linesBelow","startLine","startColumn","endLine","endColumn","Math","max","min","length","lineDiff","markerLines","i","lineNumber","sourceLength","codeFrameColumns","rawLines","shouldHighlight","forceColor","highlightCode","lines","hasColumns","numberMaxWidth","String","highlightedLines","frame","paddedNumber","hasMarker","lastMarkerLine","markerLine","Array","isArray","markerSpacing","replace","numberOfMarkers","repeat","colNumber","emitWarning","deprecationError","Error","name","console","warn","location"],"mappings":";;;;;;;;AAGO,SAASA,gBAAgBA,GAAG;EACjC,QAEE,OAAOC,OAAO,KAAK,QAAQ,KACxBA,OAAO,CAACC,GAAG,CAACC,WAAW,KAAK,GAAG,IAAIF,OAAO,CAACC,GAAG,CAACC,WAAW,KAAK,OAAO,CAAC,GACtE,KAAK,GACLC,UAAU,CAACJ,gBAAAA;AAAgB,IAAA;AAEnC,CAAA;AAmBA,MAAMK,OAAkE,GACtEA,CAACC,CAAC,EAAEC,CAAC,KAAKC,CAAC,IACTF,CAAC,CAACC,CAAC,CAACC,CAAC,CAAC,CAAC,CAAA;AAKX,SAASC,SAASA,CAACC,MAAc,EAAQ;EACvC,OAAO;IACLC,OAAO,EAAED,MAAM,CAACE,IAAI;IACpBC,WAAW,EAAEH,MAAM,CAACI,MAAM;IAC1BC,aAAa,EAAEL,MAAM,CAACI,MAAM;IAC5BE,UAAU,EAAEN,MAAM,CAACI,MAAM;IACzBG,MAAM,EAAEP,MAAM,CAACQ,OAAO;IACtBC,MAAM,EAAET,MAAM,CAACU,KAAK;IACpBC,KAAK,EAAEX,MAAM,CAACQ,OAAO;IACrBI,OAAO,EAAEZ,MAAM,CAACa,IAAI;AACpBC,IAAAA,OAAO,EAAEnB,OAAO,CAACA,OAAO,CAACK,MAAM,CAACe,KAAK,EAAEf,MAAM,CAACgB,KAAK,CAAC,EAAEhB,MAAM,CAACiB,IAAI,CAAC;IAElEC,MAAM,EAAElB,MAAM,CAACa,IAAI;IACnBM,MAAM,EAAExB,OAAO,CAACK,MAAM,CAACoB,GAAG,EAAEpB,MAAM,CAACiB,IAAI,CAAC;IACxCI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AAA;AAC1B,GAAC,MAAM;AACL,IAAA,OAAOA,KAAK,CAAA;AACd,GAAA;AACF,CAAA;AAMe,cAAA,EACbT,QAAgB,EAChBH,UAAkB,EAClBuB,SAAyB,EACzB7C,IAAa,GAAG,EAAE,EACV;EACR,IAAI,CAACJ,uBAAuB,EAAE;AAC5BA,IAAAA,uBAAuB,GAAG,IAAI,CAAA;IAE9B,MAAMtC,OAAO,GACX,qGAAqG,CAAA;IAEvG,IAAI9B,OAAO,CAACsH,WAAW,EAAE;AAGvBtH,MAAAA,OAAO,CAACsH,WAAW,CAACxF,OAAO,EAAE,oBAAoB,CAAC,CAAA;AACpD,KAAC,MAAM;AACL,MAAA,MAAMyF,gBAAgB,GAAG,IAAIC,KAAK,CAAC1F,OAAO,CAAC,CAAA;MAC3CyF,gBAAgB,CAACE,IAAI,GAAG,oBAAoB,CAAA;MAC5CC,OAAO,CAACC,IAAI,CAAC,IAAIH,KAAK,CAAC1F,OAAO,CAAC,CAAC,CAAA;AAClC,KAAA;AACF,GAAA;EAEAuF,SAAS,GAAG9B,IAAI,CAACC,GAAG,CAAC6B,SAAS,EAAE,CAAC,CAAC,CAAA;AAElC,EAAA,MAAMO,QAAsB,GAAG;AAC7B9C,IAAAA,KAAK,EAAE;AAAEF,MAAAA,MAAM,EAAEyC,SAAS;AAAExC,MAAAA,IAAI,EAAEiB,UAAAA;AAAW,KAAA;GAC9C,CAAA;AAED,EAAA,OAAOE,gBAAgB,CAACC,QAAQ,EAAE2B,QAAQ,EAAEpD,IAAI,CAAC,CAAA;AACnD;;;;;;"}
\ No newline at end of file
diff --git a/node_modules/@babel/code-frame/package.json b/node_modules/@babel/code-frame/package.json
new file mode 100644
index 0000000..c95c244
--- /dev/null
+++ b/node_modules/@babel/code-frame/package.json
@@ -0,0 +1,31 @@
+{
+ "name": "@babel/code-frame",
+ "version": "7.27.1",
+ "description": "Generate errors that contain a code frame that point to source locations.",
+ "author": "The Babel Team (https://babel.dev/team)",
+ "homepage": "https://babel.dev/docs/en/next/babel-code-frame",
+ "bugs": "https://github.com/babel/babel/issues?utf8=%E2%9C%93&q=is%3Aissue+is%3Aopen",
+ "license": "MIT",
+ "publishConfig": {
+ "access": "public"
+ },
+ "repository": {
+ "type": "git",
+ "url": "https://github.com/babel/babel.git",
+ "directory": "packages/babel-code-frame"
+ },
+ "main": "./lib/index.js",
+ "dependencies": {
+ "@babel/helper-validator-identifier": "^7.27.1",
+ "js-tokens": "^4.0.0",
+ "picocolors": "^1.1.1"
+ },
+ "devDependencies": {
+ "import-meta-resolve": "^4.1.0",
+ "strip-ansi": "^4.0.0"
+ },
+ "engines": {
+ "node": ">=6.9.0"
+ },
+ "type": "commonjs"
+}
\ No newline at end of file
diff --git a/node_modules/@babel/helper-validator-identifier/LICENSE b/node_modules/@babel/helper-validator-identifier/LICENSE
new file mode 100644
index 0000000..f31575e
--- /dev/null
+++ b/node_modules/@babel/helper-validator-identifier/LICENSE
@@ -0,0 +1,22 @@
+MIT License
+
+Copyright (c) 2014-present Sebastian McKenzie and other contributors
+
+Permission is hereby granted, free of charge, to any person obtaining
+a copy of this software and associated documentation files (the
+"Software"), to deal in the Software without restriction, including
+without limitation the rights to use, copy, modify, merge, publish,
+distribute, sublicense, and/or sell copies of the Software, and to
+permit persons to whom the Software is furnished to do so, subject to
+the following conditions:
+
+The above copyright notice and this permission notice shall be
+included in all copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
+NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
+LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
+WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
diff --git a/node_modules/@babel/helper-validator-identifier/README.md b/node_modules/@babel/helper-validator-identifier/README.md
new file mode 100644
index 0000000..05c19e6
--- /dev/null
+++ b/node_modules/@babel/helper-validator-identifier/README.md
@@ -0,0 +1,19 @@
+# @babel/helper-validator-identifier
+
+> Validate identifier/keywords name
+
+See our website [@babel/helper-validator-identifier](https://babeljs.io/docs/babel-helper-validator-identifier) for more information.
+
+## Install
+
+Using npm:
+
+```sh
+npm install --save @babel/helper-validator-identifier
+```
+
+or using yarn:
+
+```sh
+yarn add @babel/helper-validator-identifier
+```
diff --git a/node_modules/@babel/helper-validator-identifier/lib/identifier.js b/node_modules/@babel/helper-validator-identifier/lib/identifier.js
new file mode 100644
index 0000000..fdb9aec
--- /dev/null
+++ b/node_modules/@babel/helper-validator-identifier/lib/identifier.js
@@ -0,0 +1,70 @@
+"use strict";
+
+Object.defineProperty(exports, "__esModule", {
+ value: true
+});
+exports.isIdentifierChar = isIdentifierChar;
+exports.isIdentifierName = isIdentifierName;
+exports.isIdentifierStart = isIdentifierStart;
+let nonASCIIidentifierStartChars = "\xaa\xb5\xba\xc0-\xd6\xd8-\xf6\xf8-\u02c1\u02c6-\u02d1\u02e0-\u02e4\u02ec\u02ee\u0370-\u0374\u0376\u0377\u037a-\u037d\u037f\u0386\u0388-\u038a\u038c\u038e-\u03a1\u03a3-\u03f5\u03f7-\u0481\u048a-\u052f\u0531-\u0556\u0559\u0560-\u0588\u05d0-\u05ea\u05ef-\u05f2\u0620-\u064a\u066e\u066f\u0671-\u06d3\u06d5\u06e5\u06e6\u06ee\u06ef\u06fa-\u06fc\u06ff\u0710\u0712-\u072f\u074d-\u07a5\u07b1\u07ca-\u07ea\u07f4\u07f5\u07fa\u0800-\u0815\u081a\u0824\u0828\u0840-\u0858\u0860-\u086a\u0870-\u0887\u0889-\u088e\u08a0-\u08c9\u0904-\u0939\u093d\u0950\u0958-\u0961\u0971-\u0980\u0985-\u098c\u098f\u0990\u0993-\u09a8\u09aa-\u09b0\u09b2\u09b6-\u09b9\u09bd\u09ce\u09dc\u09dd\u09df-\u09e1\u09f0\u09f1\u09fc\u0a05-\u0a0a\u0a0f\u0a10\u0a13-\u0a28\u0a2a-\u0a30\u0a32\u0a33\u0a35\u0a36\u0a38\u0a39\u0a59-\u0a5c\u0a5e\u0a72-\u0a74\u0a85-\u0a8d\u0a8f-\u0a91\u0a93-\u0aa8\u0aaa-\u0ab0\u0ab2\u0ab3\u0ab5-\u0ab9\u0abd\u0ad0\u0ae0\u0ae1\u0af9\u0b05-\u0b0c\u0b0f\u0b10\u0b13-\u0b28\u0b2a-\u0b30\u0b32\u0b33\u0b35-\u0b39\u0b3d\u0b5c\u0b5d\u0b5f-\u0b61\u0b71\u0b83\u0b85-\u0b8a\u0b8e-\u0b90\u0b92-\u0b95\u0b99\u0b9a\u0b9c\u0b9e\u0b9f\u0ba3\u0ba4\u0ba8-\u0baa\u0bae-\u0bb9\u0bd0\u0c05-\u0c0c\u0c0e-\u0c10\u0c12-\u0c28\u0c2a-\u0c39\u0c3d\u0c58-\u0c5a\u0c5d\u0c60\u0c61\u0c80\u0c85-\u0c8c\u0c8e-\u0c90\u0c92-\u0ca8\u0caa-\u0cb3\u0cb5-\u0cb9\u0cbd\u0cdd\u0cde\u0ce0\u0ce1\u0cf1\u0cf2\u0d04-\u0d0c\u0d0e-\u0d10\u0d12-\u0d3a\u0d3d\u0d4e\u0d54-\u0d56\u0d5f-\u0d61\u0d7a-\u0d7f\u0d85-\u0d96\u0d9a-\u0db1\u0db3-\u0dbb\u0dbd\u0dc0-\u0dc6\u0e01-\u0e30\u0e32\u0e33\u0e40-\u0e46\u0e81\u0e82\u0e84\u0e86-\u0e8a\u0e8c-\u0ea3\u0ea5\u0ea7-\u0eb0\u0eb2\u0eb3\u0ebd\u0ec0-\u0ec4\u0ec6\u0edc-\u0edf\u0f00\u0f40-\u0f47\u0f49-\u0f6c\u0f88-\u0f8c\u1000-\u102a\u103f\u1050-\u1055\u105a-\u105d\u1061\u1065\u1066\u106e-\u1070\u1075-\u1081\u108e\u10a0-\u10c5\u10c7\u10cd\u10d0-\u10fa\u10fc-\u1248\u124a-\u124d\u1250-\u1256\u1258\u125a-\u125d\u1260-\u1288\u128a-\u128d\u1290-\u12b0\u12b2-\u12b5\u12b8-\u12be\u12c0\u12c2-\u12c5\u12c8-\u12d6\u12d8-\u1310\u1312-\u1315\u1318-\u135a\u1380-\u138f\u13a0-\u13f5\u13f8-\u13fd\u1401-\u166c\u166f-\u167f\u1681-\u169a\u16a0-\u16ea\u16ee-\u16f8\u1700-\u1711\u171f-\u1731\u1740-\u1751\u1760-\u176c\u176e-\u1770\u1780-\u17b3\u17d7\u17dc\u1820-\u1878\u1880-\u18a8\u18aa\u18b0-\u18f5\u1900-\u191e\u1950-\u196d\u1970-\u1974\u1980-\u19ab\u19b0-\u19c9\u1a00-\u1a16\u1a20-\u1a54\u1aa7\u1b05-\u1b33\u1b45-\u1b4c\u1b83-\u1ba0\u1bae\u1baf\u1bba-\u1be5\u1c00-\u1c23\u1c4d-\u1c4f\u1c5a-\u1c7d\u1c80-\u1c8a\u1c90-\u1cba\u1cbd-\u1cbf\u1ce9-\u1cec\u1cee-\u1cf3\u1cf5\u1cf6\u1cfa\u1d00-\u1dbf\u1e00-\u1f15\u1f18-\u1f1d\u1f20-\u1f45\u1f48-\u1f4d\u1f50-\u1f57\u1f59\u1f5b\u1f5d\u1f5f-\u1f7d\u1f80-\u1fb4\u1fb6-\u1fbc\u1fbe\u1fc2-\u1fc4\u1fc6-\u1fcc\u1fd0-\u1fd3\u1fd6-\u1fdb\u1fe0-\u1fec\u1ff2-\u1ff4\u1ff6-\u1ffc\u2071\u207f\u2090-\u209c\u2102\u2107\u210a-\u2113\u2115\u2118-\u211d\u2124\u2126\u2128\u212a-\u2139\u213c-\u213f\u2145-\u2149\u214e\u2160-\u2188\u2c00-\u2ce4\u2ceb-\u2cee\u2cf2\u2cf3\u2d00-\u2d25\u2d27\u2d2d\u2d30-\u2d67\u2d6f\u2d80-\u2d96\u2da0-\u2da6\u2da8-\u2dae\u2db0-\u2db6\u2db8-\u2dbe\u2dc0-\u2dc6\u2dc8-\u2dce\u2dd0-\u2dd6\u2dd8-\u2dde\u3005-\u3007\u3021-\u3029\u3031-\u3035\u3038-\u303c\u3041-\u3096\u309b-\u309f\u30a1-\u30fa\u30fc-\u30ff\u3105-\u312f\u3131-\u318e\u31a0-\u31bf\u31f0-\u31ff\u3400-\u4dbf\u4e00-\ua48c\ua4d0-\ua4fd\ua500-\ua60c\ua610-\ua61f\ua62a\ua62b\ua640-\ua66e\ua67f-\ua69d\ua6a0-\ua6ef\ua717-\ua71f\ua722-\ua788\ua78b-\ua7cd\ua7d0\ua7d1\ua7d3\ua7d5-\ua7dc\ua7f2-\ua801\ua803-\ua805\ua807-\ua80a\ua80c-\ua822\ua840-\ua873\ua882-\ua8b3\ua8f2-\ua8f7\ua8fb\ua8fd\ua8fe\ua90a-\ua925\ua930-\ua946\ua960-\ua97c\ua984-\ua9b2\ua9cf\ua9e0-\ua9e4\ua9e6-\ua9ef\ua9fa-\ua9fe\uaa00-\uaa28\uaa40-\uaa42\uaa44-\uaa4b\uaa60-\uaa76\uaa7a\uaa7e-\uaaaf\uaab1\uaab5\uaab6\uaab9-\uaabd\uaac0\uaac2\uaadb-\uaadd\uaae0-\uaaea\uaaf2-\uaaf4\uab01-\uab06\uab09-\uab0e\uab11-\uab16\uab20-\uab26\uab28-\uab2e\uab30-\uab5a\uab5c-\uab69\uab70-\uabe2\uac00-\ud7a3\ud7b0-\ud7c6\ud7cb-\ud7fb\uf900-\ufa6d\ufa70-\ufad9\ufb00-\ufb06\ufb13-\ufb17\ufb1d\ufb1f-\ufb28\ufb2a-\ufb36\ufb38-\ufb3c\ufb3e\ufb40\ufb41\ufb43\ufb44\ufb46-\ufbb1\ufbd3-\ufd3d\ufd50-\ufd8f\ufd92-\ufdc7\ufdf0-\ufdfb\ufe70-\ufe74\ufe76-\ufefc\uff21-\uff3a\uff41-\uff5a\uff66-\uffbe\uffc2-\uffc7\uffca-\uffcf\uffd2-\uffd7\uffda-\uffdc";
+let nonASCIIidentifierChars = "\xb7\u0300-\u036f\u0387\u0483-\u0487\u0591-\u05bd\u05bf\u05c1\u05c2\u05c4\u05c5\u05c7\u0610-\u061a\u064b-\u0669\u0670\u06d6-\u06dc\u06df-\u06e4\u06e7\u06e8\u06ea-\u06ed\u06f0-\u06f9\u0711\u0730-\u074a\u07a6-\u07b0\u07c0-\u07c9\u07eb-\u07f3\u07fd\u0816-\u0819\u081b-\u0823\u0825-\u0827\u0829-\u082d\u0859-\u085b\u0897-\u089f\u08ca-\u08e1\u08e3-\u0903\u093a-\u093c\u093e-\u094f\u0951-\u0957\u0962\u0963\u0966-\u096f\u0981-\u0983\u09bc\u09be-\u09c4\u09c7\u09c8\u09cb-\u09cd\u09d7\u09e2\u09e3\u09e6-\u09ef\u09fe\u0a01-\u0a03\u0a3c\u0a3e-\u0a42\u0a47\u0a48\u0a4b-\u0a4d\u0a51\u0a66-\u0a71\u0a75\u0a81-\u0a83\u0abc\u0abe-\u0ac5\u0ac7-\u0ac9\u0acb-\u0acd\u0ae2\u0ae3\u0ae6-\u0aef\u0afa-\u0aff\u0b01-\u0b03\u0b3c\u0b3e-\u0b44\u0b47\u0b48\u0b4b-\u0b4d\u0b55-\u0b57\u0b62\u0b63\u0b66-\u0b6f\u0b82\u0bbe-\u0bc2\u0bc6-\u0bc8\u0bca-\u0bcd\u0bd7\u0be6-\u0bef\u0c00-\u0c04\u0c3c\u0c3e-\u0c44\u0c46-\u0c48\u0c4a-\u0c4d\u0c55\u0c56\u0c62\u0c63\u0c66-\u0c6f\u0c81-\u0c83\u0cbc\u0cbe-\u0cc4\u0cc6-\u0cc8\u0cca-\u0ccd\u0cd5\u0cd6\u0ce2\u0ce3\u0ce6-\u0cef\u0cf3\u0d00-\u0d03\u0d3b\u0d3c\u0d3e-\u0d44\u0d46-\u0d48\u0d4a-\u0d4d\u0d57\u0d62\u0d63\u0d66-\u0d6f\u0d81-\u0d83\u0dca\u0dcf-\u0dd4\u0dd6\u0dd8-\u0ddf\u0de6-\u0def\u0df2\u0df3\u0e31\u0e34-\u0e3a\u0e47-\u0e4e\u0e50-\u0e59\u0eb1\u0eb4-\u0ebc\u0ec8-\u0ece\u0ed0-\u0ed9\u0f18\u0f19\u0f20-\u0f29\u0f35\u0f37\u0f39\u0f3e\u0f3f\u0f71-\u0f84\u0f86\u0f87\u0f8d-\u0f97\u0f99-\u0fbc\u0fc6\u102b-\u103e\u1040-\u1049\u1056-\u1059\u105e-\u1060\u1062-\u1064\u1067-\u106d\u1071-\u1074\u1082-\u108d\u108f-\u109d\u135d-\u135f\u1369-\u1371\u1712-\u1715\u1732-\u1734\u1752\u1753\u1772\u1773\u17b4-\u17d3\u17dd\u17e0-\u17e9\u180b-\u180d\u180f-\u1819\u18a9\u1920-\u192b\u1930-\u193b\u1946-\u194f\u19d0-\u19da\u1a17-\u1a1b\u1a55-\u1a5e\u1a60-\u1a7c\u1a7f-\u1a89\u1a90-\u1a99\u1ab0-\u1abd\u1abf-\u1ace\u1b00-\u1b04\u1b34-\u1b44\u1b50-\u1b59\u1b6b-\u1b73\u1b80-\u1b82\u1ba1-\u1bad\u1bb0-\u1bb9\u1be6-\u1bf3\u1c24-\u1c37\u1c40-\u1c49\u1c50-\u1c59\u1cd0-\u1cd2\u1cd4-\u1ce8\u1ced\u1cf4\u1cf7-\u1cf9\u1dc0-\u1dff\u200c\u200d\u203f\u2040\u2054\u20d0-\u20dc\u20e1\u20e5-\u20f0\u2cef-\u2cf1\u2d7f\u2de0-\u2dff\u302a-\u302f\u3099\u309a\u30fb\ua620-\ua629\ua66f\ua674-\ua67d\ua69e\ua69f\ua6f0\ua6f1\ua802\ua806\ua80b\ua823-\ua827\ua82c\ua880\ua881\ua8b4-\ua8c5\ua8d0-\ua8d9\ua8e0-\ua8f1\ua8ff-\ua909\ua926-\ua92d\ua947-\ua953\ua980-\ua983\ua9b3-\ua9c0\ua9d0-\ua9d9\ua9e5\ua9f0-\ua9f9\uaa29-\uaa36\uaa43\uaa4c\uaa4d\uaa50-\uaa59\uaa7b-\uaa7d\uaab0\uaab2-\uaab4\uaab7\uaab8\uaabe\uaabf\uaac1\uaaeb-\uaaef\uaaf5\uaaf6\uabe3-\uabea\uabec\uabed\uabf0-\uabf9\ufb1e\ufe00-\ufe0f\ufe20-\ufe2f\ufe33\ufe34\ufe4d-\ufe4f\uff10-\uff19\uff3f\uff65";
+const nonASCIIidentifierStart = new RegExp("[" + nonASCIIidentifierStartChars + "]");
+const nonASCIIidentifier = new RegExp("[" + nonASCIIidentifierStartChars + nonASCIIidentifierChars + "]");
+nonASCIIidentifierStartChars = nonASCIIidentifierChars = null;
+const astralIdentifierStartCodes = [0, 11, 2, 25, 2, 18, 2, 1, 2, 14, 3, 13, 35, 122, 70, 52, 268, 28, 4, 48, 48, 31, 14, 29, 6, 37, 11, 29, 3, 35, 5, 7, 2, 4, 43, 157, 19, 35, 5, 35, 5, 39, 9, 51, 13, 10, 2, 14, 2, 6, 2, 1, 2, 10, 2, 14, 2, 6, 2, 1, 4, 51, 13, 310, 10, 21, 11, 7, 25, 5, 2, 41, 2, 8, 70, 5, 3, 0, 2, 43, 2, 1, 4, 0, 3, 22, 11, 22, 10, 30, 66, 18, 2, 1, 11, 21, 11, 25, 71, 55, 7, 1, 65, 0, 16, 3, 2, 2, 2, 28, 43, 28, 4, 28, 36, 7, 2, 27, 28, 53, 11, 21, 11, 18, 14, 17, 111, 72, 56, 50, 14, 50, 14, 35, 39, 27, 10, 22, 251, 41, 7, 1, 17, 2, 60, 28, 11, 0, 9, 21, 43, 17, 47, 20, 28, 22, 13, 52, 58, 1, 3, 0, 14, 44, 33, 24, 27, 35, 30, 0, 3, 0, 9, 34, 4, 0, 13, 47, 15, 3, 22, 0, 2, 0, 36, 17, 2, 24, 20, 1, 64, 6, 2, 0, 2, 3, 2, 14, 2, 9, 8, 46, 39, 7, 3, 1, 3, 21, 2, 6, 2, 1, 2, 4, 4, 0, 19, 0, 13, 4, 31, 9, 2, 0, 3, 0, 2, 37, 2, 0, 26, 0, 2, 0, 45, 52, 19, 3, 21, 2, 31, 47, 21, 1, 2, 0, 185, 46, 42, 3, 37, 47, 21, 0, 60, 42, 14, 0, 72, 26, 38, 6, 186, 43, 117, 63, 32, 7, 3, 0, 3, 7, 2, 1, 2, 23, 16, 0, 2, 0, 95, 7, 3, 38, 17, 0, 2, 0, 29, 0, 11, 39, 8, 0, 22, 0, 12, 45, 20, 0, 19, 72, 200, 32, 32, 8, 2, 36, 18, 0, 50, 29, 113, 6, 2, 1, 2, 37, 22, 0, 26, 5, 2, 1, 2, 31, 15, 0, 328, 18, 16, 0, 2, 12, 2, 33, 125, 0, 80, 921, 103, 110, 18, 195, 2637, 96, 16, 1071, 18, 5, 26, 3994, 6, 582, 6842, 29, 1763, 568, 8, 30, 18, 78, 18, 29, 19, 47, 17, 3, 32, 20, 6, 18, 433, 44, 212, 63, 129, 74, 6, 0, 67, 12, 65, 1, 2, 0, 29, 6135, 9, 1237, 42, 9, 8936, 3, 2, 6, 2, 1, 2, 290, 16, 0, 30, 2, 3, 0, 15, 3, 9, 395, 2309, 106, 6, 12, 4, 8, 8, 9, 5991, 84, 2, 70, 2, 1, 3, 0, 3, 1, 3, 3, 2, 11, 2, 0, 2, 6, 2, 64, 2, 3, 3, 7, 2, 6, 2, 27, 2, 3, 2, 4, 2, 0, 4, 6, 2, 339, 3, 24, 2, 24, 2, 30, 2, 24, 2, 30, 2, 24, 2, 30, 2, 24, 2, 30, 2, 24, 2, 7, 1845, 30, 7, 5, 262, 61, 147, 44, 11, 6, 17, 0, 322, 29, 19, 43, 485, 27, 229, 29, 3, 0, 496, 6, 2, 3, 2, 1, 2, 14, 2, 196, 60, 67, 8, 0, 1205, 3, 2, 26, 2, 1, 2, 0, 3, 0, 2, 9, 2, 3, 2, 0, 2, 0, 7, 0, 5, 0, 2, 0, 2, 0, 2, 2, 2, 1, 2, 0, 3, 0, 2, 0, 2, 0, 2, 0, 2, 0, 2, 1, 2, 0, 3, 3, 2, 6, 2, 3, 2, 3, 2, 0, 2, 9, 2, 16, 6, 2, 2, 4, 2, 16, 4421, 42719, 33, 4153, 7, 221, 3, 5761, 15, 7472, 16, 621, 2467, 541, 1507, 4938, 6, 4191];
+const astralIdentifierCodes = [509, 0, 227, 0, 150, 4, 294, 9, 1368, 2, 2, 1, 6, 3, 41, 2, 5, 0, 166, 1, 574, 3, 9, 9, 7, 9, 32, 4, 318, 1, 80, 3, 71, 10, 50, 3, 123, 2, 54, 14, 32, 10, 3, 1, 11, 3, 46, 10, 8, 0, 46, 9, 7, 2, 37, 13, 2, 9, 6, 1, 45, 0, 13, 2, 49, 13, 9, 3, 2, 11, 83, 11, 7, 0, 3, 0, 158, 11, 6, 9, 7, 3, 56, 1, 2, 6, 3, 1, 3, 2, 10, 0, 11, 1, 3, 6, 4, 4, 68, 8, 2, 0, 3, 0, 2, 3, 2, 4, 2, 0, 15, 1, 83, 17, 10, 9, 5, 0, 82, 19, 13, 9, 214, 6, 3, 8, 28, 1, 83, 16, 16, 9, 82, 12, 9, 9, 7, 19, 58, 14, 5, 9, 243, 14, 166, 9, 71, 5, 2, 1, 3, 3, 2, 0, 2, 1, 13, 9, 120, 6, 3, 6, 4, 0, 29, 9, 41, 6, 2, 3, 9, 0, 10, 10, 47, 15, 343, 9, 54, 7, 2, 7, 17, 9, 57, 21, 2, 13, 123, 5, 4, 0, 2, 1, 2, 6, 2, 0, 9, 9, 49, 4, 2, 1, 2, 4, 9, 9, 330, 3, 10, 1, 2, 0, 49, 6, 4, 4, 14, 10, 5350, 0, 7, 14, 11465, 27, 2343, 9, 87, 9, 39, 4, 60, 6, 26, 9, 535, 9, 470, 0, 2, 54, 8, 3, 82, 0, 12, 1, 19628, 1, 4178, 9, 519, 45, 3, 22, 543, 4, 4, 5, 9, 7, 3, 6, 31, 3, 149, 2, 1418, 49, 513, 54, 5, 49, 9, 0, 15, 0, 23, 4, 2, 14, 1361, 6, 2, 16, 3, 6, 2, 1, 2, 4, 101, 0, 161, 6, 10, 9, 357, 0, 62, 13, 499, 13, 245, 1, 2, 9, 726, 6, 110, 6, 6, 9, 4759, 9, 787719, 239];
+function isInAstralSet(code, set) {
+ let pos = 0x10000;
+ for (let i = 0, length = set.length; i < length; i += 2) {
+ pos += set[i];
+ if (pos > code) return false;
+ pos += set[i + 1];
+ if (pos >= code) return true;
+ }
+ return false;
+}
+function isIdentifierStart(code) {
+ if (code < 65) return code === 36;
+ if (code <= 90) return true;
+ if (code < 97) return code === 95;
+ if (code <= 122) return true;
+ if (code <= 0xffff) {
+ return code >= 0xaa && nonASCIIidentifierStart.test(String.fromCharCode(code));
+ }
+ return isInAstralSet(code, astralIdentifierStartCodes);
+}
+function isIdentifierChar(code) {
+ if (code < 48) return code === 36;
+ if (code < 58) return true;
+ if (code < 65) return false;
+ if (code <= 90) return true;
+ if (code < 97) return code === 95;
+ if (code <= 122) return true;
+ if (code <= 0xffff) {
+ return code >= 0xaa && nonASCIIidentifier.test(String.fromCharCode(code));
+ }
+ return isInAstralSet(code, astralIdentifierStartCodes) || isInAstralSet(code, astralIdentifierCodes);
+}
+function isIdentifierName(name) {
+ let isFirst = true;
+ for (let i = 0; i < name.length; i++) {
+ let cp = name.charCodeAt(i);
+ if ((cp & 0xfc00) === 0xd800 && i + 1 < name.length) {
+ const trail = name.charCodeAt(++i);
+ if ((trail & 0xfc00) === 0xdc00) {
+ cp = 0x10000 + ((cp & 0x3ff) << 10) + (trail & 0x3ff);
+ }
+ }
+ if (isFirst) {
+ isFirst = false;
+ if (!isIdentifierStart(cp)) {
+ return false;
+ }
+ } else if (!isIdentifierChar(cp)) {
+ return false;
+ }
+ }
+ return !isFirst;
+}
+
+//# sourceMappingURL=identifier.js.map
diff --git a/node_modules/@babel/helper-validator-identifier/lib/identifier.js.map b/node_modules/@babel/helper-validator-identifier/lib/identifier.js.map
new file mode 100644
index 0000000..ecf0952
--- /dev/null
+++ b/node_modules/@babel/helper-validator-identifier/lib/identifier.js.map
@@ -0,0 +1 @@
+{"version":3,"names":["nonASCIIidentifierStartChars","nonASCIIidentifierChars","nonASCIIidentifierStart","RegExp","nonASCIIidentifier","astralIdentifierStartCodes","astralIdentifierCodes","isInAstralSet","code","set","pos","i","length","isIdentifierStart","test","String","fromCharCode","isIdentifierChar","isIdentifierName","name","isFirst","cp","charCodeAt","trail"],"sources":["../src/identifier.ts"],"sourcesContent":["// We inline this package\n// eslint-disable-next-line import/no-extraneous-dependencies\nimport * as charCodes from \"charcodes\";\n\n// ## Character categories\n\n// Big ugly regular expressions that match characters in the\n// whitespace, identifier, and identifier-start categories. These\n// are only applied when a character is found to actually have a\n// code point between 0x80 and 0xffff.\n// Generated by `scripts/generate-identifier-regex.cjs`.\n\n/* prettier-ignore */\nlet nonASCIIidentifierStartChars = \"\\xaa\\xb5\\xba\\xc0-\\xd6\\xd8-\\xf6\\xf8-\\u02c1\\u02c6-\\u02d1\\u02e0-\\u02e4\\u02ec\\u02ee\\u0370-\\u0374\\u0376\\u0377\\u037a-\\u037d\\u037f\\u0386\\u0388-\\u038a\\u038c\\u038e-\\u03a1\\u03a3-\\u03f5\\u03f7-\\u0481\\u048a-\\u052f\\u0531-\\u0556\\u0559\\u0560-\\u0588\\u05d0-\\u05ea\\u05ef-\\u05f2\\u0620-\\u064a\\u066e\\u066f\\u0671-\\u06d3\\u06d5\\u06e5\\u06e6\\u06ee\\u06ef\\u06fa-\\u06fc\\u06ff\\u0710\\u0712-\\u072f\\u074d-\\u07a5\\u07b1\\u07ca-\\u07ea\\u07f4\\u07f5\\u07fa\\u0800-\\u0815\\u081a\\u0824\\u0828\\u0840-\\u0858\\u0860-\\u086a\\u0870-\\u0887\\u0889-\\u088e\\u08a0-\\u08c9\\u0904-\\u0939\\u093d\\u0950\\u0958-\\u0961\\u0971-\\u0980\\u0985-\\u098c\\u098f\\u0990\\u0993-\\u09a8\\u09aa-\\u09b0\\u09b2\\u09b6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ea5\\u0ea7-\\u0eb0\\u0eb2\\u0eb3\\u0ebd\\u0ec0-\\u0ec4\\u0ec6\\u0edc-\\u0edf\\u0f00\\u0f40-\\u0f47\\u0f49-\\u0f6c\\u0f88-\\u0f8c\\u1000-\\u102a\\u103f\\u1050-\\u1055\\u105a-\\u105d\\u1061\\u1065\\u1066\\u106e-\\u1070\\u1075-\\u1081\\u108e\\u10a0-\\u10c5\\u10c7\\u10cd\\u10d0-\\u10fa\\u10fc-\\u1248\\u124a-\\u124d\\u1250-\\u1256\\u1258\\u125a-\\u125d\\u1260-\\u1288\\u128a-\\u128d\\u1290-\\u12b0\\u12b2-\\u12b5\\u12b8-\\u12be\\u12c0\\u12c2-\\u12c5\\u12c8-\\u12d6\\u12d8-\\u1310\\u1312-\\u1315\\u1318-\\u135a\\u1380-\\u138f\\u13a0-\\u13f5\\u13f8-\\u13fd\\u1401-\\u166c\\u166f-\\u167f\\u1681-\\u169a\\u16a0-\\u16ea\\u16ee-\\u16f8\\u1700-\\u1711\\u171f-\\u1731\\u1740-\\u1751\\u1760-\\u176c\\u176e-\\u1770\\u1780-\\u17b3\\u17d7\\u17dc\\u1820-\\u1878\\u1880-\\u18a8\\u18aa\\u18b0-\\u18f5\\u1900-\\u191e\\u1950-\\u196d\\u1970-\\u1974\\u1980-\\u19ab\\u19b0-\\u19c9\\u1a00-\\u1a16\\u1a20-\\u1a54\\u1aa7\\u1b05-\\u1b33\\u1b45-\\u1b4c\\u1b83-\\u1ba0\\u1bae\\u1baf\\u1bba-\\u1be5\\u1c00-\\u1c23\\u1c4d-\\u1c4f\\u1c5a-\\u1c7d\\u1c80-\\u1c8a\\u1c90-\\u1cba\\u1cbd-\\u1cbf\\u1ce9-\\u1cec\\u1cee-\\u1cf3\\u1cf5\\u1cf6\\u1cfa\\u1d00-\\u1dbf\\u1e00-\\u1f15\\u1f18-\\u1f1d\\u1f20-\\u1f45\\u1f48-\\u1f4d\\u1f50-\\u1f57\\u1f59\\u1f5b\\u1f5d\\u1f5f-\\u1f7d\\u1f80-\\u1fb4\\u1fb6-\\u1fbc\\u1fbe\\u1fc2-\\u1fc4\\u1fc6-\\u1fcc\\u1fd0-\\u1fd3\\u1fd6-\\u1fdb\\u1fe0-\\u1fec\\u1ff2-\\u1ff4\\u1ff6-\\u1ffc\\u2071\\u207f\\u2090-\\u209c\\u2102\\u2107\\u210a-\\u2113\\u2115\\u2118-\\u211d\\u2124\\u2126\\u2128\\u212a-\\u2139\\u213c-\\u213f\\u2145-\\u2149\\u214e\\u2160-\\u2188\\u2c00-\\u2ce4\\u2ceb-\\u2cee\\u2cf2\\u2cf3\\u2d00-\\u2d25\\u2d27\\u2d2d\\u2d30-\\u2d67\\u2d6f\\u2d80-\\u2d96\\u2da0-\\u2da6\\u2da8-\\u2dae\\u2db0-\\u2db6\\u2db8-\\u2dbe\\u2dc0-\\u2dc6\\u2dc8-\\u2dce\\u2dd0-\\u2dd6\\u2dd8-\\u2dde\\u3005-\\u3007\\u3021-\\u3029\\u3031-\\u3035\\u3038-\\u303c\\u3041-\\u3096\\u309b-\\u309f\\u30a1-\\u30fa\\u30fc-\\u30ff\\u3105-\\u312f\\u3131-\\u318e\\u31a0-\\u31bf\\u31f0-\\u31ff\\u3400-\\u4dbf\\u4e00-\\ua48c\\ua4d0-\\ua4fd\\ua500-\\ua60c\\ua610-\\ua61f\\ua62a\\ua62b\\ua640-\\ua66e\\ua67f-\\ua69d\\ua6a0-\\ua6ef\\ua717-\\ua71f\\ua722-\\ua788\\ua78b-\\ua7cd\\ua7d0\\ua7d1\\ua7d3\\ua7d5-\\ua7dc\\ua7f2-\\ua801\\ua803-\\ua805\\ua807-\\ua80a\\ua80c-\\ua822\\ua840-\\ua873\\ua882-\\ua8b3\\ua8f2-\\ua8f7\\ua8fb\\ua8fd\\ua8fe\\ua90a-\\ua925\\ua930-\\ua946\\ua960-\\ua97c\\ua984-\\ua9b2\\ua9cf\\ua9e0-\\ua9e4\\ua9e6-\\ua9ef\\ua9fa-\\ua9fe\\uaa00-\\uaa28\\uaa40-\\uaa42\\uaa44-\\uaa4b\\uaa60-\\uaa76\\uaa7a\\uaa7e-\\uaaaf\\uaab1\\uaab5\\uaab6\\uaab9-\\uaabd\\uaac0\\uaac2\\uaadb-\\uaadd\\uaae0-\\uaaea\\uaaf2-\\uaaf4\\uab01-\\uab06\\uab09-\\uab0e\\uab11-\\uab16\\uab20-\\uab26\\uab28-\\uab2e\\uab30-\\uab5a\\uab5c-\\uab69\\uab70-\\uabe2\\uac00-\\ud7a3\\ud7b0-\\ud7c6\\ud7cb-\\ud7fb\\uf900-\\ufa6d\\ufa70-\\ufad9\\ufb00-\\ufb06\\ufb13-\\ufb17\\ufb1d\\ufb1f-\\ufb28\\ufb2a-\\ufb36\\ufb38-\\ufb3c\\ufb3e\\ufb40\\ufb41\\ufb43\\ufb44\\ufb46-\\ufbb1\\ufbd3-\\ufd3d\\ufd50-\\ufd8f\\ufd92-\\ufdc7\\ufdf0-\\ufdfb\\ufe70-\\ufe74\\ufe76-\\ufefc\\uff21-\\uff3a\\uff41-\\uff5a\\uff66-\\uffbe\\uffc2-\\uffc7\\uffca-\\uffcf\\uffd2-\\uffd7\\uffda-\\uffdc\";\n/* prettier-ignore */\nlet nonASCIIidentifierChars = \"\\xb7\\u0300-\\u036f\\u0387\\u0483-\\u0487\\u0591-\\u05bd\\u05bf\\u05c1\\u05c2\\u05c4\\u05c5\\u05c7\\u0610-\\u061a\\u064b-\\u0669\\u0670\\u06d6-\\u06dc\\u06df-\\u06e4\\u06e7\\u06e8\\u06ea-\\u06ed\\u06f0-\\u06f9\\u0711\\u0730-\\u074a\\u07a6-\\u07b0\\u07c0-\\u07c9\\u07eb-\\u07f3\\u07fd\\u0816-\\u0819\\u081b-\\u0823\\u0825-\\u0827\\u0829-\\u082d\\u0859-\\u085b\\u0897-\\u089f\\u08ca-\\u08e1\\u08e3-\\u0903\\u093a-\\u093c\\u093e-\\u094f\\u0951-\\u0957\\u0962\\u0963\\u0966-\\u096f\\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0f8d-\\u0f97\\u0f99-\\u0fbc\\u0fc6\\u102b-\\u103e\\u1040-\\u1049\\u1056-\\u1059\\u105e-\\u1060\\u1062-\\u1064\\u1067-\\u106d\\u1071-\\u1074\\u1082-\\u108d\\u108f-\\u109d\\u135d-\\u135f\\u1369-\\u1371\\u1712-\\u1715\\u1732-\\u1734\\u1752\\u1753\\u1772\\u1773\\u17b4-\\u17d3\\u17dd\\u17e0-\\u17e9\\u180b-\\u180d\\u180f-\\u1819\\u18a9\\u1920-\\u192b\\u1930-\\u193b\\u1946-\\u194f\\u19d0-\\u19da\\u1a17-\\u1a1b\\u1a55-\\u1a5e\\u1a60-\\u1a7c\\u1a7f-\\u1a89\\u1a90-\\u1a99\\u1ab0-\\u1abd\\u1abf-\\u1ace\\u1b00-\\u1b04\\u1b34-\\u1b44\\u1b50-\\u1b59\\u1b6b-\\u1b73\\u1b80-\\u1b82\\u1ba1-\\u1bad\\u1bb0-\\u1bb9\\u1be6-\\u1bf3\\u1c24-\\u1c37\\u1c40-\\u1c49\\u1c50-\\u1c59\\u1cd0-\\u1cd2\\u1cd4-\\u1ce8\\u1ced\\u1cf4\\u1cf7-\\u1cf9\\u1dc0-\\u1dff\\u200c\\u200d\\u203f\\u2040\\u2054\\u20d0-\\u20dc\\u20e1\\u20e5-\\u20f0\\u2cef-\\u2cf1\\u2d7f\\u2de0-\\u2dff\\u302a-\\u302f\\u3099\\u309a\\u30fb\\ua620-\\ua629\\ua66f\\ua674-\\ua67d\\ua69e\\ua69f\\ua6f0\\ua6f1\\ua802\\ua806\\ua80b\\ua823-\\ua827\\ua82c\\ua880\\ua881\\ua8b4-\\ua8c5\\ua8d0-\\ua8d9\\ua8e0-\\ua8f1\\ua8ff-\\ua909\\ua926-\\ua92d\\ua947-\\ua953\\ua980-\\ua983\\ua9b3-\\ua9c0\\ua9d0-\\ua9d9\\ua9e5\\ua9f0-\\ua9f9\\uaa29-\\uaa36\\uaa43\\uaa4c\\uaa4d\\uaa50-\\uaa59\\uaa7b-\\uaa7d\\uaab0\\uaab2-\\uaab4\\uaab7\\uaab8\\uaabe\\uaabf\\uaac1\\uaaeb-\\uaaef\\uaaf5\\uaaf6\\uabe3-\\uabea\\uabec\\uabed\\uabf0-\\uabf9\\ufb1e\\ufe00-\\ufe0f\\ufe20-\\ufe2f\\ufe33\\ufe34\\ufe4d-\\ufe4f\\uff10-\\uff19\\uff3f\\uff65\";\n\nconst nonASCIIidentifierStart = new RegExp(\n \"[\" + nonASCIIidentifierStartChars + \"]\",\n);\nconst nonASCIIidentifier = new RegExp(\n \"[\" + nonASCIIidentifierStartChars + nonASCIIidentifierChars + \"]\",\n);\n\nnonASCIIidentifierStartChars = nonASCIIidentifierChars = null;\n\n// These are a run-length and offset-encoded representation of the\n// >0xffff code points that are a valid part of identifiers. The\n// offset starts at 0x10000, and each pair of numbers represents an\n// offset to the next range, and then a size of the range. They were\n// generated by `scripts/generate-identifier-regex.cjs`.\n/* prettier-ignore */\nconst astralIdentifierStartCodes = [0,11,2,25,2,18,2,1,2,14,3,13,35,122,70,52,268,28,4,48,48,31,14,29,6,37,11,29,3,35,5,7,2,4,43,157,19,35,5,35,5,39,9,51,13,10,2,14,2,6,2,1,2,10,2,14,2,6,2,1,4,51,13,310,10,21,11,7,25,5,2,41,2,8,70,5,3,0,2,43,2,1,4,0,3,22,11,22,10,30,66,18,2,1,11,21,11,25,71,55,7,1,65,0,16,3,2,2,2,28,43,28,4,28,36,7,2,27,28,53,11,21,11,18,14,17,111,72,56,50,14,50,14,35,39,27,10,22,251,41,7,1,17,2,60,28,11,0,9,21,43,17,47,20,28,22,13,52,58,1,3,0,14,44,33,24,27,35,30,0,3,0,9,34,4,0,13,47,15,3,22,0,2,0,36,17,2,24,20,1,64,6,2,0,2,3,2,14,2,9,8,46,39,7,3,1,3,21,2,6,2,1,2,4,4,0,19,0,13,4,31,9,2,0,3,0,2,37,2,0,26,0,2,0,45,52,19,3,21,2,31,47,21,1,2,0,185,46,42,3,37,47,21,0,60,42,14,0,72,26,38,6,186,43,117,63,32,7,3,0,3,7,2,1,2,23,16,0,2,0,95,7,3,38,17,0,2,0,29,0,11,39,8,0,22,0,12,45,20,0,19,72,200,32,32,8,2,36,18,0,50,29,113,6,2,1,2,37,22,0,26,5,2,1,2,31,15,0,328,18,16,0,2,12,2,33,125,0,80,921,103,110,18,195,2637,96,16,1071,18,5,26,3994,6,582,6842,29,1763,568,8,30,18,78,18,29,19,47,17,3,32,20,6,18,433,44,212,63,129,74,6,0,67,12,65,1,2,0,29,6135,9,1237,42,9,8936,3,2,6,2,1,2,290,16,0,30,2,3,0,15,3,9,395,2309,106,6,12,4,8,8,9,5991,84,2,70,2,1,3,0,3,1,3,3,2,11,2,0,2,6,2,64,2,3,3,7,2,6,2,27,2,3,2,4,2,0,4,6,2,339,3,24,2,24,2,30,2,24,2,30,2,24,2,30,2,24,2,30,2,24,2,7,1845,30,7,5,262,61,147,44,11,6,17,0,322,29,19,43,485,27,229,29,3,0,496,6,2,3,2,1,2,14,2,196,60,67,8,0,1205,3,2,26,2,1,2,0,3,0,2,9,2,3,2,0,2,0,7,0,5,0,2,0,2,0,2,2,2,1,2,0,3,0,2,0,2,0,2,0,2,0,2,1,2,0,3,3,2,6,2,3,2,3,2,0,2,9,2,16,6,2,2,4,2,16,4421,42719,33,4153,7,221,3,5761,15,7472,16,621,2467,541,1507,4938,6,4191];\n/* prettier-ignore */\nconst astralIdentifierCodes = [509,0,227,0,150,4,294,9,1368,2,2,1,6,3,41,2,5,0,166,1,574,3,9,9,7,9,32,4,318,1,80,3,71,10,50,3,123,2,54,14,32,10,3,1,11,3,46,10,8,0,46,9,7,2,37,13,2,9,6,1,45,0,13,2,49,13,9,3,2,11,83,11,7,0,3,0,158,11,6,9,7,3,56,1,2,6,3,1,3,2,10,0,11,1,3,6,4,4,68,8,2,0,3,0,2,3,2,4,2,0,15,1,83,17,10,9,5,0,82,19,13,9,214,6,3,8,28,1,83,16,16,9,82,12,9,9,7,19,58,14,5,9,243,14,166,9,71,5,2,1,3,3,2,0,2,1,13,9,120,6,3,6,4,0,29,9,41,6,2,3,9,0,10,10,47,15,343,9,54,7,2,7,17,9,57,21,2,13,123,5,4,0,2,1,2,6,2,0,9,9,49,4,2,1,2,4,9,9,330,3,10,1,2,0,49,6,4,4,14,10,5350,0,7,14,11465,27,2343,9,87,9,39,4,60,6,26,9,535,9,470,0,2,54,8,3,82,0,12,1,19628,1,4178,9,519,45,3,22,543,4,4,5,9,7,3,6,31,3,149,2,1418,49,513,54,5,49,9,0,15,0,23,4,2,14,1361,6,2,16,3,6,2,1,2,4,101,0,161,6,10,9,357,0,62,13,499,13,245,1,2,9,726,6,110,6,6,9,4759,9,787719,239];\n\n// This has a complexity linear to the value of the code. The\n// assumption is that looking up astral identifier characters is\n// rare.\nfunction isInAstralSet(code: number, set: readonly number[]): boolean {\n let pos = 0x10000;\n for (let i = 0, length = set.length; i < length; i += 2) {\n pos += set[i];\n if (pos > code) return false;\n\n pos += set[i + 1];\n if (pos >= code) return true;\n }\n return false;\n}\n\n// Test whether a given character code starts an identifier.\n\nexport function isIdentifierStart(code: number): boolean {\n if (code < charCodes.uppercaseA) return code === charCodes.dollarSign;\n if (code <= charCodes.uppercaseZ) return true;\n if (code < charCodes.lowercaseA) return code === charCodes.underscore;\n if (code <= charCodes.lowercaseZ) return true;\n if (code <= 0xffff) {\n return (\n code >= 0xaa && nonASCIIidentifierStart.test(String.fromCharCode(code))\n );\n }\n return isInAstralSet(code, astralIdentifierStartCodes);\n}\n\n// Test whether a given character is part of an identifier.\n\nexport function isIdentifierChar(code: number): boolean {\n if (code < charCodes.digit0) return code === charCodes.dollarSign;\n if (code < charCodes.colon) return true;\n if (code < charCodes.uppercaseA) return false;\n if (code <= charCodes.uppercaseZ) return true;\n if (code < charCodes.lowercaseA) return code === charCodes.underscore;\n if (code <= charCodes.lowercaseZ) return true;\n if (code <= 0xffff) {\n return code >= 0xaa && nonASCIIidentifier.test(String.fromCharCode(code));\n }\n return (\n isInAstralSet(code, astralIdentifierStartCodes) ||\n isInAstralSet(code, astralIdentifierCodes)\n );\n}\n\n// Test whether a given string is a valid identifier name\n\nexport function isIdentifierName(name: string): boolean {\n let isFirst = true;\n for (let i = 0; i < name.length; i++) {\n // The implementation is based on\n // https://source.chromium.org/chromium/chromium/src/+/master:v8/src/builtins/builtins-string-gen.cc;l=1455;drc=221e331b49dfefadbc6fa40b0c68e6f97606d0b3;bpv=0;bpt=1\n // We reimplement `codePointAt` because `codePointAt` is a V8 builtin which is not inlined by TurboFan (as of M91)\n // since `name` is mostly ASCII, an inlined `charCodeAt` wins here\n let cp = name.charCodeAt(i);\n if ((cp & 0xfc00) === 0xd800 && i + 1 < name.length) {\n const trail = name.charCodeAt(++i);\n if ((trail & 0xfc00) === 0xdc00) {\n cp = 0x10000 + ((cp & 0x3ff) << 10) + (trail & 0x3ff);\n }\n }\n if (isFirst) {\n isFirst = false;\n if (!isIdentifierStart(cp)) {\n return false;\n }\n } else if (!isIdentifierChar(cp)) {\n return false;\n }\n }\n return !isFirst;\n}\n"],"mappings":";;;;;;;;AAaA,IAAIA,4BAA4B,GAAG,8qIAA8qI;AAEjtI,IAAIC,uBAAuB,GAAG,+kFAA+kF;AAE7mF,MAAMC,uBAAuB,GAAG,IAAIC,MAAM,CACxC,GAAG,GAAGH,4BAA4B,GAAG,GACvC,CAAC;AACD,MAAMI,kBAAkB,GAAG,IAAID,MAAM,CACnC,GAAG,GAAGH,4BAA4B,GAAGC,uBAAuB,GAAG,GACjE,CAAC;AAEDD,4BAA4B,GAAGC,uBAAuB,GAAG,IAAI;AAQ7D,MAAMI,0BAA0B,GAAG,CAAC,CAAC,EAAC,EAAE,EAAC,CAAC,EAAC,EAAE,EAAC,CAAC,EAAC,EAAE,EAAC,CAAC,EAAC,CAAC,EAAC,CAAC,EAAC,EAAE,EAAC,CAAC,EAAC,EAAE,EAAC,EAAE,EAAC,GAAG,EAAC,EAAE,EAAC,EAAE,EAAC,GAAG,EAAC,EAAE,EAAC,CAAC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gBAAgBA,CAACC,IAAY,EAAW;EACtD,IAAIC,OAAO,GAAG,IAAI;EAClB,KAAK,IAAIT,CAAC,GAAG,CAAC,EAAEA,CAAC,GAAGQ,IAAI,CAACP,MAAM,EAAED,CAAC,EAAE,EAAE;IAKpC,IAAIU,EAAE,GAAGF,IAAI,CAACG,UAAU,CAACX,CAAC,CAAC;IAC3B,IAAI,CAACU,EAAE,GAAG,MAAM,MAAM,MAAM,IAAIV,CAAC,GAAG,CAAC,GAAGQ,IAAI,CAACP,MAAM,EAAE;MACnD,MAAMW,KAAK,GAAGJ,IAAI,CAACG,UAAU,CAAC,EAAEX,CAAC,CAAC;MAClC,IAAI,CAACY,KAAK,GAAG,MAAM,MAAM,MAAM,EAAE;QAC/BF,EAAE,GAAG,OAAO,IAAI,CAACA,EAAE,GAAG,KAAK,KAAK,EAAE,CAAC,IAAIE,KAAK,GAAG,KAAK,CAAC;MACvD;IACF;IACA,IAAIH,OAAO,EAAE;MACXA,OAAO,GAAG,KAAK;MACf,IAAI,CAACP,iBAAiB,CAACQ,EAAE,CAAC,EAAE;QAC1B,OAAO,KAAK;MACd;IACF,CAAC,MAAM,IAAI,CAACJ,gBAAgB,CAACI,EAAE,CAAC,EAAE;MAChC,OAAO,KAAK;IACd;EACF;EACA,OAAO,CAACD,OAAO;AACjB","ignoreList":[]}
\ No newline at end of file
diff --git a/node_modules/@babel/helper-validator-identifier/lib/index.js b/node_modules/@babel/helper-validator-identifier/lib/index.js
new file mode 100644
index 0000000..76b2282
--- /dev/null
+++ b/node_modules/@babel/helper-validator-identifier/lib/index.js
@@ -0,0 +1,57 @@
+"use strict";
+
+Object.defineProperty(exports, "__esModule", {
+ value: true
+});
+Object.defineProperty(exports, "isIdentifierChar", {
+ enumerable: true,
+ get: function () {
+ return _identifier.isIdentifierChar;
+ }
+});
+Object.defineProperty(exports, "isIdentifierName", {
+ enumerable: true,
+ get: function () {
+ return _identifier.isIdentifierName;
+ }
+});
+Object.defineProperty(exports, "isIdentifierStart", {
+ enumerable: true,
+ get: function () {
+ return _identifier.isIdentifierStart;
+ }
+});
+Object.defineProperty(exports, "isKeyword", {
+ enumerable: true,
+ get: function () {
+ return _keyword.isKeyword;
+ }
+});
+Object.defineProperty(exports, "isReservedWord", {
+ enumerable: true,
+ get: function () {
+ return _keyword.isReservedWord;
+ }
+});
+Object.defineProperty(exports, "isStrictBindOnlyReservedWord", {
+ enumerable: true,
+ get: function () {
+ return _keyword.isStrictBindOnlyReservedWord;
+ }
+});
+Object.defineProperty(exports, "isStrictBindReservedWord", {
+ enumerable: true,
+ get: function () {
+ return _keyword.isStrictBindReservedWord;
+ }
+});
+Object.defineProperty(exports, "isStrictReservedWord", {
+ enumerable: true,
+ get: function () {
+ return _keyword.isStrictReservedWord;
+ }
+});
+var _identifier = require("./identifier.js");
+var _keyword = require("./keyword.js");
+
+//# sourceMappingURL=index.js.map
diff --git a/node_modules/@babel/helper-validator-identifier/lib/index.js.map b/node_modules/@babel/helper-validator-identifier/lib/index.js.map
new file mode 100644
index 0000000..d985f3b
--- /dev/null
+++ b/node_modules/@babel/helper-validator-identifier/lib/index.js.map
@@ -0,0 +1 @@
+{"version":3,"names":["_identifier","require","_keyword"],"sources":["../src/index.ts"],"sourcesContent":["export {\n isIdentifierName,\n isIdentifierChar,\n isIdentifierStart,\n} from \"./identifier.ts\";\nexport {\n isReservedWord,\n isStrictBindOnlyReservedWord,\n isStrictBindReservedWord,\n isStrictReservedWord,\n isKeyword,\n} from \"./keyword.ts\";\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,IAAAA,WAAA,GAAAC,OAAA;AAKA,IAAAC,QAAA,GAAAD,OAAA","ignoreList":[]}
\ No newline at end of file
diff --git a/node_modules/@babel/helper-validator-identifier/lib/keyword.js b/node_modules/@babel/helper-validator-identifier/lib/keyword.js
new file mode 100644
index 0000000..054cf84
--- /dev/null
+++ b/node_modules/@babel/helper-validator-identifier/lib/keyword.js
@@ -0,0 +1,35 @@
+"use strict";
+
+Object.defineProperty(exports, "__esModule", {
+ value: true
+});
+exports.isKeyword = isKeyword;
+exports.isReservedWord = isReservedWord;
+exports.isStrictBindOnlyReservedWord = isStrictBindOnlyReservedWord;
+exports.isStrictBindReservedWord = isStrictBindReservedWord;
+exports.isStrictReservedWord = isStrictReservedWord;
+const reservedWords = {
+ keyword: ["break", "case", "catch", "continue", "debugger", "default", "do", "else", "finally", "for", "function", "if", "return", "switch", "throw", "try", "var", "const", "while", "with", "new", "this", "super", "class", "extends", "export", "import", "null", "true", "false", "in", "instanceof", "typeof", "void", "delete"],
+ strict: ["implements", "interface", "let", "package", "private", "protected", "public", "static", "yield"],
+ strictBind: ["eval", "arguments"]
+};
+const keywords = new Set(reservedWords.keyword);
+const reservedWordsStrictSet = new Set(reservedWords.strict);
+const reservedWordsStrictBindSet = new Set(reservedWords.strictBind);
+function isReservedWord(word, inModule) {
+ return inModule && word === "await" || word === "enum";
+}
+function isStrictReservedWord(word, inModule) {
+ return isReservedWord(word, inModule) || reservedWordsStrictSet.has(word);
+}
+function isStrictBindOnlyReservedWord(word) {
+ return reservedWordsStrictBindSet.has(word);
+}
+function isStrictBindReservedWord(word, inModule) {
+ return isStrictReservedWord(word, inModule) || isStrictBindOnlyReservedWord(word);
+}
+function isKeyword(word) {
+ return keywords.has(word);
+}
+
+//# sourceMappingURL=keyword.js.map
diff --git a/node_modules/@babel/helper-validator-identifier/lib/keyword.js.map b/node_modules/@babel/helper-validator-identifier/lib/keyword.js.map
new file mode 100644
index 0000000..3471f78
--- /dev/null
+++ b/node_modules/@babel/helper-validator-identifier/lib/keyword.js.map
@@ -0,0 +1 @@
+{"version":3,"names":["reservedWords","keyword","strict","strictBind","keywords","Set","reservedWordsStrictSet","reservedWordsStrictBindSet","isReservedWord","word","inModule","isStrictReservedWord","has","isStrictBindOnlyReservedWord","isStrictBindReservedWord","isKeyword"],"sources":["../src/keyword.ts"],"sourcesContent":["const reservedWords = {\n keyword: [\n \"break\",\n \"case\",\n \"catch\",\n \"continue\",\n \"debugger\",\n \"default\",\n \"do\",\n \"else\",\n \"finally\",\n \"for\",\n \"function\",\n \"if\",\n \"return\",\n \"switch\",\n \"throw\",\n \"try\",\n \"var\",\n \"const\",\n \"while\",\n \"with\",\n \"new\",\n \"this\",\n \"super\",\n \"class\",\n \"extends\",\n \"export\",\n \"import\",\n \"null\",\n \"true\",\n \"false\",\n \"in\",\n \"instanceof\",\n \"typeof\",\n \"void\",\n \"delete\",\n ],\n strict: [\n \"implements\",\n \"interface\",\n \"let\",\n \"package\",\n \"private\",\n \"protected\",\n \"public\",\n \"static\",\n \"yield\",\n ],\n strictBind: [\"eval\", \"arguments\"],\n};\nconst keywords = new Set(reservedWords.keyword);\nconst reservedWordsStrictSet = new Set(reservedWords.strict);\nconst reservedWordsStrictBindSet = new Set(reservedWords.strictBind);\n\n/**\n * Checks if word is a reserved word in non-strict mode\n */\nexport function isReservedWord(word: string, inModule: boolean): boolean {\n return (inModule && word === \"await\") || word === \"enum\";\n}\n\n/**\n * Checks if word is a reserved word in non-binding strict mode\n *\n * Includes non-strict reserved words\n */\nexport function isStrictReservedWord(word: string, inModule: boolean): boolean {\n return isReservedWord(word, inModule) || reservedWordsStrictSet.has(word);\n}\n\n/**\n * Checks if word is a reserved word in binding strict mode, but it is allowed as\n * a normal identifier.\n */\nexport function isStrictBindOnlyReservedWord(word: string): boolean {\n return reservedWordsStrictBindSet.has(word);\n}\n\n/**\n * Checks if word is a reserved word in binding strict mode\n *\n * Includes non-strict reserved words and non-binding strict reserved words\n */\nexport function isStrictBindReservedWord(\n word: string,\n inModule: boolean,\n): boolean {\n return (\n isStrictReservedWord(word, inModule) || isStrictBindOnlyReservedWord(word)\n );\n}\n\nexport function isKeyword(word: string): boolean {\n return keywords.has(word);\n}\n"],"mappings":";;;;;;;;;;AAAA,MAAMA,aAAa,GAAG;EACpBC,OAAO,EAAE,CACP,OAAO,EACP,MAAM,EACN,OAAO,EACP,UAA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,CAAC,IAAIG,4BAA4B,CAACJ,IAAI,CAAC;AAE9E;AAEO,SAASM,SAASA,CAACN,IAAY,EAAW;EAC/C,OAAOL,QAAQ,CAACQ,GAAG,CAACH,IAAI,CAAC;AAC3B","ignoreList":[]}
\ No newline at end of file
diff --git a/node_modules/@babel/helper-validator-identifier/package.json b/node_modules/@babel/helper-validator-identifier/package.json
new file mode 100644
index 0000000..316dff6
--- /dev/null
+++ b/node_modules/@babel/helper-validator-identifier/package.json
@@ -0,0 +1,31 @@
+{
+ "name": "@babel/helper-validator-identifier",
+ "version": "7.27.1",
+ "description": "Validate identifier/keywords name",
+ "repository": {
+ "type": "git",
+ "url": "https://github.com/babel/babel.git",
+ "directory": "packages/babel-helper-validator-identifier"
+ },
+ "license": "MIT",
+ "publishConfig": {
+ "access": "public"
+ },
+ "main": "./lib/index.js",
+ "exports": {
+ ".": {
+ "types": "./lib/index.d.ts",
+ "default": "./lib/index.js"
+ },
+ "./package.json": "./package.json"
+ },
+ "devDependencies": {
+ "@unicode/unicode-16.0.0": "^1.0.0",
+ "charcodes": "^0.2.0"
+ },
+ "engines": {
+ "node": ">=6.9.0"
+ },
+ "author": "The Babel Team (https://babel.dev/team)",
+ "type": "commonjs"
+}
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/README.md b/node_modules/@puppeteer/browsers/README.md
new file mode 100644
index 0000000..85eb6d8
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/README.md
@@ -0,0 +1,88 @@
+# @puppeteer/browsers
+
+Manage and launch browsers/drivers from a CLI or programmatically.
+
+## System requirements
+
+- A compatible Node version (see `engines` in `package.json`).
+- For Firefox downloads:
+ - Linux builds: `xz` and `bzip2` utilities are required to unpack `.tar.gz` and `.tar.bz2` archives.
+ - MacOS builds: `hdiutil` is required to unpack `.dmg` archives.
+
+## CLI
+
+Use `npx` to run the CLI:
+
+```bash
+# This will install and run the @puppeteer/browsers package.
+# If it is already installed in the current directory, the installed
+# version will be used.
+npx @puppeteer/browsers --help
+```
+
+Built-in per-command `help` will provide all documentation you need to use the CLI.
+
+```bash
+npx @puppeteer/browsers --help # help for all commands
+npx @puppeteer/browsers install --help # help for the install command
+npx @puppeteer/browsers launch --help # help for the launch command
+npx @puppeteer/browsers clear --help # help for the clear command
+npx @puppeteer/browsers list --help # help for the list command
+```
+
+You can specify the version of the `@puppeteer/browsers` when using
+`npx`:
+
+```bash
+# Always install and use the latest version from the registry.
+npx @puppeteer/browsers@latest --help
+# Always use a specifc version.
+npx @puppeteer/browsers@2.4.1 --help
+# Always install the latest version and automatically confirm the installation.
+npx --yes @puppeteer/browsers@latest --help
+```
+
+To clear all installed browsers, use the `clear` command:
+
+```bash
+npx @puppeteer/browsers clear
+```
+
+To list all installed browsers, use the `list` command:
+
+```bash
+npx @puppeteer/browsers list
+```
+
+Some example to give an idea of what the CLI looks like (use the `--help` command for more examples):
+
+```sh
+# Download the latest available Chrome for Testing binary corresponding to the Stable channel.
+npx @puppeteer/browsers install chrome@stable
+
+# Download a specific Chrome for Testing version.
+npx @puppeteer/browsers install chrome@116.0.5793.0
+
+# Download the latest Chrome for Testing version for the given milestone.
+npx @puppeteer/browsers install chrome@117
+
+# Download the latest available ChromeDriver version corresponding to the Canary channel.
+npx @puppeteer/browsers install chromedriver@canary
+
+# Download a specific ChromeDriver version.
+npx @puppeteer/browsers install chromedriver@116.0.5793.0
+
+# On Ubuntu/Debian and only for Chrome, install the browser and required system dependencies.
+# If the browser version has already been installed, the command
+# will still attempt to install system dependencies.
+# Requires root privileges.
+npx puppeteer browsers install chrome --install-deps
+```
+
+## Known limitations
+
+1. Launching the system browsers is only possible for Chrome/Chromium.
+
+## API
+
+The programmatic API allows installing and launching browsers from your code. See the `test` folder for examples on how to use the `install`, `canInstall`, `launch`, `computeExecutablePath`, `computeSystemExecutablePath` and other methods.
diff --git a/node_modules/@puppeteer/browsers/lib/cjs/CLI.d.ts b/node_modules/@puppeteer/browsers/lib/cjs/CLI.d.ts
new file mode 100644
index 0000000..4923b42
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/cjs/CLI.d.ts
@@ -0,0 +1,29 @@
+/**
+ * @license
+ * Copyright 2023 Google Inc.
+ * SPDX-License-Identifier: Apache-2.0
+ */
+import * as readline from 'node:readline';
+import { Browser } from './browser-data/browser-data.js';
+/**
+ * @public
+ */
+export declare class CLI {
+ #private;
+ constructor(opts?: string | {
+ cachePath?: string;
+ scriptName?: string;
+ version?: string;
+ prefixCommand?: {
+ cmd: string;
+ description: string;
+ };
+ allowCachePathOverride?: boolean;
+ pinnedBrowsers?: Partial>;
+ }, rl?: readline.Interface);
+ run(argv: string[]): Promise;
+}
+//# sourceMappingURL=CLI.d.ts.map
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/cjs/CLI.d.ts.map b/node_modules/@puppeteer/browsers/lib/cjs/CLI.d.ts.map
new file mode 100644
index 0000000..efbf34c
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/cjs/CLI.d.ts.map
@@ -0,0 +1 @@
+{"version":3,"file":"CLI.d.ts","sourceRoot":"","sources":["../../src/CLI.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAGH,OAAO,KAAK,QAAQ,MAAM,eAAe,CAAC;AAI1C,OAAO,EACL,OAAO,EAIR,MAAM,gCAAgC,CAAC;AA+BxC;;GAEG;AACH,qBAAa,GAAG;;gBAkBZ,IAAI,CAAC,EACD,MAAM,GACN;QACE,SAAS,CAAC,EAAE,MAAM,CAAC;QACnB,UAAU,CAAC,EAAE,MAAM,CAAC;QACpB,OAAO,CAAC,EAAE,MAAM,CAAC;QACjB,aAAa,CAAC,EAAE;YAAC,GAAG,EAAE,MAAM,CAAC;YAAC,WAAW,EAAE,MAAM,CAAA;SAAC,CAAC;QACnD,sBAAsB,CAAC,EAAE,OAAO,CAAC;QACjC,cAAc,CAAC,EAAE,OAAO,CACtB,MAAM,CACJ,OAAO,EACP;YACE,OAAO,EAAE,MAAM,CAAC;YAChB,YAAY,EAAE,OAAO,CAAC;SACvB,CACF,CACF,CAAC;KACH,EACL,EAAE,CAAC,EAAE,QAAQ,CAAC,SAAS;IA+EnB,GAAG,CAAC,IAAI,EAAE,MAAM,EAAE,GAAG,OAAO,CAAC,IAAI,CAAC;CAoYzC"}
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/cjs/CLI.js b/node_modules/@puppeteer/browsers/lib/cjs/CLI.js
new file mode 100644
index 0000000..1432326
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/cjs/CLI.js
@@ -0,0 +1,362 @@
+"use strict";
+/**
+ * @license
+ * Copyright 2023 Google Inc.
+ * SPDX-License-Identifier: Apache-2.0
+ */
+var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
+ if (k2 === undefined) k2 = k;
+ var desc = Object.getOwnPropertyDescriptor(m, k);
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
+ desc = { enumerable: true, get: function() { return m[k]; } };
+ }
+ Object.defineProperty(o, k2, desc);
+}) : (function(o, m, k, k2) {
+ if (k2 === undefined) k2 = k;
+ o[k2] = m[k];
+}));
+var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
+ Object.defineProperty(o, "default", { enumerable: true, value: v });
+}) : function(o, v) {
+ o["default"] = v;
+});
+var __importStar = (this && this.__importStar) || (function () {
+ var ownKeys = function(o) {
+ ownKeys = Object.getOwnPropertyNames || function (o) {
+ var ar = [];
+ for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
+ return ar;
+ };
+ return ownKeys(o);
+ };
+ return function (mod) {
+ if (mod && mod.__esModule) return mod;
+ var result = {};
+ if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
+ __setModuleDefault(result, mod);
+ return result;
+ };
+})();
+Object.defineProperty(exports, "__esModule", { value: true });
+exports.CLI = void 0;
+const node_process_1 = require("node:process");
+const readline = __importStar(require("node:readline"));
+const browser_data_js_1 = require("./browser-data/browser-data.js");
+const Cache_js_1 = require("./Cache.js");
+const detectPlatform_js_1 = require("./detectPlatform.js");
+const version_js_1 = require("./generated/version.js");
+const install_js_1 = require("./install.js");
+const launch_js_1 = require("./launch.js");
+function isValidBrowser(browser) {
+ return Object.values(browser_data_js_1.Browser).includes(browser);
+}
+function isValidPlatform(platform) {
+ return Object.values(browser_data_js_1.BrowserPlatform).includes(platform);
+}
+/**
+ * @public
+ */
+class CLI {
+ #cachePath;
+ #rl;
+ #scriptName;
+ #version;
+ #allowCachePathOverride;
+ #pinnedBrowsers;
+ #prefixCommand;
+ constructor(opts, rl) {
+ if (!opts) {
+ opts = {};
+ }
+ if (typeof opts === 'string') {
+ opts = {
+ cachePath: opts,
+ };
+ }
+ this.#cachePath = opts.cachePath ?? process.cwd();
+ this.#rl = rl;
+ this.#scriptName = opts.scriptName ?? '@puppeteer/browsers';
+ this.#version = opts.version ?? version_js_1.packageVersion;
+ this.#allowCachePathOverride = opts.allowCachePathOverride ?? true;
+ this.#pinnedBrowsers = opts.pinnedBrowsers;
+ this.#prefixCommand = opts.prefixCommand;
+ }
+ #defineBrowserParameter(yargs, required) {
+ return yargs.positional('browser', {
+ description: 'Which browser to install [@]. `latest` will try to find the latest available build. `buildId` is a browser-specific identifier such as a version or a revision.',
+ type: 'string',
+ coerce: (opt) => {
+ const browser = {
+ name: this.#parseBrowser(opt),
+ buildId: this.#parseBuildId(opt),
+ };
+ if (!isValidBrowser(browser.name)) {
+ throw new Error(`Unsupported browser '${browser.name}'`);
+ }
+ return browser;
+ },
+ demandOption: required,
+ });
+ }
+ #definePlatformParameter(yargs) {
+ return yargs.option('platform', {
+ type: 'string',
+ desc: 'Platform that the binary needs to be compatible with.',
+ choices: Object.values(browser_data_js_1.BrowserPlatform),
+ default: (0, detectPlatform_js_1.detectBrowserPlatform)(),
+ coerce: platform => {
+ if (!isValidPlatform(platform)) {
+ throw new Error(`Unsupported platform '${platform}'`);
+ }
+ return platform;
+ },
+ defaultDescription: 'Auto-detected',
+ });
+ }
+ #definePathParameter(yargs, required = false) {
+ if (!this.#allowCachePathOverride) {
+ return yargs;
+ }
+ return yargs.option('path', {
+ type: 'string',
+ desc: 'Path to the root folder for the browser downloads and installation. If a relative path is provided, it will be resolved relative to the current working directory. The installation folder structure is compatible with the cache structure used by Puppeteer.',
+ defaultDescription: 'Current working directory',
+ ...(required ? {} : { default: process.cwd() }),
+ demandOption: required,
+ });
+ }
+ async run(argv) {
+ const { default: yargs } = await import('yargs');
+ const { hideBin } = await import('yargs/helpers');
+ const yargsInstance = yargs(hideBin(argv));
+ let target = yargsInstance
+ .scriptName(this.#scriptName)
+ .version(this.#version);
+ if (this.#prefixCommand) {
+ target = target.command(this.#prefixCommand.cmd, this.#prefixCommand.description, yargs => {
+ return this.#build(yargs);
+ });
+ }
+ else {
+ target = this.#build(target);
+ }
+ await target
+ .demandCommand(1)
+ .help()
+ .wrap(Math.min(120, yargsInstance.terminalWidth()))
+ .parseAsync();
+ }
+ #build(yargs) {
+ const latestOrPinned = this.#pinnedBrowsers ? 'pinned' : 'latest';
+ // If there are pinned browsers allow the positional arg to be optional
+ const browserArgType = this.#pinnedBrowsers ? '[browser]' : '';
+ return yargs
+ .command(`install ${browserArgType}`, 'Download and install the specified browser. If successful, the command outputs the actual browser buildId that was installed and the absolute path to the browser executable (format: @).', yargs => {
+ if (this.#pinnedBrowsers) {
+ yargs.example('$0 install', 'Install all pinned browsers');
+ }
+ yargs
+ .example('$0 install chrome', `Install the ${latestOrPinned} available build of the Chrome browser.`)
+ .example('$0 install chrome@latest', 'Install the latest available build for the Chrome browser.')
+ .example('$0 install chrome@stable', 'Install the latest available build for the Chrome browser from the stable channel.')
+ .example('$0 install chrome@beta', 'Install the latest available build for the Chrome browser from the beta channel.')
+ .example('$0 install chrome@dev', 'Install the latest available build for the Chrome browser from the dev channel.')
+ .example('$0 install chrome@canary', 'Install the latest available build for the Chrome Canary browser.')
+ .example('$0 install chrome@115', 'Install the latest available build for Chrome 115.')
+ .example('$0 install chromedriver@canary', 'Install the latest available build for ChromeDriver Canary.')
+ .example('$0 install chromedriver@115', 'Install the latest available build for ChromeDriver 115.')
+ .example('$0 install chromedriver@115.0.5790', 'Install the latest available patch (115.0.5790.X) build for ChromeDriver.')
+ .example('$0 install chrome-headless-shell', 'Install the latest available chrome-headless-shell build.')
+ .example('$0 install chrome-headless-shell@beta', 'Install the latest available chrome-headless-shell build corresponding to the Beta channel.')
+ .example('$0 install chrome-headless-shell@118', 'Install the latest available chrome-headless-shell 118 build.')
+ .example('$0 install chromium@1083080', 'Install the revision 1083080 of the Chromium browser.')
+ .example('$0 install firefox', 'Install the latest nightly available build of the Firefox browser.')
+ .example('$0 install firefox@stable', 'Install the latest stable build of the Firefox browser.')
+ .example('$0 install firefox@beta', 'Install the latest beta build of the Firefox browser.')
+ .example('$0 install firefox@devedition', 'Install the latest devedition build of the Firefox browser.')
+ .example('$0 install firefox@esr', 'Install the latest ESR build of the Firefox browser.')
+ .example('$0 install firefox@nightly', 'Install the latest nightly build of the Firefox browser.')
+ .example('$0 install firefox@stable_111.0.1', 'Install a specific version of the Firefox browser.')
+ .example('$0 install firefox --platform mac', 'Install the latest Mac (Intel) build of the Firefox browser.');
+ if (this.#allowCachePathOverride) {
+ yargs.example('$0 install firefox --path /tmp/my-browser-cache', 'Install to the specified cache directory.');
+ }
+ const yargsWithBrowserParam = this.#defineBrowserParameter(yargs, !Boolean(this.#pinnedBrowsers));
+ const yargsWithPlatformParam = this.#definePlatformParameter(yargsWithBrowserParam);
+ return this.#definePathParameter(yargsWithPlatformParam, false)
+ .option('base-url', {
+ type: 'string',
+ desc: 'Base URL to download from',
+ })
+ .option('install-deps', {
+ type: 'boolean',
+ desc: 'Whether to attempt installing system dependencies (only supported on Linux, requires root privileges).',
+ default: false,
+ });
+ }, async (args) => {
+ if (this.#pinnedBrowsers && !args.browser) {
+ // Use allSettled to avoid scenarios that
+ // a browser may fail early and leave the other
+ // installation in a faulty state
+ const result = await Promise.allSettled(Object.entries(this.#pinnedBrowsers).map(async ([browser, options]) => {
+ if (options.skipDownload) {
+ return;
+ }
+ await this.#install({
+ ...args,
+ browser: {
+ name: browser,
+ buildId: options.buildId,
+ },
+ });
+ }));
+ for (const install of result) {
+ if (install.status === 'rejected') {
+ throw install.reason;
+ }
+ }
+ }
+ else {
+ await this.#install(args);
+ }
+ })
+ .command('launch ', 'Launch the specified browser', yargs => {
+ yargs
+ .example('$0 launch chrome@115.0.5790.170', 'Launch Chrome 115.0.5790.170')
+ .example('$0 launch firefox@112.0a1', 'Launch the Firefox browser identified by the milestone 112.0a1.')
+ .example('$0 launch chrome@115.0.5790.170 --detached', 'Launch the browser but detach the sub-processes.')
+ .example('$0 launch chrome@canary --system', 'Try to locate the Canary build of Chrome installed on the system and launch it.')
+ .example('$0 launch chrome@115.0.5790.170 -- --version', 'Launch Chrome 115.0.5790.170 and pass custom argument to the binary.');
+ const yargsWithExtraAgs = yargs.parserConfiguration({
+ 'populate--': true,
+ // Yargs does not have the correct overload for this.
+ });
+ const yargsWithBrowserParam = this.#defineBrowserParameter(yargsWithExtraAgs, true);
+ const yargsWithPlatformParam = this.#definePlatformParameter(yargsWithBrowserParam);
+ return this.#definePathParameter(yargsWithPlatformParam)
+ .option('detached', {
+ type: 'boolean',
+ desc: 'Detach the child process.',
+ default: false,
+ })
+ .option('system', {
+ type: 'boolean',
+ desc: 'Search for a browser installed on the system instead of the cache folder.',
+ default: false,
+ })
+ .option('dumpio', {
+ type: 'boolean',
+ desc: "Forwards the browser's process stdout and stderr",
+ default: false,
+ });
+ }, async (args) => {
+ const extraArgs = args['--']?.filter(arg => {
+ return typeof arg === 'string';
+ });
+ args.browser.buildId = this.#resolvePinnedBrowserIfNeeded(args.browser.buildId, args.browser.name);
+ const executablePath = args.system
+ ? (0, launch_js_1.computeSystemExecutablePath)({
+ browser: args.browser.name,
+ // TODO: throw an error if not a ChromeReleaseChannel is provided.
+ channel: args.browser.buildId,
+ platform: args.platform,
+ })
+ : (0, launch_js_1.computeExecutablePath)({
+ browser: args.browser.name,
+ buildId: args.browser.buildId,
+ cacheDir: args.path ?? this.#cachePath,
+ platform: args.platform,
+ });
+ (0, launch_js_1.launch)({
+ args: extraArgs,
+ executablePath,
+ dumpio: args.dumpio,
+ detached: args.detached,
+ });
+ })
+ .command('clear', this.#allowCachePathOverride
+ ? 'Removes all installed browsers from the specified cache directory'
+ : `Removes all installed browsers from ${this.#cachePath}`, yargs => {
+ return this.#definePathParameter(yargs, true);
+ }, async (args) => {
+ const cacheDir = args.path ?? this.#cachePath;
+ const rl = this.#rl ?? readline.createInterface({ input: node_process_1.stdin, output: node_process_1.stdout });
+ rl.question(`Do you want to permanently and recursively delete the content of ${cacheDir} (yes/No)? `, answer => {
+ rl.close();
+ if (!['y', 'yes'].includes(answer.toLowerCase().trim())) {
+ console.log('Cancelled.');
+ return;
+ }
+ const cache = new Cache_js_1.Cache(cacheDir);
+ cache.clear();
+ console.log(`${cacheDir} cleared.`);
+ });
+ })
+ .command('list', 'List all installed browsers in the cache directory', yargs => {
+ yargs.example('$0 list', 'List all installed browsers in the cache directory');
+ if (this.#allowCachePathOverride) {
+ yargs.example('$0 list --path /tmp/my-browser-cache', 'List browsers installed in the specified cache directory');
+ }
+ return this.#definePathParameter(yargs);
+ }, async (args) => {
+ const cacheDir = args.path ?? this.#cachePath;
+ const cache = new Cache_js_1.Cache(cacheDir);
+ const browsers = cache.getInstalledBrowsers();
+ for (const browser of browsers) {
+ console.log(`${browser.browser}@${browser.buildId} (${browser.platform}) ${browser.executablePath}`);
+ }
+ })
+ .demandCommand(1)
+ .help();
+ }
+ #parseBrowser(version) {
+ return version.split('@').shift();
+ }
+ #parseBuildId(version) {
+ const parts = version.split('@');
+ return parts.length === 2
+ ? parts[1]
+ : this.#pinnedBrowsers
+ ? 'pinned'
+ : 'latest';
+ }
+ #resolvePinnedBrowserIfNeeded(buildId, browserName) {
+ if (buildId === 'pinned') {
+ const options = this.#pinnedBrowsers?.[browserName];
+ if (!options || !options.buildId) {
+ throw new Error(`No pinned version found for ${browserName}`);
+ }
+ return options.buildId;
+ }
+ return buildId;
+ }
+ async #install(args) {
+ if (!args.browser) {
+ throw new Error(`No browser arg provided`);
+ }
+ if (!args.platform) {
+ throw new Error(`Could not resolve the current platform`);
+ }
+ args.browser.buildId = this.#resolvePinnedBrowserIfNeeded(args.browser.buildId, args.browser.name);
+ const originalBuildId = args.browser.buildId;
+ args.browser.buildId = await (0, browser_data_js_1.resolveBuildId)(args.browser.name, args.platform, args.browser.buildId);
+ await (0, install_js_1.install)({
+ browser: args.browser.name,
+ buildId: args.browser.buildId,
+ platform: args.platform,
+ cacheDir: args.path ?? this.#cachePath,
+ downloadProgressCallback: 'default',
+ baseUrl: args.baseUrl,
+ buildIdAlias: originalBuildId !== args.browser.buildId ? originalBuildId : undefined,
+ installDeps: args.installDeps,
+ });
+ console.log(`${args.browser.name}@${args.browser.buildId} ${(0, launch_js_1.computeExecutablePath)({
+ browser: args.browser.name,
+ buildId: args.browser.buildId,
+ cacheDir: args.path ?? this.#cachePath,
+ platform: args.platform,
+ })}`);
+ }
+}
+exports.CLI = CLI;
+//# sourceMappingURL=CLI.js.map
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/cjs/CLI.js.map b/node_modules/@puppeteer/browsers/lib/cjs/CLI.js.map
new file mode 100644
index 0000000..d4e0d13
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/cjs/CLI.js.map
@@ -0,0 +1 @@
+{"version":3,"file":"CLI.js","sourceRoot":"","sources":["../../src/CLI.ts"],"names":[],"mappings":";AAAA;;;;GAIG;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAEH,+CAA8D;AAC9D,wDAA0C;AAI1C,oEAKwC;AACxC,yCAAiC;AACjC,2DAA0D;AAC1D,uDAAsD;AACtD,6CAAqC;AACrC,2CAIqB;AAcrB,SAAS,cAAc,CAAC,OAAgB;IACtC,OAAO,MAAM,CA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E,OAAO,EAAE,IAAI,CAAC,OAAO,CAAC,IAAI;YAC1B,OAAO,EAAE,IAAI,CAAC,OAAO,CAAC,OAAO;YAC7B,QAAQ,EAAE,IAAI,CAAC,IAAI,IAAI,IAAI,CAAC,UAAU;YACtC,QAAQ,EAAE,IAAI,CAAC,QAAQ;SACxB,CAAC,EAAE,CACL,CAAC;IACJ,CAAC;CACF;AAvfD,kBAufC"}
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/cjs/Cache.d.ts b/node_modules/@puppeteer/browsers/lib/cjs/Cache.d.ts
new file mode 100644
index 0000000..b11b2c7
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/cjs/Cache.d.ts
@@ -0,0 +1,86 @@
+/**
+ * @license
+ * Copyright 2023 Google Inc.
+ * SPDX-License-Identifier: Apache-2.0
+ */
+import { Browser, type BrowserPlatform } from './browser-data/browser-data.js';
+/**
+ * @public
+ */
+export declare class InstalledBrowser {
+ #private;
+ browser: Browser;
+ buildId: string;
+ platform: BrowserPlatform;
+ readonly executablePath: string;
+ /**
+ * @internal
+ */
+ constructor(cache: Cache, browser: Browser, buildId: string, platform: BrowserPlatform);
+ /**
+ * Path to the root of the installation folder. Use
+ * {@link computeExecutablePath} to get the path to the executable binary.
+ */
+ get path(): string;
+ readMetadata(): Metadata;
+ writeMetadata(metadata: Metadata): void;
+}
+/**
+ * @internal
+ */
+export interface ComputeExecutablePathOptions {
+ /**
+ * Determines which platform the browser will be suited for.
+ *
+ * @defaultValue **Auto-detected.**
+ */
+ platform?: BrowserPlatform;
+ /**
+ * Determines which browser to launch.
+ */
+ browser: Browser;
+ /**
+ * Determines which buildId to download. BuildId should uniquely identify
+ * binaries and they are used for caching.
+ */
+ buildId: string;
+}
+/**
+ * @public
+ */
+export interface Metadata {
+ aliases: Record;
+}
+/**
+ * The cache used by Puppeteer relies on the following structure:
+ *
+ * - rootDir
+ * -- | browserRoot(browser1)
+ * ---- - | installationDir()
+ * ------ the browser-platform-buildId
+ * ------ specific structure.
+ * -- | browserRoot(browser2)
+ * ---- - | installationDir()
+ * ------ the browser-platform-buildId
+ * ------ specific structure.
+ * @internal
+ */
+export declare class Cache {
+ #private;
+ constructor(rootDir: string);
+ /**
+ * @internal
+ */
+ get rootDir(): string;
+ browserRoot(browser: Browser): string;
+ metadataFile(browser: Browser): string;
+ readMetadata(browser: Browser): Metadata;
+ writeMetadata(browser: Browser, metadata: Metadata): void;
+ resolveAlias(browser: Browser, alias: string): string | undefined;
+ installationDir(browser: Browser, platform: BrowserPlatform, buildId: string): string;
+ clear(): void;
+ uninstall(browser: Browser, platform: BrowserPlatform, buildId: string): void;
+ getInstalledBrowsers(): InstalledBrowser[];
+ computeExecutablePath(options: ComputeExecutablePathOptions): string;
+}
+//# sourceMappingURL=Cache.d.ts.map
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/cjs/Cache.d.ts.map b/node_modules/@puppeteer/browsers/lib/cjs/Cache.d.ts.map
new file mode 100644
index 0000000..14957b2
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/cjs/Cache.d.ts.map
@@ -0,0 +1 @@
+{"version":3,"file":"Cache.d.ts","sourceRoot":"","sources":["../../src/Cache.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAQH,OAAO,EACL,OAAO,EACP,KAAK,eAAe,EAGrB,MAAM,gCAAgC,CAAC;AAKxC;;GAEG;AACH,qBAAa,gBAAgB;;IAC3B,OAAO,EAAE,OAAO,CAAC;IACjB,OAAO,EAAE,MAAM,CAAC;IAChB,QAAQ,EAAE,eAAe,CAAC;IAC1B,QAAQ,CAAC,cAAc,EAAE,MAAM,CAAC;IAIhC;;OAEG;gBAED,KAAK,EAAE,KAAK,EACZ,OAAO,EAAE,OAAO,EAChB,OAAO,EAAE,MAAM,EACf,QAAQ,EAAE,eAAe;IAa3B;;;OAGG;IACH,IAAI,IAAI,IAAI,MAAM,CAMjB;IAED,YAAY,IAAI,QAAQ;IAIxB,aAAa,CAAC,QAAQ,EAAE,QAAQ,GAAG,IAAI;CAGxC;AAED;;GAEG;AACH,MAAM,WAAW,4BAA4B;IAC3C;;;;OAIG;IACH,QAAQ,CAAC,EAAE,eAAe,CAAC;IAC3B;;OAEG;IACH,OAAO,EAAE,OAAO,CAAC;IACjB;;;OAGG;IACH,OAAO,EAAE,MAAM,CAAC;CACjB;AAED;;GAEG;AACH,MAAM,WAAW,QAAQ;IAEvB,OAAO,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;CACjC;AAED;;;;;;;;;;;;;GAaG;AACH,qBAAa,KAAK;;gBAGJ,OAAO,EAAE,MAAM;IAI3B;;OAEG;IACH,IAAI,OAAO,IAAI,MAAM,CAEpB;IAED,WAAW,CAAC,OAAO,EAAE,OAAO,GAAG,MAAM;IAIrC,YAAY,CAAC,OAAO,EAAE,OAAO,GAAG,MAAM;IAItC,YAAY,CAAC,OAAO,EAAE,OAAO,GAAG,QAAQ;IAaxC,aAAa,CAAC,OAAO,EAAE,OAAO,EAAE,QAAQ,EAAE,QAAQ,GAAG,IAAI;IAMzD,YAAY,CAAC,OAAO,EAAE,OAAO,EAAE,KAAK,EAAE,MAAM,GAAG,MAAM,GAAG,SAAS;IAUjE,eAAe,CACb,OAAO,EAAE,OAAO,EAChB,QAAQ,EAAE,eAAe,EACzB,OAAO,EAAE,MAAM,GACd,MAAM;IAIT,KAAK,IAAI,IAAI;IASb,SAAS,CACP,OAAO,EAAE,OAAO,EAChB,QAAQ,EAAE,eAAe,EACzB,OAAO,EAAE,MAAM,GACd,IAAI;IAeP,oBAAoB,IAAI,gBAAgB,EAAE;IA+B1C,qBAAqB,CAAC,OAAO,EAAE,4BAA4B,GAAG,MAAM;CA0BrE"}
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/cjs/Cache.js b/node_modules/@puppeteer/browsers/lib/cjs/Cache.js
new file mode 100644
index 0000000..f7675c0
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/cjs/Cache.js
@@ -0,0 +1,191 @@
+"use strict";
+/**
+ * @license
+ * Copyright 2023 Google Inc.
+ * SPDX-License-Identifier: Apache-2.0
+ */
+var __importDefault = (this && this.__importDefault) || function (mod) {
+ return (mod && mod.__esModule) ? mod : { "default": mod };
+};
+Object.defineProperty(exports, "__esModule", { value: true });
+exports.Cache = exports.InstalledBrowser = void 0;
+const node_fs_1 = __importDefault(require("node:fs"));
+const node_os_1 = __importDefault(require("node:os"));
+const node_path_1 = __importDefault(require("node:path"));
+const debug_1 = __importDefault(require("debug"));
+const browser_data_js_1 = require("./browser-data/browser-data.js");
+const detectPlatform_js_1 = require("./detectPlatform.js");
+const debugCache = (0, debug_1.default)('puppeteer:browsers:cache');
+/**
+ * @public
+ */
+class InstalledBrowser {
+ browser;
+ buildId;
+ platform;
+ executablePath;
+ #cache;
+ /**
+ * @internal
+ */
+ constructor(cache, browser, buildId, platform) {
+ this.#cache = cache;
+ this.browser = browser;
+ this.buildId = buildId;
+ this.platform = platform;
+ this.executablePath = cache.computeExecutablePath({
+ browser,
+ buildId,
+ platform,
+ });
+ }
+ /**
+ * Path to the root of the installation folder. Use
+ * {@link computeExecutablePath} to get the path to the executable binary.
+ */
+ get path() {
+ return this.#cache.installationDir(this.browser, this.platform, this.buildId);
+ }
+ readMetadata() {
+ return this.#cache.readMetadata(this.browser);
+ }
+ writeMetadata(metadata) {
+ this.#cache.writeMetadata(this.browser, metadata);
+ }
+}
+exports.InstalledBrowser = InstalledBrowser;
+/**
+ * The cache used by Puppeteer relies on the following structure:
+ *
+ * - rootDir
+ * -- | browserRoot(browser1)
+ * ---- - | installationDir()
+ * ------ the browser-platform-buildId
+ * ------ specific structure.
+ * -- | browserRoot(browser2)
+ * ---- - | installationDir()
+ * ------ the browser-platform-buildId
+ * ------ specific structure.
+ * @internal
+ */
+class Cache {
+ #rootDir;
+ constructor(rootDir) {
+ this.#rootDir = rootDir;
+ }
+ /**
+ * @internal
+ */
+ get rootDir() {
+ return this.#rootDir;
+ }
+ browserRoot(browser) {
+ return node_path_1.default.join(this.#rootDir, browser);
+ }
+ metadataFile(browser) {
+ return node_path_1.default.join(this.browserRoot(browser), '.metadata');
+ }
+ readMetadata(browser) {
+ const metatadaPath = this.metadataFile(browser);
+ if (!node_fs_1.default.existsSync(metatadaPath)) {
+ return { aliases: {} };
+ }
+ // TODO: add type-safe parsing.
+ const data = JSON.parse(node_fs_1.default.readFileSync(metatadaPath, 'utf8'));
+ if (typeof data !== 'object') {
+ throw new Error('.metadata is not an object');
+ }
+ return data;
+ }
+ writeMetadata(browser, metadata) {
+ const metatadaPath = this.metadataFile(browser);
+ node_fs_1.default.mkdirSync(node_path_1.default.dirname(metatadaPath), { recursive: true });
+ node_fs_1.default.writeFileSync(metatadaPath, JSON.stringify(metadata, null, 2));
+ }
+ resolveAlias(browser, alias) {
+ const metadata = this.readMetadata(browser);
+ if (alias === 'latest') {
+ return Object.values(metadata.aliases || {})
+ .sort((0, browser_data_js_1.getVersionComparator)(browser))
+ .at(-1);
+ }
+ return metadata.aliases[alias];
+ }
+ installationDir(browser, platform, buildId) {
+ return node_path_1.default.join(this.browserRoot(browser), `${platform}-${buildId}`);
+ }
+ clear() {
+ node_fs_1.default.rmSync(this.#rootDir, {
+ force: true,
+ recursive: true,
+ maxRetries: 10,
+ retryDelay: 500,
+ });
+ }
+ uninstall(browser, platform, buildId) {
+ const metadata = this.readMetadata(browser);
+ for (const alias of Object.keys(metadata.aliases)) {
+ if (metadata.aliases[alias] === buildId) {
+ delete metadata.aliases[alias];
+ }
+ }
+ node_fs_1.default.rmSync(this.installationDir(browser, platform, buildId), {
+ force: true,
+ recursive: true,
+ maxRetries: 10,
+ retryDelay: 500,
+ });
+ }
+ getInstalledBrowsers() {
+ if (!node_fs_1.default.existsSync(this.#rootDir)) {
+ return [];
+ }
+ const types = node_fs_1.default.readdirSync(this.#rootDir);
+ const browsers = types.filter((t) => {
+ return Object.values(browser_data_js_1.Browser).includes(t);
+ });
+ return browsers.flatMap(browser => {
+ const files = node_fs_1.default.readdirSync(this.browserRoot(browser));
+ return files
+ .map(file => {
+ const result = parseFolderPath(node_path_1.default.join(this.browserRoot(browser), file));
+ if (!result) {
+ return null;
+ }
+ return new InstalledBrowser(this, browser, result.buildId, result.platform);
+ })
+ .filter((item) => {
+ return item !== null;
+ });
+ });
+ }
+ computeExecutablePath(options) {
+ options.platform ??= (0, detectPlatform_js_1.detectBrowserPlatform)();
+ if (!options.platform) {
+ throw new Error(`Cannot download a binary for the provided platform: ${node_os_1.default.platform()} (${node_os_1.default.arch()})`);
+ }
+ try {
+ options.buildId =
+ this.resolveAlias(options.browser, options.buildId) ?? options.buildId;
+ }
+ catch {
+ debugCache('could not read .metadata file for the browser');
+ }
+ const installationDir = this.installationDir(options.browser, options.platform, options.buildId);
+ return node_path_1.default.join(installationDir, browser_data_js_1.executablePathByBrowser[options.browser](options.platform, options.buildId));
+ }
+}
+exports.Cache = Cache;
+function parseFolderPath(folderPath) {
+ const name = node_path_1.default.basename(folderPath);
+ const splits = name.split('-');
+ if (splits.length !== 2) {
+ return;
+ }
+ const [platform, buildId] = splits;
+ if (!buildId || !platform) {
+ return;
+ }
+ return { platform, buildId };
+}
+//# sourceMappingURL=Cache.js.map
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/cjs/Cache.js.map b/node_modules/@puppeteer/browsers/lib/cjs/Cache.js.map
new file mode 100644
index 0000000..a7ec5cb
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/cjs/Cache.js.map
@@ -0,0 +1 @@
+{"version":3,"file":"Cache.js","sourceRoot":"","sources":["../../src/Cache.ts"],"names":[],"mappings":";AAAA;;;;GAIG;;;;;;AAEH,sDAAyB;AACzB,sDAAyB;AACzB,0DAA6B;AAE7B,kDAA0B;AAE1B,oEAKwC;AACxC,2DAA0D;AAE1D,MAAM,UAAU,GAAG,IAAA,eAAK,EAAC,0BAA0B,CAAC,CAAC;AAErD;;GAEG;AACH,MAAa,gBAAgB;IAC3B,OAAO,CAAU;IACjB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AAE,OAAO,CAAC,OAAO,CAAC,IAAI,OAAO,CAAC,OAAO,CAAC;QAC3E,CAAC;QAAC,MAAM,CAAC;YACP,UAAU,CAAC,+CAA+C,CAAC,CAAC;QAC9D,CAAC;QACD,MAAM,eAAe,GAAG,IAAI,CAAC,eAAe,CAC1C,OAAO,CAAC,OAAO,EACf,OAAO,CAAC,QAAQ,EAChB,OAAO,CAAC,OAAO,CAChB,CAAC;QACF,OAAO,mBAAI,CAAC,IAAI,CACd,eAAe,EACf,yCAAuB,CAAC,OAAO,CAAC,OAAO,CAAC,CACtC,OAAO,CAAC,QAAQ,EAChB,OAAO,CAAC,OAAO,CAChB,CACF,CAAC;IACJ,CAAC;CACF;AAhJD,sBAgJC;AAED,SAAS,eAAe,CACtB,UAAkB;IAElB,MAAM,IAAI,GAAG,mBAAI,CAAC,QAAQ,CAAC,UAAU,CAAC,CAAC;IACvC,MAAM,MAAM,GAAG,IAAI,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC;IAC/B,IAAI,MAAM,CAAC,MAAM,KAAK,CAAC,EAAE,CAAC;QACxB,OAAO;IACT,CAAC;IACD,MAAM,CAAC,QAAQ,EAAE,OAAO,CAAC,GAAG,MAAM,CAAC;IACnC,IAAI,CAAC,OAAO,IAAI,CAAC,QAAQ,EAAE,CAAC;QAC1B,OAAO;IACT,CAAC;IACD,OAAO,EAAC,QAAQ,EAAE,OAAO,EAAC,CAAC;AAC7B,CAAC"}
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/cjs/browser-data/browser-data.d.ts b/node_modules/@puppeteer/browsers/lib/cjs/browser-data/browser-data.d.ts
new file mode 100644
index 0000000..4d7d644
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/cjs/browser-data/browser-data.d.ts
@@ -0,0 +1,61 @@
+/**
+ * @license
+ * Copyright 2023 Google Inc.
+ * SPDX-License-Identifier: Apache-2.0
+ */
+import * as chromeHeadlessShell from './chrome-headless-shell.js';
+import * as chrome from './chrome.js';
+import * as chromedriver from './chromedriver.js';
+import * as chromium from './chromium.js';
+import * as firefox from './firefox.js';
+import { Browser, BrowserPlatform, BrowserTag, ChromeReleaseChannel, type ProfileOptions } from './types.js';
+export type { ProfileOptions };
+export declare const downloadUrls: {
+ chromedriver: typeof chromedriver.resolveDownloadUrl;
+ "chrome-headless-shell": typeof chromeHeadlessShell.resolveDownloadUrl;
+ chrome: typeof chrome.resolveDownloadUrl;
+ chromium: typeof chromium.resolveDownloadUrl;
+ firefox: typeof firefox.resolveDownloadUrl;
+};
+export declare const downloadPaths: {
+ chromedriver: typeof chromedriver.resolveDownloadPath;
+ "chrome-headless-shell": typeof chromeHeadlessShell.resolveDownloadPath;
+ chrome: typeof chrome.resolveDownloadPath;
+ chromium: typeof chromium.resolveDownloadPath;
+ firefox: typeof firefox.resolveDownloadPath;
+};
+export declare const executablePathByBrowser: {
+ chromedriver: typeof chromedriver.relativeExecutablePath;
+ "chrome-headless-shell": typeof chromeHeadlessShell.relativeExecutablePath;
+ chrome: typeof chrome.relativeExecutablePath;
+ chromium: typeof chromium.relativeExecutablePath;
+ firefox: typeof firefox.relativeExecutablePath;
+};
+export declare const versionComparators: {
+ chromedriver: typeof chromeHeadlessShell.compareVersions;
+ "chrome-headless-shell": typeof chromeHeadlessShell.compareVersions;
+ chrome: typeof chromeHeadlessShell.compareVersions;
+ chromium: typeof chromium.compareVersions;
+ firefox: typeof firefox.compareVersions;
+};
+export { Browser, BrowserPlatform, ChromeReleaseChannel };
+/**
+ * @public
+ */
+export declare function resolveBuildId(browser: Browser, platform: BrowserPlatform, tag: string | BrowserTag): Promise;
+/**
+ * @public
+ */
+export declare function createProfile(browser: Browser, opts: ProfileOptions): Promise;
+/**
+ * @public
+ */
+export declare function resolveSystemExecutablePath(browser: Browser, platform: BrowserPlatform, channel: ChromeReleaseChannel): string;
+/**
+ * Returns a version comparator for the given browser that can be used to sort
+ * browser versions.
+ *
+ * @public
+ */
+export declare function getVersionComparator(browser: Browser): (a: string, b: string) => number;
+//# sourceMappingURL=browser-data.d.ts.map
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/cjs/browser-data/browser-data.d.ts.map b/node_modules/@puppeteer/browsers/lib/cjs/browser-data/browser-data.d.ts.map
new file mode 100644
index 0000000..3724e9c
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/cjs/browser-data/browser-data.d.ts.map
@@ -0,0 +1 @@
+{"version":3,"file":"browser-data.d.ts","sourceRoot":"","sources":["../../../src/browser-data/browser-data.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,OAAO,KAAK,mBAAmB,MAAM,4BAA4B,CAAC;AAClE,OAAO,KAAK,MAAM,MAAM,aAAa,CAAC;AACtC,OAAO,KAAK,YAAY,MAAM,mBAAmB,CAAC;AAClD,OAAO,KAAK,QAAQ,MAAM,eAAe,CAAC;AAC1C,OAAO,KAAK,OAAO,MAAM,cAAc,CAAC;AACxC,OAAO,EACL,OAAO,EACP,eAAe,EACf,UAAU,EACV,oBAAoB,EACpB,KAAK,cAAc,EACpB,MAAM,YAAY,CAAC;AAEpB,YAAY,EAAC,cAAc,EAAC,CAAC;AAE7B,eAAO,MAAM,YAAY;;;;;;CAMxB,CAAC;AAEF,eAAO,MAAM,aAAa;;;;;;CAMzB,CAAC;AAEF,eAAO,MAAM,uBAAuB;;;;;;CAMnC,CAAC;AAEF,eAAO,MAAM,kBAAkB;;;;;;CAM9B,CAAC;AAEF,OAAO,EAAC,OAAO,EAAE,eAAe,EAAE,oBAAoB,EAAC,CAAC;AA+GxD;;GAEG;AACH,wBAAsB,cAAc,CAClC,OAAO,EAAE,OAAO,EAChB,QAAQ,EAAE,eAAe,EACzB,GAAG,EAAE,MAAM,GAAG,UAAU,GACvB,OAAO,CAAC,MAAM,CAAC,CA+BjB;AAED;;GAEG;AACH,wBAAsB,aAAa,CACjC,OAAO,EAAE,OAAO,EAChB,IAAI,EAAE,cAAc,GACnB,OAAO,CAAC,IAAI,CAAC,CAQf;AAED;;GAEG;AACH,wBAAgB,2BAA2B,CACzC,OAAO,EAAE,OAAO,EAChB,QAAQ,EAAE,eAAe,EACzB,OAAO,EAAE,oBAAoB,GAC5B,MAAM,CAYR;AAED;;;;;GAKG;AACH,wBAAgB,oBAAoB,CAClC,OAAO,EAAE,OAAO,GACf,CAAC,CAAC,EAAE,MAAM,EAAE,CAAC,EAAE,MAAM,KAAK,MAAM,CAElC"}
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/cjs/browser-data/browser-data.js b/node_modules/@puppeteer/browsers/lib/cjs/browser-data/browser-data.js
new file mode 100644
index 0000000..ac40e14
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/cjs/browser-data/browser-data.js
@@ -0,0 +1,241 @@
+"use strict";
+/**
+ * @license
+ * Copyright 2023 Google Inc.
+ * SPDX-License-Identifier: Apache-2.0
+ */
+var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
+ if (k2 === undefined) k2 = k;
+ var desc = Object.getOwnPropertyDescriptor(m, k);
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
+ desc = { enumerable: true, get: function() { return m[k]; } };
+ }
+ Object.defineProperty(o, k2, desc);
+}) : (function(o, m, k, k2) {
+ if (k2 === undefined) k2 = k;
+ o[k2] = m[k];
+}));
+var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
+ Object.defineProperty(o, "default", { enumerable: true, value: v });
+}) : function(o, v) {
+ o["default"] = v;
+});
+var __importStar = (this && this.__importStar) || (function () {
+ var ownKeys = function(o) {
+ ownKeys = Object.getOwnPropertyNames || function (o) {
+ var ar = [];
+ for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
+ return ar;
+ };
+ return ownKeys(o);
+ };
+ return function (mod) {
+ if (mod && mod.__esModule) return mod;
+ var result = {};
+ if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
+ __setModuleDefault(result, mod);
+ return result;
+ };
+})();
+Object.defineProperty(exports, "__esModule", { value: true });
+exports.ChromeReleaseChannel = exports.BrowserPlatform = exports.Browser = exports.versionComparators = exports.executablePathByBrowser = exports.downloadPaths = exports.downloadUrls = void 0;
+exports.resolveBuildId = resolveBuildId;
+exports.createProfile = createProfile;
+exports.resolveSystemExecutablePath = resolveSystemExecutablePath;
+exports.getVersionComparator = getVersionComparator;
+const chromeHeadlessShell = __importStar(require("./chrome-headless-shell.js"));
+const chrome = __importStar(require("./chrome.js"));
+const chromedriver = __importStar(require("./chromedriver.js"));
+const chromium = __importStar(require("./chromium.js"));
+const firefox = __importStar(require("./firefox.js"));
+const types_js_1 = require("./types.js");
+Object.defineProperty(exports, "Browser", { enumerable: true, get: function () { return types_js_1.Browser; } });
+Object.defineProperty(exports, "BrowserPlatform", { enumerable: true, get: function () { return types_js_1.BrowserPlatform; } });
+Object.defineProperty(exports, "ChromeReleaseChannel", { enumerable: true, get: function () { return types_js_1.ChromeReleaseChannel; } });
+exports.downloadUrls = {
+ [types_js_1.Browser.CHROMEDRIVER]: chromedriver.resolveDownloadUrl,
+ [types_js_1.Browser.CHROMEHEADLESSSHELL]: chromeHeadlessShell.resolveDownloadUrl,
+ [types_js_1.Browser.CHROME]: chrome.resolveDownloadUrl,
+ [types_js_1.Browser.CHROMIUM]: chromium.resolveDownloadUrl,
+ [types_js_1.Browser.FIREFOX]: firefox.resolveDownloadUrl,
+};
+exports.downloadPaths = {
+ [types_js_1.Browser.CHROMEDRIVER]: chromedriver.resolveDownloadPath,
+ [types_js_1.Browser.CHROMEHEADLESSSHELL]: chromeHeadlessShell.resolveDownloadPath,
+ [types_js_1.Browser.CHROME]: chrome.resolveDownloadPath,
+ [types_js_1.Browser.CHROMIUM]: chromium.resolveDownloadPath,
+ [types_js_1.Browser.FIREFOX]: firefox.resolveDownloadPath,
+};
+exports.executablePathByBrowser = {
+ [types_js_1.Browser.CHROMEDRIVER]: chromedriver.relativeExecutablePath,
+ [types_js_1.Browser.CHROMEHEADLESSSHELL]: chromeHeadlessShell.relativeExecutablePath,
+ [types_js_1.Browser.CHROME]: chrome.relativeExecutablePath,
+ [types_js_1.Browser.CHROMIUM]: chromium.relativeExecutablePath,
+ [types_js_1.Browser.FIREFOX]: firefox.relativeExecutablePath,
+};
+exports.versionComparators = {
+ [types_js_1.Browser.CHROMEDRIVER]: chromedriver.compareVersions,
+ [types_js_1.Browser.CHROMEHEADLESSSHELL]: chromeHeadlessShell.compareVersions,
+ [types_js_1.Browser.CHROME]: chrome.compareVersions,
+ [types_js_1.Browser.CHROMIUM]: chromium.compareVersions,
+ [types_js_1.Browser.FIREFOX]: firefox.compareVersions,
+};
+/**
+ * @internal
+ */
+async function resolveBuildIdForBrowserTag(browser, platform, tag) {
+ switch (browser) {
+ case types_js_1.Browser.FIREFOX:
+ switch (tag) {
+ case types_js_1.BrowserTag.LATEST:
+ return await firefox.resolveBuildId(firefox.FirefoxChannel.NIGHTLY);
+ case types_js_1.BrowserTag.BETA:
+ return await firefox.resolveBuildId(firefox.FirefoxChannel.BETA);
+ case types_js_1.BrowserTag.NIGHTLY:
+ return await firefox.resolveBuildId(firefox.FirefoxChannel.NIGHTLY);
+ case types_js_1.BrowserTag.DEVEDITION:
+ return await firefox.resolveBuildId(firefox.FirefoxChannel.DEVEDITION);
+ case types_js_1.BrowserTag.STABLE:
+ return await firefox.resolveBuildId(firefox.FirefoxChannel.STABLE);
+ case types_js_1.BrowserTag.ESR:
+ return await firefox.resolveBuildId(firefox.FirefoxChannel.ESR);
+ case types_js_1.BrowserTag.CANARY:
+ case types_js_1.BrowserTag.DEV:
+ throw new Error(`${tag.toUpperCase()} is not available for Firefox`);
+ }
+ case types_js_1.Browser.CHROME: {
+ switch (tag) {
+ case types_js_1.BrowserTag.LATEST:
+ return await chrome.resolveBuildId(types_js_1.ChromeReleaseChannel.CANARY);
+ case types_js_1.BrowserTag.BETA:
+ return await chrome.resolveBuildId(types_js_1.ChromeReleaseChannel.BETA);
+ case types_js_1.BrowserTag.CANARY:
+ return await chrome.resolveBuildId(types_js_1.ChromeReleaseChannel.CANARY);
+ case types_js_1.BrowserTag.DEV:
+ return await chrome.resolveBuildId(types_js_1.ChromeReleaseChannel.DEV);
+ case types_js_1.BrowserTag.STABLE:
+ return await chrome.resolveBuildId(types_js_1.ChromeReleaseChannel.STABLE);
+ case types_js_1.BrowserTag.NIGHTLY:
+ case types_js_1.BrowserTag.DEVEDITION:
+ case types_js_1.BrowserTag.ESR:
+ throw new Error(`${tag.toUpperCase()} is not available for Chrome`);
+ }
+ }
+ case types_js_1.Browser.CHROMEDRIVER: {
+ switch (tag) {
+ case types_js_1.BrowserTag.LATEST:
+ case types_js_1.BrowserTag.CANARY:
+ return await chromedriver.resolveBuildId(types_js_1.ChromeReleaseChannel.CANARY);
+ case types_js_1.BrowserTag.BETA:
+ return await chromedriver.resolveBuildId(types_js_1.ChromeReleaseChannel.BETA);
+ case types_js_1.BrowserTag.DEV:
+ return await chromedriver.resolveBuildId(types_js_1.ChromeReleaseChannel.DEV);
+ case types_js_1.BrowserTag.STABLE:
+ return await chromedriver.resolveBuildId(types_js_1.ChromeReleaseChannel.STABLE);
+ case types_js_1.BrowserTag.NIGHTLY:
+ case types_js_1.BrowserTag.DEVEDITION:
+ case types_js_1.BrowserTag.ESR:
+ throw new Error(`${tag.toUpperCase()} is not available for ChromeDriver`);
+ }
+ }
+ case types_js_1.Browser.CHROMEHEADLESSSHELL: {
+ switch (tag) {
+ case types_js_1.BrowserTag.LATEST:
+ case types_js_1.BrowserTag.CANARY:
+ return await chromeHeadlessShell.resolveBuildId(types_js_1.ChromeReleaseChannel.CANARY);
+ case types_js_1.BrowserTag.BETA:
+ return await chromeHeadlessShell.resolveBuildId(types_js_1.ChromeReleaseChannel.BETA);
+ case types_js_1.BrowserTag.DEV:
+ return await chromeHeadlessShell.resolveBuildId(types_js_1.ChromeReleaseChannel.DEV);
+ case types_js_1.BrowserTag.STABLE:
+ return await chromeHeadlessShell.resolveBuildId(types_js_1.ChromeReleaseChannel.STABLE);
+ case types_js_1.BrowserTag.NIGHTLY:
+ case types_js_1.BrowserTag.DEVEDITION:
+ case types_js_1.BrowserTag.ESR:
+ throw new Error(`${tag} is not available for chrome-headless-shell`);
+ }
+ }
+ case types_js_1.Browser.CHROMIUM:
+ switch (tag) {
+ case types_js_1.BrowserTag.LATEST:
+ return await chromium.resolveBuildId(platform);
+ case types_js_1.BrowserTag.NIGHTLY:
+ case types_js_1.BrowserTag.CANARY:
+ case types_js_1.BrowserTag.DEV:
+ case types_js_1.BrowserTag.DEVEDITION:
+ case types_js_1.BrowserTag.BETA:
+ case types_js_1.BrowserTag.STABLE:
+ case types_js_1.BrowserTag.ESR:
+ throw new Error(`${tag} is not supported for Chromium. Use 'latest' instead.`);
+ }
+ }
+}
+/**
+ * @public
+ */
+async function resolveBuildId(browser, platform, tag) {
+ const browserTag = tag;
+ if (Object.values(types_js_1.BrowserTag).includes(browserTag)) {
+ return await resolveBuildIdForBrowserTag(browser, platform, browserTag);
+ }
+ switch (browser) {
+ case types_js_1.Browser.FIREFOX:
+ return tag;
+ case types_js_1.Browser.CHROME:
+ const chromeResult = await chrome.resolveBuildId(tag);
+ if (chromeResult) {
+ return chromeResult;
+ }
+ return tag;
+ case types_js_1.Browser.CHROMEDRIVER:
+ const chromeDriverResult = await chromedriver.resolveBuildId(tag);
+ if (chromeDriverResult) {
+ return chromeDriverResult;
+ }
+ return tag;
+ case types_js_1.Browser.CHROMEHEADLESSSHELL:
+ const chromeHeadlessShellResult = await chromeHeadlessShell.resolveBuildId(tag);
+ if (chromeHeadlessShellResult) {
+ return chromeHeadlessShellResult;
+ }
+ return tag;
+ case types_js_1.Browser.CHROMIUM:
+ return tag;
+ }
+}
+/**
+ * @public
+ */
+async function createProfile(browser, opts) {
+ switch (browser) {
+ case types_js_1.Browser.FIREFOX:
+ return await firefox.createProfile(opts);
+ case types_js_1.Browser.CHROME:
+ case types_js_1.Browser.CHROMIUM:
+ throw new Error(`Profile creation is not support for ${browser} yet`);
+ }
+}
+/**
+ * @public
+ */
+function resolveSystemExecutablePath(browser, platform, channel) {
+ switch (browser) {
+ case types_js_1.Browser.CHROMEDRIVER:
+ case types_js_1.Browser.CHROMEHEADLESSSHELL:
+ case types_js_1.Browser.FIREFOX:
+ case types_js_1.Browser.CHROMIUM:
+ throw new Error(`System browser detection is not supported for ${browser} yet.`);
+ case types_js_1.Browser.CHROME:
+ return chrome.resolveSystemExecutablePath(platform, channel);
+ }
+}
+/**
+ * Returns a version comparator for the given browser that can be used to sort
+ * browser versions.
+ *
+ * @public
+ */
+function getVersionComparator(browser) {
+ return exports.versionComparators[browser];
+}
+//# sourceMappingURL=browser-data.js.map
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/cjs/browser-data/browser-data.js.map b/node_modules/@puppeteer/browsers/lib/cjs/browser-data/browser-data.js.map
new file mode 100644
index 0000000..a8abeef
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/cjs/browser-data/browser-data.js.map
@@ -0,0 +1 @@
+{"version":3,"file":"browser-data.js","sourceRoot":"","sources":["../../../src/browser-data/browser-data.ts"],"names":[],"mappings":";AAAA;;;;GAIG;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAmKH,wCAmCC;AAKD,sCAWC;AAKD,kEAgBC;AAQD,oDAIC;AArPD,gFAAkE;AAClE,oDAAsC;AACtC,gEAAkD;AAClD,wDAA0C;AAC1C,sDAAwC;AACxC,yCAMoB;AAoCZ,wFAzCN,kBAAO,OAyCM;AAAE,gGAxCf,0BAAe,OAwCe;AAAE,qGAtChC,+BAAoB,OAsCgC;AAhCzC,QAAA,YAAY,GAAG;IAC1B,CAAC,kBAAO,CAAC,YAAY,CAAC,EAAE,YAAY,CAAC,kBAAkB;IACvD,CAAC,kBAAO,CAAC,mBAAmB,CAAC,EAAE,mBAAmB,CAAC,kBAAkB;IACrE,CAAC,kBAAO,CAAC,MAAM,CAAC,EAAE,MA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CAAC;QACb,KAAK,kBAAO,CAAC,QAAQ;YACnB,OAAO,GAAG,CAAC;IACf,CAAC;AACH,CAAC;AAED;;GAEG;AACI,KAAK,UAAU,aAAa,CACjC,OAAgB,EAChB,IAAoB;IAEpB,QAAQ,OAAO,EAAE,CAAC;QAChB,KAAK,kBAAO,CAAC,OAAO;YAClB,OAAO,MAAM,OAAO,CAAC,aAAa,CAAC,IAAI,CAAC,CAAC;QAC3C,KAAK,kBAAO,CAAC,MAAM,CAAC;QACpB,KAAK,kBAAO,CAAC,QAAQ;YACnB,MAAM,IAAI,KAAK,CAAC,uCAAuC,OAAO,MAAM,CAAC,CAAC;IAC1E,CAAC;AACH,CAAC;AAED;;GAEG;AACH,SAAgB,2BAA2B,CACzC,OAAgB,EAChB,QAAyB,EACzB,OAA6B;IAE7B,QAAQ,OAAO,EAAE,CAAC;QAChB,KAAK,kBAAO,CAAC,YAAY,CAAC;QAC1B,KAAK,kBAAO,CAAC,mBAAmB,CAAC;QACjC,KAAK,kBAAO,CAAC,OAAO,CAAC;QACrB,KAAK,kBAAO,CAAC,QAAQ;YACnB,MAAM,IAAI,KAAK,CACb,iDAAiD,OAAO,OAAO,CAChE,CAAC;QACJ,KAAK,kBAAO,CAAC,MAAM;YACjB,OAAO,MAAM,CAAC,2BAA2B,CAAC,QAAQ,EAAE,OAAO,CAAC,CAAC;IACjE,CAAC;AACH,CAAC;AAED;;;;;GAKG;AACH,SAAgB,oBAAoB,CAClC,OAAgB;IAEhB,OAAO,0BAAkB,CAAC,OAAO,CAAC,CAAC;AACrC,CAAC"}
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/cjs/browser-data/chrome-headless-shell.d.ts b/node_modules/@puppeteer/browsers/lib/cjs/browser-data/chrome-headless-shell.d.ts
new file mode 100644
index 0000000..d21d11b
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/cjs/browser-data/chrome-headless-shell.d.ts
@@ -0,0 +1,6 @@
+import { BrowserPlatform } from './types.js';
+export declare function resolveDownloadUrl(platform: BrowserPlatform, buildId: string, baseUrl?: string): string;
+export declare function resolveDownloadPath(platform: BrowserPlatform, buildId: string): string[];
+export declare function relativeExecutablePath(platform: BrowserPlatform, _buildId: string): string;
+export { resolveBuildId, compareVersions } from './chrome.js';
+//# sourceMappingURL=chrome-headless-shell.d.ts.map
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/cjs/browser-data/chrome-headless-shell.d.ts.map b/node_modules/@puppeteer/browsers/lib/cjs/browser-data/chrome-headless-shell.d.ts.map
new file mode 100644
index 0000000..5ca312a
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/cjs/browser-data/chrome-headless-shell.d.ts.map
@@ -0,0 +1 @@
+{"version":3,"file":"chrome-headless-shell.d.ts","sourceRoot":"","sources":["../../../src/browser-data/chrome-headless-shell.ts"],"names":[],"mappings":"AAOA,OAAO,EAAC,eAAe,EAAC,MAAM,YAAY,CAAC;AAkB3C,wBAAgB,kBAAkB,CAChC,QAAQ,EAAE,eAAe,EACzB,OAAO,EAAE,MAAM,EACf,OAAO,SAA6D,GACnE,MAAM,CAER;AAED,wBAAgB,mBAAmB,CACjC,QAAQ,EAAE,eAAe,EACzB,OAAO,EAAE,MAAM,GACd,MAAM,EAAE,CAMV;AAED,wBAAgB,sBAAsB,CACpC,QAAQ,EAAE,eAAe,EACzB,QAAQ,EAAE,MAAM,GACf,MAAM,CAqBR;AAED,OAAO,EAAC,cAAc,EAAE,eAAe,EAAC,MAAM,aAAa,CAAC"}
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/cjs/browser-data/chrome-headless-shell.js b/node_modules/@puppeteer/browsers/lib/cjs/browser-data/chrome-headless-shell.js
new file mode 100644
index 0000000..abb8066
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/cjs/browser-data/chrome-headless-shell.js
@@ -0,0 +1,58 @@
+"use strict";
+var __importDefault = (this && this.__importDefault) || function (mod) {
+ return (mod && mod.__esModule) ? mod : { "default": mod };
+};
+Object.defineProperty(exports, "__esModule", { value: true });
+exports.compareVersions = exports.resolveBuildId = void 0;
+exports.resolveDownloadUrl = resolveDownloadUrl;
+exports.resolveDownloadPath = resolveDownloadPath;
+exports.relativeExecutablePath = relativeExecutablePath;
+/**
+ * @license
+ * Copyright 2023 Google Inc.
+ * SPDX-License-Identifier: Apache-2.0
+ */
+const node_path_1 = __importDefault(require("node:path"));
+const types_js_1 = require("./types.js");
+function folder(platform) {
+ switch (platform) {
+ case types_js_1.BrowserPlatform.LINUX_ARM:
+ case types_js_1.BrowserPlatform.LINUX:
+ return 'linux64';
+ case types_js_1.BrowserPlatform.MAC_ARM:
+ return 'mac-arm64';
+ case types_js_1.BrowserPlatform.MAC:
+ return 'mac-x64';
+ case types_js_1.BrowserPlatform.WIN32:
+ return 'win32';
+ case types_js_1.BrowserPlatform.WIN64:
+ return 'win64';
+ }
+}
+function resolveDownloadUrl(platform, buildId, baseUrl = 'https://storage.googleapis.com/chrome-for-testing-public') {
+ return `${baseUrl}/${resolveDownloadPath(platform, buildId).join('/')}`;
+}
+function resolveDownloadPath(platform, buildId) {
+ return [
+ buildId,
+ folder(platform),
+ `chrome-headless-shell-${folder(platform)}.zip`,
+ ];
+}
+function relativeExecutablePath(platform, _buildId) {
+ switch (platform) {
+ case types_js_1.BrowserPlatform.MAC:
+ case types_js_1.BrowserPlatform.MAC_ARM:
+ return node_path_1.default.join('chrome-headless-shell-' + folder(platform), 'chrome-headless-shell');
+ case types_js_1.BrowserPlatform.LINUX_ARM:
+ case types_js_1.BrowserPlatform.LINUX:
+ return node_path_1.default.join('chrome-headless-shell-linux64', 'chrome-headless-shell');
+ case types_js_1.BrowserPlatform.WIN32:
+ case types_js_1.BrowserPlatform.WIN64:
+ return node_path_1.default.join('chrome-headless-shell-' + folder(platform), 'chrome-headless-shell.exe');
+ }
+}
+var chrome_js_1 = require("./chrome.js");
+Object.defineProperty(exports, "resolveBuildId", { enumerable: true, get: function () { return chrome_js_1.resolveBuildId; } });
+Object.defineProperty(exports, "compareVersions", { enumerable: true, get: function () { return chrome_js_1.compareVersions; } });
+//# sourceMappingURL=chrome-headless-shell.js.map
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/cjs/browser-data/chrome-headless-shell.js.map b/node_modules/@puppeteer/browsers/lib/cjs/browser-data/chrome-headless-shell.js.map
new file mode 100644
index 0000000..ff606f9
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/cjs/browser-data/chrome-headless-shell.js.map
@@ -0,0 +1 @@
+{"version":3,"file":"chrome-headless-shell.js","sourceRoot":"","sources":["../../../src/browser-data/chrome-headless-shell.ts"],"names":[],"mappings":";;;;;;AAyBA,gDAMC;AAED,kDASC;AAED,wDAwBC;AApED;;;;GAIG;AACH,0DAA6B;AAE7B,yCAA2C;AAE3C,SAAS,MAAM,CAAC,QAAyB;IACvC,QAAQ,QAAQ,EAAE,CAAC;QACjB,KAAK,0BAAe,CAAC,SAAS,CAAC;QAC/B,KAAK,0BAAe,CAAC,KAAK;YACxB,OAAO,SAAS,CAAC;QACnB,KAAK,0BAAe,CAAC,OAAO;YAC1B,OAAO,WAAW,CAAC;QACrB,KAAK,0BAAe,CAAC,GAAG;YACtB,OAAO,SAAS,CAAC;QACnB,KAAK,0BAAe,CAAC,KAAK;YACxB,OAAO,OAAO,CAAC;QACjB,KAAK,0BAAe,CAAC,KAAK;YACxB,OAAO,OAAO,CAAC;IACnB,CAAC;AACH,CAAC;AAED,SAAgB,kBAAkB,CAChC,QAAyB,EACzB,OAAe,EACf,OAAO,GAAG,0DAA0D;IAEpE,OAAO,GAAG,OAAO,IAAI,mBAAmB,CAAC,QAAQ,EAAE,OAAO,CAAC,CAAC,IAAI,CAAC,GAAG,CAAC,EAAE,CAAC;AAC1E,CAAC;AAED,SAAgB,mBAAmB,CACjC,QAAyB,EACzB,OAAe;IAEf,OAAO;QACL,OAAO;QACP,MAAM,CAAC,QAAQ,CAAC;QAChB,yBAAyB,MAAM,CAAC,QAAQ,CAAC,MAAM;KAChD,CAAC;AACJ,CAAC;AAED,SAAgB,sBAAsB,CACpC,QAAyB,EACzB,QAAgB;IAEhB,QAAQ,QAAQ,EAAE,CAAC;QACjB,KAAK,0BAAe,CAAC,GAAG,CAAC;QACzB,KAAK,0BAAe,CAAC,OAAO;YAC1B,OAAO,mBAAI,CAAC,IAAI,CACd,wBAAwB,GAAG,MAAM,CAAC,QAAQ,CAAC,EAC3C,uBAAuB,CACxB,CAAC;QACJ,KAAK,0BAAe,CAAC,SAAS,CAAC;QAC/B,KAAK,0BAAe,CAAC,KAAK;YACxB,OAAO,mBAAI,CAAC,IAAI,CACd,+BAA+B,EAC/B,uBAAuB,CACxB,CAAC;QACJ,KAAK,0BAAe,CAAC,KAAK,CAAC;QAC3B,KAAK,0BAAe,CAAC,KAAK;YACxB,OAAO,mBAAI,CAAC,IAAI,CACd,wBAAwB,GAAG,MAAM,CAAC,QAAQ,CAAC,EAC3C,2BAA2B,CAC5B,CAAC;IACN,CAAC;AACH,CAAC;AAED,yCAA4D;AAApD,2GAAA,cAAc,OAAA;AAAE,4GAAA,eAAe,OAAA"}
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/cjs/browser-data/chrome.d.ts b/node_modules/@puppeteer/browsers/lib/cjs/browser-data/chrome.d.ts
new file mode 100644
index 0000000..da0c1e7
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/cjs/browser-data/chrome.d.ts
@@ -0,0 +1,30 @@
+/**
+ * @license
+ * Copyright 2023 Google Inc.
+ * SPDX-License-Identifier: Apache-2.0
+ */
+import { BrowserPlatform, ChromeReleaseChannel } from './types.js';
+export declare function resolveDownloadUrl(platform: BrowserPlatform, buildId: string, baseUrl?: string): string;
+export declare function resolveDownloadPath(platform: BrowserPlatform, buildId: string): string[];
+export declare function relativeExecutablePath(platform: BrowserPlatform, _buildId: string): string;
+export declare function getLastKnownGoodReleaseForChannel(channel: ChromeReleaseChannel): Promise<{
+ version: string;
+ revision: string;
+}>;
+export declare function getLastKnownGoodReleaseForMilestone(milestone: string): Promise<{
+ version: string;
+ revision: string;
+} | undefined>;
+export declare function getLastKnownGoodReleaseForBuild(
+/**
+ * @example `112.0.23`,
+ */
+buildPrefix: string): Promise<{
+ version: string;
+ revision: string;
+} | undefined>;
+export declare function resolveBuildId(channel: ChromeReleaseChannel): Promise;
+export declare function resolveBuildId(channel: string): Promise;
+export declare function resolveSystemExecutablePath(platform: BrowserPlatform, channel: ChromeReleaseChannel): string;
+export declare function compareVersions(a: string, b: string): number;
+//# sourceMappingURL=chrome.d.ts.map
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/cjs/browser-data/chrome.d.ts.map b/node_modules/@puppeteer/browsers/lib/cjs/browser-data/chrome.d.ts.map
new file mode 100644
index 0000000..2bf0d5f
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/cjs/browser-data/chrome.d.ts.map
@@ -0,0 +1 @@
+{"version":3,"file":"chrome.d.ts","sourceRoot":"","sources":["../../../src/browser-data/chrome.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAQH,OAAO,EAAC,eAAe,EAAE,oBAAoB,EAAC,MAAM,YAAY,CAAC;AAkBjE,wBAAgB,kBAAkB,CAChC,QAAQ,EAAE,eAAe,EACzB,OAAO,EAAE,MAAM,EACf,OAAO,SAA6D,GACnE,MAAM,CAER;AAED,wBAAgB,mBAAmB,CACjC,QAAQ,EAAE,eAAe,EACzB,OAAO,EAAE,MAAM,GACd,MAAM,EAAE,CAEV;AAED,wBAAgB,sBAAsB,CACpC,QAAQ,EAAE,eAAe,EACzB,QAAQ,EAAE,MAAM,GACf,MAAM,CAkBR;AAED,wBAAsB,iCAAiC,CACrD,OAAO,EAAE,oBAAoB,GAC5B,OAAO,CAAC;IAAC,OAAO,EAAE,MAAM,CAAC;IAAC,QAAQ,EAAE,MAAM,CAAA;CAAC,CAAC,CAsB9C;AAED,wBAAsB,mCAAmC,CACvD,SAAS,EAAE,MAAM,GAChB,OAAO,CAAC;IAAC,OAAO,EAAE,MAAM,CAAC;IAAC,QAAQ,EAAE,MAAM,CAAA;CAAC,GAAG,SAAS,CAAC,CAW1D;AAED,wBAAsB,+BAA+B;AACnD;;GAEG;AACH,WAAW,EAAE,MAAM,GAClB,OAAO,CAAC;IAAC,OAAO,EAAE,MAAM,CAAC;IAAC,QAAQ,EAAE,MAAM,CAAA;CAAC,GAAG,SAAS,CAAC,CAW1D;AAED,wBAAsB,cAAc,CAClC,OAAO,EAAE,oBAAoB,GAC5B,OAAO,CAAC,MAAM,CAAC,CAAC;AACnB,wBAAsB,cAAc,CAClC,OAAO,EAAE,MAAM,GACd,OAAO,CAAC,MAAM,GAAG,SAAS,CAAC,CAAC;AAwB/B,wBAAgB,2BAA2B,CACzC,QAAQ,EAAE,eAAe,EACzB,OAAO,EAAE,oBAAoB,GAC5B,MAAM,CAuCR;AAED,wBAAgB,eAAe,CAAC,CAAC,EAAE,MAAM,EAAE,CAAC,EAAE,MAAM,GAAG,MAAM,CAc5D"}
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/cjs/browser-data/chrome.js b/node_modules/@puppeteer/browsers/lib/cjs/browser-data/chrome.js
new file mode 100644
index 0000000..4369afe
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/cjs/browser-data/chrome.js
@@ -0,0 +1,149 @@
+"use strict";
+/**
+ * @license
+ * Copyright 2023 Google Inc.
+ * SPDX-License-Identifier: Apache-2.0
+ */
+var __importDefault = (this && this.__importDefault) || function (mod) {
+ return (mod && mod.__esModule) ? mod : { "default": mod };
+};
+Object.defineProperty(exports, "__esModule", { value: true });
+exports.resolveDownloadUrl = resolveDownloadUrl;
+exports.resolveDownloadPath = resolveDownloadPath;
+exports.relativeExecutablePath = relativeExecutablePath;
+exports.getLastKnownGoodReleaseForChannel = getLastKnownGoodReleaseForChannel;
+exports.getLastKnownGoodReleaseForMilestone = getLastKnownGoodReleaseForMilestone;
+exports.getLastKnownGoodReleaseForBuild = getLastKnownGoodReleaseForBuild;
+exports.resolveBuildId = resolveBuildId;
+exports.resolveSystemExecutablePath = resolveSystemExecutablePath;
+exports.compareVersions = compareVersions;
+const node_path_1 = __importDefault(require("node:path"));
+const semver_1 = __importDefault(require("semver"));
+const httpUtil_js_1 = require("../httpUtil.js");
+const types_js_1 = require("./types.js");
+function folder(platform) {
+ switch (platform) {
+ case types_js_1.BrowserPlatform.LINUX_ARM:
+ case types_js_1.BrowserPlatform.LINUX:
+ return 'linux64';
+ case types_js_1.BrowserPlatform.MAC_ARM:
+ return 'mac-arm64';
+ case types_js_1.BrowserPlatform.MAC:
+ return 'mac-x64';
+ case types_js_1.BrowserPlatform.WIN32:
+ return 'win32';
+ case types_js_1.BrowserPlatform.WIN64:
+ return 'win64';
+ }
+}
+function resolveDownloadUrl(platform, buildId, baseUrl = 'https://storage.googleapis.com/chrome-for-testing-public') {
+ return `${baseUrl}/${resolveDownloadPath(platform, buildId).join('/')}`;
+}
+function resolveDownloadPath(platform, buildId) {
+ return [buildId, folder(platform), `chrome-${folder(platform)}.zip`];
+}
+function relativeExecutablePath(platform, _buildId) {
+ switch (platform) {
+ case types_js_1.BrowserPlatform.MAC:
+ case types_js_1.BrowserPlatform.MAC_ARM:
+ return node_path_1.default.join('chrome-' + folder(platform), 'Google Chrome for Testing.app', 'Contents', 'MacOS', 'Google Chrome for Testing');
+ case types_js_1.BrowserPlatform.LINUX_ARM:
+ case types_js_1.BrowserPlatform.LINUX:
+ return node_path_1.default.join('chrome-linux64', 'chrome');
+ case types_js_1.BrowserPlatform.WIN32:
+ case types_js_1.BrowserPlatform.WIN64:
+ return node_path_1.default.join('chrome-' + folder(platform), 'chrome.exe');
+ }
+}
+async function getLastKnownGoodReleaseForChannel(channel) {
+ const data = (await (0, httpUtil_js_1.getJSON)(new URL('https://googlechromelabs.github.io/chrome-for-testing/last-known-good-versions.json')));
+ for (const channel of Object.keys(data.channels)) {
+ data.channels[channel.toLowerCase()] = data.channels[channel];
+ delete data.channels[channel];
+ }
+ return data.channels[channel];
+}
+async function getLastKnownGoodReleaseForMilestone(milestone) {
+ const data = (await (0, httpUtil_js_1.getJSON)(new URL('https://googlechromelabs.github.io/chrome-for-testing/latest-versions-per-milestone.json')));
+ return data.milestones[milestone];
+}
+async function getLastKnownGoodReleaseForBuild(
+/**
+ * @example `112.0.23`,
+ */
+buildPrefix) {
+ const data = (await (0, httpUtil_js_1.getJSON)(new URL('https://googlechromelabs.github.io/chrome-for-testing/latest-patch-versions-per-build.json')));
+ return data.builds[buildPrefix];
+}
+async function resolveBuildId(channel) {
+ if (Object.values(types_js_1.ChromeReleaseChannel).includes(channel)) {
+ return (await getLastKnownGoodReleaseForChannel(channel)).version;
+ }
+ if (channel.match(/^\d+$/)) {
+ // Potentially a milestone.
+ return (await getLastKnownGoodReleaseForMilestone(channel))?.version;
+ }
+ if (channel.match(/^\d+\.\d+\.\d+$/)) {
+ // Potentially a build prefix without the patch version.
+ return (await getLastKnownGoodReleaseForBuild(channel))?.version;
+ }
+ return;
+}
+function resolveSystemExecutablePath(platform, channel) {
+ switch (platform) {
+ case types_js_1.BrowserPlatform.WIN64:
+ case types_js_1.BrowserPlatform.WIN32:
+ switch (channel) {
+ case types_js_1.ChromeReleaseChannel.STABLE:
+ return `${process.env['PROGRAMFILES']}\\Google\\Chrome\\Application\\chrome.exe`;
+ case types_js_1.ChromeReleaseChannel.BETA:
+ return `${process.env['PROGRAMFILES']}\\Google\\Chrome Beta\\Application\\chrome.exe`;
+ case types_js_1.ChromeReleaseChannel.CANARY:
+ return `${process.env['PROGRAMFILES']}\\Google\\Chrome SxS\\Application\\chrome.exe`;
+ case types_js_1.ChromeReleaseChannel.DEV:
+ return `${process.env['PROGRAMFILES']}\\Google\\Chrome Dev\\Application\\chrome.exe`;
+ }
+ case types_js_1.BrowserPlatform.MAC_ARM:
+ case types_js_1.BrowserPlatform.MAC:
+ switch (channel) {
+ case types_js_1.ChromeReleaseChannel.STABLE:
+ return '/Applications/Google Chrome.app/Contents/MacOS/Google Chrome';
+ case types_js_1.ChromeReleaseChannel.BETA:
+ return '/Applications/Google Chrome Beta.app/Contents/MacOS/Google Chrome Beta';
+ case types_js_1.ChromeReleaseChannel.CANARY:
+ return '/Applications/Google Chrome Canary.app/Contents/MacOS/Google Chrome Canary';
+ case types_js_1.ChromeReleaseChannel.DEV:
+ return '/Applications/Google Chrome Dev.app/Contents/MacOS/Google Chrome Dev';
+ }
+ case types_js_1.BrowserPlatform.LINUX_ARM:
+ case types_js_1.BrowserPlatform.LINUX:
+ switch (channel) {
+ case types_js_1.ChromeReleaseChannel.STABLE:
+ return '/opt/google/chrome/chrome';
+ case types_js_1.ChromeReleaseChannel.BETA:
+ return '/opt/google/chrome-beta/chrome';
+ case types_js_1.ChromeReleaseChannel.CANARY:
+ return '/opt/google/chrome-canary/chrome';
+ case types_js_1.ChromeReleaseChannel.DEV:
+ return '/opt/google/chrome-unstable/chrome';
+ }
+ }
+}
+function compareVersions(a, b) {
+ if (!semver_1.default.valid(a)) {
+ throw new Error(`Version ${a} is not a valid semver version`);
+ }
+ if (!semver_1.default.valid(b)) {
+ throw new Error(`Version ${b} is not a valid semver version`);
+ }
+ if (semver_1.default.gt(a, b)) {
+ return 1;
+ }
+ else if (semver_1.default.lt(a, b)) {
+ return -1;
+ }
+ else {
+ return 0;
+ }
+}
+//# sourceMappingURL=chrome.js.map
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/cjs/browser-data/chrome.js.map b/node_modules/@puppeteer/browsers/lib/cjs/browser-data/chrome.js.map
new file mode 100644
index 0000000..5394f36
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/cjs/browser-data/chrome.js.map
@@ -0,0 +1 @@
+{"version":3,"file":"chrome.js","sourceRoot":"","sources":["../../../src/browser-data/chrome.ts"],"names":[],"mappings":";AAAA;;;;GAIG;;;;;AA0BH,gDAMC;AAED,kDAKC;AAED,wDAqBC;AAED,8EAwBC;AAED,kFAaC;AAED,0EAgBC;AAQD,wCAqBC;AAED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newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/cjs/browser-data/chromedriver.d.ts b/node_modules/@puppeteer/browsers/lib/cjs/browser-data/chromedriver.d.ts
new file mode 100644
index 0000000..5a26c3f
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/cjs/browser-data/chromedriver.d.ts
@@ -0,0 +1,6 @@
+import { BrowserPlatform } from './types.js';
+export declare function resolveDownloadUrl(platform: BrowserPlatform, buildId: string, baseUrl?: string): string;
+export declare function resolveDownloadPath(platform: BrowserPlatform, buildId: string): string[];
+export declare function relativeExecutablePath(platform: BrowserPlatform, _buildId: string): string;
+export { resolveBuildId, compareVersions } from './chrome.js';
+//# sourceMappingURL=chromedriver.d.ts.map
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/cjs/browser-data/chromedriver.d.ts.map b/node_modules/@puppeteer/browsers/lib/cjs/browser-data/chromedriver.d.ts.map
new file mode 100644
index 0000000..83af5f7
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/cjs/browser-data/chromedriver.d.ts.map
@@ -0,0 +1 @@
+{"version":3,"file":"chromedriver.d.ts","sourceRoot":"","sources":["../../../src/browser-data/chromedriver.ts"],"names":[],"mappings":"AAOA,OAAO,EAAC,eAAe,EAAC,MAAM,YAAY,CAAC;AAkB3C,wBAAgB,kBAAkB,CAChC,QAAQ,EAAE,eAAe,EACzB,OAAO,EAAE,MAAM,EACf,OAAO,SAA6D,GACnE,MAAM,CAER;AAED,wBAAgB,mBAAmB,CACjC,QAAQ,EAAE,eAAe,EACzB,OAAO,EAAE,MAAM,GACd,MAAM,EAAE,CAEV;AAED,wBAAgB,sBAAsB,CACpC,QAAQ,EAAE,eAAe,EACzB,QAAQ,EAAE,MAAM,GACf,MAAM,CAYR;AAED,OAAO,EAAC,cAAc,EAAE,eAAe,EAAC,MAAM,aAAa,CAAC"}
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/cjs/browser-data/chromedriver.js b/node_modules/@puppeteer/browsers/lib/cjs/browser-data/chromedriver.js
new file mode 100644
index 0000000..2907bee
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/cjs/browser-data/chromedriver.js
@@ -0,0 +1,54 @@
+"use strict";
+var __importDefault = (this && this.__importDefault) || function (mod) {
+ return (mod && mod.__esModule) ? mod : { "default": mod };
+};
+Object.defineProperty(exports, "__esModule", { value: true });
+exports.compareVersions = exports.resolveBuildId = void 0;
+exports.resolveDownloadUrl = resolveDownloadUrl;
+exports.resolveDownloadPath = resolveDownloadPath;
+exports.relativeExecutablePath = relativeExecutablePath;
+/**
+ * @license
+ * Copyright 2023 Google Inc.
+ * SPDX-License-Identifier: Apache-2.0
+ */
+const node_path_1 = __importDefault(require("node:path"));
+const types_js_1 = require("./types.js");
+function folder(platform) {
+ switch (platform) {
+ case types_js_1.BrowserPlatform.LINUX_ARM:
+ case types_js_1.BrowserPlatform.LINUX:
+ return 'linux64';
+ case types_js_1.BrowserPlatform.MAC_ARM:
+ return 'mac-arm64';
+ case types_js_1.BrowserPlatform.MAC:
+ return 'mac-x64';
+ case types_js_1.BrowserPlatform.WIN32:
+ return 'win32';
+ case types_js_1.BrowserPlatform.WIN64:
+ return 'win64';
+ }
+}
+function resolveDownloadUrl(platform, buildId, baseUrl = 'https://storage.googleapis.com/chrome-for-testing-public') {
+ return `${baseUrl}/${resolveDownloadPath(platform, buildId).join('/')}`;
+}
+function resolveDownloadPath(platform, buildId) {
+ return [buildId, folder(platform), `chromedriver-${folder(platform)}.zip`];
+}
+function relativeExecutablePath(platform, _buildId) {
+ switch (platform) {
+ case types_js_1.BrowserPlatform.MAC:
+ case types_js_1.BrowserPlatform.MAC_ARM:
+ return node_path_1.default.join('chromedriver-' + folder(platform), 'chromedriver');
+ case types_js_1.BrowserPlatform.LINUX_ARM:
+ case types_js_1.BrowserPlatform.LINUX:
+ return node_path_1.default.join('chromedriver-linux64', 'chromedriver');
+ case types_js_1.BrowserPlatform.WIN32:
+ case types_js_1.BrowserPlatform.WIN64:
+ return node_path_1.default.join('chromedriver-' + folder(platform), 'chromedriver.exe');
+ }
+}
+var chrome_js_1 = require("./chrome.js");
+Object.defineProperty(exports, "resolveBuildId", { enumerable: true, get: function () { return chrome_js_1.resolveBuildId; } });
+Object.defineProperty(exports, "compareVersions", { enumerable: true, get: function () { return chrome_js_1.compareVersions; } });
+//# sourceMappingURL=chromedriver.js.map
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/cjs/browser-data/chromedriver.js.map b/node_modules/@puppeteer/browsers/lib/cjs/browser-data/chromedriver.js.map
new file mode 100644
index 0000000..04309b9
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/cjs/browser-data/chromedriver.js.map
@@ -0,0 +1 @@
+{"version":3,"file":"chromedriver.js","sourceRoot":"","sources":["../../../src/browser-data/chromedriver.ts"],"names":[],"mappings":";;;;;;AAyBA,gDAMC;AAED,kDAKC;AAED,wDAeC;AAvDD;;;;GAIG;AACH,0DAA6B;AAE7B,yCAA2C;AAE3C,SAAS,MAAM,CAAC,QAAyB;IACvC,QAAQ,QAAQ,EAAE,CAAC;QACjB,KAAK,0BAAe,CAAC,SAAS,CAAC;QAC/B,KAAK,0BAAe,CAAC,KAAK;YACxB,OAAO,SAAS,CAAC;QACnB,KAAK,0BAAe,CAAC,OAAO;YAC1B,OAAO,WAAW,CAAC;QACrB,KAAK,0BAAe,CAAC,GAAG;YACtB,OAAO,SAAS,CAAC;QACnB,KAAK,0BAAe,CAAC,KAAK;YACxB,OAAO,OAAO,CAAC;QACjB,KAAK,0BAAe,CAAC,KAAK;YACxB,OAAO,OAAO,CAAC;IACnB,CAAC;AACH,CAAC;AAED,SAAgB,kBAAkB,CAChC,QAAyB,EACzB,OAAe,EACf,OAAO,GAAG,0DAA0D;IAEpE,OAAO,GAAG,OAAO,IAAI,mBAAmB,CAAC,QAAQ,EAAE,OAAO,CAAC,CAAC,IAAI,CAAC,GAAG,CAAC,EAAE,CAAC;AAC1E,CAAC;AAED,SAAgB,mBAAmB,CACjC,QAAyB,EACzB,OAAe;IAEf,OAAO,CAAC,OAAO,EAAE,MAAM,CAAC,QAAQ,CAAC,EAAE,gBAAgB,MAAM,CAAC,QAAQ,CAAC,MAAM,CAAC,CAAC;AAC7E,CAAC;AAED,SAAgB,sBAAsB,CACpC,QAAyB,EACzB,QAAgB;IAEhB,QAAQ,QAAQ,EAAE,CAAC;QACjB,KAAK,0BAAe,CAAC,GAAG,CAAC;QACzB,KAAK,0BAAe,CAAC,OAAO;YAC1B,OAAO,mBAAI,CAAC,IAAI,CAAC,eAAe,GAAG,MAAM,CAAC,QAAQ,CAAC,EAAE,cAAc,CAAC,CAAC;QACvE,KAAK,0BAAe,CAAC,SAAS,CAAC;QAC/B,KAAK,0BAAe,CAAC,KAAK;YACxB,OAAO,mBAAI,CAAC,IAAI,CAAC,sBAAsB,EAAE,cAAc,CAAC,CAAC;QAC3D,KAAK,0BAAe,CAAC,KAAK,CAAC;QAC3B,KAAK,0BAAe,CAAC,KAAK;YACxB,OAAO,mBAAI,CAAC,IAAI,CAAC,eAAe,GAAG,MAAM,CAAC,QAAQ,CAAC,EAAE,kBAAkB,CAAC,CAAC;IAC7E,CAAC;AACH,CAAC;AAED,yCAA4D;AAApD,2GAAA,cAAc,OAAA;AAAE,4GAAA,eAAe,OAAA"}
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/cjs/browser-data/chromium.d.ts b/node_modules/@puppeteer/browsers/lib/cjs/browser-data/chromium.d.ts
new file mode 100644
index 0000000..6bcb936
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/cjs/browser-data/chromium.d.ts
@@ -0,0 +1,12 @@
+/**
+ * @license
+ * Copyright 2023 Google Inc.
+ * SPDX-License-Identifier: Apache-2.0
+ */
+import { BrowserPlatform } from './types.js';
+export declare function resolveDownloadUrl(platform: BrowserPlatform, buildId: string, baseUrl?: string): string;
+export declare function resolveDownloadPath(platform: BrowserPlatform, buildId: string): string[];
+export declare function relativeExecutablePath(platform: BrowserPlatform, _buildId: string): string;
+export declare function resolveBuildId(platform: BrowserPlatform): Promise;
+export declare function compareVersions(a: string, b: string): number;
+//# sourceMappingURL=chromium.d.ts.map
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/cjs/browser-data/chromium.d.ts.map b/node_modules/@puppeteer/browsers/lib/cjs/browser-data/chromium.d.ts.map
new file mode 100644
index 0000000..cf36579
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/cjs/browser-data/chromium.d.ts.map
@@ -0,0 +1 @@
+{"version":3,"file":"chromium.d.ts","sourceRoot":"","sources":["../../../src/browser-data/chromium.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAMH,OAAO,EAAC,eAAe,EAAC,MAAM,YAAY,CAAC;AAiC3C,wBAAgB,kBAAkB,CAChC,QAAQ,EAAE,eAAe,EACzB,OAAO,EAAE,MAAM,EACf,OAAO,SAA8D,GACpE,MAAM,CAER;AAED,wBAAgB,mBAAmB,CACjC,QAAQ,EAAE,eAAe,EACzB,OAAO,EAAE,MAAM,GACd,MAAM,EAAE,CAEV;AAED,wBAAgB,sBAAsB,CACpC,QAAQ,EAAE,eAAe,EACzB,QAAQ,EAAE,MAAM,GACf,MAAM,CAkBR;AACD,wBAAsB,cAAc,CAClC,QAAQ,EAAE,eAAe,GACxB,OAAO,CAAC,MAAM,CAAC,CAQjB;AAED,wBAAgB,eAAe,CAAC,CAAC,EAAE,MAAM,EAAE,CAAC,EAAE,MAAM,GAAG,MAAM,CAE5D"}
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/cjs/browser-data/chromium.js b/node_modules/@puppeteer/browsers/lib/cjs/browser-data/chromium.js
new file mode 100644
index 0000000..99152d6
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/cjs/browser-data/chromium.js
@@ -0,0 +1,73 @@
+"use strict";
+/**
+ * @license
+ * Copyright 2023 Google Inc.
+ * SPDX-License-Identifier: Apache-2.0
+ */
+var __importDefault = (this && this.__importDefault) || function (mod) {
+ return (mod && mod.__esModule) ? mod : { "default": mod };
+};
+Object.defineProperty(exports, "__esModule", { value: true });
+exports.resolveDownloadUrl = resolveDownloadUrl;
+exports.resolveDownloadPath = resolveDownloadPath;
+exports.relativeExecutablePath = relativeExecutablePath;
+exports.resolveBuildId = resolveBuildId;
+exports.compareVersions = compareVersions;
+const node_path_1 = __importDefault(require("node:path"));
+const httpUtil_js_1 = require("../httpUtil.js");
+const types_js_1 = require("./types.js");
+function archive(platform, buildId) {
+ switch (platform) {
+ case types_js_1.BrowserPlatform.LINUX_ARM:
+ case types_js_1.BrowserPlatform.LINUX:
+ return 'chrome-linux';
+ case types_js_1.BrowserPlatform.MAC_ARM:
+ case types_js_1.BrowserPlatform.MAC:
+ return 'chrome-mac';
+ case types_js_1.BrowserPlatform.WIN32:
+ case types_js_1.BrowserPlatform.WIN64:
+ // Windows archive name changed at r591479.
+ return parseInt(buildId, 10) > 591479 ? 'chrome-win' : 'chrome-win32';
+ }
+}
+function folder(platform) {
+ switch (platform) {
+ case types_js_1.BrowserPlatform.LINUX_ARM:
+ case types_js_1.BrowserPlatform.LINUX:
+ return 'Linux_x64';
+ case types_js_1.BrowserPlatform.MAC_ARM:
+ return 'Mac_Arm';
+ case types_js_1.BrowserPlatform.MAC:
+ return 'Mac';
+ case types_js_1.BrowserPlatform.WIN32:
+ return 'Win';
+ case types_js_1.BrowserPlatform.WIN64:
+ return 'Win_x64';
+ }
+}
+function resolveDownloadUrl(platform, buildId, baseUrl = 'https://storage.googleapis.com/chromium-browser-snapshots') {
+ return `${baseUrl}/${resolveDownloadPath(platform, buildId).join('/')}`;
+}
+function resolveDownloadPath(platform, buildId) {
+ return [folder(platform), buildId, `${archive(platform, buildId)}.zip`];
+}
+function relativeExecutablePath(platform, _buildId) {
+ switch (platform) {
+ case types_js_1.BrowserPlatform.MAC:
+ case types_js_1.BrowserPlatform.MAC_ARM:
+ return node_path_1.default.join('chrome-mac', 'Chromium.app', 'Contents', 'MacOS', 'Chromium');
+ case types_js_1.BrowserPlatform.LINUX_ARM:
+ case types_js_1.BrowserPlatform.LINUX:
+ return node_path_1.default.join('chrome-linux', 'chrome');
+ case types_js_1.BrowserPlatform.WIN32:
+ case types_js_1.BrowserPlatform.WIN64:
+ return node_path_1.default.join('chrome-win', 'chrome.exe');
+ }
+}
+async function resolveBuildId(platform) {
+ return await (0, httpUtil_js_1.getText)(new URL(`https://storage.googleapis.com/chromium-browser-snapshots/${folder(platform)}/LAST_CHANGE`));
+}
+function compareVersions(a, b) {
+ return Number(a) - Number(b);
+}
+//# sourceMappingURL=chromium.js.map
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/cjs/browser-data/chromium.js.map b/node_modules/@puppeteer/browsers/lib/cjs/browser-data/chromium.js.map
new file mode 100644
index 0000000..f44441a
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/cjs/browser-data/chromium.js.map
@@ -0,0 +1 @@
+{"version":3,"file":"chromium.js","sourceRoot":"","sources":["../../../src/browser-data/chromium.ts"],"names":[],"mappings":";AAAA;;;;GAIG;;;;;AAuCH,gDAMC;AAED,kDAKC;AAED,wDAqBC;AACD,wCAUC;AAED,0CAEC;AAxFD,0DAA6B;AAE7B,gDAAuC;AAEvC,yCAA2C;AAE3C,SAAS,OAAO,CAAC,QAAyB,EAAE,OAAe;IACzD,QAAQ,QAAQ,EAAE,CAAC;QACjB,KAAK,0BAAe,CAAC,SAAS,CAAC;QAC/B,KAAK,0BAAe,CAAC,KAAK;YACxB,OAAO,cAAc,CAAC;QACxB,KAAK,0BAAe,CAAC,OAAO,CAAC;QAC7B,KAAK,0BAAe,CAAC,GAAG;YACtB,OAAO,YAAY,CAAC;QACtB,KAAK,0BAAe,CAAC,KAAK,CAAC;QAC3B,KAAK,0BAAe,CAAC,KAAK;YACxB,2CAA2C;YAC3C,OAAO,QAAQ,CAAC,OAAO,EAAE,EAAE,CAAC,GAAG,MAAM,CAAC,CAAC,CAAC,YAAY,CAAC,CAAC,CAA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K,CAAC;QAC3B,KAAK,0BAAe,CAAC,KAAK;YACxB,OAAO,mBAAI,CAAC,IAAI,CAAC,YAAY,EAAE,YAAY,CAAC,CAAC;IACjD,CAAC;AACH,CAAC;AACM,KAAK,UAAU,cAAc,CAClC,QAAyB;IAEzB,OAAO,MAAM,IAAA,qBAAO,EAClB,IAAI,GAAG,CACL,6DAA6D,MAAM,CACjE,QAAQ,CACT,cAAc,CAChB,CACF,CAAC;AACJ,CAAC;AAED,SAAgB,eAAe,CAAC,CAAS,EAAE,CAAS;IAClD,OAAO,MAAM,CAAC,CAAC,CAAC,GAAG,MAAM,CAAC,CAAC,CAAC,CAAC;AAC/B,CAAC"}
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/cjs/browser-data/firefox.d.ts b/node_modules/@puppeteer/browsers/lib/cjs/browser-data/firefox.d.ts
new file mode 100644
index 0000000..447f91d
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/cjs/browser-data/firefox.d.ts
@@ -0,0 +1,20 @@
+/**
+ * @license
+ * Copyright 2023 Google Inc.
+ * SPDX-License-Identifier: Apache-2.0
+ */
+import { BrowserPlatform, type ProfileOptions } from './types.js';
+export declare function resolveDownloadUrl(platform: BrowserPlatform, buildId: string, baseUrl?: string): string;
+export declare function resolveDownloadPath(platform: BrowserPlatform, buildId: string): string[];
+export declare function relativeExecutablePath(platform: BrowserPlatform, buildId: string): string;
+export declare enum FirefoxChannel {
+ STABLE = "stable",
+ ESR = "esr",
+ DEVEDITION = "devedition",
+ BETA = "beta",
+ NIGHTLY = "nightly"
+}
+export declare function resolveBuildId(channel?: FirefoxChannel): Promise;
+export declare function createProfile(options: ProfileOptions): Promise;
+export declare function compareVersions(a: string, b: string): number;
+//# sourceMappingURL=firefox.d.ts.map
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/cjs/browser-data/firefox.d.ts.map b/node_modules/@puppeteer/browsers/lib/cjs/browser-data/firefox.d.ts.map
new file mode 100644
index 0000000..259341b
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/cjs/browser-data/firefox.d.ts.map
@@ -0,0 +1 @@
+{"version":3,"file":"firefox.d.ts","sourceRoot":"","sources":["../../../src/browser-data/firefox.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAOH,OAAO,EAAC,eAAe,EAAE,KAAK,cAAc,EAAC,MAAM,YAAY,CAAC;AA8DhE,wBAAgB,kBAAkB,CAChC,QAAQ,EAAE,eAAe,EACzB,OAAO,EAAE,MAAM,EACf,OAAO,CAAC,EAAE,MAAM,GACf,MAAM,CAiBR;AAED,wBAAgB,mBAAmB,CACjC,QAAQ,EAAE,eAAe,EACzB,OAAO,EAAE,MAAM,GACd,MAAM,EAAE,CAgBV;AAED,wBAAgB,sBAAsB,CACpC,QAAQ,EAAE,eAAe,EACzB,OAAO,EAAE,MAAM,GACd,MAAM,CAoCR;AAED,oBAAY,cAAc;IACxB,MAAM,WAAW;IACjB,GAAG,QAAQ;IACX,UAAU,eAAe;IACzB,IAAI,SAAS;IACb,OAAO,YAAY;CACpB;AAED,wBAAsB,cAAc,CAClC,OAAO,GAAE,cAAuC,GAC/C,OAAO,CAAC,MAAM,CAAC,CAgBjB;AAED,wBAAsB,aAAa,CAAC,OAAO,EAAE,cAAc,GAAG,OAAO,CAAC,IAAI,CAAC,CAa1E;AAkQD,wBAAgB,eAAe,CAAC,CAAC,EAAE,MAAM,EAAE,CAAC,EAAE,MAAM,GAAG,MAAM,CAG5D"}
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/cjs/browser-data/firefox.js b/node_modules/@puppeteer/browsers/lib/cjs/browser-data/firefox.js
new file mode 100644
index 0000000..5800b52
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/cjs/browser-data/firefox.js
@@ -0,0 +1,381 @@
+"use strict";
+/**
+ * @license
+ * Copyright 2023 Google Inc.
+ * SPDX-License-Identifier: Apache-2.0
+ */
+var __importDefault = (this && this.__importDefault) || function (mod) {
+ return (mod && mod.__esModule) ? mod : { "default": mod };
+};
+Object.defineProperty(exports, "__esModule", { value: true });
+exports.FirefoxChannel = void 0;
+exports.resolveDownloadUrl = resolveDownloadUrl;
+exports.resolveDownloadPath = resolveDownloadPath;
+exports.relativeExecutablePath = relativeExecutablePath;
+exports.resolveBuildId = resolveBuildId;
+exports.createProfile = createProfile;
+exports.compareVersions = compareVersions;
+const node_fs_1 = __importDefault(require("node:fs"));
+const node_path_1 = __importDefault(require("node:path"));
+const httpUtil_js_1 = require("../httpUtil.js");
+const types_js_1 = require("./types.js");
+function getFormat(buildId) {
+ const majorVersion = Number(buildId.split('.').shift());
+ return majorVersion >= 135 ? 'xz' : 'bz2';
+}
+function archiveNightly(platform, buildId) {
+ switch (platform) {
+ case types_js_1.BrowserPlatform.LINUX:
+ return `firefox-${buildId}.en-US.linux-x86_64.tar.${getFormat(buildId)}`;
+ case types_js_1.BrowserPlatform.LINUX_ARM:
+ return `firefox-${buildId}.en-US.linux-aarch64.tar.${getFormat(buildId)}`;
+ case types_js_1.BrowserPlatform.MAC_ARM:
+ case types_js_1.BrowserPlatform.MAC:
+ return `firefox-${buildId}.en-US.mac.dmg`;
+ case types_js_1.BrowserPlatform.WIN32:
+ case types_js_1.BrowserPlatform.WIN64:
+ return `firefox-${buildId}.en-US.${platform}.zip`;
+ }
+}
+function archive(platform, buildId) {
+ switch (platform) {
+ case types_js_1.BrowserPlatform.LINUX_ARM:
+ case types_js_1.BrowserPlatform.LINUX:
+ return `firefox-${buildId}.tar.${getFormat(buildId)}`;
+ case types_js_1.BrowserPlatform.MAC_ARM:
+ case types_js_1.BrowserPlatform.MAC:
+ return `Firefox ${buildId}.dmg`;
+ case types_js_1.BrowserPlatform.WIN32:
+ case types_js_1.BrowserPlatform.WIN64:
+ return `Firefox Setup ${buildId}.exe`;
+ }
+}
+function platformName(platform) {
+ switch (platform) {
+ case types_js_1.BrowserPlatform.LINUX:
+ return `linux-x86_64`;
+ case types_js_1.BrowserPlatform.LINUX_ARM:
+ return `linux-aarch64`;
+ case types_js_1.BrowserPlatform.MAC_ARM:
+ case types_js_1.BrowserPlatform.MAC:
+ return `mac`;
+ case types_js_1.BrowserPlatform.WIN32:
+ case types_js_1.BrowserPlatform.WIN64:
+ return platform;
+ }
+}
+function parseBuildId(buildId) {
+ for (const value of Object.values(FirefoxChannel)) {
+ if (buildId.startsWith(value + '_')) {
+ buildId = buildId.substring(value.length + 1);
+ return [value, buildId];
+ }
+ }
+ // Older versions do not have channel as the prefix.«
+ return [FirefoxChannel.NIGHTLY, buildId];
+}
+function resolveDownloadUrl(platform, buildId, baseUrl) {
+ const [channel] = parseBuildId(buildId);
+ switch (channel) {
+ case FirefoxChannel.NIGHTLY:
+ baseUrl ??=
+ 'https://archive.mozilla.org/pub/firefox/nightly/latest-mozilla-central';
+ break;
+ case FirefoxChannel.DEVEDITION:
+ baseUrl ??= 'https://archive.mozilla.org/pub/devedition/releases';
+ break;
+ case FirefoxChannel.BETA:
+ case FirefoxChannel.STABLE:
+ case FirefoxChannel.ESR:
+ baseUrl ??= 'https://archive.mozilla.org/pub/firefox/releases';
+ break;
+ }
+ return `${baseUrl}/${resolveDownloadPath(platform, buildId).join('/')}`;
+}
+function resolveDownloadPath(platform, buildId) {
+ const [channel, resolvedBuildId] = parseBuildId(buildId);
+ switch (channel) {
+ case FirefoxChannel.NIGHTLY:
+ return [archiveNightly(platform, resolvedBuildId)];
+ case FirefoxChannel.DEVEDITION:
+ case FirefoxChannel.BETA:
+ case FirefoxChannel.STABLE:
+ case FirefoxChannel.ESR:
+ return [
+ resolvedBuildId,
+ platformName(platform),
+ 'en-US',
+ archive(platform, resolvedBuildId),
+ ];
+ }
+}
+function relativeExecutablePath(platform, buildId) {
+ const [channel] = parseBuildId(buildId);
+ switch (channel) {
+ case FirefoxChannel.NIGHTLY:
+ switch (platform) {
+ case types_js_1.BrowserPlatform.MAC_ARM:
+ case types_js_1.BrowserPlatform.MAC:
+ return node_path_1.default.join('Firefox Nightly.app', 'Contents', 'MacOS', 'firefox');
+ case types_js_1.BrowserPlatform.LINUX_ARM:
+ case types_js_1.BrowserPlatform.LINUX:
+ return node_path_1.default.join('firefox', 'firefox');
+ case types_js_1.BrowserPlatform.WIN32:
+ case types_js_1.BrowserPlatform.WIN64:
+ return node_path_1.default.join('firefox', 'firefox.exe');
+ }
+ case FirefoxChannel.BETA:
+ case FirefoxChannel.DEVEDITION:
+ case FirefoxChannel.ESR:
+ case FirefoxChannel.STABLE:
+ switch (platform) {
+ case types_js_1.BrowserPlatform.MAC_ARM:
+ case types_js_1.BrowserPlatform.MAC:
+ return node_path_1.default.join('Firefox.app', 'Contents', 'MacOS', 'firefox');
+ case types_js_1.BrowserPlatform.LINUX_ARM:
+ case types_js_1.BrowserPlatform.LINUX:
+ return node_path_1.default.join('firefox', 'firefox');
+ case types_js_1.BrowserPlatform.WIN32:
+ case types_js_1.BrowserPlatform.WIN64:
+ return node_path_1.default.join('core', 'firefox.exe');
+ }
+ }
+}
+var FirefoxChannel;
+(function (FirefoxChannel) {
+ FirefoxChannel["STABLE"] = "stable";
+ FirefoxChannel["ESR"] = "esr";
+ FirefoxChannel["DEVEDITION"] = "devedition";
+ FirefoxChannel["BETA"] = "beta";
+ FirefoxChannel["NIGHTLY"] = "nightly";
+})(FirefoxChannel || (exports.FirefoxChannel = FirefoxChannel = {}));
+async function resolveBuildId(channel = FirefoxChannel.NIGHTLY) {
+ const channelToVersionKey = {
+ [FirefoxChannel.ESR]: 'FIREFOX_ESR',
+ [FirefoxChannel.STABLE]: 'LATEST_FIREFOX_VERSION',
+ [FirefoxChannel.DEVEDITION]: 'FIREFOX_DEVEDITION',
+ [FirefoxChannel.BETA]: 'FIREFOX_DEVEDITION',
+ [FirefoxChannel.NIGHTLY]: 'FIREFOX_NIGHTLY',
+ };
+ const versions = (await (0, httpUtil_js_1.getJSON)(new URL('https://product-details.mozilla.org/1.0/firefox_versions.json')));
+ const version = versions[channelToVersionKey[channel]];
+ if (!version) {
+ throw new Error(`Channel ${channel} is not found.`);
+ }
+ return channel + '_' + version;
+}
+async function createProfile(options) {
+ if (!node_fs_1.default.existsSync(options.path)) {
+ await node_fs_1.default.promises.mkdir(options.path, {
+ recursive: true,
+ });
+ }
+ await syncPreferences({
+ preferences: {
+ ...defaultProfilePreferences(options.preferences),
+ ...options.preferences,
+ },
+ path: options.path,
+ });
+}
+function defaultProfilePreferences(extraPrefs) {
+ const server = 'dummy.test';
+ const defaultPrefs = {
+ // Make sure Shield doesn't hit the network.
+ 'app.normandy.api_url': '',
+ // Disable Firefox old build background check
+ 'app.update.checkInstallTime': false,
+ // Disable automatically upgrading Firefox
+ 'app.update.disabledForTesting': true,
+ // Increase the APZ content response timeout to 1 minute
+ 'apz.content_response_timeout': 60000,
+ // Disables backup service to improve startup performance and stability. See
+ // https://github.com/puppeteer/puppeteer/issues/14194. TODO: can be removed
+ // once the service is disabled on the Firefox side for WebDriver (see
+ // https://bugzilla.mozilla.org/show_bug.cgi?id=1988250).
+ 'browser.backup.enabled': false,
+ // Prevent various error message on the console
+ // jest-puppeteer asserts that no error message is emitted by the console
+ 'browser.contentblocking.features.standard': '-tp,tpPrivate,cookieBehavior0,-cryptoTP,-fp',
+ // Enable the dump function: which sends messages to the system
+ // console
+ // https://bugzilla.mozilla.org/show_bug.cgi?id=1543115
+ 'browser.dom.window.dump.enabled': true,
+ // Disable topstories
+ 'browser.newtabpage.activity-stream.feeds.system.topstories': false,
+ // Always display a blank page
+ 'browser.newtabpage.enabled': false,
+ // Background thumbnails in particular cause grief: and disabling
+ // thumbnails in general cannot hurt
+ 'browser.pagethumbnails.capturing_disabled': true,
+ // Disable safebrowsing components.
+ 'browser.safebrowsing.blockedURIs.enabled': false,
+ 'browser.safebrowsing.downloads.enabled': false,
+ 'browser.safebrowsing.malware.enabled': false,
+ 'browser.safebrowsing.phishing.enabled': false,
+ // Disable updates to search engines.
+ 'browser.search.update': false,
+ // Do not restore the last open set of tabs if the browser has crashed
+ 'browser.sessionstore.resume_from_crash': false,
+ // Skip check for default browser on startup
+ 'browser.shell.checkDefaultBrowser': false,
+ // Disable newtabpage
+ 'browser.startup.homepage': 'about:blank',
+ // Do not redirect user when a milstone upgrade of Firefox is detected
+ 'browser.startup.homepage_override.mstone': 'ignore',
+ // Start with a blank page about:blank
+ 'browser.startup.page': 0,
+ // Do not allow background tabs to be zombified on Android: otherwise for
+ // tests that open additional tabs: the test harness tab itself might get
+ // unloaded
+ 'browser.tabs.disableBackgroundZombification': false,
+ // Do not warn when closing all other open tabs
+ 'browser.tabs.warnOnCloseOtherTabs': false,
+ // Do not warn when multiple tabs will be opened
+ 'browser.tabs.warnOnOpen': false,
+ // Do not automatically offer translations, as tests do not expect this.
+ 'browser.translations.automaticallyPopup': false,
+ // Disable the UI tour.
+ 'browser.uitour.enabled': false,
+ // Turn off search suggestions in the location bar so as not to trigger
+ // network connections.
+ 'browser.urlbar.suggest.searches': false,
+ // Disable first run splash page on Windows 10
+ 'browser.usedOnWindows10.introURL': '',
+ // Do not warn on quitting Firefox
+ 'browser.warnOnQuit': false,
+ // Defensively disable data reporting systems
+ 'datareporting.healthreport.documentServerURI': `http://${server}/dummy/healthreport/`,
+ 'datareporting.healthreport.logging.consoleEnabled': false,
+ 'datareporting.healthreport.service.enabled': false,
+ 'datareporting.healthreport.service.firstRun': false,
+ 'datareporting.healthreport.uploadEnabled': false,
+ // Do not show datareporting policy notifications which can interfere with tests
+ 'datareporting.policy.dataSubmissionEnabled': false,
+ 'datareporting.policy.dataSubmissionPolicyBypassNotification': true,
+ // DevTools JSONViewer sometimes fails to load dependencies with its require.js.
+ // This doesn't affect Puppeteer but spams console (Bug 1424372)
+ 'devtools.jsonview.enabled': false,
+ // Disable popup-blocker
+ 'dom.disable_open_during_load': false,
+ // Enable the support for File object creation in the content process
+ // Required for |Page.setFileInputFiles| protocol method.
+ 'dom.file.createInChild': true,
+ // Disable the ProcessHangMonitor
+ 'dom.ipc.reportProcessHangs': false,
+ // Disable slow script dialogues
+ 'dom.max_chrome_script_run_time': 0,
+ 'dom.max_script_run_time': 0,
+ // Only load extensions from the application and user profile
+ // AddonManager.SCOPE_PROFILE + AddonManager.SCOPE_APPLICATION
+ 'extensions.autoDisableScopes': 0,
+ 'extensions.enabledScopes': 5,
+ // Disable metadata caching for installed add-ons by default
+ 'extensions.getAddons.cache.enabled': false,
+ // Disable installing any distribution extensions or add-ons.
+ 'extensions.installDistroAddons': false,
+ // Turn off extension updates so they do not bother tests
+ 'extensions.update.enabled': false,
+ // Turn off extension updates so they do not bother tests
+ 'extensions.update.notifyUser': false,
+ // Make sure opening about:addons will not hit the network
+ 'extensions.webservice.discoverURL': `http://${server}/dummy/discoveryURL`,
+ // Allow the application to have focus even it runs in the background
+ 'focusmanager.testmode': true,
+ // Disable useragent updates
+ 'general.useragent.updates.enabled': false,
+ // Always use network provider for geolocation tests so we bypass the
+ // macOS dialog raised by the corelocation provider
+ 'geo.provider.testing': true,
+ // Do not scan Wifi
+ 'geo.wifi.scan': false,
+ // No hang monitor
+ 'hangmonitor.timeout': 0,
+ // Show chrome errors and warnings in the error console
+ 'javascript.options.showInConsole': true,
+ // Disable download and usage of OpenH264: and Widevine plugins
+ 'media.gmp-manager.updateEnabled': false,
+ // Disable the GFX sanity window
+ 'media.sanity-test.disabled': true,
+ // Disable experimental feature that is only available in Nightly
+ 'network.cookie.sameSite.laxByDefault': false,
+ // Do not prompt for temporary redirects
+ 'network.http.prompt-temp-redirect': false,
+ // Disable speculative connections so they are not reported as leaking
+ // when they are hanging around
+ 'network.http.speculative-parallel-limit': 0,
+ // Do not automatically switch between offline and online
+ 'network.manage-offline-status': false,
+ // Make sure SNTP requests do not hit the network
+ 'network.sntp.pools': server,
+ // Disable Flash.
+ 'plugin.state.flash': 0,
+ 'privacy.trackingprotection.enabled': false,
+ // Can be removed once Firefox 89 is no longer supported
+ // https://bugzilla.mozilla.org/show_bug.cgi?id=1710839
+ 'remote.enabled': true,
+ // Disabled screenshots component
+ 'screenshots.browser.component.enabled': false,
+ // Don't do network connections for mitm priming
+ 'security.certerrors.mitm.priming.enabled': false,
+ // Local documents have access to all other local documents,
+ // including directory listings
+ 'security.fileuri.strict_origin_policy': false,
+ // Do not wait for the notification button security delay
+ 'security.notification_enable_delay': 0,
+ // Ensure blocklist updates do not hit the network
+ 'services.settings.server': `http://${server}/dummy/blocklist/`,
+ // Do not automatically fill sign-in forms with known usernames and
+ // passwords
+ 'signon.autofillForms': false,
+ // Disable password capture, so that tests that include forms are not
+ // influenced by the presence of the persistent doorhanger notification
+ 'signon.rememberSignons': false,
+ // Disable first-run welcome page
+ 'startup.homepage_welcome_url': 'about:blank',
+ // Disable first-run welcome page
+ 'startup.homepage_welcome_url.additional': '',
+ // Disable browser animations (tabs, fullscreen, sliding alerts)
+ 'toolkit.cosmeticAnimations.enabled': false,
+ // Prevent starting into safe mode after application crashes
+ 'toolkit.startup.max_resumed_crashes': -1,
+ };
+ return Object.assign(defaultPrefs, extraPrefs);
+}
+async function backupFile(input) {
+ if (!node_fs_1.default.existsSync(input)) {
+ return;
+ }
+ await node_fs_1.default.promises.copyFile(input, input + '.puppeteer');
+}
+/**
+ * Populates the user.js file with custom preferences as needed to allow
+ * Firefox's support to properly function. These preferences will be
+ * automatically copied over to prefs.js during startup of Firefox. To be
+ * able to restore the original values of preferences a backup of prefs.js
+ * will be created.
+ */
+async function syncPreferences(options) {
+ const prefsPath = node_path_1.default.join(options.path, 'prefs.js');
+ const userPath = node_path_1.default.join(options.path, 'user.js');
+ const lines = Object.entries(options.preferences).map(([key, value]) => {
+ return `user_pref(${JSON.stringify(key)}, ${JSON.stringify(value)});`;
+ });
+ // Use allSettled to prevent corruption.
+ const result = await Promise.allSettled([
+ backupFile(userPath).then(async () => {
+ await node_fs_1.default.promises.writeFile(userPath, lines.join('\n'));
+ }),
+ backupFile(prefsPath),
+ ]);
+ for (const command of result) {
+ if (command.status === 'rejected') {
+ throw command.reason;
+ }
+ }
+}
+function compareVersions(a, b) {
+ // TODO: this is a not very reliable check.
+ return parseInt(a.replace('.', ''), 16) - parseInt(b.replace('.', ''), 16);
+}
+//# sourceMappingURL=firefox.js.map
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/cjs/browser-data/firefox.js.map b/node_modules/@puppeteer/browsers/lib/cjs/browser-data/firefox.js.map
new file mode 100644
index 0000000..8bf48a4
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/cjs/browser-data/firefox.js.map
@@ -0,0 +1 @@
+{"version":3,"file":"firefox.js","sourceRoot":"","sources":["../../../src/browser-data/firefox.ts"],"names":[],"mappings":";AAAA;;;;GAIG;;;;;;AAqEH,gDAqBC;AAED,kDAmBC;AAED,wDAuCC;AAUD,wCAkBC;AAED,sCAaC;AAkQD,0CAGC;AAtcD,sDAAyB;AACzB,0DAA6B;AAE7B,gDAAuC;AAEvC,yCAAgE;AAEhE,SAAS,SAAS,CAAC,OAAe;IAChC,MAAM,YAAY,GAAG,MAAM,CAAC,OAAO,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC,KAAK,EAAG,CAAC,CAAC;IACzD,OAAO,YAAY,IAAI,GAAG,CAAC,CAAC,CAAC,IAAI,CAAC,CAAC,CAAC,KAAK,CAAC;AAC5C,CAAC;AAED,SAAS,cAAc,CAAC,QAAyB,EAAE,OAAe;IAChE,QAAQ,QAAQ,EAAE,CAAC;QACjB,KAAK,0BAAe,CAAC,KAAK;YACxB,OAAO,WAAW,OAAO,2BAA2B,SAAS,CAAC,OAAO,CAAC,EAAE,CAAC;QAC3E,KAAK,0BAAe,CAAC,SAAS;YAC5B,OAAO,WAAW,OAAO,4BAA4B,SAAS,CAAC,OAAO,CAAC,EAAE,CAAC;QAC5E,KAAK,0BAAe,CAAC,OAAO,CAAC;QAC7B,KAAK,0BAAe,CAAC,GAAG;YACtB,OAAO,WAAW,OAAO,gBAAgB,CAAC;QAC5C,KAAK,0BAAe,CAAC,KAAK,CAAC;QAC3B,KAAK,0BAAe,CAAC,KAAK;YACxB,OAAO,WAAW,OAAO,UAAU,QAAQ,M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AAC,CAAC,OAAO,CAAC,GAAG,EAAE,EAAE,CAAC,EAAE,EAAE,CAAC,GAAG,QAAQ,CAAC,CAAC,CAAC,OAAO,CAAC,GAAG,EAAE,EAAE,CAAC,EAAE,EAAE,CAAC,CAAC;AAC7E,CAAC"}
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/cjs/browser-data/types.d.ts b/node_modules/@puppeteer/browsers/lib/cjs/browser-data/types.d.ts
new file mode 100644
index 0000000..a1aaecc
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/cjs/browser-data/types.d.ts
@@ -0,0 +1,66 @@
+/**
+ * @license
+ * Copyright 2023 Google Inc.
+ * SPDX-License-Identifier: Apache-2.0
+ */
+/**
+ * Supported browsers.
+ *
+ * @public
+ */
+export declare enum Browser {
+ CHROME = "chrome",
+ CHROMEHEADLESSSHELL = "chrome-headless-shell",
+ CHROMIUM = "chromium",
+ FIREFOX = "firefox",
+ CHROMEDRIVER = "chromedriver"
+}
+/**
+ * Platform names used to identify a OS platform x architecture combination in the way
+ * that is relevant for the browser download.
+ *
+ * @public
+ */
+export declare enum BrowserPlatform {
+ LINUX = "linux",
+ LINUX_ARM = "linux_arm",
+ MAC = "mac",
+ MAC_ARM = "mac_arm",
+ WIN32 = "win32",
+ WIN64 = "win64"
+}
+/**
+ * Enum describing a release channel for a browser.
+ *
+ * You can use this in combination with {@link resolveBuildId} to resolve
+ * a build ID based on a release channel.
+ *
+ * @public
+ */
+export declare enum BrowserTag {
+ CANARY = "canary",
+ NIGHTLY = "nightly",
+ BETA = "beta",
+ DEV = "dev",
+ DEVEDITION = "devedition",
+ STABLE = "stable",
+ ESR = "esr",
+ LATEST = "latest"
+}
+/**
+ * @public
+ */
+export interface ProfileOptions {
+ preferences: Record;
+ path: string;
+}
+/**
+ * @public
+ */
+export declare enum ChromeReleaseChannel {
+ STABLE = "stable",
+ DEV = "dev",
+ CANARY = "canary",
+ BETA = "beta"
+}
+//# sourceMappingURL=types.d.ts.map
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/cjs/browser-data/types.d.ts.map b/node_modules/@puppeteer/browsers/lib/cjs/browser-data/types.d.ts.map
new file mode 100644
index 0000000..9a647cd
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/cjs/browser-data/types.d.ts.map
@@ -0,0 +1 @@
+{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../src/browser-data/types.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH;;;;GAIG;AACH,oBAAY,OAAO;IACjB,MAAM,WAAW;IACjB,mBAAmB,0BAA0B;IAC7C,QAAQ,aAAa;IACrB,OAAO,YAAY;IACnB,YAAY,iBAAiB;CAC9B;AAED;;;;;GAKG;AACH,oBAAY,eAAe;IACzB,KAAK,UAAU;IACf,SAAS,cAAc;IACvB,GAAG,QAAQ;IACX,OAAO,YAAY;IACnB,KAAK,UAAU;IACf,KAAK,UAAU;CAChB;AAED;;;;;;;GAOG;AACH,oBAAY,UAAU;IACpB,MAAM,WAAW;IACjB,OAAO,YAAY;IACnB,IAAI,SAAS;IACb,GAAG,QAAQ;IACX,UAAU,eAAe;IACzB,MAAM,WAAW;IACjB,GAAG,QAAQ;IACX,MAAM,WAAW;CAClB;AAED;;GAEG;AACH,MAAM,WAAW,cAAc;IAC7B,WAAW,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;IACrC,IAAI,EAAE,MAAM,CAAC;CACd;AAED;;GAEG;AACH,oBAAY,oBAAoB;IAC9B,MAAM,WAAW;IACjB,GAAG,QAAQ;IACX,MAAM,WAAW;IACjB,IAAI,SAAS;CACd"}
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/cjs/browser-data/types.js b/node_modules/@puppeteer/browsers/lib/cjs/browser-data/types.js
new file mode 100644
index 0000000..c55e39a
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/cjs/browser-data/types.js
@@ -0,0 +1,66 @@
+"use strict";
+/**
+ * @license
+ * Copyright 2023 Google Inc.
+ * SPDX-License-Identifier: Apache-2.0
+ */
+Object.defineProperty(exports, "__esModule", { value: true });
+exports.ChromeReleaseChannel = exports.BrowserTag = exports.BrowserPlatform = exports.Browser = void 0;
+/**
+ * Supported browsers.
+ *
+ * @public
+ */
+var Browser;
+(function (Browser) {
+ Browser["CHROME"] = "chrome";
+ Browser["CHROMEHEADLESSSHELL"] = "chrome-headless-shell";
+ Browser["CHROMIUM"] = "chromium";
+ Browser["FIREFOX"] = "firefox";
+ Browser["CHROMEDRIVER"] = "chromedriver";
+})(Browser || (exports.Browser = Browser = {}));
+/**
+ * Platform names used to identify a OS platform x architecture combination in the way
+ * that is relevant for the browser download.
+ *
+ * @public
+ */
+var BrowserPlatform;
+(function (BrowserPlatform) {
+ BrowserPlatform["LINUX"] = "linux";
+ BrowserPlatform["LINUX_ARM"] = "linux_arm";
+ BrowserPlatform["MAC"] = "mac";
+ BrowserPlatform["MAC_ARM"] = "mac_arm";
+ BrowserPlatform["WIN32"] = "win32";
+ BrowserPlatform["WIN64"] = "win64";
+})(BrowserPlatform || (exports.BrowserPlatform = BrowserPlatform = {}));
+/**
+ * Enum describing a release channel for a browser.
+ *
+ * You can use this in combination with {@link resolveBuildId} to resolve
+ * a build ID based on a release channel.
+ *
+ * @public
+ */
+var BrowserTag;
+(function (BrowserTag) {
+ BrowserTag["CANARY"] = "canary";
+ BrowserTag["NIGHTLY"] = "nightly";
+ BrowserTag["BETA"] = "beta";
+ BrowserTag["DEV"] = "dev";
+ BrowserTag["DEVEDITION"] = "devedition";
+ BrowserTag["STABLE"] = "stable";
+ BrowserTag["ESR"] = "esr";
+ BrowserTag["LATEST"] = "latest";
+})(BrowserTag || (exports.BrowserTag = BrowserTag = {}));
+/**
+ * @public
+ */
+var ChromeReleaseChannel;
+(function (ChromeReleaseChannel) {
+ ChromeReleaseChannel["STABLE"] = "stable";
+ ChromeReleaseChannel["DEV"] = "dev";
+ ChromeReleaseChannel["CANARY"] = "canary";
+ ChromeReleaseChannel["BETA"] = "beta";
+})(ChromeReleaseChannel || (exports.ChromeReleaseChannel = ChromeReleaseChannel = {}));
+//# sourceMappingURL=types.js.map
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/cjs/browser-data/types.js.map b/node_modules/@puppeteer/browsers/lib/cjs/browser-data/types.js.map
new file mode 100644
index 0000000..06f918f
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/cjs/browser-data/types.js.map
@@ -0,0 +1 @@
+{"version":3,"file":"types.js","sourceRoot":"","sources":["../../../src/browser-data/types.ts"],"names":[],"mappings":";AAAA;;;;GAIG;;;AAEH;;;;GAIG;AACH,IAAY,OAMX;AAND,WAAY,OAAO;IACjB,4BAAiB,CAAA;IACjB,wDAA6C,CAAA;IAC7C,gCAAqB,CAAA;IACrB,8BAAmB,CAAA;IACnB,wCAA6B,CAAA;AAC/B,CAAC,EANW,OAAO,uBAAP,OAAO,QAMlB;AAED;;;;;GAKG;AACH,IAAY,eAOX;AAPD,WAAY,eAAe;IACzB,kCAAe,CAAA;IACf,0CAAuB,CAAA;IACvB,8BAAW,CAAA;IACX,sCAAmB,CAAA;IACnB,kCAAe,CAAA;IACf,kCAAe,CAAA;AACjB,CAAC,EAPW,eAAe,+BAAf,eAAe,QAO1B;AAED;;;;;;;GAOG;AACH,IAAY,UASX;AATD,WAAY,UAAU;IACpB,+BAAiB,CAAA;IACjB,iCAAmB,CAAA;IACnB,2BAAa,CAAA;IACb,yBAAW,CAAA;IACX,uCAAyB,CAAA;IACzB,+BAAiB,CAAA;IACjB,yBAAW,CAAA;IACX,+BAAiB,CAAA;AACnB,CAAC,EATW,UAAU,0BAAV,UAAU,QASrB;AAUD;;GAEG;AACH,IAAY,oBAKX;AALD,WAAY,oBAAoB;IAC9B,yCAAiB,CAAA;IACjB,mCAAW,CAAA;IACX,yCAAiB,CAAA;IACjB,qCAAa,CAAA;AACf,CAAC,EALW,oBAAoB,oCAApB,oBAAoB,QAK/B"}
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/cjs/debug.d.ts b/node_modules/@puppeteer/browsers/lib/cjs/debug.d.ts
new file mode 100644
index 0000000..aa062da
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/cjs/debug.d.ts
@@ -0,0 +1,8 @@
+/**
+ * @license
+ * Copyright 2023 Google Inc.
+ * SPDX-License-Identifier: Apache-2.0
+ */
+import debug from 'debug';
+export { debug };
+//# sourceMappingURL=debug.d.ts.map
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/cjs/debug.d.ts.map b/node_modules/@puppeteer/browsers/lib/cjs/debug.d.ts.map
new file mode 100644
index 0000000..2f5f252
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/cjs/debug.d.ts.map
@@ -0,0 +1 @@
+{"version":3,"file":"debug.d.ts","sourceRoot":"","sources":["../../src/debug.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,OAAO,KAAK,MAAM,OAAO,CAAC;AAE1B,OAAO,EAAC,KAAK,EAAC,CAAC"}
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/cjs/debug.js b/node_modules/@puppeteer/browsers/lib/cjs/debug.js
new file mode 100644
index 0000000..754d7e2
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/cjs/debug.js
@@ -0,0 +1,14 @@
+"use strict";
+/**
+ * @license
+ * Copyright 2023 Google Inc.
+ * SPDX-License-Identifier: Apache-2.0
+ */
+var __importDefault = (this && this.__importDefault) || function (mod) {
+ return (mod && mod.__esModule) ? mod : { "default": mod };
+};
+Object.defineProperty(exports, "__esModule", { value: true });
+exports.debug = void 0;
+const debug_1 = __importDefault(require("debug"));
+exports.debug = debug_1.default;
+//# sourceMappingURL=debug.js.map
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/cjs/debug.js.map b/node_modules/@puppeteer/browsers/lib/cjs/debug.js.map
new file mode 100644
index 0000000..e300130
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/cjs/debug.js.map
@@ -0,0 +1 @@
+{"version":3,"file":"debug.js","sourceRoot":"","sources":["../../src/debug.ts"],"names":[],"mappings":";AAAA;;;;GAIG;;;;;;AAEH,kDAA0B;AAElB,gBAFD,eAAK,CAEC"}
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/cjs/detectPlatform.d.ts b/node_modules/@puppeteer/browsers/lib/cjs/detectPlatform.d.ts
new file mode 100644
index 0000000..3ed4758
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/cjs/detectPlatform.d.ts
@@ -0,0 +1,11 @@
+/**
+ * @license
+ * Copyright 2023 Google Inc.
+ * SPDX-License-Identifier: Apache-2.0
+ */
+import { BrowserPlatform } from './browser-data/browser-data.js';
+/**
+ * @public
+ */
+export declare function detectBrowserPlatform(): BrowserPlatform | undefined;
+//# sourceMappingURL=detectPlatform.d.ts.map
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/cjs/detectPlatform.d.ts.map b/node_modules/@puppeteer/browsers/lib/cjs/detectPlatform.d.ts.map
new file mode 100644
index 0000000..d71877b
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/cjs/detectPlatform.d.ts.map
@@ -0,0 +1 @@
+{"version":3,"file":"detectPlatform.d.ts","sourceRoot":"","sources":["../../src/detectPlatform.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAIH,OAAO,EAAC,eAAe,EAAC,MAAM,gCAAgC,CAAC;AAE/D;;GAEG;AACH,wBAAgB,qBAAqB,IAAI,eAAe,GAAG,SAAS,CAmBnE"}
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/cjs/detectPlatform.js b/node_modules/@puppeteer/browsers/lib/cjs/detectPlatform.js
new file mode 100644
index 0000000..056ea7e
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/cjs/detectPlatform.js
@@ -0,0 +1,53 @@
+"use strict";
+/**
+ * @license
+ * Copyright 2023 Google Inc.
+ * SPDX-License-Identifier: Apache-2.0
+ */
+var __importDefault = (this && this.__importDefault) || function (mod) {
+ return (mod && mod.__esModule) ? mod : { "default": mod };
+};
+Object.defineProperty(exports, "__esModule", { value: true });
+exports.detectBrowserPlatform = detectBrowserPlatform;
+const node_os_1 = __importDefault(require("node:os"));
+const browser_data_js_1 = require("./browser-data/browser-data.js");
+/**
+ * @public
+ */
+function detectBrowserPlatform() {
+ const platform = node_os_1.default.platform();
+ const arch = node_os_1.default.arch();
+ switch (platform) {
+ case 'darwin':
+ return arch === 'arm64' ? browser_data_js_1.BrowserPlatform.MAC_ARM : browser_data_js_1.BrowserPlatform.MAC;
+ case 'linux':
+ return arch === 'arm64'
+ ? browser_data_js_1.BrowserPlatform.LINUX_ARM
+ : browser_data_js_1.BrowserPlatform.LINUX;
+ case 'win32':
+ return arch === 'x64' ||
+ // Windows 11 for ARM supports x64 emulation
+ (arch === 'arm64' && isWindows11(node_os_1.default.release()))
+ ? browser_data_js_1.BrowserPlatform.WIN64
+ : browser_data_js_1.BrowserPlatform.WIN32;
+ default:
+ return undefined;
+ }
+}
+/**
+ * Windows 11 is identified by the version 10.0.22000 or greater
+ * @internal
+ */
+function isWindows11(version) {
+ const parts = version.split('.');
+ if (parts.length > 2) {
+ const major = parseInt(parts[0], 10);
+ const minor = parseInt(parts[1], 10);
+ const patch = parseInt(parts[2], 10);
+ return (major > 10 ||
+ (major === 10 && minor > 0) ||
+ (major === 10 && minor === 0 && patch >= 22000));
+ }
+ return false;
+}
+//# sourceMappingURL=detectPlatform.js.map
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/cjs/detectPlatform.js.map b/node_modules/@puppeteer/browsers/lib/cjs/detectPlatform.js.map
new file mode 100644
index 0000000..1809082
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/cjs/detectPlatform.js.map
@@ -0,0 +1 @@
+{"version":3,"file":"detectPlatform.js","sourceRoot":"","sources":["../../src/detectPlatform.ts"],"names":[],"mappings":";AAAA;;;;GAIG;;;;;AASH,sDAmBC;AA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K,KAAK,EAAE,IAAI,KAAK,GAAG,CAAC,CAAC;YAC3B,CAAC,KAAK,KAAK,EAAE,IAAI,KAAK,KAAK,CAAC,IAAI,KAAK,IAAI,KAAK,CAAC,CAChD,CAAC;IACJ,CAAC;IACD,OAAO,KAAK,CAAC;AACf,CAAC"}
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/cjs/fileUtil.d.ts b/node_modules/@puppeteer/browsers/lib/cjs/fileUtil.d.ts
new file mode 100644
index 0000000..63b529c
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/cjs/fileUtil.d.ts
@@ -0,0 +1,17 @@
+/**
+ * @license
+ * Copyright 2023 Google Inc.
+ * SPDX-License-Identifier: Apache-2.0
+ */
+/**
+ * @internal
+ */
+export declare function unpackArchive(archivePath: string, folderPath: string): Promise;
+/**
+ * @internal
+ */
+export declare const internalConstantsForTesting: {
+ xz: string;
+ bzip2: string;
+};
+//# sourceMappingURL=fileUtil.d.ts.map
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/cjs/fileUtil.d.ts.map b/node_modules/@puppeteer/browsers/lib/cjs/fileUtil.d.ts.map
new file mode 100644
index 0000000..cfa5ebe
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/cjs/fileUtil.d.ts.map
@@ -0,0 +1 @@
+{"version":3,"file":"fileUtil.d.ts","sourceRoot":"","sources":["../../src/fileUtil.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAcH;;GAEG;AACH,wBAAsB,aAAa,CACjC,WAAW,EAAE,MAAM,EACnB,UAAU,EAAE,MAAM,GACjB,OAAO,CAAC,IAAI,CAAC,CA6Bf;AAgDD;;GAEG;AACH,eAAO,MAAM,2BAA2B;;;CAGvC,CAAC"}
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/cjs/fileUtil.js b/node_modules/@puppeteer/browsers/lib/cjs/fileUtil.js
new file mode 100644
index 0000000..700e209
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/cjs/fileUtil.js
@@ -0,0 +1,196 @@
+"use strict";
+/**
+ * @license
+ * Copyright 2023 Google Inc.
+ * SPDX-License-Identifier: Apache-2.0
+ */
+var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
+ if (k2 === undefined) k2 = k;
+ var desc = Object.getOwnPropertyDescriptor(m, k);
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
+ desc = { enumerable: true, get: function() { return m[k]; } };
+ }
+ Object.defineProperty(o, k2, desc);
+}) : (function(o, m, k, k2) {
+ if (k2 === undefined) k2 = k;
+ o[k2] = m[k];
+}));
+var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
+ Object.defineProperty(o, "default", { enumerable: true, value: v });
+}) : function(o, v) {
+ o["default"] = v;
+});
+var __importStar = (this && this.__importStar) || (function () {
+ var ownKeys = function(o) {
+ ownKeys = Object.getOwnPropertyNames || function (o) {
+ var ar = [];
+ for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
+ return ar;
+ };
+ return ownKeys(o);
+ };
+ return function (mod) {
+ if (mod && mod.__esModule) return mod;
+ var result = {};
+ if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
+ __setModuleDefault(result, mod);
+ return result;
+ };
+})();
+var __importDefault = (this && this.__importDefault) || function (mod) {
+ return (mod && mod.__esModule) ? mod : { "default": mod };
+};
+Object.defineProperty(exports, "__esModule", { value: true });
+exports.internalConstantsForTesting = void 0;
+exports.unpackArchive = unpackArchive;
+const node_child_process_1 = require("node:child_process");
+const node_fs_1 = require("node:fs");
+const promises_1 = require("node:fs/promises");
+const path = __importStar(require("node:path"));
+const node_stream_1 = require("node:stream");
+const debug_1 = __importDefault(require("debug"));
+const debugFileUtil = (0, debug_1.default)('puppeteer:browsers:fileUtil');
+/**
+ * @internal
+ */
+async function unpackArchive(archivePath, folderPath) {
+ if (!path.isAbsolute(folderPath)) {
+ folderPath = path.resolve(process.cwd(), folderPath);
+ }
+ if (archivePath.endsWith('.zip')) {
+ const extractZip = await import('extract-zip');
+ await extractZip.default(archivePath, { dir: folderPath });
+ }
+ else if (archivePath.endsWith('.tar.bz2')) {
+ await extractTar(archivePath, folderPath, 'bzip2');
+ }
+ else if (archivePath.endsWith('.dmg')) {
+ await (0, promises_1.mkdir)(folderPath);
+ await installDMG(archivePath, folderPath);
+ }
+ else if (archivePath.endsWith('.exe')) {
+ // Firefox on Windows.
+ const result = (0, node_child_process_1.spawnSync)(archivePath, [`/ExtractDir=${folderPath}`], {
+ env: {
+ __compat_layer: 'RunAsInvoker',
+ },
+ });
+ if (result.status !== 0) {
+ throw new Error(`Failed to extract ${archivePath} to ${folderPath}: ${result.output}`);
+ }
+ }
+ else if (archivePath.endsWith('.tar.xz')) {
+ await extractTar(archivePath, folderPath, 'xz');
+ }
+ else {
+ throw new Error(`Unsupported archive format: ${archivePath}`);
+ }
+}
+function createTransformStream(child) {
+ const stream = new node_stream_1.Stream.Transform({
+ transform(chunk, encoding, callback) {
+ if (!child.stdin.write(chunk, encoding)) {
+ child.stdin.once('drain', callback);
+ }
+ else {
+ callback();
+ }
+ },
+ flush(callback) {
+ if (child.stdout.destroyed) {
+ callback();
+ }
+ else {
+ child.stdin.end();
+ child.stdout.on('close', callback);
+ }
+ },
+ });
+ child.stdin.on('error', e => {
+ if ('code' in e && e.code === 'EPIPE') {
+ // finished before reading the file finished (i.e. head)
+ stream.emit('end');
+ }
+ else {
+ stream.destroy(e);
+ }
+ });
+ child.stdout
+ .on('data', data => {
+ return stream.push(data);
+ })
+ .on('error', e => {
+ return stream.destroy(e);
+ });
+ child.once('close', () => {
+ return stream.end();
+ });
+ return stream;
+}
+/**
+ * @internal
+ */
+exports.internalConstantsForTesting = {
+ xz: 'xz',
+ bzip2: 'bzip2',
+};
+/**
+ * @internal
+ */
+async function extractTar(tarPath, folderPath, decompressUtilityName) {
+ const tarFs = await import('tar-fs');
+ return await new Promise((fulfill, reject) => {
+ function handleError(utilityName) {
+ return (error) => {
+ if ('code' in error && error.code === 'ENOENT') {
+ error = new Error(`\`${utilityName}\` utility is required to unpack this archive`, {
+ cause: error,
+ });
+ }
+ reject(error);
+ };
+ }
+ const unpack = (0, node_child_process_1.spawn)(exports.internalConstantsForTesting[decompressUtilityName], ['-d'], {
+ stdio: ['pipe', 'pipe', 'inherit'],
+ })
+ .once('error', handleError(decompressUtilityName))
+ .once('exit', code => {
+ debugFileUtil(`${decompressUtilityName} exited, code=${code}`);
+ });
+ const tar = tarFs.extract(folderPath);
+ tar.once('error', handleError('tar'));
+ tar.once('finish', fulfill);
+ (0, node_fs_1.createReadStream)(tarPath).pipe(createTransformStream(unpack)).pipe(tar);
+ });
+}
+/**
+ * @internal
+ */
+async function installDMG(dmgPath, folderPath) {
+ const { stdout } = (0, node_child_process_1.spawnSync)(`hdiutil`, [
+ 'attach',
+ '-nobrowse',
+ '-noautoopen',
+ dmgPath,
+ ]);
+ const volumes = stdout.toString('utf8').match(/\/Volumes\/(.*)/m);
+ if (!volumes) {
+ throw new Error(`Could not find volume path in ${stdout}`);
+ }
+ const mountPath = volumes[0];
+ try {
+ const fileNames = await (0, promises_1.readdir)(mountPath);
+ const appName = fileNames.find(item => {
+ return typeof item === 'string' && item.endsWith('.app');
+ });
+ if (!appName) {
+ throw new Error(`Cannot find app in ${mountPath}`);
+ }
+ const mountedPath = path.join(mountPath, appName);
+ (0, node_child_process_1.spawnSync)('cp', ['-R', mountedPath, folderPath]);
+ }
+ finally {
+ (0, node_child_process_1.spawnSync)('hdiutil', ['detach', mountPath, '-quiet']);
+ }
+}
+//# sourceMappingURL=fileUtil.js.map
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/cjs/fileUtil.js.map b/node_modules/@puppeteer/browsers/lib/cjs/fileUtil.js.map
new file mode 100644
index 0000000..ac02a8d
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/cjs/fileUtil.js.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C;IACD,MAAM,SAAS,GAAG,OAAO,CAAC,CAAC,CAAE,CAAC;IAE9B,IAAI,CAAC;QACH,MAAM,SAAS,GAAG,MAAM,IAAA,kBAAO,EAAC,SAAS,CAAC,CAAC;QAC3C,MAAM,OAAO,GAAG,SAAS,CAAC,IAAI,CAAC,IAAI,CAAC,EAAE;YACpC,OAAO,OAAO,IAAI,KAAK,QAAQ,IAAI,IAAI,CAAC,QAAQ,CAAC,MAAM,CAAC,CAAC;QAC3D,CAAC,CAAC,CAAC;QACH,IAAI,CAAC,OAAO,EAAE,CAAC;YACb,MAAM,IAAI,KAAK,CAAC,sBAAsB,SAAS,EAAE,CAAC,CAAC;QACrD,CAAC;QACD,MAAM,WAAW,GAAG,IAAI,CAAC,IAAI,CAAC,SAAU,EAAE,OAAO,CAAC,CAAC;QAEnD,IAAA,8BAAS,EAAC,IAAI,EAAE,CAAC,IAAI,EAAE,WAAW,EAAE,UAAU,CAAC,CAAC,CAAC;IACnD,CAAC;YAAS,CAAC;QACT,IAAA,8BAAS,EAAC,SAAS,EAAE,CAAC,QAAQ,EAAE,SAAS,EAAE,QAAQ,CAAC,CAAC,CAAC;IACxD,CAAC;AACH,CAAC"}
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/cjs/generated/version.d.ts b/node_modules/@puppeteer/browsers/lib/cjs/generated/version.d.ts
new file mode 100644
index 0000000..73db3f4
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/cjs/generated/version.d.ts
@@ -0,0 +1,5 @@
+/**
+ * @internal
+ */
+export declare const packageVersion = "2.10.10";
+//# sourceMappingURL=version.d.ts.map
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/cjs/generated/version.d.ts.map b/node_modules/@puppeteer/browsers/lib/cjs/generated/version.d.ts.map
new file mode 100644
index 0000000..f1de697
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/cjs/generated/version.d.ts.map
@@ -0,0 +1 @@
+{"version":3,"file":"version.d.ts","sourceRoot":"","sources":["../../../src/generated/version.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH,eAAO,MAAM,cAAc,YAAY,CAAC"}
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/cjs/generated/version.js b/node_modules/@puppeteer/browsers/lib/cjs/generated/version.js
new file mode 100644
index 0000000..310e2d9
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/cjs/generated/version.js
@@ -0,0 +1,8 @@
+"use strict";
+Object.defineProperty(exports, "__esModule", { value: true });
+exports.packageVersion = void 0;
+/**
+ * @internal
+ */
+exports.packageVersion = '2.10.10';
+//# sourceMappingURL=version.js.map
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/cjs/generated/version.js.map b/node_modules/@puppeteer/browsers/lib/cjs/generated/version.js.map
new file mode 100644
index 0000000..a2e44c5
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/cjs/generated/version.js.map
@@ -0,0 +1 @@
+{"version":3,"file":"version.js","sourceRoot":"","sources":["../../../src/generated/version.ts"],"names":[],"mappings":";;;AAAA;;GAEG;AACU,QAAA,cAAc,GAAG,SAAS,CAAC"}
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/cjs/httpUtil.d.ts b/node_modules/@puppeteer/browsers/lib/cjs/httpUtil.d.ts
new file mode 100644
index 0000000..02c916a
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/cjs/httpUtil.d.ts
@@ -0,0 +1,16 @@
+/**
+ * @license
+ * Copyright 2023 Google Inc.
+ * SPDX-License-Identifier: Apache-2.0
+ */
+import * as http from 'node:http';
+import { URL } from 'node:url';
+export declare function headHttpRequest(url: URL): Promise;
+export declare function httpRequest(url: URL, method: string, response: (x: http.IncomingMessage) => void, keepAlive?: boolean): http.ClientRequest;
+/**
+ * @internal
+ */
+export declare function downloadFile(url: URL, destinationPath: string, progressCallback?: (downloadedBytes: number, totalBytes: number) => void): Promise;
+export declare function getJSON(url: URL): Promise;
+export declare function getText(url: URL): Promise;
+//# sourceMappingURL=httpUtil.d.ts.map
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/cjs/httpUtil.d.ts.map b/node_modules/@puppeteer/browsers/lib/cjs/httpUtil.d.ts.map
new file mode 100644
index 0000000..c8eda85
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/cjs/httpUtil.d.ts.map
@@ -0,0 +1 @@
+{"version":3,"file":"httpUtil.d.ts","sourceRoot":"","sources":["../../src/httpUtil.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAGH,OAAO,KAAK,IAAI,MAAM,WAAW,CAAC;AAElC,OAAO,EAAC,GAAG,EAAmB,MAAM,UAAU,CAAC;AAI/C,wBAAgB,eAAe,CAAC,GAAG,EAAE,GAAG,GAAG,OAAO,CAAC,OAAO,CAAC,CAgB1D;AAED,wBAAgB,WAAW,CACzB,GAAG,EAAE,GAAG,EACR,MAAM,EAAE,MAAM,EACd,QAAQ,EAAE,CAAC,CAAC,EAAE,IAAI,CAAC,eAAe,KAAK,IAAI,EAC3C,SAAS,UAAO,GACf,IAAI,CAAC,aAAa,CAiCpB;AAED;;GAEG;AACH,wBAAgB,YAAY,CAC1B,GAAG,EAAE,GAAG,EACR,eAAe,EAAE,MAAM,EACvB,gBAAgB,CAAC,EAAE,CAAC,eAAe,EAAE,MAAM,EAAE,UAAU,EAAE,MAAM,KAAK,IAAI,GACvE,OAAO,CAAC,IAAI,CAAC,CA6Cf;AAED,wBAAsB,OAAO,CAAC,GAAG,EAAE,GAAG,GAAG,OAAO,CAAC,OAAO,CAAC,CAOxD;AAED,wBAAgB,OAAO,CAAC,GAAG,EAAE,GAAG,GAAG,OAAO,CAAC,MAAM,CAAC,CA2BjD"}
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/cjs/httpUtil.js b/node_modules/@puppeteer/browsers/lib/cjs/httpUtil.js
new file mode 100644
index 0000000..2c64b7e
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/cjs/httpUtil.js
@@ -0,0 +1,172 @@
+"use strict";
+/**
+ * @license
+ * Copyright 2023 Google Inc.
+ * SPDX-License-Identifier: Apache-2.0
+ */
+var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
+ if (k2 === undefined) k2 = k;
+ var desc = Object.getOwnPropertyDescriptor(m, k);
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
+ desc = { enumerable: true, get: function() { return m[k]; } };
+ }
+ Object.defineProperty(o, k2, desc);
+}) : (function(o, m, k, k2) {
+ if (k2 === undefined) k2 = k;
+ o[k2] = m[k];
+}));
+var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
+ Object.defineProperty(o, "default", { enumerable: true, value: v });
+}) : function(o, v) {
+ o["default"] = v;
+});
+var __importStar = (this && this.__importStar) || (function () {
+ var ownKeys = function(o) {
+ ownKeys = Object.getOwnPropertyNames || function (o) {
+ var ar = [];
+ for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
+ return ar;
+ };
+ return ownKeys(o);
+ };
+ return function (mod) {
+ if (mod && mod.__esModule) return mod;
+ var result = {};
+ if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
+ __setModuleDefault(result, mod);
+ return result;
+ };
+})();
+Object.defineProperty(exports, "__esModule", { value: true });
+exports.headHttpRequest = headHttpRequest;
+exports.httpRequest = httpRequest;
+exports.downloadFile = downloadFile;
+exports.getJSON = getJSON;
+exports.getText = getText;
+const node_fs_1 = require("node:fs");
+const http = __importStar(require("node:http"));
+const https = __importStar(require("node:https"));
+const node_url_1 = require("node:url");
+const proxy_agent_1 = require("proxy-agent");
+function headHttpRequest(url) {
+ return new Promise(resolve => {
+ const request = httpRequest(url, 'HEAD', response => {
+ // consume response data free node process
+ response.resume();
+ resolve(response.statusCode === 200);
+ }, false);
+ request.on('error', () => {
+ resolve(false);
+ });
+ });
+}
+function httpRequest(url, method, response, keepAlive = true) {
+ const options = {
+ protocol: url.protocol,
+ hostname: url.hostname,
+ port: url.port,
+ path: url.pathname + url.search,
+ method,
+ headers: keepAlive ? { Connection: 'keep-alive' } : undefined,
+ auth: (0, node_url_1.urlToHttpOptions)(url).auth,
+ agent: new proxy_agent_1.ProxyAgent(),
+ };
+ const requestCallback = (res) => {
+ if (res.statusCode &&
+ res.statusCode >= 300 &&
+ res.statusCode < 400 &&
+ res.headers.location) {
+ httpRequest(new node_url_1.URL(res.headers.location), method, response);
+ // consume response data to free up memory
+ // And prevents the connection from being kept alive
+ res.resume();
+ }
+ else {
+ response(res);
+ }
+ };
+ const request = options.protocol === 'https:'
+ ? https.request(options, requestCallback)
+ : http.request(options, requestCallback);
+ request.end();
+ return request;
+}
+/**
+ * @internal
+ */
+function downloadFile(url, destinationPath, progressCallback) {
+ return new Promise((resolve, reject) => {
+ let downloadedBytes = 0;
+ let totalBytes = 0;
+ function onData(chunk) {
+ downloadedBytes += chunk.length;
+ progressCallback(downloadedBytes, totalBytes);
+ }
+ const request = httpRequest(url, 'GET', response => {
+ if (response.statusCode !== 200) {
+ const error = new Error(`Download failed: server returned code ${response.statusCode}. URL: ${url}`);
+ // consume response data to free up memory
+ response.resume();
+ reject(error);
+ return;
+ }
+ const file = (0, node_fs_1.createWriteStream)(destinationPath);
+ file.on('close', () => {
+ // The 'close' event is emitted when the stream and any of its
+ // underlying resources (a file descriptor, for example) have been
+ // closed. The event indicates that no more events will be emitted, and
+ // no further computation will occur.
+ return resolve();
+ });
+ file.on('error', error => {
+ // The 'error' event may be emitted by a Readable implementation at any
+ // time. Typically, this may occur if the underlying stream is unable to
+ // generate data due to an underlying internal failure, or when a stream
+ // implementation attempts to push an invalid chunk of data.
+ return reject(error);
+ });
+ response.pipe(file);
+ totalBytes = parseInt(response.headers['content-length'], 10);
+ if (progressCallback) {
+ response.on('data', onData);
+ }
+ });
+ request.on('error', error => {
+ return reject(error);
+ });
+ });
+}
+async function getJSON(url) {
+ const text = await getText(url);
+ try {
+ return JSON.parse(text);
+ }
+ catch {
+ throw new Error('Could not parse JSON from ' + url.toString());
+ }
+}
+function getText(url) {
+ return new Promise((resolve, reject) => {
+ const request = httpRequest(url, 'GET', response => {
+ let data = '';
+ if (response.statusCode && response.statusCode >= 400) {
+ return reject(new Error(`Got status code ${response.statusCode}`));
+ }
+ response.on('data', chunk => {
+ data += chunk;
+ });
+ response.on('end', () => {
+ try {
+ return resolve(String(data));
+ }
+ catch {
+ return reject(new Error('Chrome version not found'));
+ }
+ });
+ }, false);
+ request.on('error', err => {
+ reject(err);
+ });
+ });
+}
+//# sourceMappingURL=httpUtil.js.map
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/cjs/httpUtil.js.map b/node_modules/@puppeteer/browsers/lib/cjs/httpUtil.js.map
new file mode 100644
index 0000000..940530a
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/cjs/httpUtil.js.map
@@ -0,0 +1 @@
+{"version":3,"file":"httpUtil.js","sourceRoot":"","sources":["../../src/httpUtil.ts"],"names":[],"mappings":";AAAA;;;;GAIG;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AASH,0CAgBC;AAED,kCAsCC;AAKD,oCAiDC;AAED,0BAOC;AAED,0BA2BC;AA3JD,qCAA0C;AAC1C,gDAAkC;AAClC,kDAAoC;AACpC,uCAA+C;AAE/C,6CAAuC;AAEvC,SAAgB,eAAe,CAAC,GAAQ;IACtC,OAAO,IAAI,OAAO,CAAC,OAAO,CAAC,EAAE;QAC3B,MAAM,OAAO,GAAG,WAAW,CACzB,GAAG,EACH,MAAM,EACN,QAAQ,CAAC,EAAE;YACT,0CAA0C;YAC1C,QAAQ,CAAC,MAAM,EAAE,CAAC;YAClB,OAAO,CAAC,QAAQ,CAAC,UAAU,KAAK,GAAG,CAAC,CAAC;QACvC,CAAC,EACD,KAAK,CACN,CAAC;QACF,OAAO,CAAC,EAAE,CAAC,OAAO,EAAE,GAAG,EAAE;YACvB,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ACH,QAAQ,CAAC,EAAE,CAAC,KAAK,EAAE,GAAG,EAAE;gBACtB,IAAI,CAAC;oBACH,OAAO,OAAO,CAAC,MAAM,CAAC,IAAI,CAAC,CAAC,CAAC;gBAC/B,CAAC;gBAAC,MAAM,CAAC;oBACP,OAAO,MAAM,CAAC,IAAI,KAAK,CAAC,0BAA0B,CAAC,CAAC,CAAC;gBACvD,CAAC;YACH,CAAC,CAAC,CAAC;QACL,CAAC,EACD,KAAK,CACN,CAAC;QACF,OAAO,CAAC,EAAE,CAAC,OAAO,EAAE,GAAG,CAAC,EAAE;YACxB,MAAM,CAAC,GAAG,CAAC,CAAC;QACd,CAAC,CAAC,CAAC;IACL,CAAC,CAAC,CAAC;AACL,CAAC"}
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/cjs/install.d.ts b/node_modules/@puppeteer/browsers/lib/cjs/install.d.ts
new file mode 100644
index 0000000..8f7a0dc
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/cjs/install.d.ts
@@ -0,0 +1,157 @@
+/**
+ * @license
+ * Copyright 2017 Google Inc.
+ * SPDX-License-Identifier: Apache-2.0
+ */
+import { Browser, BrowserPlatform } from './browser-data/browser-data.js';
+import { InstalledBrowser } from './Cache.js';
+/**
+ * @public
+ */
+export interface InstallOptions {
+ /**
+ * Determines the path to download browsers to.
+ */
+ cacheDir: string;
+ /**
+ * Determines which platform the browser will be suited for.
+ *
+ * @defaultValue **Auto-detected.**
+ */
+ platform?: BrowserPlatform;
+ /**
+ * Determines which browser to install.
+ */
+ browser: Browser;
+ /**
+ * Determines which buildId to download. BuildId should uniquely identify
+ * binaries and they are used for caching.
+ */
+ buildId: string;
+ /**
+ * An alias for the provided `buildId`. It will be used to maintain local
+ * metadata to support aliases in the `launch` command.
+ *
+ * @example 'canary'
+ */
+ buildIdAlias?: string;
+ /**
+ * Provides information about the progress of the download. If set to
+ * 'default', the default callback implementing a progress bar will be
+ * used.
+ */
+ downloadProgressCallback?: 'default' | ((downloadedBytes: number, totalBytes: number) => void);
+ /**
+ * Determines the host that will be used for downloading.
+ *
+ * @defaultValue Either
+ *
+ * - https://storage.googleapis.com/chrome-for-testing-public or
+ * - https://archive.mozilla.org/pub/firefox/nightly/latest-mozilla-central
+ *
+ */
+ baseUrl?: string;
+ /**
+ * Whether to unpack and install browser archives.
+ *
+ * @defaultValue `true`
+ */
+ unpack?: boolean;
+ /**
+ * @internal
+ * @defaultValue `false`
+ */
+ forceFallbackForTesting?: boolean;
+ /**
+ * Whether to attempt to install system-level dependencies required
+ * for the browser.
+ *
+ * Only supported for Chrome on Debian or Ubuntu.
+ * Requires system-level privileges to run `apt-get`.
+ *
+ * @defaultValue `false`
+ */
+ installDeps?: boolean;
+}
+/**
+ * Downloads and unpacks the browser archive according to the
+ * {@link InstallOptions}.
+ *
+ * @returns a {@link InstalledBrowser} instance.
+ *
+ * @public
+ */
+export declare function install(options: InstallOptions & {
+ unpack?: true;
+}): Promise;
+/**
+ * Downloads the browser archive according to the {@link InstallOptions} without
+ * unpacking.
+ *
+ * @returns the absolute path to the archive.
+ *
+ * @public
+ */
+export declare function install(options: InstallOptions & {
+ unpack: false;
+}): Promise;
+/**
+ * @public
+ */
+export interface UninstallOptions {
+ /**
+ * Determines the platform for the browser binary.
+ *
+ * @defaultValue **Auto-detected.**
+ */
+ platform?: BrowserPlatform;
+ /**
+ * The path to the root of the cache directory.
+ */
+ cacheDir: string;
+ /**
+ * Determines which browser to uninstall.
+ */
+ browser: Browser;
+ /**
+ * The browser build to uninstall
+ */
+ buildId: string;
+}
+/**
+ *
+ * @public
+ */
+export declare function uninstall(options: UninstallOptions): Promise;
+/**
+ * @public
+ */
+export interface GetInstalledBrowsersOptions {
+ /**
+ * The path to the root of the cache directory.
+ */
+ cacheDir: string;
+}
+/**
+ * Returns metadata about browsers installed in the cache directory.
+ *
+ * @public
+ */
+export declare function getInstalledBrowsers(options: GetInstalledBrowsersOptions): Promise;
+/**
+ * @public
+ */
+export declare function canDownload(options: InstallOptions): Promise;
+/**
+ * Retrieves a URL for downloading the binary archive of a given browser.
+ *
+ * The archive is bound to the specific platform and build ID specified.
+ *
+ * @public
+ */
+export declare function getDownloadUrl(browser: Browser, platform: BrowserPlatform, buildId: string, baseUrl?: string): URL;
+/**
+ * @public
+ */
+export declare function makeProgressCallback(browser: Browser, buildId: string): (downloadedBytes: number, totalBytes: number) => void;
+//# sourceMappingURL=install.d.ts.map
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/cjs/install.d.ts.map b/node_modules/@puppeteer/browsers/lib/cjs/install.d.ts.map
new file mode 100644
index 0000000..c4184e8
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/cjs/install.d.ts.map
@@ -0,0 +1 @@
+{"version":3,"file":"install.d.ts","sourceRoot":"","sources":["../../src/install.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAYH,OAAO,EACL,OAAO,EACP,eAAe,EAEhB,MAAM,gCAAgC,CAAC;AACxC,OAAO,EAAQ,gBAAgB,EAAC,MAAM,YAAY,CAAC;AAwBnD;;GAEG;AACH,MAAM,WAAW,cAAc;IAC7B;;OAEG;IACH,QAAQ,EAAE,MAAM,CAAC;IACjB;;;;OAIG;IACH,QAAQ,CAAC,EAAE,eAAe,CAAC;IAC3B;;OAEG;IACH,OAAO,EAAE,OAAO,CAAC;IACjB;;;OAGG;IACH,OAAO,EAAE,MAAM,CAAC;IAChB;;;;;OAKG;IACH,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB;;;;OAIG;IACH,wBAAwB,CAAC,EACrB,SAAS,GACT,CAAC,CAAC,eAAe,EAAE,MAAM,EAAE,UAAU,EAAE,MAAM,KAAK,IAAI,CAAC,CAAC;IAC5D;;;;;;;;OAQG;IACH,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB;;;;OAIG;IACH,MAAM,CAAC,EAAE,OAAO,CAAC;IACjB;;;OAGG;IACH,uBAAuB,CAAC,EAAE,OAAO,CAAC;IAElC;;;;;;;;OAQG;IAC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,KAAK,IAAI,CAsBvD"}
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/cjs/install.js b/node_modules/@puppeteer/browsers/lib/cjs/install.js
new file mode 100644
index 0000000..35c7229
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/cjs/install.js
@@ -0,0 +1,294 @@
+"use strict";
+/**
+ * @license
+ * Copyright 2017 Google Inc.
+ * SPDX-License-Identifier: Apache-2.0
+ */
+var __importDefault = (this && this.__importDefault) || function (mod) {
+ return (mod && mod.__esModule) ? mod : { "default": mod };
+};
+Object.defineProperty(exports, "__esModule", { value: true });
+exports.install = install;
+exports.uninstall = uninstall;
+exports.getInstalledBrowsers = getInstalledBrowsers;
+exports.canDownload = canDownload;
+exports.getDownloadUrl = getDownloadUrl;
+exports.makeProgressCallback = makeProgressCallback;
+const node_assert_1 = __importDefault(require("node:assert"));
+const node_child_process_1 = require("node:child_process");
+const node_fs_1 = require("node:fs");
+const promises_1 = require("node:fs/promises");
+const node_os_1 = __importDefault(require("node:os"));
+const node_path_1 = __importDefault(require("node:path"));
+const progress_1 = __importDefault(require("progress"));
+const browser_data_js_1 = require("./browser-data/browser-data.js");
+const Cache_js_1 = require("./Cache.js");
+const debug_js_1 = require("./debug.js");
+const detectPlatform_js_1 = require("./detectPlatform.js");
+const fileUtil_js_1 = require("./fileUtil.js");
+const httpUtil_js_1 = require("./httpUtil.js");
+const debugInstall = (0, debug_js_1.debug)('puppeteer:browsers:install');
+const times = new Map();
+function debugTime(label) {
+ times.set(label, process.hrtime());
+}
+function debugTimeEnd(label) {
+ const end = process.hrtime();
+ const start = times.get(label);
+ if (!start) {
+ return;
+ }
+ const duration = end[0] * 1000 + end[1] / 1e6 - (start[0] * 1000 + start[1] / 1e6); // calculate duration in milliseconds
+ debugInstall(`Duration for ${label}: ${duration}ms`);
+}
+async function install(options) {
+ options.platform ??= (0, detectPlatform_js_1.detectBrowserPlatform)();
+ options.unpack ??= true;
+ if (!options.platform) {
+ throw new Error(`Cannot download a binary for the provided platform: ${node_os_1.default.platform()} (${node_os_1.default.arch()})`);
+ }
+ const url = getDownloadUrl(options.browser, options.platform, options.buildId, options.baseUrl);
+ try {
+ return await installUrl(url, options);
+ }
+ catch (err) {
+ // If custom baseUrl is provided, do not fall back to CfT dashboard.
+ if (options.baseUrl && !options.forceFallbackForTesting) {
+ throw err;
+ }
+ debugInstall(`Error downloading from ${url}.`);
+ switch (options.browser) {
+ case browser_data_js_1.Browser.CHROME:
+ case browser_data_js_1.Browser.CHROMEDRIVER:
+ case browser_data_js_1.Browser.CHROMEHEADLESSSHELL: {
+ debugInstall(`Trying to find download URL via https://googlechromelabs.github.io/chrome-for-testing.`);
+ const version = (await (0, httpUtil_js_1.getJSON)(new URL(`https://googlechromelabs.github.io/chrome-for-testing/${options.buildId}.json`)));
+ let platform = '';
+ switch (options.platform) {
+ case browser_data_js_1.BrowserPlatform.LINUX:
+ platform = 'linux64';
+ break;
+ case browser_data_js_1.BrowserPlatform.MAC_ARM:
+ platform = 'mac-arm64';
+ break;
+ case browser_data_js_1.BrowserPlatform.MAC:
+ platform = 'mac-x64';
+ break;
+ case browser_data_js_1.BrowserPlatform.WIN32:
+ platform = 'win32';
+ break;
+ case browser_data_js_1.BrowserPlatform.WIN64:
+ platform = 'win64';
+ break;
+ }
+ const backupUrl = version.downloads[options.browser]?.find(link => {
+ return link['platform'] === platform;
+ })?.url;
+ if (backupUrl) {
+ // If the URL is the same, skip the retry.
+ if (backupUrl === url.toString()) {
+ throw err;
+ }
+ debugInstall(`Falling back to downloading from ${backupUrl}.`);
+ return await installUrl(new URL(backupUrl), options);
+ }
+ throw err;
+ }
+ default:
+ throw err;
+ }
+ }
+}
+async function installDeps(installedBrowser) {
+ if (process.platform !== 'linux' ||
+ installedBrowser.platform !== browser_data_js_1.BrowserPlatform.LINUX) {
+ return;
+ }
+ // Currently, only Debian-like deps are supported.
+ const depsPath = node_path_1.default.join(node_path_1.default.dirname(installedBrowser.executablePath), 'deb.deps');
+ if (!(0, node_fs_1.existsSync)(depsPath)) {
+ debugInstall(`deb.deps file was not found at ${depsPath}`);
+ return;
+ }
+ const data = (0, node_fs_1.readFileSync)(depsPath, 'utf-8').split('\n').join(',');
+ if (process.getuid?.() !== 0) {
+ throw new Error('Installing system dependencies requires root privileges');
+ }
+ let result = (0, node_child_process_1.spawnSync)('apt-get', ['-v']);
+ if (result.status !== 0) {
+ throw new Error('Failed to install system dependencies: apt-get does not seem to be available');
+ }
+ debugInstall(`Trying to install dependencies: ${data}`);
+ result = (0, node_child_process_1.spawnSync)('apt-get', [
+ 'satisfy',
+ '-y',
+ data,
+ '--no-install-recommends',
+ ]);
+ if (result.status !== 0) {
+ throw new Error(`Failed to install system dependencies: status=${result.status},error=${result.error},stdout=${result.stdout.toString('utf8')},stderr=${result.stderr.toString('utf8')}`);
+ }
+ debugInstall(`Installed system dependencies ${data}`);
+}
+async function installUrl(url, options) {
+ options.platform ??= (0, detectPlatform_js_1.detectBrowserPlatform)();
+ if (!options.platform) {
+ throw new Error(`Cannot download a binary for the provided platform: ${node_os_1.default.platform()} (${node_os_1.default.arch()})`);
+ }
+ let downloadProgressCallback = options.downloadProgressCallback;
+ if (downloadProgressCallback === 'default') {
+ downloadProgressCallback = await makeProgressCallback(options.browser, options.buildIdAlias ?? options.buildId);
+ }
+ const fileName = decodeURIComponent(url.toString()).split('/').pop();
+ (0, node_assert_1.default)(fileName, `A malformed download URL was found: ${url}.`);
+ const cache = new Cache_js_1.Cache(options.cacheDir);
+ const browserRoot = cache.browserRoot(options.browser);
+ const archivePath = node_path_1.default.join(browserRoot, `${options.buildId}-${fileName}`);
+ if (!(0, node_fs_1.existsSync)(browserRoot)) {
+ await (0, promises_1.mkdir)(browserRoot, { recursive: true });
+ }
+ if (!options.unpack) {
+ if ((0, node_fs_1.existsSync)(archivePath)) {
+ return archivePath;
+ }
+ debugInstall(`Downloading binary from ${url}`);
+ debugTime('download');
+ await (0, httpUtil_js_1.downloadFile)(url, archivePath, downloadProgressCallback);
+ debugTimeEnd('download');
+ return archivePath;
+ }
+ const outputPath = cache.installationDir(options.browser, options.platform, options.buildId);
+ try {
+ if ((0, node_fs_1.existsSync)(outputPath)) {
+ const installedBrowser = new Cache_js_1.InstalledBrowser(cache, options.browser, options.buildId, options.platform);
+ if (!(0, node_fs_1.existsSync)(installedBrowser.executablePath)) {
+ throw new Error(`The browser folder (${outputPath}) exists but the executable (${installedBrowser.executablePath}) is missing`);
+ }
+ await runSetup(installedBrowser);
+ if (options.installDeps) {
+ await installDeps(installedBrowser);
+ }
+ return installedBrowser;
+ }
+ debugInstall(`Downloading binary from ${url}`);
+ try {
+ debugTime('download');
+ await (0, httpUtil_js_1.downloadFile)(url, archivePath, downloadProgressCallback);
+ }
+ finally {
+ debugTimeEnd('download');
+ }
+ debugInstall(`Installing ${archivePath} to ${outputPath}`);
+ try {
+ debugTime('extract');
+ await (0, fileUtil_js_1.unpackArchive)(archivePath, outputPath);
+ }
+ finally {
+ debugTimeEnd('extract');
+ }
+ const installedBrowser = new Cache_js_1.InstalledBrowser(cache, options.browser, options.buildId, options.platform);
+ if (options.buildIdAlias) {
+ const metadata = installedBrowser.readMetadata();
+ metadata.aliases[options.buildIdAlias] = options.buildId;
+ installedBrowser.writeMetadata(metadata);
+ }
+ await runSetup(installedBrowser);
+ if (options.installDeps) {
+ await installDeps(installedBrowser);
+ }
+ return installedBrowser;
+ }
+ finally {
+ if ((0, node_fs_1.existsSync)(archivePath)) {
+ await (0, promises_1.unlink)(archivePath);
+ }
+ }
+}
+async function runSetup(installedBrowser) {
+ // On Windows for Chrome invoke setup.exe to configure sandboxes.
+ if ((installedBrowser.platform === browser_data_js_1.BrowserPlatform.WIN32 ||
+ installedBrowser.platform === browser_data_js_1.BrowserPlatform.WIN64) &&
+ installedBrowser.browser === browser_data_js_1.Browser.CHROME &&
+ installedBrowser.platform === (0, detectPlatform_js_1.detectBrowserPlatform)()) {
+ try {
+ debugTime('permissions');
+ const browserDir = node_path_1.default.dirname(installedBrowser.executablePath);
+ const setupExePath = node_path_1.default.join(browserDir, 'setup.exe');
+ if (!(0, node_fs_1.existsSync)(setupExePath)) {
+ return;
+ }
+ (0, node_child_process_1.spawnSync)(node_path_1.default.join(browserDir, 'setup.exe'), [`--configure-browser-in-directory=` + browserDir], {
+ shell: true,
+ });
+ // TODO: Handle error here. Currently the setup.exe sometimes
+ // errors although it sets the permissions correctly.
+ }
+ finally {
+ debugTimeEnd('permissions');
+ }
+ }
+}
+/**
+ *
+ * @public
+ */
+async function uninstall(options) {
+ options.platform ??= (0, detectPlatform_js_1.detectBrowserPlatform)();
+ if (!options.platform) {
+ throw new Error(`Cannot detect the browser platform for: ${node_os_1.default.platform()} (${node_os_1.default.arch()})`);
+ }
+ new Cache_js_1.Cache(options.cacheDir).uninstall(options.browser, options.platform, options.buildId);
+}
+/**
+ * Returns metadata about browsers installed in the cache directory.
+ *
+ * @public
+ */
+async function getInstalledBrowsers(options) {
+ return new Cache_js_1.Cache(options.cacheDir).getInstalledBrowsers();
+}
+/**
+ * @public
+ */
+async function canDownload(options) {
+ options.platform ??= (0, detectPlatform_js_1.detectBrowserPlatform)();
+ if (!options.platform) {
+ throw new Error(`Cannot download a binary for the provided platform: ${node_os_1.default.platform()} (${node_os_1.default.arch()})`);
+ }
+ return await (0, httpUtil_js_1.headHttpRequest)(getDownloadUrl(options.browser, options.platform, options.buildId, options.baseUrl));
+}
+/**
+ * Retrieves a URL for downloading the binary archive of a given browser.
+ *
+ * The archive is bound to the specific platform and build ID specified.
+ *
+ * @public
+ */
+function getDownloadUrl(browser, platform, buildId, baseUrl) {
+ return new URL(browser_data_js_1.downloadUrls[browser](platform, buildId, baseUrl));
+}
+/**
+ * @public
+ */
+function makeProgressCallback(browser, buildId) {
+ let progressBar;
+ let lastDownloadedBytes = 0;
+ return (downloadedBytes, totalBytes) => {
+ if (!progressBar) {
+ progressBar = new progress_1.default(`Downloading ${browser} ${buildId} - ${toMegabytes(totalBytes)} [:bar] :percent :etas `, {
+ complete: '=',
+ incomplete: ' ',
+ width: 20,
+ total: totalBytes,
+ });
+ }
+ const delta = downloadedBytes - lastDownloadedBytes;
+ lastDownloadedBytes = downloadedBytes;
+ progressBar.tick(delta);
+ };
+}
+function toMegabytes(bytes) {
+ const mb = bytes / 1000 / 1000;
+ return `${Math.round(mb * 10) / 10} MB`;
+}
+//# sourceMappingURL=install.js.map
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/cjs/install.js.map b/node_modules/@puppeteer/browsers/lib/cjs/install.js.map
new file mode 100644
index 0000000..5a7482e
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/cjs/install.js.map
@@ -0,0 +1 @@
+{"version":3,"file":"install.js","sourceRoot":"","sources":["../../src/install.ts"],"names":[],"mappings":";AAAA;;;;GAIG;;;;;AAuIH,0BA0EC;AA2MD,8BAaC;AAiBD,oDAIC;AAKD,kCAeC;AASD,wCAOC;AAKD,oDAyBC;AA9fD,8DAAiC;AACjC,2DAA6C;AAC7C,qCAAiD;AACjD,+CAA+C;AAC/C,sDAAyB;AACzB,0DAA6B;AAG7B,wDAAwC;AAExC,oEAIwC;AACxC,yCAAmD;AACnD,yCAAiC;AACjC,2DAA0D;AAC1D,+CAA4C;AAC5C,+CAAqE;AAErE,MAAM,YAAY,GAAG,IAAA,gBAAK,EAAC,4BAA4B,CAAC,CAAC;AAEzD,MAAM,KAAK,GAAG,IAAI,GAAG,EAA4B,CAAC;AAClD,SAAS,SAAS,CAAC,KAAa;IAC9B,KAAK,CAAC,GAAG,CAAC,KAAK,EAAE,OAAO,CAAC,MAAM,EAAE,CAAC,CAAC;AACrC,CAAC;AAED,SAAS,YAAY,CAAC,KAAa;IACjC,MAAM,GAAG,GAAG,OAAO,CAAC,MAAM,EAAE,CAAC;IAC7B,MAAM,KAAK,GAAG,KAAK,CAAC,GAAG,CAAC,KAAK,CAAC,CAAC;IAC/B,IAAI,CAAC,KAAK,EAAE,CAAC;QACX,OAAO;IACT,CAAC;IACD,MAAM,QAAQ,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AAC;QACD,MAAM,KAAK,GAAG,eAAe,GAAG,mBAAmB,CAAC;QACpD,mBAAmB,GAAG,eAAe,CAAC;QACtC,WAAW,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC;IAC1B,CAAC,CAAC;AACJ,CAAC;AAED,SAAS,WAAW,CAAC,KAAa;IAChC,MAAM,EAAE,GAAG,KAAK,GAAG,IAAI,GAAG,IAAI,CAAC;IAC/B,OAAO,GAAG,IAAI,CAAC,KAAK,CAAC,EAAE,GAAG,EAAE,CAAC,GAAG,EAAE,KAAK,CAAC;AAC1C,CAAC"}
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/cjs/launch.d.ts b/node_modules/@puppeteer/browsers/lib/cjs/launch.d.ts
new file mode 100644
index 0000000..d1560b1
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/cjs/launch.d.ts
@@ -0,0 +1,186 @@
+/**
+ * @license
+ * Copyright 2023 Google Inc.
+ * SPDX-License-Identifier: Apache-2.0
+ */
+import childProcess from 'node:child_process';
+import { type Browser, type BrowserPlatform, type ChromeReleaseChannel } from './browser-data/browser-data.js';
+/**
+ * @public
+ */
+export interface ComputeExecutablePathOptions {
+ /**
+ * Root path to the storage directory.
+ *
+ * Can be set to `null` if the executable path should be relative
+ * to the extracted download location. E.g. `./chrome-linux64/chrome`.
+ */
+ cacheDir: string | null;
+ /**
+ * Determines which platform the browser will be suited for.
+ *
+ * @defaultValue **Auto-detected.**
+ */
+ platform?: BrowserPlatform;
+ /**
+ * Determines which browser to launch.
+ */
+ browser: Browser;
+ /**
+ * Determines which buildId to download. BuildId should uniquely identify
+ * binaries and they are used for caching.
+ */
+ buildId: string;
+}
+/**
+ * @public
+ */
+export declare function computeExecutablePath(options: ComputeExecutablePathOptions): string;
+/**
+ * @public
+ */
+export interface SystemOptions {
+ /**
+ * Determines which platform the browser will be suited for.
+ *
+ * @defaultValue **Auto-detected.**
+ */
+ platform?: BrowserPlatform;
+ /**
+ * Determines which browser to launch.
+ */
+ browser: Browser;
+ /**
+ * Release channel to look for on the system.
+ */
+ channel: ChromeReleaseChannel;
+}
+/**
+ * Returns a path to a system-wide Chrome installation given a release channel
+ * name by checking known installation locations (using
+ * {@link https://pptr.dev/browsers-api/browsers.computesystemexecutablepath}).
+ * If Chrome instance is not found at the expected path, an error is thrown.
+ *
+ * @public
+ */
+export declare function computeSystemExecutablePath(options: SystemOptions): string;
+/**
+ * @public
+ */
+export interface LaunchOptions {
+ /**
+ * Absolute path to the browser's executable.
+ */
+ executablePath: string;
+ /**
+ * Configures stdio streams to open two additional streams for automation over
+ * those streams instead of WebSocket.
+ *
+ * @defaultValue `false`.
+ */
+ pipe?: boolean;
+ /**
+ * If true, forwards the browser's process stdout and stderr to the Node's
+ * process stdout and stderr.
+ *
+ * @defaultValue `false`.
+ */
+ dumpio?: boolean;
+ /**
+ * Additional arguments to pass to the executable when launching.
+ */
+ args?: string[];
+ /**
+ * Environment variables to set for the browser process.
+ */
+ env?: Record;
+ /**
+ * Handles SIGINT in the Node process and tries to kill the browser process.
+ *
+ * @defaultValue `true`.
+ */
+ handleSIGINT?: boolean;
+ /**
+ * Handles SIGTERM in the Node process and tries to gracefully close the browser
+ * process.
+ *
+ * @defaultValue `true`.
+ */
+ handleSIGTERM?: boolean;
+ /**
+ * Handles SIGHUP in the Node process and tries to gracefully close the browser process.
+ *
+ * @defaultValue `true`.
+ */
+ handleSIGHUP?: boolean;
+ /**
+ * Whether to spawn process in the {@link https://nodejs.org/api/child_process.html#optionsdetached | detached}
+ * mode.
+ *
+ * @defaultValue `true` except on Windows.
+ */
+ detached?: boolean;
+ /**
+ * A callback to run after the browser process exits or before the process
+ * will be closed via the {@link Process.close} call (including when handling
+ * signals). The callback is only run once.
+ */
+ onExit?: () => Promise;
+}
+/**
+ * Launches a browser process according to {@link LaunchOptions}.
+ *
+ * @public
+ */
+export declare function launch(opts: LaunchOptions): Process;
+/**
+ * @public
+ */
+export declare const CDP_WEBSOCKET_ENDPOINT_REGEX: RegExp;
+/**
+ * @public
+ */
+export declare const WEBDRIVER_BIDI_WEBSOCKET_ENDPOINT_REGEX: RegExp;
+/**
+ * @public
+ */
+export declare class Process {
+ #private;
+ constructor(opts: LaunchOptions);
+ get nodeProcess(): childProcess.ChildProcess;
+ close(): Promise;
+ hasClosed(): Promise;
+ kill(): void;
+ /**
+ * Get recent logs (stderr + stdout) emitted by the browser.
+ *
+ * @public
+ */
+ getRecentLogs(): string[];
+ waitForLineOutput(regex: RegExp, timeout?: number): Promise;
+}
+/**
+ * @internal
+ */
+export interface ErrorLike extends Error {
+ name: string;
+ message: string;
+}
+/**
+ * @internal
+ */
+export declare function isErrorLike(obj: unknown): obj is ErrorLike;
+/**
+ * @internal
+ */
+export declare function isErrnoException(obj: unknown): obj is NodeJS.ErrnoException;
+/**
+ * @public
+ */
+export declare class TimeoutError extends Error {
+ /**
+ * @internal
+ */
+ constructor(message?: string);
+}
+//# sourceMappingURL=launch.d.ts.map
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/cjs/launch.d.ts.map b/node_modules/@puppeteer/browsers/lib/cjs/launch.d.ts.map
new file mode 100644
index 0000000..a1c3d2a
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/cjs/launch.d.ts.map
@@ -0,0 +1 @@
+{"version":3,"file":"launch.d.ts","sourceRoot":"","sources":["../../src/launch.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,OAAO,YAAY,MAAM,oBAAoB,CAAC;AAO9C,OAAO,EACL,KAAK,OAAO,EACZ,KAAK,eAAe,EAEpB,KAAK,oBAAoB,EAE1B,MAAM,gCAAgC,CAAC;AAOxC;;GAEG;AACH,MAAM,WAAW,4BAA4B;IAC3C;;;;;OAKG;IACH,QAAQ,EAAE,MAAM,GAAG,IAAI,CAAC;IACxB;;;;OAIG;IACH,QAAQ,CAAC,EAAE,eAAe,CAAC;IAC3B;;OAEG;IACH,OAAO,EAAE,OAAO,CAAC;IACjB;;;OAGG;IACH,OAAO,EAAE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IAAI,YAAY,CAAC,YAAY,CAE3C;IAiCK,KAAK,IAAI,OAAO,CAAC,IAAI,CAAC;IAQ5B,SAAS,IAAI,OAAO,CAAC,IAAI,CAAC;IAI1B,IAAI,IAAI,IAAI;IAmFZ;;;;OAIG;IACH,aAAa,IAAI,MAAM,EAAE;IAIzB,iBAAiB,CAAC,KAAK,EAAE,MAAM,EAAE,OAAO,SAAI,GAAG,OAAO,CAAC,MAAM,CAAC;CA4D/D;AAuBD;;GAEG;AACH,MAAM,WAAW,SAAU,SAAQ,KAAK;IACtC,IAAI,EAAE,MAAM,CAAC;IACb,OAAO,EAAE,MAAM,CAAC;CACjB;AAED;;GAEG;AACH,wBAAgB,WAAW,CAAC,GAAG,EAAE,OAAO,GAAG,GAAG,IAAI,SAAS,CAI1D;AACD;;GAEG;AACH,wBAAgB,gBAAgB,CAAC,GAAG,EAAE,OAAO,GAAG,GAAG,IAAI,MAAM,CAAC,cAAc,CAK3E;AAED;;GAEG;AACH,qBAAa,YAAa,SAAQ,KAAK;IACrC;;OAEG;gBACS,OAAO,CAAC,EAAE,MAAM;CAK7B"}
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/cjs/launch.js b/node_modules/@puppeteer/browsers/lib/cjs/launch.js
new file mode 100644
index 0000000..51f3857
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/cjs/launch.js
@@ -0,0 +1,426 @@
+"use strict";
+/**
+ * @license
+ * Copyright 2023 Google Inc.
+ * SPDX-License-Identifier: Apache-2.0
+ */
+var __importDefault = (this && this.__importDefault) || function (mod) {
+ return (mod && mod.__esModule) ? mod : { "default": mod };
+};
+Object.defineProperty(exports, "__esModule", { value: true });
+exports.TimeoutError = exports.Process = exports.WEBDRIVER_BIDI_WEBSOCKET_ENDPOINT_REGEX = exports.CDP_WEBSOCKET_ENDPOINT_REGEX = void 0;
+exports.computeExecutablePath = computeExecutablePath;
+exports.computeSystemExecutablePath = computeSystemExecutablePath;
+exports.launch = launch;
+exports.isErrorLike = isErrorLike;
+exports.isErrnoException = isErrnoException;
+const node_child_process_1 = __importDefault(require("node:child_process"));
+const node_events_1 = require("node:events");
+const node_fs_1 = require("node:fs");
+const node_os_1 = __importDefault(require("node:os"));
+const node_readline_1 = __importDefault(require("node:readline"));
+const browser_data_js_1 = require("./browser-data/browser-data.js");
+const Cache_js_1 = require("./Cache.js");
+const debug_js_1 = require("./debug.js");
+const detectPlatform_js_1 = require("./detectPlatform.js");
+const debugLaunch = (0, debug_js_1.debug)('puppeteer:browsers:launcher');
+/**
+ * @public
+ */
+function computeExecutablePath(options) {
+ if (options.cacheDir === null) {
+ options.platform ??= (0, detectPlatform_js_1.detectBrowserPlatform)();
+ if (options.platform === undefined) {
+ throw new Error(`No platform specified. Couldn't auto-detect browser platform.`);
+ }
+ return browser_data_js_1.executablePathByBrowser[options.browser](options.platform, options.buildId);
+ }
+ return new Cache_js_1.Cache(options.cacheDir).computeExecutablePath(options);
+}
+/**
+ * Returns a path to a system-wide Chrome installation given a release channel
+ * name by checking known installation locations (using
+ * {@link https://pptr.dev/browsers-api/browsers.computesystemexecutablepath}).
+ * If Chrome instance is not found at the expected path, an error is thrown.
+ *
+ * @public
+ */
+function computeSystemExecutablePath(options) {
+ options.platform ??= (0, detectPlatform_js_1.detectBrowserPlatform)();
+ if (!options.platform) {
+ throw new Error(`Cannot download a binary for the provided platform: ${node_os_1.default.platform()} (${node_os_1.default.arch()})`);
+ }
+ const path = (0, browser_data_js_1.resolveSystemExecutablePath)(options.browser, options.platform, options.channel);
+ try {
+ (0, node_fs_1.accessSync)(path);
+ }
+ catch {
+ throw new Error(`Could not find Google Chrome executable for channel '${options.channel}' at '${path}'.`);
+ }
+ return path;
+}
+/**
+ * Launches a browser process according to {@link LaunchOptions}.
+ *
+ * @public
+ */
+function launch(opts) {
+ return new Process(opts);
+}
+/**
+ * @public
+ */
+exports.CDP_WEBSOCKET_ENDPOINT_REGEX = /^DevTools listening on (ws:\/\/.*)$/;
+/**
+ * @public
+ */
+exports.WEBDRIVER_BIDI_WEBSOCKET_ENDPOINT_REGEX = /^WebDriver BiDi listening on (ws:\/\/.*)$/;
+const processListeners = new Map();
+const dispatchers = {
+ exit: (...args) => {
+ processListeners.get('exit')?.forEach(handler => {
+ return handler(...args);
+ });
+ },
+ SIGINT: (...args) => {
+ processListeners.get('SIGINT')?.forEach(handler => {
+ return handler(...args);
+ });
+ },
+ SIGHUP: (...args) => {
+ processListeners.get('SIGHUP')?.forEach(handler => {
+ return handler(...args);
+ });
+ },
+ SIGTERM: (...args) => {
+ processListeners.get('SIGTERM')?.forEach(handler => {
+ return handler(...args);
+ });
+ },
+};
+function subscribeToProcessEvent(event, handler) {
+ const listeners = processListeners.get(event) || [];
+ if (listeners.length === 0) {
+ process.on(event, dispatchers[event]);
+ }
+ listeners.push(handler);
+ processListeners.set(event, listeners);
+}
+function unsubscribeFromProcessEvent(event, handler) {
+ const listeners = processListeners.get(event) || [];
+ const existingListenerIdx = listeners.indexOf(handler);
+ if (existingListenerIdx === -1) {
+ return;
+ }
+ listeners.splice(existingListenerIdx, 1);
+ processListeners.set(event, listeners);
+ if (listeners.length === 0) {
+ process.off(event, dispatchers[event]);
+ }
+}
+/**
+ * @public
+ */
+class Process {
+ #executablePath;
+ #args;
+ #browserProcess;
+ #exited = false;
+ // The browser process can be closed externally or from the driver process. We
+ // need to invoke the hooks only once though but we don't know how many times
+ // we will be invoked.
+ #hooksRan = false;
+ #onExitHook = async () => { };
+ #browserProcessExiting;
+ #logs = [];
+ #maxLogLinesSize = 1000;
+ #lineEmitter = new node_events_1.EventEmitter();
+ constructor(opts) {
+ this.#executablePath = opts.executablePath;
+ this.#args = opts.args ?? [];
+ opts.pipe ??= false;
+ opts.dumpio ??= false;
+ opts.handleSIGINT ??= true;
+ opts.handleSIGTERM ??= true;
+ opts.handleSIGHUP ??= true;
+ // On non-windows platforms, `detached: true` makes child process a
+ // leader of a new process group, making it possible to kill child
+ // process tree with `.kill(-pid)` command. @see
+ // https://nodejs.org/api/child_process.html#child_process_options_detached
+ opts.detached ??= process.platform !== 'win32';
+ const stdio = this.#configureStdio({
+ pipe: opts.pipe,
+ });
+ const env = opts.env || {};
+ debugLaunch(`Launching ${this.#executablePath} ${this.#args.join(' ')}`, {
+ detached: opts.detached,
+ env: Object.keys(env).reduce((res, key) => {
+ if (key.toLowerCase().startsWith('puppeteer_')) {
+ res[key] = env[key];
+ }
+ return res;
+ }, {}),
+ stdio,
+ });
+ this.#browserProcess = node_child_process_1.default.spawn(this.#executablePath, this.#args, {
+ detached: opts.detached,
+ env,
+ stdio,
+ });
+ this.#recordStream(this.#browserProcess.stderr);
+ this.#recordStream(this.#browserProcess.stdout);
+ debugLaunch(`Launched ${this.#browserProcess.pid}`);
+ if (opts.dumpio) {
+ this.#browserProcess.stderr?.pipe(process.stderr);
+ this.#browserProcess.stdout?.pipe(process.stdout);
+ }
+ subscribeToProcessEvent('exit', this.#onDriverProcessExit);
+ if (opts.handleSIGINT) {
+ subscribeToProcessEvent('SIGINT', this.#onDriverProcessSignal);
+ }
+ if (opts.handleSIGTERM) {
+ subscribeToProcessEvent('SIGTERM', this.#onDriverProcessSignal);
+ }
+ if (opts.handleSIGHUP) {
+ subscribeToProcessEvent('SIGHUP', this.#onDriverProcessSignal);
+ }
+ if (opts.onExit) {
+ this.#onExitHook = opts.onExit;
+ }
+ this.#browserProcessExiting = new Promise((resolve, reject) => {
+ this.#browserProcess.once('exit', async () => {
+ debugLaunch(`Browser process ${this.#browserProcess.pid} onExit`);
+ this.#clearListeners();
+ this.#exited = true;
+ try {
+ await this.#runHooks();
+ }
+ catch (err) {
+ reject(err);
+ return;
+ }
+ resolve();
+ });
+ });
+ }
+ async #runHooks() {
+ if (this.#hooksRan) {
+ return;
+ }
+ this.#hooksRan = true;
+ await this.#onExitHook();
+ }
+ get nodeProcess() {
+ return this.#browserProcess;
+ }
+ #configureStdio(opts) {
+ if (opts.pipe) {
+ return ['pipe', 'pipe', 'pipe', 'pipe', 'pipe'];
+ }
+ else {
+ return ['pipe', 'pipe', 'pipe'];
+ }
+ }
+ #clearListeners() {
+ unsubscribeFromProcessEvent('exit', this.#onDriverProcessExit);
+ unsubscribeFromProcessEvent('SIGINT', this.#onDriverProcessSignal);
+ unsubscribeFromProcessEvent('SIGTERM', this.#onDriverProcessSignal);
+ unsubscribeFromProcessEvent('SIGHUP', this.#onDriverProcessSignal);
+ }
+ #onDriverProcessExit = (_code) => {
+ this.kill();
+ };
+ #onDriverProcessSignal = (signal) => {
+ switch (signal) {
+ case 'SIGINT':
+ this.kill();
+ process.exit(130);
+ case 'SIGTERM':
+ case 'SIGHUP':
+ void this.close();
+ break;
+ }
+ };
+ async close() {
+ await this.#runHooks();
+ if (!this.#exited) {
+ this.kill();
+ }
+ return await this.#browserProcessExiting;
+ }
+ hasClosed() {
+ return this.#browserProcessExiting;
+ }
+ kill() {
+ debugLaunch(`Trying to kill ${this.#browserProcess.pid}`);
+ // If the process failed to launch (for example if the browser executable path
+ // is invalid), then the process does not get a pid assigned. A call to
+ // `proc.kill` would error, as the `pid` to-be-killed can not be found.
+ if (this.#browserProcess &&
+ this.#browserProcess.pid &&
+ pidExists(this.#browserProcess.pid)) {
+ try {
+ debugLaunch(`Browser process ${this.#browserProcess.pid} exists`);
+ if (process.platform === 'win32') {
+ try {
+ node_child_process_1.default.execSync(`taskkill /pid ${this.#browserProcess.pid} /T /F`);
+ }
+ catch (error) {
+ debugLaunch(`Killing ${this.#browserProcess.pid} using taskkill failed`, error);
+ // taskkill can fail to kill the process e.g. due to missing permissions.
+ // Let's kill the process via Node API. This delays killing of all child
+ // processes of `this.proc` until the main Node.js process dies.
+ this.#browserProcess.kill();
+ }
+ }
+ else {
+ // on linux the process group can be killed with the group id prefixed with
+ // a minus sign. The process group id is the group leader's pid.
+ const processGroupId = -this.#browserProcess.pid;
+ try {
+ process.kill(processGroupId, 'SIGKILL');
+ }
+ catch (error) {
+ debugLaunch(`Killing ${this.#browserProcess.pid} using process.kill failed`, error);
+ // Killing the process group can fail due e.g. to missing permissions.
+ // Let's kill the process via Node API. This delays killing of all child
+ // processes of `this.proc` until the main Node.js process dies.
+ this.#browserProcess.kill('SIGKILL');
+ }
+ }
+ }
+ catch (error) {
+ throw new Error(`${PROCESS_ERROR_EXPLANATION}\nError cause: ${isErrorLike(error) ? error.stack : error}`);
+ }
+ }
+ this.#clearListeners();
+ }
+ #recordStream(stream) {
+ const rl = node_readline_1.default.createInterface(stream);
+ const cleanup = () => {
+ rl.off('line', onLine);
+ rl.off('close', onClose);
+ try {
+ rl.close();
+ }
+ catch { }
+ };
+ const onLine = (line) => {
+ if (line.trim() === '') {
+ return;
+ }
+ this.#logs.push(line);
+ const delta = this.#logs.length - this.#maxLogLinesSize;
+ if (delta) {
+ this.#logs.splice(0, delta);
+ }
+ this.#lineEmitter.emit('line', line);
+ };
+ const onClose = () => {
+ cleanup();
+ };
+ rl.on('line', onLine);
+ rl.on('close', onClose);
+ }
+ /**
+ * Get recent logs (stderr + stdout) emitted by the browser.
+ *
+ * @public
+ */
+ getRecentLogs() {
+ return [...this.#logs];
+ }
+ waitForLineOutput(regex, timeout = 0) {
+ return new Promise((resolve, reject) => {
+ const onClose = (errorOrCode) => {
+ cleanup();
+ reject(new Error([
+ `Failed to launch the browser process: ${errorOrCode instanceof Error
+ ? ` ${errorOrCode.message}`
+ : ` Code: ${errorOrCode}`}`,
+ '',
+ `stderr:`,
+ this.getRecentLogs().join('\n'),
+ '',
+ 'TROUBLESHOOTING: https://pptr.dev/troubleshooting',
+ '',
+ ].join('\n')));
+ };
+ this.#browserProcess.on('exit', onClose);
+ this.#browserProcess.on('error', onClose);
+ const timeoutId = timeout > 0 ? setTimeout(onTimeout, timeout) : undefined;
+ this.#lineEmitter.on('line', onLine);
+ const cleanup = () => {
+ clearTimeout(timeoutId);
+ this.#lineEmitter.off('line', onLine);
+ this.#browserProcess.off('exit', onClose);
+ this.#browserProcess.off('error', onClose);
+ };
+ function onTimeout() {
+ cleanup();
+ reject(new TimeoutError(`Timed out after ${timeout} ms while waiting for the WS endpoint URL to appear in stdout!`));
+ }
+ for (const line of this.#logs) {
+ onLine(line);
+ }
+ function onLine(line) {
+ const match = line.match(regex);
+ if (!match) {
+ return;
+ }
+ cleanup();
+ // The RegExp matches, so this will obviously exist.
+ resolve(match[1]);
+ }
+ });
+ }
+}
+exports.Process = Process;
+const PROCESS_ERROR_EXPLANATION = `Puppeteer was unable to kill the process which ran the browser binary.
+This means that, on future Puppeteer launches, Puppeteer might not be able to launch the browser.
+Please check your open processes and ensure that the browser processes that Puppeteer launched have been killed.
+If you think this is a bug, please report it on the Puppeteer issue tracker.`;
+/**
+ * @internal
+ */
+function pidExists(pid) {
+ try {
+ return process.kill(pid, 0);
+ }
+ catch (error) {
+ if (isErrnoException(error)) {
+ if (error.code && error.code === 'ESRCH') {
+ return false;
+ }
+ }
+ throw error;
+ }
+}
+/**
+ * @internal
+ */
+function isErrorLike(obj) {
+ return (typeof obj === 'object' && obj !== null && 'name' in obj && 'message' in obj);
+}
+/**
+ * @internal
+ */
+function isErrnoException(obj) {
+ return (isErrorLike(obj) &&
+ ('errno' in obj || 'code' in obj || 'path' in obj || 'syscall' in obj));
+}
+/**
+ * @public
+ */
+class TimeoutError extends Error {
+ /**
+ * @internal
+ */
+ constructor(message) {
+ super(message);
+ this.name = this.constructor.name;
+ Error.captureStackTrace(this, this.constructor);
+ }
+}
+exports.TimeoutError = TimeoutError;
+//# sourceMappingURL=launch.js.map
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/cjs/launch.js.map b/node_modules/@puppeteer/browsers/lib/cjs/launch.js.map
new file mode 100644
index 0000000..531f85e
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/cjs/launch.js.map
@@ -0,0 +1 @@
+{"version":3,"file":"launch.js","sourceRoot":"","sources":["../../src/launch.ts"],"names":[],"mappings":";AAAA;;;;GAIG;;;;;;AAqDH,sDAiBC;AA8BD,kEAoBC;AAuED,wBAEC;AAsZD,kCAIC;AAID,4CA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C;QAClC,KAAK,CAAC,iBAAiB,CAAC,IAAI,EAAE,IAAI,CAAC,WAAW,CAAC,CAAC;IAClD,CAAC;CACF;AATD,oCASC"}
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/cjs/main-cli.d.ts b/node_modules/@puppeteer/browsers/lib/cjs/main-cli.d.ts
new file mode 100644
index 0000000..24f6aa5
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/cjs/main-cli.d.ts
@@ -0,0 +1,8 @@
+#!/usr/bin/env node
+/**
+ * @license
+ * Copyright 2023 Google Inc.
+ * SPDX-License-Identifier: Apache-2.0
+ */
+export {};
+//# sourceMappingURL=main-cli.d.ts.map
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/cjs/main-cli.d.ts.map b/node_modules/@puppeteer/browsers/lib/cjs/main-cli.d.ts.map
new file mode 100644
index 0000000..97cfca7
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/cjs/main-cli.d.ts.map
@@ -0,0 +1 @@
+{"version":3,"file":"main-cli.d.ts","sourceRoot":"","sources":["../../src/main-cli.ts"],"names":[],"mappings":";AAEA;;;;GAIG"}
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/cjs/main-cli.js b/node_modules/@puppeteer/browsers/lib/cjs/main-cli.js
new file mode 100755
index 0000000..0671147
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/cjs/main-cli.js
@@ -0,0 +1,11 @@
+#!/usr/bin/env node
+"use strict";
+/**
+ * @license
+ * Copyright 2023 Google Inc.
+ * SPDX-License-Identifier: Apache-2.0
+ */
+Object.defineProperty(exports, "__esModule", { value: true });
+const CLI_js_1 = require("./CLI.js");
+void new CLI_js_1.CLI().run(process.argv);
+//# sourceMappingURL=main-cli.js.map
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/cjs/main-cli.js.map b/node_modules/@puppeteer/browsers/lib/cjs/main-cli.js.map
new file mode 100644
index 0000000..e8ef40f
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/cjs/main-cli.js.map
@@ -0,0 +1 @@
+{"version":3,"file":"main-cli.js","sourceRoot":"","sources":["../../src/main-cli.ts"],"names":[],"mappings":";;AAEA;;;;GAIG;;AAEH,qCAA6B;AAE7B,KAAK,IAAI,YAAG,EAAE,CAAC,GAAG,CAAC,OAAO,CAAC,IAAI,CAAC,CAAC"}
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/cjs/main.d.ts b/node_modules/@puppeteer/browsers/lib/cjs/main.d.ts
new file mode 100644
index 0000000..89874fd
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/cjs/main.d.ts
@@ -0,0 +1,16 @@
+/**
+ * @license
+ * Copyright 2023 Google Inc.
+ * SPDX-License-Identifier: Apache-2.0
+ */
+export type { LaunchOptions, ComputeExecutablePathOptions as Options, SystemOptions, } from './launch.js';
+export { launch, computeExecutablePath, computeSystemExecutablePath, TimeoutError, CDP_WEBSOCKET_ENDPOINT_REGEX, WEBDRIVER_BIDI_WEBSOCKET_ENDPOINT_REGEX, Process, } from './launch.js';
+export type { InstallOptions, GetInstalledBrowsersOptions, UninstallOptions, } from './install.js';
+export { install, makeProgressCallback, getInstalledBrowsers, canDownload, uninstall, getDownloadUrl, } from './install.js';
+export { detectBrowserPlatform } from './detectPlatform.js';
+export type { ProfileOptions } from './browser-data/browser-data.js';
+export { resolveBuildId, Browser, BrowserPlatform, ChromeReleaseChannel, createProfile, getVersionComparator, } from './browser-data/browser-data.js';
+export { CLI } from './CLI.js';
+export { Cache, InstalledBrowser, type Metadata, type ComputeExecutablePathOptions, } from './Cache.js';
+export { BrowserTag } from './browser-data/types.js';
+//# sourceMappingURL=main.d.ts.map
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/cjs/main.d.ts.map b/node_modules/@puppeteer/browsers/lib/cjs/main.d.ts.map
new file mode 100644
index 0000000..8346bb9
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/cjs/main.d.ts.map
@@ -0,0 +1 @@
+{"version":3,"file":"main.d.ts","sourceRoot":"","sources":["../../src/main.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,YAAY,EACV,aAAa,EACb,4BAA4B,IAAI,OAAO,EACvC,aAAa,GACd,MAAM,aAAa,CAAC;AACrB,OAAO,EACL,MAAM,EACN,qBAAqB,EACrB,2BAA2B,EAC3B,YAAY,EACZ,4BAA4B,EAC5B,uCAAuC,EACvC,OAAO,GACR,MAAM,aAAa,CAAC;AACrB,YAAY,EACV,cAAc,EACd,2BAA2B,EAC3B,gBAAgB,GACjB,MAAM,cAAc,CAAC;AACtB,OAAO,EACL,OAAO,EACP,oBAAoB,EACpB,oBAAoB,EACpB,WAAW,EACX,SAAS,EACT,cAAc,GACf,MAAM,cAAc,CAAC;AACtB,OAAO,EAAC,qBAAqB,EAAC,MAAM,qBAAqB,CAAC;AAC1D,YAAY,EAAC,cAAc,EAAC,MAAM,gCAAgC,CAAC;AACnE,OAAO,EACL,cAAc,EACd,OAAO,EACP,eAAe,EACf,oBAAoB,EACpB,aAAa,EACb,oBAAoB,GACrB,MAAM,gCAAgC,CAAC;AACxC,OAAO,EAAC,GAAG,EAAC,MAAM,UAAU,CAAC;AAC7B,OAAO,EACL,KAAK,EACL,gBAAgB,EAChB,KAAK,QAAQ,EACb,KAAK,4BAA4B,GAClC,MAAM,YAAY,CAAC;AACpB,OAAO,EAAC,UAAU,EAAC,MAAM,yBAAyB,CAAC"}
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/cjs/main.js b/node_modules/@puppeteer/browsers/lib/cjs/main.js
new file mode 100644
index 0000000..d3e029e
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/cjs/main.js
@@ -0,0 +1,40 @@
+"use strict";
+/**
+ * @license
+ * Copyright 2023 Google Inc.
+ * SPDX-License-Identifier: Apache-2.0
+ */
+Object.defineProperty(exports, "__esModule", { value: true });
+exports.BrowserTag = exports.InstalledBrowser = exports.Cache = exports.CLI = exports.getVersionComparator = exports.createProfile = exports.ChromeReleaseChannel = exports.BrowserPlatform = exports.Browser = exports.resolveBuildId = exports.detectBrowserPlatform = exports.getDownloadUrl = exports.uninstall = exports.canDownload = exports.getInstalledBrowsers = exports.makeProgressCallback = exports.install = exports.Process = exports.WEBDRIVER_BIDI_WEBSOCKET_ENDPOINT_REGEX = exports.CDP_WEBSOCKET_ENDPOINT_REGEX = exports.TimeoutError = exports.computeSystemExecutablePath = exports.computeExecutablePath = exports.launch = void 0;
+var launch_js_1 = require("./launch.js");
+Object.defineProperty(exports, "launch", { enumerable: true, get: function () { return launch_js_1.launch; } });
+Object.defineProperty(exports, "computeExecutablePath", { enumerable: true, get: function () { return launch_js_1.computeExecutablePath; } });
+Object.defineProperty(exports, "computeSystemExecutablePath", { enumerable: true, get: function () { return launch_js_1.computeSystemExecutablePath; } });
+Object.defineProperty(exports, "TimeoutError", { enumerable: true, get: function () { return launch_js_1.TimeoutError; } });
+Object.defineProperty(exports, "CDP_WEBSOCKET_ENDPOINT_REGEX", { enumerable: true, get: function () { return launch_js_1.CDP_WEBSOCKET_ENDPOINT_REGEX; } });
+Object.defineProperty(exports, "WEBDRIVER_BIDI_WEBSOCKET_ENDPOINT_REGEX", { enumerable: true, get: function () { return launch_js_1.WEBDRIVER_BIDI_WEBSOCKET_ENDPOINT_REGEX; } });
+Object.defineProperty(exports, "Process", { enumerable: true, get: function () { return launch_js_1.Process; } });
+var install_js_1 = require("./install.js");
+Object.defineProperty(exports, "install", { enumerable: true, get: function () { return install_js_1.install; } });
+Object.defineProperty(exports, "makeProgressCallback", { enumerable: true, get: function () { return install_js_1.makeProgressCallback; } });
+Object.defineProperty(exports, "getInstalledBrowsers", { enumerable: true, get: function () { return install_js_1.getInstalledBrowsers; } });
+Object.defineProperty(exports, "canDownload", { enumerable: true, get: function () { return install_js_1.canDownload; } });
+Object.defineProperty(exports, "uninstall", { enumerable: true, get: function () { return install_js_1.uninstall; } });
+Object.defineProperty(exports, "getDownloadUrl", { enumerable: true, get: function () { return install_js_1.getDownloadUrl; } });
+var detectPlatform_js_1 = require("./detectPlatform.js");
+Object.defineProperty(exports, "detectBrowserPlatform", { enumerable: true, get: function () { return detectPlatform_js_1.detectBrowserPlatform; } });
+var browser_data_js_1 = require("./browser-data/browser-data.js");
+Object.defineProperty(exports, "resolveBuildId", { enumerable: true, get: function () { return browser_data_js_1.resolveBuildId; } });
+Object.defineProperty(exports, "Browser", { enumerable: true, get: function () { return browser_data_js_1.Browser; } });
+Object.defineProperty(exports, "BrowserPlatform", { enumerable: true, get: function () { return browser_data_js_1.BrowserPlatform; } });
+Object.defineProperty(exports, "ChromeReleaseChannel", { enumerable: true, get: function () { return browser_data_js_1.ChromeReleaseChannel; } });
+Object.defineProperty(exports, "createProfile", { enumerable: true, get: function () { return browser_data_js_1.createProfile; } });
+Object.defineProperty(exports, "getVersionComparator", { enumerable: true, get: function () { return browser_data_js_1.getVersionComparator; } });
+var CLI_js_1 = require("./CLI.js");
+Object.defineProperty(exports, "CLI", { enumerable: true, get: function () { return CLI_js_1.CLI; } });
+var Cache_js_1 = require("./Cache.js");
+Object.defineProperty(exports, "Cache", { enumerable: true, get: function () { return Cache_js_1.Cache; } });
+Object.defineProperty(exports, "InstalledBrowser", { enumerable: true, get: function () { return Cache_js_1.InstalledBrowser; } });
+var types_js_1 = require("./browser-data/types.js");
+Object.defineProperty(exports, "BrowserTag", { enumerable: true, get: function () { return types_js_1.BrowserTag; } });
+//# sourceMappingURL=main.js.map
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/cjs/main.js.map b/node_modules/@puppeteer/browsers/lib/cjs/main.js.map
new file mode 100644
index 0000000..7754cb9
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/cjs/main.js.map
@@ -0,0 +1 @@
+{"version":3,"file":"main.js","sourceRoot":"","sources":["../../src/main.ts"],"names":[],"mappings":";AAAA;;;;GAIG;;;AAOH,yCAQqB;AAPnB,mGAAA,MAAM,OAAA;AACN,kHAAA,qBAAqB,OAAA;AACrB,wHAAA,2BAA2B,OAAA;AAC3B,yGAAA,YAAY,OAAA;AACZ,yHAAA,4BAA4B,OAAA;AAC5B,oIAAA,uCAAuC,OAAA;AACvC,oGAAA,OAAO,OAAA;AAOT,2CAOsB;AANpB,qGAAA,OAAO,OAAA;AACP,kHAAA,oBAAoB,OAAA;AACpB,kHAAA,oBAAoB,OAAA;AACpB,yGAAA,WAAW,OAAA;AACX,uGAAA,SAAS,OAAA;AACT,4GAAA,cAAc,OAAA;AAEhB,yDAA0D;AAAlD,0HAAA,qBAAqB,OAAA;AAE7B,kEAOwC;AANtC,iHAAA,cAAc,OAAA;AACd,0GAAA,OAAO,OAAA;AACP,kHAAA,eAAe,OAAA;AACf,uHAAA,oBAAoB,OAAA;AACpB,gHAAA,aAAa,OAAA;AACb,uHAAA,oBAAoB,OAAA;AAEtB,mCAA6B;AAArB,6FAAA,GAAG,OAAA;AACX,uCAKoB;AAJlB,iGAAA,KAAK,OAAA;AACL,4GAAA,gBAAgB,OAAA;AAIlB,oDAAmD;AAA3C,sGAAA,UAAU,OAAA"}
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/esm/CLI.d.ts b/node_modules/@puppeteer/browsers/lib/esm/CLI.d.ts
new file mode 100644
index 0000000..4923b42
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/esm/CLI.d.ts
@@ -0,0 +1,29 @@
+/**
+ * @license
+ * Copyright 2023 Google Inc.
+ * SPDX-License-Identifier: Apache-2.0
+ */
+import * as readline from 'node:readline';
+import { Browser } from './browser-data/browser-data.js';
+/**
+ * @public
+ */
+export declare class CLI {
+ #private;
+ constructor(opts?: string | {
+ cachePath?: string;
+ scriptName?: string;
+ version?: string;
+ prefixCommand?: {
+ cmd: string;
+ description: string;
+ };
+ allowCachePathOverride?: boolean;
+ pinnedBrowsers?: Partial>;
+ }, rl?: readline.Interface);
+ run(argv: string[]): Promise;
+}
+//# sourceMappingURL=CLI.d.ts.map
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/esm/CLI.d.ts.map b/node_modules/@puppeteer/browsers/lib/esm/CLI.d.ts.map
new file mode 100644
index 0000000..efbf34c
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/esm/CLI.d.ts.map
@@ -0,0 +1 @@
+{"version":3,"file":"CLI.d.ts","sourceRoot":"","sources":["../../src/CLI.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAGH,OAAO,KAAK,QAAQ,MAAM,eAAe,CAAC;AAI1C,OAAO,EACL,OAAO,EAIR,MAAM,gCAAgC,CAAC;AA+BxC;;GAEG;AACH,qBAAa,GAAG;;gBAkBZ,IAAI,CAAC,EACD,MAAM,GACN;QACE,SAAS,CAAC,EAAE,MAAM,CAAC;QACnB,UAAU,CAAC,EAAE,MAAM,CAAC;QACpB,OAAO,CAAC,EAAE,MAAM,CAAC;QACjB,aAAa,CAAC,EAAE;YAAC,GAAG,EAAE,MAAM,CAAC;YAAC,WAAW,EAAE,MAAM,CAAA;SAAC,CAAC;QACnD,sBAAsB,CAAC,EAAE,OAAO,CAAC;QACjC,cAAc,CAAC,EAAE,OAAO,CACtB,MAAM,CACJ,OAAO,EACP;YACE,OAAO,EAAE,MAAM,CAAC;YAChB,YAAY,EAAE,OAAO,CAAC;SACvB,CACF,CACF,CAAC;KACH,EACL,EAAE,CAAC,EAAE,QAAQ,CAAC,SAAS;IA+EnB,GAAG,CAAC,IAAI,EAAE,MAAM,EAAE,GAAG,OAAO,CAAC,IAAI,CAAC;CAoYzC"}
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/esm/CLI.js b/node_modules/@puppeteer/browsers/lib/esm/CLI.js
new file mode 100644
index 0000000..321947a
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/esm/CLI.js
@@ -0,0 +1,325 @@
+/**
+ * @license
+ * Copyright 2023 Google Inc.
+ * SPDX-License-Identifier: Apache-2.0
+ */
+import { stdin as input, stdout as output } from 'node:process';
+import * as readline from 'node:readline';
+import { Browser, resolveBuildId, BrowserPlatform, } from './browser-data/browser-data.js';
+import { Cache } from './Cache.js';
+import { detectBrowserPlatform } from './detectPlatform.js';
+import { packageVersion } from './generated/version.js';
+import { install } from './install.js';
+import { computeExecutablePath, computeSystemExecutablePath, launch, } from './launch.js';
+function isValidBrowser(browser) {
+ return Object.values(Browser).includes(browser);
+}
+function isValidPlatform(platform) {
+ return Object.values(BrowserPlatform).includes(platform);
+}
+/**
+ * @public
+ */
+export class CLI {
+ #cachePath;
+ #rl;
+ #scriptName;
+ #version;
+ #allowCachePathOverride;
+ #pinnedBrowsers;
+ #prefixCommand;
+ constructor(opts, rl) {
+ if (!opts) {
+ opts = {};
+ }
+ if (typeof opts === 'string') {
+ opts = {
+ cachePath: opts,
+ };
+ }
+ this.#cachePath = opts.cachePath ?? process.cwd();
+ this.#rl = rl;
+ this.#scriptName = opts.scriptName ?? '@puppeteer/browsers';
+ this.#version = opts.version ?? packageVersion;
+ this.#allowCachePathOverride = opts.allowCachePathOverride ?? true;
+ this.#pinnedBrowsers = opts.pinnedBrowsers;
+ this.#prefixCommand = opts.prefixCommand;
+ }
+ #defineBrowserParameter(yargs, required) {
+ return yargs.positional('browser', {
+ description: 'Which browser to install [@]. `latest` will try to find the latest available build. `buildId` is a browser-specific identifier such as a version or a revision.',
+ type: 'string',
+ coerce: (opt) => {
+ const browser = {
+ name: this.#parseBrowser(opt),
+ buildId: this.#parseBuildId(opt),
+ };
+ if (!isValidBrowser(browser.name)) {
+ throw new Error(`Unsupported browser '${browser.name}'`);
+ }
+ return browser;
+ },
+ demandOption: required,
+ });
+ }
+ #definePlatformParameter(yargs) {
+ return yargs.option('platform', {
+ type: 'string',
+ desc: 'Platform that the binary needs to be compatible with.',
+ choices: Object.values(BrowserPlatform),
+ default: detectBrowserPlatform(),
+ coerce: platform => {
+ if (!isValidPlatform(platform)) {
+ throw new Error(`Unsupported platform '${platform}'`);
+ }
+ return platform;
+ },
+ defaultDescription: 'Auto-detected',
+ });
+ }
+ #definePathParameter(yargs, required = false) {
+ if (!this.#allowCachePathOverride) {
+ return yargs;
+ }
+ return yargs.option('path', {
+ type: 'string',
+ desc: 'Path to the root folder for the browser downloads and installation. If a relative path is provided, it will be resolved relative to the current working directory. The installation folder structure is compatible with the cache structure used by Puppeteer.',
+ defaultDescription: 'Current working directory',
+ ...(required ? {} : { default: process.cwd() }),
+ demandOption: required,
+ });
+ }
+ async run(argv) {
+ const { default: yargs } = await import('yargs');
+ const { hideBin } = await import('yargs/helpers');
+ const yargsInstance = yargs(hideBin(argv));
+ let target = yargsInstance
+ .scriptName(this.#scriptName)
+ .version(this.#version);
+ if (this.#prefixCommand) {
+ target = target.command(this.#prefixCommand.cmd, this.#prefixCommand.description, yargs => {
+ return this.#build(yargs);
+ });
+ }
+ else {
+ target = this.#build(target);
+ }
+ await target
+ .demandCommand(1)
+ .help()
+ .wrap(Math.min(120, yargsInstance.terminalWidth()))
+ .parseAsync();
+ }
+ #build(yargs) {
+ const latestOrPinned = this.#pinnedBrowsers ? 'pinned' : 'latest';
+ // If there are pinned browsers allow the positional arg to be optional
+ const browserArgType = this.#pinnedBrowsers ? '[browser]' : '';
+ return yargs
+ .command(`install ${browserArgType}`, 'Download and install the specified browser. If successful, the command outputs the actual browser buildId that was installed and the absolute path to the browser executable (format: @).', yargs => {
+ if (this.#pinnedBrowsers) {
+ yargs.example('$0 install', 'Install all pinned browsers');
+ }
+ yargs
+ .example('$0 install chrome', `Install the ${latestOrPinned} available build of the Chrome browser.`)
+ .example('$0 install chrome@latest', 'Install the latest available build for the Chrome browser.')
+ .example('$0 install chrome@stable', 'Install the latest available build for the Chrome browser from the stable channel.')
+ .example('$0 install chrome@beta', 'Install the latest available build for the Chrome browser from the beta channel.')
+ .example('$0 install chrome@dev', 'Install the latest available build for the Chrome browser from the dev channel.')
+ .example('$0 install chrome@canary', 'Install the latest available build for the Chrome Canary browser.')
+ .example('$0 install chrome@115', 'Install the latest available build for Chrome 115.')
+ .example('$0 install chromedriver@canary', 'Install the latest available build for ChromeDriver Canary.')
+ .example('$0 install chromedriver@115', 'Install the latest available build for ChromeDriver 115.')
+ .example('$0 install chromedriver@115.0.5790', 'Install the latest available patch (115.0.5790.X) build for ChromeDriver.')
+ .example('$0 install chrome-headless-shell', 'Install the latest available chrome-headless-shell build.')
+ .example('$0 install chrome-headless-shell@beta', 'Install the latest available chrome-headless-shell build corresponding to the Beta channel.')
+ .example('$0 install chrome-headless-shell@118', 'Install the latest available chrome-headless-shell 118 build.')
+ .example('$0 install chromium@1083080', 'Install the revision 1083080 of the Chromium browser.')
+ .example('$0 install firefox', 'Install the latest nightly available build of the Firefox browser.')
+ .example('$0 install firefox@stable', 'Install the latest stable build of the Firefox browser.')
+ .example('$0 install firefox@beta', 'Install the latest beta build of the Firefox browser.')
+ .example('$0 install firefox@devedition', 'Install the latest devedition build of the Firefox browser.')
+ .example('$0 install firefox@esr', 'Install the latest ESR build of the Firefox browser.')
+ .example('$0 install firefox@nightly', 'Install the latest nightly build of the Firefox browser.')
+ .example('$0 install firefox@stable_111.0.1', 'Install a specific version of the Firefox browser.')
+ .example('$0 install firefox --platform mac', 'Install the latest Mac (Intel) build of the Firefox browser.');
+ if (this.#allowCachePathOverride) {
+ yargs.example('$0 install firefox --path /tmp/my-browser-cache', 'Install to the specified cache directory.');
+ }
+ const yargsWithBrowserParam = this.#defineBrowserParameter(yargs, !Boolean(this.#pinnedBrowsers));
+ const yargsWithPlatformParam = this.#definePlatformParameter(yargsWithBrowserParam);
+ return this.#definePathParameter(yargsWithPlatformParam, false)
+ .option('base-url', {
+ type: 'string',
+ desc: 'Base URL to download from',
+ })
+ .option('install-deps', {
+ type: 'boolean',
+ desc: 'Whether to attempt installing system dependencies (only supported on Linux, requires root privileges).',
+ default: false,
+ });
+ }, async (args) => {
+ if (this.#pinnedBrowsers && !args.browser) {
+ // Use allSettled to avoid scenarios that
+ // a browser may fail early and leave the other
+ // installation in a faulty state
+ const result = await Promise.allSettled(Object.entries(this.#pinnedBrowsers).map(async ([browser, options]) => {
+ if (options.skipDownload) {
+ return;
+ }
+ await this.#install({
+ ...args,
+ browser: {
+ name: browser,
+ buildId: options.buildId,
+ },
+ });
+ }));
+ for (const install of result) {
+ if (install.status === 'rejected') {
+ throw install.reason;
+ }
+ }
+ }
+ else {
+ await this.#install(args);
+ }
+ })
+ .command('launch ', 'Launch the specified browser', yargs => {
+ yargs
+ .example('$0 launch chrome@115.0.5790.170', 'Launch Chrome 115.0.5790.170')
+ .example('$0 launch firefox@112.0a1', 'Launch the Firefox browser identified by the milestone 112.0a1.')
+ .example('$0 launch chrome@115.0.5790.170 --detached', 'Launch the browser but detach the sub-processes.')
+ .example('$0 launch chrome@canary --system', 'Try to locate the Canary build of Chrome installed on the system and launch it.')
+ .example('$0 launch chrome@115.0.5790.170 -- --version', 'Launch Chrome 115.0.5790.170 and pass custom argument to the binary.');
+ const yargsWithExtraAgs = yargs.parserConfiguration({
+ 'populate--': true,
+ // Yargs does not have the correct overload for this.
+ });
+ const yargsWithBrowserParam = this.#defineBrowserParameter(yargsWithExtraAgs, true);
+ const yargsWithPlatformParam = this.#definePlatformParameter(yargsWithBrowserParam);
+ return this.#definePathParameter(yargsWithPlatformParam)
+ .option('detached', {
+ type: 'boolean',
+ desc: 'Detach the child process.',
+ default: false,
+ })
+ .option('system', {
+ type: 'boolean',
+ desc: 'Search for a browser installed on the system instead of the cache folder.',
+ default: false,
+ })
+ .option('dumpio', {
+ type: 'boolean',
+ desc: "Forwards the browser's process stdout and stderr",
+ default: false,
+ });
+ }, async (args) => {
+ const extraArgs = args['--']?.filter(arg => {
+ return typeof arg === 'string';
+ });
+ args.browser.buildId = this.#resolvePinnedBrowserIfNeeded(args.browser.buildId, args.browser.name);
+ const executablePath = args.system
+ ? computeSystemExecutablePath({
+ browser: args.browser.name,
+ // TODO: throw an error if not a ChromeReleaseChannel is provided.
+ channel: args.browser.buildId,
+ platform: args.platform,
+ })
+ : computeExecutablePath({
+ browser: args.browser.name,
+ buildId: args.browser.buildId,
+ cacheDir: args.path ?? this.#cachePath,
+ platform: args.platform,
+ });
+ launch({
+ args: extraArgs,
+ executablePath,
+ dumpio: args.dumpio,
+ detached: args.detached,
+ });
+ })
+ .command('clear', this.#allowCachePathOverride
+ ? 'Removes all installed browsers from the specified cache directory'
+ : `Removes all installed browsers from ${this.#cachePath}`, yargs => {
+ return this.#definePathParameter(yargs, true);
+ }, async (args) => {
+ const cacheDir = args.path ?? this.#cachePath;
+ const rl = this.#rl ?? readline.createInterface({ input, output });
+ rl.question(`Do you want to permanently and recursively delete the content of ${cacheDir} (yes/No)? `, answer => {
+ rl.close();
+ if (!['y', 'yes'].includes(answer.toLowerCase().trim())) {
+ console.log('Cancelled.');
+ return;
+ }
+ const cache = new Cache(cacheDir);
+ cache.clear();
+ console.log(`${cacheDir} cleared.`);
+ });
+ })
+ .command('list', 'List all installed browsers in the cache directory', yargs => {
+ yargs.example('$0 list', 'List all installed browsers in the cache directory');
+ if (this.#allowCachePathOverride) {
+ yargs.example('$0 list --path /tmp/my-browser-cache', 'List browsers installed in the specified cache directory');
+ }
+ return this.#definePathParameter(yargs);
+ }, async (args) => {
+ const cacheDir = args.path ?? this.#cachePath;
+ const cache = new Cache(cacheDir);
+ const browsers = cache.getInstalledBrowsers();
+ for (const browser of browsers) {
+ console.log(`${browser.browser}@${browser.buildId} (${browser.platform}) ${browser.executablePath}`);
+ }
+ })
+ .demandCommand(1)
+ .help();
+ }
+ #parseBrowser(version) {
+ return version.split('@').shift();
+ }
+ #parseBuildId(version) {
+ const parts = version.split('@');
+ return parts.length === 2
+ ? parts[1]
+ : this.#pinnedBrowsers
+ ? 'pinned'
+ : 'latest';
+ }
+ #resolvePinnedBrowserIfNeeded(buildId, browserName) {
+ if (buildId === 'pinned') {
+ const options = this.#pinnedBrowsers?.[browserName];
+ if (!options || !options.buildId) {
+ throw new Error(`No pinned version found for ${browserName}`);
+ }
+ return options.buildId;
+ }
+ return buildId;
+ }
+ async #install(args) {
+ if (!args.browser) {
+ throw new Error(`No browser arg provided`);
+ }
+ if (!args.platform) {
+ throw new Error(`Could not resolve the current platform`);
+ }
+ args.browser.buildId = this.#resolvePinnedBrowserIfNeeded(args.browser.buildId, args.browser.name);
+ const originalBuildId = args.browser.buildId;
+ args.browser.buildId = await resolveBuildId(args.browser.name, args.platform, args.browser.buildId);
+ await install({
+ browser: args.browser.name,
+ buildId: args.browser.buildId,
+ platform: args.platform,
+ cacheDir: args.path ?? this.#cachePath,
+ downloadProgressCallback: 'default',
+ baseUrl: args.baseUrl,
+ buildIdAlias: originalBuildId !== args.browser.buildId ? originalBuildId : undefined,
+ installDeps: args.installDeps,
+ });
+ console.log(`${args.browser.name}@${args.browser.buildId} ${computeExecutablePath({
+ browser: args.browser.name,
+ buildId: args.browser.buildId,
+ cacheDir: args.path ?? this.#cachePath,
+ platform: args.platform,
+ })}`);
+ }
+}
+//# sourceMappingURL=CLI.js.map
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/esm/CLI.js.map b/node_modules/@puppeteer/browsers/lib/esm/CLI.js.map
new file mode 100644
index 0000000..8fb9acc
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/esm/CLI.js.map
@@ -0,0 +1 @@
+{"version":3,"file":"CLI.js","sourceRoot":"","sources":["../../src/CLI.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,OAAO,EAAC,KAAK,IAAI,KAAK,EAAE,MAAM,IAAI,MAAM,EAAC,MAAM,cAAc,CAAC;AAC9D,OAAO,KAAK,QAAQ,MAAM,eAAe,CAAC;AAI1C,OAAO,EACL,OAAO,EACP,cAAc,EACd,eAAe,GAEhB,MAAM,gCAAgC,CAAC;AACxC,OAAO,EAAC,KAAK,EAAC,MAAM,YAAY,CAAC;AACjC,OAAO,EAAC,qBAAqB,EAAC,MAAM,qBAAqB,CAAC;AAC1D,OAAO,EAAC,cAAc,EAAC,MAAM,wBAAwB,CAAC;AACtD,OAAO,EAAC,OAAO,EAAC,M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CAAC,IAAI,IAAI,IAAI,CAAC,OAAO,CAAC,OAAO,IAAI,qBAAqB,CAAC;YACpE,OAAO,EAAE,IAAI,CAAC,OAAO,CAAC,IAAI;YAC1B,OAAO,EAAE,IAAI,CAAC,OAAO,CAAC,OAAO;YAC7B,QAAQ,EAAE,IAAI,CAAC,IAAI,IAAI,IAAI,CAAC,UAAU;YACtC,QAAQ,EAAE,IAAI,CAAC,QAAQ;SACxB,CAAC,EAAE,CACL,CAAC;IACJ,CAAC;CACF"}
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/esm/Cache.d.ts b/node_modules/@puppeteer/browsers/lib/esm/Cache.d.ts
new file mode 100644
index 0000000..b11b2c7
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/esm/Cache.d.ts
@@ -0,0 +1,86 @@
+/**
+ * @license
+ * Copyright 2023 Google Inc.
+ * SPDX-License-Identifier: Apache-2.0
+ */
+import { Browser, type BrowserPlatform } from './browser-data/browser-data.js';
+/**
+ * @public
+ */
+export declare class InstalledBrowser {
+ #private;
+ browser: Browser;
+ buildId: string;
+ platform: BrowserPlatform;
+ readonly executablePath: string;
+ /**
+ * @internal
+ */
+ constructor(cache: Cache, browser: Browser, buildId: string, platform: BrowserPlatform);
+ /**
+ * Path to the root of the installation folder. Use
+ * {@link computeExecutablePath} to get the path to the executable binary.
+ */
+ get path(): string;
+ readMetadata(): Metadata;
+ writeMetadata(metadata: Metadata): void;
+}
+/**
+ * @internal
+ */
+export interface ComputeExecutablePathOptions {
+ /**
+ * Determines which platform the browser will be suited for.
+ *
+ * @defaultValue **Auto-detected.**
+ */
+ platform?: BrowserPlatform;
+ /**
+ * Determines which browser to launch.
+ */
+ browser: Browser;
+ /**
+ * Determines which buildId to download. BuildId should uniquely identify
+ * binaries and they are used for caching.
+ */
+ buildId: string;
+}
+/**
+ * @public
+ */
+export interface Metadata {
+ aliases: Record;
+}
+/**
+ * The cache used by Puppeteer relies on the following structure:
+ *
+ * - rootDir
+ * -- | browserRoot(browser1)
+ * ---- - | installationDir()
+ * ------ the browser-platform-buildId
+ * ------ specific structure.
+ * -- | browserRoot(browser2)
+ * ---- - | installationDir()
+ * ------ the browser-platform-buildId
+ * ------ specific structure.
+ * @internal
+ */
+export declare class Cache {
+ #private;
+ constructor(rootDir: string);
+ /**
+ * @internal
+ */
+ get rootDir(): string;
+ browserRoot(browser: Browser): string;
+ metadataFile(browser: Browser): string;
+ readMetadata(browser: Browser): Metadata;
+ writeMetadata(browser: Browser, metadata: Metadata): void;
+ resolveAlias(browser: Browser, alias: string): string | undefined;
+ installationDir(browser: Browser, platform: BrowserPlatform, buildId: string): string;
+ clear(): void;
+ uninstall(browser: Browser, platform: BrowserPlatform, buildId: string): void;
+ getInstalledBrowsers(): InstalledBrowser[];
+ computeExecutablePath(options: ComputeExecutablePathOptions): string;
+}
+//# sourceMappingURL=Cache.d.ts.map
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/esm/Cache.d.ts.map b/node_modules/@puppeteer/browsers/lib/esm/Cache.d.ts.map
new file mode 100644
index 0000000..14957b2
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/esm/Cache.d.ts.map
@@ -0,0 +1 @@
+{"version":3,"file":"Cache.d.ts","sourceRoot":"","sources":["../../src/Cache.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAQH,OAAO,EACL,OAAO,EACP,KAAK,eAAe,EAGrB,MAAM,gCAAgC,CAAC;AAKxC;;GAEG;AACH,qBAAa,gBAAgB;;IAC3B,OAAO,EAAE,OAAO,CAAC;IACjB,OAAO,EAAE,MAAM,CAAC;IAChB,QAAQ,EAAE,eAAe,CAAC;IAC1B,QAAQ,CAAC,cAAc,EAAE,MAAM,CAAC;IAIhC;;OAEG;gBAED,KAAK,EAAE,KAAK,EACZ,OAAO,EAAE,OAAO,EAChB,OAAO,EAAE,MAAM,EACf,QAAQ,EAAE,eAAe;IAa3B;;;OAGG;IACH,IAAI,IAAI,IAAI,MAAM,CAMjB;IAED,YAAY,IAAI,QAAQ;IAIxB,aAAa,CAAC,QAAQ,EAAE,QAAQ,GAAG,IAAI;CAGxC;AAED;;GAEG;AACH,MAAM,WAAW,4BAA4B;IAC3C;;;;OAIG;IACH,QAAQ,CAAC,EAAE,eAAe,CAAC;IAC3B;;OAEG;IACH,OAAO,EAAE,OAAO,CAAC;IACjB;;;OAGG;IACH,OAAO,EAAE,MAAM,CAAC;CACjB;AAED;;GAEG;AACH,MAAM,WAAW,QAAQ;IAEvB,OAAO,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;CACjC;AAED;;;;;;;;;;;;;GAaG;AACH,qBAAa,KAAK;;gBAGJ,OAAO,EAAE,MAAM;IAI3B;;OAEG;IACH,IAAI,OAAO,IAAI,MAAM,CAEpB;IAED,WAAW,CAAC,OAAO,EAAE,OAAO,GAAG,MAAM;IAIrC,YAAY,CAAC,OAAO,EAAE,OAAO,GAAG,MAAM;IAItC,YAAY,CAAC,OAAO,EAAE,OAAO,GAAG,QAAQ;IAaxC,aAAa,CAAC,OAAO,EAAE,OAAO,EAAE,QAAQ,EAAE,QAAQ,GAAG,IAAI;IAMzD,YAAY,CAAC,OAAO,EAAE,OAAO,EAAE,KAAK,EAAE,MAAM,GAAG,MAAM,GAAG,SAAS;IAUjE,eAAe,CACb,OAAO,EAAE,OAAO,EAChB,QAAQ,EAAE,eAAe,EACzB,OAAO,EAAE,MAAM,GACd,MAAM;IAIT,KAAK,IAAI,IAAI;IASb,SAAS,CACP,OAAO,EAAE,OAAO,EAChB,QAAQ,EAAE,eAAe,EACzB,OAAO,EAAE,MAAM,GACd,IAAI;IAeP,oBAAoB,IAAI,gBAAgB,EAAE;IA+B1C,qBAAqB,CAAC,OAAO,EAAE,4BAA4B,GAAG,MAAM;CA0BrE"}
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/esm/Cache.js b/node_modules/@puppeteer/browsers/lib/esm/Cache.js
new file mode 100644
index 0000000..87e8bd0
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/esm/Cache.js
@@ -0,0 +1,183 @@
+/**
+ * @license
+ * Copyright 2023 Google Inc.
+ * SPDX-License-Identifier: Apache-2.0
+ */
+import fs from 'node:fs';
+import os from 'node:os';
+import path from 'node:path';
+import debug from 'debug';
+import { Browser, executablePathByBrowser, getVersionComparator, } from './browser-data/browser-data.js';
+import { detectBrowserPlatform } from './detectPlatform.js';
+const debugCache = debug('puppeteer:browsers:cache');
+/**
+ * @public
+ */
+export class InstalledBrowser {
+ browser;
+ buildId;
+ platform;
+ executablePath;
+ #cache;
+ /**
+ * @internal
+ */
+ constructor(cache, browser, buildId, platform) {
+ this.#cache = cache;
+ this.browser = browser;
+ this.buildId = buildId;
+ this.platform = platform;
+ this.executablePath = cache.computeExecutablePath({
+ browser,
+ buildId,
+ platform,
+ });
+ }
+ /**
+ * Path to the root of the installation folder. Use
+ * {@link computeExecutablePath} to get the path to the executable binary.
+ */
+ get path() {
+ return this.#cache.installationDir(this.browser, this.platform, this.buildId);
+ }
+ readMetadata() {
+ return this.#cache.readMetadata(this.browser);
+ }
+ writeMetadata(metadata) {
+ this.#cache.writeMetadata(this.browser, metadata);
+ }
+}
+/**
+ * The cache used by Puppeteer relies on the following structure:
+ *
+ * - rootDir
+ * -- | browserRoot(browser1)
+ * ---- - | installationDir()
+ * ------ the browser-platform-buildId
+ * ------ specific structure.
+ * -- | browserRoot(browser2)
+ * ---- - | installationDir()
+ * ------ the browser-platform-buildId
+ * ------ specific structure.
+ * @internal
+ */
+export class Cache {
+ #rootDir;
+ constructor(rootDir) {
+ this.#rootDir = rootDir;
+ }
+ /**
+ * @internal
+ */
+ get rootDir() {
+ return this.#rootDir;
+ }
+ browserRoot(browser) {
+ return path.join(this.#rootDir, browser);
+ }
+ metadataFile(browser) {
+ return path.join(this.browserRoot(browser), '.metadata');
+ }
+ readMetadata(browser) {
+ const metatadaPath = this.metadataFile(browser);
+ if (!fs.existsSync(metatadaPath)) {
+ return { aliases: {} };
+ }
+ // TODO: add type-safe parsing.
+ const data = JSON.parse(fs.readFileSync(metatadaPath, 'utf8'));
+ if (typeof data !== 'object') {
+ throw new Error('.metadata is not an object');
+ }
+ return data;
+ }
+ writeMetadata(browser, metadata) {
+ const metatadaPath = this.metadataFile(browser);
+ fs.mkdirSync(path.dirname(metatadaPath), { recursive: true });
+ fs.writeFileSync(metatadaPath, JSON.stringify(metadata, null, 2));
+ }
+ resolveAlias(browser, alias) {
+ const metadata = this.readMetadata(browser);
+ if (alias === 'latest') {
+ return Object.values(metadata.aliases || {})
+ .sort(getVersionComparator(browser))
+ .at(-1);
+ }
+ return metadata.aliases[alias];
+ }
+ installationDir(browser, platform, buildId) {
+ return path.join(this.browserRoot(browser), `${platform}-${buildId}`);
+ }
+ clear() {
+ fs.rmSync(this.#rootDir, {
+ force: true,
+ recursive: true,
+ maxRetries: 10,
+ retryDelay: 500,
+ });
+ }
+ uninstall(browser, platform, buildId) {
+ const metadata = this.readMetadata(browser);
+ for (const alias of Object.keys(metadata.aliases)) {
+ if (metadata.aliases[alias] === buildId) {
+ delete metadata.aliases[alias];
+ }
+ }
+ fs.rmSync(this.installationDir(browser, platform, buildId), {
+ force: true,
+ recursive: true,
+ maxRetries: 10,
+ retryDelay: 500,
+ });
+ }
+ getInstalledBrowsers() {
+ if (!fs.existsSync(this.#rootDir)) {
+ return [];
+ }
+ const types = fs.readdirSync(this.#rootDir);
+ const browsers = types.filter((t) => {
+ return Object.values(Browser).includes(t);
+ });
+ return browsers.flatMap(browser => {
+ const files = fs.readdirSync(this.browserRoot(browser));
+ return files
+ .map(file => {
+ const result = parseFolderPath(path.join(this.browserRoot(browser), file));
+ if (!result) {
+ return null;
+ }
+ return new InstalledBrowser(this, browser, result.buildId, result.platform);
+ })
+ .filter((item) => {
+ return item !== null;
+ });
+ });
+ }
+ computeExecutablePath(options) {
+ options.platform ??= detectBrowserPlatform();
+ if (!options.platform) {
+ throw new Error(`Cannot download a binary for the provided platform: ${os.platform()} (${os.arch()})`);
+ }
+ try {
+ options.buildId =
+ this.resolveAlias(options.browser, options.buildId) ?? options.buildId;
+ }
+ catch {
+ debugCache('could not read .metadata file for the browser');
+ }
+ const installationDir = this.installationDir(options.browser, options.platform, options.buildId);
+ return path.join(installationDir, executablePathByBrowser[options.browser](options.platform, options.buildId));
+ }
+}
+function parseFolderPath(folderPath) {
+ const name = path.basename(folderPath);
+ const splits = name.split('-');
+ if (splits.length !== 2) {
+ return;
+ }
+ const [platform, buildId] = splits;
+ if (!buildId || !platform) {
+ return;
+ }
+ return { platform, buildId };
+}
+//# sourceMappingURL=Cache.js.map
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/esm/Cache.js.map b/node_modules/@puppeteer/browsers/lib/esm/Cache.js.map
new file mode 100644
index 0000000..4d14313
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/esm/Cache.js.map
@@ -0,0 +1 @@
+{"version":3,"file":"Cache.js","sourceRoot":"","sources":["../../src/Cache.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,OAAO,EAAE,MAAM,SAAS,CAAC;AACzB,OAAO,EAAE,MAAM,SAAS,CAAC;AACzB,OAAO,IAAI,MAAM,WAAW,CAAC;AAE7B,OAAO,KAAK,MAAM,OAAO,CAAC;AAE1B,OAAO,EACL,OAAO,EAEP,uBAAuB,EACvB,oBAAoB,GACrB,MAAM,gCAAgC,CAAC;AACxC,OAAO,EAAC,qBAAqB,EAAC,MAAM,qBAAqB,CAAC;AAE1D,MAAM,UAAU,GAAG,KAAK,CAAC,0BAA0B,CAAC,CAAC;AAErD;;GAEG;AACH,MAAM,OAAO,gBAAgB;IAC3B,OAAO,CAAU;IACjB,OAAO,CAAS;IAChB,QAAQ,CAAkB;IACjB,cAAc,CAAS;IAEhC,MAAM,CAAQ;IAEd;;OAEG;IACH,YACE,KAAY,EACZ,OAAgB,EAChB,OAAe,EACf,QAAyB;QAEzB,IAAI,CAAC,MAAM,GAAG,KAAK,CAAC;QACpB,IA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AChB,OAAO,CAAC,OAAO,CAChB,CAAC;QACF,OAAO,IAAI,CAAC,IAAI,CACd,eAAe,EACf,uBAAuB,CAAC,OAAO,CAAC,OAAO,CAAC,CACtC,OAAO,CAAC,QAAQ,EAChB,OAAO,CAAC,OAAO,CAChB,CACF,CAAC;IACJ,CAAC;CACF;AAED,SAAS,eAAe,CACtB,UAAkB;IAElB,MAAM,IAAI,GAAG,IAAI,CAAC,QAAQ,CAAC,UAAU,CAAC,CAAC;IACvC,MAAM,MAAM,GAAG,IAAI,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC;IAC/B,IAAI,MAAM,CAAC,MAAM,KAAK,CAAC,EAAE,CAAC;QACxB,OAAO;IACT,CAAC;IACD,MAAM,CAAC,QAAQ,EAAE,OAAO,CAAC,GAAG,MAAM,CAAC;IACnC,IAAI,CAAC,OAAO,IAAI,CAAC,QAAQ,EAAE,CAAC;QAC1B,OAAO;IACT,CAAC;IACD,OAAO,EAAC,QAAQ,EAAE,OAAO,EAAC,CAAC;AAC7B,CAAC"}
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/esm/browser-data/browser-data.d.ts b/node_modules/@puppeteer/browsers/lib/esm/browser-data/browser-data.d.ts
new file mode 100644
index 0000000..4d7d644
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/esm/browser-data/browser-data.d.ts
@@ -0,0 +1,61 @@
+/**
+ * @license
+ * Copyright 2023 Google Inc.
+ * SPDX-License-Identifier: Apache-2.0
+ */
+import * as chromeHeadlessShell from './chrome-headless-shell.js';
+import * as chrome from './chrome.js';
+import * as chromedriver from './chromedriver.js';
+import * as chromium from './chromium.js';
+import * as firefox from './firefox.js';
+import { Browser, BrowserPlatform, BrowserTag, ChromeReleaseChannel, type ProfileOptions } from './types.js';
+export type { ProfileOptions };
+export declare const downloadUrls: {
+ chromedriver: typeof chromedriver.resolveDownloadUrl;
+ "chrome-headless-shell": typeof chromeHeadlessShell.resolveDownloadUrl;
+ chrome: typeof chrome.resolveDownloadUrl;
+ chromium: typeof chromium.resolveDownloadUrl;
+ firefox: typeof firefox.resolveDownloadUrl;
+};
+export declare const downloadPaths: {
+ chromedriver: typeof chromedriver.resolveDownloadPath;
+ "chrome-headless-shell": typeof chromeHeadlessShell.resolveDownloadPath;
+ chrome: typeof chrome.resolveDownloadPath;
+ chromium: typeof chromium.resolveDownloadPath;
+ firefox: typeof firefox.resolveDownloadPath;
+};
+export declare const executablePathByBrowser: {
+ chromedriver: typeof chromedriver.relativeExecutablePath;
+ "chrome-headless-shell": typeof chromeHeadlessShell.relativeExecutablePath;
+ chrome: typeof chrome.relativeExecutablePath;
+ chromium: typeof chromium.relativeExecutablePath;
+ firefox: typeof firefox.relativeExecutablePath;
+};
+export declare const versionComparators: {
+ chromedriver: typeof chromeHeadlessShell.compareVersions;
+ "chrome-headless-shell": typeof chromeHeadlessShell.compareVersions;
+ chrome: typeof chromeHeadlessShell.compareVersions;
+ chromium: typeof chromium.compareVersions;
+ firefox: typeof firefox.compareVersions;
+};
+export { Browser, BrowserPlatform, ChromeReleaseChannel };
+/**
+ * @public
+ */
+export declare function resolveBuildId(browser: Browser, platform: BrowserPlatform, tag: string | BrowserTag): Promise;
+/**
+ * @public
+ */
+export declare function createProfile(browser: Browser, opts: ProfileOptions): Promise;
+/**
+ * @public
+ */
+export declare function resolveSystemExecutablePath(browser: Browser, platform: BrowserPlatform, channel: ChromeReleaseChannel): string;
+/**
+ * Returns a version comparator for the given browser that can be used to sort
+ * browser versions.
+ *
+ * @public
+ */
+export declare function getVersionComparator(browser: Browser): (a: string, b: string) => number;
+//# sourceMappingURL=browser-data.d.ts.map
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/esm/browser-data/browser-data.d.ts.map b/node_modules/@puppeteer/browsers/lib/esm/browser-data/browser-data.d.ts.map
new file mode 100644
index 0000000..3724e9c
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/esm/browser-data/browser-data.d.ts.map
@@ -0,0 +1 @@
+{"version":3,"file":"browser-data.d.ts","sourceRoot":"","sources":["../../../src/browser-data/browser-data.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,OAAO,KAAK,mBAAmB,MAAM,4BAA4B,CAAC;AAClE,OAAO,KAAK,MAAM,MAAM,aAAa,CAAC;AACtC,OAAO,KAAK,YAAY,MAAM,mBAAmB,CAAC;AAClD,OAAO,KAAK,QAAQ,MAAM,eAAe,CAAC;AAC1C,OAAO,KAAK,OAAO,MAAM,cAAc,CAAC;AACxC,OAAO,EACL,OAAO,EACP,eAAe,EACf,UAAU,EACV,oBAAoB,EACpB,KAAK,cAAc,EACpB,MAAM,YAAY,CAAC;AAEpB,YAAY,EAAC,cAAc,EAAC,CAAC;AAE7B,eAAO,MAAM,YAAY;;;;;;CAMxB,CAAC;AAEF,eAAO,MAAM,aAAa;;;;;;CAMzB,CAAC;AAEF,eAAO,MAAM,uBAAuB;;;;;;CAMnC,CAAC;AAEF,eAAO,MAAM,kBAAkB;;;;;;CAM9B,CAAC;AAEF,OAAO,EAAC,OAAO,EAAE,eAAe,EAAE,oBAAoB,EAAC,CAAC;AA+GxD;;GAEG;AACH,wBAAsB,cAAc,CAClC,OAAO,EAAE,OAAO,EAChB,QAAQ,EAAE,eAAe,EACzB,GAAG,EAAE,MAAM,GAAG,UAAU,GACvB,OAAO,CAAC,MAAM,CAAC,CA+BjB;AAED;;GAEG;AACH,wBAAsB,aAAa,CACjC,OAAO,EAAE,OAAO,EAChB,IAAI,EAAE,cAAc,GACnB,OAAO,CAAC,IAAI,CAAC,CAQf;AAED;;GAEG;AACH,wBAAgB,2BAA2B,CACzC,OAAO,EAAE,OAAO,EAChB,QAAQ,EAAE,eAAe,EACzB,OAAO,EAAE,oBAAoB,GAC5B,MAAM,CAYR;AAED;;;;;GAKG;AACH,wBAAgB,oBAAoB,CAClC,OAAO,EAAE,OAAO,GACf,CAAC,CAAC,EAAE,MAAM,EAAE,CAAC,EAAE,MAAM,KAAK,MAAM,CAElC"}
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/esm/browser-data/browser-data.js b/node_modules/@puppeteer/browsers/lib/esm/browser-data/browser-data.js
new file mode 100644
index 0000000..eb9ed16
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/esm/browser-data/browser-data.js
@@ -0,0 +1,199 @@
+/**
+ * @license
+ * Copyright 2023 Google Inc.
+ * SPDX-License-Identifier: Apache-2.0
+ */
+import * as chromeHeadlessShell from './chrome-headless-shell.js';
+import * as chrome from './chrome.js';
+import * as chromedriver from './chromedriver.js';
+import * as chromium from './chromium.js';
+import * as firefox from './firefox.js';
+import { Browser, BrowserPlatform, BrowserTag, ChromeReleaseChannel, } from './types.js';
+export const downloadUrls = {
+ [Browser.CHROMEDRIVER]: chromedriver.resolveDownloadUrl,
+ [Browser.CHROMEHEADLESSSHELL]: chromeHeadlessShell.resolveDownloadUrl,
+ [Browser.CHROME]: chrome.resolveDownloadUrl,
+ [Browser.CHROMIUM]: chromium.resolveDownloadUrl,
+ [Browser.FIREFOX]: firefox.resolveDownloadUrl,
+};
+export const downloadPaths = {
+ [Browser.CHROMEDRIVER]: chromedriver.resolveDownloadPath,
+ [Browser.CHROMEHEADLESSSHELL]: chromeHeadlessShell.resolveDownloadPath,
+ [Browser.CHROME]: chrome.resolveDownloadPath,
+ [Browser.CHROMIUM]: chromium.resolveDownloadPath,
+ [Browser.FIREFOX]: firefox.resolveDownloadPath,
+};
+export const executablePathByBrowser = {
+ [Browser.CHROMEDRIVER]: chromedriver.relativeExecutablePath,
+ [Browser.CHROMEHEADLESSSHELL]: chromeHeadlessShell.relativeExecutablePath,
+ [Browser.CHROME]: chrome.relativeExecutablePath,
+ [Browser.CHROMIUM]: chromium.relativeExecutablePath,
+ [Browser.FIREFOX]: firefox.relativeExecutablePath,
+};
+export const versionComparators = {
+ [Browser.CHROMEDRIVER]: chromedriver.compareVersions,
+ [Browser.CHROMEHEADLESSSHELL]: chromeHeadlessShell.compareVersions,
+ [Browser.CHROME]: chrome.compareVersions,
+ [Browser.CHROMIUM]: chromium.compareVersions,
+ [Browser.FIREFOX]: firefox.compareVersions,
+};
+export { Browser, BrowserPlatform, ChromeReleaseChannel };
+/**
+ * @internal
+ */
+async function resolveBuildIdForBrowserTag(browser, platform, tag) {
+ switch (browser) {
+ case Browser.FIREFOX:
+ switch (tag) {
+ case BrowserTag.LATEST:
+ return await firefox.resolveBuildId(firefox.FirefoxChannel.NIGHTLY);
+ case BrowserTag.BETA:
+ return await firefox.resolveBuildId(firefox.FirefoxChannel.BETA);
+ case BrowserTag.NIGHTLY:
+ return await firefox.resolveBuildId(firefox.FirefoxChannel.NIGHTLY);
+ case BrowserTag.DEVEDITION:
+ return await firefox.resolveBuildId(firefox.FirefoxChannel.DEVEDITION);
+ case BrowserTag.STABLE:
+ return await firefox.resolveBuildId(firefox.FirefoxChannel.STABLE);
+ case BrowserTag.ESR:
+ return await firefox.resolveBuildId(firefox.FirefoxChannel.ESR);
+ case BrowserTag.CANARY:
+ case BrowserTag.DEV:
+ throw new Error(`${tag.toUpperCase()} is not available for Firefox`);
+ }
+ case Browser.CHROME: {
+ switch (tag) {
+ case BrowserTag.LATEST:
+ return await chrome.resolveBuildId(ChromeReleaseChannel.CANARY);
+ case BrowserTag.BETA:
+ return await chrome.resolveBuildId(ChromeReleaseChannel.BETA);
+ case BrowserTag.CANARY:
+ return await chrome.resolveBuildId(ChromeReleaseChannel.CANARY);
+ case BrowserTag.DEV:
+ return await chrome.resolveBuildId(ChromeReleaseChannel.DEV);
+ case BrowserTag.STABLE:
+ return await chrome.resolveBuildId(ChromeReleaseChannel.STABLE);
+ case BrowserTag.NIGHTLY:
+ case BrowserTag.DEVEDITION:
+ case BrowserTag.ESR:
+ throw new Error(`${tag.toUpperCase()} is not available for Chrome`);
+ }
+ }
+ case Browser.CHROMEDRIVER: {
+ switch (tag) {
+ case BrowserTag.LATEST:
+ case BrowserTag.CANARY:
+ return await chromedriver.resolveBuildId(ChromeReleaseChannel.CANARY);
+ case BrowserTag.BETA:
+ return await chromedriver.resolveBuildId(ChromeReleaseChannel.BETA);
+ case BrowserTag.DEV:
+ return await chromedriver.resolveBuildId(ChromeReleaseChannel.DEV);
+ case BrowserTag.STABLE:
+ return await chromedriver.resolveBuildId(ChromeReleaseChannel.STABLE);
+ case BrowserTag.NIGHTLY:
+ case BrowserTag.DEVEDITION:
+ case BrowserTag.ESR:
+ throw new Error(`${tag.toUpperCase()} is not available for ChromeDriver`);
+ }
+ }
+ case Browser.CHROMEHEADLESSSHELL: {
+ switch (tag) {
+ case BrowserTag.LATEST:
+ case BrowserTag.CANARY:
+ return await chromeHeadlessShell.resolveBuildId(ChromeReleaseChannel.CANARY);
+ case BrowserTag.BETA:
+ return await chromeHeadlessShell.resolveBuildId(ChromeReleaseChannel.BETA);
+ case BrowserTag.DEV:
+ return await chromeHeadlessShell.resolveBuildId(ChromeReleaseChannel.DEV);
+ case BrowserTag.STABLE:
+ return await chromeHeadlessShell.resolveBuildId(ChromeReleaseChannel.STABLE);
+ case BrowserTag.NIGHTLY:
+ case BrowserTag.DEVEDITION:
+ case BrowserTag.ESR:
+ throw new Error(`${tag} is not available for chrome-headless-shell`);
+ }
+ }
+ case Browser.CHROMIUM:
+ switch (tag) {
+ case BrowserTag.LATEST:
+ return await chromium.resolveBuildId(platform);
+ case BrowserTag.NIGHTLY:
+ case BrowserTag.CANARY:
+ case BrowserTag.DEV:
+ case BrowserTag.DEVEDITION:
+ case BrowserTag.BETA:
+ case BrowserTag.STABLE:
+ case BrowserTag.ESR:
+ throw new Error(`${tag} is not supported for Chromium. Use 'latest' instead.`);
+ }
+ }
+}
+/**
+ * @public
+ */
+export async function resolveBuildId(browser, platform, tag) {
+ const browserTag = tag;
+ if (Object.values(BrowserTag).includes(browserTag)) {
+ return await resolveBuildIdForBrowserTag(browser, platform, browserTag);
+ }
+ switch (browser) {
+ case Browser.FIREFOX:
+ return tag;
+ case Browser.CHROME:
+ const chromeResult = await chrome.resolveBuildId(tag);
+ if (chromeResult) {
+ return chromeResult;
+ }
+ return tag;
+ case Browser.CHROMEDRIVER:
+ const chromeDriverResult = await chromedriver.resolveBuildId(tag);
+ if (chromeDriverResult) {
+ return chromeDriverResult;
+ }
+ return tag;
+ case Browser.CHROMEHEADLESSSHELL:
+ const chromeHeadlessShellResult = await chromeHeadlessShell.resolveBuildId(tag);
+ if (chromeHeadlessShellResult) {
+ return chromeHeadlessShellResult;
+ }
+ return tag;
+ case Browser.CHROMIUM:
+ return tag;
+ }
+}
+/**
+ * @public
+ */
+export async function createProfile(browser, opts) {
+ switch (browser) {
+ case Browser.FIREFOX:
+ return await firefox.createProfile(opts);
+ case Browser.CHROME:
+ case Browser.CHROMIUM:
+ throw new Error(`Profile creation is not support for ${browser} yet`);
+ }
+}
+/**
+ * @public
+ */
+export function resolveSystemExecutablePath(browser, platform, channel) {
+ switch (browser) {
+ case Browser.CHROMEDRIVER:
+ case Browser.CHROMEHEADLESSSHELL:
+ case Browser.FIREFOX:
+ case Browser.CHROMIUM:
+ throw new Error(`System browser detection is not supported for ${browser} yet.`);
+ case Browser.CHROME:
+ return chrome.resolveSystemExecutablePath(platform, channel);
+ }
+}
+/**
+ * Returns a version comparator for the given browser that can be used to sort
+ * browser versions.
+ *
+ * @public
+ */
+export function getVersionComparator(browser) {
+ return versionComparators[browser];
+}
+//# sourceMappingURL=browser-data.js.map
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/esm/browser-data/browser-data.js.map b/node_modules/@puppeteer/browsers/lib/esm/browser-data/browser-data.js.map
new file mode 100644
index 0000000..98fc075
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/esm/browser-data/browser-data.js.map
@@ -0,0 +1 @@
+{"version":3,"file":"browser-data.js","sourceRoot":"","sources":["../../../src/browser-data/browser-data.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,OAAO,KAAK,mBAAmB,MAAM,4BAA4B,CAAC;AAClE,OAAO,KAAK,MAAM,MAAM,aAAa,CAAC;AACtC,O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OAAO,MAAM,CAAC,2BAA2B,CAAC,QAAQ,EAAE,OAAO,CAAC,CAAC;IACjE,CAAC;AACH,CAAC;AAED;;;;;GAKG;AACH,MAAM,UAAU,oBAAoB,CAClC,OAAgB;IAEhB,OAAO,kBAAkB,CAAC,OAAO,CAAC,CAAC;AACrC,CAAC"}
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/esm/browser-data/chrome-headless-shell.d.ts b/node_modules/@puppeteer/browsers/lib/esm/browser-data/chrome-headless-shell.d.ts
new file mode 100644
index 0000000..d21d11b
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/esm/browser-data/chrome-headless-shell.d.ts
@@ -0,0 +1,6 @@
+import { BrowserPlatform } from './types.js';
+export declare function resolveDownloadUrl(platform: BrowserPlatform, buildId: string, baseUrl?: string): string;
+export declare function resolveDownloadPath(platform: BrowserPlatform, buildId: string): string[];
+export declare function relativeExecutablePath(platform: BrowserPlatform, _buildId: string): string;
+export { resolveBuildId, compareVersions } from './chrome.js';
+//# sourceMappingURL=chrome-headless-shell.d.ts.map
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/esm/browser-data/chrome-headless-shell.d.ts.map b/node_modules/@puppeteer/browsers/lib/esm/browser-data/chrome-headless-shell.d.ts.map
new file mode 100644
index 0000000..5ca312a
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/esm/browser-data/chrome-headless-shell.d.ts.map
@@ -0,0 +1 @@
+{"version":3,"file":"chrome-headless-shell.d.ts","sourceRoot":"","sources":["../../../src/browser-data/chrome-headless-shell.ts"],"names":[],"mappings":"AAOA,OAAO,EAAC,eAAe,EAAC,MAAM,YAAY,CAAC;AAkB3C,wBAAgB,kBAAkB,CAChC,QAAQ,EAAE,eAAe,EACzB,OAAO,EAAE,MAAM,EACf,OAAO,SAA6D,GACnE,MAAM,CAER;AAED,wBAAgB,mBAAmB,CACjC,QAAQ,EAAE,eAAe,EACzB,OAAO,EAAE,MAAM,GACd,MAAM,EAAE,CAMV;AAED,wBAAgB,sBAAsB,CACpC,QAAQ,EAAE,eAAe,EACzB,QAAQ,EAAE,MAAM,GACf,MAAM,CAqBR;AAED,OAAO,EAAC,cAAc,EAAE,eAAe,EAAC,MAAM,aAAa,CAAC"}
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/esm/browser-data/chrome-headless-shell.js b/node_modules/@puppeteer/browsers/lib/esm/browser-data/chrome-headless-shell.js
new file mode 100644
index 0000000..90aedc1
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/esm/browser-data/chrome-headless-shell.js
@@ -0,0 +1,47 @@
+/**
+ * @license
+ * Copyright 2023 Google Inc.
+ * SPDX-License-Identifier: Apache-2.0
+ */
+import path from 'node:path';
+import { BrowserPlatform } from './types.js';
+function folder(platform) {
+ switch (platform) {
+ case BrowserPlatform.LINUX_ARM:
+ case BrowserPlatform.LINUX:
+ return 'linux64';
+ case BrowserPlatform.MAC_ARM:
+ return 'mac-arm64';
+ case BrowserPlatform.MAC:
+ return 'mac-x64';
+ case BrowserPlatform.WIN32:
+ return 'win32';
+ case BrowserPlatform.WIN64:
+ return 'win64';
+ }
+}
+export function resolveDownloadUrl(platform, buildId, baseUrl = 'https://storage.googleapis.com/chrome-for-testing-public') {
+ return `${baseUrl}/${resolveDownloadPath(platform, buildId).join('/')}`;
+}
+export function resolveDownloadPath(platform, buildId) {
+ return [
+ buildId,
+ folder(platform),
+ `chrome-headless-shell-${folder(platform)}.zip`,
+ ];
+}
+export function relativeExecutablePath(platform, _buildId) {
+ switch (platform) {
+ case BrowserPlatform.MAC:
+ case BrowserPlatform.MAC_ARM:
+ return path.join('chrome-headless-shell-' + folder(platform), 'chrome-headless-shell');
+ case BrowserPlatform.LINUX_ARM:
+ case BrowserPlatform.LINUX:
+ return path.join('chrome-headless-shell-linux64', 'chrome-headless-shell');
+ case BrowserPlatform.WIN32:
+ case BrowserPlatform.WIN64:
+ return path.join('chrome-headless-shell-' + folder(platform), 'chrome-headless-shell.exe');
+ }
+}
+export { resolveBuildId, compareVersions } from './chrome.js';
+//# sourceMappingURL=chrome-headless-shell.js.map
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/esm/browser-data/chrome-headless-shell.js.map b/node_modules/@puppeteer/browsers/lib/esm/browser-data/chrome-headless-shell.js.map
new file mode 100644
index 0000000..5d2413b
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/esm/browser-data/chrome-headless-shell.js.map
@@ -0,0 +1 @@
+{"version":3,"file":"chrome-headless-shell.js","sourceRoot":"","sources":["../../../src/browser-data/chrome-headless-shell.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AACH,OAAO,IAAI,MAAM,WAAW,CAAC;AAE7B,OAAO,EAAC,eAAe,EAAC,MAAM,YAAY,CAAC;AAE3C,SAAS,MAAM,CAAC,QAAyB;IACvC,QAAQ,QAAQ,EAAE,CAAC;QACjB,KAAK,eAAe,CAAC,SAAS,CAAC;QAC/B,KAAK,eAAe,CAAC,KAAK;YACxB,OAAO,SAAS,CAAC;QACnB,KAAK,eAAe,CAAC,OAAO;YAC1B,OAAO,WAAW,CAAC;QACrB,KAAK,eAAe,CAAC,GAAG;YACtB,OAAO,SAAS,CAAC;QACnB,KAAK,eAAe,CAAC,KAAK;YACxB,OAAO,OAAO,CAAC;QACjB,KAAK,eAAe,CAAC,KAAK;YACxB,OAAO,OAAO,CAAC;IACnB,CAAC;AACH,CAAC;AAED,MAAM,UAAU,kBAAkB,CAChC,QAAyB,EACzB,OAAe,EACf,OAAO,GAAG,0DAA0D;IAEpE,OAAO,GAAG,OAAO,IAAI,mBAAmB,CAAC,QAAQ,EAAE,OAAO,CAAC,CAAC,IAAI,CAAC,GAAG,CAAC,EAAE,CAAC;AAC1E,CAAC;AAED,MAAM,UAAU,mBAAmB,CACjC,QAAyB,EACzB,OAAe;IAEf,OAAO;QACL,OAAO;QACP,MAAM,CAAC,QAAQ,CAAC;QAChB,yBAAyB,MAAM,CAAC,QAAQ,CAAC,MAAM;KAChD,CAAC;AACJ,CAAC;AAED,MAAM,UAAU,sBAAsB,CACpC,QAAyB,EACzB,QAAgB;IAEhB,QAAQ,QAAQ,EAAE,CAAC;QACjB,KAAK,eAAe,CAAC,GAAG,CAAC;QACzB,KAAK,eAAe,CAAC,OAAO;YAC1B,OAAO,IAAI,CAAC,IAAI,CACd,wBAAwB,GAAG,MAAM,CAAC,QAAQ,CAAC,EAC3C,uBAAuB,CACxB,CAAC;QACJ,KAAK,eAAe,CAAC,SAAS,CAAC;QAC/B,KAAK,eAAe,CAAC,KAAK;YACxB,OAAO,IAAI,CAAC,IAAI,CACd,+BAA+B,EAC/B,uBAAuB,CACxB,CAAC;QACJ,KAAK,eAAe,CAAC,KAAK,CAAC;QAC3B,KAAK,eAAe,CAAC,KAAK;YACxB,OAAO,IAAI,CAAC,IAAI,CACd,wBAAwB,GAAG,MAAM,CAAC,QAAQ,CAAC,EAC3C,2BAA2B,CAC5B,CAAC;IACN,CAAC;AACH,CAAC;AAED,OAAO,EAAC,cAAc,EAAE,eAAe,EAAC,MAAM,aAAa,CAAC"}
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/esm/browser-data/chrome.d.ts b/node_modules/@puppeteer/browsers/lib/esm/browser-data/chrome.d.ts
new file mode 100644
index 0000000..da0c1e7
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/esm/browser-data/chrome.d.ts
@@ -0,0 +1,30 @@
+/**
+ * @license
+ * Copyright 2023 Google Inc.
+ * SPDX-License-Identifier: Apache-2.0
+ */
+import { BrowserPlatform, ChromeReleaseChannel } from './types.js';
+export declare function resolveDownloadUrl(platform: BrowserPlatform, buildId: string, baseUrl?: string): string;
+export declare function resolveDownloadPath(platform: BrowserPlatform, buildId: string): string[];
+export declare function relativeExecutablePath(platform: BrowserPlatform, _buildId: string): string;
+export declare function getLastKnownGoodReleaseForChannel(channel: ChromeReleaseChannel): Promise<{
+ version: string;
+ revision: string;
+}>;
+export declare function getLastKnownGoodReleaseForMilestone(milestone: string): Promise<{
+ version: string;
+ revision: string;
+} | undefined>;
+export declare function getLastKnownGoodReleaseForBuild(
+/**
+ * @example `112.0.23`,
+ */
+buildPrefix: string): Promise<{
+ version: string;
+ revision: string;
+} | undefined>;
+export declare function resolveBuildId(channel: ChromeReleaseChannel): Promise;
+export declare function resolveBuildId(channel: string): Promise;
+export declare function resolveSystemExecutablePath(platform: BrowserPlatform, channel: ChromeReleaseChannel): string;
+export declare function compareVersions(a: string, b: string): number;
+//# sourceMappingURL=chrome.d.ts.map
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/esm/browser-data/chrome.d.ts.map b/node_modules/@puppeteer/browsers/lib/esm/browser-data/chrome.d.ts.map
new file mode 100644
index 0000000..2bf0d5f
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/esm/browser-data/chrome.d.ts.map
@@ -0,0 +1 @@
+{"version":3,"file":"chrome.d.ts","sourceRoot":"","sources":["../../../src/browser-data/chrome.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAQH,OAAO,EAAC,eAAe,EAAE,oBAAoB,EAAC,MAAM,YAAY,CAAC;AAkBjE,wBAAgB,kBAAkB,CAChC,QAAQ,EAAE,eAAe,EACzB,OAAO,EAAE,MAAM,EACf,OAAO,SAA6D,GACnE,MAAM,CAER;AAED,wBAAgB,mBAAmB,CACjC,QAAQ,EAAE,eAAe,EACzB,OAAO,EAAE,MAAM,GACd,MAAM,EAAE,CAEV;AAED,wBAAgB,sBAAsB,CACpC,QAAQ,EAAE,eAAe,EACzB,QAAQ,EAAE,MAAM,GACf,MAAM,CAkBR;AAED,wBAAsB,iCAAiC,CACrD,OAAO,EAAE,oBAAoB,GAC5B,OAAO,CAAC;IAAC,OAAO,EAAE,MAAM,CAAC;IAAC,QAAQ,EAAE,MAAM,CAAA;CAAC,CAAC,CAsB9C;AAED,wBAAsB,mCAAmC,CACvD,SAAS,EAAE,MAAM,GAChB,OAAO,CAAC;IAAC,OAAO,EAAE,MAAM,CAAC;IAAC,QAAQ,EAAE,MAAM,CAAA;CAAC,GAAG,SAAS,CAAC,CAW1D;AAED,wBAAsB,+BAA+B;AACnD;;GAEG;AACH,WAAW,EAAE,MAAM,GAClB,OAAO,CAAC;IAAC,OAAO,EAAE,MAAM,CAAC;IAAC,QAAQ,EAAE,MAAM,CAAA;CAAC,GAAG,SAAS,CAAC,CAW1D;AAED,wBAAsB,cAAc,CAClC,OAAO,EAAE,oBAAoB,GAC5B,OAAO,CAAC,MAAM,CAAC,CAAC;AACnB,wBAAsB,cAAc,CAClC,OAAO,EAAE,MAAM,GACd,OAAO,CAAC,MAAM,GAAG,SAAS,CAAC,CAAC;AAwB/B,wBAAgB,2BAA2B,CACzC,QAAQ,EAAE,eAAe,EACzB,OAAO,EAAE,oBAAoB,GAC5B,MAAM,CAuCR;AAED,wBAAgB,eAAe,CAAC,CAAC,EAAE,MAAM,EAAE,CAAC,EAAE,MAAM,GAAG,MAAM,CAc5D"}
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/esm/browser-data/chrome.js b/node_modules/@puppeteer/browsers/lib/esm/browser-data/chrome.js
new file mode 100644
index 0000000..825f9e2
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/esm/browser-data/chrome.js
@@ -0,0 +1,135 @@
+/**
+ * @license
+ * Copyright 2023 Google Inc.
+ * SPDX-License-Identifier: Apache-2.0
+ */
+import path from 'node:path';
+import semver from 'semver';
+import { getJSON } from '../httpUtil.js';
+import { BrowserPlatform, ChromeReleaseChannel } from './types.js';
+function folder(platform) {
+ switch (platform) {
+ case BrowserPlatform.LINUX_ARM:
+ case BrowserPlatform.LINUX:
+ return 'linux64';
+ case BrowserPlatform.MAC_ARM:
+ return 'mac-arm64';
+ case BrowserPlatform.MAC:
+ return 'mac-x64';
+ case BrowserPlatform.WIN32:
+ return 'win32';
+ case BrowserPlatform.WIN64:
+ return 'win64';
+ }
+}
+export function resolveDownloadUrl(platform, buildId, baseUrl = 'https://storage.googleapis.com/chrome-for-testing-public') {
+ return `${baseUrl}/${resolveDownloadPath(platform, buildId).join('/')}`;
+}
+export function resolveDownloadPath(platform, buildId) {
+ return [buildId, folder(platform), `chrome-${folder(platform)}.zip`];
+}
+export function relativeExecutablePath(platform, _buildId) {
+ switch (platform) {
+ case BrowserPlatform.MAC:
+ case BrowserPlatform.MAC_ARM:
+ return path.join('chrome-' + folder(platform), 'Google Chrome for Testing.app', 'Contents', 'MacOS', 'Google Chrome for Testing');
+ case BrowserPlatform.LINUX_ARM:
+ case BrowserPlatform.LINUX:
+ return path.join('chrome-linux64', 'chrome');
+ case BrowserPlatform.WIN32:
+ case BrowserPlatform.WIN64:
+ return path.join('chrome-' + folder(platform), 'chrome.exe');
+ }
+}
+export async function getLastKnownGoodReleaseForChannel(channel) {
+ const data = (await getJSON(new URL('https://googlechromelabs.github.io/chrome-for-testing/last-known-good-versions.json')));
+ for (const channel of Object.keys(data.channels)) {
+ data.channels[channel.toLowerCase()] = data.channels[channel];
+ delete data.channels[channel];
+ }
+ return data.channels[channel];
+}
+export async function getLastKnownGoodReleaseForMilestone(milestone) {
+ const data = (await getJSON(new URL('https://googlechromelabs.github.io/chrome-for-testing/latest-versions-per-milestone.json')));
+ return data.milestones[milestone];
+}
+export async function getLastKnownGoodReleaseForBuild(
+/**
+ * @example `112.0.23`,
+ */
+buildPrefix) {
+ const data = (await getJSON(new URL('https://googlechromelabs.github.io/chrome-for-testing/latest-patch-versions-per-build.json')));
+ return data.builds[buildPrefix];
+}
+export async function resolveBuildId(channel) {
+ if (Object.values(ChromeReleaseChannel).includes(channel)) {
+ return (await getLastKnownGoodReleaseForChannel(channel)).version;
+ }
+ if (channel.match(/^\d+$/)) {
+ // Potentially a milestone.
+ return (await getLastKnownGoodReleaseForMilestone(channel))?.version;
+ }
+ if (channel.match(/^\d+\.\d+\.\d+$/)) {
+ // Potentially a build prefix without the patch version.
+ return (await getLastKnownGoodReleaseForBuild(channel))?.version;
+ }
+ return;
+}
+export function resolveSystemExecutablePath(platform, channel) {
+ switch (platform) {
+ case BrowserPlatform.WIN64:
+ case BrowserPlatform.WIN32:
+ switch (channel) {
+ case ChromeReleaseChannel.STABLE:
+ return `${process.env['PROGRAMFILES']}\\Google\\Chrome\\Application\\chrome.exe`;
+ case ChromeReleaseChannel.BETA:
+ return `${process.env['PROGRAMFILES']}\\Google\\Chrome Beta\\Application\\chrome.exe`;
+ case ChromeReleaseChannel.CANARY:
+ return `${process.env['PROGRAMFILES']}\\Google\\Chrome SxS\\Application\\chrome.exe`;
+ case ChromeReleaseChannel.DEV:
+ return `${process.env['PROGRAMFILES']}\\Google\\Chrome Dev\\Application\\chrome.exe`;
+ }
+ case BrowserPlatform.MAC_ARM:
+ case BrowserPlatform.MAC:
+ switch (channel) {
+ case ChromeReleaseChannel.STABLE:
+ return '/Applications/Google Chrome.app/Contents/MacOS/Google Chrome';
+ case ChromeReleaseChannel.BETA:
+ return '/Applications/Google Chrome Beta.app/Contents/MacOS/Google Chrome Beta';
+ case ChromeReleaseChannel.CANARY:
+ return '/Applications/Google Chrome Canary.app/Contents/MacOS/Google Chrome Canary';
+ case ChromeReleaseChannel.DEV:
+ return '/Applications/Google Chrome Dev.app/Contents/MacOS/Google Chrome Dev';
+ }
+ case BrowserPlatform.LINUX_ARM:
+ case BrowserPlatform.LINUX:
+ switch (channel) {
+ case ChromeReleaseChannel.STABLE:
+ return '/opt/google/chrome/chrome';
+ case ChromeReleaseChannel.BETA:
+ return '/opt/google/chrome-beta/chrome';
+ case ChromeReleaseChannel.CANARY:
+ return '/opt/google/chrome-canary/chrome';
+ case ChromeReleaseChannel.DEV:
+ return '/opt/google/chrome-unstable/chrome';
+ }
+ }
+}
+export function compareVersions(a, b) {
+ if (!semver.valid(a)) {
+ throw new Error(`Version ${a} is not a valid semver version`);
+ }
+ if (!semver.valid(b)) {
+ throw new Error(`Version ${b} is not a valid semver version`);
+ }
+ if (semver.gt(a, b)) {
+ return 1;
+ }
+ else if (semver.lt(a, b)) {
+ return -1;
+ }
+ else {
+ return 0;
+ }
+}
+//# sourceMappingURL=chrome.js.map
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/esm/browser-data/chrome.js.map b/node_modules/@puppeteer/browsers/lib/esm/browser-data/chrome.js.map
new file mode 100644
index 0000000..22edcd6
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/esm/browser-data/chrome.js.map
@@ -0,0 +1 @@
+{"version":3,"file":"chrome.js","sourceRoot":"","sources":["../../../src/browser-data/chrome.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,OAAO,IAAI,MAAM,WAAW,CAAC;AAE7B,OAAO,MAAM,MAAM,QAAQ,CAAC;AAE5B,OAAO,EAAC,OAAO,EAAC,MAAM,gBAAgB,CAAC;AAEvC,OAAO,EAAC,eAAe,EAAE,oBAAoB,EAAC,MAAM,YAAY,CAAC;AAEjE,SAAS,MAAM,CAAC,QAAyB;IACvC,QAAQ,QAAQ,EAAE,CAAC;QACjB,KAAK,eAAe,CAAC,SAAS,CAAC;QAC/B,KAAK,eAAe,CAAC,KAAK;YACxB,OAAO,SAAS,CAAC;QACnB,KAAK,eAAe,CAAC,OAAO;YAC1B,OAAO,WAAW,CAAC;QACrB,KAAK,eAAe,CAAC,GAAG;YACtB,OAAO,SAAS,CAAC;QACnB,KAAK,eAAe,CAAC,KAAK;YACxB,OAAO,OAAO,CAAC;QACjB,KAAK,eAAe,CAAC,KAAK;YACxB,OAAO,OAAO,CAAC;IACnB,CAAC;AACH,CAAC;AAED,MAAM,UAAU,kBAAkB,CAChC,QAAyB,EACzB,OAAe,EACf,OAAO,GAAG,0DAA0D;IAEpE,OAAO,GAAG,OAAO,IAAI,mBAAmB,CAAC,QAAQ,EAAE,OAAO,CAAC,CAAC,IAAI,CAAC,GAAG,CAAC,EAAE,CAAC;AAC1E,CAAC;AAED,MAAM,UAAU,mBAAmB,CACjC,QAAyB,EACzB,OAAe;IAEf,OAAO,CAAC,OAAO,EAAE,MAAM,CAAC,QAAQ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WAAW,CAAC,gCAAgC,CAAC,CAAC;IAChE,CAAC;IACD,IAAI,CAAC,MAAM,CAAC,KAAK,CAAC,CAAC,CAAC,EAAE,CAAC;QACrB,MAAM,IAAI,KAAK,CAAC,WAAW,CAAC,gCAAgC,CAAC,CAAC;IAChE,CAAC;IACD,IAAI,MAAM,CAAC,EAAE,CAAC,CAAC,EAAE,CAAC,CAAC,EAAE,CAAC;QACpB,OAAO,CAAC,CAAC;IACX,CAAC;SAAM,IAAI,MAAM,CAAC,EAAE,CAAC,CAAC,EAAE,CAAC,CAAC,EAAE,CAAC;QAC3B,OAAO,CAAC,CAAC,CAAC;IACZ,CAAC;SAAM,CAAC;QACN,OAAO,CAAC,CAAC;IACX,CAAC;AACH,CAAC"}
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/esm/browser-data/chromedriver.d.ts b/node_modules/@puppeteer/browsers/lib/esm/browser-data/chromedriver.d.ts
new file mode 100644
index 0000000..5a26c3f
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/esm/browser-data/chromedriver.d.ts
@@ -0,0 +1,6 @@
+import { BrowserPlatform } from './types.js';
+export declare function resolveDownloadUrl(platform: BrowserPlatform, buildId: string, baseUrl?: string): string;
+export declare function resolveDownloadPath(platform: BrowserPlatform, buildId: string): string[];
+export declare function relativeExecutablePath(platform: BrowserPlatform, _buildId: string): string;
+export { resolveBuildId, compareVersions } from './chrome.js';
+//# sourceMappingURL=chromedriver.d.ts.map
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/esm/browser-data/chromedriver.d.ts.map b/node_modules/@puppeteer/browsers/lib/esm/browser-data/chromedriver.d.ts.map
new file mode 100644
index 0000000..83af5f7
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/esm/browser-data/chromedriver.d.ts.map
@@ -0,0 +1 @@
+{"version":3,"file":"chromedriver.d.ts","sourceRoot":"","sources":["../../../src/browser-data/chromedriver.ts"],"names":[],"mappings":"AAOA,OAAO,EAAC,eAAe,EAAC,MAAM,YAAY,CAAC;AAkB3C,wBAAgB,kBAAkB,CAChC,QAAQ,EAAE,eAAe,EACzB,OAAO,EAAE,MAAM,EACf,OAAO,SAA6D,GACnE,MAAM,CAER;AAED,wBAAgB,mBAAmB,CACjC,QAAQ,EAAE,eAAe,EACzB,OAAO,EAAE,MAAM,GACd,MAAM,EAAE,CAEV;AAED,wBAAgB,sBAAsB,CACpC,QAAQ,EAAE,eAAe,EACzB,QAAQ,EAAE,MAAM,GACf,MAAM,CAYR;AAED,OAAO,EAAC,cAAc,EAAE,eAAe,EAAC,MAAM,aAAa,CAAC"}
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/esm/browser-data/chromedriver.js b/node_modules/@puppeteer/browsers/lib/esm/browser-data/chromedriver.js
new file mode 100644
index 0000000..2bff977
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/esm/browser-data/chromedriver.js
@@ -0,0 +1,43 @@
+/**
+ * @license
+ * Copyright 2023 Google Inc.
+ * SPDX-License-Identifier: Apache-2.0
+ */
+import path from 'node:path';
+import { BrowserPlatform } from './types.js';
+function folder(platform) {
+ switch (platform) {
+ case BrowserPlatform.LINUX_ARM:
+ case BrowserPlatform.LINUX:
+ return 'linux64';
+ case BrowserPlatform.MAC_ARM:
+ return 'mac-arm64';
+ case BrowserPlatform.MAC:
+ return 'mac-x64';
+ case BrowserPlatform.WIN32:
+ return 'win32';
+ case BrowserPlatform.WIN64:
+ return 'win64';
+ }
+}
+export function resolveDownloadUrl(platform, buildId, baseUrl = 'https://storage.googleapis.com/chrome-for-testing-public') {
+ return `${baseUrl}/${resolveDownloadPath(platform, buildId).join('/')}`;
+}
+export function resolveDownloadPath(platform, buildId) {
+ return [buildId, folder(platform), `chromedriver-${folder(platform)}.zip`];
+}
+export function relativeExecutablePath(platform, _buildId) {
+ switch (platform) {
+ case BrowserPlatform.MAC:
+ case BrowserPlatform.MAC_ARM:
+ return path.join('chromedriver-' + folder(platform), 'chromedriver');
+ case BrowserPlatform.LINUX_ARM:
+ case BrowserPlatform.LINUX:
+ return path.join('chromedriver-linux64', 'chromedriver');
+ case BrowserPlatform.WIN32:
+ case BrowserPlatform.WIN64:
+ return path.join('chromedriver-' + folder(platform), 'chromedriver.exe');
+ }
+}
+export { resolveBuildId, compareVersions } from './chrome.js';
+//# sourceMappingURL=chromedriver.js.map
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/esm/browser-data/chromedriver.js.map b/node_modules/@puppeteer/browsers/lib/esm/browser-data/chromedriver.js.map
new file mode 100644
index 0000000..1919d09
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/esm/browser-data/chromedriver.js.map
@@ -0,0 +1 @@
+{"version":3,"file":"chromedriver.js","sourceRoot":"","sources":["../../../src/browser-data/chromedriver.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AACH,OAAO,IAAI,MAAM,WAAW,CAAC;AAE7B,OAAO,EAAC,eAAe,EAAC,MAAM,YAAY,CAAC;AAE3C,SAAS,MAAM,CAAC,QAAyB;IACvC,QAAQ,QAAQ,EAAE,CAAC;QACjB,KAAK,eAAe,CAAC,SAAS,CAAC;QAC/B,KAAK,eAAe,CAAC,KAAK;YACxB,OAAO,SAAS,CAAC;QACnB,KAAK,eAAe,CAAC,OAAO;YAC1B,OAAO,WAAW,CAAC;QACrB,KAAK,eAAe,CAAC,GAAG;YACtB,OAAO,SAAS,CAAC;QACnB,KAAK,eAAe,CAAC,KAAK;YACxB,OAAO,OAAO,CAAC;QACjB,KAAK,eAAe,CAAC,KAAK;YACxB,OAAO,OAAO,CAAC;IACnB,CAAC;AACH,CAAC;AAED,MAAM,UAAU,kBAAkB,CAChC,QAAyB,EACzB,OAAe,EACf,OAAO,GAAG,0DAA0D;IAEpE,OAAO,GAAG,OAAO,IAAI,mBAAmB,CAAC,QAAQ,EAAE,OAAO,CAAC,CAAC,IAAI,CAAC,GAAG,CAAC,EAAE,CAAC;AAC1E,CAAC;AAED,MAAM,UAAU,mBAAmB,CACjC,QAAyB,EACzB,OAAe;IAEf,OAAO,CAAC,OAAO,EAAE,MAAM,CAAC,QAAQ,CAAC,EAAE,gBAAgB,MAAM,CAAC,QAAQ,CAAC,MAAM,CAAC,CAAC;AAC7E,CAAC;AAED,MAAM,UAAU,sBAAsB,CACpC,QAAyB,EACzB,QAAgB;IAEhB,QAAQ,QAAQ,EAAE,CAAC;QACjB,KAAK,eAAe,CAAC,GAAG,CAAC;QACzB,KAAK,eAAe,CAAC,OAAO;YAC1B,OAAO,IAAI,CAAC,IAAI,CAAC,eAAe,GAAG,MAAM,CAAC,QAAQ,CAAC,EAAE,cAAc,CAAC,CAAC;QACvE,KAAK,eAAe,CAAC,SAAS,CAAC;QAC/B,KAAK,eAAe,CAAC,KAAK;YACxB,OAAO,IAAI,CAAC,IAAI,CAAC,sBAAsB,EAAE,cAAc,CAAC,CAAC;QAC3D,KAAK,eAAe,CAAC,KAAK,CAAC;QAC3B,KAAK,eAAe,CAAC,KAAK;YACxB,OAAO,IAAI,CAAC,IAAI,CAAC,eAAe,GAAG,MAAM,CAAC,QAAQ,CAAC,EAAE,kBAAkB,CAAC,CAAC;IAC7E,CAAC;AACH,CAAC;AAED,OAAO,EAAC,cAAc,EAAE,eAAe,EAAC,MAAM,aAAa,CAAC"}
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/esm/browser-data/chromium.d.ts b/node_modules/@puppeteer/browsers/lib/esm/browser-data/chromium.d.ts
new file mode 100644
index 0000000..6bcb936
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/esm/browser-data/chromium.d.ts
@@ -0,0 +1,12 @@
+/**
+ * @license
+ * Copyright 2023 Google Inc.
+ * SPDX-License-Identifier: Apache-2.0
+ */
+import { BrowserPlatform } from './types.js';
+export declare function resolveDownloadUrl(platform: BrowserPlatform, buildId: string, baseUrl?: string): string;
+export declare function resolveDownloadPath(platform: BrowserPlatform, buildId: string): string[];
+export declare function relativeExecutablePath(platform: BrowserPlatform, _buildId: string): string;
+export declare function resolveBuildId(platform: BrowserPlatform): Promise;
+export declare function compareVersions(a: string, b: string): number;
+//# sourceMappingURL=chromium.d.ts.map
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/esm/browser-data/chromium.d.ts.map b/node_modules/@puppeteer/browsers/lib/esm/browser-data/chromium.d.ts.map
new file mode 100644
index 0000000..cf36579
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/esm/browser-data/chromium.d.ts.map
@@ -0,0 +1 @@
+{"version":3,"file":"chromium.d.ts","sourceRoot":"","sources":["../../../src/browser-data/chromium.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAMH,OAAO,EAAC,eAAe,EAAC,MAAM,YAAY,CAAC;AAiC3C,wBAAgB,kBAAkB,CAChC,QAAQ,EAAE,eAAe,EACzB,OAAO,EAAE,MAAM,EACf,OAAO,SAA8D,GACpE,MAAM,CAER;AAED,wBAAgB,mBAAmB,CACjC,QAAQ,EAAE,eAAe,EACzB,OAAO,EAAE,MAAM,GACd,MAAM,EAAE,CAEV;AAED,wBAAgB,sBAAsB,CACpC,QAAQ,EAAE,eAAe,EACzB,QAAQ,EAAE,MAAM,GACf,MAAM,CAkBR;AACD,wBAAsB,cAAc,CAClC,QAAQ,EAAE,eAAe,GACxB,OAAO,CAAC,MAAM,CAAC,CAQjB;AAED,wBAAgB,eAAe,CAAC,CAAC,EAAE,MAAM,EAAE,CAAC,EAAE,MAAM,GAAG,MAAM,CAE5D"}
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/esm/browser-data/chromium.js b/node_modules/@puppeteer/browsers/lib/esm/browser-data/chromium.js
new file mode 100644
index 0000000..f49873a
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/esm/browser-data/chromium.js
@@ -0,0 +1,63 @@
+/**
+ * @license
+ * Copyright 2023 Google Inc.
+ * SPDX-License-Identifier: Apache-2.0
+ */
+import path from 'node:path';
+import { getText } from '../httpUtil.js';
+import { BrowserPlatform } from './types.js';
+function archive(platform, buildId) {
+ switch (platform) {
+ case BrowserPlatform.LINUX_ARM:
+ case BrowserPlatform.LINUX:
+ return 'chrome-linux';
+ case BrowserPlatform.MAC_ARM:
+ case BrowserPlatform.MAC:
+ return 'chrome-mac';
+ case BrowserPlatform.WIN32:
+ case BrowserPlatform.WIN64:
+ // Windows archive name changed at r591479.
+ return parseInt(buildId, 10) > 591479 ? 'chrome-win' : 'chrome-win32';
+ }
+}
+function folder(platform) {
+ switch (platform) {
+ case BrowserPlatform.LINUX_ARM:
+ case BrowserPlatform.LINUX:
+ return 'Linux_x64';
+ case BrowserPlatform.MAC_ARM:
+ return 'Mac_Arm';
+ case BrowserPlatform.MAC:
+ return 'Mac';
+ case BrowserPlatform.WIN32:
+ return 'Win';
+ case BrowserPlatform.WIN64:
+ return 'Win_x64';
+ }
+}
+export function resolveDownloadUrl(platform, buildId, baseUrl = 'https://storage.googleapis.com/chromium-browser-snapshots') {
+ return `${baseUrl}/${resolveDownloadPath(platform, buildId).join('/')}`;
+}
+export function resolveDownloadPath(platform, buildId) {
+ return [folder(platform), buildId, `${archive(platform, buildId)}.zip`];
+}
+export function relativeExecutablePath(platform, _buildId) {
+ switch (platform) {
+ case BrowserPlatform.MAC:
+ case BrowserPlatform.MAC_ARM:
+ return path.join('chrome-mac', 'Chromium.app', 'Contents', 'MacOS', 'Chromium');
+ case BrowserPlatform.LINUX_ARM:
+ case BrowserPlatform.LINUX:
+ return path.join('chrome-linux', 'chrome');
+ case BrowserPlatform.WIN32:
+ case BrowserPlatform.WIN64:
+ return path.join('chrome-win', 'chrome.exe');
+ }
+}
+export async function resolveBuildId(platform) {
+ return await getText(new URL(`https://storage.googleapis.com/chromium-browser-snapshots/${folder(platform)}/LAST_CHANGE`));
+}
+export function compareVersions(a, b) {
+ return Number(a) - Number(b);
+}
+//# sourceMappingURL=chromium.js.map
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/esm/browser-data/chromium.js.map b/node_modules/@puppeteer/browsers/lib/esm/browser-data/chromium.js.map
new file mode 100644
index 0000000..e4f255f
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/esm/browser-data/chromium.js.map
@@ -0,0 +1 @@
+{"version":3,"file":"chromium.js","sourceRoot":"","sources":["../../../src/browser-data/chromium.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,OAAO,IAAI,MAAM,WAAW,CAAC;AAE7B,OAAO,EAAC,OAAO,EAAC,MAAM,gBAAgB,CAAC;AAEvC,OAAO,EAAC,eAAe,EAAC,MAAM,YAAY,CAAC;AAE3C,SAAS,OAAO,CAAC,QAAyB,EAAE,OAAe;IACzD,QAAQ,QAAQ,EAAE,CAAC;QACjB,KAAK,eAAe,CAAC,SAAS,CAAC;QAC/B,KAAK,eAAe,CAAC,KAAK;YACxB,OAAO,cAAc,CAAC;QACxB,KAAK,eAAe,CAAC,OAAO,CAAC;QAC7B,KAAK,eAAe,CAAC,GAAG;YACtB,OAAO,YAAY,CAAC;QACtB,KAAK,eAAe,CAAC,KAAK,CAAC;QAC3B,KAAK,eAAe,CAAC,KAAK;YACxB,2CAA2C;YAC3C,OAAO,QAAQ,CAAC,OAAO,EAAE,EAAE,CAAC,GAAG,MAAM,CAAC,CAAC,CAAC,YAAY,CAAC,CAAC,CAAC,cAAc,CAAC;IAC1E,CAAC;AACH,CAAC;AAED,SAAS,MAAM,CAAC,QAAyB;IACvC,QAAQ,QAAQ,EAAE,CAAC;QACjB,KAAK,eAAe,CAAC,SAAS,CAAC;QAC/B,KAAK,eAAe,CAAC,KAAK;YACxB,OAAO,WAAW,CAAC;QACrB,KAAK,eAAe,CAAC,OAAO;YAC1B,OAAO,SAAS,CAAC;QACnB,KAAK,eAAe,CAAC,GAAG;YACtB,OAAO,KAAK,CAAC;QACf,KAAK,eAAe,CAAC,KAAK;YACxB,OAAO,KAAK,CAAC;QACf,KAAK,eAAe,CAAC,KAAK;YACxB,OAAO,SAAS,CAAC;IACrB,CAAC;AACH,CAAC;AAED,MAAM,UA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/node_modules/@puppeteer/browsers/lib/esm/browser-data/firefox.d.ts b/node_modules/@puppeteer/browsers/lib/esm/browser-data/firefox.d.ts
new file mode 100644
index 0000000..447f91d
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/esm/browser-data/firefox.d.ts
@@ -0,0 +1,20 @@
+/**
+ * @license
+ * Copyright 2023 Google Inc.
+ * SPDX-License-Identifier: Apache-2.0
+ */
+import { BrowserPlatform, type ProfileOptions } from './types.js';
+export declare function resolveDownloadUrl(platform: BrowserPlatform, buildId: string, baseUrl?: string): string;
+export declare function resolveDownloadPath(platform: BrowserPlatform, buildId: string): string[];
+export declare function relativeExecutablePath(platform: BrowserPlatform, buildId: string): string;
+export declare enum FirefoxChannel {
+ STABLE = "stable",
+ ESR = "esr",
+ DEVEDITION = "devedition",
+ BETA = "beta",
+ NIGHTLY = "nightly"
+}
+export declare function resolveBuildId(channel?: FirefoxChannel): Promise;
+export declare function createProfile(options: ProfileOptions): Promise;
+export declare function compareVersions(a: string, b: string): number;
+//# sourceMappingURL=firefox.d.ts.map
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/esm/browser-data/firefox.d.ts.map b/node_modules/@puppeteer/browsers/lib/esm/browser-data/firefox.d.ts.map
new file mode 100644
index 0000000..259341b
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/esm/browser-data/firefox.d.ts.map
@@ -0,0 +1 @@
+{"version":3,"file":"firefox.d.ts","sourceRoot":"","sources":["../../../src/browser-data/firefox.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAOH,OAAO,EAAC,eAAe,EAAE,KAAK,cAAc,EAAC,MAAM,YAAY,CAAC;AA8DhE,wBAAgB,kBAAkB,CAChC,QAAQ,EAAE,eAAe,EACzB,OAAO,EAAE,MAAM,EACf,OAAO,CAAC,EAAE,MAAM,GACf,MAAM,CAiBR;AAED,wBAAgB,mBAAmB,CACjC,QAAQ,EAAE,eAAe,EACzB,OAAO,EAAE,MAAM,GACd,MAAM,EAAE,CAgBV;AAED,wBAAgB,sBAAsB,CACpC,QAAQ,EAAE,eAAe,EACzB,OAAO,EAAE,MAAM,GACd,MAAM,CAoCR;AAED,oBAAY,cAAc;IACxB,MAAM,WAAW;IACjB,GAAG,QAAQ;IACX,UAAU,eAAe;IACzB,IAAI,SAAS;IACb,OAAO,YAAY;CACpB;AAED,wBAAsB,cAAc,CAClC,OAAO,GAAE,cAAuC,GAC/C,OAAO,CAAC,MAAM,CAAC,CAgBjB;AAED,wBAAsB,aAAa,CAAC,OAAO,EAAE,cAAc,GAAG,OAAO,CAAC,IAAI,CAAC,CAa1E;AAkQD,wBAAgB,eAAe,CAAC,CAAC,EAAE,MAAM,EAAE,CAAC,EAAE,MAAM,GAAG,MAAM,CAG5D"}
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/esm/browser-data/firefox.js b/node_modules/@puppeteer/browsers/lib/esm/browser-data/firefox.js
new file mode 100644
index 0000000..293cc12
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/esm/browser-data/firefox.js
@@ -0,0 +1,369 @@
+/**
+ * @license
+ * Copyright 2023 Google Inc.
+ * SPDX-License-Identifier: Apache-2.0
+ */
+import fs from 'node:fs';
+import path from 'node:path';
+import { getJSON } from '../httpUtil.js';
+import { BrowserPlatform } from './types.js';
+function getFormat(buildId) {
+ const majorVersion = Number(buildId.split('.').shift());
+ return majorVersion >= 135 ? 'xz' : 'bz2';
+}
+function archiveNightly(platform, buildId) {
+ switch (platform) {
+ case BrowserPlatform.LINUX:
+ return `firefox-${buildId}.en-US.linux-x86_64.tar.${getFormat(buildId)}`;
+ case BrowserPlatform.LINUX_ARM:
+ return `firefox-${buildId}.en-US.linux-aarch64.tar.${getFormat(buildId)}`;
+ case BrowserPlatform.MAC_ARM:
+ case BrowserPlatform.MAC:
+ return `firefox-${buildId}.en-US.mac.dmg`;
+ case BrowserPlatform.WIN32:
+ case BrowserPlatform.WIN64:
+ return `firefox-${buildId}.en-US.${platform}.zip`;
+ }
+}
+function archive(platform, buildId) {
+ switch (platform) {
+ case BrowserPlatform.LINUX_ARM:
+ case BrowserPlatform.LINUX:
+ return `firefox-${buildId}.tar.${getFormat(buildId)}`;
+ case BrowserPlatform.MAC_ARM:
+ case BrowserPlatform.MAC:
+ return `Firefox ${buildId}.dmg`;
+ case BrowserPlatform.WIN32:
+ case BrowserPlatform.WIN64:
+ return `Firefox Setup ${buildId}.exe`;
+ }
+}
+function platformName(platform) {
+ switch (platform) {
+ case BrowserPlatform.LINUX:
+ return `linux-x86_64`;
+ case BrowserPlatform.LINUX_ARM:
+ return `linux-aarch64`;
+ case BrowserPlatform.MAC_ARM:
+ case BrowserPlatform.MAC:
+ return `mac`;
+ case BrowserPlatform.WIN32:
+ case BrowserPlatform.WIN64:
+ return platform;
+ }
+}
+function parseBuildId(buildId) {
+ for (const value of Object.values(FirefoxChannel)) {
+ if (buildId.startsWith(value + '_')) {
+ buildId = buildId.substring(value.length + 1);
+ return [value, buildId];
+ }
+ }
+ // Older versions do not have channel as the prefix.«
+ return [FirefoxChannel.NIGHTLY, buildId];
+}
+export function resolveDownloadUrl(platform, buildId, baseUrl) {
+ const [channel] = parseBuildId(buildId);
+ switch (channel) {
+ case FirefoxChannel.NIGHTLY:
+ baseUrl ??=
+ 'https://archive.mozilla.org/pub/firefox/nightly/latest-mozilla-central';
+ break;
+ case FirefoxChannel.DEVEDITION:
+ baseUrl ??= 'https://archive.mozilla.org/pub/devedition/releases';
+ break;
+ case FirefoxChannel.BETA:
+ case FirefoxChannel.STABLE:
+ case FirefoxChannel.ESR:
+ baseUrl ??= 'https://archive.mozilla.org/pub/firefox/releases';
+ break;
+ }
+ return `${baseUrl}/${resolveDownloadPath(platform, buildId).join('/')}`;
+}
+export function resolveDownloadPath(platform, buildId) {
+ const [channel, resolvedBuildId] = parseBuildId(buildId);
+ switch (channel) {
+ case FirefoxChannel.NIGHTLY:
+ return [archiveNightly(platform, resolvedBuildId)];
+ case FirefoxChannel.DEVEDITION:
+ case FirefoxChannel.BETA:
+ case FirefoxChannel.STABLE:
+ case FirefoxChannel.ESR:
+ return [
+ resolvedBuildId,
+ platformName(platform),
+ 'en-US',
+ archive(platform, resolvedBuildId),
+ ];
+ }
+}
+export function relativeExecutablePath(platform, buildId) {
+ const [channel] = parseBuildId(buildId);
+ switch (channel) {
+ case FirefoxChannel.NIGHTLY:
+ switch (platform) {
+ case BrowserPlatform.MAC_ARM:
+ case BrowserPlatform.MAC:
+ return path.join('Firefox Nightly.app', 'Contents', 'MacOS', 'firefox');
+ case BrowserPlatform.LINUX_ARM:
+ case BrowserPlatform.LINUX:
+ return path.join('firefox', 'firefox');
+ case BrowserPlatform.WIN32:
+ case BrowserPlatform.WIN64:
+ return path.join('firefox', 'firefox.exe');
+ }
+ case FirefoxChannel.BETA:
+ case FirefoxChannel.DEVEDITION:
+ case FirefoxChannel.ESR:
+ case FirefoxChannel.STABLE:
+ switch (platform) {
+ case BrowserPlatform.MAC_ARM:
+ case BrowserPlatform.MAC:
+ return path.join('Firefox.app', 'Contents', 'MacOS', 'firefox');
+ case BrowserPlatform.LINUX_ARM:
+ case BrowserPlatform.LINUX:
+ return path.join('firefox', 'firefox');
+ case BrowserPlatform.WIN32:
+ case BrowserPlatform.WIN64:
+ return path.join('core', 'firefox.exe');
+ }
+ }
+}
+export var FirefoxChannel;
+(function (FirefoxChannel) {
+ FirefoxChannel["STABLE"] = "stable";
+ FirefoxChannel["ESR"] = "esr";
+ FirefoxChannel["DEVEDITION"] = "devedition";
+ FirefoxChannel["BETA"] = "beta";
+ FirefoxChannel["NIGHTLY"] = "nightly";
+})(FirefoxChannel || (FirefoxChannel = {}));
+export async function resolveBuildId(channel = FirefoxChannel.NIGHTLY) {
+ const channelToVersionKey = {
+ [FirefoxChannel.ESR]: 'FIREFOX_ESR',
+ [FirefoxChannel.STABLE]: 'LATEST_FIREFOX_VERSION',
+ [FirefoxChannel.DEVEDITION]: 'FIREFOX_DEVEDITION',
+ [FirefoxChannel.BETA]: 'FIREFOX_DEVEDITION',
+ [FirefoxChannel.NIGHTLY]: 'FIREFOX_NIGHTLY',
+ };
+ const versions = (await getJSON(new URL('https://product-details.mozilla.org/1.0/firefox_versions.json')));
+ const version = versions[channelToVersionKey[channel]];
+ if (!version) {
+ throw new Error(`Channel ${channel} is not found.`);
+ }
+ return channel + '_' + version;
+}
+export async function createProfile(options) {
+ if (!fs.existsSync(options.path)) {
+ await fs.promises.mkdir(options.path, {
+ recursive: true,
+ });
+ }
+ await syncPreferences({
+ preferences: {
+ ...defaultProfilePreferences(options.preferences),
+ ...options.preferences,
+ },
+ path: options.path,
+ });
+}
+function defaultProfilePreferences(extraPrefs) {
+ const server = 'dummy.test';
+ const defaultPrefs = {
+ // Make sure Shield doesn't hit the network.
+ 'app.normandy.api_url': '',
+ // Disable Firefox old build background check
+ 'app.update.checkInstallTime': false,
+ // Disable automatically upgrading Firefox
+ 'app.update.disabledForTesting': true,
+ // Increase the APZ content response timeout to 1 minute
+ 'apz.content_response_timeout': 60000,
+ // Disables backup service to improve startup performance and stability. See
+ // https://github.com/puppeteer/puppeteer/issues/14194. TODO: can be removed
+ // once the service is disabled on the Firefox side for WebDriver (see
+ // https://bugzilla.mozilla.org/show_bug.cgi?id=1988250).
+ 'browser.backup.enabled': false,
+ // Prevent various error message on the console
+ // jest-puppeteer asserts that no error message is emitted by the console
+ 'browser.contentblocking.features.standard': '-tp,tpPrivate,cookieBehavior0,-cryptoTP,-fp',
+ // Enable the dump function: which sends messages to the system
+ // console
+ // https://bugzilla.mozilla.org/show_bug.cgi?id=1543115
+ 'browser.dom.window.dump.enabled': true,
+ // Disable topstories
+ 'browser.newtabpage.activity-stream.feeds.system.topstories': false,
+ // Always display a blank page
+ 'browser.newtabpage.enabled': false,
+ // Background thumbnails in particular cause grief: and disabling
+ // thumbnails in general cannot hurt
+ 'browser.pagethumbnails.capturing_disabled': true,
+ // Disable safebrowsing components.
+ 'browser.safebrowsing.blockedURIs.enabled': false,
+ 'browser.safebrowsing.downloads.enabled': false,
+ 'browser.safebrowsing.malware.enabled': false,
+ 'browser.safebrowsing.phishing.enabled': false,
+ // Disable updates to search engines.
+ 'browser.search.update': false,
+ // Do not restore the last open set of tabs if the browser has crashed
+ 'browser.sessionstore.resume_from_crash': false,
+ // Skip check for default browser on startup
+ 'browser.shell.checkDefaultBrowser': false,
+ // Disable newtabpage
+ 'browser.startup.homepage': 'about:blank',
+ // Do not redirect user when a milstone upgrade of Firefox is detected
+ 'browser.startup.homepage_override.mstone': 'ignore',
+ // Start with a blank page about:blank
+ 'browser.startup.page': 0,
+ // Do not allow background tabs to be zombified on Android: otherwise for
+ // tests that open additional tabs: the test harness tab itself might get
+ // unloaded
+ 'browser.tabs.disableBackgroundZombification': false,
+ // Do not warn when closing all other open tabs
+ 'browser.tabs.warnOnCloseOtherTabs': false,
+ // Do not warn when multiple tabs will be opened
+ 'browser.tabs.warnOnOpen': false,
+ // Do not automatically offer translations, as tests do not expect this.
+ 'browser.translations.automaticallyPopup': false,
+ // Disable the UI tour.
+ 'browser.uitour.enabled': false,
+ // Turn off search suggestions in the location bar so as not to trigger
+ // network connections.
+ 'browser.urlbar.suggest.searches': false,
+ // Disable first run splash page on Windows 10
+ 'browser.usedOnWindows10.introURL': '',
+ // Do not warn on quitting Firefox
+ 'browser.warnOnQuit': false,
+ // Defensively disable data reporting systems
+ 'datareporting.healthreport.documentServerURI': `http://${server}/dummy/healthreport/`,
+ 'datareporting.healthreport.logging.consoleEnabled': false,
+ 'datareporting.healthreport.service.enabled': false,
+ 'datareporting.healthreport.service.firstRun': false,
+ 'datareporting.healthreport.uploadEnabled': false,
+ // Do not show datareporting policy notifications which can interfere with tests
+ 'datareporting.policy.dataSubmissionEnabled': false,
+ 'datareporting.policy.dataSubmissionPolicyBypassNotification': true,
+ // DevTools JSONViewer sometimes fails to load dependencies with its require.js.
+ // This doesn't affect Puppeteer but spams console (Bug 1424372)
+ 'devtools.jsonview.enabled': false,
+ // Disable popup-blocker
+ 'dom.disable_open_during_load': false,
+ // Enable the support for File object creation in the content process
+ // Required for |Page.setFileInputFiles| protocol method.
+ 'dom.file.createInChild': true,
+ // Disable the ProcessHangMonitor
+ 'dom.ipc.reportProcessHangs': false,
+ // Disable slow script dialogues
+ 'dom.max_chrome_script_run_time': 0,
+ 'dom.max_script_run_time': 0,
+ // Only load extensions from the application and user profile
+ // AddonManager.SCOPE_PROFILE + AddonManager.SCOPE_APPLICATION
+ 'extensions.autoDisableScopes': 0,
+ 'extensions.enabledScopes': 5,
+ // Disable metadata caching for installed add-ons by default
+ 'extensions.getAddons.cache.enabled': false,
+ // Disable installing any distribution extensions or add-ons.
+ 'extensions.installDistroAddons': false,
+ // Turn off extension updates so they do not bother tests
+ 'extensions.update.enabled': false,
+ // Turn off extension updates so they do not bother tests
+ 'extensions.update.notifyUser': false,
+ // Make sure opening about:addons will not hit the network
+ 'extensions.webservice.discoverURL': `http://${server}/dummy/discoveryURL`,
+ // Allow the application to have focus even it runs in the background
+ 'focusmanager.testmode': true,
+ // Disable useragent updates
+ 'general.useragent.updates.enabled': false,
+ // Always use network provider for geolocation tests so we bypass the
+ // macOS dialog raised by the corelocation provider
+ 'geo.provider.testing': true,
+ // Do not scan Wifi
+ 'geo.wifi.scan': false,
+ // No hang monitor
+ 'hangmonitor.timeout': 0,
+ // Show chrome errors and warnings in the error console
+ 'javascript.options.showInConsole': true,
+ // Disable download and usage of OpenH264: and Widevine plugins
+ 'media.gmp-manager.updateEnabled': false,
+ // Disable the GFX sanity window
+ 'media.sanity-test.disabled': true,
+ // Disable experimental feature that is only available in Nightly
+ 'network.cookie.sameSite.laxByDefault': false,
+ // Do not prompt for temporary redirects
+ 'network.http.prompt-temp-redirect': false,
+ // Disable speculative connections so they are not reported as leaking
+ // when they are hanging around
+ 'network.http.speculative-parallel-limit': 0,
+ // Do not automatically switch between offline and online
+ 'network.manage-offline-status': false,
+ // Make sure SNTP requests do not hit the network
+ 'network.sntp.pools': server,
+ // Disable Flash.
+ 'plugin.state.flash': 0,
+ 'privacy.trackingprotection.enabled': false,
+ // Can be removed once Firefox 89 is no longer supported
+ // https://bugzilla.mozilla.org/show_bug.cgi?id=1710839
+ 'remote.enabled': true,
+ // Disabled screenshots component
+ 'screenshots.browser.component.enabled': false,
+ // Don't do network connections for mitm priming
+ 'security.certerrors.mitm.priming.enabled': false,
+ // Local documents have access to all other local documents,
+ // including directory listings
+ 'security.fileuri.strict_origin_policy': false,
+ // Do not wait for the notification button security delay
+ 'security.notification_enable_delay': 0,
+ // Ensure blocklist updates do not hit the network
+ 'services.settings.server': `http://${server}/dummy/blocklist/`,
+ // Do not automatically fill sign-in forms with known usernames and
+ // passwords
+ 'signon.autofillForms': false,
+ // Disable password capture, so that tests that include forms are not
+ // influenced by the presence of the persistent doorhanger notification
+ 'signon.rememberSignons': false,
+ // Disable first-run welcome page
+ 'startup.homepage_welcome_url': 'about:blank',
+ // Disable first-run welcome page
+ 'startup.homepage_welcome_url.additional': '',
+ // Disable browser animations (tabs, fullscreen, sliding alerts)
+ 'toolkit.cosmeticAnimations.enabled': false,
+ // Prevent starting into safe mode after application crashes
+ 'toolkit.startup.max_resumed_crashes': -1,
+ };
+ return Object.assign(defaultPrefs, extraPrefs);
+}
+async function backupFile(input) {
+ if (!fs.existsSync(input)) {
+ return;
+ }
+ await fs.promises.copyFile(input, input + '.puppeteer');
+}
+/**
+ * Populates the user.js file with custom preferences as needed to allow
+ * Firefox's support to properly function. These preferences will be
+ * automatically copied over to prefs.js during startup of Firefox. To be
+ * able to restore the original values of preferences a backup of prefs.js
+ * will be created.
+ */
+async function syncPreferences(options) {
+ const prefsPath = path.join(options.path, 'prefs.js');
+ const userPath = path.join(options.path, 'user.js');
+ const lines = Object.entries(options.preferences).map(([key, value]) => {
+ return `user_pref(${JSON.stringify(key)}, ${JSON.stringify(value)});`;
+ });
+ // Use allSettled to prevent corruption.
+ const result = await Promise.allSettled([
+ backupFile(userPath).then(async () => {
+ await fs.promises.writeFile(userPath, lines.join('\n'));
+ }),
+ backupFile(prefsPath),
+ ]);
+ for (const command of result) {
+ if (command.status === 'rejected') {
+ throw command.reason;
+ }
+ }
+}
+export function compareVersions(a, b) {
+ // TODO: this is a not very reliable check.
+ return parseInt(a.replace('.', ''), 16) - parseInt(b.replace('.', ''), 16);
+}
+//# sourceMappingURL=firefox.js.map
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/esm/browser-data/firefox.js.map b/node_modules/@puppeteer/browsers/lib/esm/browser-data/firefox.js.map
new file mode 100644
index 0000000..ca7a21e
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/esm/browser-data/firefox.js.map
@@ -0,0 +1 @@
+{"version":3,"file":"firefox.js","sourceRoot":"","sources":["../../../src/browser-data/firefox.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,OAAO,EAAE,MAAM,SAAS,CAAC;AACzB,OAAO,IAAI,MAAM,WAAW,CAAC;AAE7B,OAAO,EAAC,OAAO,EAAC,MAAM,gBAAgB,CAAC;AAEvC,OAAO,EAAC,eAAe,EAAsB,MAAM,YAAY,CAAC;AAEhE,SAAS,SAAS,CAAC,OAAe;IAChC,MAAM,YAAY,GAAG,MAAM,CAAC,OAAO,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC,KAAK,EAAG,CAAC,CAAC;IACzD,OAAO,YAAY,IAAI,GAAG,CAAC,CAAC,CAAC,IAAI,CAAC,CAAC,CAAC,KAAK,CAAC;AAC5C,CAAC;AAED,SAAS,cAAc,CAAC,QAAyB,EAAE,OAAe;IAChE,QAAQ,QAAQ,EAAE,CAAC;QACjB,KAAK,eAAe,CAAC,KAAK;YACxB,OAAO,WAAW,OAAO,2BAA2B,SAAS,CAAC,OAAO,CAAC,EAAE,CAAC;QAC3E,KAAK,eAAe,CAAC,SAAS;YAC5B,OAAO,WAAW,OAAO,4BAA4B,SAAS,CAAC,OAAO,CAAC,EAAE,CAAC;QAC5E,KAAK,eAAe,CAAC,OAAO,CAAC;QAC7B,KAAK,eAAe,CAAC,GAAG;Y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AO,CAAC,MAAM,CAAC;QACvB,CAAC;IACH,CAAC;AACH,CAAC;AAED,MAAM,UAAU,eAAe,CAAC,CAAS,EAAE,CAAS;IAClD,2CAA2C;IAC3C,OAAO,QAAQ,CAAC,CAAC,CAAC,OAAO,CAAC,GAAG,EAAE,EAAE,CAAC,EAAE,EAAE,CAAC,GAAG,QAAQ,CAAC,CAAC,CAAC,OAAO,CAAC,GAAG,EAAE,EAAE,CAAC,EAAE,EAAE,CAAC,CAAC;AAC7E,CAAC"}
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/esm/browser-data/types.d.ts b/node_modules/@puppeteer/browsers/lib/esm/browser-data/types.d.ts
new file mode 100644
index 0000000..a1aaecc
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/esm/browser-data/types.d.ts
@@ -0,0 +1,66 @@
+/**
+ * @license
+ * Copyright 2023 Google Inc.
+ * SPDX-License-Identifier: Apache-2.0
+ */
+/**
+ * Supported browsers.
+ *
+ * @public
+ */
+export declare enum Browser {
+ CHROME = "chrome",
+ CHROMEHEADLESSSHELL = "chrome-headless-shell",
+ CHROMIUM = "chromium",
+ FIREFOX = "firefox",
+ CHROMEDRIVER = "chromedriver"
+}
+/**
+ * Platform names used to identify a OS platform x architecture combination in the way
+ * that is relevant for the browser download.
+ *
+ * @public
+ */
+export declare enum BrowserPlatform {
+ LINUX = "linux",
+ LINUX_ARM = "linux_arm",
+ MAC = "mac",
+ MAC_ARM = "mac_arm",
+ WIN32 = "win32",
+ WIN64 = "win64"
+}
+/**
+ * Enum describing a release channel for a browser.
+ *
+ * You can use this in combination with {@link resolveBuildId} to resolve
+ * a build ID based on a release channel.
+ *
+ * @public
+ */
+export declare enum BrowserTag {
+ CANARY = "canary",
+ NIGHTLY = "nightly",
+ BETA = "beta",
+ DEV = "dev",
+ DEVEDITION = "devedition",
+ STABLE = "stable",
+ ESR = "esr",
+ LATEST = "latest"
+}
+/**
+ * @public
+ */
+export interface ProfileOptions {
+ preferences: Record;
+ path: string;
+}
+/**
+ * @public
+ */
+export declare enum ChromeReleaseChannel {
+ STABLE = "stable",
+ DEV = "dev",
+ CANARY = "canary",
+ BETA = "beta"
+}
+//# sourceMappingURL=types.d.ts.map
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/esm/browser-data/types.d.ts.map b/node_modules/@puppeteer/browsers/lib/esm/browser-data/types.d.ts.map
new file mode 100644
index 0000000..9a647cd
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/esm/browser-data/types.d.ts.map
@@ -0,0 +1 @@
+{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../src/browser-data/types.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH;;;;GAIG;AACH,oBAAY,OAAO;IACjB,MAAM,WAAW;IACjB,mBAAmB,0BAA0B;IAC7C,QAAQ,aAAa;IACrB,OAAO,YAAY;IACnB,YAAY,iBAAiB;CAC9B;AAED;;;;;GAKG;AACH,oBAAY,eAAe;IACzB,KAAK,UAAU;IACf,SAAS,cAAc;IACvB,GAAG,QAAQ;IACX,OAAO,YAAY;IACnB,KAAK,UAAU;IACf,KAAK,UAAU;CAChB;AAED;;;;;;;GAOG;AACH,oBAAY,UAAU;IACpB,MAAM,WAAW;IACjB,OAAO,YAAY;IACnB,IAAI,SAAS;IACb,GAAG,QAAQ;IACX,UAAU,eAAe;IACzB,MAAM,WAAW;IACjB,GAAG,QAAQ;IACX,MAAM,WAAW;CAClB;AAED;;GAEG;AACH,MAAM,WAAW,cAAc;IAC7B,WAAW,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;IACrC,IAAI,EAAE,MAAM,CAAC;CACd;AAED;;GAEG;AACH,oBAAY,oBAAoB;IAC9B,MAAM,WAAW;IACjB,GAAG,QAAQ;IACX,MAAM,WAAW;IACjB,IAAI,SAAS;CACd"}
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/esm/browser-data/types.js b/node_modules/@puppeteer/browsers/lib/esm/browser-data/types.js
new file mode 100644
index 0000000..d71aae8
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/esm/browser-data/types.js
@@ -0,0 +1,63 @@
+/**
+ * @license
+ * Copyright 2023 Google Inc.
+ * SPDX-License-Identifier: Apache-2.0
+ */
+/**
+ * Supported browsers.
+ *
+ * @public
+ */
+export var Browser;
+(function (Browser) {
+ Browser["CHROME"] = "chrome";
+ Browser["CHROMEHEADLESSSHELL"] = "chrome-headless-shell";
+ Browser["CHROMIUM"] = "chromium";
+ Browser["FIREFOX"] = "firefox";
+ Browser["CHROMEDRIVER"] = "chromedriver";
+})(Browser || (Browser = {}));
+/**
+ * Platform names used to identify a OS platform x architecture combination in the way
+ * that is relevant for the browser download.
+ *
+ * @public
+ */
+export var BrowserPlatform;
+(function (BrowserPlatform) {
+ BrowserPlatform["LINUX"] = "linux";
+ BrowserPlatform["LINUX_ARM"] = "linux_arm";
+ BrowserPlatform["MAC"] = "mac";
+ BrowserPlatform["MAC_ARM"] = "mac_arm";
+ BrowserPlatform["WIN32"] = "win32";
+ BrowserPlatform["WIN64"] = "win64";
+})(BrowserPlatform || (BrowserPlatform = {}));
+/**
+ * Enum describing a release channel for a browser.
+ *
+ * You can use this in combination with {@link resolveBuildId} to resolve
+ * a build ID based on a release channel.
+ *
+ * @public
+ */
+export var BrowserTag;
+(function (BrowserTag) {
+ BrowserTag["CANARY"] = "canary";
+ BrowserTag["NIGHTLY"] = "nightly";
+ BrowserTag["BETA"] = "beta";
+ BrowserTag["DEV"] = "dev";
+ BrowserTag["DEVEDITION"] = "devedition";
+ BrowserTag["STABLE"] = "stable";
+ BrowserTag["ESR"] = "esr";
+ BrowserTag["LATEST"] = "latest";
+})(BrowserTag || (BrowserTag = {}));
+/**
+ * @public
+ */
+export var ChromeReleaseChannel;
+(function (ChromeReleaseChannel) {
+ ChromeReleaseChannel["STABLE"] = "stable";
+ ChromeReleaseChannel["DEV"] = "dev";
+ ChromeReleaseChannel["CANARY"] = "canary";
+ ChromeReleaseChannel["BETA"] = "beta";
+})(ChromeReleaseChannel || (ChromeReleaseChannel = {}));
+//# sourceMappingURL=types.js.map
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/esm/browser-data/types.js.map b/node_modules/@puppeteer/browsers/lib/esm/browser-data/types.js.map
new file mode 100644
index 0000000..efa9f11
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/esm/browser-data/types.js.map
@@ -0,0 +1 @@
+{"version":3,"file":"types.js","sourceRoot":"","sources":["../../../src/browser-data/types.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH;;;;GAIG;AACH,MAAM,CAAN,IAAY,OAMX;AAND,WAAY,OAAO;IACjB,4BAAiB,CAAA;IACjB,wDAA6C,CAAA;IAC7C,gCAAqB,CAAA;IACrB,8BAAmB,CAAA;IACnB,wCAA6B,CAAA;AAC/B,CAAC,EANW,OAAO,KAAP,OAAO,QAMlB;AAED;;;;;GAKG;AACH,MAAM,CAAN,IAAY,eAOX;AAPD,WAAY,eAAe;IACzB,kCAAe,CAAA;IACf,0CAAuB,CAAA;IACvB,8BAAW,CAAA;IACX,sCAAmB,CAAA;IACnB,kCAAe,CAAA;IACf,kCAAe,CAAA;AACjB,CAAC,EAPW,eAAe,KAAf,eAAe,QAO1B;AAED;;;;;;;GAOG;AACH,MAAM,CAAN,IAAY,UASX;AATD,WAAY,UAAU;IACpB,+BAAiB,CAAA;IACjB,iCAAmB,CAAA;IACnB,2BAAa,CAAA;IACb,yBAAW,CAAA;IACX,uCAAyB,CAAA;IACzB,+BAAiB,CAAA;IACjB,yBAAW,CAAA;IACX,+BAAiB,CAAA;AACnB,CAAC,EATW,UAAU,KAAV,UAAU,QASrB;AAUD;;GAEG;AACH,MAAM,CAAN,IAAY,oBAKX;AALD,WAAY,oBAAoB;IAC9B,yCAAiB,CAAA;IACjB,mCAAW,CAAA;IACX,yCAAiB,CAAA;IACjB,qCAAa,CAAA;AACf,CAAC,EALW,oBAAoB,KAApB,oBAAoB,QAK/B"}
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/esm/debug.d.ts b/node_modules/@puppeteer/browsers/lib/esm/debug.d.ts
new file mode 100644
index 0000000..aa062da
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/esm/debug.d.ts
@@ -0,0 +1,8 @@
+/**
+ * @license
+ * Copyright 2023 Google Inc.
+ * SPDX-License-Identifier: Apache-2.0
+ */
+import debug from 'debug';
+export { debug };
+//# sourceMappingURL=debug.d.ts.map
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/esm/debug.d.ts.map b/node_modules/@puppeteer/browsers/lib/esm/debug.d.ts.map
new file mode 100644
index 0000000..2f5f252
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/esm/debug.d.ts.map
@@ -0,0 +1 @@
+{"version":3,"file":"debug.d.ts","sourceRoot":"","sources":["../../src/debug.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,OAAO,KAAK,MAAM,OAAO,CAAC;AAE1B,OAAO,EAAC,KAAK,EAAC,CAAC"}
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/esm/debug.js b/node_modules/@puppeteer/browsers/lib/esm/debug.js
new file mode 100644
index 0000000..6d7db6a
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/esm/debug.js
@@ -0,0 +1,8 @@
+/**
+ * @license
+ * Copyright 2023 Google Inc.
+ * SPDX-License-Identifier: Apache-2.0
+ */
+import debug from 'debug';
+export { debug };
+//# sourceMappingURL=debug.js.map
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/esm/debug.js.map b/node_modules/@puppeteer/browsers/lib/esm/debug.js.map
new file mode 100644
index 0000000..9351349
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/esm/debug.js.map
@@ -0,0 +1 @@
+{"version":3,"file":"debug.js","sourceRoot":"","sources":["../../src/debug.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,OAAO,KAAK,MAAM,OAAO,CAAC;AAE1B,OAAO,EAAC,KAAK,EAAC,CAAC"}
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/esm/detectPlatform.d.ts b/node_modules/@puppeteer/browsers/lib/esm/detectPlatform.d.ts
new file mode 100644
index 0000000..3ed4758
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/esm/detectPlatform.d.ts
@@ -0,0 +1,11 @@
+/**
+ * @license
+ * Copyright 2023 Google Inc.
+ * SPDX-License-Identifier: Apache-2.0
+ */
+import { BrowserPlatform } from './browser-data/browser-data.js';
+/**
+ * @public
+ */
+export declare function detectBrowserPlatform(): BrowserPlatform | undefined;
+//# sourceMappingURL=detectPlatform.d.ts.map
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/esm/detectPlatform.d.ts.map b/node_modules/@puppeteer/browsers/lib/esm/detectPlatform.d.ts.map
new file mode 100644
index 0000000..d71877b
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/esm/detectPlatform.d.ts.map
@@ -0,0 +1 @@
+{"version":3,"file":"detectPlatform.d.ts","sourceRoot":"","sources":["../../src/detectPlatform.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAIH,OAAO,EAAC,eAAe,EAAC,MAAM,gCAAgC,CAAC;AAE/D;;GAEG;AACH,wBAAgB,qBAAqB,IAAI,eAAe,GAAG,SAAS,CAmBnE"}
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/esm/detectPlatform.js b/node_modules/@puppeteer/browsers/lib/esm/detectPlatform.js
new file mode 100644
index 0000000..70113d8
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/esm/detectPlatform.js
@@ -0,0 +1,47 @@
+/**
+ * @license
+ * Copyright 2023 Google Inc.
+ * SPDX-License-Identifier: Apache-2.0
+ */
+import os from 'node:os';
+import { BrowserPlatform } from './browser-data/browser-data.js';
+/**
+ * @public
+ */
+export function detectBrowserPlatform() {
+ const platform = os.platform();
+ const arch = os.arch();
+ switch (platform) {
+ case 'darwin':
+ return arch === 'arm64' ? BrowserPlatform.MAC_ARM : BrowserPlatform.MAC;
+ case 'linux':
+ return arch === 'arm64'
+ ? BrowserPlatform.LINUX_ARM
+ : BrowserPlatform.LINUX;
+ case 'win32':
+ return arch === 'x64' ||
+ // Windows 11 for ARM supports x64 emulation
+ (arch === 'arm64' && isWindows11(os.release()))
+ ? BrowserPlatform.WIN64
+ : BrowserPlatform.WIN32;
+ default:
+ return undefined;
+ }
+}
+/**
+ * Windows 11 is identified by the version 10.0.22000 or greater
+ * @internal
+ */
+function isWindows11(version) {
+ const parts = version.split('.');
+ if (parts.length > 2) {
+ const major = parseInt(parts[0], 10);
+ const minor = parseInt(parts[1], 10);
+ const patch = parseInt(parts[2], 10);
+ return (major > 10 ||
+ (major === 10 && minor > 0) ||
+ (major === 10 && minor === 0 && patch >= 22000));
+ }
+ return false;
+}
+//# sourceMappingURL=detectPlatform.js.map
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/esm/detectPlatform.js.map b/node_modules/@puppeteer/browsers/lib/esm/detectPlatform.js.map
new file mode 100644
index 0000000..dfd3d0f
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/esm/detectPlatform.js.map
@@ -0,0 +1 @@
+{"version":3,"file":"detectPlatform.js","sourceRoot":"","sources":["../../src/detectPlatform.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,OAAO,EAAE,MAAM,SAAS,CAAC;AAEzB,OAAO,EAAC,eAAe,EAAC,MAAM,gCAAgC,CAAC;AAE/D;;GAEG;AACH,MAAM,UAAU,qBAAqB;IACnC,MAAM,QAAQ,GAAG,EAAE,CAAC,QAAQ,EAAE,CAAC;IAC/B,MAAM,IAAI,GAAG,EAAE,CAAC,IAAI,EAAE,CAAC;IACvB,QAAQ,QAAQ,EAAE,CAAC;QACjB,KAAK,QAAQ;YACX,OAAO,IAAI,KAAK,OAAO,CAAC,CAAC,CAAC,eAAe,CAAC,OAAO,CAAC,CAAC,CAAC,eAAe,CAAC,GAAG,CAAC;QAC1E,KAAK,OAAO;YACV,OAAO,IAAI,KAAK,OAAO;gBACrB,CAAC,CAAC,eAAe,CAAC,SAAS;gBAC3B,CAAC,CAAC,eAAe,CAAC,KAAK,CAAC;QAC5B,KAAK,OAAO;YACV,OAAO,IAAI,KAAK,KAAK;gBACnB,4CAA4C;gBAC5C,CAAC,IAAI,KAAK,OAAO,IAAI,WAAW,CAAC,EAAE,CAAC,OAAO,EAAE,CAAC,CAAC;gBAC/C,CAAC,CAAC,eAAe,CAAC,KAAK;gBACvB,CAAC,CAAC,eAAe,CAAC,KAAK,CAAC;QAC5B;YACE,OAAO,SAAS,CAAC;IACrB,CAAC;AACH,CAAC;AAED;;;GAGG;AACH,SAAS,WAAW,CAAC,OAAe;IAClC,MAAM,KAAK,GAAG,OAAO,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC;IACjC,IAAI,KAAK,CAAC,MAAM,GAAG,CAAC,EAAE,CAAC;QACrB,MAAM,KAAK,GAAG,QAAQ,CAAC,KAAK,CAAC,CAAC,CAAW,EAAE,EAAE,CAAC,CAAC;QAC/C,MAAM,KAAK,GAAG,QAAQ,CAAC,KAAK,CAAC,CAAC,CAAW,EAAE,EAAE,CAAC,CAAC;QAC/C,MAAM,KAAK,GAAG,QAAQ,CAAC,KAAK,CAAC,CAAC,CAAW,EAAE,EAAE,CAAC,CAAC;QAC/C,OAAO,CACL,KAAK,GAAG,EAAE;YACV,CAAC,KAAK,KAAK,EAAE,IAAI,KAAK,GAAG,CAAC,CAAC;YAC3B,CAAC,KAAK,KAAK,EAAE,IAAI,KAAK,KAAK,CAAC,IAAI,KAAK,IAAI,KAAK,CAAC,CAChD,CAAC;IACJ,CAAC;IACD,OAAO,KAAK,CAAC;AACf,CAAC"}
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/esm/fileUtil.d.ts b/node_modules/@puppeteer/browsers/lib/esm/fileUtil.d.ts
new file mode 100644
index 0000000..63b529c
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/esm/fileUtil.d.ts
@@ -0,0 +1,17 @@
+/**
+ * @license
+ * Copyright 2023 Google Inc.
+ * SPDX-License-Identifier: Apache-2.0
+ */
+/**
+ * @internal
+ */
+export declare function unpackArchive(archivePath: string, folderPath: string): Promise;
+/**
+ * @internal
+ */
+export declare const internalConstantsForTesting: {
+ xz: string;
+ bzip2: string;
+};
+//# sourceMappingURL=fileUtil.d.ts.map
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/esm/fileUtil.d.ts.map b/node_modules/@puppeteer/browsers/lib/esm/fileUtil.d.ts.map
new file mode 100644
index 0000000..cfa5ebe
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/esm/fileUtil.d.ts.map
@@ -0,0 +1 @@
+{"version":3,"file":"fileUtil.d.ts","sourceRoot":"","sources":["../../src/fileUtil.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAcH;;GAEG;AACH,wBAAsB,aAAa,CACjC,WAAW,EAAE,MAAM,EACnB,UAAU,EAAE,MAAM,GACjB,OAAO,CAAC,IAAI,CAAC,CA6Bf;AAgDD;;GAEG;AACH,eAAO,MAAM,2BAA2B;;;CAGvC,CAAC"}
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/esm/fileUtil.js b/node_modules/@puppeteer/browsers/lib/esm/fileUtil.js
new file mode 100644
index 0000000..0fdb25c
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/esm/fileUtil.js
@@ -0,0 +1,156 @@
+/**
+ * @license
+ * Copyright 2023 Google Inc.
+ * SPDX-License-Identifier: Apache-2.0
+ */
+import { spawnSync, spawn } from 'node:child_process';
+import { createReadStream } from 'node:fs';
+import { mkdir, readdir } from 'node:fs/promises';
+import * as path from 'node:path';
+import { Stream } from 'node:stream';
+import debug from 'debug';
+const debugFileUtil = debug('puppeteer:browsers:fileUtil');
+/**
+ * @internal
+ */
+export async function unpackArchive(archivePath, folderPath) {
+ if (!path.isAbsolute(folderPath)) {
+ folderPath = path.resolve(process.cwd(), folderPath);
+ }
+ if (archivePath.endsWith('.zip')) {
+ const extractZip = await import('extract-zip');
+ await extractZip.default(archivePath, { dir: folderPath });
+ }
+ else if (archivePath.endsWith('.tar.bz2')) {
+ await extractTar(archivePath, folderPath, 'bzip2');
+ }
+ else if (archivePath.endsWith('.dmg')) {
+ await mkdir(folderPath);
+ await installDMG(archivePath, folderPath);
+ }
+ else if (archivePath.endsWith('.exe')) {
+ // Firefox on Windows.
+ const result = spawnSync(archivePath, [`/ExtractDir=${folderPath}`], {
+ env: {
+ __compat_layer: 'RunAsInvoker',
+ },
+ });
+ if (result.status !== 0) {
+ throw new Error(`Failed to extract ${archivePath} to ${folderPath}: ${result.output}`);
+ }
+ }
+ else if (archivePath.endsWith('.tar.xz')) {
+ await extractTar(archivePath, folderPath, 'xz');
+ }
+ else {
+ throw new Error(`Unsupported archive format: ${archivePath}`);
+ }
+}
+function createTransformStream(child) {
+ const stream = new Stream.Transform({
+ transform(chunk, encoding, callback) {
+ if (!child.stdin.write(chunk, encoding)) {
+ child.stdin.once('drain', callback);
+ }
+ else {
+ callback();
+ }
+ },
+ flush(callback) {
+ if (child.stdout.destroyed) {
+ callback();
+ }
+ else {
+ child.stdin.end();
+ child.stdout.on('close', callback);
+ }
+ },
+ });
+ child.stdin.on('error', e => {
+ if ('code' in e && e.code === 'EPIPE') {
+ // finished before reading the file finished (i.e. head)
+ stream.emit('end');
+ }
+ else {
+ stream.destroy(e);
+ }
+ });
+ child.stdout
+ .on('data', data => {
+ return stream.push(data);
+ })
+ .on('error', e => {
+ return stream.destroy(e);
+ });
+ child.once('close', () => {
+ return stream.end();
+ });
+ return stream;
+}
+/**
+ * @internal
+ */
+export const internalConstantsForTesting = {
+ xz: 'xz',
+ bzip2: 'bzip2',
+};
+/**
+ * @internal
+ */
+async function extractTar(tarPath, folderPath, decompressUtilityName) {
+ const tarFs = await import('tar-fs');
+ return await new Promise((fulfill, reject) => {
+ function handleError(utilityName) {
+ return (error) => {
+ if ('code' in error && error.code === 'ENOENT') {
+ error = new Error(`\`${utilityName}\` utility is required to unpack this archive`, {
+ cause: error,
+ });
+ }
+ reject(error);
+ };
+ }
+ const unpack = spawn(internalConstantsForTesting[decompressUtilityName], ['-d'], {
+ stdio: ['pipe', 'pipe', 'inherit'],
+ })
+ .once('error', handleError(decompressUtilityName))
+ .once('exit', code => {
+ debugFileUtil(`${decompressUtilityName} exited, code=${code}`);
+ });
+ const tar = tarFs.extract(folderPath);
+ tar.once('error', handleError('tar'));
+ tar.once('finish', fulfill);
+ createReadStream(tarPath).pipe(createTransformStream(unpack)).pipe(tar);
+ });
+}
+/**
+ * @internal
+ */
+async function installDMG(dmgPath, folderPath) {
+ const { stdout } = spawnSync(`hdiutil`, [
+ 'attach',
+ '-nobrowse',
+ '-noautoopen',
+ dmgPath,
+ ]);
+ const volumes = stdout.toString('utf8').match(/\/Volumes\/(.*)/m);
+ if (!volumes) {
+ throw new Error(`Could not find volume path in ${stdout}`);
+ }
+ const mountPath = volumes[0];
+ try {
+ const fileNames = await readdir(mountPath);
+ const appName = fileNames.find(item => {
+ return typeof item === 'string' && item.endsWith('.app');
+ });
+ if (!appName) {
+ throw new Error(`Cannot find app in ${mountPath}`);
+ }
+ const mountedPath = path.join(mountPath, appName);
+ spawnSync('cp', ['-R', mountedPath, folderPath]);
+ }
+ finally {
+ spawnSync('hdiutil', ['detach', mountPath, '-quiet']);
+ }
+}
+//# sourceMappingURL=fileUtil.js.map
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/esm/fileUtil.js.map b/node_modules/@puppeteer/browsers/lib/esm/fileUtil.js.map
new file mode 100644
index 0000000..1c5c47a
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/esm/fileUtil.js.map
@@ -0,0 +1 @@
+{"version":3,"file":"fileUtil.js","sourceRoot":"","sources":["../../src/fileUtil.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAGH,OAAO,EAAC,SAAS,EAAE,K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C;IACD,MAAM,SAAS,GAAG,OAAO,CAAC,CAAC,CAAE,CAAC;IAE9B,IAAI,CAAC;QACH,MAAM,SAAS,GAAG,MAAM,OAAO,CAAC,SAAS,CAAC,CAAC;QAC3C,MAAM,OAAO,GAAG,SAAS,CAAC,IAAI,CAAC,IAAI,CAAC,EAAE;YACpC,OAAO,OAAO,IAAI,KAAK,QAAQ,IAAI,IAAI,CAAC,QAAQ,CAAC,MAAM,CAAC,CAAC;QAC3D,CAAC,CAAC,CAAC;QACH,IAAI,CAAC,OAAO,EAAE,CAAC;YACb,MAAM,IAAI,KAAK,CAAC,sBAAsB,SAAS,EAAE,CAAC,CAAC;QACrD,CAAC;QACD,MAAM,WAAW,GAAG,IAAI,CAAC,IAAI,CAAC,SAAU,EAAE,OAAO,CAAC,CAAC;QAEnD,SAAS,CAAC,IAAI,EAAE,CAAC,IAAI,EAAE,WAAW,EAAE,UAAU,CAAC,CAAC,CAAC;IACnD,CAAC;YAAS,CAAC;QACT,SAAS,CAAC,SAAS,EAAE,CAAC,QAAQ,EAAE,SAAS,EAAE,QAAQ,CAAC,CAAC,CAAC;IACxD,CAAC;AACH,CAAC"}
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/esm/generated/version.d.ts b/node_modules/@puppeteer/browsers/lib/esm/generated/version.d.ts
new file mode 100644
index 0000000..73db3f4
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/esm/generated/version.d.ts
@@ -0,0 +1,5 @@
+/**
+ * @internal
+ */
+export declare const packageVersion = "2.10.10";
+//# sourceMappingURL=version.d.ts.map
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/esm/generated/version.d.ts.map b/node_modules/@puppeteer/browsers/lib/esm/generated/version.d.ts.map
new file mode 100644
index 0000000..f1de697
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/esm/generated/version.d.ts.map
@@ -0,0 +1 @@
+{"version":3,"file":"version.d.ts","sourceRoot":"","sources":["../../../src/generated/version.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH,eAAO,MAAM,cAAc,YAAY,CAAC"}
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/esm/generated/version.js b/node_modules/@puppeteer/browsers/lib/esm/generated/version.js
new file mode 100644
index 0000000..f87531b
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/esm/generated/version.js
@@ -0,0 +1,5 @@
+/**
+ * @internal
+ */
+export const packageVersion = '2.10.10';
+//# sourceMappingURL=version.js.map
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/esm/generated/version.js.map b/node_modules/@puppeteer/browsers/lib/esm/generated/version.js.map
new file mode 100644
index 0000000..896d130
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/esm/generated/version.js.map
@@ -0,0 +1 @@
+{"version":3,"file":"version.js","sourceRoot":"","sources":["../../../src/generated/version.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH,MAAM,CAAC,MAAM,cAAc,GAAG,SAAS,CAAC"}
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/esm/httpUtil.d.ts b/node_modules/@puppeteer/browsers/lib/esm/httpUtil.d.ts
new file mode 100644
index 0000000..02c916a
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/esm/httpUtil.d.ts
@@ -0,0 +1,16 @@
+/**
+ * @license
+ * Copyright 2023 Google Inc.
+ * SPDX-License-Identifier: Apache-2.0
+ */
+import * as http from 'node:http';
+import { URL } from 'node:url';
+export declare function headHttpRequest(url: URL): Promise;
+export declare function httpRequest(url: URL, method: string, response: (x: http.IncomingMessage) => void, keepAlive?: boolean): http.ClientRequest;
+/**
+ * @internal
+ */
+export declare function downloadFile(url: URL, destinationPath: string, progressCallback?: (downloadedBytes: number, totalBytes: number) => void): Promise;
+export declare function getJSON(url: URL): Promise;
+export declare function getText(url: URL): Promise;
+//# sourceMappingURL=httpUtil.d.ts.map
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/esm/httpUtil.d.ts.map b/node_modules/@puppeteer/browsers/lib/esm/httpUtil.d.ts.map
new file mode 100644
index 0000000..c8eda85
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/esm/httpUtil.d.ts.map
@@ -0,0 +1 @@
+{"version":3,"file":"httpUtil.d.ts","sourceRoot":"","sources":["../../src/httpUtil.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAGH,OAAO,KAAK,IAAI,MAAM,WAAW,CAAC;AAElC,OAAO,EAAC,GAAG,EAAmB,MAAM,UAAU,CAAC;AAI/C,wBAAgB,eAAe,CAAC,GAAG,EAAE,GAAG,GAAG,OAAO,CAAC,OAAO,CAAC,CAgB1D;AAED,wBAAgB,WAAW,CACzB,GAAG,EAAE,GAAG,EACR,MAAM,EAAE,MAAM,EACd,QAAQ,EAAE,CAAC,CAAC,EAAE,IAAI,CAAC,eAAe,KAAK,IAAI,EAC3C,SAAS,UAAO,GACf,IAAI,CAAC,aAAa,CAiCpB;AAED;;GAEG;AACH,wBAAgB,YAAY,CAC1B,GAAG,EAAE,GAAG,EACR,eAAe,EAAE,MAAM,EACvB,gBAAgB,CAAC,EAAE,CAAC,eAAe,EAAE,MAAM,EAAE,UAAU,EAAE,MAAM,KAAK,IAAI,GACvE,OAAO,CAAC,IAAI,CAAC,CA6Cf;AAED,wBAAsB,OAAO,CAAC,GAAG,EAAE,GAAG,GAAG,OAAO,CAAC,OAAO,CAAC,CAOxD;AAED,wBAAgB,OAAO,CAAC,GAAG,EAAE,GAAG,GAAG,OAAO,CAAC,MAAM,CAAC,CA2BjD"}
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/esm/httpUtil.js b/node_modules/@puppeteer/browsers/lib/esm/httpUtil.js
new file mode 100644
index 0000000..79826b2
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/esm/httpUtil.js
@@ -0,0 +1,132 @@
+/**
+ * @license
+ * Copyright 2023 Google Inc.
+ * SPDX-License-Identifier: Apache-2.0
+ */
+import { createWriteStream } from 'node:fs';
+import * as http from 'node:http';
+import * as https from 'node:https';
+import { URL, urlToHttpOptions } from 'node:url';
+import { ProxyAgent } from 'proxy-agent';
+export function headHttpRequest(url) {
+ return new Promise(resolve => {
+ const request = httpRequest(url, 'HEAD', response => {
+ // consume response data free node process
+ response.resume();
+ resolve(response.statusCode === 200);
+ }, false);
+ request.on('error', () => {
+ resolve(false);
+ });
+ });
+}
+export function httpRequest(url, method, response, keepAlive = true) {
+ const options = {
+ protocol: url.protocol,
+ hostname: url.hostname,
+ port: url.port,
+ path: url.pathname + url.search,
+ method,
+ headers: keepAlive ? { Connection: 'keep-alive' } : undefined,
+ auth: urlToHttpOptions(url).auth,
+ agent: new ProxyAgent(),
+ };
+ const requestCallback = (res) => {
+ if (res.statusCode &&
+ res.statusCode >= 300 &&
+ res.statusCode < 400 &&
+ res.headers.location) {
+ httpRequest(new URL(res.headers.location), method, response);
+ // consume response data to free up memory
+ // And prevents the connection from being kept alive
+ res.resume();
+ }
+ else {
+ response(res);
+ }
+ };
+ const request = options.protocol === 'https:'
+ ? https.request(options, requestCallback)
+ : http.request(options, requestCallback);
+ request.end();
+ return request;
+}
+/**
+ * @internal
+ */
+export function downloadFile(url, destinationPath, progressCallback) {
+ return new Promise((resolve, reject) => {
+ let downloadedBytes = 0;
+ let totalBytes = 0;
+ function onData(chunk) {
+ downloadedBytes += chunk.length;
+ progressCallback(downloadedBytes, totalBytes);
+ }
+ const request = httpRequest(url, 'GET', response => {
+ if (response.statusCode !== 200) {
+ const error = new Error(`Download failed: server returned code ${response.statusCode}. URL: ${url}`);
+ // consume response data to free up memory
+ response.resume();
+ reject(error);
+ return;
+ }
+ const file = createWriteStream(destinationPath);
+ file.on('close', () => {
+ // The 'close' event is emitted when the stream and any of its
+ // underlying resources (a file descriptor, for example) have been
+ // closed. The event indicates that no more events will be emitted, and
+ // no further computation will occur.
+ return resolve();
+ });
+ file.on('error', error => {
+ // The 'error' event may be emitted by a Readable implementation at any
+ // time. Typically, this may occur if the underlying stream is unable to
+ // generate data due to an underlying internal failure, or when a stream
+ // implementation attempts to push an invalid chunk of data.
+ return reject(error);
+ });
+ response.pipe(file);
+ totalBytes = parseInt(response.headers['content-length'], 10);
+ if (progressCallback) {
+ response.on('data', onData);
+ }
+ });
+ request.on('error', error => {
+ return reject(error);
+ });
+ });
+}
+export async function getJSON(url) {
+ const text = await getText(url);
+ try {
+ return JSON.parse(text);
+ }
+ catch {
+ throw new Error('Could not parse JSON from ' + url.toString());
+ }
+}
+export function getText(url) {
+ return new Promise((resolve, reject) => {
+ const request = httpRequest(url, 'GET', response => {
+ let data = '';
+ if (response.statusCode && response.statusCode >= 400) {
+ return reject(new Error(`Got status code ${response.statusCode}`));
+ }
+ response.on('data', chunk => {
+ data += chunk;
+ });
+ response.on('end', () => {
+ try {
+ return resolve(String(data));
+ }
+ catch {
+ return reject(new Error('Chrome version not found'));
+ }
+ });
+ }, false);
+ request.on('error', err => {
+ reject(err);
+ });
+ });
+}
+//# sourceMappingURL=httpUtil.js.map
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/esm/httpUtil.js.map b/node_modules/@puppeteer/browsers/lib/esm/httpUtil.js.map
new file mode 100644
index 0000000..b8c8da9
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/esm/httpUtil.js.map
@@ -0,0 +1 @@
+{"version":3,"file":"httpUtil.js","sourceRoot":"","sources":["../../src/httpUtil.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,OAAO,EAAC,iBAAiB,EAAC,MAAM,SAAS,CAAC;AAC1C,OAAO,KAAK,IAAI,MAAM,WAAW,CAAC;AAClC,OAAO,KAAK,KAAK,MAAM,YAAY,CAAC;AACpC,OAAO,EAAC,GAAG,EAAE,gBAAgB,EAAC,MAAM,UAAU,CAAC;AAE/C,OAAO,EAAC,UAAU,EAAC,MAAM,aAAa,CAAC;AAEvC,MAAM,UAAU,eAAe,CAAC,GAAQ;IACtC,OAAO,IAAI,OAAO,CAAC,OAAO,CAAC,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d,IAAI,QAAQ,CAAC,UAAU,IAAI,QAAQ,CAAC,UAAU,IAAI,GAAG,EAAE,CAAC;gBACtD,OAAO,MAAM,CAAC,IAAI,KAAK,CAAC,mBAAmB,QAAQ,CAAC,UAAU,EAAE,CAAC,CAAC,CAAC;YACrE,CAAC;YACD,QAAQ,CAAC,EAAE,CAAC,MAAM,EAAE,KAAK,CAAC,EAAE;gBAC1B,IAAI,IAAI,KAAK,CAAC;YAChB,CAAC,CAAC,CAAC;YACH,QAAQ,CAAC,EAAE,CAAC,KAAK,EAAE,GAAG,EAAE;gBACtB,IAAI,CAAC;oBACH,OAAO,OAAO,CAAC,MAAM,CAAC,IAAI,CAAC,CAAC,CAAC;gBAC/B,CAAC;gBAAC,MAAM,CAAC;oBACP,OAAO,MAAM,CAAC,IAAI,KAAK,CAAC,0BAA0B,CAAC,CAAC,CAAC;gBACvD,CAAC;YACH,CAAC,CAAC,CAAC;QACL,CAAC,EACD,KAAK,CACN,CAAC;QACF,OAAO,CAAC,EAAE,CAAC,OAAO,EAAE,GAAG,CAAC,EAAE;YACxB,MAAM,CAAC,GAAG,CAAC,CAAC;QACd,CAAC,CAAC,CAAC;IACL,CAAC,CAAC,CAAC;AACL,CAAC"}
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/esm/install.d.ts b/node_modules/@puppeteer/browsers/lib/esm/install.d.ts
new file mode 100644
index 0000000..8f7a0dc
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/esm/install.d.ts
@@ -0,0 +1,157 @@
+/**
+ * @license
+ * Copyright 2017 Google Inc.
+ * SPDX-License-Identifier: Apache-2.0
+ */
+import { Browser, BrowserPlatform } from './browser-data/browser-data.js';
+import { InstalledBrowser } from './Cache.js';
+/**
+ * @public
+ */
+export interface InstallOptions {
+ /**
+ * Determines the path to download browsers to.
+ */
+ cacheDir: string;
+ /**
+ * Determines which platform the browser will be suited for.
+ *
+ * @defaultValue **Auto-detected.**
+ */
+ platform?: BrowserPlatform;
+ /**
+ * Determines which browser to install.
+ */
+ browser: Browser;
+ /**
+ * Determines which buildId to download. BuildId should uniquely identify
+ * binaries and they are used for caching.
+ */
+ buildId: string;
+ /**
+ * An alias for the provided `buildId`. It will be used to maintain local
+ * metadata to support aliases in the `launch` command.
+ *
+ * @example 'canary'
+ */
+ buildIdAlias?: string;
+ /**
+ * Provides information about the progress of the download. If set to
+ * 'default', the default callback implementing a progress bar will be
+ * used.
+ */
+ downloadProgressCallback?: 'default' | ((downloadedBytes: number, totalBytes: number) => void);
+ /**
+ * Determines the host that will be used for downloading.
+ *
+ * @defaultValue Either
+ *
+ * - https://storage.googleapis.com/chrome-for-testing-public or
+ * - https://archive.mozilla.org/pub/firefox/nightly/latest-mozilla-central
+ *
+ */
+ baseUrl?: string;
+ /**
+ * Whether to unpack and install browser archives.
+ *
+ * @defaultValue `true`
+ */
+ unpack?: boolean;
+ /**
+ * @internal
+ * @defaultValue `false`
+ */
+ forceFallbackForTesting?: boolean;
+ /**
+ * Whether to attempt to install system-level dependencies required
+ * for the browser.
+ *
+ * Only supported for Chrome on Debian or Ubuntu.
+ * Requires system-level privileges to run `apt-get`.
+ *
+ * @defaultValue `false`
+ */
+ installDeps?: boolean;
+}
+/**
+ * Downloads and unpacks the browser archive according to the
+ * {@link InstallOptions}.
+ *
+ * @returns a {@link InstalledBrowser} instance.
+ *
+ * @public
+ */
+export declare function install(options: InstallOptions & {
+ unpack?: true;
+}): Promise;
+/**
+ * Downloads the browser archive according to the {@link InstallOptions} without
+ * unpacking.
+ *
+ * @returns the absolute path to the archive.
+ *
+ * @public
+ */
+export declare function install(options: InstallOptions & {
+ unpack: false;
+}): Promise;
+/**
+ * @public
+ */
+export interface UninstallOptions {
+ /**
+ * Determines the platform for the browser binary.
+ *
+ * @defaultValue **Auto-detected.**
+ */
+ platform?: BrowserPlatform;
+ /**
+ * The path to the root of the cache directory.
+ */
+ cacheDir: string;
+ /**
+ * Determines which browser to uninstall.
+ */
+ browser: Browser;
+ /**
+ * The browser build to uninstall
+ */
+ buildId: string;
+}
+/**
+ *
+ * @public
+ */
+export declare function uninstall(options: UninstallOptions): Promise;
+/**
+ * @public
+ */
+export interface GetInstalledBrowsersOptions {
+ /**
+ * The path to the root of the cache directory.
+ */
+ cacheDir: string;
+}
+/**
+ * Returns metadata about browsers installed in the cache directory.
+ *
+ * @public
+ */
+export declare function getInstalledBrowsers(options: GetInstalledBrowsersOptions): Promise;
+/**
+ * @public
+ */
+export declare function canDownload(options: InstallOptions): Promise;
+/**
+ * Retrieves a URL for downloading the binary archive of a given browser.
+ *
+ * The archive is bound to the specific platform and build ID specified.
+ *
+ * @public
+ */
+export declare function getDownloadUrl(browser: Browser, platform: BrowserPlatform, buildId: string, baseUrl?: string): URL;
+/**
+ * @public
+ */
+export declare function makeProgressCallback(browser: Browser, buildId: string): (downloadedBytes: number, totalBytes: number) => void;
+//# sourceMappingURL=install.d.ts.map
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/esm/install.d.ts.map b/node_modules/@puppeteer/browsers/lib/esm/install.d.ts.map
new file mode 100644
index 0000000..c4184e8
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/esm/install.d.ts.map
@@ -0,0 +1 @@
+{"version":3,"file":"install.d.ts","sourceRoot":"","sources":["../../src/install.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAYH,OAAO,EACL,OAAO,EACP,eAAe,EAEhB,MAAM,gCAAgC,CAAC;AACxC,OAAO,EAAQ,gBAAgB,EAAC,MAAM,YAAY,CAAC;AAwBnD;;GAEG;AACH,MAAM,WAAW,cAAc;IAC7B;;OAEG;IACH,QAAQ,EAAE,MAAM,CAAC;IACjB;;;;OAIG;IACH,QAAQ,CAAC,EAAE,eAAe,CAAC;IAC3B;;OAEG;IACH,OAAO,EAAE,OAAO,CAAC;IACjB;;;OAGG;IACH,OAAO,EAAE,MAAM,CAAC;IAChB;;;;;OAKG;IACH,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB;;;;OAIG;I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e3E;AAED;;;;;;GAMG;AACH,wBAAgB,cAAc,CAC5B,OAAO,EAAE,OAAO,EAChB,QAAQ,EAAE,eAAe,EACzB,OAAO,EAAE,MAAM,EACf,OAAO,CAAC,EAAE,MAAM,GACf,GAAG,CAEL;AAED;;GAEG;AACH,wBAAgB,oBAAoB,CAClC,OAAO,EAAE,OAAO,EAChB,OAAO,EAAE,MAAM,GACd,CAAC,eAAe,EAAE,MAAM,EAAE,UAAU,EAAE,MAAM,KAAK,IAAI,CAsBvD"}
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/esm/install.js b/node_modules/@puppeteer/browsers/lib/esm/install.js
new file mode 100644
index 0000000..5f6bbc1
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/esm/install.js
@@ -0,0 +1,283 @@
+/**
+ * @license
+ * Copyright 2017 Google Inc.
+ * SPDX-License-Identifier: Apache-2.0
+ */
+import assert from 'node:assert';
+import { spawnSync } from 'node:child_process';
+import { existsSync, readFileSync } from 'node:fs';
+import { mkdir, unlink } from 'node:fs/promises';
+import os from 'node:os';
+import path from 'node:path';
+import ProgressBarClass from 'progress';
+import { Browser, BrowserPlatform, downloadUrls, } from './browser-data/browser-data.js';
+import { Cache, InstalledBrowser } from './Cache.js';
+import { debug } from './debug.js';
+import { detectBrowserPlatform } from './detectPlatform.js';
+import { unpackArchive } from './fileUtil.js';
+import { downloadFile, getJSON, headHttpRequest } from './httpUtil.js';
+const debugInstall = debug('puppeteer:browsers:install');
+const times = new Map();
+function debugTime(label) {
+ times.set(label, process.hrtime());
+}
+function debugTimeEnd(label) {
+ const end = process.hrtime();
+ const start = times.get(label);
+ if (!start) {
+ return;
+ }
+ const duration = end[0] * 1000 + end[1] / 1e6 - (start[0] * 1000 + start[1] / 1e6); // calculate duration in milliseconds
+ debugInstall(`Duration for ${label}: ${duration}ms`);
+}
+export async function install(options) {
+ options.platform ??= detectBrowserPlatform();
+ options.unpack ??= true;
+ if (!options.platform) {
+ throw new Error(`Cannot download a binary for the provided platform: ${os.platform()} (${os.arch()})`);
+ }
+ const url = getDownloadUrl(options.browser, options.platform, options.buildId, options.baseUrl);
+ try {
+ return await installUrl(url, options);
+ }
+ catch (err) {
+ // If custom baseUrl is provided, do not fall back to CfT dashboard.
+ if (options.baseUrl && !options.forceFallbackForTesting) {
+ throw err;
+ }
+ debugInstall(`Error downloading from ${url}.`);
+ switch (options.browser) {
+ case Browser.CHROME:
+ case Browser.CHROMEDRIVER:
+ case Browser.CHROMEHEADLESSSHELL: {
+ debugInstall(`Trying to find download URL via https://googlechromelabs.github.io/chrome-for-testing.`);
+ const version = (await getJSON(new URL(`https://googlechromelabs.github.io/chrome-for-testing/${options.buildId}.json`)));
+ let platform = '';
+ switch (options.platform) {
+ case BrowserPlatform.LINUX:
+ platform = 'linux64';
+ break;
+ case BrowserPlatform.MAC_ARM:
+ platform = 'mac-arm64';
+ break;
+ case BrowserPlatform.MAC:
+ platform = 'mac-x64';
+ break;
+ case BrowserPlatform.WIN32:
+ platform = 'win32';
+ break;
+ case BrowserPlatform.WIN64:
+ platform = 'win64';
+ break;
+ }
+ const backupUrl = version.downloads[options.browser]?.find(link => {
+ return link['platform'] === platform;
+ })?.url;
+ if (backupUrl) {
+ // If the URL is the same, skip the retry.
+ if (backupUrl === url.toString()) {
+ throw err;
+ }
+ debugInstall(`Falling back to downloading from ${backupUrl}.`);
+ return await installUrl(new URL(backupUrl), options);
+ }
+ throw err;
+ }
+ default:
+ throw err;
+ }
+ }
+}
+async function installDeps(installedBrowser) {
+ if (process.platform !== 'linux' ||
+ installedBrowser.platform !== BrowserPlatform.LINUX) {
+ return;
+ }
+ // Currently, only Debian-like deps are supported.
+ const depsPath = path.join(path.dirname(installedBrowser.executablePath), 'deb.deps');
+ if (!existsSync(depsPath)) {
+ debugInstall(`deb.deps file was not found at ${depsPath}`);
+ return;
+ }
+ const data = readFileSync(depsPath, 'utf-8').split('\n').join(',');
+ if (process.getuid?.() !== 0) {
+ throw new Error('Installing system dependencies requires root privileges');
+ }
+ let result = spawnSync('apt-get', ['-v']);
+ if (result.status !== 0) {
+ throw new Error('Failed to install system dependencies: apt-get does not seem to be available');
+ }
+ debugInstall(`Trying to install dependencies: ${data}`);
+ result = spawnSync('apt-get', [
+ 'satisfy',
+ '-y',
+ data,
+ '--no-install-recommends',
+ ]);
+ if (result.status !== 0) {
+ throw new Error(`Failed to install system dependencies: status=${result.status},error=${result.error},stdout=${result.stdout.toString('utf8')},stderr=${result.stderr.toString('utf8')}`);
+ }
+ debugInstall(`Installed system dependencies ${data}`);
+}
+async function installUrl(url, options) {
+ options.platform ??= detectBrowserPlatform();
+ if (!options.platform) {
+ throw new Error(`Cannot download a binary for the provided platform: ${os.platform()} (${os.arch()})`);
+ }
+ let downloadProgressCallback = options.downloadProgressCallback;
+ if (downloadProgressCallback === 'default') {
+ downloadProgressCallback = await makeProgressCallback(options.browser, options.buildIdAlias ?? options.buildId);
+ }
+ const fileName = decodeURIComponent(url.toString()).split('/').pop();
+ assert(fileName, `A malformed download URL was found: ${url}.`);
+ const cache = new Cache(options.cacheDir);
+ const browserRoot = cache.browserRoot(options.browser);
+ const archivePath = path.join(browserRoot, `${options.buildId}-${fileName}`);
+ if (!existsSync(browserRoot)) {
+ await mkdir(browserRoot, { recursive: true });
+ }
+ if (!options.unpack) {
+ if (existsSync(archivePath)) {
+ return archivePath;
+ }
+ debugInstall(`Downloading binary from ${url}`);
+ debugTime('download');
+ await downloadFile(url, archivePath, downloadProgressCallback);
+ debugTimeEnd('download');
+ return archivePath;
+ }
+ const outputPath = cache.installationDir(options.browser, options.platform, options.buildId);
+ try {
+ if (existsSync(outputPath)) {
+ const installedBrowser = new InstalledBrowser(cache, options.browser, options.buildId, options.platform);
+ if (!existsSync(installedBrowser.executablePath)) {
+ throw new Error(`The browser folder (${outputPath}) exists but the executable (${installedBrowser.executablePath}) is missing`);
+ }
+ await runSetup(installedBrowser);
+ if (options.installDeps) {
+ await installDeps(installedBrowser);
+ }
+ return installedBrowser;
+ }
+ debugInstall(`Downloading binary from ${url}`);
+ try {
+ debugTime('download');
+ await downloadFile(url, archivePath, downloadProgressCallback);
+ }
+ finally {
+ debugTimeEnd('download');
+ }
+ debugInstall(`Installing ${archivePath} to ${outputPath}`);
+ try {
+ debugTime('extract');
+ await unpackArchive(archivePath, outputPath);
+ }
+ finally {
+ debugTimeEnd('extract');
+ }
+ const installedBrowser = new InstalledBrowser(cache, options.browser, options.buildId, options.platform);
+ if (options.buildIdAlias) {
+ const metadata = installedBrowser.readMetadata();
+ metadata.aliases[options.buildIdAlias] = options.buildId;
+ installedBrowser.writeMetadata(metadata);
+ }
+ await runSetup(installedBrowser);
+ if (options.installDeps) {
+ await installDeps(installedBrowser);
+ }
+ return installedBrowser;
+ }
+ finally {
+ if (existsSync(archivePath)) {
+ await unlink(archivePath);
+ }
+ }
+}
+async function runSetup(installedBrowser) {
+ // On Windows for Chrome invoke setup.exe to configure sandboxes.
+ if ((installedBrowser.platform === BrowserPlatform.WIN32 ||
+ installedBrowser.platform === BrowserPlatform.WIN64) &&
+ installedBrowser.browser === Browser.CHROME &&
+ installedBrowser.platform === detectBrowserPlatform()) {
+ try {
+ debugTime('permissions');
+ const browserDir = path.dirname(installedBrowser.executablePath);
+ const setupExePath = path.join(browserDir, 'setup.exe');
+ if (!existsSync(setupExePath)) {
+ return;
+ }
+ spawnSync(path.join(browserDir, 'setup.exe'), [`--configure-browser-in-directory=` + browserDir], {
+ shell: true,
+ });
+ // TODO: Handle error here. Currently the setup.exe sometimes
+ // errors although it sets the permissions correctly.
+ }
+ finally {
+ debugTimeEnd('permissions');
+ }
+ }
+}
+/**
+ *
+ * @public
+ */
+export async function uninstall(options) {
+ options.platform ??= detectBrowserPlatform();
+ if (!options.platform) {
+ throw new Error(`Cannot detect the browser platform for: ${os.platform()} (${os.arch()})`);
+ }
+ new Cache(options.cacheDir).uninstall(options.browser, options.platform, options.buildId);
+}
+/**
+ * Returns metadata about browsers installed in the cache directory.
+ *
+ * @public
+ */
+export async function getInstalledBrowsers(options) {
+ return new Cache(options.cacheDir).getInstalledBrowsers();
+}
+/**
+ * @public
+ */
+export async function canDownload(options) {
+ options.platform ??= detectBrowserPlatform();
+ if (!options.platform) {
+ throw new Error(`Cannot download a binary for the provided platform: ${os.platform()} (${os.arch()})`);
+ }
+ return await headHttpRequest(getDownloadUrl(options.browser, options.platform, options.buildId, options.baseUrl));
+}
+/**
+ * Retrieves a URL for downloading the binary archive of a given browser.
+ *
+ * The archive is bound to the specific platform and build ID specified.
+ *
+ * @public
+ */
+export function getDownloadUrl(browser, platform, buildId, baseUrl) {
+ return new URL(downloadUrls[browser](platform, buildId, baseUrl));
+}
+/**
+ * @public
+ */
+export function makeProgressCallback(browser, buildId) {
+ let progressBar;
+ let lastDownloadedBytes = 0;
+ return (downloadedBytes, totalBytes) => {
+ if (!progressBar) {
+ progressBar = new ProgressBarClass(`Downloading ${browser} ${buildId} - ${toMegabytes(totalBytes)} [:bar] :percent :etas `, {
+ complete: '=',
+ incomplete: ' ',
+ width: 20,
+ total: totalBytes,
+ });
+ }
+ const delta = downloadedBytes - lastDownloadedBytes;
+ lastDownloadedBytes = downloadedBytes;
+ progressBar.tick(delta);
+ };
+}
+function toMegabytes(bytes) {
+ const mb = bytes / 1000 / 1000;
+ return `${Math.round(mb * 10) / 10} MB`;
+}
+//# sourceMappingURL=install.js.map
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/esm/install.js.map b/node_modules/@puppeteer/browsers/lib/esm/install.js.map
new file mode 100644
index 0000000..77fa537
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/esm/install.js.map
@@ -0,0 +1 @@
+{"version":3,"file":"install.js","sourceRoot":"","sources":["../../src/install.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,OAAO,MAAM,MAAM,aAAa,CAAC;AACjC,OAAO,EAAC,SAAS,EAAC,MAAM,oBAAoB,CAAC;AAC7C,OAAO,EAAC,UAAU,EAAE,YAAY,EAAC,MAAM,SAAS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_modules/@puppeteer/browsers/lib/esm/launch.d.ts b/node_modules/@puppeteer/browsers/lib/esm/launch.d.ts
new file mode 100644
index 0000000..d1560b1
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/esm/launch.d.ts
@@ -0,0 +1,186 @@
+/**
+ * @license
+ * Copyright 2023 Google Inc.
+ * SPDX-License-Identifier: Apache-2.0
+ */
+import childProcess from 'node:child_process';
+import { type Browser, type BrowserPlatform, type ChromeReleaseChannel } from './browser-data/browser-data.js';
+/**
+ * @public
+ */
+export interface ComputeExecutablePathOptions {
+ /**
+ * Root path to the storage directory.
+ *
+ * Can be set to `null` if the executable path should be relative
+ * to the extracted download location. E.g. `./chrome-linux64/chrome`.
+ */
+ cacheDir: string | null;
+ /**
+ * Determines which platform the browser will be suited for.
+ *
+ * @defaultValue **Auto-detected.**
+ */
+ platform?: BrowserPlatform;
+ /**
+ * Determines which browser to launch.
+ */
+ browser: Browser;
+ /**
+ * Determines which buildId to download. BuildId should uniquely identify
+ * binaries and they are used for caching.
+ */
+ buildId: string;
+}
+/**
+ * @public
+ */
+export declare function computeExecutablePath(options: ComputeExecutablePathOptions): string;
+/**
+ * @public
+ */
+export interface SystemOptions {
+ /**
+ * Determines which platform the browser will be suited for.
+ *
+ * @defaultValue **Auto-detected.**
+ */
+ platform?: BrowserPlatform;
+ /**
+ * Determines which browser to launch.
+ */
+ browser: Browser;
+ /**
+ * Release channel to look for on the system.
+ */
+ channel: ChromeReleaseChannel;
+}
+/**
+ * Returns a path to a system-wide Chrome installation given a release channel
+ * name by checking known installation locations (using
+ * {@link https://pptr.dev/browsers-api/browsers.computesystemexecutablepath}).
+ * If Chrome instance is not found at the expected path, an error is thrown.
+ *
+ * @public
+ */
+export declare function computeSystemExecutablePath(options: SystemOptions): string;
+/**
+ * @public
+ */
+export interface LaunchOptions {
+ /**
+ * Absolute path to the browser's executable.
+ */
+ executablePath: string;
+ /**
+ * Configures stdio streams to open two additional streams for automation over
+ * those streams instead of WebSocket.
+ *
+ * @defaultValue `false`.
+ */
+ pipe?: boolean;
+ /**
+ * If true, forwards the browser's process stdout and stderr to the Node's
+ * process stdout and stderr.
+ *
+ * @defaultValue `false`.
+ */
+ dumpio?: boolean;
+ /**
+ * Additional arguments to pass to the executable when launching.
+ */
+ args?: string[];
+ /**
+ * Environment variables to set for the browser process.
+ */
+ env?: Record;
+ /**
+ * Handles SIGINT in the Node process and tries to kill the browser process.
+ *
+ * @defaultValue `true`.
+ */
+ handleSIGINT?: boolean;
+ /**
+ * Handles SIGTERM in the Node process and tries to gracefully close the browser
+ * process.
+ *
+ * @defaultValue `true`.
+ */
+ handleSIGTERM?: boolean;
+ /**
+ * Handles SIGHUP in the Node process and tries to gracefully close the browser process.
+ *
+ * @defaultValue `true`.
+ */
+ handleSIGHUP?: boolean;
+ /**
+ * Whether to spawn process in the {@link https://nodejs.org/api/child_process.html#optionsdetached | detached}
+ * mode.
+ *
+ * @defaultValue `true` except on Windows.
+ */
+ detached?: boolean;
+ /**
+ * A callback to run after the browser process exits or before the process
+ * will be closed via the {@link Process.close} call (including when handling
+ * signals). The callback is only run once.
+ */
+ onExit?: () => Promise;
+}
+/**
+ * Launches a browser process according to {@link LaunchOptions}.
+ *
+ * @public
+ */
+export declare function launch(opts: LaunchOptions): Process;
+/**
+ * @public
+ */
+export declare const CDP_WEBSOCKET_ENDPOINT_REGEX: RegExp;
+/**
+ * @public
+ */
+export declare const WEBDRIVER_BIDI_WEBSOCKET_ENDPOINT_REGEX: RegExp;
+/**
+ * @public
+ */
+export declare class Process {
+ #private;
+ constructor(opts: LaunchOptions);
+ get nodeProcess(): childProcess.ChildProcess;
+ close(): Promise;
+ hasClosed(): Promise;
+ kill(): void;
+ /**
+ * Get recent logs (stderr + stdout) emitted by the browser.
+ *
+ * @public
+ */
+ getRecentLogs(): string[];
+ waitForLineOutput(regex: RegExp, timeout?: number): Promise;
+}
+/**
+ * @internal
+ */
+export interface ErrorLike extends Error {
+ name: string;
+ message: string;
+}
+/**
+ * @internal
+ */
+export declare function isErrorLike(obj: unknown): obj is ErrorLike;
+/**
+ * @internal
+ */
+export declare function isErrnoException(obj: unknown): obj is NodeJS.ErrnoException;
+/**
+ * @public
+ */
+export declare class TimeoutError extends Error {
+ /**
+ * @internal
+ */
+ constructor(message?: string);
+}
+//# sourceMappingURL=launch.d.ts.map
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/esm/launch.d.ts.map b/node_modules/@puppeteer/browsers/lib/esm/launch.d.ts.map
new file mode 100644
index 0000000..a1c3d2a
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/esm/launch.d.ts.map
@@ -0,0 +1 @@
+{"version":3,"file":"launch.d.ts","sourceRoot":"","sources":["../../src/launch.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,OAAO,YAAY,MAAM,oBAAoB,CAAC;AAO9C,OAAO,EACL,KAAK,OAAO,EACZ,KAAK,eAAe,EAEpB,KAAK,oBAAoB,EAE1B,MAAM,gCAAgC,CAAC;AAOxC;;GAEG;AACH,MAAM,WAAW,4BAA4B;IAC3C;;;;;OAKG;IACH,QAAQ,EAAE,MAAM,GAAG,IAAI,CAAC;IACxB;;;;OAIG;IACH,QAAQ,CAAC,EAAE,eAAe,CAAC;IAC3B;;OAEG;IACH,OAAO,EAAE,OAAO,CAAC;IACjB;;;OAGG;IACH,OAAO,EAAE,MAAM,CAAC;CACjB;AAED;;GAEG;AACH,wBAAgB,qBAAqB,CACnC,OAAO,EAAE,4BAA4B,GACpC,MAAM,CAeR;AAED;;GAEG;AACH,MAAM,WAAW,aAAa;IAC5B;;;;OAIG;IACH,QAAQ,CAAC,EAAE,eAAe,CAAC;IAC3B;;OAEG;IACH,OAAO,EAAE,OAAO,CAAC;IACjB;;OAEG;IACH,OAAO,EAAE,oBAAoB,CAAC;CAC/B;AAED;;;;;;;GAOG;AACH,wBAAgB,2BAA2B,CAAC,OAAO,EAAE,aAAa,GAAG,MAAM,CAoB1E;AAED;;GAEG;AACH,MAAM,WA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,CAAC;CACjB;AAED;;GAEG;AACH,wBAAgB,WAAW,CAAC,GAAG,EAAE,OAAO,GAAG,GAAG,IAAI,SAAS,CAI1D;AACD;;GAEG;AACH,wBAAgB,gBAAgB,CAAC,GAAG,EAAE,OAAO,GAAG,GAAG,IAAI,MAAM,CAAC,cAAc,CAK3E;AAED;;GAEG;AACH,qBAAa,YAAa,SAAQ,KAAK;IACrC;;OAEG;gBACS,OAAO,CAAC,EAAE,MAAM;CAK7B"}
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/esm/launch.js b/node_modules/@puppeteer/browsers/lib/esm/launch.js
new file mode 100644
index 0000000..e7d5635
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/esm/launch.js
@@ -0,0 +1,413 @@
+/**
+ * @license
+ * Copyright 2023 Google Inc.
+ * SPDX-License-Identifier: Apache-2.0
+ */
+import childProcess from 'node:child_process';
+import { EventEmitter } from 'node:events';
+import { accessSync } from 'node:fs';
+import os from 'node:os';
+import readline from 'node:readline';
+import { resolveSystemExecutablePath, executablePathByBrowser, } from './browser-data/browser-data.js';
+import { Cache } from './Cache.js';
+import { debug } from './debug.js';
+import { detectBrowserPlatform } from './detectPlatform.js';
+const debugLaunch = debug('puppeteer:browsers:launcher');
+/**
+ * @public
+ */
+export function computeExecutablePath(options) {
+ if (options.cacheDir === null) {
+ options.platform ??= detectBrowserPlatform();
+ if (options.platform === undefined) {
+ throw new Error(`No platform specified. Couldn't auto-detect browser platform.`);
+ }
+ return executablePathByBrowser[options.browser](options.platform, options.buildId);
+ }
+ return new Cache(options.cacheDir).computeExecutablePath(options);
+}
+/**
+ * Returns a path to a system-wide Chrome installation given a release channel
+ * name by checking known installation locations (using
+ * {@link https://pptr.dev/browsers-api/browsers.computesystemexecutablepath}).
+ * If Chrome instance is not found at the expected path, an error is thrown.
+ *
+ * @public
+ */
+export function computeSystemExecutablePath(options) {
+ options.platform ??= detectBrowserPlatform();
+ if (!options.platform) {
+ throw new Error(`Cannot download a binary for the provided platform: ${os.platform()} (${os.arch()})`);
+ }
+ const path = resolveSystemExecutablePath(options.browser, options.platform, options.channel);
+ try {
+ accessSync(path);
+ }
+ catch {
+ throw new Error(`Could not find Google Chrome executable for channel '${options.channel}' at '${path}'.`);
+ }
+ return path;
+}
+/**
+ * Launches a browser process according to {@link LaunchOptions}.
+ *
+ * @public
+ */
+export function launch(opts) {
+ return new Process(opts);
+}
+/**
+ * @public
+ */
+export const CDP_WEBSOCKET_ENDPOINT_REGEX = /^DevTools listening on (ws:\/\/.*)$/;
+/**
+ * @public
+ */
+export const WEBDRIVER_BIDI_WEBSOCKET_ENDPOINT_REGEX = /^WebDriver BiDi listening on (ws:\/\/.*)$/;
+const processListeners = new Map();
+const dispatchers = {
+ exit: (...args) => {
+ processListeners.get('exit')?.forEach(handler => {
+ return handler(...args);
+ });
+ },
+ SIGINT: (...args) => {
+ processListeners.get('SIGINT')?.forEach(handler => {
+ return handler(...args);
+ });
+ },
+ SIGHUP: (...args) => {
+ processListeners.get('SIGHUP')?.forEach(handler => {
+ return handler(...args);
+ });
+ },
+ SIGTERM: (...args) => {
+ processListeners.get('SIGTERM')?.forEach(handler => {
+ return handler(...args);
+ });
+ },
+};
+function subscribeToProcessEvent(event, handler) {
+ const listeners = processListeners.get(event) || [];
+ if (listeners.length === 0) {
+ process.on(event, dispatchers[event]);
+ }
+ listeners.push(handler);
+ processListeners.set(event, listeners);
+}
+function unsubscribeFromProcessEvent(event, handler) {
+ const listeners = processListeners.get(event) || [];
+ const existingListenerIdx = listeners.indexOf(handler);
+ if (existingListenerIdx === -1) {
+ return;
+ }
+ listeners.splice(existingListenerIdx, 1);
+ processListeners.set(event, listeners);
+ if (listeners.length === 0) {
+ process.off(event, dispatchers[event]);
+ }
+}
+/**
+ * @public
+ */
+export class Process {
+ #executablePath;
+ #args;
+ #browserProcess;
+ #exited = false;
+ // The browser process can be closed externally or from the driver process. We
+ // need to invoke the hooks only once though but we don't know how many times
+ // we will be invoked.
+ #hooksRan = false;
+ #onExitHook = async () => { };
+ #browserProcessExiting;
+ #logs = [];
+ #maxLogLinesSize = 1000;
+ #lineEmitter = new EventEmitter();
+ constructor(opts) {
+ this.#executablePath = opts.executablePath;
+ this.#args = opts.args ?? [];
+ opts.pipe ??= false;
+ opts.dumpio ??= false;
+ opts.handleSIGINT ??= true;
+ opts.handleSIGTERM ??= true;
+ opts.handleSIGHUP ??= true;
+ // On non-windows platforms, `detached: true` makes child process a
+ // leader of a new process group, making it possible to kill child
+ // process tree with `.kill(-pid)` command. @see
+ // https://nodejs.org/api/child_process.html#child_process_options_detached
+ opts.detached ??= process.platform !== 'win32';
+ const stdio = this.#configureStdio({
+ pipe: opts.pipe,
+ });
+ const env = opts.env || {};
+ debugLaunch(`Launching ${this.#executablePath} ${this.#args.join(' ')}`, {
+ detached: opts.detached,
+ env: Object.keys(env).reduce((res, key) => {
+ if (key.toLowerCase().startsWith('puppeteer_')) {
+ res[key] = env[key];
+ }
+ return res;
+ }, {}),
+ stdio,
+ });
+ this.#browserProcess = childProcess.spawn(this.#executablePath, this.#args, {
+ detached: opts.detached,
+ env,
+ stdio,
+ });
+ this.#recordStream(this.#browserProcess.stderr);
+ this.#recordStream(this.#browserProcess.stdout);
+ debugLaunch(`Launched ${this.#browserProcess.pid}`);
+ if (opts.dumpio) {
+ this.#browserProcess.stderr?.pipe(process.stderr);
+ this.#browserProcess.stdout?.pipe(process.stdout);
+ }
+ subscribeToProcessEvent('exit', this.#onDriverProcessExit);
+ if (opts.handleSIGINT) {
+ subscribeToProcessEvent('SIGINT', this.#onDriverProcessSignal);
+ }
+ if (opts.handleSIGTERM) {
+ subscribeToProcessEvent('SIGTERM', this.#onDriverProcessSignal);
+ }
+ if (opts.handleSIGHUP) {
+ subscribeToProcessEvent('SIGHUP', this.#onDriverProcessSignal);
+ }
+ if (opts.onExit) {
+ this.#onExitHook = opts.onExit;
+ }
+ this.#browserProcessExiting = new Promise((resolve, reject) => {
+ this.#browserProcess.once('exit', async () => {
+ debugLaunch(`Browser process ${this.#browserProcess.pid} onExit`);
+ this.#clearListeners();
+ this.#exited = true;
+ try {
+ await this.#runHooks();
+ }
+ catch (err) {
+ reject(err);
+ return;
+ }
+ resolve();
+ });
+ });
+ }
+ async #runHooks() {
+ if (this.#hooksRan) {
+ return;
+ }
+ this.#hooksRan = true;
+ await this.#onExitHook();
+ }
+ get nodeProcess() {
+ return this.#browserProcess;
+ }
+ #configureStdio(opts) {
+ if (opts.pipe) {
+ return ['pipe', 'pipe', 'pipe', 'pipe', 'pipe'];
+ }
+ else {
+ return ['pipe', 'pipe', 'pipe'];
+ }
+ }
+ #clearListeners() {
+ unsubscribeFromProcessEvent('exit', this.#onDriverProcessExit);
+ unsubscribeFromProcessEvent('SIGINT', this.#onDriverProcessSignal);
+ unsubscribeFromProcessEvent('SIGTERM', this.#onDriverProcessSignal);
+ unsubscribeFromProcessEvent('SIGHUP', this.#onDriverProcessSignal);
+ }
+ #onDriverProcessExit = (_code) => {
+ this.kill();
+ };
+ #onDriverProcessSignal = (signal) => {
+ switch (signal) {
+ case 'SIGINT':
+ this.kill();
+ process.exit(130);
+ case 'SIGTERM':
+ case 'SIGHUP':
+ void this.close();
+ break;
+ }
+ };
+ async close() {
+ await this.#runHooks();
+ if (!this.#exited) {
+ this.kill();
+ }
+ return await this.#browserProcessExiting;
+ }
+ hasClosed() {
+ return this.#browserProcessExiting;
+ }
+ kill() {
+ debugLaunch(`Trying to kill ${this.#browserProcess.pid}`);
+ // If the process failed to launch (for example if the browser executable path
+ // is invalid), then the process does not get a pid assigned. A call to
+ // `proc.kill` would error, as the `pid` to-be-killed can not be found.
+ if (this.#browserProcess &&
+ this.#browserProcess.pid &&
+ pidExists(this.#browserProcess.pid)) {
+ try {
+ debugLaunch(`Browser process ${this.#browserProcess.pid} exists`);
+ if (process.platform === 'win32') {
+ try {
+ childProcess.execSync(`taskkill /pid ${this.#browserProcess.pid} /T /F`);
+ }
+ catch (error) {
+ debugLaunch(`Killing ${this.#browserProcess.pid} using taskkill failed`, error);
+ // taskkill can fail to kill the process e.g. due to missing permissions.
+ // Let's kill the process via Node API. This delays killing of all child
+ // processes of `this.proc` until the main Node.js process dies.
+ this.#browserProcess.kill();
+ }
+ }
+ else {
+ // on linux the process group can be killed with the group id prefixed with
+ // a minus sign. The process group id is the group leader's pid.
+ const processGroupId = -this.#browserProcess.pid;
+ try {
+ process.kill(processGroupId, 'SIGKILL');
+ }
+ catch (error) {
+ debugLaunch(`Killing ${this.#browserProcess.pid} using process.kill failed`, error);
+ // Killing the process group can fail due e.g. to missing permissions.
+ // Let's kill the process via Node API. This delays killing of all child
+ // processes of `this.proc` until the main Node.js process dies.
+ this.#browserProcess.kill('SIGKILL');
+ }
+ }
+ }
+ catch (error) {
+ throw new Error(`${PROCESS_ERROR_EXPLANATION}\nError cause: ${isErrorLike(error) ? error.stack : error}`);
+ }
+ }
+ this.#clearListeners();
+ }
+ #recordStream(stream) {
+ const rl = readline.createInterface(stream);
+ const cleanup = () => {
+ rl.off('line', onLine);
+ rl.off('close', onClose);
+ try {
+ rl.close();
+ }
+ catch { }
+ };
+ const onLine = (line) => {
+ if (line.trim() === '') {
+ return;
+ }
+ this.#logs.push(line);
+ const delta = this.#logs.length - this.#maxLogLinesSize;
+ if (delta) {
+ this.#logs.splice(0, delta);
+ }
+ this.#lineEmitter.emit('line', line);
+ };
+ const onClose = () => {
+ cleanup();
+ };
+ rl.on('line', onLine);
+ rl.on('close', onClose);
+ }
+ /**
+ * Get recent logs (stderr + stdout) emitted by the browser.
+ *
+ * @public
+ */
+ getRecentLogs() {
+ return [...this.#logs];
+ }
+ waitForLineOutput(regex, timeout = 0) {
+ return new Promise((resolve, reject) => {
+ const onClose = (errorOrCode) => {
+ cleanup();
+ reject(new Error([
+ `Failed to launch the browser process: ${errorOrCode instanceof Error
+ ? ` ${errorOrCode.message}`
+ : ` Code: ${errorOrCode}`}`,
+ '',
+ `stderr:`,
+ this.getRecentLogs().join('\n'),
+ '',
+ 'TROUBLESHOOTING: https://pptr.dev/troubleshooting',
+ '',
+ ].join('\n')));
+ };
+ this.#browserProcess.on('exit', onClose);
+ this.#browserProcess.on('error', onClose);
+ const timeoutId = timeout > 0 ? setTimeout(onTimeout, timeout) : undefined;
+ this.#lineEmitter.on('line', onLine);
+ const cleanup = () => {
+ clearTimeout(timeoutId);
+ this.#lineEmitter.off('line', onLine);
+ this.#browserProcess.off('exit', onClose);
+ this.#browserProcess.off('error', onClose);
+ };
+ function onTimeout() {
+ cleanup();
+ reject(new TimeoutError(`Timed out after ${timeout} ms while waiting for the WS endpoint URL to appear in stdout!`));
+ }
+ for (const line of this.#logs) {
+ onLine(line);
+ }
+ function onLine(line) {
+ const match = line.match(regex);
+ if (!match) {
+ return;
+ }
+ cleanup();
+ // The RegExp matches, so this will obviously exist.
+ resolve(match[1]);
+ }
+ });
+ }
+}
+const PROCESS_ERROR_EXPLANATION = `Puppeteer was unable to kill the process which ran the browser binary.
+This means that, on future Puppeteer launches, Puppeteer might not be able to launch the browser.
+Please check your open processes and ensure that the browser processes that Puppeteer launched have been killed.
+If you think this is a bug, please report it on the Puppeteer issue tracker.`;
+/**
+ * @internal
+ */
+function pidExists(pid) {
+ try {
+ return process.kill(pid, 0);
+ }
+ catch (error) {
+ if (isErrnoException(error)) {
+ if (error.code && error.code === 'ESRCH') {
+ return false;
+ }
+ }
+ throw error;
+ }
+}
+/**
+ * @internal
+ */
+export function isErrorLike(obj) {
+ return (typeof obj === 'object' && obj !== null && 'name' in obj && 'message' in obj);
+}
+/**
+ * @internal
+ */
+export function isErrnoException(obj) {
+ return (isErrorLike(obj) &&
+ ('errno' in obj || 'code' in obj || 'path' in obj || 'syscall' in obj));
+}
+/**
+ * @public
+ */
+export class TimeoutError extends Error {
+ /**
+ * @internal
+ */
+ constructor(message) {
+ super(message);
+ this.name = this.constructor.name;
+ Error.captureStackTrace(this, this.constructor);
+ }
+}
+//# sourceMappingURL=launch.js.map
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/esm/launch.js.map b/node_modules/@puppeteer/browsers/lib/esm/launch.js.map
new file mode 100644
index 0000000..d44f225
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/esm/launch.js.map
@@ -0,0 +1 @@
+{"version":3,"file":"launch.js","sourceRoot":"","sources":["../../src/launch.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,OAAO,YAAY,MAAM,oBAAoB,CAAC;AAC9C,OAAO,EAAC,YAAY,EAAC,MAAM,aAAa,CAAC;AACzC,OAAO,EAAC,UAAU,EAAC,MAAM,SAAS,CAAC;AACnC,OAAO,EAAE,MAAM,SAAS,CAAC;AACzB,OAAO,QAAQ,MAAM,eAAe,CAAC;AAGrC,OAAO,EAGL,2BAA2B,EAE3B,uBAAuB,GACxB,MAAM,gCAAgC,CAAC;AACxC,OAAO,EAAC,KAAK,EAAC,MAAM,YAAY,CAAC;AACjC,OAAO,EAAC,KAAK,EAAC,MAAM,YAAY,CAAC;AACjC,OAAO,EAAC,qBAAqB,EAAC,MAAM,qBAAqB,CAAC;AAE1D,MAAM,WAAW,GAAG,KAAK,CAAC,6BAA6B,CAAC,CAAC;AA8BzD;;GAEG;AACH,MAAM,UAAU,qBAAqB,CACnC,OAAqC;IAErC,IAAI,OAAO,CAAC,QAAQ,KAAK,IAAI,EAAE,CAAC;QAC9B,OAAO,CAAC,QAAQ,KAAK,qBAAqB,EAAE,CAAC;QAC7C,IAAI,OAAO,CAAC,QAAQ,KAAK,SAAS,EAAE,CAAC;YACnC,MAAM,IAAI,KAAK,CACb,+DAA+D,CAChE,CAAC;QACJ,CAAC;QACD,OAAO,uBAAuB,CAAC,OAAO,CAAC,OAAO,CAAC,CAC7C,OAAO,CAAC,QAAQ,EAChB,OAAO,CAAC,OAAO,CAChB,CAAC;IACJ,CAAC;IAED,OAAO,IAAI,KAAK,CAAC,OAAO,CAAC,QAAQ,CAAC,CAAC,qBAAqB,CAAC,OAAO,CAAC,CAAC;AACpE,CAAC;AAsBD;;;;;;;GAOG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AK,QAAQ,IAAI,GAAG,KAAK,IAAI,IAAI,MAAM,IAAI,GAAG,IAAI,SAAS,IAAI,GAAG,CAC7E,CAAC;AACJ,CAAC;AACD;;GAEG;AACH,MAAM,UAAU,gBAAgB,CAAC,GAAY;IAC3C,OAAO,CACL,WAAW,CAAC,GAAG,CAAC;QAChB,CAAC,OAAO,IAAI,GAAG,IAAI,MAAM,IAAI,GAAG,IAAI,MAAM,IAAI,GAAG,IAAI,SAAS,IAAI,GAAG,CAAC,CACvE,CAAC;AACJ,CAAC;AAED;;GAEG;AACH,MAAM,OAAO,YAAa,SAAQ,KAAK;IACrC;;OAEG;IACH,YAAY,OAAgB;QAC1B,KAAK,CAAC,OAAO,CAAC,CAAC;QACf,IAAI,CAAC,IAAI,GAAG,IAAI,CAAC,WAAW,CAAC,IAAI,CAAC;QAClC,KAAK,CAAC,iBAAiB,CAAC,IAAI,EAAE,IAAI,CAAC,WAAW,CAAC,CAAC;IAClD,CAAC;CACF"}
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/esm/main-cli.d.ts b/node_modules/@puppeteer/browsers/lib/esm/main-cli.d.ts
new file mode 100644
index 0000000..24f6aa5
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/esm/main-cli.d.ts
@@ -0,0 +1,8 @@
+#!/usr/bin/env node
+/**
+ * @license
+ * Copyright 2023 Google Inc.
+ * SPDX-License-Identifier: Apache-2.0
+ */
+export {};
+//# sourceMappingURL=main-cli.d.ts.map
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/esm/main-cli.d.ts.map b/node_modules/@puppeteer/browsers/lib/esm/main-cli.d.ts.map
new file mode 100644
index 0000000..97cfca7
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/esm/main-cli.d.ts.map
@@ -0,0 +1 @@
+{"version":3,"file":"main-cli.d.ts","sourceRoot":"","sources":["../../src/main-cli.ts"],"names":[],"mappings":";AAEA;;;;GAIG"}
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/esm/main-cli.js b/node_modules/@puppeteer/browsers/lib/esm/main-cli.js
new file mode 100755
index 0000000..7a9047e
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/esm/main-cli.js
@@ -0,0 +1,9 @@
+#!/usr/bin/env node
+/**
+ * @license
+ * Copyright 2023 Google Inc.
+ * SPDX-License-Identifier: Apache-2.0
+ */
+import { CLI } from './CLI.js';
+void new CLI().run(process.argv);
+//# sourceMappingURL=main-cli.js.map
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/esm/main-cli.js.map b/node_modules/@puppeteer/browsers/lib/esm/main-cli.js.map
new file mode 100644
index 0000000..d856a59
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/esm/main-cli.js.map
@@ -0,0 +1 @@
+{"version":3,"file":"main-cli.js","sourceRoot":"","sources":["../../src/main-cli.ts"],"names":[],"mappings":";AAEA;;;;GAIG;AAEH,OAAO,EAAC,GAAG,EAAC,MAAM,UAAU,CAAC;AAE7B,KAAK,IAAI,GAAG,EAAE,CAAC,GAAG,CAAC,OAAO,CAAC,IAAI,CAAC,CAAC"}
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/esm/main.d.ts b/node_modules/@puppeteer/browsers/lib/esm/main.d.ts
new file mode 100644
index 0000000..89874fd
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/esm/main.d.ts
@@ -0,0 +1,16 @@
+/**
+ * @license
+ * Copyright 2023 Google Inc.
+ * SPDX-License-Identifier: Apache-2.0
+ */
+export type { LaunchOptions, ComputeExecutablePathOptions as Options, SystemOptions, } from './launch.js';
+export { launch, computeExecutablePath, computeSystemExecutablePath, TimeoutError, CDP_WEBSOCKET_ENDPOINT_REGEX, WEBDRIVER_BIDI_WEBSOCKET_ENDPOINT_REGEX, Process, } from './launch.js';
+export type { InstallOptions, GetInstalledBrowsersOptions, UninstallOptions, } from './install.js';
+export { install, makeProgressCallback, getInstalledBrowsers, canDownload, uninstall, getDownloadUrl, } from './install.js';
+export { detectBrowserPlatform } from './detectPlatform.js';
+export type { ProfileOptions } from './browser-data/browser-data.js';
+export { resolveBuildId, Browser, BrowserPlatform, ChromeReleaseChannel, createProfile, getVersionComparator, } from './browser-data/browser-data.js';
+export { CLI } from './CLI.js';
+export { Cache, InstalledBrowser, type Metadata, type ComputeExecutablePathOptions, } from './Cache.js';
+export { BrowserTag } from './browser-data/types.js';
+//# sourceMappingURL=main.d.ts.map
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/esm/main.d.ts.map b/node_modules/@puppeteer/browsers/lib/esm/main.d.ts.map
new file mode 100644
index 0000000..8346bb9
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/esm/main.d.ts.map
@@ -0,0 +1 @@
+{"version":3,"file":"main.d.ts","sourceRoot":"","sources":["../../src/main.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,YAAY,EACV,aAAa,EACb,4BAA4B,IAAI,OAAO,EACvC,aAAa,GACd,MAAM,aAAa,CAAC;AACrB,OAAO,EACL,MAAM,EACN,qBAAqB,EACrB,2BAA2B,EAC3B,YAAY,EACZ,4BAA4B,EAC5B,uCAAuC,EACvC,OAAO,GACR,MAAM,aAAa,CAAC;AACrB,YAAY,EACV,cAAc,EACd,2BAA2B,EAC3B,gBAAgB,GACjB,MAAM,cAAc,CAAC;AACtB,OAAO,EACL,OAAO,EACP,oBAAoB,EACpB,oBAAoB,EACpB,WAAW,EACX,SAAS,EACT,cAAc,GACf,MAAM,cAAc,CAAC;AACtB,OAAO,EAAC,qBAAqB,EAAC,MAAM,qBAAqB,CAAC;AAC1D,YAAY,EAAC,cAAc,EAAC,MAAM,gCAAgC,CAAC;AACnE,OAAO,EACL,cAAc,EACd,OAAO,EACP,eAAe,EACf,oBAAoB,EACpB,aAAa,EACb,oBAAoB,GACrB,MAAM,gCAAgC,CAAC;AACxC,OAAO,EAAC,GAAG,EAAC,MAAM,UAAU,CAAC;AAC7B,OAAO,EACL,KAAK,EACL,gBAAgB,EAChB,KAAK,QAAQ,EACb,KAAK,4BAA4B,GAClC,MAAM,YAAY,CAAC;AACpB,OAAO,EAAC,UAAU,EAAC,MAAM,yBAAyB,CAAC"}
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/esm/main.js b/node_modules/@puppeteer/browsers/lib/esm/main.js
new file mode 100644
index 0000000..bc0d21c
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/esm/main.js
@@ -0,0 +1,13 @@
+/**
+ * @license
+ * Copyright 2023 Google Inc.
+ * SPDX-License-Identifier: Apache-2.0
+ */
+export { launch, computeExecutablePath, computeSystemExecutablePath, TimeoutError, CDP_WEBSOCKET_ENDPOINT_REGEX, WEBDRIVER_BIDI_WEBSOCKET_ENDPOINT_REGEX, Process, } from './launch.js';
+export { install, makeProgressCallback, getInstalledBrowsers, canDownload, uninstall, getDownloadUrl, } from './install.js';
+export { detectBrowserPlatform } from './detectPlatform.js';
+export { resolveBuildId, Browser, BrowserPlatform, ChromeReleaseChannel, createProfile, getVersionComparator, } from './browser-data/browser-data.js';
+export { CLI } from './CLI.js';
+export { Cache, InstalledBrowser, } from './Cache.js';
+export { BrowserTag } from './browser-data/types.js';
+//# sourceMappingURL=main.js.map
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/esm/main.js.map b/node_modules/@puppeteer/browsers/lib/esm/main.js.map
new file mode 100644
index 0000000..c75e6a1
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/esm/main.js.map
@@ -0,0 +1 @@
+{"version":3,"file":"main.js","sourceRoot":"","sources":["../../src/main.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAOH,OAAO,EACL,MAAM,EACN,qBAAqB,EACrB,2BAA2B,EAC3B,YAAY,EACZ,4BAA4B,EAC5B,uCAAuC,EACvC,OAAO,GACR,MAAM,aAAa,CAAC;AAMrB,OAAO,EACL,OAAO,EACP,oBAAoB,EACpB,oBAAoB,EACpB,WAAW,EACX,SAAS,EACT,cAAc,GACf,MAAM,cAAc,CAAC;AACtB,OAAO,EAAC,qBAAqB,EAAC,MAAM,qBAAqB,CAAC;AAE1D,OAAO,EACL,cAAc,EACd,OAAO,EACP,eAAe,EACf,oBAAoB,EACpB,aAAa,EACb,oBAAoB,GACrB,MAAM,gCAAgC,CAAC;AACxC,OAAO,EAAC,GAAG,EAAC,MAAM,UAAU,CAAC;AAC7B,OAAO,EACL,KAAK,EACL,gBAAgB,GAGjB,MAAM,YAAY,CAAC;AACpB,OAAO,EAAC,UAAU,EAAC,MAAM,yBAAyB,CAAC"}
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/lib/esm/package.json b/node_modules/@puppeteer/browsers/lib/esm/package.json
new file mode 100644
index 0000000..1632c2c
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/lib/esm/package.json
@@ -0,0 +1 @@
+{"type": "module"}
\ No newline at end of file
diff --git a/node_modules/@puppeteer/browsers/package.json b/node_modules/@puppeteer/browsers/package.json
new file mode 100644
index 0000000..a227350
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/package.json
@@ -0,0 +1,124 @@
+{
+ "name": "@puppeteer/browsers",
+ "version": "2.10.10",
+ "description": "Download and launch browsers",
+ "scripts": {
+ "build:docs": "wireit",
+ "build": "wireit",
+ "build:test": "wireit",
+ "clean": "../../tools/clean.mjs",
+ "test": "wireit"
+ },
+ "type": "commonjs",
+ "bin": "lib/cjs/main-cli.js",
+ "main": "./lib/cjs/main.js",
+ "exports": {
+ "import": "./lib/esm/main.js",
+ "require": "./lib/cjs/main.js"
+ },
+ "wireit": {
+ "build": {
+ "command": "tsc -b && node --experimental-strip-types ../../tools/chmod.ts 755 lib/cjs/main-cli.js lib/esm/main-cli.js",
+ "files": [
+ "src/**/*.ts",
+ "tsconfig.json"
+ ],
+ "clean": "if-file-deleted",
+ "output": [
+ "lib/**",
+ "!lib/esm/package.json"
+ ],
+ "dependencies": [
+ "generate:package-json",
+ "generate:version"
+ ]
+ },
+ "generate:version": {
+ "command": "hereby generate:version",
+ "clean": "if-file-deleted",
+ "files": [
+ "Herebyfile.mjs"
+ ],
+ "output": [
+ "src/generated/version.ts"
+ ]
+ },
+ "generate:package-json": {
+ "command": "node --experimental-strip-types ../../tools/generate_module_package_json.ts lib/esm/package.json",
+ "files": [
+ "../../tools/generate_module_package_json.ts"
+ ],
+ "output": [
+ "lib/esm/package.json"
+ ]
+ },
+ "build:docs": {
+ "command": "api-extractor run --local --config \"./api-extractor.docs.json\"",
+ "files": [
+ "api-extractor.docs.json",
+ "lib/esm/main.d.ts",
+ "tsconfig.json"
+ ],
+ "dependencies": [
+ "build"
+ ]
+ },
+ "build:test": {
+ "command": "tsc -b test/src/tsconfig.json",
+ "files": [
+ "test/**/*.ts",
+ "test/src/tsconfig.json"
+ ],
+ "output": [
+ "test/build/**"
+ ],
+ "dependencies": [
+ "build",
+ "../testserver:build"
+ ]
+ },
+ "test": {
+ "command": "node tools/downloadTestBrowsers.mjs && mocha",
+ "files": [
+ ".mocharc.cjs"
+ ],
+ "dependencies": [
+ "build:test"
+ ]
+ }
+ },
+ "keywords": [
+ "puppeteer",
+ "browsers"
+ ],
+ "repository": {
+ "type": "git",
+ "url": "https://github.com/puppeteer/puppeteer/tree/main/packages/browsers"
+ },
+ "author": "The Chromium Authors",
+ "license": "Apache-2.0",
+ "engines": {
+ "node": ">=18"
+ },
+ "files": [
+ "lib",
+ "src",
+ "!*.tsbuildinfo"
+ ],
+ "dependencies": {
+ "debug": "^4.4.3",
+ "extract-zip": "^2.0.1",
+ "progress": "^2.0.3",
+ "proxy-agent": "^6.5.0",
+ "tar-fs": "^3.1.0",
+ "yargs": "^17.7.2",
+ "semver": "^7.7.2"
+ },
+ "devDependencies": {
+ "@types/debug": "4.1.12",
+ "@types/progress": "2.0.7",
+ "@types/tar-fs": "2.0.4",
+ "@types/yargs": "17.0.33",
+ "@types/ws": "8.18.1"
+ }
+}
diff --git a/node_modules/@puppeteer/browsers/src/CLI.ts b/node_modules/@puppeteer/browsers/src/CLI.ts
new file mode 100644
index 0000000..5508ceb
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/src/CLI.ts
@@ -0,0 +1,554 @@
+/**
+ * @license
+ * Copyright 2023 Google Inc.
+ * SPDX-License-Identifier: Apache-2.0
+ */
+
+import {stdin as input, stdout as output} from 'node:process';
+import * as readline from 'node:readline';
+
+import type * as Yargs from 'yargs';
+
+import {
+ Browser,
+ resolveBuildId,
+ BrowserPlatform,
+ type ChromeReleaseChannel,
+} from './browser-data/browser-data.js';
+import {Cache} from './Cache.js';
+import {detectBrowserPlatform} from './detectPlatform.js';
+import {packageVersion} from './generated/version.js';
+import {install} from './install.js';
+import {
+ computeExecutablePath,
+ computeSystemExecutablePath,
+ launch,
+} from './launch.js';
+
+interface InstallBrowser {
+ name: Browser;
+ buildId: string;
+}
+interface InstallArgs {
+ browser?: InstallBrowser;
+ path?: string;
+ platform?: BrowserPlatform;
+ baseUrl?: string;
+ installDeps?: boolean;
+}
+
+function isValidBrowser(browser: unknown): browser is Browser {
+ return Object.values(Browser).includes(browser as Browser);
+}
+
+function isValidPlatform(platform: unknown): platform is BrowserPlatform {
+ return Object.values(BrowserPlatform).includes(platform as BrowserPlatform);
+}
+
+/**
+ * @public
+ */
+export class CLI {
+ #cachePath: string;
+ #rl?: readline.Interface;
+ #scriptName: string;
+ #version: string;
+ #allowCachePathOverride: boolean;
+ #pinnedBrowsers?: Partial<
+ Record<
+ Browser,
+ {
+ buildId: string;
+ skipDownload: boolean;
+ }
+ >
+ >;
+ #prefixCommand?: {cmd: string; description: string};
+
+ constructor(
+ opts?:
+ | string
+ | {
+ cachePath?: string;
+ scriptName?: string;
+ version?: string;
+ prefixCommand?: {cmd: string; description: string};
+ allowCachePathOverride?: boolean;
+ pinnedBrowsers?: Partial<
+ Record<
+ Browser,
+ {
+ buildId: string;
+ skipDownload: boolean;
+ }
+ >
+ >;
+ },
+ rl?: readline.Interface,
+ ) {
+ if (!opts) {
+ opts = {};
+ }
+ if (typeof opts === 'string') {
+ opts = {
+ cachePath: opts,
+ };
+ }
+ this.#cachePath = opts.cachePath ?? process.cwd();
+ this.#rl = rl;
+ this.#scriptName = opts.scriptName ?? '@puppeteer/browsers';
+ this.#version = opts.version ?? packageVersion;
+ this.#allowCachePathOverride = opts.allowCachePathOverride ?? true;
+ this.#pinnedBrowsers = opts.pinnedBrowsers;
+ this.#prefixCommand = opts.prefixCommand;
+ }
+
+ #defineBrowserParameter(
+ yargs: Yargs.Argv,
+ required: true,
+ ): Yargs.Argv;
+ #defineBrowserParameter(
+ yargs: Yargs.Argv,
+ required: boolean,
+ ): Yargs.Argv;
+ #defineBrowserParameter(yargs: Yargs.Argv, required: boolean) {
+ return yargs.positional('browser', {
+ description:
+ 'Which browser to install [@]. `latest` will try to find the latest available build. `buildId` is a browser-specific identifier such as a version or a revision.',
+ type: 'string',
+ coerce: (opt): InstallBrowser => {
+ const browser: InstallBrowser = {
+ name: this.#parseBrowser(opt),
+ buildId: this.#parseBuildId(opt),
+ };
+
+ if (!isValidBrowser(browser.name)) {
+ throw new Error(`Unsupported browser '${browser.name}'`);
+ }
+
+ return browser;
+ },
+ demandOption: required,
+ });
+ }
+
+ #definePlatformParameter(yargs: Yargs.Argv) {
+ return yargs.option('platform', {
+ type: 'string',
+ desc: 'Platform that the binary needs to be compatible with.',
+ choices: Object.values(BrowserPlatform),
+ default: detectBrowserPlatform(),
+ coerce: platform => {
+ if (!isValidPlatform(platform)) {
+ throw new Error(`Unsupported platform '${platform}'`);
+ }
+
+ return platform;
+ },
+ defaultDescription: 'Auto-detected',
+ });
+ }
+
+ #definePathParameter(yargs: Yargs.Argv, required = false) {
+ if (!this.#allowCachePathOverride) {
+ return yargs as Yargs.Argv;
+ }
+
+ return yargs.option('path', {
+ type: 'string',
+ desc: 'Path to the root folder for the browser downloads and installation. If a relative path is provided, it will be resolved relative to the current working directory. The installation folder structure is compatible with the cache structure used by Puppeteer.',
+ defaultDescription: 'Current working directory',
+ ...(required ? {} : {default: process.cwd()}),
+ demandOption: required,
+ });
+ }
+
+ async run(argv: string[]): Promise {
+ const {default: yargs} = await import('yargs');
+ const {hideBin} = await import('yargs/helpers');
+ const yargsInstance = yargs(hideBin(argv));
+ let target = yargsInstance
+ .scriptName(this.#scriptName)
+ .version(this.#version);
+ if (this.#prefixCommand) {
+ target = target.command(
+ this.#prefixCommand.cmd,
+ this.#prefixCommand.description,
+ yargs => {
+ return this.#build(yargs);
+ },
+ );
+ } else {
+ target = this.#build(target);
+ }
+ await target
+ .demandCommand(1)
+ .help()
+ .wrap(Math.min(120, yargsInstance.terminalWidth()))
+ .parseAsync();
+ }
+
+ #build(yargs: Yargs.Argv) {
+ const latestOrPinned = this.#pinnedBrowsers ? 'pinned' : 'latest';
+ // If there are pinned browsers allow the positional arg to be optional
+ const browserArgType = this.#pinnedBrowsers ? '[browser]' : '';
+ return yargs
+ .command(
+ `install ${browserArgType}`,
+ 'Download and install the specified browser. If successful, the command outputs the actual browser buildId that was installed and the absolute path to the browser executable (format: @).',
+ yargs => {
+ if (this.#pinnedBrowsers) {
+ yargs.example('$0 install', 'Install all pinned browsers');
+ }
+ yargs
+ .example(
+ '$0 install chrome',
+ `Install the ${latestOrPinned} available build of the Chrome browser.`,
+ )
+ .example(
+ '$0 install chrome@latest',
+ 'Install the latest available build for the Chrome browser.',
+ )
+ .example(
+ '$0 install chrome@stable',
+ 'Install the latest available build for the Chrome browser from the stable channel.',
+ )
+ .example(
+ '$0 install chrome@beta',
+ 'Install the latest available build for the Chrome browser from the beta channel.',
+ )
+ .example(
+ '$0 install chrome@dev',
+ 'Install the latest available build for the Chrome browser from the dev channel.',
+ )
+ .example(
+ '$0 install chrome@canary',
+ 'Install the latest available build for the Chrome Canary browser.',
+ )
+ .example(
+ '$0 install chrome@115',
+ 'Install the latest available build for Chrome 115.',
+ )
+ .example(
+ '$0 install chromedriver@canary',
+ 'Install the latest available build for ChromeDriver Canary.',
+ )
+ .example(
+ '$0 install chromedriver@115',
+ 'Install the latest available build for ChromeDriver 115.',
+ )
+ .example(
+ '$0 install chromedriver@115.0.5790',
+ 'Install the latest available patch (115.0.5790.X) build for ChromeDriver.',
+ )
+ .example(
+ '$0 install chrome-headless-shell',
+ 'Install the latest available chrome-headless-shell build.',
+ )
+ .example(
+ '$0 install chrome-headless-shell@beta',
+ 'Install the latest available chrome-headless-shell build corresponding to the Beta channel.',
+ )
+ .example(
+ '$0 install chrome-headless-shell@118',
+ 'Install the latest available chrome-headless-shell 118 build.',
+ )
+ .example(
+ '$0 install chromium@1083080',
+ 'Install the revision 1083080 of the Chromium browser.',
+ )
+ .example(
+ '$0 install firefox',
+ 'Install the latest nightly available build of the Firefox browser.',
+ )
+ .example(
+ '$0 install firefox@stable',
+ 'Install the latest stable build of the Firefox browser.',
+ )
+ .example(
+ '$0 install firefox@beta',
+ 'Install the latest beta build of the Firefox browser.',
+ )
+ .example(
+ '$0 install firefox@devedition',
+ 'Install the latest devedition build of the Firefox browser.',
+ )
+ .example(
+ '$0 install firefox@esr',
+ 'Install the latest ESR build of the Firefox browser.',
+ )
+ .example(
+ '$0 install firefox@nightly',
+ 'Install the latest nightly build of the Firefox browser.',
+ )
+ .example(
+ '$0 install firefox@stable_111.0.1',
+ 'Install a specific version of the Firefox browser.',
+ )
+ .example(
+ '$0 install firefox --platform mac',
+ 'Install the latest Mac (Intel) build of the Firefox browser.',
+ );
+ if (this.#allowCachePathOverride) {
+ yargs.example(
+ '$0 install firefox --path /tmp/my-browser-cache',
+ 'Install to the specified cache directory.',
+ );
+ }
+
+ const yargsWithBrowserParam = this.#defineBrowserParameter(
+ yargs,
+ !Boolean(this.#pinnedBrowsers),
+ );
+ const yargsWithPlatformParam = this.#definePlatformParameter(
+ yargsWithBrowserParam,
+ );
+ return this.#definePathParameter(yargsWithPlatformParam, false)
+ .option('base-url', {
+ type: 'string',
+ desc: 'Base URL to download from',
+ })
+ .option('install-deps', {
+ type: 'boolean',
+ desc: 'Whether to attempt installing system dependencies (only supported on Linux, requires root privileges).',
+ default: false,
+ });
+ },
+ async args => {
+ if (this.#pinnedBrowsers && !args.browser) {
+ // Use allSettled to avoid scenarios that
+ // a browser may fail early and leave the other
+ // installation in a faulty state
+ const result = await Promise.allSettled(
+ Object.entries(this.#pinnedBrowsers).map(
+ async ([browser, options]) => {
+ if (options.skipDownload) {
+ return;
+ }
+ await this.#install({
+ ...args,
+ browser: {
+ name: browser as Browser,
+ buildId: options.buildId,
+ },
+ });
+ },
+ ),
+ );
+
+ for (const install of result) {
+ if (install.status === 'rejected') {
+ throw install.reason;
+ }
+ }
+ } else {
+ await this.#install(args);
+ }
+ },
+ )
+ .command(
+ 'launch ',
+ 'Launch the specified browser',
+ yargs => {
+ yargs
+ .example(
+ '$0 launch chrome@115.0.5790.170',
+ 'Launch Chrome 115.0.5790.170',
+ )
+ .example(
+ '$0 launch firefox@112.0a1',
+ 'Launch the Firefox browser identified by the milestone 112.0a1.',
+ )
+ .example(
+ '$0 launch chrome@115.0.5790.170 --detached',
+ 'Launch the browser but detach the sub-processes.',
+ )
+ .example(
+ '$0 launch chrome@canary --system',
+ 'Try to locate the Canary build of Chrome installed on the system and launch it.',
+ )
+ .example(
+ '$0 launch chrome@115.0.5790.170 -- --version',
+ 'Launch Chrome 115.0.5790.170 and pass custom argument to the binary.',
+ );
+
+ const yargsWithExtraAgs = yargs.parserConfiguration({
+ 'populate--': true,
+ // Yargs does not have the correct overload for this.
+ }) as Yargs.Argv<{'--'?: Array}>;
+ const yargsWithBrowserParam = this.#defineBrowserParameter(
+ yargsWithExtraAgs,
+ true,
+ );
+ const yargsWithPlatformParam = this.#definePlatformParameter(
+ yargsWithBrowserParam,
+ );
+ return this.#definePathParameter(yargsWithPlatformParam)
+ .option('detached', {
+ type: 'boolean',
+ desc: 'Detach the child process.',
+ default: false,
+ })
+ .option('system', {
+ type: 'boolean',
+ desc: 'Search for a browser installed on the system instead of the cache folder.',
+ default: false,
+ })
+ .option('dumpio', {
+ type: 'boolean',
+ desc: "Forwards the browser's process stdout and stderr",
+ default: false,
+ });
+ },
+ async args => {
+ const extraArgs = args['--']?.filter(arg => {
+ return typeof arg === 'string';
+ });
+
+ args.browser.buildId = this.#resolvePinnedBrowserIfNeeded(
+ args.browser.buildId,
+ args.browser.name,
+ );
+
+ const executablePath = args.system
+ ? computeSystemExecutablePath({
+ browser: args.browser.name,
+ // TODO: throw an error if not a ChromeReleaseChannel is provided.
+ channel: args.browser.buildId as ChromeReleaseChannel,
+ platform: args.platform,
+ })
+ : computeExecutablePath({
+ browser: args.browser.name,
+ buildId: args.browser.buildId,
+ cacheDir: args.path ?? this.#cachePath,
+ platform: args.platform,
+ });
+ launch({
+ args: extraArgs,
+ executablePath,
+ dumpio: args.dumpio,
+ detached: args.detached,
+ });
+ },
+ )
+ .command(
+ 'clear',
+ this.#allowCachePathOverride
+ ? 'Removes all installed browsers from the specified cache directory'
+ : `Removes all installed browsers from ${this.#cachePath}`,
+ yargs => {
+ return this.#definePathParameter(yargs, true);
+ },
+ async args => {
+ const cacheDir = args.path ?? this.#cachePath;
+ const rl = this.#rl ?? readline.createInterface({input, output});
+ rl.question(
+ `Do you want to permanently and recursively delete the content of ${cacheDir} (yes/No)? `,
+ answer => {
+ rl.close();
+ if (!['y', 'yes'].includes(answer.toLowerCase().trim())) {
+ console.log('Cancelled.');
+ return;
+ }
+ const cache = new Cache(cacheDir);
+ cache.clear();
+ console.log(`${cacheDir} cleared.`);
+ },
+ );
+ },
+ )
+ .command(
+ 'list',
+ 'List all installed browsers in the cache directory',
+ yargs => {
+ yargs.example(
+ '$0 list',
+ 'List all installed browsers in the cache directory',
+ );
+ if (this.#allowCachePathOverride) {
+ yargs.example(
+ '$0 list --path /tmp/my-browser-cache',
+ 'List browsers installed in the specified cache directory',
+ );
+ }
+
+ return this.#definePathParameter(yargs);
+ },
+ async args => {
+ const cacheDir = args.path ?? this.#cachePath;
+ const cache = new Cache(cacheDir);
+ const browsers = cache.getInstalledBrowsers();
+
+ for (const browser of browsers) {
+ console.log(
+ `${browser.browser}@${browser.buildId} (${browser.platform}) ${browser.executablePath}`,
+ );
+ }
+ },
+ )
+ .demandCommand(1)
+ .help();
+ }
+
+ #parseBrowser(version: string): Browser {
+ return version.split('@').shift() as Browser;
+ }
+
+ #parseBuildId(version: string): string {
+ const parts = version.split('@');
+ return parts.length === 2
+ ? parts[1]!
+ : this.#pinnedBrowsers
+ ? 'pinned'
+ : 'latest';
+ }
+
+ #resolvePinnedBrowserIfNeeded(buildId: string, browserName: Browser): string {
+ if (buildId === 'pinned') {
+ const options = this.#pinnedBrowsers?.[browserName];
+ if (!options || !options.buildId) {
+ throw new Error(`No pinned version found for ${browserName}`);
+ }
+ return options.buildId;
+ }
+ return buildId;
+ }
+
+ async #install(args: InstallArgs) {
+ if (!args.browser) {
+ throw new Error(`No browser arg provided`);
+ }
+ if (!args.platform) {
+ throw new Error(`Could not resolve the current platform`);
+ }
+ args.browser.buildId = this.#resolvePinnedBrowserIfNeeded(
+ args.browser.buildId,
+ args.browser.name,
+ );
+ const originalBuildId = args.browser.buildId;
+ args.browser.buildId = await resolveBuildId(
+ args.browser.name,
+ args.platform,
+ args.browser.buildId,
+ );
+ await install({
+ browser: args.browser.name,
+ buildId: args.browser.buildId,
+ platform: args.platform,
+ cacheDir: args.path ?? this.#cachePath,
+ downloadProgressCallback: 'default',
+ baseUrl: args.baseUrl,
+ buildIdAlias:
+ originalBuildId !== args.browser.buildId ? originalBuildId : undefined,
+ installDeps: args.installDeps,
+ });
+ console.log(
+ `${args.browser.name}@${args.browser.buildId} ${computeExecutablePath({
+ browser: args.browser.name,
+ buildId: args.browser.buildId,
+ cacheDir: args.path ?? this.#cachePath,
+ platform: args.platform,
+ })}`,
+ );
+ }
+}
diff --git a/node_modules/@puppeteer/browsers/src/Cache.ts b/node_modules/@puppeteer/browsers/src/Cache.ts
new file mode 100644
index 0000000..bc089b5
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/src/Cache.ts
@@ -0,0 +1,277 @@
+/**
+ * @license
+ * Copyright 2023 Google Inc.
+ * SPDX-License-Identifier: Apache-2.0
+ */
+
+import fs from 'node:fs';
+import os from 'node:os';
+import path from 'node:path';
+
+import debug from 'debug';
+
+import {
+ Browser,
+ type BrowserPlatform,
+ executablePathByBrowser,
+ getVersionComparator,
+} from './browser-data/browser-data.js';
+import {detectBrowserPlatform} from './detectPlatform.js';
+
+const debugCache = debug('puppeteer:browsers:cache');
+
+/**
+ * @public
+ */
+export class InstalledBrowser {
+ browser: Browser;
+ buildId: string;
+ platform: BrowserPlatform;
+ readonly executablePath: string;
+
+ #cache: Cache;
+
+ /**
+ * @internal
+ */
+ constructor(
+ cache: Cache,
+ browser: Browser,
+ buildId: string,
+ platform: BrowserPlatform,
+ ) {
+ this.#cache = cache;
+ this.browser = browser;
+ this.buildId = buildId;
+ this.platform = platform;
+ this.executablePath = cache.computeExecutablePath({
+ browser,
+ buildId,
+ platform,
+ });
+ }
+
+ /**
+ * Path to the root of the installation folder. Use
+ * {@link computeExecutablePath} to get the path to the executable binary.
+ */
+ get path(): string {
+ return this.#cache.installationDir(
+ this.browser,
+ this.platform,
+ this.buildId,
+ );
+ }
+
+ readMetadata(): Metadata {
+ return this.#cache.readMetadata(this.browser);
+ }
+
+ writeMetadata(metadata: Metadata): void {
+ this.#cache.writeMetadata(this.browser, metadata);
+ }
+}
+
+/**
+ * @internal
+ */
+export interface ComputeExecutablePathOptions {
+ /**
+ * Determines which platform the browser will be suited for.
+ *
+ * @defaultValue **Auto-detected.**
+ */
+ platform?: BrowserPlatform;
+ /**
+ * Determines which browser to launch.
+ */
+ browser: Browser;
+ /**
+ * Determines which buildId to download. BuildId should uniquely identify
+ * binaries and they are used for caching.
+ */
+ buildId: string;
+}
+
+/**
+ * @public
+ */
+export interface Metadata {
+ // Maps an alias (canary/latest/dev/etc.) to a buildId.
+ aliases: Record;
+}
+
+/**
+ * The cache used by Puppeteer relies on the following structure:
+ *
+ * - rootDir
+ * -- | browserRoot(browser1)
+ * ---- - | installationDir()
+ * ------ the browser-platform-buildId
+ * ------ specific structure.
+ * -- | browserRoot(browser2)
+ * ---- - | installationDir()
+ * ------ the browser-platform-buildId
+ * ------ specific structure.
+ * @internal
+ */
+export class Cache {
+ #rootDir: string;
+
+ constructor(rootDir: string) {
+ this.#rootDir = rootDir;
+ }
+
+ /**
+ * @internal
+ */
+ get rootDir(): string {
+ return this.#rootDir;
+ }
+
+ browserRoot(browser: Browser): string {
+ return path.join(this.#rootDir, browser);
+ }
+
+ metadataFile(browser: Browser): string {
+ return path.join(this.browserRoot(browser), '.metadata');
+ }
+
+ readMetadata(browser: Browser): Metadata {
+ const metatadaPath = this.metadataFile(browser);
+ if (!fs.existsSync(metatadaPath)) {
+ return {aliases: {}};
+ }
+ // TODO: add type-safe parsing.
+ const data = JSON.parse(fs.readFileSync(metatadaPath, 'utf8'));
+ if (typeof data !== 'object') {
+ throw new Error('.metadata is not an object');
+ }
+ return data;
+ }
+
+ writeMetadata(browser: Browser, metadata: Metadata): void {
+ const metatadaPath = this.metadataFile(browser);
+ fs.mkdirSync(path.dirname(metatadaPath), {recursive: true});
+ fs.writeFileSync(metatadaPath, JSON.stringify(metadata, null, 2));
+ }
+
+ resolveAlias(browser: Browser, alias: string): string | undefined {
+ const metadata = this.readMetadata(browser);
+ if (alias === 'latest') {
+ return Object.values(metadata.aliases || {})
+ .sort(getVersionComparator(browser))
+ .at(-1);
+ }
+ return metadata.aliases[alias];
+ }
+
+ installationDir(
+ browser: Browser,
+ platform: BrowserPlatform,
+ buildId: string,
+ ): string {
+ return path.join(this.browserRoot(browser), `${platform}-${buildId}`);
+ }
+
+ clear(): void {
+ fs.rmSync(this.#rootDir, {
+ force: true,
+ recursive: true,
+ maxRetries: 10,
+ retryDelay: 500,
+ });
+ }
+
+ uninstall(
+ browser: Browser,
+ platform: BrowserPlatform,
+ buildId: string,
+ ): void {
+ const metadata = this.readMetadata(browser);
+ for (const alias of Object.keys(metadata.aliases)) {
+ if (metadata.aliases[alias] === buildId) {
+ delete metadata.aliases[alias];
+ }
+ }
+ fs.rmSync(this.installationDir(browser, platform, buildId), {
+ force: true,
+ recursive: true,
+ maxRetries: 10,
+ retryDelay: 500,
+ });
+ }
+
+ getInstalledBrowsers(): InstalledBrowser[] {
+ if (!fs.existsSync(this.#rootDir)) {
+ return [];
+ }
+ const types = fs.readdirSync(this.#rootDir);
+ const browsers = types.filter((t): t is Browser => {
+ return (Object.values(Browser) as string[]).includes(t);
+ });
+ return browsers.flatMap(browser => {
+ const files = fs.readdirSync(this.browserRoot(browser));
+ return files
+ .map(file => {
+ const result = parseFolderPath(
+ path.join(this.browserRoot(browser), file),
+ );
+ if (!result) {
+ return null;
+ }
+ return new InstalledBrowser(
+ this,
+ browser,
+ result.buildId,
+ result.platform as BrowserPlatform,
+ );
+ })
+ .filter((item: InstalledBrowser | null): item is InstalledBrowser => {
+ return item !== null;
+ });
+ });
+ }
+
+ computeExecutablePath(options: ComputeExecutablePathOptions): string {
+ options.platform ??= detectBrowserPlatform();
+ if (!options.platform) {
+ throw new Error(
+ `Cannot download a binary for the provided platform: ${os.platform()} (${os.arch()})`,
+ );
+ }
+ try {
+ options.buildId =
+ this.resolveAlias(options.browser, options.buildId) ?? options.buildId;
+ } catch {
+ debugCache('could not read .metadata file for the browser');
+ }
+ const installationDir = this.installationDir(
+ options.browser,
+ options.platform,
+ options.buildId,
+ );
+ return path.join(
+ installationDir,
+ executablePathByBrowser[options.browser](
+ options.platform,
+ options.buildId,
+ ),
+ );
+ }
+}
+
+function parseFolderPath(
+ folderPath: string,
+): {platform: string; buildId: string} | undefined {
+ const name = path.basename(folderPath);
+ const splits = name.split('-');
+ if (splits.length !== 2) {
+ return;
+ }
+ const [platform, buildId] = splits;
+ if (!buildId || !platform) {
+ return;
+ }
+ return {platform, buildId};
+}
diff --git a/node_modules/@puppeteer/browsers/src/browser-data/browser-data.ts b/node_modules/@puppeteer/browsers/src/browser-data/browser-data.ts
new file mode 100644
index 0000000..6107dde
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/src/browser-data/browser-data.ts
@@ -0,0 +1,252 @@
+/**
+ * @license
+ * Copyright 2023 Google Inc.
+ * SPDX-License-Identifier: Apache-2.0
+ */
+
+import * as chromeHeadlessShell from './chrome-headless-shell.js';
+import * as chrome from './chrome.js';
+import * as chromedriver from './chromedriver.js';
+import * as chromium from './chromium.js';
+import * as firefox from './firefox.js';
+import {
+ Browser,
+ BrowserPlatform,
+ BrowserTag,
+ ChromeReleaseChannel,
+ type ProfileOptions,
+} from './types.js';
+
+export type {ProfileOptions};
+
+export const downloadUrls = {
+ [Browser.CHROMEDRIVER]: chromedriver.resolveDownloadUrl,
+ [Browser.CHROMEHEADLESSSHELL]: chromeHeadlessShell.resolveDownloadUrl,
+ [Browser.CHROME]: chrome.resolveDownloadUrl,
+ [Browser.CHROMIUM]: chromium.resolveDownloadUrl,
+ [Browser.FIREFOX]: firefox.resolveDownloadUrl,
+};
+
+export const downloadPaths = {
+ [Browser.CHROMEDRIVER]: chromedriver.resolveDownloadPath,
+ [Browser.CHROMEHEADLESSSHELL]: chromeHeadlessShell.resolveDownloadPath,
+ [Browser.CHROME]: chrome.resolveDownloadPath,
+ [Browser.CHROMIUM]: chromium.resolveDownloadPath,
+ [Browser.FIREFOX]: firefox.resolveDownloadPath,
+};
+
+export const executablePathByBrowser = {
+ [Browser.CHROMEDRIVER]: chromedriver.relativeExecutablePath,
+ [Browser.CHROMEHEADLESSSHELL]: chromeHeadlessShell.relativeExecutablePath,
+ [Browser.CHROME]: chrome.relativeExecutablePath,
+ [Browser.CHROMIUM]: chromium.relativeExecutablePath,
+ [Browser.FIREFOX]: firefox.relativeExecutablePath,
+};
+
+export const versionComparators = {
+ [Browser.CHROMEDRIVER]: chromedriver.compareVersions,
+ [Browser.CHROMEHEADLESSSHELL]: chromeHeadlessShell.compareVersions,
+ [Browser.CHROME]: chrome.compareVersions,
+ [Browser.CHROMIUM]: chromium.compareVersions,
+ [Browser.FIREFOX]: firefox.compareVersions,
+};
+
+export {Browser, BrowserPlatform, ChromeReleaseChannel};
+
+/**
+ * @internal
+ */
+async function resolveBuildIdForBrowserTag(
+ browser: Browser,
+ platform: BrowserPlatform,
+ tag: BrowserTag,
+): Promise {
+ switch (browser) {
+ case Browser.FIREFOX:
+ switch (tag) {
+ case BrowserTag.LATEST:
+ return await firefox.resolveBuildId(firefox.FirefoxChannel.NIGHTLY);
+ case BrowserTag.BETA:
+ return await firefox.resolveBuildId(firefox.FirefoxChannel.BETA);
+ case BrowserTag.NIGHTLY:
+ return await firefox.resolveBuildId(firefox.FirefoxChannel.NIGHTLY);
+ case BrowserTag.DEVEDITION:
+ return await firefox.resolveBuildId(
+ firefox.FirefoxChannel.DEVEDITION,
+ );
+ case BrowserTag.STABLE:
+ return await firefox.resolveBuildId(firefox.FirefoxChannel.STABLE);
+ case BrowserTag.ESR:
+ return await firefox.resolveBuildId(firefox.FirefoxChannel.ESR);
+ case BrowserTag.CANARY:
+ case BrowserTag.DEV:
+ throw new Error(`${tag.toUpperCase()} is not available for Firefox`);
+ }
+ case Browser.CHROME: {
+ switch (tag) {
+ case BrowserTag.LATEST:
+ return await chrome.resolveBuildId(ChromeReleaseChannel.CANARY);
+ case BrowserTag.BETA:
+ return await chrome.resolveBuildId(ChromeReleaseChannel.BETA);
+ case BrowserTag.CANARY:
+ return await chrome.resolveBuildId(ChromeReleaseChannel.CANARY);
+ case BrowserTag.DEV:
+ return await chrome.resolveBuildId(ChromeReleaseChannel.DEV);
+ case BrowserTag.STABLE:
+ return await chrome.resolveBuildId(ChromeReleaseChannel.STABLE);
+ case BrowserTag.NIGHTLY:
+ case BrowserTag.DEVEDITION:
+ case BrowserTag.ESR:
+ throw new Error(`${tag.toUpperCase()} is not available for Chrome`);
+ }
+ }
+ case Browser.CHROMEDRIVER: {
+ switch (tag) {
+ case BrowserTag.LATEST:
+ case BrowserTag.CANARY:
+ return await chromedriver.resolveBuildId(ChromeReleaseChannel.CANARY);
+ case BrowserTag.BETA:
+ return await chromedriver.resolveBuildId(ChromeReleaseChannel.BETA);
+ case BrowserTag.DEV:
+ return await chromedriver.resolveBuildId(ChromeReleaseChannel.DEV);
+ case BrowserTag.STABLE:
+ return await chromedriver.resolveBuildId(ChromeReleaseChannel.STABLE);
+ case BrowserTag.NIGHTLY:
+ case BrowserTag.DEVEDITION:
+ case BrowserTag.ESR:
+ throw new Error(
+ `${tag.toUpperCase()} is not available for ChromeDriver`,
+ );
+ }
+ }
+ case Browser.CHROMEHEADLESSSHELL: {
+ switch (tag) {
+ case BrowserTag.LATEST:
+ case BrowserTag.CANARY:
+ return await chromeHeadlessShell.resolveBuildId(
+ ChromeReleaseChannel.CANARY,
+ );
+ case BrowserTag.BETA:
+ return await chromeHeadlessShell.resolveBuildId(
+ ChromeReleaseChannel.BETA,
+ );
+ case BrowserTag.DEV:
+ return await chromeHeadlessShell.resolveBuildId(
+ ChromeReleaseChannel.DEV,
+ );
+ case BrowserTag.STABLE:
+ return await chromeHeadlessShell.resolveBuildId(
+ ChromeReleaseChannel.STABLE,
+ );
+ case BrowserTag.NIGHTLY:
+ case BrowserTag.DEVEDITION:
+ case BrowserTag.ESR:
+ throw new Error(`${tag} is not available for chrome-headless-shell`);
+ }
+ }
+ case Browser.CHROMIUM:
+ switch (tag) {
+ case BrowserTag.LATEST:
+ return await chromium.resolveBuildId(platform);
+ case BrowserTag.NIGHTLY:
+ case BrowserTag.CANARY:
+ case BrowserTag.DEV:
+ case BrowserTag.DEVEDITION:
+ case BrowserTag.BETA:
+ case BrowserTag.STABLE:
+ case BrowserTag.ESR:
+ throw new Error(
+ `${tag} is not supported for Chromium. Use 'latest' instead.`,
+ );
+ }
+ }
+}
+
+/**
+ * @public
+ */
+export async function resolveBuildId(
+ browser: Browser,
+ platform: BrowserPlatform,
+ tag: string | BrowserTag,
+): Promise {
+ const browserTag = tag as BrowserTag;
+ if (Object.values(BrowserTag).includes(browserTag)) {
+ return await resolveBuildIdForBrowserTag(browser, platform, browserTag);
+ }
+
+ switch (browser) {
+ case Browser.FIREFOX:
+ return tag;
+ case Browser.CHROME:
+ const chromeResult = await chrome.resolveBuildId(tag);
+ if (chromeResult) {
+ return chromeResult;
+ }
+ return tag;
+ case Browser.CHROMEDRIVER:
+ const chromeDriverResult = await chromedriver.resolveBuildId(tag);
+ if (chromeDriverResult) {
+ return chromeDriverResult;
+ }
+ return tag;
+ case Browser.CHROMEHEADLESSSHELL:
+ const chromeHeadlessShellResult =
+ await chromeHeadlessShell.resolveBuildId(tag);
+ if (chromeHeadlessShellResult) {
+ return chromeHeadlessShellResult;
+ }
+ return tag;
+ case Browser.CHROMIUM:
+ return tag;
+ }
+}
+
+/**
+ * @public
+ */
+export async function createProfile(
+ browser: Browser,
+ opts: ProfileOptions,
+): Promise {
+ switch (browser) {
+ case Browser.FIREFOX:
+ return await firefox.createProfile(opts);
+ case Browser.CHROME:
+ case Browser.CHROMIUM:
+ throw new Error(`Profile creation is not support for ${browser} yet`);
+ }
+}
+
+/**
+ * @public
+ */
+export function resolveSystemExecutablePath(
+ browser: Browser,
+ platform: BrowserPlatform,
+ channel: ChromeReleaseChannel,
+): string {
+ switch (browser) {
+ case Browser.CHROMEDRIVER:
+ case Browser.CHROMEHEADLESSSHELL:
+ case Browser.FIREFOX:
+ case Browser.CHROMIUM:
+ throw new Error(
+ `System browser detection is not supported for ${browser} yet.`,
+ );
+ case Browser.CHROME:
+ return chrome.resolveSystemExecutablePath(platform, channel);
+ }
+}
+
+/**
+ * Returns a version comparator for the given browser that can be used to sort
+ * browser versions.
+ *
+ * @public
+ */
+export function getVersionComparator(
+ browser: Browser,
+): (a: string, b: string) => number {
+ return versionComparators[browser];
+}
diff --git a/node_modules/@puppeteer/browsers/src/browser-data/chrome-headless-shell.ts b/node_modules/@puppeteer/browsers/src/browser-data/chrome-headless-shell.ts
new file mode 100644
index 0000000..dda03f5
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/src/browser-data/chrome-headless-shell.ts
@@ -0,0 +1,71 @@
+/**
+ * @license
+ * Copyright 2023 Google Inc.
+ * SPDX-License-Identifier: Apache-2.0
+ */
+import path from 'node:path';
+
+import {BrowserPlatform} from './types.js';
+
+function folder(platform: BrowserPlatform): string {
+ switch (platform) {
+ case BrowserPlatform.LINUX_ARM:
+ case BrowserPlatform.LINUX:
+ return 'linux64';
+ case BrowserPlatform.MAC_ARM:
+ return 'mac-arm64';
+ case BrowserPlatform.MAC:
+ return 'mac-x64';
+ case BrowserPlatform.WIN32:
+ return 'win32';
+ case BrowserPlatform.WIN64:
+ return 'win64';
+ }
+}
+
+export function resolveDownloadUrl(
+ platform: BrowserPlatform,
+ buildId: string,
+ baseUrl = 'https://storage.googleapis.com/chrome-for-testing-public',
+): string {
+ return `${baseUrl}/${resolveDownloadPath(platform, buildId).join('/')}`;
+}
+
+export function resolveDownloadPath(
+ platform: BrowserPlatform,
+ buildId: string,
+): string[] {
+ return [
+ buildId,
+ folder(platform),
+ `chrome-headless-shell-${folder(platform)}.zip`,
+ ];
+}
+
+export function relativeExecutablePath(
+ platform: BrowserPlatform,
+ _buildId: string,
+): string {
+ switch (platform) {
+ case BrowserPlatform.MAC:
+ case BrowserPlatform.MAC_ARM:
+ return path.join(
+ 'chrome-headless-shell-' + folder(platform),
+ 'chrome-headless-shell',
+ );
+ case BrowserPlatform.LINUX_ARM:
+ case BrowserPlatform.LINUX:
+ return path.join(
+ 'chrome-headless-shell-linux64',
+ 'chrome-headless-shell',
+ );
+ case BrowserPlatform.WIN32:
+ case BrowserPlatform.WIN64:
+ return path.join(
+ 'chrome-headless-shell-' + folder(platform),
+ 'chrome-headless-shell.exe',
+ );
+ }
+}
+
+export {resolveBuildId, compareVersions} from './chrome.js';
diff --git a/node_modules/@puppeteer/browsers/src/browser-data/chrome.ts b/node_modules/@puppeteer/browsers/src/browser-data/chrome.ts
new file mode 100644
index 0000000..7fe3454
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/src/browser-data/chrome.ts
@@ -0,0 +1,215 @@
+/**
+ * @license
+ * Copyright 2023 Google Inc.
+ * SPDX-License-Identifier: Apache-2.0
+ */
+
+import path from 'node:path';
+
+import semver from 'semver';
+
+import {getJSON} from '../httpUtil.js';
+
+import {BrowserPlatform, ChromeReleaseChannel} from './types.js';
+
+function folder(platform: BrowserPlatform): string {
+ switch (platform) {
+ case BrowserPlatform.LINUX_ARM:
+ case BrowserPlatform.LINUX:
+ return 'linux64';
+ case BrowserPlatform.MAC_ARM:
+ return 'mac-arm64';
+ case BrowserPlatform.MAC:
+ return 'mac-x64';
+ case BrowserPlatform.WIN32:
+ return 'win32';
+ case BrowserPlatform.WIN64:
+ return 'win64';
+ }
+}
+
+export function resolveDownloadUrl(
+ platform: BrowserPlatform,
+ buildId: string,
+ baseUrl = 'https://storage.googleapis.com/chrome-for-testing-public',
+): string {
+ return `${baseUrl}/${resolveDownloadPath(platform, buildId).join('/')}`;
+}
+
+export function resolveDownloadPath(
+ platform: BrowserPlatform,
+ buildId: string,
+): string[] {
+ return [buildId, folder(platform), `chrome-${folder(platform)}.zip`];
+}
+
+export function relativeExecutablePath(
+ platform: BrowserPlatform,
+ _buildId: string,
+): string {
+ switch (platform) {
+ case BrowserPlatform.MAC:
+ case BrowserPlatform.MAC_ARM:
+ return path.join(
+ 'chrome-' + folder(platform),
+ 'Google Chrome for Testing.app',
+ 'Contents',
+ 'MacOS',
+ 'Google Chrome for Testing',
+ );
+ case BrowserPlatform.LINUX_ARM:
+ case BrowserPlatform.LINUX:
+ return path.join('chrome-linux64', 'chrome');
+ case BrowserPlatform.WIN32:
+ case BrowserPlatform.WIN64:
+ return path.join('chrome-' + folder(platform), 'chrome.exe');
+ }
+}
+
+export async function getLastKnownGoodReleaseForChannel(
+ channel: ChromeReleaseChannel,
+): Promise<{version: string; revision: string}> {
+ const data = (await getJSON(
+ new URL(
+ 'https://googlechromelabs.github.io/chrome-for-testing/last-known-good-versions.json',
+ ),
+ )) as {
+ channels: Record;
+ };
+
+ for (const channel of Object.keys(data.channels)) {
+ data.channels[channel.toLowerCase()] = data.channels[channel]!;
+ delete data.channels[channel];
+ }
+
+ return (
+ data as {
+ channels: Record<
+ ChromeReleaseChannel,
+ {version: string; revision: string}
+ >;
+ }
+ ).channels[channel];
+}
+
+export async function getLastKnownGoodReleaseForMilestone(
+ milestone: string,
+): Promise<{version: string; revision: string} | undefined> {
+ const data = (await getJSON(
+ new URL(
+ 'https://googlechromelabs.github.io/chrome-for-testing/latest-versions-per-milestone.json',
+ ),
+ )) as {
+ milestones: Record;
+ };
+ return data.milestones[milestone] as
+ | {version: string; revision: string}
+ | undefined;
+}
+
+export async function getLastKnownGoodReleaseForBuild(
+ /**
+ * @example `112.0.23`,
+ */
+ buildPrefix: string,
+): Promise<{version: string; revision: string} | undefined> {
+ const data = (await getJSON(
+ new URL(
+ 'https://googlechromelabs.github.io/chrome-for-testing/latest-patch-versions-per-build.json',
+ ),
+ )) as {
+ builds: Record;
+ };
+ return data.builds[buildPrefix] as
+ | {version: string; revision: string}
+ | undefined;
+}
+
+export async function resolveBuildId(
+ channel: ChromeReleaseChannel,
+): Promise;
+export async function resolveBuildId(
+ channel: string,
+): Promise;
+export async function resolveBuildId(
+ channel: ChromeReleaseChannel | string,
+): Promise {
+ if (
+ Object.values(ChromeReleaseChannel).includes(
+ channel as ChromeReleaseChannel,
+ )
+ ) {
+ return (
+ await getLastKnownGoodReleaseForChannel(channel as ChromeReleaseChannel)
+ ).version;
+ }
+ if (channel.match(/^\d+$/)) {
+ // Potentially a milestone.
+ return (await getLastKnownGoodReleaseForMilestone(channel))?.version;
+ }
+ if (channel.match(/^\d+\.\d+\.\d+$/)) {
+ // Potentially a build prefix without the patch version.
+ return (await getLastKnownGoodReleaseForBuild(channel))?.version;
+ }
+ return;
+}
+
+export function resolveSystemExecutablePath(
+ platform: BrowserPlatform,
+ channel: ChromeReleaseChannel,
+): string {
+ switch (platform) {
+ case BrowserPlatform.WIN64:
+ case BrowserPlatform.WIN32:
+ switch (channel) {
+ case ChromeReleaseChannel.STABLE:
+ return `${process.env['PROGRAMFILES']}\\Google\\Chrome\\Application\\chrome.exe`;
+ case ChromeReleaseChannel.BETA:
+ return `${process.env['PROGRAMFILES']}\\Google\\Chrome Beta\\Application\\chrome.exe`;
+ case ChromeReleaseChannel.CANARY:
+ return `${process.env['PROGRAMFILES']}\\Google\\Chrome SxS\\Application\\chrome.exe`;
+ case ChromeReleaseChannel.DEV:
+ return `${process.env['PROGRAMFILES']}\\Google\\Chrome Dev\\Application\\chrome.exe`;
+ }
+ case BrowserPlatform.MAC_ARM:
+ case BrowserPlatform.MAC:
+ switch (channel) {
+ case ChromeReleaseChannel.STABLE:
+ return '/Applications/Google Chrome.app/Contents/MacOS/Google Chrome';
+ case ChromeReleaseChannel.BETA:
+ return '/Applications/Google Chrome Beta.app/Contents/MacOS/Google Chrome Beta';
+ case ChromeReleaseChannel.CANARY:
+ return '/Applications/Google Chrome Canary.app/Contents/MacOS/Google Chrome Canary';
+ case ChromeReleaseChannel.DEV:
+ return '/Applications/Google Chrome Dev.app/Contents/MacOS/Google Chrome Dev';
+ }
+ case BrowserPlatform.LINUX_ARM:
+ case BrowserPlatform.LINUX:
+ switch (channel) {
+ case ChromeReleaseChannel.STABLE:
+ return '/opt/google/chrome/chrome';
+ case ChromeReleaseChannel.BETA:
+ return '/opt/google/chrome-beta/chrome';
+ case ChromeReleaseChannel.CANARY:
+ return '/opt/google/chrome-canary/chrome';
+ case ChromeReleaseChannel.DEV:
+ return '/opt/google/chrome-unstable/chrome';
+ }
+ }
+}
+
+export function compareVersions(a: string, b: string): number {
+ if (!semver.valid(a)) {
+ throw new Error(`Version ${a} is not a valid semver version`);
+ }
+ if (!semver.valid(b)) {
+ throw new Error(`Version ${b} is not a valid semver version`);
+ }
+ if (semver.gt(a, b)) {
+ return 1;
+ } else if (semver.lt(a, b)) {
+ return -1;
+ } else {
+ return 0;
+ }
+}
diff --git a/node_modules/@puppeteer/browsers/src/browser-data/chromedriver.ts b/node_modules/@puppeteer/browsers/src/browser-data/chromedriver.ts
new file mode 100644
index 0000000..fd7b8bd
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/src/browser-data/chromedriver.ts
@@ -0,0 +1,58 @@
+/**
+ * @license
+ * Copyright 2023 Google Inc.
+ * SPDX-License-Identifier: Apache-2.0
+ */
+import path from 'node:path';
+
+import {BrowserPlatform} from './types.js';
+
+function folder(platform: BrowserPlatform): string {
+ switch (platform) {
+ case BrowserPlatform.LINUX_ARM:
+ case BrowserPlatform.LINUX:
+ return 'linux64';
+ case BrowserPlatform.MAC_ARM:
+ return 'mac-arm64';
+ case BrowserPlatform.MAC:
+ return 'mac-x64';
+ case BrowserPlatform.WIN32:
+ return 'win32';
+ case BrowserPlatform.WIN64:
+ return 'win64';
+ }
+}
+
+export function resolveDownloadUrl(
+ platform: BrowserPlatform,
+ buildId: string,
+ baseUrl = 'https://storage.googleapis.com/chrome-for-testing-public',
+): string {
+ return `${baseUrl}/${resolveDownloadPath(platform, buildId).join('/')}`;
+}
+
+export function resolveDownloadPath(
+ platform: BrowserPlatform,
+ buildId: string,
+): string[] {
+ return [buildId, folder(platform), `chromedriver-${folder(platform)}.zip`];
+}
+
+export function relativeExecutablePath(
+ platform: BrowserPlatform,
+ _buildId: string,
+): string {
+ switch (platform) {
+ case BrowserPlatform.MAC:
+ case BrowserPlatform.MAC_ARM:
+ return path.join('chromedriver-' + folder(platform), 'chromedriver');
+ case BrowserPlatform.LINUX_ARM:
+ case BrowserPlatform.LINUX:
+ return path.join('chromedriver-linux64', 'chromedriver');
+ case BrowserPlatform.WIN32:
+ case BrowserPlatform.WIN64:
+ return path.join('chromedriver-' + folder(platform), 'chromedriver.exe');
+ }
+}
+
+export {resolveBuildId, compareVersions} from './chrome.js';
diff --git a/node_modules/@puppeteer/browsers/src/browser-data/chromium.ts b/node_modules/@puppeteer/browsers/src/browser-data/chromium.ts
new file mode 100644
index 0000000..9b35110
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/src/browser-data/chromium.ts
@@ -0,0 +1,95 @@
+/**
+ * @license
+ * Copyright 2023 Google Inc.
+ * SPDX-License-Identifier: Apache-2.0
+ */
+
+import path from 'node:path';
+
+import {getText} from '../httpUtil.js';
+
+import {BrowserPlatform} from './types.js';
+
+function archive(platform: BrowserPlatform, buildId: string): string {
+ switch (platform) {
+ case BrowserPlatform.LINUX_ARM:
+ case BrowserPlatform.LINUX:
+ return 'chrome-linux';
+ case BrowserPlatform.MAC_ARM:
+ case BrowserPlatform.MAC:
+ return 'chrome-mac';
+ case BrowserPlatform.WIN32:
+ case BrowserPlatform.WIN64:
+ // Windows archive name changed at r591479.
+ return parseInt(buildId, 10) > 591479 ? 'chrome-win' : 'chrome-win32';
+ }
+}
+
+function folder(platform: BrowserPlatform): string {
+ switch (platform) {
+ case BrowserPlatform.LINUX_ARM:
+ case BrowserPlatform.LINUX:
+ return 'Linux_x64';
+ case BrowserPlatform.MAC_ARM:
+ return 'Mac_Arm';
+ case BrowserPlatform.MAC:
+ return 'Mac';
+ case BrowserPlatform.WIN32:
+ return 'Win';
+ case BrowserPlatform.WIN64:
+ return 'Win_x64';
+ }
+}
+
+export function resolveDownloadUrl(
+ platform: BrowserPlatform,
+ buildId: string,
+ baseUrl = 'https://storage.googleapis.com/chromium-browser-snapshots',
+): string {
+ return `${baseUrl}/${resolveDownloadPath(platform, buildId).join('/')}`;
+}
+
+export function resolveDownloadPath(
+ platform: BrowserPlatform,
+ buildId: string,
+): string[] {
+ return [folder(platform), buildId, `${archive(platform, buildId)}.zip`];
+}
+
+export function relativeExecutablePath(
+ platform: BrowserPlatform,
+ _buildId: string,
+): string {
+ switch (platform) {
+ case BrowserPlatform.MAC:
+ case BrowserPlatform.MAC_ARM:
+ return path.join(
+ 'chrome-mac',
+ 'Chromium.app',
+ 'Contents',
+ 'MacOS',
+ 'Chromium',
+ );
+ case BrowserPlatform.LINUX_ARM:
+ case BrowserPlatform.LINUX:
+ return path.join('chrome-linux', 'chrome');
+ case BrowserPlatform.WIN32:
+ case BrowserPlatform.WIN64:
+ return path.join('chrome-win', 'chrome.exe');
+ }
+}
+export async function resolveBuildId(
+ platform: BrowserPlatform,
+): Promise {
+ return await getText(
+ new URL(
+ `https://storage.googleapis.com/chromium-browser-snapshots/${folder(
+ platform,
+ )}/LAST_CHANGE`,
+ ),
+ );
+}
+
+export function compareVersions(a: string, b: string): number {
+ return Number(a) - Number(b);
+}
diff --git a/node_modules/@puppeteer/browsers/src/browser-data/firefox.ts b/node_modules/@puppeteer/browsers/src/browser-data/firefox.ts
new file mode 100644
index 0000000..cc474bc
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/src/browser-data/firefox.ts
@@ -0,0 +1,461 @@
+/**
+ * @license
+ * Copyright 2023 Google Inc.
+ * SPDX-License-Identifier: Apache-2.0
+ */
+
+import fs from 'node:fs';
+import path from 'node:path';
+
+import {getJSON} from '../httpUtil.js';
+
+import {BrowserPlatform, type ProfileOptions} from './types.js';
+
+function getFormat(buildId: string): string {
+ const majorVersion = Number(buildId.split('.').shift()!);
+ return majorVersion >= 135 ? 'xz' : 'bz2';
+}
+
+function archiveNightly(platform: BrowserPlatform, buildId: string): string {
+ switch (platform) {
+ case BrowserPlatform.LINUX:
+ return `firefox-${buildId}.en-US.linux-x86_64.tar.${getFormat(buildId)}`;
+ case BrowserPlatform.LINUX_ARM:
+ return `firefox-${buildId}.en-US.linux-aarch64.tar.${getFormat(buildId)}`;
+ case BrowserPlatform.MAC_ARM:
+ case BrowserPlatform.MAC:
+ return `firefox-${buildId}.en-US.mac.dmg`;
+ case BrowserPlatform.WIN32:
+ case BrowserPlatform.WIN64:
+ return `firefox-${buildId}.en-US.${platform}.zip`;
+ }
+}
+
+function archive(platform: BrowserPlatform, buildId: string): string {
+ switch (platform) {
+ case BrowserPlatform.LINUX_ARM:
+ case BrowserPlatform.LINUX:
+ return `firefox-${buildId}.tar.${getFormat(buildId)}`;
+ case BrowserPlatform.MAC_ARM:
+ case BrowserPlatform.MAC:
+ return `Firefox ${buildId}.dmg`;
+ case BrowserPlatform.WIN32:
+ case BrowserPlatform.WIN64:
+ return `Firefox Setup ${buildId}.exe`;
+ }
+}
+
+function platformName(platform: BrowserPlatform): string {
+ switch (platform) {
+ case BrowserPlatform.LINUX:
+ return `linux-x86_64`;
+ case BrowserPlatform.LINUX_ARM:
+ return `linux-aarch64`;
+ case BrowserPlatform.MAC_ARM:
+ case BrowserPlatform.MAC:
+ return `mac`;
+ case BrowserPlatform.WIN32:
+ case BrowserPlatform.WIN64:
+ return platform;
+ }
+}
+
+function parseBuildId(buildId: string): [FirefoxChannel, string] {
+ for (const value of Object.values(FirefoxChannel)) {
+ if (buildId.startsWith(value + '_')) {
+ buildId = buildId.substring(value.length + 1);
+ return [value, buildId];
+ }
+ }
+ // Older versions do not have channel as the prefix.«
+ return [FirefoxChannel.NIGHTLY, buildId];
+}
+
+export function resolveDownloadUrl(
+ platform: BrowserPlatform,
+ buildId: string,
+ baseUrl?: string,
+): string {
+ const [channel] = parseBuildId(buildId);
+ switch (channel) {
+ case FirefoxChannel.NIGHTLY:
+ baseUrl ??=
+ 'https://archive.mozilla.org/pub/firefox/nightly/latest-mozilla-central';
+ break;
+ case FirefoxChannel.DEVEDITION:
+ baseUrl ??= 'https://archive.mozilla.org/pub/devedition/releases';
+ break;
+ case FirefoxChannel.BETA:
+ case FirefoxChannel.STABLE:
+ case FirefoxChannel.ESR:
+ baseUrl ??= 'https://archive.mozilla.org/pub/firefox/releases';
+ break;
+ }
+ return `${baseUrl}/${resolveDownloadPath(platform, buildId).join('/')}`;
+}
+
+export function resolveDownloadPath(
+ platform: BrowserPlatform,
+ buildId: string,
+): string[] {
+ const [channel, resolvedBuildId] = parseBuildId(buildId);
+ switch (channel) {
+ case FirefoxChannel.NIGHTLY:
+ return [archiveNightly(platform, resolvedBuildId)];
+ case FirefoxChannel.DEVEDITION:
+ case FirefoxChannel.BETA:
+ case FirefoxChannel.STABLE:
+ case FirefoxChannel.ESR:
+ return [
+ resolvedBuildId,
+ platformName(platform),
+ 'en-US',
+ archive(platform, resolvedBuildId),
+ ];
+ }
+}
+
+export function relativeExecutablePath(
+ platform: BrowserPlatform,
+ buildId: string,
+): string {
+ const [channel] = parseBuildId(buildId);
+ switch (channel) {
+ case FirefoxChannel.NIGHTLY:
+ switch (platform) {
+ case BrowserPlatform.MAC_ARM:
+ case BrowserPlatform.MAC:
+ return path.join(
+ 'Firefox Nightly.app',
+ 'Contents',
+ 'MacOS',
+ 'firefox',
+ );
+ case BrowserPlatform.LINUX_ARM:
+ case BrowserPlatform.LINUX:
+ return path.join('firefox', 'firefox');
+ case BrowserPlatform.WIN32:
+ case BrowserPlatform.WIN64:
+ return path.join('firefox', 'firefox.exe');
+ }
+ case FirefoxChannel.BETA:
+ case FirefoxChannel.DEVEDITION:
+ case FirefoxChannel.ESR:
+ case FirefoxChannel.STABLE:
+ switch (platform) {
+ case BrowserPlatform.MAC_ARM:
+ case BrowserPlatform.MAC:
+ return path.join('Firefox.app', 'Contents', 'MacOS', 'firefox');
+ case BrowserPlatform.LINUX_ARM:
+ case BrowserPlatform.LINUX:
+ return path.join('firefox', 'firefox');
+ case BrowserPlatform.WIN32:
+ case BrowserPlatform.WIN64:
+ return path.join('core', 'firefox.exe');
+ }
+ }
+}
+
+export enum FirefoxChannel {
+ STABLE = 'stable',
+ ESR = 'esr',
+ DEVEDITION = 'devedition',
+ BETA = 'beta',
+ NIGHTLY = 'nightly',
+}
+
+export async function resolveBuildId(
+ channel: FirefoxChannel = FirefoxChannel.NIGHTLY,
+): Promise {
+ const channelToVersionKey = {
+ [FirefoxChannel.ESR]: 'FIREFOX_ESR',
+ [FirefoxChannel.STABLE]: 'LATEST_FIREFOX_VERSION',
+ [FirefoxChannel.DEVEDITION]: 'FIREFOX_DEVEDITION',
+ [FirefoxChannel.BETA]: 'FIREFOX_DEVEDITION',
+ [FirefoxChannel.NIGHTLY]: 'FIREFOX_NIGHTLY',
+ };
+ const versions = (await getJSON(
+ new URL('https://product-details.mozilla.org/1.0/firefox_versions.json'),
+ )) as Record;
+ const version = versions[channelToVersionKey[channel]];
+ if (!version) {
+ throw new Error(`Channel ${channel} is not found.`);
+ }
+ return channel + '_' + version;
+}
+
+export async function createProfile(options: ProfileOptions): Promise {
+ if (!fs.existsSync(options.path)) {
+ await fs.promises.mkdir(options.path, {
+ recursive: true,
+ });
+ }
+ await syncPreferences({
+ preferences: {
+ ...defaultProfilePreferences(options.preferences),
+ ...options.preferences,
+ },
+ path: options.path,
+ });
+}
+
+function defaultProfilePreferences(
+ extraPrefs: Record,
+): Record {
+ const server = 'dummy.test';
+
+ const defaultPrefs = {
+ // Make sure Shield doesn't hit the network.
+ 'app.normandy.api_url': '',
+ // Disable Firefox old build background check
+ 'app.update.checkInstallTime': false,
+ // Disable automatically upgrading Firefox
+ 'app.update.disabledForTesting': true,
+
+ // Increase the APZ content response timeout to 1 minute
+ 'apz.content_response_timeout': 60000,
+
+ // Disables backup service to improve startup performance and stability. See
+ // https://github.com/puppeteer/puppeteer/issues/14194. TODO: can be removed
+ // once the service is disabled on the Firefox side for WebDriver (see
+ // https://bugzilla.mozilla.org/show_bug.cgi?id=1988250).
+ 'browser.backup.enabled': false,
+
+ // Prevent various error message on the console
+ // jest-puppeteer asserts that no error message is emitted by the console
+ 'browser.contentblocking.features.standard':
+ '-tp,tpPrivate,cookieBehavior0,-cryptoTP,-fp',
+
+ // Enable the dump function: which sends messages to the system
+ // console
+ // https://bugzilla.mozilla.org/show_bug.cgi?id=1543115
+ 'browser.dom.window.dump.enabled': true,
+ // Disable topstories
+ 'browser.newtabpage.activity-stream.feeds.system.topstories': false,
+ // Always display a blank page
+ 'browser.newtabpage.enabled': false,
+ // Background thumbnails in particular cause grief: and disabling
+ // thumbnails in general cannot hurt
+ 'browser.pagethumbnails.capturing_disabled': true,
+
+ // Disable safebrowsing components.
+ 'browser.safebrowsing.blockedURIs.enabled': false,
+ 'browser.safebrowsing.downloads.enabled': false,
+ 'browser.safebrowsing.malware.enabled': false,
+ 'browser.safebrowsing.phishing.enabled': false,
+
+ // Disable updates to search engines.
+ 'browser.search.update': false,
+ // Do not restore the last open set of tabs if the browser has crashed
+ 'browser.sessionstore.resume_from_crash': false,
+ // Skip check for default browser on startup
+ 'browser.shell.checkDefaultBrowser': false,
+
+ // Disable newtabpage
+ 'browser.startup.homepage': 'about:blank',
+ // Do not redirect user when a milstone upgrade of Firefox is detected
+ 'browser.startup.homepage_override.mstone': 'ignore',
+ // Start with a blank page about:blank
+ 'browser.startup.page': 0,
+
+ // Do not allow background tabs to be zombified on Android: otherwise for
+ // tests that open additional tabs: the test harness tab itself might get
+ // unloaded
+ 'browser.tabs.disableBackgroundZombification': false,
+ // Do not warn when closing all other open tabs
+ 'browser.tabs.warnOnCloseOtherTabs': false,
+ // Do not warn when multiple tabs will be opened
+ 'browser.tabs.warnOnOpen': false,
+
+ // Do not automatically offer translations, as tests do not expect this.
+ 'browser.translations.automaticallyPopup': false,
+
+ // Disable the UI tour.
+ 'browser.uitour.enabled': false,
+ // Turn off search suggestions in the location bar so as not to trigger
+ // network connections.
+ 'browser.urlbar.suggest.searches': false,
+ // Disable first run splash page on Windows 10
+ 'browser.usedOnWindows10.introURL': '',
+ // Do not warn on quitting Firefox
+ 'browser.warnOnQuit': false,
+
+ // Defensively disable data reporting systems
+ 'datareporting.healthreport.documentServerURI': `http://${server}/dummy/healthreport/`,
+ 'datareporting.healthreport.logging.consoleEnabled': false,
+ 'datareporting.healthreport.service.enabled': false,
+ 'datareporting.healthreport.service.firstRun': false,
+ 'datareporting.healthreport.uploadEnabled': false,
+
+ // Do not show datareporting policy notifications which can interfere with tests
+ 'datareporting.policy.dataSubmissionEnabled': false,
+ 'datareporting.policy.dataSubmissionPolicyBypassNotification': true,
+
+ // DevTools JSONViewer sometimes fails to load dependencies with its require.js.
+ // This doesn't affect Puppeteer but spams console (Bug 1424372)
+ 'devtools.jsonview.enabled': false,
+
+ // Disable popup-blocker
+ 'dom.disable_open_during_load': false,
+
+ // Enable the support for File object creation in the content process
+ // Required for |Page.setFileInputFiles| protocol method.
+ 'dom.file.createInChild': true,
+
+ // Disable the ProcessHangMonitor
+ 'dom.ipc.reportProcessHangs': false,
+
+ // Disable slow script dialogues
+ 'dom.max_chrome_script_run_time': 0,
+ 'dom.max_script_run_time': 0,
+
+ // Only load extensions from the application and user profile
+ // AddonManager.SCOPE_PROFILE + AddonManager.SCOPE_APPLICATION
+ 'extensions.autoDisableScopes': 0,
+ 'extensions.enabledScopes': 5,
+
+ // Disable metadata caching for installed add-ons by default
+ 'extensions.getAddons.cache.enabled': false,
+
+ // Disable installing any distribution extensions or add-ons.
+ 'extensions.installDistroAddons': false,
+
+ // Turn off extension updates so they do not bother tests
+ 'extensions.update.enabled': false,
+
+ // Turn off extension updates so they do not bother tests
+ 'extensions.update.notifyUser': false,
+
+ // Make sure opening about:addons will not hit the network
+ 'extensions.webservice.discoverURL': `http://${server}/dummy/discoveryURL`,
+
+ // Allow the application to have focus even it runs in the background
+ 'focusmanager.testmode': true,
+
+ // Disable useragent updates
+ 'general.useragent.updates.enabled': false,
+
+ // Always use network provider for geolocation tests so we bypass the
+ // macOS dialog raised by the corelocation provider
+ 'geo.provider.testing': true,
+
+ // Do not scan Wifi
+ 'geo.wifi.scan': false,
+
+ // No hang monitor
+ 'hangmonitor.timeout': 0,
+
+ // Show chrome errors and warnings in the error console
+ 'javascript.options.showInConsole': true,
+
+ // Disable download and usage of OpenH264: and Widevine plugins
+ 'media.gmp-manager.updateEnabled': false,
+
+ // Disable the GFX sanity window
+ 'media.sanity-test.disabled': true,
+
+ // Disable experimental feature that is only available in Nightly
+ 'network.cookie.sameSite.laxByDefault': false,
+
+ // Do not prompt for temporary redirects
+ 'network.http.prompt-temp-redirect': false,
+
+ // Disable speculative connections so they are not reported as leaking
+ // when they are hanging around
+ 'network.http.speculative-parallel-limit': 0,
+
+ // Do not automatically switch between offline and online
+ 'network.manage-offline-status': false,
+
+ // Make sure SNTP requests do not hit the network
+ 'network.sntp.pools': server,
+
+ // Disable Flash.
+ 'plugin.state.flash': 0,
+
+ 'privacy.trackingprotection.enabled': false,
+
+ // Can be removed once Firefox 89 is no longer supported
+ // https://bugzilla.mozilla.org/show_bug.cgi?id=1710839
+ 'remote.enabled': true,
+
+ // Disabled screenshots component
+ 'screenshots.browser.component.enabled': false,
+
+ // Don't do network connections for mitm priming
+ 'security.certerrors.mitm.priming.enabled': false,
+
+ // Local documents have access to all other local documents,
+ // including directory listings
+ 'security.fileuri.strict_origin_policy': false,
+
+ // Do not wait for the notification button security delay
+ 'security.notification_enable_delay': 0,
+
+ // Ensure blocklist updates do not hit the network
+ 'services.settings.server': `http://${server}/dummy/blocklist/`,
+
+ // Do not automatically fill sign-in forms with known usernames and
+ // passwords
+ 'signon.autofillForms': false,
+
+ // Disable password capture, so that tests that include forms are not
+ // influenced by the presence of the persistent doorhanger notification
+ 'signon.rememberSignons': false,
+
+ // Disable first-run welcome page
+ 'startup.homepage_welcome_url': 'about:blank',
+
+ // Disable first-run welcome page
+ 'startup.homepage_welcome_url.additional': '',
+
+ // Disable browser animations (tabs, fullscreen, sliding alerts)
+ 'toolkit.cosmeticAnimations.enabled': false,
+
+ // Prevent starting into safe mode after application crashes
+ 'toolkit.startup.max_resumed_crashes': -1,
+ };
+
+ return Object.assign(defaultPrefs, extraPrefs);
+}
+
+async function backupFile(input: string): Promise {
+ if (!fs.existsSync(input)) {
+ return;
+ }
+ await fs.promises.copyFile(input, input + '.puppeteer');
+}
+
+/**
+ * Populates the user.js file with custom preferences as needed to allow
+ * Firefox's support to properly function. These preferences will be
+ * automatically copied over to prefs.js during startup of Firefox. To be
+ * able to restore the original values of preferences a backup of prefs.js
+ * will be created.
+ */
+async function syncPreferences(options: ProfileOptions): Promise {
+ const prefsPath = path.join(options.path, 'prefs.js');
+ const userPath = path.join(options.path, 'user.js');
+
+ const lines = Object.entries(options.preferences).map(([key, value]) => {
+ return `user_pref(${JSON.stringify(key)}, ${JSON.stringify(value)});`;
+ });
+
+ // Use allSettled to prevent corruption.
+ const result = await Promise.allSettled([
+ backupFile(userPath).then(async () => {
+ await fs.promises.writeFile(userPath, lines.join('\n'));
+ }),
+ backupFile(prefsPath),
+ ]);
+ for (const command of result) {
+ if (command.status === 'rejected') {
+ throw command.reason;
+ }
+ }
+}
+
+export function compareVersions(a: string, b: string): number {
+ // TODO: this is a not very reliable check.
+ return parseInt(a.replace('.', ''), 16) - parseInt(b.replace('.', ''), 16);
+}
diff --git a/node_modules/@puppeteer/browsers/src/browser-data/types.ts b/node_modules/@puppeteer/browsers/src/browser-data/types.ts
new file mode 100644
index 0000000..ee4f2a9
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/src/browser-data/types.ts
@@ -0,0 +1,70 @@
+/**
+ * @license
+ * Copyright 2023 Google Inc.
+ * SPDX-License-Identifier: Apache-2.0
+ */
+
+/**
+ * Supported browsers.
+ *
+ * @public
+ */
+export enum Browser {
+ CHROME = 'chrome',
+ CHROMEHEADLESSSHELL = 'chrome-headless-shell',
+ CHROMIUM = 'chromium',
+ FIREFOX = 'firefox',
+ CHROMEDRIVER = 'chromedriver',
+}
+
+/**
+ * Platform names used to identify a OS platform x architecture combination in the way
+ * that is relevant for the browser download.
+ *
+ * @public
+ */
+export enum BrowserPlatform {
+ LINUX = 'linux',
+ LINUX_ARM = 'linux_arm',
+ MAC = 'mac',
+ MAC_ARM = 'mac_arm',
+ WIN32 = 'win32',
+ WIN64 = 'win64',
+}
+
+/**
+ * Enum describing a release channel for a browser.
+ *
+ * You can use this in combination with {@link resolveBuildId} to resolve
+ * a build ID based on a release channel.
+ *
+ * @public
+ */
+export enum BrowserTag {
+ CANARY = 'canary',
+ NIGHTLY = 'nightly',
+ BETA = 'beta',
+ DEV = 'dev',
+ DEVEDITION = 'devedition',
+ STABLE = 'stable',
+ ESR = 'esr',
+ LATEST = 'latest',
+}
+
+/**
+ * @public
+ */
+export interface ProfileOptions {
+ preferences: Record;
+ path: string;
+}
+
+/**
+ * @public
+ */
+export enum ChromeReleaseChannel {
+ STABLE = 'stable',
+ DEV = 'dev',
+ CANARY = 'canary',
+ BETA = 'beta',
+}
diff --git a/node_modules/@puppeteer/browsers/src/debug.ts b/node_modules/@puppeteer/browsers/src/debug.ts
new file mode 100644
index 0000000..491097f
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/src/debug.ts
@@ -0,0 +1,9 @@
+/**
+ * @license
+ * Copyright 2023 Google Inc.
+ * SPDX-License-Identifier: Apache-2.0
+ */
+
+import debug from 'debug';
+
+export {debug};
diff --git a/node_modules/@puppeteer/browsers/src/detectPlatform.ts b/node_modules/@puppeteer/browsers/src/detectPlatform.ts
new file mode 100644
index 0000000..1a87c20
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/src/detectPlatform.ts
@@ -0,0 +1,52 @@
+/**
+ * @license
+ * Copyright 2023 Google Inc.
+ * SPDX-License-Identifier: Apache-2.0
+ */
+
+import os from 'node:os';
+
+import {BrowserPlatform} from './browser-data/browser-data.js';
+
+/**
+ * @public
+ */
+export function detectBrowserPlatform(): BrowserPlatform | undefined {
+ const platform = os.platform();
+ const arch = os.arch();
+ switch (platform) {
+ case 'darwin':
+ return arch === 'arm64' ? BrowserPlatform.MAC_ARM : BrowserPlatform.MAC;
+ case 'linux':
+ return arch === 'arm64'
+ ? BrowserPlatform.LINUX_ARM
+ : BrowserPlatform.LINUX;
+ case 'win32':
+ return arch === 'x64' ||
+ // Windows 11 for ARM supports x64 emulation
+ (arch === 'arm64' && isWindows11(os.release()))
+ ? BrowserPlatform.WIN64
+ : BrowserPlatform.WIN32;
+ default:
+ return undefined;
+ }
+}
+
+/**
+ * Windows 11 is identified by the version 10.0.22000 or greater
+ * @internal
+ */
+function isWindows11(version: string): boolean {
+ const parts = version.split('.');
+ if (parts.length > 2) {
+ const major = parseInt(parts[0] as string, 10);
+ const minor = parseInt(parts[1] as string, 10);
+ const patch = parseInt(parts[2] as string, 10);
+ return (
+ major > 10 ||
+ (major === 10 && minor > 0) ||
+ (major === 10 && minor === 0 && patch >= 22000)
+ );
+ }
+ return false;
+}
diff --git a/node_modules/@puppeteer/browsers/src/fileUtil.ts b/node_modules/@puppeteer/browsers/src/fileUtil.ts
new file mode 100644
index 0000000..e287646
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/src/fileUtil.ts
@@ -0,0 +1,183 @@
+/**
+ * @license
+ * Copyright 2023 Google Inc.
+ * SPDX-License-Identifier: Apache-2.0
+ */
+
+import type {ChildProcessByStdio} from 'node:child_process';
+import {spawnSync, spawn} from 'node:child_process';
+import {createReadStream} from 'node:fs';
+import {mkdir, readdir} from 'node:fs/promises';
+import * as path from 'node:path';
+import type {Readable, Transform, Writable} from 'node:stream';
+import {Stream} from 'node:stream';
+
+import debug from 'debug';
+
+const debugFileUtil = debug('puppeteer:browsers:fileUtil');
+
+/**
+ * @internal
+ */
+export async function unpackArchive(
+ archivePath: string,
+ folderPath: string,
+): Promise {
+ if (!path.isAbsolute(folderPath)) {
+ folderPath = path.resolve(process.cwd(), folderPath);
+ }
+ if (archivePath.endsWith('.zip')) {
+ const extractZip = await import('extract-zip');
+ await extractZip.default(archivePath, {dir: folderPath});
+ } else if (archivePath.endsWith('.tar.bz2')) {
+ await extractTar(archivePath, folderPath, 'bzip2');
+ } else if (archivePath.endsWith('.dmg')) {
+ await mkdir(folderPath);
+ await installDMG(archivePath, folderPath);
+ } else if (archivePath.endsWith('.exe')) {
+ // Firefox on Windows.
+ const result = spawnSync(archivePath, [`/ExtractDir=${folderPath}`], {
+ env: {
+ __compat_layer: 'RunAsInvoker',
+ },
+ });
+ if (result.status !== 0) {
+ throw new Error(
+ `Failed to extract ${archivePath} to ${folderPath}: ${result.output}`,
+ );
+ }
+ } else if (archivePath.endsWith('.tar.xz')) {
+ await extractTar(archivePath, folderPath, 'xz');
+ } else {
+ throw new Error(`Unsupported archive format: ${archivePath}`);
+ }
+}
+
+function createTransformStream(
+ child: ChildProcessByStdio,
+): Transform {
+ const stream = new Stream.Transform({
+ transform(chunk, encoding, callback) {
+ if (!child.stdin.write(chunk, encoding)) {
+ child.stdin.once('drain', callback);
+ } else {
+ callback();
+ }
+ },
+
+ flush(callback) {
+ if (child.stdout.destroyed) {
+ callback();
+ } else {
+ child.stdin.end();
+ child.stdout.on('close', callback);
+ }
+ },
+ });
+
+ child.stdin.on('error', e => {
+ if ('code' in e && e.code === 'EPIPE') {
+ // finished before reading the file finished (i.e. head)
+ stream.emit('end');
+ } else {
+ stream.destroy(e);
+ }
+ });
+
+ child.stdout
+ .on('data', data => {
+ return stream.push(data);
+ })
+ .on('error', e => {
+ return stream.destroy(e);
+ });
+
+ child.once('close', () => {
+ return stream.end();
+ });
+
+ return stream;
+}
+
+/**
+ * @internal
+ */
+export const internalConstantsForTesting = {
+ xz: 'xz',
+ bzip2: 'bzip2',
+};
+
+/**
+ * @internal
+ */
+async function extractTar(
+ tarPath: string,
+ folderPath: string,
+ decompressUtilityName: keyof typeof internalConstantsForTesting,
+): Promise {
+ const tarFs = await import('tar-fs');
+ return await new Promise((fulfill, reject) => {
+ function handleError(utilityName: string) {
+ return (error: Error) => {
+ if ('code' in error && error.code === 'ENOENT') {
+ error = new Error(
+ `\`${utilityName}\` utility is required to unpack this archive`,
+ {
+ cause: error,
+ },
+ );
+ }
+ reject(error);
+ };
+ }
+ const unpack = spawn(
+ internalConstantsForTesting[decompressUtilityName],
+ ['-d'],
+ {
+ stdio: ['pipe', 'pipe', 'inherit'],
+ },
+ )
+ .once('error', handleError(decompressUtilityName))
+ .once('exit', code => {
+ debugFileUtil(`${decompressUtilityName} exited, code=${code}`);
+ });
+
+ const tar = tarFs.extract(folderPath);
+ tar.once('error', handleError('tar'));
+ tar.once('finish', fulfill);
+ createReadStream(tarPath).pipe(createTransformStream(unpack)).pipe(tar);
+ });
+}
+
+/**
+ * @internal
+ */
+async function installDMG(dmgPath: string, folderPath: string): Promise {
+ const {stdout} = spawnSync(`hdiutil`, [
+ 'attach',
+ '-nobrowse',
+ '-noautoopen',
+ dmgPath,
+ ]);
+
+ const volumes = stdout.toString('utf8').match(/\/Volumes\/(.*)/m);
+ if (!volumes) {
+ throw new Error(`Could not find volume path in ${stdout}`);
+ }
+ const mountPath = volumes[0]!;
+
+ try {
+ const fileNames = await readdir(mountPath);
+ const appName = fileNames.find(item => {
+ return typeof item === 'string' && item.endsWith('.app');
+ });
+ if (!appName) {
+ throw new Error(`Cannot find app in ${mountPath}`);
+ }
+ const mountedPath = path.join(mountPath!, appName);
+
+ spawnSync('cp', ['-R', mountedPath, folderPath]);
+ } finally {
+ spawnSync('hdiutil', ['detach', mountPath, '-quiet']);
+ }
+}
diff --git a/node_modules/@puppeteer/browsers/src/generated/version.ts b/node_modules/@puppeteer/browsers/src/generated/version.ts
new file mode 100644
index 0000000..6e21817
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/src/generated/version.ts
@@ -0,0 +1,4 @@
+/**
+ * @internal
+ */
+export const packageVersion = '2.10.10';
diff --git a/node_modules/@puppeteer/browsers/src/httpUtil.ts b/node_modules/@puppeteer/browsers/src/httpUtil.ts
new file mode 100644
index 0000000..58647da
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/src/httpUtil.ts
@@ -0,0 +1,162 @@
+/**
+ * @license
+ * Copyright 2023 Google Inc.
+ * SPDX-License-Identifier: Apache-2.0
+ */
+
+import {createWriteStream} from 'node:fs';
+import * as http from 'node:http';
+import * as https from 'node:https';
+import {URL, urlToHttpOptions} from 'node:url';
+
+import {ProxyAgent} from 'proxy-agent';
+
+export function headHttpRequest(url: URL): Promise {
+ return new Promise(resolve => {
+ const request = httpRequest(
+ url,
+ 'HEAD',
+ response => {
+ // consume response data free node process
+ response.resume();
+ resolve(response.statusCode === 200);
+ },
+ false,
+ );
+ request.on('error', () => {
+ resolve(false);
+ });
+ });
+}
+
+export function httpRequest(
+ url: URL,
+ method: string,
+ response: (x: http.IncomingMessage) => void,
+ keepAlive = true,
+): http.ClientRequest {
+ const options: http.RequestOptions = {
+ protocol: url.protocol,
+ hostname: url.hostname,
+ port: url.port,
+ path: url.pathname + url.search,
+ method,
+ headers: keepAlive ? {Connection: 'keep-alive'} : undefined,
+ auth: urlToHttpOptions(url).auth,
+ agent: new ProxyAgent(),
+ };
+
+ const requestCallback = (res: http.IncomingMessage): void => {
+ if (
+ res.statusCode &&
+ res.statusCode >= 300 &&
+ res.statusCode < 400 &&
+ res.headers.location
+ ) {
+ httpRequest(new URL(res.headers.location), method, response);
+ // consume response data to free up memory
+ // And prevents the connection from being kept alive
+ res.resume();
+ } else {
+ response(res);
+ }
+ };
+ const request =
+ options.protocol === 'https:'
+ ? https.request(options, requestCallback)
+ : http.request(options, requestCallback);
+ request.end();
+ return request;
+}
+
+/**
+ * @internal
+ */
+export function downloadFile(
+ url: URL,
+ destinationPath: string,
+ progressCallback?: (downloadedBytes: number, totalBytes: number) => void,
+): Promise {
+ return new Promise((resolve, reject) => {
+ let downloadedBytes = 0;
+ let totalBytes = 0;
+
+ function onData(chunk: string): void {
+ downloadedBytes += chunk.length;
+ progressCallback!(downloadedBytes, totalBytes);
+ }
+
+ const request = httpRequest(url, 'GET', response => {
+ if (response.statusCode !== 200) {
+ const error = new Error(
+ `Download failed: server returned code ${response.statusCode}. URL: ${url}`,
+ );
+ // consume response data to free up memory
+ response.resume();
+ reject(error);
+ return;
+ }
+ const file = createWriteStream(destinationPath);
+ file.on('close', () => {
+ // The 'close' event is emitted when the stream and any of its
+ // underlying resources (a file descriptor, for example) have been
+ // closed. The event indicates that no more events will be emitted, and
+ // no further computation will occur.
+ return resolve();
+ });
+ file.on('error', error => {
+ // The 'error' event may be emitted by a Readable implementation at any
+ // time. Typically, this may occur if the underlying stream is unable to
+ // generate data due to an underlying internal failure, or when a stream
+ // implementation attempts to push an invalid chunk of data.
+ return reject(error);
+ });
+ response.pipe(file);
+ totalBytes = parseInt(response.headers['content-length']!, 10);
+ if (progressCallback) {
+ response.on('data', onData);
+ }
+ });
+ request.on('error', error => {
+ return reject(error);
+ });
+ });
+}
+
+export async function getJSON(url: URL): Promise {
+ const text = await getText(url);
+ try {
+ return JSON.parse(text);
+ } catch {
+ throw new Error('Could not parse JSON from ' + url.toString());
+ }
+}
+
+export function getText(url: URL): Promise {
+ return new Promise((resolve, reject) => {
+ const request = httpRequest(
+ url,
+ 'GET',
+ response => {
+ let data = '';
+ if (response.statusCode && response.statusCode >= 400) {
+ return reject(new Error(`Got status code ${response.statusCode}`));
+ }
+ response.on('data', chunk => {
+ data += chunk;
+ });
+ response.on('end', () => {
+ try {
+ return resolve(String(data));
+ } catch {
+ return reject(new Error('Chrome version not found'));
+ }
+ });
+ },
+ false,
+ );
+ request.on('error', err => {
+ reject(err);
+ });
+ });
+}
diff --git a/node_modules/@puppeteer/browsers/src/install.ts b/node_modules/@puppeteer/browsers/src/install.ts
new file mode 100644
index 0000000..056497e
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/src/install.ts
@@ -0,0 +1,522 @@
+/**
+ * @license
+ * Copyright 2017 Google Inc.
+ * SPDX-License-Identifier: Apache-2.0
+ */
+
+import assert from 'node:assert';
+import {spawnSync} from 'node:child_process';
+import {existsSync, readFileSync} from 'node:fs';
+import {mkdir, unlink} from 'node:fs/promises';
+import os from 'node:os';
+import path from 'node:path';
+
+import type * as ProgressBar from 'progress';
+import ProgressBarClass from 'progress';
+
+import {
+ Browser,
+ BrowserPlatform,
+ downloadUrls,
+} from './browser-data/browser-data.js';
+import {Cache, InstalledBrowser} from './Cache.js';
+import {debug} from './debug.js';
+import {detectBrowserPlatform} from './detectPlatform.js';
+import {unpackArchive} from './fileUtil.js';
+import {downloadFile, getJSON, headHttpRequest} from './httpUtil.js';
+
+const debugInstall = debug('puppeteer:browsers:install');
+
+const times = new Map();
+function debugTime(label: string) {
+ times.set(label, process.hrtime());
+}
+
+function debugTimeEnd(label: string) {
+ const end = process.hrtime();
+ const start = times.get(label);
+ if (!start) {
+ return;
+ }
+ const duration =
+ end[0] * 1000 + end[1] / 1e6 - (start[0] * 1000 + start[1] / 1e6); // calculate duration in milliseconds
+ debugInstall(`Duration for ${label}: ${duration}ms`);
+}
+
+/**
+ * @public
+ */
+export interface InstallOptions {
+ /**
+ * Determines the path to download browsers to.
+ */
+ cacheDir: string;
+ /**
+ * Determines which platform the browser will be suited for.
+ *
+ * @defaultValue **Auto-detected.**
+ */
+ platform?: BrowserPlatform;
+ /**
+ * Determines which browser to install.
+ */
+ browser: Browser;
+ /**
+ * Determines which buildId to download. BuildId should uniquely identify
+ * binaries and they are used for caching.
+ */
+ buildId: string;
+ /**
+ * An alias for the provided `buildId`. It will be used to maintain local
+ * metadata to support aliases in the `launch` command.
+ *
+ * @example 'canary'
+ */
+ buildIdAlias?: string;
+ /**
+ * Provides information about the progress of the download. If set to
+ * 'default', the default callback implementing a progress bar will be
+ * used.
+ */
+ downloadProgressCallback?:
+ | 'default'
+ | ((downloadedBytes: number, totalBytes: number) => void);
+ /**
+ * Determines the host that will be used for downloading.
+ *
+ * @defaultValue Either
+ *
+ * - https://storage.googleapis.com/chrome-for-testing-public or
+ * - https://archive.mozilla.org/pub/firefox/nightly/latest-mozilla-central
+ *
+ */
+ baseUrl?: string;
+ /**
+ * Whether to unpack and install browser archives.
+ *
+ * @defaultValue `true`
+ */
+ unpack?: boolean;
+ /**
+ * @internal
+ * @defaultValue `false`
+ */
+ forceFallbackForTesting?: boolean;
+
+ /**
+ * Whether to attempt to install system-level dependencies required
+ * for the browser.
+ *
+ * Only supported for Chrome on Debian or Ubuntu.
+ * Requires system-level privileges to run `apt-get`.
+ *
+ * @defaultValue `false`
+ */
+ installDeps?: boolean;
+}
+
+/**
+ * Downloads and unpacks the browser archive according to the
+ * {@link InstallOptions}.
+ *
+ * @returns a {@link InstalledBrowser} instance.
+ *
+ * @public
+ */
+export function install(
+ options: InstallOptions & {unpack?: true},
+): Promise;
+/**
+ * Downloads the browser archive according to the {@link InstallOptions} without
+ * unpacking.
+ *
+ * @returns the absolute path to the archive.
+ *
+ * @public
+ */
+export function install(
+ options: InstallOptions & {unpack: false},
+): Promise;
+export async function install(
+ options: InstallOptions,
+): Promise {
+ options.platform ??= detectBrowserPlatform();
+ options.unpack ??= true;
+ if (!options.platform) {
+ throw new Error(
+ `Cannot download a binary for the provided platform: ${os.platform()} (${os.arch()})`,
+ );
+ }
+ const url = getDownloadUrl(
+ options.browser,
+ options.platform,
+ options.buildId,
+ options.baseUrl,
+ );
+ try {
+ return await installUrl(url, options);
+ } catch (err) {
+ // If custom baseUrl is provided, do not fall back to CfT dashboard.
+ if (options.baseUrl && !options.forceFallbackForTesting) {
+ throw err;
+ }
+ debugInstall(`Error downloading from ${url}.`);
+ switch (options.browser) {
+ case Browser.CHROME:
+ case Browser.CHROMEDRIVER:
+ case Browser.CHROMEHEADLESSSHELL: {
+ debugInstall(
+ `Trying to find download URL via https://googlechromelabs.github.io/chrome-for-testing.`,
+ );
+ interface Version {
+ downloads: Record>;
+ }
+ const version = (await getJSON(
+ new URL(
+ `https://googlechromelabs.github.io/chrome-for-testing/${options.buildId}.json`,
+ ),
+ )) as Version;
+ let platform = '';
+ switch (options.platform) {
+ case BrowserPlatform.LINUX:
+ platform = 'linux64';
+ break;
+ case BrowserPlatform.MAC_ARM:
+ platform = 'mac-arm64';
+ break;
+ case BrowserPlatform.MAC:
+ platform = 'mac-x64';
+ break;
+ case BrowserPlatform.WIN32:
+ platform = 'win32';
+ break;
+ case BrowserPlatform.WIN64:
+ platform = 'win64';
+ break;
+ }
+ const backupUrl = version.downloads[options.browser]?.find(link => {
+ return link['platform'] === platform;
+ })?.url;
+ if (backupUrl) {
+ // If the URL is the same, skip the retry.
+ if (backupUrl === url.toString()) {
+ throw err;
+ }
+ debugInstall(`Falling back to downloading from ${backupUrl}.`);
+ return await installUrl(new URL(backupUrl), options);
+ }
+ throw err;
+ }
+ default:
+ throw err;
+ }
+ }
+}
+
+async function installDeps(installedBrowser: InstalledBrowser) {
+ if (
+ process.platform !== 'linux' ||
+ installedBrowser.platform !== BrowserPlatform.LINUX
+ ) {
+ return;
+ }
+ // Currently, only Debian-like deps are supported.
+ const depsPath = path.join(
+ path.dirname(installedBrowser.executablePath),
+ 'deb.deps',
+ );
+ if (!existsSync(depsPath)) {
+ debugInstall(`deb.deps file was not found at ${depsPath}`);
+ return;
+ }
+ const data = readFileSync(depsPath, 'utf-8').split('\n').join(',');
+ if (process.getuid?.() !== 0) {
+ throw new Error('Installing system dependencies requires root privileges');
+ }
+ let result = spawnSync('apt-get', ['-v']);
+ if (result.status !== 0) {
+ throw new Error(
+ 'Failed to install system dependencies: apt-get does not seem to be available',
+ );
+ }
+ debugInstall(`Trying to install dependencies: ${data}`);
+ result = spawnSync('apt-get', [
+ 'satisfy',
+ '-y',
+ data,
+ '--no-install-recommends',
+ ]);
+ if (result.status !== 0) {
+ throw new Error(
+ `Failed to install system dependencies: status=${result.status},error=${result.error},stdout=${result.stdout.toString('utf8')},stderr=${result.stderr.toString('utf8')}`,
+ );
+ }
+ debugInstall(`Installed system dependencies ${data}`);
+}
+
+async function installUrl(
+ url: URL,
+ options: InstallOptions,
+): Promise {
+ options.platform ??= detectBrowserPlatform();
+ if (!options.platform) {
+ throw new Error(
+ `Cannot download a binary for the provided platform: ${os.platform()} (${os.arch()})`,
+ );
+ }
+ let downloadProgressCallback = options.downloadProgressCallback;
+ if (downloadProgressCallback === 'default') {
+ downloadProgressCallback = await makeProgressCallback(
+ options.browser,
+ options.buildIdAlias ?? options.buildId,
+ );
+ }
+ const fileName = decodeURIComponent(url.toString()).split('/').pop();
+ assert(fileName, `A malformed download URL was found: ${url}.`);
+ const cache = new Cache(options.cacheDir);
+ const browserRoot = cache.browserRoot(options.browser);
+ const archivePath = path.join(browserRoot, `${options.buildId}-${fileName}`);
+ if (!existsSync(browserRoot)) {
+ await mkdir(browserRoot, {recursive: true});
+ }
+
+ if (!options.unpack) {
+ if (existsSync(archivePath)) {
+ return archivePath;
+ }
+ debugInstall(`Downloading binary from ${url}`);
+ debugTime('download');
+ await downloadFile(url, archivePath, downloadProgressCallback);
+ debugTimeEnd('download');
+ return archivePath;
+ }
+
+ const outputPath = cache.installationDir(
+ options.browser,
+ options.platform,
+ options.buildId,
+ );
+
+ try {
+ if (existsSync(outputPath)) {
+ const installedBrowser = new InstalledBrowser(
+ cache,
+ options.browser,
+ options.buildId,
+ options.platform,
+ );
+ if (!existsSync(installedBrowser.executablePath)) {
+ throw new Error(
+ `The browser folder (${outputPath}) exists but the executable (${installedBrowser.executablePath}) is missing`,
+ );
+ }
+ await runSetup(installedBrowser);
+ if (options.installDeps) {
+ await installDeps(installedBrowser);
+ }
+ return installedBrowser;
+ }
+ debugInstall(`Downloading binary from ${url}`);
+ try {
+ debugTime('download');
+ await downloadFile(url, archivePath, downloadProgressCallback);
+ } finally {
+ debugTimeEnd('download');
+ }
+
+ debugInstall(`Installing ${archivePath} to ${outputPath}`);
+ try {
+ debugTime('extract');
+ await unpackArchive(archivePath, outputPath);
+ } finally {
+ debugTimeEnd('extract');
+ }
+
+ const installedBrowser = new InstalledBrowser(
+ cache,
+ options.browser,
+ options.buildId,
+ options.platform,
+ );
+ if (options.buildIdAlias) {
+ const metadata = installedBrowser.readMetadata();
+ metadata.aliases[options.buildIdAlias] = options.buildId;
+ installedBrowser.writeMetadata(metadata);
+ }
+
+ await runSetup(installedBrowser);
+ if (options.installDeps) {
+ await installDeps(installedBrowser);
+ }
+ return installedBrowser;
+ } finally {
+ if (existsSync(archivePath)) {
+ await unlink(archivePath);
+ }
+ }
+}
+
+async function runSetup(installedBrowser: InstalledBrowser): Promise {
+ // On Windows for Chrome invoke setup.exe to configure sandboxes.
+ if (
+ (installedBrowser.platform === BrowserPlatform.WIN32 ||
+ installedBrowser.platform === BrowserPlatform.WIN64) &&
+ installedBrowser.browser === Browser.CHROME &&
+ installedBrowser.platform === detectBrowserPlatform()
+ ) {
+ try {
+ debugTime('permissions');
+ const browserDir = path.dirname(installedBrowser.executablePath);
+ const setupExePath = path.join(browserDir, 'setup.exe');
+ if (!existsSync(setupExePath)) {
+ return;
+ }
+ spawnSync(
+ path.join(browserDir, 'setup.exe'),
+ [`--configure-browser-in-directory=` + browserDir],
+ {
+ shell: true,
+ },
+ );
+ // TODO: Handle error here. Currently the setup.exe sometimes
+ // errors although it sets the permissions correctly.
+ } finally {
+ debugTimeEnd('permissions');
+ }
+ }
+}
+
+/**
+ * @public
+ */
+export interface UninstallOptions {
+ /**
+ * Determines the platform for the browser binary.
+ *
+ * @defaultValue **Auto-detected.**
+ */
+ platform?: BrowserPlatform;
+ /**
+ * The path to the root of the cache directory.
+ */
+ cacheDir: string;
+ /**
+ * Determines which browser to uninstall.
+ */
+ browser: Browser;
+ /**
+ * The browser build to uninstall
+ */
+ buildId: string;
+}
+
+/**
+ *
+ * @public
+ */
+export async function uninstall(options: UninstallOptions): Promise {
+ options.platform ??= detectBrowserPlatform();
+ if (!options.platform) {
+ throw new Error(
+ `Cannot detect the browser platform for: ${os.platform()} (${os.arch()})`,
+ );
+ }
+
+ new Cache(options.cacheDir).uninstall(
+ options.browser,
+ options.platform,
+ options.buildId,
+ );
+}
+
+/**
+ * @public
+ */
+export interface GetInstalledBrowsersOptions {
+ /**
+ * The path to the root of the cache directory.
+ */
+ cacheDir: string;
+}
+
+/**
+ * Returns metadata about browsers installed in the cache directory.
+ *
+ * @public
+ */
+export async function getInstalledBrowsers(
+ options: GetInstalledBrowsersOptions,
+): Promise {
+ return new Cache(options.cacheDir).getInstalledBrowsers();
+}
+
+/**
+ * @public
+ */
+export async function canDownload(options: InstallOptions): Promise {
+ options.platform ??= detectBrowserPlatform();
+ if (!options.platform) {
+ throw new Error(
+ `Cannot download a binary for the provided platform: ${os.platform()} (${os.arch()})`,
+ );
+ }
+ return await headHttpRequest(
+ getDownloadUrl(
+ options.browser,
+ options.platform,
+ options.buildId,
+ options.baseUrl,
+ ),
+ );
+}
+
+/**
+ * Retrieves a URL for downloading the binary archive of a given browser.
+ *
+ * The archive is bound to the specific platform and build ID specified.
+ *
+ * @public
+ */
+export function getDownloadUrl(
+ browser: Browser,
+ platform: BrowserPlatform,
+ buildId: string,
+ baseUrl?: string,
+): URL {
+ return new URL(downloadUrls[browser](platform, buildId, baseUrl));
+}
+
+/**
+ * @public
+ */
+export function makeProgressCallback(
+ browser: Browser,
+ buildId: string,
+): (downloadedBytes: number, totalBytes: number) => void {
+ let progressBar: ProgressBar;
+
+ let lastDownloadedBytes = 0;
+ return (downloadedBytes: number, totalBytes: number) => {
+ if (!progressBar) {
+ progressBar = new ProgressBarClass(
+ `Downloading ${browser} ${buildId} - ${toMegabytes(
+ totalBytes,
+ )} [:bar] :percent :etas `,
+ {
+ complete: '=',
+ incomplete: ' ',
+ width: 20,
+ total: totalBytes,
+ },
+ );
+ }
+ const delta = downloadedBytes - lastDownloadedBytes;
+ lastDownloadedBytes = downloadedBytes;
+ progressBar.tick(delta);
+ };
+}
+
+function toMegabytes(bytes: number) {
+ const mb = bytes / 1000 / 1000;
+ return `${Math.round(mb * 10) / 10} MB`;
+}
diff --git a/node_modules/@puppeteer/browsers/src/launch.ts b/node_modules/@puppeteer/browsers/src/launch.ts
new file mode 100644
index 0000000..2b3702d
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/src/launch.ts
@@ -0,0 +1,631 @@
+/**
+ * @license
+ * Copyright 2023 Google Inc.
+ * SPDX-License-Identifier: Apache-2.0
+ */
+
+import childProcess from 'node:child_process';
+import {EventEmitter} from 'node:events';
+import {accessSync} from 'node:fs';
+import os from 'node:os';
+import readline from 'node:readline';
+import type Stream from 'node:stream';
+
+import {
+ type Browser,
+ type BrowserPlatform,
+ resolveSystemExecutablePath,
+ type ChromeReleaseChannel,
+ executablePathByBrowser,
+} from './browser-data/browser-data.js';
+import {Cache} from './Cache.js';
+import {debug} from './debug.js';
+import {detectBrowserPlatform} from './detectPlatform.js';
+
+const debugLaunch = debug('puppeteer:browsers:launcher');
+
+/**
+ * @public
+ */
+export interface ComputeExecutablePathOptions {
+ /**
+ * Root path to the storage directory.
+ *
+ * Can be set to `null` if the executable path should be relative
+ * to the extracted download location. E.g. `./chrome-linux64/chrome`.
+ */
+ cacheDir: string | null;
+ /**
+ * Determines which platform the browser will be suited for.
+ *
+ * @defaultValue **Auto-detected.**
+ */
+ platform?: BrowserPlatform;
+ /**
+ * Determines which browser to launch.
+ */
+ browser: Browser;
+ /**
+ * Determines which buildId to download. BuildId should uniquely identify
+ * binaries and they are used for caching.
+ */
+ buildId: string;
+}
+
+/**
+ * @public
+ */
+export function computeExecutablePath(
+ options: ComputeExecutablePathOptions,
+): string {
+ if (options.cacheDir === null) {
+ options.platform ??= detectBrowserPlatform();
+ if (options.platform === undefined) {
+ throw new Error(
+ `No platform specified. Couldn't auto-detect browser platform.`,
+ );
+ }
+ return executablePathByBrowser[options.browser](
+ options.platform,
+ options.buildId,
+ );
+ }
+
+ return new Cache(options.cacheDir).computeExecutablePath(options);
+}
+
+/**
+ * @public
+ */
+export interface SystemOptions {
+ /**
+ * Determines which platform the browser will be suited for.
+ *
+ * @defaultValue **Auto-detected.**
+ */
+ platform?: BrowserPlatform;
+ /**
+ * Determines which browser to launch.
+ */
+ browser: Browser;
+ /**
+ * Release channel to look for on the system.
+ */
+ channel: ChromeReleaseChannel;
+}
+
+/**
+ * Returns a path to a system-wide Chrome installation given a release channel
+ * name by checking known installation locations (using
+ * {@link https://pptr.dev/browsers-api/browsers.computesystemexecutablepath}).
+ * If Chrome instance is not found at the expected path, an error is thrown.
+ *
+ * @public
+ */
+export function computeSystemExecutablePath(options: SystemOptions): string {
+ options.platform ??= detectBrowserPlatform();
+ if (!options.platform) {
+ throw new Error(
+ `Cannot download a binary for the provided platform: ${os.platform()} (${os.arch()})`,
+ );
+ }
+ const path = resolveSystemExecutablePath(
+ options.browser,
+ options.platform,
+ options.channel,
+ );
+ try {
+ accessSync(path);
+ } catch {
+ throw new Error(
+ `Could not find Google Chrome executable for channel '${options.channel}' at '${path}'.`,
+ );
+ }
+ return path;
+}
+
+/**
+ * @public
+ */
+export interface LaunchOptions {
+ /**
+ * Absolute path to the browser's executable.
+ */
+ executablePath: string;
+ /**
+ * Configures stdio streams to open two additional streams for automation over
+ * those streams instead of WebSocket.
+ *
+ * @defaultValue `false`.
+ */
+ pipe?: boolean;
+ /**
+ * If true, forwards the browser's process stdout and stderr to the Node's
+ * process stdout and stderr.
+ *
+ * @defaultValue `false`.
+ */
+ dumpio?: boolean;
+ /**
+ * Additional arguments to pass to the executable when launching.
+ */
+ args?: string[];
+ /**
+ * Environment variables to set for the browser process.
+ */
+ env?: Record;
+ /**
+ * Handles SIGINT in the Node process and tries to kill the browser process.
+ *
+ * @defaultValue `true`.
+ */
+ handleSIGINT?: boolean;
+ /**
+ * Handles SIGTERM in the Node process and tries to gracefully close the browser
+ * process.
+ *
+ * @defaultValue `true`.
+ */
+ handleSIGTERM?: boolean;
+ /**
+ * Handles SIGHUP in the Node process and tries to gracefully close the browser process.
+ *
+ * @defaultValue `true`.
+ */
+ handleSIGHUP?: boolean;
+ /**
+ * Whether to spawn process in the {@link https://nodejs.org/api/child_process.html#optionsdetached | detached}
+ * mode.
+ *
+ * @defaultValue `true` except on Windows.
+ */
+ detached?: boolean;
+ /**
+ * A callback to run after the browser process exits or before the process
+ * will be closed via the {@link Process.close} call (including when handling
+ * signals). The callback is only run once.
+ */
+ onExit?: () => Promise;
+}
+
+/**
+ * Launches a browser process according to {@link LaunchOptions}.
+ *
+ * @public
+ */
+export function launch(opts: LaunchOptions): Process {
+ return new Process(opts);
+}
+
+/**
+ * @public
+ */
+export const CDP_WEBSOCKET_ENDPOINT_REGEX =
+ /^DevTools listening on (ws:\/\/.*)$/;
+
+/**
+ * @public
+ */
+export const WEBDRIVER_BIDI_WEBSOCKET_ENDPOINT_REGEX =
+ /^WebDriver BiDi listening on (ws:\/\/.*)$/;
+
+type EventHandler = (...args: any[]) => void;
+const processListeners = new Map();
+const dispatchers = {
+ exit: (...args: any[]) => {
+ processListeners.get('exit')?.forEach(handler => {
+ return handler(...args);
+ });
+ },
+ SIGINT: (...args: any[]) => {
+ processListeners.get('SIGINT')?.forEach(handler => {
+ return handler(...args);
+ });
+ },
+ SIGHUP: (...args: any[]) => {
+ processListeners.get('SIGHUP')?.forEach(handler => {
+ return handler(...args);
+ });
+ },
+ SIGTERM: (...args: any[]) => {
+ processListeners.get('SIGTERM')?.forEach(handler => {
+ return handler(...args);
+ });
+ },
+};
+
+function subscribeToProcessEvent(
+ event: 'exit' | 'SIGINT' | 'SIGHUP' | 'SIGTERM',
+ handler: EventHandler,
+): void {
+ const listeners = processListeners.get(event) || [];
+ if (listeners.length === 0) {
+ process.on(event, dispatchers[event]);
+ }
+ listeners.push(handler);
+ processListeners.set(event, listeners);
+}
+
+function unsubscribeFromProcessEvent(
+ event: 'exit' | 'SIGINT' | 'SIGHUP' | 'SIGTERM',
+ handler: EventHandler,
+): void {
+ const listeners = processListeners.get(event) || [];
+ const existingListenerIdx = listeners.indexOf(handler);
+ if (existingListenerIdx === -1) {
+ return;
+ }
+ listeners.splice(existingListenerIdx, 1);
+ processListeners.set(event, listeners);
+ if (listeners.length === 0) {
+ process.off(event, dispatchers[event]);
+ }
+}
+
+/**
+ * @public
+ */
+export class Process {
+ #executablePath;
+ #args: string[];
+ #browserProcess: childProcess.ChildProcess;
+ #exited = false;
+ // The browser process can be closed externally or from the driver process. We
+ // need to invoke the hooks only once though but we don't know how many times
+ // we will be invoked.
+ #hooksRan = false;
+ #onExitHook = async () => {};
+ #browserProcessExiting: Promise;
+ #logs: string[] = [];
+ #maxLogLinesSize = 1000;
+ #lineEmitter = new EventEmitter();
+
+ constructor(opts: LaunchOptions) {
+ this.#executablePath = opts.executablePath;
+ this.#args = opts.args ?? [];
+
+ opts.pipe ??= false;
+ opts.dumpio ??= false;
+ opts.handleSIGINT ??= true;
+ opts.handleSIGTERM ??= true;
+ opts.handleSIGHUP ??= true;
+ // On non-windows platforms, `detached: true` makes child process a
+ // leader of a new process group, making it possible to kill child
+ // process tree with `.kill(-pid)` command. @see
+ // https://nodejs.org/api/child_process.html#child_process_options_detached
+ opts.detached ??= process.platform !== 'win32';
+ const stdio = this.#configureStdio({
+ pipe: opts.pipe,
+ });
+
+ const env = opts.env || {};
+
+ debugLaunch(`Launching ${this.#executablePath} ${this.#args.join(' ')}`, {
+ detached: opts.detached,
+ env: Object.keys(env).reduce>(
+ (res, key) => {
+ if (key.toLowerCase().startsWith('puppeteer_')) {
+ res[key] = env[key];
+ }
+ return res;
+ },
+ {},
+ ),
+ stdio,
+ });
+
+ this.#browserProcess = childProcess.spawn(
+ this.#executablePath,
+ this.#args,
+ {
+ detached: opts.detached,
+ env,
+ stdio,
+ },
+ );
+ this.#recordStream(this.#browserProcess.stderr!);
+ this.#recordStream(this.#browserProcess.stdout!);
+
+ debugLaunch(`Launched ${this.#browserProcess.pid}`);
+ if (opts.dumpio) {
+ this.#browserProcess.stderr?.pipe(process.stderr);
+ this.#browserProcess.stdout?.pipe(process.stdout);
+ }
+ subscribeToProcessEvent('exit', this.#onDriverProcessExit);
+ if (opts.handleSIGINT) {
+ subscribeToProcessEvent('SIGINT', this.#onDriverProcessSignal);
+ }
+ if (opts.handleSIGTERM) {
+ subscribeToProcessEvent('SIGTERM', this.#onDriverProcessSignal);
+ }
+ if (opts.handleSIGHUP) {
+ subscribeToProcessEvent('SIGHUP', this.#onDriverProcessSignal);
+ }
+ if (opts.onExit) {
+ this.#onExitHook = opts.onExit;
+ }
+ this.#browserProcessExiting = new Promise((resolve, reject) => {
+ this.#browserProcess.once('exit', async () => {
+ debugLaunch(`Browser process ${this.#browserProcess.pid} onExit`);
+ this.#clearListeners();
+ this.#exited = true;
+ try {
+ await this.#runHooks();
+ } catch (err) {
+ reject(err);
+ return;
+ }
+ resolve();
+ });
+ });
+ }
+
+ async #runHooks() {
+ if (this.#hooksRan) {
+ return;
+ }
+ this.#hooksRan = true;
+ await this.#onExitHook();
+ }
+
+ get nodeProcess(): childProcess.ChildProcess {
+ return this.#browserProcess;
+ }
+
+ #configureStdio(opts: {pipe: boolean}): Array<'ignore' | 'pipe'> {
+ if (opts.pipe) {
+ return ['pipe', 'pipe', 'pipe', 'pipe', 'pipe'];
+ } else {
+ return ['pipe', 'pipe', 'pipe'];
+ }
+ }
+
+ #clearListeners(): void {
+ unsubscribeFromProcessEvent('exit', this.#onDriverProcessExit);
+ unsubscribeFromProcessEvent('SIGINT', this.#onDriverProcessSignal);
+ unsubscribeFromProcessEvent('SIGTERM', this.#onDriverProcessSignal);
+ unsubscribeFromProcessEvent('SIGHUP', this.#onDriverProcessSignal);
+ }
+
+ #onDriverProcessExit = (_code: number) => {
+ this.kill();
+ };
+
+ #onDriverProcessSignal = (signal: string): void => {
+ switch (signal) {
+ case 'SIGINT':
+ this.kill();
+ process.exit(130);
+ case 'SIGTERM':
+ case 'SIGHUP':
+ void this.close();
+ break;
+ }
+ };
+
+ async close(): Promise {
+ await this.#runHooks();
+ if (!this.#exited) {
+ this.kill();
+ }
+ return await this.#browserProcessExiting;
+ }
+
+ hasClosed(): Promise {
+ return this.#browserProcessExiting;
+ }
+
+ kill(): void {
+ debugLaunch(`Trying to kill ${this.#browserProcess.pid}`);
+ // If the process failed to launch (for example if the browser executable path
+ // is invalid), then the process does not get a pid assigned. A call to
+ // `proc.kill` would error, as the `pid` to-be-killed can not be found.
+ if (
+ this.#browserProcess &&
+ this.#browserProcess.pid &&
+ pidExists(this.#browserProcess.pid)
+ ) {
+ try {
+ debugLaunch(`Browser process ${this.#browserProcess.pid} exists`);
+ if (process.platform === 'win32') {
+ try {
+ childProcess.execSync(
+ `taskkill /pid ${this.#browserProcess.pid} /T /F`,
+ );
+ } catch (error) {
+ debugLaunch(
+ `Killing ${this.#browserProcess.pid} using taskkill failed`,
+ error,
+ );
+ // taskkill can fail to kill the process e.g. due to missing permissions.
+ // Let's kill the process via Node API. This delays killing of all child
+ // processes of `this.proc` until the main Node.js process dies.
+ this.#browserProcess.kill();
+ }
+ } else {
+ // on linux the process group can be killed with the group id prefixed with
+ // a minus sign. The process group id is the group leader's pid.
+ const processGroupId = -this.#browserProcess.pid;
+
+ try {
+ process.kill(processGroupId, 'SIGKILL');
+ } catch (error) {
+ debugLaunch(
+ `Killing ${this.#browserProcess.pid} using process.kill failed`,
+ error,
+ );
+ // Killing the process group can fail due e.g. to missing permissions.
+ // Let's kill the process via Node API. This delays killing of all child
+ // processes of `this.proc` until the main Node.js process dies.
+ this.#browserProcess.kill('SIGKILL');
+ }
+ }
+ } catch (error) {
+ throw new Error(
+ `${PROCESS_ERROR_EXPLANATION}\nError cause: ${
+ isErrorLike(error) ? error.stack : error
+ }`,
+ );
+ }
+ }
+ this.#clearListeners();
+ }
+
+ #recordStream(stream: Stream.Readable): void {
+ const rl = readline.createInterface(stream);
+ const cleanup = (): void => {
+ rl.off('line', onLine);
+ rl.off('close', onClose);
+ try {
+ rl.close();
+ } catch {}
+ };
+ const onLine = (line: string) => {
+ if (line.trim() === '') {
+ return;
+ }
+ this.#logs.push(line);
+ const delta = this.#logs.length - this.#maxLogLinesSize;
+ if (delta) {
+ this.#logs.splice(0, delta);
+ }
+ this.#lineEmitter.emit('line', line);
+ };
+ const onClose = (): void => {
+ cleanup();
+ };
+ rl.on('line', onLine);
+ rl.on('close', onClose);
+ }
+
+ /**
+ * Get recent logs (stderr + stdout) emitted by the browser.
+ *
+ * @public
+ */
+ getRecentLogs(): string[] {
+ return [...this.#logs];
+ }
+
+ waitForLineOutput(regex: RegExp, timeout = 0): Promise {
+ return new Promise((resolve, reject) => {
+ const onClose = (errorOrCode?: Error | number): void => {
+ cleanup();
+ reject(
+ new Error(
+ [
+ `Failed to launch the browser process: ${
+ errorOrCode instanceof Error
+ ? ` ${errorOrCode.message}`
+ : ` Code: ${errorOrCode}`
+ }`,
+ '',
+ `stderr:`,
+ this.getRecentLogs().join('\n'),
+ '',
+ 'TROUBLESHOOTING: https://pptr.dev/troubleshooting',
+ '',
+ ].join('\n'),
+ ),
+ );
+ };
+
+ this.#browserProcess.on('exit', onClose);
+ this.#browserProcess.on('error', onClose);
+ const timeoutId =
+ timeout > 0 ? setTimeout(onTimeout, timeout) : undefined;
+
+ this.#lineEmitter.on('line', onLine);
+ const cleanup = (): void => {
+ clearTimeout(timeoutId);
+ this.#lineEmitter.off('line', onLine);
+ this.#browserProcess.off('exit', onClose);
+ this.#browserProcess.off('error', onClose);
+ };
+
+ function onTimeout(): void {
+ cleanup();
+ reject(
+ new TimeoutError(
+ `Timed out after ${timeout} ms while waiting for the WS endpoint URL to appear in stdout!`,
+ ),
+ );
+ }
+
+ for (const line of this.#logs) {
+ onLine(line);
+ }
+
+ function onLine(line: string): void {
+ const match = line.match(regex);
+ if (!match) {
+ return;
+ }
+ cleanup();
+ // The RegExp matches, so this will obviously exist.
+ resolve(match[1]!);
+ }
+ });
+ }
+}
+
+const PROCESS_ERROR_EXPLANATION = `Puppeteer was unable to kill the process which ran the browser binary.
+This means that, on future Puppeteer launches, Puppeteer might not be able to launch the browser.
+Please check your open processes and ensure that the browser processes that Puppeteer launched have been killed.
+If you think this is a bug, please report it on the Puppeteer issue tracker.`;
+
+/**
+ * @internal
+ */
+function pidExists(pid: number): boolean {
+ try {
+ return process.kill(pid, 0);
+ } catch (error) {
+ if (isErrnoException(error)) {
+ if (error.code && error.code === 'ESRCH') {
+ return false;
+ }
+ }
+ throw error;
+ }
+}
+
+/**
+ * @internal
+ */
+export interface ErrorLike extends Error {
+ name: string;
+ message: string;
+}
+
+/**
+ * @internal
+ */
+export function isErrorLike(obj: unknown): obj is ErrorLike {
+ return (
+ typeof obj === 'object' && obj !== null && 'name' in obj && 'message' in obj
+ );
+}
+/**
+ * @internal
+ */
+export function isErrnoException(obj: unknown): obj is NodeJS.ErrnoException {
+ return (
+ isErrorLike(obj) &&
+ ('errno' in obj || 'code' in obj || 'path' in obj || 'syscall' in obj)
+ );
+}
+
+/**
+ * @public
+ */
+export class TimeoutError extends Error {
+ /**
+ * @internal
+ */
+ constructor(message?: string) {
+ super(message);
+ this.name = this.constructor.name;
+ Error.captureStackTrace(this, this.constructor);
+ }
+}
diff --git a/node_modules/@puppeteer/browsers/src/main-cli.ts b/node_modules/@puppeteer/browsers/src/main-cli.ts
new file mode 100644
index 0000000..9919a4d
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/src/main-cli.ts
@@ -0,0 +1,11 @@
+#!/usr/bin/env node
+
+/**
+ * @license
+ * Copyright 2023 Google Inc.
+ * SPDX-License-Identifier: Apache-2.0
+ */
+
+import {CLI} from './CLI.js';
+
+void new CLI().run(process.argv);
diff --git a/node_modules/@puppeteer/browsers/src/main.ts b/node_modules/@puppeteer/browsers/src/main.ts
new file mode 100644
index 0000000..548baf5
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/src/main.ts
@@ -0,0 +1,51 @@
+/**
+ * @license
+ * Copyright 2023 Google Inc.
+ * SPDX-License-Identifier: Apache-2.0
+ */
+
+export type {
+ LaunchOptions,
+ ComputeExecutablePathOptions as Options,
+ SystemOptions,
+} from './launch.js';
+export {
+ launch,
+ computeExecutablePath,
+ computeSystemExecutablePath,
+ TimeoutError,
+ CDP_WEBSOCKET_ENDPOINT_REGEX,
+ WEBDRIVER_BIDI_WEBSOCKET_ENDPOINT_REGEX,
+ Process,
+} from './launch.js';
+export type {
+ InstallOptions,
+ GetInstalledBrowsersOptions,
+ UninstallOptions,
+} from './install.js';
+export {
+ install,
+ makeProgressCallback,
+ getInstalledBrowsers,
+ canDownload,
+ uninstall,
+ getDownloadUrl,
+} from './install.js';
+export {detectBrowserPlatform} from './detectPlatform.js';
+export type {ProfileOptions} from './browser-data/browser-data.js';
+export {
+ resolveBuildId,
+ Browser,
+ BrowserPlatform,
+ ChromeReleaseChannel,
+ createProfile,
+ getVersionComparator,
+} from './browser-data/browser-data.js';
+export {CLI} from './CLI.js';
+export {
+ Cache,
+ InstalledBrowser,
+ type Metadata,
+ type ComputeExecutablePathOptions,
+} from './Cache.js';
+export {BrowserTag} from './browser-data/types.js';
diff --git a/node_modules/@puppeteer/browsers/src/templates/version.ts.tmpl b/node_modules/@puppeteer/browsers/src/templates/version.ts.tmpl
new file mode 100644
index 0000000..73b984d
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/src/templates/version.ts.tmpl
@@ -0,0 +1,4 @@
+/**
+ * @internal
+ */
+export const packageVersion = 'PACKAGE_VERSION';
diff --git a/node_modules/@puppeteer/browsers/src/tsconfig.cjs.json b/node_modules/@puppeteer/browsers/src/tsconfig.cjs.json
new file mode 100644
index 0000000..acb1968
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/src/tsconfig.cjs.json
@@ -0,0 +1,8 @@
+{
+ "extends": "../../../tsconfig.base.json",
+ "compilerOptions": {
+ "module": "NodeNext",
+ "moduleResolution": "NodeNext",
+ "outDir": "../lib/cjs"
+ }
+}
diff --git a/node_modules/@puppeteer/browsers/src/tsconfig.esm.json b/node_modules/@puppeteer/browsers/src/tsconfig.esm.json
new file mode 100644
index 0000000..a824bc8
--- /dev/null
+++ b/node_modules/@puppeteer/browsers/src/tsconfig.esm.json
@@ -0,0 +1,6 @@
+{
+ "extends": "../../../tsconfig.base.json",
+ "compilerOptions": {
+ "outDir": "../lib/esm"
+ }
+}
diff --git a/node_modules/@tootallnate/quickjs-emscripten/LICENSE b/node_modules/@tootallnate/quickjs-emscripten/LICENSE
new file mode 100644
index 0000000..07499f6
--- /dev/null
+++ b/node_modules/@tootallnate/quickjs-emscripten/LICENSE
@@ -0,0 +1,21 @@
+MIT License
+
+quickjs-emscripten copyright (c) 2019 Jake Teton-Landis
+
+Permission is hereby granted, free of charge, to any person obtaining a copy
+of this software and associated documentation files (the "Software"), to deal
+in the Software without restriction, including without limitation the rights
+to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+copies of the Software, and to permit persons to whom the Software is
+furnished to do so, subject to the following conditions:
+
+The above copyright notice and this permission notice shall be included in all
+copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
+SOFTWARE.
diff --git a/node_modules/@tootallnate/quickjs-emscripten/README.md b/node_modules/@tootallnate/quickjs-emscripten/README.md
new file mode 100644
index 0000000..70658a5
--- /dev/null
+++ b/node_modules/@tootallnate/quickjs-emscripten/README.md
@@ -0,0 +1,597 @@
+# quickjs-emscripten
+
+Javascript/Typescript bindings for QuickJS, a modern Javascript interpreter,
+compiled to WebAssembly.
+
+- Safely evaluate untrusted Javascript (up to ES2020).
+- Create and manipulate values inside the QuickJS runtime ([more][values]).
+- Expose host functions to the QuickJS runtime ([more][functions]).
+- Execute synchronous code that uses asynchronous functions, with [asyncify][asyncify].
+
+[Github] | [NPM] | [API Documentation][api] | [Examples][tests]
+
+```typescript
+import { getQuickJS } from "quickjs-emscripten"
+
+async function main() {
+ const QuickJS = await getQuickJS()
+ const vm = QuickJS.newContext()
+
+ const world = vm.newString("world")
+ vm.setProp(vm.global, "NAME", world)
+ world.dispose()
+
+ const result = vm.evalCode(`"Hello " + NAME + "!"`)
+ if (result.error) {
+ console.log("Execution failed:", vm.dump(result.error))
+ result.error.dispose()
+ } else {
+ console.log("Success:", vm.dump(result.value))
+ result.value.dispose()
+ }
+
+ vm.dispose()
+}
+
+main()
+```
+
+[github]: https://github.com/justjake/quickjs-emscripten
+[npm]: https://www.npmjs.com/package/quickjs-emscripten
+[api]: https://github.com/justjake/quickjs-emscripten/blob/main/doc/modules.md
+[tests]: https://github.com/justjake/quickjs-emscripten/blob/main/ts/quickjs.test.ts
+[values]: #interfacing-with-the-interpreter
+[asyncify]: #asyncify
+[functions]: #exposing-apis
+
+## Usage
+
+Install from `npm`: `npm install --save quickjs-emscripten` or `yarn add quickjs-emscripten`.
+
+The root entrypoint of this library is the `getQuickJS` function, which returns
+a promise that resolves to a [QuickJS singleton](./doc/classes/quickjs.md) when
+the QuickJS WASM module is ready.
+
+Once `getQuickJS` has been awaited at least once, you also can use the `getQuickJSSync`
+function to directly access the singleton engine in your synchronous code.
+
+### Safely evaluate Javascript code
+
+See [QuickJS.evalCode](https://github.com/justjake/quickjs-emscripten/blob/main/doc/classes/quickjs.md#evalcode)
+
+```typescript
+import { getQuickJS, shouldInterruptAfterDeadline } from "quickjs-emscripten"
+
+getQuickJS().then((QuickJS) => {
+ const result = QuickJS.evalCode("1 + 1", {
+ shouldInterrupt: shouldInterruptAfterDeadline(Date.now() + 1000),
+ memoryLimitBytes: 1024 * 1024,
+ })
+ console.log(result)
+})
+```
+
+### Interfacing with the interpreter
+
+You can use [QuickJSContext](https://github.com/justjake/quickjs-emscripten/blob/main/doc/classes/QuickJSContext.md)
+to build a scripting environment by modifying globals and exposing functions
+into the QuickJS interpreter.
+
+Each `QuickJSContext` instance has its own environment -- globals, built-in
+classes -- and actions from one context won't leak into other contexts or
+runtimes (with one exception, see [Asyncify][asyncify]).
+
+Every context is created inside a
+[QuickJSRuntime](https://github.com/justjake/quickjs-emscripten/blob/main/doc/classes/QuickJSRuntime.md).
+A runtime represents a Javascript heap, and you can even share values between
+contexts in the same runtime.
+
+```typescript
+const vm = QuickJS.newContext()
+let state = 0
+
+const fnHandle = vm.newFunction("nextId", () => {
+ return vm.newNumber(++state)
+})
+
+vm.setProp(vm.global, "nextId", fnHandle)
+fnHandle.dispose()
+
+const nextId = vm.unwrapResult(vm.evalCode(`nextId(); nextId(); nextId()`))
+console.log("vm result:", vm.getNumber(nextId), "native state:", state)
+
+nextId.dispose()
+vm.dispose()
+```
+
+When you create a context from a top-level API like in the example above,
+instead of by calling `runtime.newContext()`, a runtime is automatically created
+for the lifetime of the context, and disposed of when you dispose the context.
+
+#### Runtime
+
+The runtime has APIs for CPU and memory limits that apply to all contexts within
+the runtime in aggregate. You can also use the runtime to configure EcmaScript
+module loading.
+
+```typescript
+const runtime = QuickJS.newRuntime()
+// "Should be enough for everyone" -- attributed to B. Gates
+runtime.setMemoryLimit(1024 * 640)
+// Limit stack size
+runtime.setMaxStackSize(1024 * 320)
+// Interrupt computation after 1024 calls to the interrupt handler
+let interruptCycles = 0
+runtime.setInterruptHandler(() => ++interruptCycles > 1024)
+// Toy module system that always returns the module name
+// as the default export
+runtime.setModuleLoader((moduleName) => `export default '${moduleName}'`)
+const context = runtime.newContext()
+const ok = context.evalCode(`
+import fooName from './foo.js'
+globalThis.result = fooName
+`)
+context.unwrapResult(ok).dispose()
+// logs "foo.js"
+console.log(context.getProp(context.global, "result").consume(context.dump))
+context.dispose()
+runtime.dispose()
+```
+
+### Memory Management
+
+Many methods in this library return handles to memory allocated inside the
+WebAssembly heap. These types cannot be garbage-collected as usual in
+Javascript. Instead, you must manually manage their memory by calling a
+`.dispose()` method to free the underlying resources. Once a handle has been
+disposed, it cannot be used anymore. Note that in the example above, we call
+`.dispose()` on each handle once it is no longer needed.
+
+Calling `QuickJSContext.dispose()` will throw a RuntimeError if you've forgotten to
+dispose any handles associated with that VM, so it's good practice to create a
+new VM instance for each of your tests, and to call `vm.dispose()` at the end
+of every test.
+
+```typescript
+const vm = QuickJS.newContext()
+const numberHandle = vm.newNumber(42)
+// Note: numberHandle not disposed, so it leaks memory.
+vm.dispose()
+// throws RuntimeError: abort(Assertion failed: list_empty(&rt->gc_obj_list), at: quickjs/quickjs.c,1963,JS_FreeRuntime)
+```
+
+Here are some strategies to reduce the toil of calling `.dispose()` on each
+handle you create:
+
+#### Scope
+
+A
+[`Scope`](https://github.com/justjake/quickjs-emscripten/blob/main/doc/classes/scope.md#class-scope)
+instance manages a set of disposables and calls their `.dispose()`
+method in the reverse order in which they're added to the scope. Here's the
+"Interfacing with the interpreter" example re-written using `Scope`:
+
+```typescript
+Scope.withScope((scope) => {
+ const vm = scope.manage(QuickJS.newContext())
+ let state = 0
+
+ const fnHandle = scope.manage(
+ vm.newFunction("nextId", () => {
+ return vm.newNumber(++state)
+ })
+ )
+
+ vm.setProp(vm.global, "nextId", fnHandle)
+
+ const nextId = scope.manage(vm.unwrapResult(vm.evalCode(`nextId(); nextId(); nextId()`)))
+ console.log("vm result:", vm.getNumber(nextId), "native state:", state)
+
+ // When the withScope block exits, it calls scope.dispose(), which in turn calls
+ // the .dispose() methods of all the disposables managed by the scope.
+})
+```
+
+You can also create `Scope` instances with `new Scope()` if you want to manage
+calling `scope.dispose()` yourself.
+
+#### `Lifetime.consume(fn)`
+
+[`Lifetime.consume`](https://github.com/justjake/quickjs-emscripten/blob/main/doc/classes/lifetime.md#consume)
+is sugar for the common pattern of using a handle and then
+immediately disposing of it. `Lifetime.consume` takes a `map` function that
+produces a result of any type. The `map` fuction is called with the handle,
+then the handle is disposed, then the result is returned.
+
+Here's the "Interfacing with interpreter" example re-written using `.consume()`:
+
+```typescript
+const vm = QuickJS.newContext()
+let state = 0
+
+vm.newFunction("nextId", () => {
+ return vm.newNumber(++state)
+}).consume((fnHandle) => vm.setProp(vm.global, "nextId", fnHandle))
+
+vm.unwrapResult(vm.evalCode(`nextId(); nextId(); nextId()`)).consume((nextId) =>
+ console.log("vm result:", vm.getNumber(nextId), "native state:", state)
+)
+
+vm.dispose()
+```
+
+Generally working with `Scope` leads to more straight-forward code, but
+`Lifetime.consume` can be handy sugar as part of a method call chain.
+
+### Exposing APIs
+
+To add APIs inside the QuickJS environment, you'll need to create objects to
+define the shape of your API, and add properties and functions to those objects
+to allow code inside QuickJS to call code on the host.
+
+By default, no host functionality is exposed to code running inside QuickJS.
+
+```typescript
+const vm = QuickJS.newContext()
+// `console.log`
+const logHandle = vm.newFunction("log", (...args) => {
+ const nativeArgs = args.map(vm.dump)
+ console.log("QuickJS:", ...nativeArgs)
+})
+// Partially implement `console` object
+const consoleHandle = vm.newObject()
+vm.setProp(consoleHandle, "log", logHandle)
+vm.setProp(vm.global, "console", consoleHandle)
+consoleHandle.dispose()
+logHandle.dispose()
+
+vm.unwrapResult(vm.evalCode(`console.log("Hello from QuickJS!")`)).dispose()
+```
+
+#### Promises
+
+To expose an asynchronous function that _returns a promise_ to callers within
+QuickJS, your function can return the handle of a `QuickJSDeferredPromise`
+created via `context.newPromise()`.
+
+When you resolve a `QuickJSDeferredPromise` -- and generally whenever async
+behavior completes for the VM -- pending listeners inside QuickJS may not
+execute immediately. Your code needs to explicitly call
+`runtime.executePendingJobs()` to resume execution inside QuickJS. This API
+gives your code maximum control to _schedule_ when QuickJS will block the host's
+event loop by resuming execution.
+
+To work with QuickJS handles that contain a promise inside the environment, you
+can convert the QuickJSHandle into a native promise using
+`context.resolvePromise()`. Take care with this API to avoid 'deadlocks' where
+the host awaits a guest promise, but the guest cannot make progress until the
+host calls `runtime.executePendingJobs()`. The simplest way to avoid this kind
+of deadlock is to always schedule `executePendingJobs` after any promise is
+settled.
+
+```typescript
+const vm = QuickJS.newContext()
+const fakeFileSystem = new Map([["example.txt", "Example file content"]])
+
+// Function that simulates reading data asynchronously
+const readFileHandle = vm.newFunction("readFile", (pathHandle) => {
+ const path = vm.getString(pathHandle)
+ const promise = vm.newPromise()
+ setTimeout(() => {
+ const content = fakeFileSystem.get(path)
+ promise.resolve(vm.newString(content || ""))
+ }, 100)
+ // IMPORTANT: Once you resolve an async action inside QuickJS,
+ // call runtime.executePendingJobs() to run any code that was
+ // waiting on the promise or callback.
+ promise.settled.then(vm.runtime.executePendingJobs)
+ return promise.handle
+})
+readFileHandle.consume((handle) => vm.setProp(vm.global, "readFile", handle))
+
+// Evaluate code that uses `readFile`, which returns a promise
+const result = vm.evalCode(`(async () => {
+ const content = await readFile('example.txt')
+ return content.toUpperCase()
+})()`)
+const promiseHandle = vm.unwrapResult(result)
+
+// Convert the promise handle into a native promise and await it.
+// If code like this deadlocks, make sure you are calling
+// runtime.executePendingJobs appropriately.
+const resolvedResult = await vm.resolvePromise(promiseHandle)
+promiseHandle.dispose()
+const resolvedHandle = vm.unwrapResult(resolvedResult)
+console.log("Result:", vm.getString(resolvedHandle))
+resolvedHandle.dispose()
+```
+
+#### Asyncify
+
+Sometimes, we want to create a function that's synchronous from the perspective
+of QuickJS, but prefer to implement that function _asynchronously_ in your host
+code. The most obvious use-case is for EcmaScript module loading. The underlying
+QuickJS C library expects the module loader function to return synchronously,
+but loading data synchronously in the browser or server is somewhere between "a
+bad idea" and "impossible". QuickJS also doesn't expose an API to "pause" the
+execution of a runtime, and adding such an API is tricky due to the VM's
+implementation.
+
+As a work-around, we provide an alternate build of QuickJS processed by
+Emscripten/Binaryen's [ASYNCIFY](https://emscripten.org/docs/porting/asyncify.html)
+compiler transform. Here's how Emscripten's documentation describes Asyncify:
+
+> Asyncify lets synchronous C or C++ code interact with asynchronous \[host] JavaScript. This allows things like:
+>
+> - A synchronous call in C that yields to the event loop, which allows browser events to be handled.
+>
+> - A synchronous call in C that waits for an asynchronous operation in \[host] JS to complete.
+>
+> Asyncify automatically transforms ... code into a form that can be paused and
+> resumed ..., so that it is asynchronous (hence the name “Asyncify”) even though
+> \[it is written] in a normal synchronous way.
+
+This means we can suspend an _entire WebAssembly module_ (which could contain
+multiple runtimes and contexts) while our host Javascript loads data
+asynchronously, and then resume execution once the data load completes. This is
+a very handy superpower, but it comes with a couple of major limitations:
+
+1. _An asyncified WebAssembly module can only suspend to wait for a single
+ asynchronous call at a time_. You may call back into a suspended WebAssembly
+ module eg. to create a QuickJS value to return a result, but the system will
+ crash if this call tries to suspend again. Take a look at Emscripten's documentation
+ on [reentrancy](https://emscripten.org/docs/porting/asyncify.html#reentrancy).
+
+2. _Asyncified code is bigger and runs slower_. The asyncified build of
+ Quickjs-emscripten library is 1M, 2x larger than the 500K of the default
+ version. There may be room for further
+ [optimization](https://emscripten.org/docs/porting/asyncify.html#optimizing)
+ Of our build in the future.
+
+To use asyncify features, use the following functions:
+
+- [newAsyncRuntime][]: create a runtime inside a new WebAssembly module.
+- [newAsyncContext][]: create runtime and context together inside a new
+ WebAssembly module.
+- [newQuickJSAsyncWASMModule][]: create an empty WebAssembly module.
+
+[newasyncruntime]: https://github.com/justjake/quickjs-emscripten/blob/main/doc/modules.md#newasyncruntime
+[newasynccontext]: https://github.com/justjake/quickjs-emscripten/blob/main/doc/modules.md#newasynccontext
+[newquickjsasyncwasmmodule]: https://github.com/justjake/quickjs-emscripten/blob/main/doc/modules.md#newquickjsasyncwasmmodule
+
+These functions are asynchronous because they always create a new underlying
+WebAssembly module so that each instance can suspend and resume independently,
+and instantiating a WebAssembly module is an async operation. This also adds
+substantial overhead compared to creating a runtime or context inside an
+existing module; if you only need to wait for a single async action at a time,
+you can create a single top-level module and create runtimes or contexts inside
+of it.
+
+##### Async module loader
+
+Here's an example of valuating a script that loads React asynchronously as an ES
+module. In our example, we're loading from the filesystem for reproducibility,
+but you can use this technique to load using `fetch`.
+
+```typescript
+const module = await newQuickJSAsyncWASMModule()
+const runtime = module.newRuntime()
+const path = await import("path")
+const { promises: fs } = await import("fs")
+
+const importsPath = path.join(__dirname, "../examples/imports") + "/"
+// Module loaders can return promises.
+// Execution will suspend until the promise resolves.
+runtime.setModuleLoader((moduleName) => {
+ const modulePath = path.join(importsPath, moduleName)
+ if (!modulePath.startsWith(importsPath)) {
+ throw new Error("out of bounds")
+ }
+ console.log("loading", moduleName, "from", modulePath)
+ return fs.readFile(modulePath, "utf-8")
+})
+
+// evalCodeAsync is required when execution may suspend.
+const context = runtime.newContext()
+const result = await context.evalCodeAsync(`
+import * as React from 'esm.sh/react@17'
+import * as ReactDOMServer from 'esm.sh/react-dom@17/server'
+const e = React.createElement
+globalThis.html = ReactDOMServer.renderToStaticMarkup(
+ e('div', null, e('strong', null, 'Hello world!'))
+)
+`)
+context.unwrapResult(result).dispose()
+const html = context.getProp(context.global, "html").consume(context.getString)
+console.log(html) //
Hello world!
+```
+
+##### Async on host, sync in QuickJS
+
+Here's an example of turning an async function into a sync function inside the
+VM.
+
+```typescript
+const context = await newAsyncContext()
+const path = await import("path")
+const { promises: fs } = await import("fs")
+
+const importsPath = path.join(__dirname, "../examples/imports") + "/"
+const readFileHandle = context.newAsyncifiedFunction("readFile", async (pathHandle) => {
+ const pathString = path.join(importsPath, context.getString(pathHandle))
+ if (!pathString.startsWith(importsPath)) {
+ throw new Error("out of bounds")
+ }
+ const data = await fs.readFile(pathString, "utf-8")
+ return context.newString(data)
+})
+readFileHandle.consume((fn) => context.setProp(context.global, "readFile", fn))
+
+// evalCodeAsync is required when execution may suspend.
+const result = await context.evalCodeAsync(`
+// Not a promise! Sync! vvvvvvvvvvvvvvvvvvvv
+const data = JSON.parse(readFile('data.json'))
+data.map(x => x.toUpperCase()).join(' ')
+`)
+const upperCaseData = context.unwrapResult(result).consume(context.getString)
+console.log(upperCaseData) // 'VERY USEFUL DATA'
+```
+
+### Testing your code
+
+This library is complicated to use, so please consider automated testing your
+implementation. We highly writing your test suite to run with both the "release"
+build variant of quickjs-emscripten, and also the [DEBUG_SYNC] build variant.
+The debug sync build variant has extra instrumentation code for detecting memory
+leaks.
+
+The class [TestQuickJSWASMModule] exposes the memory leak detection API, although
+this API is only accurate when using `DEBUG_SYNC` variant.
+
+```typescript
+// Define your test suite in a function, so that you can test against
+// different module loaders.
+function myTests(moduleLoader: () => Promise) {
+ let QuickJS: TestQuickJSWASMModule
+ beforeEach(async () => {
+ // Get a unique TestQuickJSWASMModule instance for each test.
+ const wasmModule = await moduleLoader()
+ QuickJS = new TestQuickJSWASMModule(wasmModule)
+ })
+ afterEach(() => {
+ // Assert that the test disposed all handles. The DEBUG_SYNC build
+ // variant will show detailed traces for each leak.
+ QuickJS.assertNoMemoryAllocated()
+ })
+
+ it("works well", () => {
+ // TODO: write a test using QuickJS
+ const context = QuickJS.newContext()
+ context.unwrapResult(context.evalCode("1 + 1")).dispose()
+ context.dispose()
+ })
+}
+
+// Run the test suite against a matrix of module loaders.
+describe("Check for memory leaks with QuickJS DEBUG build", () => {
+ const moduleLoader = memoizePromiseFactory(() => newQuickJSWASMModule(DEBUG_SYNC))
+ myTests(moduleLoader)
+})
+
+describe("Realistic test with QuickJS RELEASE build", () => {
+ myTests(getQuickJS)
+})
+```
+
+For more testing examples, please explore the typescript source of [quickjs-emscripten][ts] repository.
+
+[ts]: https://github.com/justjake/quickjs-emscripten/blob/main/ts
+[debug_sync]: https://github.com/justjake/quickjs-emscripten/blob/main/doc/modules.md#debug_sync
+[testquickjswasmmodule]: https://github.com/justjake/quickjs-emscripten/blob/main/doc/classes/TestQuickJSWASMModule.md
+
+### Debugging
+
+- Switch to a DEBUG build variant of the WebAssembly module to see debug log messages from the C part of this library.
+- Set `process.env.QTS_DEBUG` to see debug log messages from the Javascript part of this library.
+
+### More Documentation
+
+[Github] | [NPM] | [API Documentation][api] | [Examples][tests]
+
+## Background
+
+This was inspired by seeing https://github.com/maple3142/duktape-eval
+[on Hacker News](https://news.ycombinator.com/item?id=21946565) and Figma's
+blogposts about using building a Javascript plugin runtime:
+
+- [How Figma built the Figma plugin system](https://www.figma.com/blog/how-we-built-the-figma-plugin-system/): Describes the LowLevelJavascriptVm interface.
+- [An update on plugin security](https://www.figma.com/blog/an-update-on-plugin-security/): Figma switches to QuickJS.
+
+## Status & Roadmap
+
+**Stability**: Because the version number of this project is below `1.0.0`,
+\*expect occasional breaking API changes.
+
+**Security**: This project makes every effort to be secure, but has not been
+audited. Please use with care in production settings.
+
+**Roadmap**: I work on this project in my free time, for fun. Here's I'm
+thinking comes next. Last updated 2022-03-18.
+
+1. Further work on module loading APIs:
+
+ - Create modules via Javascript, instead of source text.
+ - Scan source text for imports, for ahead of time or concurrent loading.
+ (This is possible with third-party tools, so lower priority.)
+
+2. Higher-level tools for reading QuickJS values:
+
+ - Type guard functions: `context.isArray(handle)`, `context.isPromise(handle)`, etc.
+ - Iteration utilities: `context.getIterable(handle)`, `context.iterateObjectEntries(handle)`.
+ This better supports user-level code to deserialize complex handle objects.
+
+3. Higher-level tools for creating QuickJS values:
+
+ - Devise a way to avoid needing to mess around with handles when setting up
+ the environment.
+ - Consider integrating
+ [quickjs-emscripten-sync](https://github.com/reearth/quickjs-emscripten-sync)
+ for automatic translation.
+ - Consider class-based or interface-type-based marshalling.
+
+4. EcmaScript Modules / WebAssembly files / Deno support. This requires me to
+ learn a lot of new things, but should be interesting for modern browser usage.
+
+5. SQLite integration.
+
+## Related
+
+- Duktape wrapped in Wasm: https://github.com/maple3142/duktape-eval/blob/main/src/Makefile
+- QuickJS wrapped in C++: https://github.com/ftk/quickjspp
+
+## Developing
+
+This library is implemented in two languages: C (compiled to WASM with
+Emscripten), and Typescript.
+
+### The C parts
+
+The ./c directory contains C code that wraps the QuickJS C library (in ./quickjs).
+Public functions (those starting with `QTS_`) in ./c/interface.c are
+automatically exported to native code (via a generated header) and to
+Typescript (via a generated FFI class). See ./generate.ts for how this works.
+
+The C code builds as both with `emscripten` (using `emcc`), to produce WASM (or
+ASM.js) and with `clang`. Build outputs are checked in, so you can iterate on
+the Javascript parts of the library without setting up the Emscripten toolchain.
+
+Intermediate object files from QuickJS end up in ./build/quickjs/.
+
+This project uses `emscripten 3.1.32`.
+
+- On ARM64, you should install `emscripten` on your machine. For example on macOS, `brew install emscripten`.
+- If _the correct version of emcc_ is not in your PATH, compilation falls back to using Docker.
+ On ARM64, this is 10-50x slower than native compilation, but it's just fine on x64.
+
+Related NPM scripts:
+
+- `yarn update-quickjs` will sync the ./quickjs folder with a
+ github repo tracking the upstream QuickJS.
+- `yarn make-debug` will rebuild C outputs into ./build/wrapper
+- `yarn make-release` will rebuild C outputs in release mode, which is the mode
+ that should be checked into the repo.
+
+### The Typescript parts
+
+The ./ts directory contains Typescript types and wraps the generated Emscripten
+FFI in a more usable interface.
+
+You'll need `node` and `yarn`. Install dependencies with `yarn install`.
+
+- `yarn build` produces ./dist.
+- `yarn test` runs the tests.
+- `yarn test --watch` watches for changes and re-runs the tests.
+
+### Yarn updates
+
+Just run `yarn set version from sources` to upgrade the Yarn release.
diff --git a/node_modules/@tootallnate/quickjs-emscripten/c/interface.c b/node_modules/@tootallnate/quickjs-emscripten/c/interface.c
new file mode 100644
index 0000000..0126cff
--- /dev/null
+++ b/node_modules/@tootallnate/quickjs-emscripten/c/interface.c
@@ -0,0 +1,819 @@
+/**
+ * interface.c
+ *
+ * We primarily use JSValue* (pointer to JSValue) when communicating with the
+ * host javascript environment, because pointers are trivial to use for calls
+ * into emscripten because they're just a number!
+ *
+ * As with the quickjs.h API, a JSValueConst* value is "borrowed" and should
+ * not be freed. A JSValue* is "owned" and should be freed by the owner.
+ *
+ * Functions starting with "QTS_" are exported by generate.ts to:
+ * - interface.h for native C code.
+ * - ffi.ts for emscripten.
+ *
+ * We support building the following build outputs:
+ *
+ * ## 1. Native machine code
+ * For internal development testing purposes.
+ *
+ * ## 2. WASM via Emscripten
+ * For general production use.
+ *
+ * ## 3. Experimental: Asyncified WASM via Emscripten with -s ASYNCIFY=1.
+ * This variant supports treating async host Javascript calls as synchronous
+ * from the perspective of the WASM c code.
+ *
+ * The way this works is described here:
+ * https://emscripten.org/docs/porting/asyncify.html
+ *
+ * In this variant, any call into our C code could return a promise if it ended
+ * up suspended. We mark the methods we suspect might suspend due to users' code
+ * as returning MaybeAsync(T). This information is ignored for the regular
+ * build.
+ */
+
+#ifdef __EMSCRIPTEN__
+#include
+#endif
+
+#include // For NAN
+#include
+#include
+#include
+#ifdef QTS_SANITIZE_LEAK
+#include
+#endif
+
+#include "../quickjs/cutils.h"
+#include "../quickjs/quickjs-libc.h"
+#include "../quickjs/quickjs.h"
+
+#define PKG "quickjs-emscripten: "
+
+#ifdef QTS_DEBUG_MODE
+#define QTS_DEBUG(msg) qts_log(msg);
+#define QTS_DUMP(value) qts_dump(ctx, value);
+#else
+#define QTS_DEBUG(msg) ;
+#define QTS_DUMP(value) ;
+#endif
+
+/**
+ * Signal to our FFI code generator that this string argument should be passed as a pointer
+ * allocated by the caller on the heap, not a JS string on the stack.
+ * https://github.com/emscripten-core/emscripten/issues/6860#issuecomment-405818401
+ */
+#define BorrowedHeapChar const char
+#define OwnedHeapChar char
+#define JSBorrowedChar const char
+
+/**
+ * Signal to our FFI code generator that this function should be called
+ * asynchronously when compiled with ASYNCIFY.
+ */
+#define MaybeAsync(T) T
+
+/**
+ * Signal to our FFI code generator that this function is only available in
+ * ASYNCIFY builds.
+ */
+#define AsyncifyOnly(T) T
+
+#define JSVoid void
+
+#define EvalFlags int
+#define EvalDetectModule int
+
+void qts_log(char *msg) {
+ fputs(PKG, stderr);
+ fputs(msg, stderr);
+ fputs("\n", stderr);
+}
+
+void qts_dump(JSContext *ctx, JSValueConst value) {
+ const char *str = JS_ToCString(ctx, value);
+ if (!str) {
+ QTS_DEBUG("QTS_DUMP: can't dump");
+ return;
+ }
+ fputs(str, stderr);
+ JS_FreeCString(ctx, str);
+ putchar('\n');
+}
+
+void copy_prop_if_needed(JSContext *ctx, JSValueConst dest, JSValueConst src, const char *prop_name) {
+ JSAtom prop_atom = JS_NewAtom(ctx, prop_name);
+ JSValue dest_prop = JS_GetProperty(ctx, dest, prop_atom);
+ if (JS_IsUndefined(dest_prop)) {
+ JSValue src_prop = JS_GetProperty(ctx, src, prop_atom);
+ if (!JS_IsUndefined(src_prop) && !JS_IsException(src_prop)) {
+ JS_SetProperty(ctx, dest, prop_atom, src_prop);
+ }
+ } else {
+ JS_FreeValue(ctx, dest_prop);
+ }
+ JS_FreeAtom(ctx, prop_atom);
+}
+
+JSValue *jsvalue_to_heap(JSValueConst value) {
+ JSValue *result = malloc(sizeof(JSValue));
+ if (result) {
+ // Could be better optimized, but at -0z / -ftlo, it
+ // appears to produce the same binary code as a memcpy.
+ *result = value;
+ }
+ return result;
+}
+
+JSValue *QTS_Throw(JSContext *ctx, JSValueConst *error) {
+ JSValue copy = JS_DupValue(ctx, *error);
+ return jsvalue_to_heap(JS_Throw(ctx, copy));
+}
+
+JSValue *QTS_NewError(JSContext *ctx) {
+ return jsvalue_to_heap(JS_NewError(ctx));
+}
+
+/**
+ * Limits.
+ */
+
+/**
+ * Memory limit. Set to -1 to disable.
+ */
+void QTS_RuntimeSetMemoryLimit(JSRuntime *rt, size_t limit) {
+ JS_SetMemoryLimit(rt, limit);
+}
+
+/**
+ * Memory diagnostics
+ */
+
+JSValue *QTS_RuntimeComputeMemoryUsage(JSRuntime *rt, JSContext *ctx) {
+ JSMemoryUsage s;
+ JS_ComputeMemoryUsage(rt, &s);
+
+ // Note that we're going to allocate more memory just to report the memory usage.
+ // A more sound approach would be to bind JSMemoryUsage struct directly - but that's
+ // a lot of work. This should be okay in the mean time.
+ JSValue result = JS_NewObject(ctx);
+
+ // Manually generated via editor-fu from JSMemoryUsage struct definition in quickjs.h
+ JS_SetPropertyStr(ctx, result, "malloc_limit", JS_NewInt64(ctx, s.malloc_limit));
+ JS_SetPropertyStr(ctx, result, "memory_used_size", JS_NewInt64(ctx, s.memory_used_size));
+ JS_SetPropertyStr(ctx, result, "malloc_count", JS_NewInt64(ctx, s.malloc_count));
+ JS_SetPropertyStr(ctx, result, "memory_used_count", JS_NewInt64(ctx, s.memory_used_count));
+ JS_SetPropertyStr(ctx, result, "atom_count", JS_NewInt64(ctx, s.atom_count));
+ JS_SetPropertyStr(ctx, result, "atom_size", JS_NewInt64(ctx, s.atom_size));
+ JS_SetPropertyStr(ctx, result, "str_count", JS_NewInt64(ctx, s.str_count));
+ JS_SetPropertyStr(ctx, result, "str_size", JS_NewInt64(ctx, s.str_size));
+ JS_SetPropertyStr(ctx, result, "obj_count", JS_NewInt64(ctx, s.obj_count));
+ JS_SetPropertyStr(ctx, result, "obj_size", JS_NewInt64(ctx, s.obj_size));
+ JS_SetPropertyStr(ctx, result, "prop_count", JS_NewInt64(ctx, s.prop_count));
+ JS_SetPropertyStr(ctx, result, "prop_size", JS_NewInt64(ctx, s.prop_size));
+ JS_SetPropertyStr(ctx, result, "shape_count", JS_NewInt64(ctx, s.shape_count));
+ JS_SetPropertyStr(ctx, result, "shape_size", JS_NewInt64(ctx, s.shape_size));
+ JS_SetPropertyStr(ctx, result, "js_func_count", JS_NewInt64(ctx, s.js_func_count));
+ JS_SetPropertyStr(ctx, result, "js_func_size", JS_NewInt64(ctx, s.js_func_size));
+ JS_SetPropertyStr(ctx, result, "js_func_code_size", JS_NewInt64(ctx, s.js_func_code_size));
+ JS_SetPropertyStr(ctx, result, "js_func_pc2line_count", JS_NewInt64(ctx, s.js_func_pc2line_count));
+ JS_SetPropertyStr(ctx, result, "js_func_pc2line_size", JS_NewInt64(ctx, s.js_func_pc2line_size));
+ JS_SetPropertyStr(ctx, result, "c_func_count", JS_NewInt64(ctx, s.c_func_count));
+ JS_SetPropertyStr(ctx, result, "array_count", JS_NewInt64(ctx, s.array_count));
+ JS_SetPropertyStr(ctx, result, "fast_array_count", JS_NewInt64(ctx, s.fast_array_count));
+ JS_SetPropertyStr(ctx, result, "fast_array_elements", JS_NewInt64(ctx, s.fast_array_elements));
+ JS_SetPropertyStr(ctx, result, "binary_object_count", JS_NewInt64(ctx, s.binary_object_count));
+ JS_SetPropertyStr(ctx, result, "binary_object_size", JS_NewInt64(ctx, s.binary_object_size));
+
+ return jsvalue_to_heap(result);
+}
+
+OwnedHeapChar *QTS_RuntimeDumpMemoryUsage(JSRuntime *rt) {
+ char *result = malloc(sizeof(char) * 1024);
+ FILE *memfile = fmemopen(result, 1024, "w");
+ JSMemoryUsage s;
+ JS_ComputeMemoryUsage(rt, &s);
+ JS_DumpMemoryUsage(memfile, &s, rt);
+ fclose(memfile);
+ return result;
+}
+
+int QTS_RecoverableLeakCheck() {
+#ifdef QTS_SANITIZE_LEAK
+ return __lsan_do_recoverable_leak_check();
+#else
+ return 0;
+#endif
+}
+
+int QTS_BuildIsSanitizeLeak() {
+#ifdef QTS_SANITIZE_LEAK
+ return 1;
+#else
+ return 0;
+#endif
+}
+
+#ifdef QTS_ASYNCIFY
+EM_JS(void, set_asyncify_stack_size, (size_t size), {
+ Asyncify.StackSize = size || 81920;
+});
+#endif
+
+/**
+ * Set the stack size limit, in bytes. Set to 0 to disable.
+ */
+void QTS_RuntimeSetMaxStackSize(JSRuntime *rt, size_t stack_size) {
+#ifdef QTS_ASYNCIFY
+ set_asyncify_stack_size(stack_size);
+#endif
+ JS_SetMaxStackSize(rt, stack_size);
+}
+
+/**
+ * Constant pointers. Because we always use JSValue* from the host Javascript environment,
+ * we need helper fuctions to return pointers to these constants.
+ */
+
+JSValueConst QTS_Undefined = JS_UNDEFINED;
+JSValueConst *QTS_GetUndefined() {
+ return &QTS_Undefined;
+}
+
+JSValueConst QTS_Null = JS_NULL;
+JSValueConst *QTS_GetNull() {
+ return &QTS_Null;
+}
+
+JSValueConst QTS_False = JS_FALSE;
+JSValueConst *QTS_GetFalse() {
+ return &QTS_False;
+}
+
+JSValueConst QTS_True = JS_TRUE;
+JSValueConst *QTS_GetTrue() {
+ return &QTS_True;
+}
+
+/**
+ * Standard FFI functions
+ */
+
+JSRuntime *QTS_NewRuntime() {
+ return JS_NewRuntime();
+}
+
+void QTS_FreeRuntime(JSRuntime *rt) {
+ JS_FreeRuntime(rt);
+}
+
+JSContext *QTS_NewContext(JSRuntime *rt) {
+ return JS_NewContext(rt);
+}
+
+void QTS_FreeContext(JSContext *ctx) {
+ JS_FreeContext(ctx);
+}
+
+void QTS_FreeValuePointer(JSContext *ctx, JSValue *value) {
+ JS_FreeValue(ctx, *value);
+ free(value);
+}
+
+void QTS_FreeValuePointerRuntime(JSRuntime *rt, JSValue *value) {
+ JS_FreeValueRT(rt, *value);
+ free(value);
+}
+
+void QTS_FreeVoidPointer(JSContext *ctx, JSVoid *ptr) {
+ js_free(ctx, ptr);
+}
+
+void QTS_FreeCString(JSContext *ctx, JSBorrowedChar *str) {
+ JS_FreeCString(ctx, str);
+}
+
+JSValue *QTS_DupValuePointer(JSContext *ctx, JSValueConst *val) {
+ return jsvalue_to_heap(JS_DupValue(ctx, *val));
+}
+
+JSValue *QTS_NewObject(JSContext *ctx) {
+ return jsvalue_to_heap(JS_NewObject(ctx));
+}
+
+JSValue *QTS_NewObjectProto(JSContext *ctx, JSValueConst *proto) {
+ return jsvalue_to_heap(JS_NewObjectProto(ctx, *proto));
+}
+
+JSValue *QTS_NewArray(JSContext *ctx) {
+ return jsvalue_to_heap(JS_NewArray(ctx));
+}
+
+JSValue *QTS_NewFloat64(JSContext *ctx, double num) {
+ return jsvalue_to_heap(JS_NewFloat64(ctx, num));
+}
+
+double QTS_GetFloat64(JSContext *ctx, JSValueConst *value) {
+ double result = NAN;
+ JS_ToFloat64(ctx, &result, *value);
+ return result;
+}
+
+JSValue *QTS_NewString(JSContext *ctx, BorrowedHeapChar *string) {
+ return jsvalue_to_heap(JS_NewString(ctx, string));
+}
+
+JSBorrowedChar *QTS_GetString(JSContext *ctx, JSValueConst *value) {
+ return JS_ToCString(ctx, *value);
+}
+
+JSValue qts_get_symbol_key(JSContext *ctx, JSValueConst *value) {
+ JSValue global = JS_GetGlobalObject(ctx);
+ JSValue Symbol = JS_GetPropertyStr(ctx, global, "Symbol");
+ JS_FreeValue(ctx, global);
+
+ JSValue Symbol_keyFor = JS_GetPropertyStr(ctx, Symbol, "keyFor");
+ JSValue key = JS_Call(ctx, Symbol_keyFor, Symbol, 1, value);
+ JS_FreeValue(ctx, Symbol_keyFor);
+ JS_FreeValue(ctx, Symbol);
+ return key;
+}
+
+JSValue *QTS_NewSymbol(JSContext *ctx, BorrowedHeapChar *description, int isGlobal) {
+ JSValue global = JS_GetGlobalObject(ctx);
+ JSValue Symbol = JS_GetPropertyStr(ctx, global, "Symbol");
+ JS_FreeValue(ctx, global);
+ JSValue descriptionValue = JS_NewString(ctx, description);
+ JSValue symbol;
+
+ if (isGlobal != 0) {
+ JSValue Symbol_for = JS_GetPropertyStr(ctx, Symbol, "for");
+ symbol = JS_Call(ctx, Symbol_for, Symbol, 1, &descriptionValue);
+ JS_FreeValue(ctx, descriptionValue);
+ JS_FreeValue(ctx, Symbol_for);
+ JS_FreeValue(ctx, Symbol);
+ return jsvalue_to_heap(symbol);
+ }
+
+ symbol = JS_Call(ctx, Symbol, JS_UNDEFINED, 1, &descriptionValue);
+ JS_FreeValue(ctx, descriptionValue);
+ JS_FreeValue(ctx, Symbol);
+
+ return jsvalue_to_heap(symbol);
+}
+
+MaybeAsync(JSBorrowedChar *) QTS_GetSymbolDescriptionOrKey(JSContext *ctx, JSValueConst *value) {
+ JSBorrowedChar *result;
+
+ JSValue key = qts_get_symbol_key(ctx, value);
+ if (!JS_IsUndefined(key)) {
+ result = JS_ToCString(ctx, key);
+ JS_FreeValue(ctx, key);
+ return result;
+ }
+
+ JSValue description = JS_GetPropertyStr(ctx, *value, "description");
+ result = JS_ToCString(ctx, description);
+ JS_FreeValue(ctx, description);
+ return result;
+}
+
+int QTS_IsGlobalSymbol(JSContext *ctx, JSValueConst *value) {
+ JSValue key = qts_get_symbol_key(ctx, value);
+ int undefined = JS_IsUndefined(key);
+ JS_FreeValue(ctx, key);
+
+ if (undefined) {
+ return 0;
+ } else {
+ return 1;
+ }
+}
+
+int QTS_IsJobPending(JSRuntime *rt) {
+ return JS_IsJobPending(rt);
+}
+
+/*
+ runs pending jobs (Promises/async functions) until it encounters
+ an exception or it executed the passed maxJobsToExecute jobs.
+
+ Passing a negative value will run the loop until there are no more
+ pending jobs or an exception happened
+
+ Returns the executed number of jobs or the exception encountered
+*/
+MaybeAsync(JSValue *) QTS_ExecutePendingJob(JSRuntime *rt, int maxJobsToExecute, JSContext **lastJobContext) {
+ JSContext *pctx;
+ int status = 1;
+ int executed = 0;
+ while (executed != maxJobsToExecute && status == 1) {
+ status = JS_ExecutePendingJob(rt, &pctx);
+ if (status == -1) {
+ *lastJobContext = pctx;
+ return jsvalue_to_heap(JS_GetException(pctx));
+ } else if (status == 1) {
+ *lastJobContext = pctx;
+ executed++;
+ }
+ }
+#ifdef QTS_DEBUG_MODE
+ char msg[500];
+ sprintf(msg, "QTS_ExecutePendingJob(executed: %d, pctx: %p, lastJobExecuted: %p)", executed, pctx, *lastJobContext);
+ QTS_DEBUG(msg)
+#endif
+ return jsvalue_to_heap(JS_NewFloat64(pctx, executed));
+}
+
+MaybeAsync(JSValue *) QTS_GetProp(JSContext *ctx, JSValueConst *this_val, JSValueConst *prop_name) {
+ JSAtom prop_atom = JS_ValueToAtom(ctx, *prop_name);
+ JSValue prop_val = JS_GetProperty(ctx, *this_val, prop_atom);
+ JS_FreeAtom(ctx, prop_atom);
+ return jsvalue_to_heap(prop_val);
+}
+
+MaybeAsync(void) QTS_SetProp(JSContext *ctx, JSValueConst *this_val, JSValueConst *prop_name, JSValueConst *prop_value) {
+ JSAtom prop_atom = JS_ValueToAtom(ctx, *prop_name);
+ JSValue extra_prop_value = JS_DupValue(ctx, *prop_value);
+ // TODO: should we use DefineProperty internally if this object doesn't have the property yet?
+ JS_SetProperty(ctx, *this_val, prop_atom, extra_prop_value); // consumes extra_prop_value
+ JS_FreeAtom(ctx, prop_atom);
+}
+
+void QTS_DefineProp(JSContext *ctx, JSValueConst *this_val, JSValueConst *prop_name, JSValueConst *prop_value, JSValueConst *get, JSValueConst *set, bool configurable, bool enumerable, bool has_value) {
+ JSAtom prop_atom = JS_ValueToAtom(ctx, *prop_name);
+
+ int flags = 0;
+ if (configurable) {
+ flags = flags | JS_PROP_CONFIGURABLE;
+ if (has_value) {
+ flags = flags | JS_PROP_HAS_CONFIGURABLE;
+ }
+ }
+ if (enumerable) {
+ flags = flags | JS_PROP_ENUMERABLE;
+ if (has_value) {
+ flags = flags | JS_PROP_HAS_ENUMERABLE;
+ }
+ }
+ if (!JS_IsUndefined(*get)) {
+ flags = flags | JS_PROP_HAS_GET;
+ }
+ if (!JS_IsUndefined(*set)) {
+ flags = flags | JS_PROP_HAS_SET;
+ }
+ if (has_value) {
+ flags = flags | JS_PROP_HAS_VALUE;
+ }
+
+ JS_DefineProperty(ctx, *this_val, prop_atom, *prop_value, *get, *set, flags);
+ JS_FreeAtom(ctx, prop_atom);
+}
+
+MaybeAsync(JSValue *) QTS_Call(JSContext *ctx, JSValueConst *func_obj, JSValueConst *this_obj, int argc, JSValueConst **argv_ptrs) {
+ // convert array of pointers to array of values
+ JSValueConst argv[argc];
+ int i;
+ for (i = 0; i < argc; i++) {
+ argv[i] = *(argv_ptrs[i]);
+ }
+
+ return jsvalue_to_heap(JS_Call(ctx, *func_obj, *this_obj, argc, argv));
+}
+
+/**
+ * If maybe_exception is an exception, get the error.
+ * Otherwise, return NULL.
+ */
+JSValue *QTS_ResolveException(JSContext *ctx, JSValue *maybe_exception) {
+ if (JS_IsException(*maybe_exception)) {
+ return jsvalue_to_heap(JS_GetException(ctx));
+ }
+
+ return NULL;
+}
+
+MaybeAsync(JSBorrowedChar *) QTS_Dump(JSContext *ctx, JSValueConst *obj) {
+ JSValue obj_json_value = JS_JSONStringify(ctx, *obj, JS_UNDEFINED, JS_UNDEFINED);
+ if (!JS_IsException(obj_json_value)) {
+ const char *obj_json_chars = JS_ToCString(ctx, obj_json_value);
+ JS_FreeValue(ctx, obj_json_value);
+ if (obj_json_chars != NULL) {
+ JSValue enumerable_props = JS_ParseJSON(ctx, obj_json_chars, strlen(obj_json_chars), "");
+ JS_FreeCString(ctx, obj_json_chars);
+ if (!JS_IsException(enumerable_props)) {
+ // Copy common non-enumerable props for different object types.
+ // Errors:
+ copy_prop_if_needed(ctx, enumerable_props, *obj, "name");
+ copy_prop_if_needed(ctx, enumerable_props, *obj, "message");
+ copy_prop_if_needed(ctx, enumerable_props, *obj, "stack");
+
+ // Serialize again.
+ JSValue enumerable_json = JS_JSONStringify(ctx, enumerable_props, JS_UNDEFINED, JS_UNDEFINED);
+ JS_FreeValue(ctx, enumerable_props);
+
+ JSBorrowedChar *result = QTS_GetString(ctx, &enumerable_json);
+ JS_FreeValue(ctx, enumerable_json);
+ return result;
+ }
+ }
+ }
+
+#ifdef QTS_DEBUG_MODE
+ qts_log("Error dumping JSON:");
+ js_std_dump_error(ctx);
+#endif
+
+ // Fallback: convert to string
+ return QTS_GetString(ctx, obj);
+}
+
+MaybeAsync(JSValue *) QTS_Eval(JSContext *ctx, BorrowedHeapChar *js_code, const char *filename, EvalDetectModule detectModule, EvalFlags evalFlags) {
+ size_t js_code_len = strlen(js_code);
+
+ if (detectModule) {
+ if (JS_DetectModule((const char *)js_code, js_code_len)) {
+ QTS_DEBUG("QTS_Eval: Detected module = true");
+ evalFlags |= JS_EVAL_TYPE_MODULE;
+ } else {
+ QTS_DEBUG("QTS_Eval: Detected module = false");
+ }
+ } else {
+ QTS_DEBUG("QTS_Eval: do not detect module");
+ }
+
+ return jsvalue_to_heap(JS_Eval(ctx, js_code, strlen(js_code), filename, evalFlags));
+}
+
+OwnedHeapChar *QTS_Typeof(JSContext *ctx, JSValueConst *value) {
+ const char *result = "unknown";
+ uint32_t tag = JS_VALUE_GET_TAG(*value);
+
+ if (JS_IsNumber(*value)) {
+ result = "number";
+ } else if (JS_IsBigInt(ctx, *value)) {
+ result = "bigint";
+ } else if (JS_IsBigFloat(*value)) {
+ result = "bigfloat";
+ } else if (JS_IsBigDecimal(*value)) {
+ result = "bigdecimal";
+ } else if (JS_IsFunction(ctx, *value)) {
+ result = "function";
+ } else if (JS_IsBool(*value)) {
+ result = "boolean";
+ } else if (JS_IsNull(*value)) {
+ result = "object";
+ } else if (JS_IsUndefined(*value)) {
+ result = "undefined";
+ } else if (JS_IsUninitialized(*value)) {
+ result = "undefined";
+ } else if (JS_IsString(*value)) {
+ result = "string";
+ } else if (JS_IsSymbol(*value)) {
+ result = "symbol";
+ } else if (JS_IsObject(*value)) {
+ result = "object";
+ }
+
+ char *out = strdup(result);
+ return out;
+}
+
+JSValue *QTS_GetGlobalObject(JSContext *ctx) {
+ return jsvalue_to_heap(JS_GetGlobalObject(ctx));
+}
+
+JSValue *QTS_NewPromiseCapability(JSContext *ctx, JSValue **resolve_funcs_out) {
+ JSValue resolve_funcs[2];
+ JSValue promise = JS_NewPromiseCapability(ctx, resolve_funcs);
+ resolve_funcs_out[0] = jsvalue_to_heap(resolve_funcs[0]);
+ resolve_funcs_out[1] = jsvalue_to_heap(resolve_funcs[1]);
+ return jsvalue_to_heap(promise);
+}
+
+void QTS_TestStringArg(const char *string) {
+ // pass
+}
+
+int QTS_BuildIsDebug() {
+#ifdef QTS_DEBUG_MODE
+ return 1;
+#else
+ return 0;
+#endif
+}
+
+int QTS_BuildIsAsyncify() {
+#ifdef QTS_ASYNCIFY
+ return 1;
+#else
+ return 0;
+#endif
+}
+
+// ----------------------------------------------------------------------------
+// Module loading helpers
+
+// ----------------------------------------------------------------------------
+// C -> Host Callbacks
+// Note: inside EM_JS, we need to use ['...'] subscript syntax for accessing JS
+// objects, because in optimized builds, Closure compiler will mangle all the
+// names.
+
+// -------------------
+// function: C -> Host
+#ifdef __EMSCRIPTEN__
+EM_JS(MaybeAsync(JSValue *), qts_host_call_function, (JSContext * ctx, JSValueConst *this_ptr, int argc, JSValueConst *argv, uint32_t magic_func_id), {
+#ifdef QTS_ASYNCIFY
+ const asyncify = {['handleSleep'] : Asyncify.handleSleep};
+#else
+ const asyncify = undefined;
+#endif
+ return Module['callbacks']['callFunction'](asyncify, ctx, this_ptr, argc, argv, magic_func_id);
+});
+#endif
+
+// Function: QuickJS -> C
+JSValue qts_call_function(JSContext *ctx, JSValueConst this_val, int argc, JSValueConst *argv, int magic) {
+ JSValue *result_ptr = qts_host_call_function(ctx, &this_val, argc, argv, magic);
+ if (result_ptr == NULL) {
+ return JS_UNDEFINED;
+ }
+ JSValue result = *result_ptr;
+ free(result_ptr);
+ return result;
+}
+
+// Function: Host -> QuickJS
+JSValue *QTS_NewFunction(JSContext *ctx, uint32_t func_id, const char *name) {
+#ifdef QTS_DEBUG_MODE
+ char msg[500];
+ sprintf(msg, "new_function(name: %s, magic: %d)", name, func_id);
+ QTS_DEBUG(msg)
+#endif
+ JSValue func_obj = JS_NewCFunctionMagic(
+ /* context */ ctx,
+ /* JSCFunctionMagic* */ &qts_call_function,
+ /* name */ name,
+ /* min argc */ 0,
+ /* function type */ JS_CFUNC_generic_magic,
+ /* magic: fn id */ func_id);
+ return jsvalue_to_heap(func_obj);
+}
+
+JSValueConst *QTS_ArgvGetJSValueConstPointer(JSValueConst *argv, int index) {
+ return &argv[index];
+}
+
+// --------------------
+// interrupt: C -> Host
+#ifdef __EMSCRIPTEN__
+EM_JS(int, qts_host_interrupt_handler, (JSRuntime * rt), {
+ // Async not supported here.
+ // #ifdef QTS_ASYNCIFY
+ // const asyncify = Asyncify;
+ // #else
+ const asyncify = undefined;
+ // #endif
+ return Module['callbacks']['shouldInterrupt'](asyncify, rt);
+});
+#endif
+
+// interrupt: QuickJS -> C
+int qts_interrupt_handler(JSRuntime *rt, void *_unused) {
+ return qts_host_interrupt_handler(rt);
+}
+
+// interrupt: Host -> QuickJS
+void QTS_RuntimeEnableInterruptHandler(JSRuntime *rt) {
+ JS_SetInterruptHandler(rt, &qts_interrupt_handler, NULL);
+}
+
+void QTS_RuntimeDisableInterruptHandler(JSRuntime *rt) {
+ JS_SetInterruptHandler(rt, NULL, NULL);
+}
+
+// --------------------
+// load module: C -> Host
+// TODO: a future version can support host returning JSModuleDef* directly;
+// for now we only support loading module source code.
+
+/*
+The module loading model under ASYNCIFY is convoluted. We need to make sure we
+never have an async request running concurrently for loading modules.
+
+The first implemenation looked like this:
+
+C HOST SUSPENDED
+qts_host_load_module(name) ------> false
+ call rt.loadModule(name) false
+ Start async load module false
+ Suspend C true
+ Async load complete true
+ < --------------- QTS_CompileModule(source) true
+QTS_Eval(source, COMPILE_ONLY) true
+Loaded module has import true
+qts_host_load_module(dep) -------> true
+ call rt.loadModule(dep) true
+ Start async load module true
+ ALREADY SUSPENDED, CRASH
+
+We can solve this in two different ways:
+
+1. Return to C as soon as we async load the module source.
+ That way, we unsuspend before calling QTS_CompileModule.
+2. Once we load the module, use a new API to detect and async
+ load the module's downstream dependencies. This way
+ they're loaded synchronously so we don't need to suspend "again".
+
+Probably we could optimize (2) to make it more performant, eg with parallel
+loading, but (1) seems much easier to implement in the sort run.
+*/
+
+JSModuleDef *qts_compile_module(JSContext *ctx, const char *module_name, BorrowedHeapChar *module_body) {
+#ifdef QTS_DEBUG_MODE
+ char msg[500];
+ sprintf(msg, "QTS_CompileModule(ctx: %p, name: %s, bodyLength: %lu)", ctx, module_name, strlen(module_body));
+ QTS_DEBUG(msg)
+#endif
+ JSValue func_val = JS_Eval(ctx, module_body, strlen(module_body), module_name, JS_EVAL_TYPE_MODULE | JS_EVAL_FLAG_COMPILE_ONLY);
+ if (JS_IsException(func_val)) {
+ return NULL;
+ }
+ // TODO: Is exception ok?
+ // TODO: set import.meta?
+ JSModuleDef *module = JS_VALUE_GET_PTR(func_val);
+ JS_FreeValue(ctx, func_val);
+ return module;
+}
+
+#ifdef __EMSCRIPTEN__
+EM_JS(MaybeAsync(char *), qts_host_load_module_source, (JSRuntime * rt, JSContext *ctx, const char *module_name), {
+#ifdef QTS_ASYNCIFY
+ const asyncify = {['handleSleep'] : Asyncify.handleSleep};
+#else
+ const asyncify = undefined;
+#endif
+ // https://emscripten.org/docs/api_reference/preamble.js.html#UTF8ToString
+ const moduleNameString = UTF8ToString(module_name);
+ return Module['callbacks']['loadModuleSource'](asyncify, rt, ctx, moduleNameString);
+});
+
+EM_JS(MaybeAsync(char *), qts_host_normalize_module, (JSRuntime * rt, JSContext *ctx, const char *module_base_name, const char *module_name), {
+#ifdef QTS_ASYNCIFY
+ const asyncify = {['handleSleep'] : Asyncify.handleSleep};
+#else
+ const asyncify = undefined;
+#endif
+ // https://emscripten.org/docs/api_reference/preamble.js.html#UTF8ToString
+ const moduleBaseNameString = UTF8ToString(module_base_name);
+ const moduleNameString = UTF8ToString(module_name);
+ return Module['callbacks']['normalizeModule'](asyncify, rt, ctx, moduleBaseNameString, moduleNameString);
+});
+#endif
+
+// load module: QuickJS -> C
+// See js_module_loader in quickjs/quickjs-libc.c:567
+JSModuleDef *qts_load_module(JSContext *ctx, const char *module_name, void *_unused) {
+ JSRuntime *rt = JS_GetRuntime(ctx);
+#ifdef QTS_DEBUG_MODE
+ char msg[500];
+ sprintf(msg, "qts_load_module(rt: %p, ctx: %p, name: %s)", rt, ctx, module_name);
+ QTS_DEBUG(msg)
+#endif
+ char *module_source = qts_host_load_module_source(rt, ctx, module_name);
+ if (module_source == NULL) {
+ return NULL;
+ }
+
+ JSModuleDef *module = qts_compile_module(ctx, module_name, module_source);
+ free(module_source);
+ return module;
+}
+
+char *qts_normalize_module(JSContext *ctx, const char *module_base_name, const char *module_name, void *_unused) {
+ JSRuntime *rt = JS_GetRuntime(ctx);
+#ifdef QTS_DEBUG_MODE
+ char msg[500];
+ sprintf(msg, "qts_normalize_module(rt: %p, ctx: %p, base_name: %s, name: %s)", rt, ctx, module_base_name, module_name);
+ QTS_DEBUG(msg)
+#endif
+ char *em_module_name = qts_host_normalize_module(rt, ctx, module_base_name, module_name);
+ char *js_module_name = js_strdup(ctx, em_module_name);
+ free(em_module_name);
+ return js_module_name;
+}
+
+// Load module: Host -> QuickJS
+void QTS_RuntimeEnableModuleLoader(JSRuntime *rt, int use_custom_normalize) {
+ JSModuleNormalizeFunc *module_normalize = NULL; /* use default name normalizer */
+ if (use_custom_normalize) {
+ module_normalize = &qts_normalize_module;
+ }
+ JS_SetModuleLoaderFunc(rt, module_normalize, &qts_load_module, NULL);
+}
+
+void QTS_RuntimeDisableModuleLoader(JSRuntime *rt) {
+ JS_SetModuleLoaderFunc(rt, NULL, NULL, NULL);
+}
\ No newline at end of file
diff --git a/node_modules/@tootallnate/quickjs-emscripten/dist/asyncify-helpers.d.ts b/node_modules/@tootallnate/quickjs-emscripten/dist/asyncify-helpers.d.ts
new file mode 100644
index 0000000..f3bb599
--- /dev/null
+++ b/node_modules/@tootallnate/quickjs-emscripten/dist/asyncify-helpers.d.ts
@@ -0,0 +1,24 @@
+declare function awaitYield(value: T | Promise): Generator, T, T>;
+declare function awaitYieldOf(generator: Generator, T, Yielded>): Generator, T, T>;
+export type AwaitYield = typeof awaitYield & {
+ of: typeof awaitYieldOf;
+};
+/**
+ * Create a function that may or may not be async, using a generator
+ *
+ * Within the generator, call `yield* awaited(maybePromise)` to await a value
+ * that may or may not be a promise.
+ *
+ * If the inner function never yields a promise, it will return synchronously.
+ */
+export declare function maybeAsyncFn<
+/** Function arguments */
+Args extends any[], This,
+/** Function return type */
+Return,
+/** Yields to unwrap */
+Yielded>(that: This, fn: (this: This, awaited: AwaitYield, ...args: Args) => Generator, Return, Yielded>): (...args: Args) => Return | Promise;
+export type MaybeAsyncBlock = (this: This, awaited: AwaitYield, ...args: Args) => Generator, Return, Yielded>;
+export declare function maybeAsync(that: This, startGenerator: (this: This, await: AwaitYield) => Generator, Return, Yielded>): Return | Promise;
+export declare function awaitEachYieldedPromise(gen: Generator, Returned, Yielded>): Returned | Promise;
+export {};
diff --git a/node_modules/@tootallnate/quickjs-emscripten/dist/asyncify-helpers.js b/node_modules/@tootallnate/quickjs-emscripten/dist/asyncify-helpers.js
new file mode 100644
index 0000000..c140dde
--- /dev/null
+++ b/node_modules/@tootallnate/quickjs-emscripten/dist/asyncify-helpers.js
@@ -0,0 +1,53 @@
+"use strict";
+Object.defineProperty(exports, "__esModule", { value: true });
+exports.awaitEachYieldedPromise = exports.maybeAsync = exports.maybeAsyncFn = void 0;
+function* awaitYield(value) {
+ return (yield value);
+}
+function awaitYieldOf(generator) {
+ return awaitYield(awaitEachYieldedPromise(generator));
+}
+const AwaitYield = awaitYield;
+AwaitYield.of = awaitYieldOf;
+/**
+ * Create a function that may or may not be async, using a generator
+ *
+ * Within the generator, call `yield* awaited(maybePromise)` to await a value
+ * that may or may not be a promise.
+ *
+ * If the inner function never yields a promise, it will return synchronously.
+ */
+function maybeAsyncFn(that, fn) {
+ return (...args) => {
+ const generator = fn.call(that, AwaitYield, ...args);
+ return awaitEachYieldedPromise(generator);
+ };
+}
+exports.maybeAsyncFn = maybeAsyncFn;
+class Example {
+ constructor() {
+ this.maybeAsyncMethod = maybeAsyncFn(this, function* (awaited, a) {
+ yield* awaited(new Promise((resolve) => setTimeout(resolve, a)));
+ return 5;
+ });
+ }
+}
+function maybeAsync(that, startGenerator) {
+ const generator = startGenerator.call(that, AwaitYield);
+ return awaitEachYieldedPromise(generator);
+}
+exports.maybeAsync = maybeAsync;
+function awaitEachYieldedPromise(gen) {
+ function handleNextStep(step) {
+ if (step.done) {
+ return step.value;
+ }
+ if (step.value instanceof Promise) {
+ return step.value.then((value) => handleNextStep(gen.next(value)), (error) => handleNextStep(gen.throw(error)));
+ }
+ return handleNextStep(gen.next(step.value));
+ }
+ return handleNextStep(gen.next());
+}
+exports.awaitEachYieldedPromise = awaitEachYieldedPromise;
+//# sourceMappingURL=asyncify-helpers.js.map
\ No newline at end of file
diff --git a/node_modules/@tootallnate/quickjs-emscripten/dist/asyncify-helpers.js.map b/node_modules/@tootallnate/quickjs-emscripten/dist/asyncify-helpers.js.map
new file mode 100644
index 0000000..10dcc46
--- /dev/null
+++ b/node_modules/@tootallnate/quickjs-emscripten/dist/asyncify-helpers.js.map
@@ -0,0 +1 @@
+{"version":3,"file":"asyncify-helpers.js","sourceRoot":"","sources":["../ts/asyncify-helpers.ts"],"names":[],"mappings":";;;AAAA,QAAQ,CAAC,CAAC,UAAU,CAAI,KAAqB;IAC3C,OAAO,CAAC,MAAM,KAAK,CAAM,CAAA;AAC3B,CAAC;AAED,SAAS,YAAY,CACnB,SAA4D;IAE5D,OAAO,UAAU,CAAC,uBAAuB,CAAC,SAAS,CAAC,CAAC,CAAA;AACvD,CAAC;AAMD,MAAM,UAAU,GAAe,UAAwB,CAAA;AACvD,UAAU,CAAC,EAAE,GAAG,YAAY,CAAA;AAE5B;;;;;;;GAOG;AACH,SAAgB,YAAY,CAS1B,IAAU,EACV,EAI2D;IAE3D,OAAO,CAAC,GAAG,IAAU,EAAE,EAAE;QACvB,MAAM,SAAS,GAAG,EAAE,CAAC,IAAI,CAAC,IAAI,EAAE,UAAU,EAAE,GAAG,IAAI,CAAC,CAAA;QACpD,OAAO,uBAAuB,CAAC,SAAS,CAAC,CAAA;IAC3C,CAAC,CAAA;AACH,CAAC;AApBD,oCAoBC;AAED,MAAM,OAAO;IAAb;QACU,qBAAgB,GAAG,YAAY,CAAC,IAAI,EAAE,QAAQ,CAAC,EAAE,OAAO,EAAE,CAAS;YACzE,KAAK,CAAC,CAAC,OAAO,CAAC,IAAI,OAAO,CAAC,CAAC,OAAO,EAAE,EAAE,CAAC,UAAU,CAAC,OAAO,EAAE,CAAC,CAAC,CAAC,CAAC,CAAA;YAChE,OAAO,CAAC,CAAA;QACV,CAAC,CAAC,CAAA;IACJ,CAAC;CAAA;AAQD,SAAgB,UAAU,CACxB,IAAU,EACV,cAG2D;IAE3D,MAAM,SAAS,GAAG,cAAc,CAAC,IAAI,CAAC,IAAI,EAAE,UAAU,CAAC,CAAA;IACvD,OAAO,uBAAuB,CAAC,SAAS,CAAC,CAAA;AAC3C,CAAC;AATD,gCASC;AAED,SAAgB,uBAAuB,CACrC,GAA6D;IAI7D,SAAS,cAAc,CAAC,IAAgB;QACtC,IAAI,IAAI,CAAC,IAAI,EAAE;YACb,OAAO,IAAI,CAAC,KAAK,CAAA;SAClB;QAED,IAAI,IAAI,CAAC,KAAK,YAAY,OAAO,EAAE;YACjC,OAAO,IAAI,CAAC,KAAK,CAAC,IAAI,CACpB,CAAC,KAAK,EAAE,EAAE,CAAC,cAAc,CAAC,GAAG,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC,EAC1C,CAAC,KAAK,EAAE,EAAE,CAAC,cAAc,CAAC,GAAG,CAAC,KAAK,CAAC,KAAK,CAAC,CAAC,CAC5C,CAAA;SACF;QAED,OAAO,cAAc,CAAC,GAAG,CAAC,IAAI,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC,CAAA;IAC7C,CAAC;IAED,OAAO,cAAc,CAAC,GAAG,CAAC,IAAI,EAAE,CAAC,CAAA;AACnC,CAAC;AArBD,0DAqBC","sourcesContent":["function* awaitYield(value: T | Promise) {\n return (yield value) as T\n}\n\nfunction awaitYieldOf(\n generator: Generator, T, Yielded>\n): Generator, T, T> {\n return awaitYield(awaitEachYieldedPromise(generator))\n}\n\nexport type AwaitYield = typeof awaitYield & {\n of: typeof awaitYieldOf\n}\n\nconst AwaitYield: AwaitYield = awaitYield as AwaitYield\nAwaitYield.of = awaitYieldOf\n\n/**\n * Create a function that may or may not be async, using a generator\n *\n * Within the generator, call `yield* awaited(maybePromise)` to await a value\n * that may or may not be a promise.\n *\n * If the inner function never yields a promise, it will return synchronously.\n */\nexport function maybeAsyncFn<\n /** Function arguments */\n Args extends any[],\n This,\n /** Function return type */\n Return,\n /** Yields to unwrap */\n Yielded\n>(\n that: This,\n fn: (\n this: This,\n awaited: AwaitYield,\n ...args: Args\n ) => Generator, Return, Yielded>\n): (...args: Args) => Return | Promise {\n return (...args: Args) => {\n const generator = fn.call(that, AwaitYield, ...args)\n return awaitEachYieldedPromise(generator)\n }\n}\n\nclass Example {\n private maybeAsyncMethod = maybeAsyncFn(this, function* (awaited, a: number) {\n yield* awaited(new Promise((resolve) => setTimeout(resolve, a)))\n return 5\n })\n}\n\nexport type MaybeAsyncBlock = (\n this: This,\n awaited: AwaitYield,\n ...args: Args\n) => Generator, Return, Yielded>\n\nexport function maybeAsync(\n that: This,\n startGenerator: (\n this: This,\n await: AwaitYield\n ) => Generator, Return, Yielded>\n): Return | Promise {\n const generator = startGenerator.call(that, AwaitYield)\n return awaitEachYieldedPromise(generator)\n}\n\nexport function awaitEachYieldedPromise(\n gen: Generator, Returned, Yielded>\n): Returned | Promise {\n type NextResult = ReturnType\n\n function handleNextStep(step: NextResult): Returned | Promise {\n if (step.done) {\n return step.value\n }\n\n if (step.value instanceof Promise) {\n return step.value.then(\n (value) => handleNextStep(gen.next(value)),\n (error) => handleNextStep(gen.throw(error))\n )\n }\n\n return handleNextStep(gen.next(step.value))\n }\n\n return handleNextStep(gen.next())\n}\n"]}
\ No newline at end of file
diff --git a/node_modules/@tootallnate/quickjs-emscripten/dist/context-asyncify.d.ts b/node_modules/@tootallnate/quickjs-emscripten/dist/context-asyncify.d.ts
new file mode 100644
index 0000000..290a9ec
--- /dev/null
+++ b/node_modules/@tootallnate/quickjs-emscripten/dist/context-asyncify.d.ts
@@ -0,0 +1,48 @@
+import { QuickJSContext } from "./context";
+import { QuickJSAsyncEmscriptenModule } from "./emscripten-types";
+import { QuickJSAsyncFFI } from "./variants";
+import { JSRuntimePointer } from "./types-ffi";
+import { Lifetime } from "./lifetime";
+import { QuickJSModuleCallbacks } from "./module";
+import { QuickJSAsyncRuntime } from "./runtime-asyncify";
+import { ContextEvalOptions, QuickJSHandle } from "./types";
+import { VmCallResult } from "./vm-interface";
+export type AsyncFunctionImplementation = (this: QuickJSHandle, ...args: QuickJSHandle[]) => Promise | void>;
+/**
+ * Asyncified version of [[QuickJSContext]].
+ *
+ * *Asyncify* allows normally synchronous code to wait for asynchronous Promises
+ * or callbacks. The asyncified version of QuickJSContext can wait for async
+ * host functions as though they were synchronous.
+ */
+export declare class QuickJSAsyncContext extends QuickJSContext {
+ runtime: QuickJSAsyncRuntime;
+ /** @private */
+ protected module: QuickJSAsyncEmscriptenModule;
+ /** @private */
+ protected ffi: QuickJSAsyncFFI;
+ /** @private */
+ protected rt: Lifetime;
+ /** @private */
+ protected callbacks: QuickJSModuleCallbacks;
+ /**
+ * Asyncified version of [[evalCode]].
+ */
+ evalCodeAsync(code: string, filename?: string,
+ /** See [[EvalFlags]] for number semantics */
+ options?: number | ContextEvalOptions): Promise>;
+ /**
+ * Similar to [[newFunction]].
+ * Convert an async host Javascript function into a synchronous QuickJS function value.
+ *
+ * Whenever QuickJS calls this function, the VM's stack will be unwound while
+ * waiting the async function to complete, and then restored when the returned
+ * promise resolves.
+ *
+ * Asyncified functions must never call other asyncified functions or
+ * `import`, even indirectly, because the stack cannot be unwound twice.
+ *
+ * See [Emscripten's docs on Asyncify](https://emscripten.org/docs/porting/asyncify.html).
+ */
+ newAsyncifiedFunction(name: string, fn: AsyncFunctionImplementation): QuickJSHandle;
+}
diff --git a/node_modules/@tootallnate/quickjs-emscripten/dist/context-asyncify.js b/node_modules/@tootallnate/quickjs-emscripten/dist/context-asyncify.js
new file mode 100644
index 0000000..7b3fe56
--- /dev/null
+++ b/node_modules/@tootallnate/quickjs-emscripten/dist/context-asyncify.js
@@ -0,0 +1,58 @@
+"use strict";
+Object.defineProperty(exports, "__esModule", { value: true });
+exports.QuickJSAsyncContext = void 0;
+const context_1 = require("./context");
+const debug_1 = require("./debug");
+const types_1 = require("./types");
+/**
+ * Asyncified version of [[QuickJSContext]].
+ *
+ * *Asyncify* allows normally synchronous code to wait for asynchronous Promises
+ * or callbacks. The asyncified version of QuickJSContext can wait for async
+ * host functions as though they were synchronous.
+ */
+class QuickJSAsyncContext extends context_1.QuickJSContext {
+ /**
+ * Asyncified version of [[evalCode]].
+ */
+ async evalCodeAsync(code, filename = "eval.js",
+ /** See [[EvalFlags]] for number semantics */
+ options) {
+ const detectModule = (options === undefined ? 1 : 0);
+ const flags = (0, types_1.evalOptionsToFlags)(options);
+ let resultPtr = 0;
+ try {
+ resultPtr = await this.memory
+ .newHeapCharPointer(code)
+ .consume((charHandle) => this.ffi.QTS_Eval_MaybeAsync(this.ctx.value, charHandle.value, filename, detectModule, flags));
+ }
+ catch (error) {
+ (0, debug_1.debugLog)("QTS_Eval_MaybeAsync threw", error);
+ throw error;
+ }
+ const errorPtr = this.ffi.QTS_ResolveException(this.ctx.value, resultPtr);
+ if (errorPtr) {
+ this.ffi.QTS_FreeValuePointer(this.ctx.value, resultPtr);
+ return { error: this.memory.heapValueHandle(errorPtr) };
+ }
+ return { value: this.memory.heapValueHandle(resultPtr) };
+ }
+ /**
+ * Similar to [[newFunction]].
+ * Convert an async host Javascript function into a synchronous QuickJS function value.
+ *
+ * Whenever QuickJS calls this function, the VM's stack will be unwound while
+ * waiting the async function to complete, and then restored when the returned
+ * promise resolves.
+ *
+ * Asyncified functions must never call other asyncified functions or
+ * `import`, even indirectly, because the stack cannot be unwound twice.
+ *
+ * See [Emscripten's docs on Asyncify](https://emscripten.org/docs/porting/asyncify.html).
+ */
+ newAsyncifiedFunction(name, fn) {
+ return this.newFunction(name, fn);
+ }
+}
+exports.QuickJSAsyncContext = QuickJSAsyncContext;
+//# sourceMappingURL=context-asyncify.js.map
\ No newline at end of file
diff --git a/node_modules/@tootallnate/quickjs-emscripten/dist/context-asyncify.js.map b/node_modules/@tootallnate/quickjs-emscripten/dist/context-asyncify.js.map
new file mode 100644
index 0000000..93695e2
--- /dev/null
+++ b/node_modules/@tootallnate/quickjs-emscripten/dist/context-asyncify.js.map
@@ -0,0 +1 @@
+{"version":3,"file":"context-asyncify.js","sourceRoot":"","sources":["../ts/context-asyncify.ts"],"names":[],"mappings":";;;AAAA,uCAA0C;AAC1C,mCAAkC;AAOlC,mCAA+E;AAQ/E;;;;;;GAMG;AACH,MAAa,mBAAoB,SAAQ,wBAAc;IAWrD;;OAEG;IACH,KAAK,CAAC,aAAa,CACjB,IAAY,EACZ,WAAmB,SAAS;IAC5B,6CAA6C;IAC7C,OAAqC;QAErC,MAAM,YAAY,GAAG,CAAC,OAAO,KAAK,SAAS,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAqB,CAAA;QACxE,MAAM,KAAK,GAAG,IAAA,0BAAkB,EAAC,OAAO,CAAc,CAAA;QACtD,IAAI,SAAS,GAAG,CAAmB,CAAA;QACnC,IAAI;YACF,SAAS,GAAG,MAAM,IAAI,CAAC,MAAM;iBAC1B,kBAAkB,CAAC,IAAI,CAAC;iBACxB,OAAO,CAAC,CAAC,UAAU,EAAE,EAAE,CACtB,IAAI,CAAC,GAAG,CAAC,mBAAmB,CAC1B,IAAI,CAAC,GAAG,CAAC,KAAK,EACd,UAAU,CAAC,KAAK,EAChB,QAAQ,EACR,YAAY,EACZ,KAAK,CACN,CACF,CAAA;SACJ;QAAC,OAAO,KAAK,EAAE;YACd,IAAA,gBAAQ,EAAC,2BAA2B,EAAE,KAAK,CAAC,CAAA;YAC5C,MAAM,KAAK,CAAA;SACZ;QACD,MAAM,QAAQ,GAAG,IAAI,CAAC,GAAG,CAAC,oBAAoB,CAAC,IAAI,CAAC,GAAG,CAAC,KAAK,EAAE,SAAS,CAAC,CAAA;QACzE,IAAI,QAAQ,EAAE;YACZ,IAAI,CAAC,GAAG,CAAC,oBAAoB,CAAC,IAAI,CAAC,GAAG,CAAC,KAAK,EAAE,SAAS,CAAC,CAAA;YACxD,OAAO,EAAE,KAAK,EAAE,IAAI,CAAC,MAAM,CAAC,eAAe,CAAC,QAAQ,CAAC,EAAE,CAAA;SACxD;QACD,OAAO,EAAE,KAAK,EAAE,IAAI,CAAC,MAAM,CAAC,eAAe,CAAC,SAAS,CAAC,EAAE,CAAA;IAC1D,CAAC;IAED;;;;;;;;;;;;OAYG;IACH,qBAAqB,CAAC,IAAY,EAAE,EAA+B;QACjE,OAAO,IAAI,CAAC,WAAW,CAAC,IAAI,EAAE,EAAS,CAAC,CAAA;IAC1C,CAAC;CACF;AA/DD,kDA+DC","sourcesContent":["import { QuickJSContext } from \"./context\"\nimport { debugLog } from \"./debug\"\nimport { QuickJSAsyncEmscriptenModule } from \"./emscripten-types\"\nimport { QuickJSAsyncFFI } from \"./variants\"\nimport { EvalDetectModule, EvalFlags, JSRuntimePointer, JSValuePointer } from \"./types-ffi\"\nimport { Lifetime } from \"./lifetime\"\nimport { QuickJSModuleCallbacks } from \"./module\"\nimport { QuickJSAsyncRuntime } from \"./runtime-asyncify\"\nimport { ContextEvalOptions, evalOptionsToFlags, QuickJSHandle } from \"./types\"\nimport { VmCallResult } from \"./vm-interface\"\n\nexport type AsyncFunctionImplementation = (\n this: QuickJSHandle,\n ...args: QuickJSHandle[]\n) => Promise | void>\n\n/**\n * Asyncified version of [[QuickJSContext]].\n *\n * *Asyncify* allows normally synchronous code to wait for asynchronous Promises\n * or callbacks. The asyncified version of QuickJSContext can wait for async\n * host functions as though they were synchronous.\n */\nexport class QuickJSAsyncContext extends QuickJSContext {\n public declare runtime: QuickJSAsyncRuntime\n /** @private */\n protected declare module: QuickJSAsyncEmscriptenModule\n /** @private */\n protected declare ffi: QuickJSAsyncFFI\n /** @private */\n protected declare rt: Lifetime\n /** @private */\n protected declare callbacks: QuickJSModuleCallbacks\n\n /**\n * Asyncified version of [[evalCode]].\n */\n async evalCodeAsync(\n code: string,\n filename: string = \"eval.js\",\n /** See [[EvalFlags]] for number semantics */\n options?: number | ContextEvalOptions\n ): Promise> {\n const detectModule = (options === undefined ? 1 : 0) as EvalDetectModule\n const flags = evalOptionsToFlags(options) as EvalFlags\n let resultPtr = 0 as JSValuePointer\n try {\n resultPtr = await this.memory\n .newHeapCharPointer(code)\n .consume((charHandle) =>\n this.ffi.QTS_Eval_MaybeAsync(\n this.ctx.value,\n charHandle.value,\n filename,\n detectModule,\n flags\n )\n )\n } catch (error) {\n debugLog(\"QTS_Eval_MaybeAsync threw\", error)\n throw error\n }\n const errorPtr = this.ffi.QTS_ResolveException(this.ctx.value, resultPtr)\n if (errorPtr) {\n this.ffi.QTS_FreeValuePointer(this.ctx.value, resultPtr)\n return { error: this.memory.heapValueHandle(errorPtr) }\n }\n return { value: this.memory.heapValueHandle(resultPtr) }\n }\n\n /**\n * Similar to [[newFunction]].\n * Convert an async host Javascript function into a synchronous QuickJS function value.\n *\n * Whenever QuickJS calls this function, the VM's stack will be unwound while\n * waiting the async function to complete, and then restored when the returned\n * promise resolves.\n *\n * Asyncified functions must never call other asyncified functions or\n * `import`, even indirectly, because the stack cannot be unwound twice.\n *\n * See [Emscripten's docs on Asyncify](https://emscripten.org/docs/porting/asyncify.html).\n */\n newAsyncifiedFunction(name: string, fn: AsyncFunctionImplementation): QuickJSHandle {\n return this.newFunction(name, fn as any)\n }\n}\n"]}
\ No newline at end of file
diff --git a/node_modules/@tootallnate/quickjs-emscripten/dist/context.d.ts b/node_modules/@tootallnate/quickjs-emscripten/dist/context.d.ts
new file mode 100644
index 0000000..d30d199
--- /dev/null
+++ b/node_modules/@tootallnate/quickjs-emscripten/dist/context.d.ts
@@ -0,0 +1,371 @@
+import { QuickJSDeferredPromise } from "./deferred-promise";
+import type { EitherModule } from "./emscripten-types";
+import { JSBorrowedCharPointer, JSContextPointer, JSRuntimePointer, JSValueConstPointer, JSValuePointer } from "./types-ffi";
+import { Disposable, Lifetime, Scope } from "./lifetime";
+import { ModuleMemory } from "./memory";
+import { QuickJSModuleCallbacks } from "./module";
+import { QuickJSRuntime } from "./runtime";
+import { ContextEvalOptions, EitherFFI, JSValue, PromiseExecutor, QuickJSHandle } from "./types";
+import { LowLevelJavascriptVm, SuccessOrFail, VmCallResult, VmFunctionImplementation, VmPropertyDescriptor } from "./vm-interface";
+/**
+ * Property key for getting or setting a property on a handle with
+ * [[QuickJSContext.getProp]], [[QuickJSContext.setProp]], or [[QuickJSContext.defineProp]].
+ */
+export type QuickJSPropertyKey = number | string | QuickJSHandle;
+/**
+ * @private
+ */
+declare class ContextMemory extends ModuleMemory implements Disposable {
+ readonly owner: QuickJSRuntime;
+ readonly ctx: Lifetime;
+ readonly rt: Lifetime;
+ readonly module: EitherModule;
+ readonly ffi: EitherFFI;
+ readonly scope: Scope;
+ /** @private */
+ constructor(args: {
+ owner: QuickJSRuntime;
+ module: EitherModule;
+ ffi: EitherFFI;
+ ctx: Lifetime;
+ rt: Lifetime;
+ ownedLifetimes?: Disposable[];
+ });
+ get alive(): boolean;
+ dispose(): void;
+ /**
+ * Track `lifetime` so that it is disposed when this scope is disposed.
+ */
+ manage(lifetime: T): T;
+ copyJSValue: (ptr: JSValuePointer | JSValueConstPointer) => any;
+ freeJSValue: (ptr: JSValuePointer) => void;
+ consumeJSCharPointer(ptr: JSBorrowedCharPointer): string;
+ heapValueHandle(ptr: JSValuePointer): JSValue;
+}
+/**
+ * QuickJSContext wraps a QuickJS Javascript context (JSContext*) within a
+ * runtime. The contexts within the same runtime may exchange objects freely.
+ * You can think of separate runtimes like different domains in a browser, and
+ * the contexts within a runtime like the different windows open to the same
+ * domain. The {@link runtime} references the context's runtime.
+ *
+ * This class's methods return {@link QuickJSHandle}, which wrap C pointers (JSValue*).
+ * It's the caller's responsibility to call `.dispose()` on any
+ * handles you create to free memory once you're done with the handle.
+ *
+ * Use {@link QuickJSRuntime.newContext} or {@link QuickJSWASMModule.newContext}
+ * to create a new QuickJSContext.
+ *
+ * Create QuickJS values inside the interpreter with methods like
+ * [[newNumber]], [[newString]], [[newArray]], [[newObject]],
+ * [[newFunction]], and [[newPromise]].
+ *
+ * Call [[setProp]] or [[defineProp]] to customize objects. Use those methods
+ * with [[global]] to expose the values you create to the interior of the
+ * interpreter, so they can be used in [[evalCode]].
+ *
+ * Use [[evalCode]] or [[callFunction]] to execute Javascript inside the VM. If
+ * you're using asynchronous code inside the QuickJSContext, you may need to also
+ * call [[executePendingJobs]]. Executing code inside the runtime returns a
+ * result object representing successful execution or an error. You must dispose
+ * of any such results to avoid leaking memory inside the VM.
+ *
+ * Implement memory and CPU constraints at the runtime level, using [[runtime]].
+ * See {@link QuickJSRuntime} for more information.
+ *
+ */
+export declare class QuickJSContext implements LowLevelJavascriptVm, Disposable {
+ /**
+ * The runtime that created this context.
+ */
+ readonly runtime: QuickJSRuntime;
+ /** @private */
+ protected readonly ctx: Lifetime;
+ /** @private */
+ protected readonly rt: Lifetime;
+ /** @private */
+ protected readonly module: EitherModule;
+ /** @private */
+ protected readonly ffi: EitherFFI;
+ /** @private */
+ protected memory: ContextMemory;
+ /** @private */
+ protected _undefined: QuickJSHandle | undefined;
+ /** @private */
+ protected _null: QuickJSHandle | undefined;
+ /** @private */
+ protected _false: QuickJSHandle | undefined;
+ /** @private */
+ protected _true: QuickJSHandle | undefined;
+ /** @private */
+ protected _global: QuickJSHandle | undefined;
+ /** @private */
+ protected _BigInt: QuickJSHandle | undefined;
+ /**
+ * Use {@link QuickJS.createVm} to create a QuickJSContext instance.
+ */
+ constructor(args: {
+ module: EitherModule;
+ ffi: EitherFFI;
+ ctx: Lifetime;
+ rt: Lifetime;
+ runtime: QuickJSRuntime;
+ ownedLifetimes?: Disposable[];
+ callbacks: QuickJSModuleCallbacks;
+ });
+ get alive(): boolean;
+ /**
+ * Dispose of this VM's underlying resources.
+ *
+ * @throws Calling this method without disposing of all created handles
+ * will result in an error.
+ */
+ dispose(): void;
+ /**
+ * [`undefined`](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/undefined).
+ */
+ get undefined(): QuickJSHandle;
+ /**
+ * [`null`](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/null).
+ */
+ get null(): QuickJSHandle;
+ /**
+ * [`true`](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/true).
+ */
+ get true(): QuickJSHandle;
+ /**
+ * [`false`](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/false).
+ */
+ get false(): QuickJSHandle;
+ /**
+ * [`global`](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects).
+ * A handle to the global object inside the interpreter.
+ * You can set properties to create global variables.
+ */
+ get global(): QuickJSHandle;
+ /**
+ * Converts a Javascript number into a QuickJS value.
+ */
+ newNumber(num: number): QuickJSHandle;
+ /**
+ * Create a QuickJS [string](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/String) value.
+ */
+ newString(str: string): QuickJSHandle;
+ /**
+ * Create a QuickJS [symbol](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Symbol) value.
+ * No two symbols created with this function will be the same value.
+ */
+ newUniqueSymbol(description: string | symbol): QuickJSHandle;
+ /**
+ * Get a symbol from the [global registry](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Symbol#shared_symbols_in_the_global_symbol_registry) for the given key.
+ * All symbols created with the same key will be the same value.
+ */
+ newSymbolFor(key: string | symbol): QuickJSHandle;
+ /**
+ * Create a QuickJS [bigint](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/BigInt) value.
+ */
+ newBigInt(num: bigint): QuickJSHandle;
+ /**
+ * `{}`.
+ * Create a new QuickJS [object](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Operators/Object_initializer).
+ *
+ * @param prototype - Like [`Object.create`](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/create).
+ */
+ newObject(prototype?: QuickJSHandle): QuickJSHandle;
+ /**
+ * `[]`.
+ * Create a new QuickJS [array](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array).
+ */
+ newArray(): QuickJSHandle;
+ /**
+ * Create a new [[QuickJSDeferredPromise]]. Use `deferred.resolve(handle)` and
+ * `deferred.reject(handle)` to fulfill the promise handle available at `deferred.handle`.
+ * Note that you are responsible for calling `deferred.dispose()` to free the underlying
+ * resources; see the documentation on [[QuickJSDeferredPromise]] for details.
+ */
+ newPromise(): QuickJSDeferredPromise;
+ /**
+ * Create a new [[QuickJSDeferredPromise]] that resolves when the
+ * given native Promise resolves. Rejections will be coerced
+ * to a QuickJS error.
+ *
+ * You can still resolve/reject the created promise "early" using its methods.
+ */
+ newPromise(promise: Promise): QuickJSDeferredPromise;
+ /**
+ * Construct a new native Promise, and then convert it into a
+ * [[QuickJSDeferredPromise]].
+ *
+ * You can still resolve/reject the created promise "early" using its methods.
+ */
+ newPromise(newPromiseFn: PromiseExecutor): QuickJSDeferredPromise;
+ /**
+ * Convert a Javascript function into a QuickJS function value.
+ * See [[VmFunctionImplementation]] for more details.
+ *
+ * A [[VmFunctionImplementation]] should not free its arguments or its return
+ * value. A VmFunctionImplementation should also not retain any references to
+ * its return value.
+ *
+ * To implement an async function, create a promise with [[newPromise]], then
+ * return the deferred promise handle from `deferred.handle` from your
+ * function implementation:
+ *
+ * ```
+ * const deferred = vm.newPromise()
+ * someNativeAsyncFunction().then(deferred.resolve)
+ * return deferred.handle
+ * ```
+ */
+ newFunction(name: string, fn: VmFunctionImplementation): QuickJSHandle;
+ newError(error: {
+ name: string;
+ message: string;
+ }): QuickJSHandle;
+ newError(message: string): QuickJSHandle;
+ newError(): QuickJSHandle;
+ /**
+ * `typeof` operator. **Not** [standards compliant](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Operators/typeof).
+ *
+ * @remarks
+ * Does not support BigInt values correctly.
+ */
+ typeof(handle: QuickJSHandle): string;
+ /**
+ * Converts `handle` into a Javascript number.
+ * @returns `NaN` on error, otherwise a `number`.
+ */
+ getNumber(handle: QuickJSHandle): number;
+ /**
+ * Converts `handle` to a Javascript string.
+ */
+ getString(handle: QuickJSHandle): string;
+ /**
+ * Converts `handle` into a Javascript symbol. If the symbol is in the global
+ * registry in the guest, it will be created with Symbol.for on the host.
+ */
+ getSymbol(handle: QuickJSHandle): symbol;
+ /**
+ * Converts `handle` to a Javascript bigint.
+ */
+ getBigInt(handle: QuickJSHandle): bigint;
+ /**
+ * `Promise.resolve(value)`.
+ * Convert a handle containing a Promise-like value inside the VM into an
+ * actual promise on the host.
+ *
+ * @remarks
+ * You may need to call [[executePendingJobs]] to ensure that the promise is resolved.
+ *
+ * @param promiseLikeHandle - A handle to a Promise-like value with a `.then(onSuccess, onError)` method.
+ */
+ resolvePromise(promiseLikeHandle: QuickJSHandle): Promise>;
+ /**
+ * `handle[key]`.
+ * Get a property from a JSValue.
+ *
+ * @param key - The property may be specified as a JSValue handle, or as a
+ * Javascript string (which will be converted automatically).
+ */
+ getProp(handle: QuickJSHandle, key: QuickJSPropertyKey): QuickJSHandle;
+ /**
+ * `handle[key] = value`.
+ * Set a property on a JSValue.
+ *
+ * @remarks
+ * Note that the QuickJS authors recommend using [[defineProp]] to define new
+ * properties.
+ *
+ * @param key - The property may be specified as a JSValue handle, or as a
+ * Javascript string or number (which will be converted automatically to a JSValue).
+ */
+ setProp(handle: QuickJSHandle, key: QuickJSPropertyKey, value: QuickJSHandle): void;
+ /**
+ * [`Object.defineProperty(handle, key, descriptor)`](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/defineProperty).
+ *
+ * @param key - The property may be specified as a JSValue handle, or as a
+ * Javascript string or number (which will be converted automatically to a JSValue).
+ */
+ defineProp(handle: QuickJSHandle, key: QuickJSPropertyKey, descriptor: VmPropertyDescriptor): void;
+ /**
+ * [`func.call(thisVal, ...args)`](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Function/call).
+ * Call a JSValue as a function.
+ *
+ * See [[unwrapResult]], which will throw if the function returned an error, or
+ * return the result handle directly. If evaluation returned a handle containing
+ * a promise, use [[resolvePromise]] to convert it to a native promise and
+ * [[executePendingJobs]] to finish evaluating the promise.
+ *
+ * @returns A result. If the function threw synchronously, `result.error` be a
+ * handle to the exception. Otherwise `result.value` will be a handle to the
+ * value.
+ */
+ callFunction(func: QuickJSHandle, thisVal: QuickJSHandle, ...args: QuickJSHandle[]): VmCallResult;
+ /**
+ * Like [`eval(code)`](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/eval#Description).
+ * Evaluates the Javascript source `code` in the global scope of this VM.
+ * When working with async code, you many need to call [[executePendingJobs]]
+ * to execute callbacks pending after synchronous evaluation returns.
+ *
+ * See [[unwrapResult]], which will throw if the function returned an error, or
+ * return the result handle directly. If evaluation returned a handle containing
+ * a promise, use [[resolvePromise]] to convert it to a native promise and
+ * [[executePendingJobs]] to finish evaluating the promise.
+ *
+ * *Note*: to protect against infinite loops, provide an interrupt handler to
+ * [[setInterruptHandler]]. You can use [[shouldInterruptAfterDeadline]] to
+ * create a time-based deadline.
+ *
+ * @returns The last statement's value. If the code threw synchronously,
+ * `result.error` will be a handle to the exception. If execution was
+ * interrupted, the error will have name `InternalError` and message
+ * `interrupted`.
+ */
+ evalCode(code: string, filename?: string,
+ /**
+ * If no options are passed, a heuristic will be used to detect if `code` is
+ * an ES module.
+ *
+ * See [[EvalFlags]] for number semantics.
+ */
+ options?: number | ContextEvalOptions): VmCallResult;
+ /**
+ * Throw an error in the VM, interrupted whatever current execution is in progress when execution resumes.
+ * @experimental
+ */
+ throw(error: Error | QuickJSHandle): any;
+ /**
+ * @private
+ */
+ protected borrowPropertyKey(key: QuickJSPropertyKey): QuickJSHandle;
+ /**
+ * @private
+ */
+ getMemory(rt: JSRuntimePointer): ContextMemory;
+ /**
+ * Dump a JSValue to Javascript in a best-effort fashion.
+ * Returns `handle.toString()` if it cannot be serialized to JSON.
+ */
+ dump(handle: QuickJSHandle): any;
+ /**
+ * Unwrap a SuccessOrFail result such as a [[VmCallResult]] or a
+ * [[ExecutePendingJobsResult]], where the fail branch contains a handle to a QuickJS error value.
+ * If the result is a success, returns the value.
+ * If the result is an error, converts the error to a native object and throws the error.
+ */
+ unwrapResult(result: SuccessOrFail): T;
+ /** @private */
+ protected fnNextId: number;
+ /** @private */
+ protected fnMaps: Map>>;
+ /** @private */
+ protected getFunction(fn_id: number): VmFunctionImplementation | undefined;
+ /** @private */
+ protected setFunction(fn_id: number, handle: VmFunctionImplementation): Map>;
+ /**
+ * @hidden
+ */
+ private cToHostCallbacks;
+ private errorToHandle;
+}
+export {};
diff --git a/node_modules/@tootallnate/quickjs-emscripten/dist/context.js b/node_modules/@tootallnate/quickjs-emscripten/dist/context.js
new file mode 100644
index 0000000..e65258d
--- /dev/null
+++ b/node_modules/@tootallnate/quickjs-emscripten/dist/context.js
@@ -0,0 +1,691 @@
+"use strict";
+Object.defineProperty(exports, "__esModule", { value: true });
+exports.QuickJSContext = void 0;
+const debug_1 = require("./debug");
+const deferred_promise_1 = require("./deferred-promise");
+const errors_1 = require("./errors");
+const lifetime_1 = require("./lifetime");
+const memory_1 = require("./memory");
+const types_1 = require("./types");
+/**
+ * @private
+ */
+class ContextMemory extends memory_1.ModuleMemory {
+ /** @private */
+ constructor(args) {
+ super(args.module);
+ this.scope = new lifetime_1.Scope();
+ this.copyJSValue = (ptr) => {
+ return this.ffi.QTS_DupValuePointer(this.ctx.value, ptr);
+ };
+ this.freeJSValue = (ptr) => {
+ this.ffi.QTS_FreeValuePointer(this.ctx.value, ptr);
+ };
+ args.ownedLifetimes?.forEach((lifetime) => this.scope.manage(lifetime));
+ this.owner = args.owner;
+ this.module = args.module;
+ this.ffi = args.ffi;
+ this.rt = args.rt;
+ this.ctx = this.scope.manage(args.ctx);
+ }
+ get alive() {
+ return this.scope.alive;
+ }
+ dispose() {
+ return this.scope.dispose();
+ }
+ /**
+ * Track `lifetime` so that it is disposed when this scope is disposed.
+ */
+ manage(lifetime) {
+ return this.scope.manage(lifetime);
+ }
+ consumeJSCharPointer(ptr) {
+ const str = this.module.UTF8ToString(ptr);
+ this.ffi.QTS_FreeCString(this.ctx.value, ptr);
+ return str;
+ }
+ heapValueHandle(ptr) {
+ return new lifetime_1.Lifetime(ptr, this.copyJSValue, this.freeJSValue, this.owner);
+ }
+}
+/**
+ * QuickJSContext wraps a QuickJS Javascript context (JSContext*) within a
+ * runtime. The contexts within the same runtime may exchange objects freely.
+ * You can think of separate runtimes like different domains in a browser, and
+ * the contexts within a runtime like the different windows open to the same
+ * domain. The {@link runtime} references the context's runtime.
+ *
+ * This class's methods return {@link QuickJSHandle}, which wrap C pointers (JSValue*).
+ * It's the caller's responsibility to call `.dispose()` on any
+ * handles you create to free memory once you're done with the handle.
+ *
+ * Use {@link QuickJSRuntime.newContext} or {@link QuickJSWASMModule.newContext}
+ * to create a new QuickJSContext.
+ *
+ * Create QuickJS values inside the interpreter with methods like
+ * [[newNumber]], [[newString]], [[newArray]], [[newObject]],
+ * [[newFunction]], and [[newPromise]].
+ *
+ * Call [[setProp]] or [[defineProp]] to customize objects. Use those methods
+ * with [[global]] to expose the values you create to the interior of the
+ * interpreter, so they can be used in [[evalCode]].
+ *
+ * Use [[evalCode]] or [[callFunction]] to execute Javascript inside the VM. If
+ * you're using asynchronous code inside the QuickJSContext, you may need to also
+ * call [[executePendingJobs]]. Executing code inside the runtime returns a
+ * result object representing successful execution or an error. You must dispose
+ * of any such results to avoid leaking memory inside the VM.
+ *
+ * Implement memory and CPU constraints at the runtime level, using [[runtime]].
+ * See {@link QuickJSRuntime} for more information.
+ *
+ */
+// TODO: Manage own callback registration
+class QuickJSContext {
+ /**
+ * Use {@link QuickJS.createVm} to create a QuickJSContext instance.
+ */
+ constructor(args) {
+ /** @private */
+ this._undefined = undefined;
+ /** @private */
+ this._null = undefined;
+ /** @private */
+ this._false = undefined;
+ /** @private */
+ this._true = undefined;
+ /** @private */
+ this._global = undefined;
+ /** @private */
+ this._BigInt = undefined;
+ /** @private */
+ this.fnNextId = -32768; // min value of signed 16bit int used by Quickjs
+ /** @private */
+ this.fnMaps = new Map();
+ /**
+ * @hidden
+ */
+ this.cToHostCallbacks = {
+ callFunction: (ctx, this_ptr, argc, argv, fn_id) => {
+ if (ctx !== this.ctx.value) {
+ throw new Error("QuickJSContext instance received C -> JS call with mismatched ctx");
+ }
+ const fn = this.getFunction(fn_id);
+ if (!fn) {
+ // this "throw" is not catch-able from the TS side. could we somehow handle this higher up?
+ throw new Error(`QuickJSContext had no callback with id ${fn_id}`);
+ }
+ return lifetime_1.Scope.withScopeMaybeAsync(this, function* (awaited, scope) {
+ const thisHandle = scope.manage(new lifetime_1.WeakLifetime(this_ptr, this.memory.copyJSValue, this.memory.freeJSValue, this.runtime));
+ const argHandles = new Array(argc);
+ for (let i = 0; i < argc; i++) {
+ const ptr = this.ffi.QTS_ArgvGetJSValueConstPointer(argv, i);
+ argHandles[i] = scope.manage(new lifetime_1.WeakLifetime(ptr, this.memory.copyJSValue, this.memory.freeJSValue, this.runtime));
+ }
+ try {
+ const result = yield* awaited(fn.apply(thisHandle, argHandles));
+ if (result) {
+ if ("error" in result && result.error) {
+ (0, debug_1.debugLog)("throw error", result.error);
+ throw result.error;
+ }
+ const handle = scope.manage(result instanceof lifetime_1.Lifetime ? result : result.value);
+ return this.ffi.QTS_DupValuePointer(this.ctx.value, handle.value);
+ }
+ return 0;
+ }
+ catch (error) {
+ return this.errorToHandle(error).consume((errorHandle) => this.ffi.QTS_Throw(this.ctx.value, errorHandle.value));
+ }
+ });
+ },
+ };
+ this.runtime = args.runtime;
+ this.module = args.module;
+ this.ffi = args.ffi;
+ this.rt = args.rt;
+ this.ctx = args.ctx;
+ this.memory = new ContextMemory({
+ ...args,
+ owner: this.runtime,
+ });
+ args.callbacks.setContextCallbacks(this.ctx.value, this.cToHostCallbacks);
+ this.dump = this.dump.bind(this);
+ this.getString = this.getString.bind(this);
+ this.getNumber = this.getNumber.bind(this);
+ this.resolvePromise = this.resolvePromise.bind(this);
+ }
+ // @implement Disposable ----------------------------------------------------
+ get alive() {
+ return this.memory.alive;
+ }
+ /**
+ * Dispose of this VM's underlying resources.
+ *
+ * @throws Calling this method without disposing of all created handles
+ * will result in an error.
+ */
+ dispose() {
+ this.memory.dispose();
+ }
+ // Globals ------------------------------------------------------------------
+ /**
+ * [`undefined`](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/undefined).
+ */
+ get undefined() {
+ if (this._undefined) {
+ return this._undefined;
+ }
+ // Undefined is a constant, immutable value in QuickJS.
+ const ptr = this.ffi.QTS_GetUndefined();
+ return (this._undefined = new lifetime_1.StaticLifetime(ptr));
+ }
+ /**
+ * [`null`](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/null).
+ */
+ get null() {
+ if (this._null) {
+ return this._null;
+ }
+ // Null is a constant, immutable value in QuickJS.
+ const ptr = this.ffi.QTS_GetNull();
+ return (this._null = new lifetime_1.StaticLifetime(ptr));
+ }
+ /**
+ * [`true`](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/true).
+ */
+ get true() {
+ if (this._true) {
+ return this._true;
+ }
+ // True is a constant, immutable value in QuickJS.
+ const ptr = this.ffi.QTS_GetTrue();
+ return (this._true = new lifetime_1.StaticLifetime(ptr));
+ }
+ /**
+ * [`false`](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/false).
+ */
+ get false() {
+ if (this._false) {
+ return this._false;
+ }
+ // False is a constant, immutable value in QuickJS.
+ const ptr = this.ffi.QTS_GetFalse();
+ return (this._false = new lifetime_1.StaticLifetime(ptr));
+ }
+ /**
+ * [`global`](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects).
+ * A handle to the global object inside the interpreter.
+ * You can set properties to create global variables.
+ */
+ get global() {
+ if (this._global) {
+ return this._global;
+ }
+ // The global is a JSValue, but since it's lifetime is as long as the VM's,
+ // we should manage it.
+ const ptr = this.ffi.QTS_GetGlobalObject(this.ctx.value);
+ // Automatically clean up this reference when we dispose
+ this.memory.manage(this.memory.heapValueHandle(ptr));
+ // This isn't technically a static lifetime, but since it has the same
+ // lifetime as the VM, it's okay to fake one since when the VM is
+ // disposed, no other functions will accept the value.
+ this._global = new lifetime_1.StaticLifetime(ptr, this.runtime);
+ return this._global;
+ }
+ // New values ---------------------------------------------------------------
+ /**
+ * Converts a Javascript number into a QuickJS value.
+ */
+ newNumber(num) {
+ return this.memory.heapValueHandle(this.ffi.QTS_NewFloat64(this.ctx.value, num));
+ }
+ /**
+ * Create a QuickJS [string](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/String) value.
+ */
+ newString(str) {
+ const ptr = this.memory
+ .newHeapCharPointer(str)
+ .consume((charHandle) => this.ffi.QTS_NewString(this.ctx.value, charHandle.value));
+ return this.memory.heapValueHandle(ptr);
+ }
+ /**
+ * Create a QuickJS [symbol](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Symbol) value.
+ * No two symbols created with this function will be the same value.
+ */
+ newUniqueSymbol(description) {
+ const key = (typeof description === "symbol" ? description.description : description) ?? "";
+ const ptr = this.memory
+ .newHeapCharPointer(key)
+ .consume((charHandle) => this.ffi.QTS_NewSymbol(this.ctx.value, charHandle.value, 0));
+ return this.memory.heapValueHandle(ptr);
+ }
+ /**
+ * Get a symbol from the [global registry](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Symbol#shared_symbols_in_the_global_symbol_registry) for the given key.
+ * All symbols created with the same key will be the same value.
+ */
+ newSymbolFor(key) {
+ const description = (typeof key === "symbol" ? key.description : key) ?? "";
+ const ptr = this.memory
+ .newHeapCharPointer(description)
+ .consume((charHandle) => this.ffi.QTS_NewSymbol(this.ctx.value, charHandle.value, 1));
+ return this.memory.heapValueHandle(ptr);
+ }
+ /**
+ * Create a QuickJS [bigint](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/BigInt) value.
+ */
+ newBigInt(num) {
+ if (!this._BigInt) {
+ const bigIntHandle = this.getProp(this.global, "BigInt");
+ this.memory.manage(bigIntHandle);
+ this._BigInt = new lifetime_1.StaticLifetime(bigIntHandle.value, this.runtime);
+ }
+ const bigIntHandle = this._BigInt;
+ const asString = String(num);
+ return this.newString(asString).consume((handle) => this.unwrapResult(this.callFunction(bigIntHandle, this.undefined, handle)));
+ }
+ /**
+ * `{}`.
+ * Create a new QuickJS [object](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Operators/Object_initializer).
+ *
+ * @param prototype - Like [`Object.create`](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/create).
+ */
+ newObject(prototype) {
+ if (prototype) {
+ this.runtime.assertOwned(prototype);
+ }
+ const ptr = prototype
+ ? this.ffi.QTS_NewObjectProto(this.ctx.value, prototype.value)
+ : this.ffi.QTS_NewObject(this.ctx.value);
+ return this.memory.heapValueHandle(ptr);
+ }
+ /**
+ * `[]`.
+ * Create a new QuickJS [array](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array).
+ */
+ newArray() {
+ const ptr = this.ffi.QTS_NewArray(this.ctx.value);
+ return this.memory.heapValueHandle(ptr);
+ }
+ newPromise(value) {
+ const deferredPromise = lifetime_1.Scope.withScope((scope) => {
+ const mutablePointerArray = scope.manage(this.memory.newMutablePointerArray(2));
+ const promisePtr = this.ffi.QTS_NewPromiseCapability(this.ctx.value, mutablePointerArray.value.ptr);
+ const promiseHandle = this.memory.heapValueHandle(promisePtr);
+ const [resolveHandle, rejectHandle] = Array.from(mutablePointerArray.value.typedArray).map((jsvaluePtr) => this.memory.heapValueHandle(jsvaluePtr));
+ return new deferred_promise_1.QuickJSDeferredPromise({
+ context: this,
+ promiseHandle,
+ resolveHandle,
+ rejectHandle,
+ });
+ });
+ if (value && typeof value === "function") {
+ value = new Promise(value);
+ }
+ if (value) {
+ Promise.resolve(value).then(deferredPromise.resolve, (error) => error instanceof lifetime_1.Lifetime
+ ? deferredPromise.reject(error)
+ : this.newError(error).consume(deferredPromise.reject));
+ }
+ return deferredPromise;
+ }
+ /**
+ * Convert a Javascript function into a QuickJS function value.
+ * See [[VmFunctionImplementation]] for more details.
+ *
+ * A [[VmFunctionImplementation]] should not free its arguments or its return
+ * value. A VmFunctionImplementation should also not retain any references to
+ * its return value.
+ *
+ * To implement an async function, create a promise with [[newPromise]], then
+ * return the deferred promise handle from `deferred.handle` from your
+ * function implementation:
+ *
+ * ```
+ * const deferred = vm.newPromise()
+ * someNativeAsyncFunction().then(deferred.resolve)
+ * return deferred.handle
+ * ```
+ */
+ newFunction(name, fn) {
+ const fnId = ++this.fnNextId;
+ this.setFunction(fnId, fn);
+ return this.memory.heapValueHandle(this.ffi.QTS_NewFunction(this.ctx.value, fnId, name));
+ }
+ newError(error) {
+ const errorHandle = this.memory.heapValueHandle(this.ffi.QTS_NewError(this.ctx.value));
+ if (error && typeof error === "object") {
+ if (error.name !== undefined) {
+ this.newString(error.name).consume((handle) => this.setProp(errorHandle, "name", handle));
+ }
+ if (error.message !== undefined) {
+ this.newString(error.message).consume((handle) => this.setProp(errorHandle, "message", handle));
+ }
+ }
+ else if (typeof error === "string") {
+ this.newString(error).consume((handle) => this.setProp(errorHandle, "message", handle));
+ }
+ else if (error !== undefined) {
+ // This isn't supported in the type signature but maybe it will make life easier.
+ this.newString(String(error)).consume((handle) => this.setProp(errorHandle, "message", handle));
+ }
+ return errorHandle;
+ }
+ // Read values --------------------------------------------------------------
+ /**
+ * `typeof` operator. **Not** [standards compliant](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Operators/typeof).
+ *
+ * @remarks
+ * Does not support BigInt values correctly.
+ */
+ typeof(handle) {
+ this.runtime.assertOwned(handle);
+ return this.memory.consumeHeapCharPointer(this.ffi.QTS_Typeof(this.ctx.value, handle.value));
+ }
+ /**
+ * Converts `handle` into a Javascript number.
+ * @returns `NaN` on error, otherwise a `number`.
+ */
+ getNumber(handle) {
+ this.runtime.assertOwned(handle);
+ return this.ffi.QTS_GetFloat64(this.ctx.value, handle.value);
+ }
+ /**
+ * Converts `handle` to a Javascript string.
+ */
+ getString(handle) {
+ this.runtime.assertOwned(handle);
+ return this.memory.consumeJSCharPointer(this.ffi.QTS_GetString(this.ctx.value, handle.value));
+ }
+ /**
+ * Converts `handle` into a Javascript symbol. If the symbol is in the global
+ * registry in the guest, it will be created with Symbol.for on the host.
+ */
+ getSymbol(handle) {
+ this.runtime.assertOwned(handle);
+ const key = this.memory.consumeJSCharPointer(this.ffi.QTS_GetSymbolDescriptionOrKey(this.ctx.value, handle.value));
+ const isGlobal = this.ffi.QTS_IsGlobalSymbol(this.ctx.value, handle.value);
+ return isGlobal ? Symbol.for(key) : Symbol(key);
+ }
+ /**
+ * Converts `handle` to a Javascript bigint.
+ */
+ getBigInt(handle) {
+ this.runtime.assertOwned(handle);
+ const asString = this.getString(handle);
+ return BigInt(asString);
+ }
+ /**
+ * `Promise.resolve(value)`.
+ * Convert a handle containing a Promise-like value inside the VM into an
+ * actual promise on the host.
+ *
+ * @remarks
+ * You may need to call [[executePendingJobs]] to ensure that the promise is resolved.
+ *
+ * @param promiseLikeHandle - A handle to a Promise-like value with a `.then(onSuccess, onError)` method.
+ */
+ resolvePromise(promiseLikeHandle) {
+ this.runtime.assertOwned(promiseLikeHandle);
+ const vmResolveResult = lifetime_1.Scope.withScope((scope) => {
+ const vmPromise = scope.manage(this.getProp(this.global, "Promise"));
+ const vmPromiseResolve = scope.manage(this.getProp(vmPromise, "resolve"));
+ return this.callFunction(vmPromiseResolve, vmPromise, promiseLikeHandle);
+ });
+ if (vmResolveResult.error) {
+ return Promise.resolve(vmResolveResult);
+ }
+ return new Promise((resolve) => {
+ lifetime_1.Scope.withScope((scope) => {
+ const resolveHandle = scope.manage(this.newFunction("resolve", (value) => {
+ resolve({ value: value && value.dup() });
+ }));
+ const rejectHandle = scope.manage(this.newFunction("reject", (error) => {
+ resolve({ error: error && error.dup() });
+ }));
+ const promiseHandle = scope.manage(vmResolveResult.value);
+ const promiseThenHandle = scope.manage(this.getProp(promiseHandle, "then"));
+ this.unwrapResult(this.callFunction(promiseThenHandle, promiseHandle, resolveHandle, rejectHandle)).dispose();
+ });
+ });
+ }
+ // Properties ---------------------------------------------------------------
+ /**
+ * `handle[key]`.
+ * Get a property from a JSValue.
+ *
+ * @param key - The property may be specified as a JSValue handle, or as a
+ * Javascript string (which will be converted automatically).
+ */
+ getProp(handle, key) {
+ this.runtime.assertOwned(handle);
+ const ptr = this.borrowPropertyKey(key).consume((quickJSKey) => this.ffi.QTS_GetProp(this.ctx.value, handle.value, quickJSKey.value));
+ const result = this.memory.heapValueHandle(ptr);
+ return result;
+ }
+ /**
+ * `handle[key] = value`.
+ * Set a property on a JSValue.
+ *
+ * @remarks
+ * Note that the QuickJS authors recommend using [[defineProp]] to define new
+ * properties.
+ *
+ * @param key - The property may be specified as a JSValue handle, or as a
+ * Javascript string or number (which will be converted automatically to a JSValue).
+ */
+ setProp(handle, key, value) {
+ this.runtime.assertOwned(handle);
+ // free newly allocated value if key was a string or number. No-op if string was already
+ // a QuickJS handle.
+ this.borrowPropertyKey(key).consume((quickJSKey) => this.ffi.QTS_SetProp(this.ctx.value, handle.value, quickJSKey.value, value.value));
+ }
+ /**
+ * [`Object.defineProperty(handle, key, descriptor)`](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/defineProperty).
+ *
+ * @param key - The property may be specified as a JSValue handle, or as a
+ * Javascript string or number (which will be converted automatically to a JSValue).
+ */
+ defineProp(handle, key, descriptor) {
+ this.runtime.assertOwned(handle);
+ lifetime_1.Scope.withScope((scope) => {
+ const quickJSKey = scope.manage(this.borrowPropertyKey(key));
+ const value = descriptor.value || this.undefined;
+ const configurable = Boolean(descriptor.configurable);
+ const enumerable = Boolean(descriptor.enumerable);
+ const hasValue = Boolean(descriptor.value);
+ const get = descriptor.get
+ ? scope.manage(this.newFunction(descriptor.get.name, descriptor.get))
+ : this.undefined;
+ const set = descriptor.set
+ ? scope.manage(this.newFunction(descriptor.set.name, descriptor.set))
+ : this.undefined;
+ this.ffi.QTS_DefineProp(this.ctx.value, handle.value, quickJSKey.value, value.value, get.value, set.value, configurable, enumerable, hasValue);
+ });
+ }
+ // Evaluation ---------------------------------------------------------------
+ /**
+ * [`func.call(thisVal, ...args)`](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Function/call).
+ * Call a JSValue as a function.
+ *
+ * See [[unwrapResult]], which will throw if the function returned an error, or
+ * return the result handle directly. If evaluation returned a handle containing
+ * a promise, use [[resolvePromise]] to convert it to a native promise and
+ * [[executePendingJobs]] to finish evaluating the promise.
+ *
+ * @returns A result. If the function threw synchronously, `result.error` be a
+ * handle to the exception. Otherwise `result.value` will be a handle to the
+ * value.
+ */
+ callFunction(func, thisVal, ...args) {
+ this.runtime.assertOwned(func);
+ const resultPtr = this.memory
+ .toPointerArray(args)
+ .consume((argsArrayPtr) => this.ffi.QTS_Call(this.ctx.value, func.value, thisVal.value, args.length, argsArrayPtr.value));
+ const errorPtr = this.ffi.QTS_ResolveException(this.ctx.value, resultPtr);
+ if (errorPtr) {
+ this.ffi.QTS_FreeValuePointer(this.ctx.value, resultPtr);
+ return { error: this.memory.heapValueHandle(errorPtr) };
+ }
+ return { value: this.memory.heapValueHandle(resultPtr) };
+ }
+ /**
+ * Like [`eval(code)`](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/eval#Description).
+ * Evaluates the Javascript source `code` in the global scope of this VM.
+ * When working with async code, you many need to call [[executePendingJobs]]
+ * to execute callbacks pending after synchronous evaluation returns.
+ *
+ * See [[unwrapResult]], which will throw if the function returned an error, or
+ * return the result handle directly. If evaluation returned a handle containing
+ * a promise, use [[resolvePromise]] to convert it to a native promise and
+ * [[executePendingJobs]] to finish evaluating the promise.
+ *
+ * *Note*: to protect against infinite loops, provide an interrupt handler to
+ * [[setInterruptHandler]]. You can use [[shouldInterruptAfterDeadline]] to
+ * create a time-based deadline.
+ *
+ * @returns The last statement's value. If the code threw synchronously,
+ * `result.error` will be a handle to the exception. If execution was
+ * interrupted, the error will have name `InternalError` and message
+ * `interrupted`.
+ */
+ evalCode(code, filename = "eval.js",
+ /**
+ * If no options are passed, a heuristic will be used to detect if `code` is
+ * an ES module.
+ *
+ * See [[EvalFlags]] for number semantics.
+ */
+ options) {
+ const detectModule = (options === undefined ? 1 : 0);
+ const flags = (0, types_1.evalOptionsToFlags)(options);
+ const resultPtr = this.memory
+ .newHeapCharPointer(code)
+ .consume((charHandle) => this.ffi.QTS_Eval(this.ctx.value, charHandle.value, filename, detectModule, flags));
+ const errorPtr = this.ffi.QTS_ResolveException(this.ctx.value, resultPtr);
+ if (errorPtr) {
+ this.ffi.QTS_FreeValuePointer(this.ctx.value, resultPtr);
+ return { error: this.memory.heapValueHandle(errorPtr) };
+ }
+ return { value: this.memory.heapValueHandle(resultPtr) };
+ }
+ /**
+ * Throw an error in the VM, interrupted whatever current execution is in progress when execution resumes.
+ * @experimental
+ */
+ throw(error) {
+ return this.errorToHandle(error).consume((handle) => this.ffi.QTS_Throw(this.ctx.value, handle.value));
+ }
+ /**
+ * @private
+ */
+ borrowPropertyKey(key) {
+ if (typeof key === "number") {
+ return this.newNumber(key);
+ }
+ if (typeof key === "string") {
+ return this.newString(key);
+ }
+ // key is already a JSValue, but we're borrowing it. Return a static handle
+ // for internal use only.
+ return new lifetime_1.StaticLifetime(key.value, this.runtime);
+ }
+ /**
+ * @private
+ */
+ getMemory(rt) {
+ if (rt === this.rt.value) {
+ return this.memory;
+ }
+ else {
+ throw new Error("Private API. Cannot get memory from a different runtime");
+ }
+ }
+ // Utilities ----------------------------------------------------------------
+ /**
+ * Dump a JSValue to Javascript in a best-effort fashion.
+ * Returns `handle.toString()` if it cannot be serialized to JSON.
+ */
+ dump(handle) {
+ this.runtime.assertOwned(handle);
+ const type = this.typeof(handle);
+ if (type === "string") {
+ return this.getString(handle);
+ }
+ else if (type === "number") {
+ return this.getNumber(handle);
+ }
+ else if (type === "bigint") {
+ return this.getBigInt(handle);
+ }
+ else if (type === "undefined") {
+ return undefined;
+ }
+ else if (type === "symbol") {
+ return this.getSymbol(handle);
+ }
+ const str = this.memory.consumeJSCharPointer(this.ffi.QTS_Dump(this.ctx.value, handle.value));
+ try {
+ return JSON.parse(str);
+ }
+ catch (err) {
+ return str;
+ }
+ }
+ /**
+ * Unwrap a SuccessOrFail result such as a [[VmCallResult]] or a
+ * [[ExecutePendingJobsResult]], where the fail branch contains a handle to a QuickJS error value.
+ * If the result is a success, returns the value.
+ * If the result is an error, converts the error to a native object and throws the error.
+ */
+ unwrapResult(result) {
+ if (result.error) {
+ const context = "context" in result.error ? result.error.context : this;
+ const cause = result.error.consume((error) => this.dump(error));
+ if (cause && typeof cause === "object" && typeof cause.message === "string") {
+ const { message, name, stack } = cause;
+ const exception = new errors_1.QuickJSUnwrapError("");
+ const hostStack = exception.stack;
+ if (typeof name === "string") {
+ exception.name = cause.name;
+ }
+ if (typeof stack === "string") {
+ exception.stack = `${name}: ${message}\n${cause.stack}Host: ${hostStack}`;
+ }
+ Object.assign(exception, { cause, context, message });
+ throw exception;
+ }
+ throw new errors_1.QuickJSUnwrapError(cause, context);
+ }
+ return result.value;
+ }
+ /** @private */
+ getFunction(fn_id) {
+ const map_id = fn_id >> 8;
+ const fnMap = this.fnMaps.get(map_id);
+ if (!fnMap) {
+ return undefined;
+ }
+ return fnMap.get(fn_id);
+ }
+ /** @private */
+ setFunction(fn_id, handle) {
+ const map_id = fn_id >> 8;
+ let fnMap = this.fnMaps.get(map_id);
+ if (!fnMap) {
+ fnMap = new Map();
+ this.fnMaps.set(map_id, fnMap);
+ }
+ return fnMap.set(fn_id, handle);
+ }
+ errorToHandle(error) {
+ if (error instanceof lifetime_1.Lifetime) {
+ return error;
+ }
+ return this.newError(error);
+ }
+}
+exports.QuickJSContext = QuickJSContext;
+//# sourceMappingURL=context.js.map
\ No newline at end of file
diff --git a/node_modules/@tootallnate/quickjs-emscripten/dist/context.js.map b/node_modules/@tootallnate/quickjs-emscripten/dist/context.js.map
new file mode 100644
index 0000000..1398a53
--- /dev/null
+++ b/node_modules/@tootallnate/quickjs-emscripten/dist/context.js.map
@@ -0,0 +1 @@
+{"version":3,"file":"context.js","sourceRoot":"","sources":["../ts/context.ts"],"names":[],"mappings":";;;AAAA,mCAAkC;AAClC,yDAA2D;AAE3D,qCAA6C;AAa7C,yCAAsF;AACtF,qCAAuC;AAGvC,mCAOgB;AAehB;;GAEG;AACH,MAAM,aAAc,SAAQ,qBAAY;IAQtC,eAAe;IACf,YAAY,IAOX;QACC,KAAK,CAAC,IAAI,CAAC,MAAM,CAAC,CAAA;QAXX,UAAK,GAAG,IAAI,gBAAK,EAAE,CAAA;QAmC5B,gBAAW,GAAG,CAAC,GAAyC,EAAE,EAAE;YAC1D,OAAO,IAAI,CAAC,GAAG,CAAC,mBAAmB,CAAC,IAAI,CAAC,GAAG,CAAC,KAAK,EAAE,GAAG,CAAC,CAAA;QAC1D,CAAC,CAAA;QAED,gBAAW,GAAG,CAAC,GAAmB,EAAE,EAAE;YACpC,IAAI,CAAC,GAAG,CAAC,oBAAoB,CAAC,IAAI,CAAC,GAAG,CAAC,KAAK,EAAE,GAAG,CAAC,CAAA;QACpD,CAAC,CAAA;QA7BC,IAAI,CAAC,cAAc,EAAE,OAAO,CAAC,CAAC,QAAQ,EAAE,EAAE,CAAC,IAAI,CAAC,KAAK,CAAC,MAAM,CAAC,QAAQ,CAAC,CAAC,CAAA;QACvE,IAAI,CAAC,KAAK,GAAG,IAAI,CAAC,KAAK,CAAA;QACvB,IAAI,CAAC,MAAM,GAAG,IAAI,CAAC,MAAM,CAAA;QACzB,IAAI,CAAC,GAAG,GAAG,IAAI,CAAC,GAAG,CAAA;QACnB,IAAI,CAAC,EAAE,GAAG,IAAI,CAAC,EAAE,CAAA;QACjB,IAAI,CAAC,GAAG,GAAG,IAAI,CAAC,KAAK,CAAC,MAAM,CAAC,IAAI,CA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CAAA;QACzB,IAAI,KAAK,GAAG,IAAI,CAAC,MAAM,CAAC,GAAG,CAAC,MAAM,CAAC,CAAA;QACnC,IAAI,CAAC,KAAK,EAAE;YACV,KAAK,GAAG,IAAI,GAAG,EAAmD,CAAA;YAClE,IAAI,CAAC,MAAM,CAAC,GAAG,CAAC,MAAM,EAAE,KAAK,CAAC,CAAA;SAC/B;QACD,OAAO,KAAK,CAAC,GAAG,CAAC,KAAK,EAAE,MAAM,CAAC,CAAA;IACjC,CAAC;IAiDO,aAAa,CAAC,KAA4B;QAChD,IAAI,KAAK,YAAY,mBAAQ,EAAE;YAC7B,OAAO,KAAK,CAAA;SACb;QAED,OAAO,IAAI,CAAC,QAAQ,CAAC,KAAK,CAAC,CAAA;IAC7B,CAAC;CACF;AA5xBD,wCA4xBC","sourcesContent":["import { debugLog } from \"./debug\"\nimport { QuickJSDeferredPromise } from \"./deferred-promise\"\nimport type { EitherModule } from \"./emscripten-types\"\nimport { QuickJSUnwrapError } from \"./errors\"\nimport {\n EvalDetectModule,\n EvalFlags,\n JSBorrowedCharPointer,\n JSContextPointer,\n JSModuleDefPointer,\n JSRuntimePointer,\n JSValueConstPointer,\n JSValuePointer,\n JSValuePointerPointer,\n JSVoidPointer,\n} from \"./types-ffi\"\nimport { Disposable, Lifetime, Scope, StaticLifetime, WeakLifetime } from \"./lifetime\"\nimport { ModuleMemory } from \"./memory\"\nimport { ContextCallbacks, QuickJSModuleCallbacks } from \"./module\"\nimport { QuickJSRuntime } from \"./runtime\"\nimport {\n ContextEvalOptions,\n EitherFFI,\n evalOptionsToFlags,\n JSValue,\n PromiseExecutor,\n QuickJSHandle,\n} from \"./types\"\nimport {\n LowLevelJavascriptVm,\n SuccessOrFail,\n VmCallResult,\n VmFunctionImplementation,\n VmPropertyDescriptor,\n} from \"./vm-interface\"\n\n/**\n * Property key for getting or setting a property on a handle with\n * [[QuickJSContext.getProp]], [[QuickJSContext.setProp]], or [[QuickJSContext.defineProp]].\n */\nexport type QuickJSPropertyKey = number | string | QuickJSHandle\n\n/**\n * @private\n */\nclass ContextMemory extends ModuleMemory implements Disposable {\n readonly owner: QuickJSRuntime\n readonly ctx: Lifetime\n readonly rt: Lifetime\n readonly module: EitherModule\n readonly ffi: EitherFFI\n readonly scope = new Scope()\n\n /** @private */\n constructor(args: {\n owner: QuickJSRuntime\n module: EitherModule\n ffi: EitherFFI\n ctx: Lifetime\n rt: Lifetime\n ownedLifetimes?: Disposable[]\n }) {\n super(args.module)\n args.ownedLifetimes?.forEach((lifetime) => this.scope.manage(lifetime))\n this.owner = args.owner\n this.module = args.module\n this.ffi = args.ffi\n this.rt = args.rt\n this.ctx = this.scope.manage(args.ctx)\n }\n\n get alive() {\n return this.scope.alive\n }\n\n dispose() {\n return this.scope.dispose()\n }\n\n /**\n * Track `lifetime` so that it is disposed when this scope is disposed.\n */\n manage(lifetime: T): T {\n return this.scope.manage(lifetime)\n }\n\n copyJSValue = (ptr: JSValuePointer | JSValueConstPointer) => {\n return this.ffi.QTS_DupValuePointer(this.ctx.value, ptr)\n }\n\n freeJSValue = (ptr: JSValuePointer) => {\n this.ffi.QTS_FreeValuePointer(this.ctx.value, ptr)\n }\n\n consumeJSCharPointer(ptr: JSBorrowedCharPointer): string {\n const str = this.module.UTF8ToString(ptr)\n this.ffi.QTS_FreeCString(this.ctx.value, ptr)\n return str\n }\n\n heapValueHandle(ptr: JSValuePointer): JSValue {\n return new Lifetime(ptr, this.copyJSValue, this.freeJSValue, this.owner)\n }\n}\n\n/**\n * QuickJSContext wraps a QuickJS Javascript context (JSContext*) within a\n * runtime. The contexts within the same runtime may exchange objects freely.\n * You can think of separate runtimes like different domains in a browser, and\n * the contexts within a runtime like the different windows open to the same\n * domain. The {@link runtime} references the context's runtime.\n *\n * This class's methods return {@link QuickJSHandle}, which wrap C pointers (JSValue*).\n * It's the caller's responsibility to call `.dispose()` on any\n * handles you create to free memory once you're done with the handle.\n *\n * Use {@link QuickJSRuntime.newContext} or {@link QuickJSWASMModule.newContext}\n * to create a new QuickJSContext.\n *\n * Create QuickJS values inside the interpreter with methods like\n * [[newNumber]], [[newString]], [[newArray]], [[newObject]],\n * [[newFunction]], and [[newPromise]].\n *\n * Call [[setProp]] or [[defineProp]] to customize objects. Use those methods\n * with [[global]] to expose the values you create to the interior of the\n * interpreter, so they can be used in [[evalCode]].\n *\n * Use [[evalCode]] or [[callFunction]] to execute Javascript inside the VM. If\n * you're using asynchronous code inside the QuickJSContext, you may need to also\n * call [[executePendingJobs]]. Executing code inside the runtime returns a\n * result object representing successful execution or an error. You must dispose\n * of any such results to avoid leaking memory inside the VM.\n *\n * Implement memory and CPU constraints at the runtime level, using [[runtime]].\n * See {@link QuickJSRuntime} for more information.\n *\n */\n// TODO: Manage own callback registration\nexport class QuickJSContext implements LowLevelJavascriptVm, Disposable {\n /**\n * The runtime that created this context.\n */\n public readonly runtime: QuickJSRuntime\n\n /** @private */\n protected readonly ctx: Lifetime\n /** @private */\n protected readonly rt: Lifetime\n /** @private */\n protected readonly module: EitherModule\n /** @private */\n protected readonly ffi: EitherFFI\n /** @private */\n protected memory: ContextMemory\n\n /** @private */\n protected _undefined: QuickJSHandle | undefined = undefined\n /** @private */\n protected _null: QuickJSHandle | undefined = undefined\n /** @private */\n protected _false: QuickJSHandle | undefined = undefined\n /** @private */\n protected _true: QuickJSHandle | undefined = undefined\n /** @private */\n protected _global: QuickJSHandle | undefined = undefined\n /** @private */\n protected _BigInt: QuickJSHandle | undefined = undefined\n\n /**\n * Use {@link QuickJS.createVm} to create a QuickJSContext instance.\n */\n constructor(args: {\n module: EitherModule\n ffi: EitherFFI\n ctx: Lifetime\n rt: Lifetime\n runtime: QuickJSRuntime\n ownedLifetimes?: Disposable[]\n callbacks: QuickJSModuleCallbacks\n }) {\n this.runtime = args.runtime\n this.module = args.module\n this.ffi = args.ffi\n this.rt = args.rt\n this.ctx = args.ctx\n this.memory = new ContextMemory({\n ...args,\n owner: this.runtime,\n })\n args.callbacks.setContextCallbacks(this.ctx.value, this.cToHostCallbacks)\n this.dump = this.dump.bind(this)\n this.getString = this.getString.bind(this)\n this.getNumber = this.getNumber.bind(this)\n this.resolvePromise = this.resolvePromise.bind(this)\n }\n\n // @implement Disposable ----------------------------------------------------\n\n get alive() {\n return this.memory.alive\n }\n\n /**\n * Dispose of this VM's underlying resources.\n *\n * @throws Calling this method without disposing of all created handles\n * will result in an error.\n */\n dispose() {\n this.memory.dispose()\n }\n\n // Globals ------------------------------------------------------------------\n\n /**\n * [`undefined`](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/undefined).\n */\n get undefined(): QuickJSHandle {\n if (this._undefined) {\n return this._undefined\n }\n\n // Undefined is a constant, immutable value in QuickJS.\n const ptr = this.ffi.QTS_GetUndefined()\n return (this._undefined = new StaticLifetime(ptr))\n }\n\n /**\n * [`null`](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/null).\n */\n get null(): QuickJSHandle {\n if (this._null) {\n return this._null\n }\n\n // Null is a constant, immutable value in QuickJS.\n const ptr = this.ffi.QTS_GetNull()\n return (this._null = new StaticLifetime(ptr))\n }\n\n /**\n * [`true`](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/true).\n */\n get true(): QuickJSHandle {\n if (this._true) {\n return this._true\n }\n\n // True is a constant, immutable value in QuickJS.\n const ptr = this.ffi.QTS_GetTrue()\n return (this._true = new StaticLifetime(ptr))\n }\n\n /**\n * [`false`](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/false).\n */\n get false(): QuickJSHandle {\n if (this._false) {\n return this._false\n }\n\n // False is a constant, immutable value in QuickJS.\n const ptr = this.ffi.QTS_GetFalse()\n return (this._false = new StaticLifetime(ptr))\n }\n\n /**\n * [`global`](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects).\n * A handle to the global object inside the interpreter.\n * You can set properties to create global variables.\n */\n get global(): QuickJSHandle {\n if (this._global) {\n return this._global\n }\n\n // The global is a JSValue, but since it's lifetime is as long as the VM's,\n // we should manage it.\n const ptr = this.ffi.QTS_GetGlobalObject(this.ctx.value)\n\n // Automatically clean up this reference when we dispose\n this.memory.manage(this.memory.heapValueHandle(ptr))\n\n // This isn't technically a static lifetime, but since it has the same\n // lifetime as the VM, it's okay to fake one since when the VM is\n // disposed, no other functions will accept the value.\n this._global = new StaticLifetime(ptr, this.runtime)\n return this._global\n }\n\n // New values ---------------------------------------------------------------\n\n /**\n * Converts a Javascript number into a QuickJS value.\n */\n newNumber(num: number): QuickJSHandle {\n return this.memory.heapValueHandle(this.ffi.QTS_NewFloat64(this.ctx.value, num))\n }\n\n /**\n * Create a QuickJS [string](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/String) value.\n */\n newString(str: string): QuickJSHandle {\n const ptr = this.memory\n .newHeapCharPointer(str)\n .consume((charHandle) => this.ffi.QTS_NewString(this.ctx.value, charHandle.value))\n return this.memory.heapValueHandle(ptr)\n }\n\n /**\n * Create a QuickJS [symbol](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Symbol) value.\n * No two symbols created with this function will be the same value.\n */\n newUniqueSymbol(description: string | symbol): QuickJSHandle {\n const key = (typeof description === \"symbol\" ? description.description : description) ?? \"\"\n const ptr = this.memory\n .newHeapCharPointer(key)\n .consume((charHandle) => this.ffi.QTS_NewSymbol(this.ctx.value, charHandle.value, 0))\n return this.memory.heapValueHandle(ptr)\n }\n\n /**\n * Get a symbol from the [global registry](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Symbol#shared_symbols_in_the_global_symbol_registry) for the given key.\n * All symbols created with the same key will be the same value.\n */\n newSymbolFor(key: string | symbol): QuickJSHandle {\n const description = (typeof key === \"symbol\" ? key.description : key) ?? \"\"\n const ptr = this.memory\n .newHeapCharPointer(description)\n .consume((charHandle) => this.ffi.QTS_NewSymbol(this.ctx.value, charHandle.value, 1))\n return this.memory.heapValueHandle(ptr)\n }\n\n /**\n * Create a QuickJS [bigint](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/BigInt) value.\n */\n newBigInt(num: bigint): QuickJSHandle {\n if (!this._BigInt) {\n const bigIntHandle = this.getProp(this.global, \"BigInt\")\n this.memory.manage(bigIntHandle)\n this._BigInt = new StaticLifetime(bigIntHandle.value as JSValueConstPointer, this.runtime)\n }\n\n const bigIntHandle = this._BigInt\n const asString = String(num)\n return this.newString(asString).consume((handle) =>\n this.unwrapResult(this.callFunction(bigIntHandle, this.undefined, handle))\n )\n }\n\n /**\n * `{}`.\n * Create a new QuickJS [object](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Operators/Object_initializer).\n *\n * @param prototype - Like [`Object.create`](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/create).\n */\n newObject(prototype?: QuickJSHandle): QuickJSHandle {\n if (prototype) {\n this.runtime.assertOwned(prototype)\n }\n const ptr = prototype\n ? this.ffi.QTS_NewObjectProto(this.ctx.value, prototype.value)\n : this.ffi.QTS_NewObject(this.ctx.value)\n return this.memory.heapValueHandle(ptr)\n }\n\n /**\n * `[]`.\n * Create a new QuickJS [array](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array).\n */\n newArray(): QuickJSHandle {\n const ptr = this.ffi.QTS_NewArray(this.ctx.value)\n return this.memory.heapValueHandle(ptr)\n }\n\n /**\n * Create a new [[QuickJSDeferredPromise]]. Use `deferred.resolve(handle)` and\n * `deferred.reject(handle)` to fulfill the promise handle available at `deferred.handle`.\n * Note that you are responsible for calling `deferred.dispose()` to free the underlying\n * resources; see the documentation on [[QuickJSDeferredPromise]] for details.\n */\n newPromise(): QuickJSDeferredPromise\n /**\n * Create a new [[QuickJSDeferredPromise]] that resolves when the\n * given native Promise