diff --git a/node_modules/@duckduckgo/content-scope-scripts/build/android/autofillPasswordImport.js b/node_modules/@duckduckgo/content-scope-scripts/build/android/autofillPasswordImport.js index 6eecceb4c35f..d9b8b718499f 100644 --- a/node_modules/@duckduckgo/content-scope-scripts/build/android/autofillPasswordImport.js +++ b/node_modules/@duckduckgo/content-scope-scripts/build/android/autofillPasswordImport.js @@ -11,6 +11,7 @@ var __privateGet = (obj, member, getter) => (__accessCheck(obj, member, "read from private field"), getter ? getter.call(obj) : member.get(obj)); var __privateAdd = (obj, member, value) => member.has(obj) ? __typeError("Cannot add the same private member more than once") : member instanceof WeakSet ? member.add(obj) : member.set(obj, value); var __privateSet = (obj, member, value, setter) => (__accessCheck(obj, member, "write to private field"), setter ? setter.call(obj, value) : member.set(obj, value), value); + var __privateMethod = (obj, member, method) => (__accessCheck(obj, member, "access private method"), method); // var define_import_meta_trackerLookup_default = { org: { cdn77: { rsc: { "1558334541": 1 } }, adsrvr: 1, ampproject: 1, "browser-update": 1, flowplayer: 1, "privacy-center": 1, webvisor: 1, framasoft: 1, "do-not-tracker": 1, trackersimulator: 1 }, io: { "1dmp": 1, "1rx": 1, "4dex": 1, adnami: 1, aidata: 1, arcspire: 1, bidr: 1, branch: 1, center: 1, cloudimg: 1, concert: 1, connectad: 1, cordial: 1, dcmn: 1, extole: 1, getblue: 1, hbrd: 1, instana: 1, karte: 1, leadsmonitor: 1, litix: 1, lytics: 1, marchex: 1, mediago: 1, mrf: 1, narrative: 1, ntv: 1, optad360: 1, oracleinfinity: 1, oribi: 1, "p-n": 1, personalizer: 1, pghub: 1, piano: 1, powr: 1, pzz: 1, searchspring: 1, segment: 1, siteimproveanalytics: 1, sspinc: 1, t13: 1, webgains: 1, wovn: 1, yellowblue: 1, zprk: 1, axept: 1, akstat: 1, clarium: 1, hotjar: 1 }, com: { "2020mustang": 1, "33across": 1, "360yield": 1, "3lift": 1, "4dsply": 1, "4strokemedia": 1, "8353e36c2a": 1, "a-mx": 1, a2z: 1, aamsitecertifier: 1, absorbingband: 1, abstractedauthority: 1, abtasty: 1, acexedge: 1, acidpigs: 1, acsbapp: 1, acuityplatform: 1, "ad-score": 1, "ad-stir": 1, adalyser: 1, adapf: 1, adara: 1, adblade: 1, addthis: 1, addtoany: 1, adelixir: 1, adentifi: 1, adextrem: 1, adgrx: 1, adhese: 1, adition: 1, adkernel: 1, adlightning: 1, adlooxtracking: 1, admanmedia: 1, admedo: 1, adnium: 1, "adnxs-simple": 1, adnxs: 1, adobedtm: 1, adotmob: 1, adpone: 1, adpushup: 1, adroll: 1, adrta: 1, "ads-twitter": 1, "ads3-adnow": 1, adsafeprotected: 1, adstanding: 1, adswizz: 1, adtdp: 1, adtechus: 1, adtelligent: 1, adthrive: 1, adtlgc: 1, adtng: 1, adultfriendfinder: 1, advangelists: 1, adventive: 1, adventori: 1, advertising: 1, aegpresents: 1, affinity: 1, affirm: 1, agilone: 1, agkn: 1, aimbase: 1, albacross: 1, alcmpn: 1, alexametrics: 1, alicdn: 1, alikeaddition: 1, aliveachiever: 1, aliyuncs: 1, alluringbucket: 1, aloofvest: 1, "amazon-adsystem": 1, amazon: 1, ambiguousafternoon: 1, amplitude: 1, "analytics-egain": 1, aniview: 1, annoyedairport: 1, annoyingclover: 1, anyclip: 1, anymind360: 1, "app-us1": 1, appboycdn: 1, appdynamics: 1, appsflyer: 1, aralego: 1, aspiringattempt: 1, aswpsdkus: 1, atemda: 1, att: 1, attentivemobile: 1, attractionbanana: 1, audioeye: 1, audrte: 1, automaticside: 1, avanser: 1, avmws: 1, aweber: 1, aweprt: 1, azure: 1, b0e8: 1, badgevolcano: 1, bagbeam: 1, ballsbanana: 1, bandborder: 1, batch: 1, bawdybalance: 1, bc0a: 1, bdstatic: 1, bedsberry: 1, beginnerpancake: 1, benchmarkemail: 1, betweendigital: 1, bfmio: 1, bidtheatre: 1, billowybelief: 1, bimbolive: 1, bing: 1, bizographics: 1, bizrate: 1, bkrtx: 1, blismedia: 1, blogherads: 1, bluecava: 1, bluekai: 1, blushingbread: 1, boatwizard: 1, boilingcredit: 1, boldchat: 1, booking: 1, borderfree: 1, bounceexchange: 1, brainlyads: 1, "brand-display": 1, brandmetrics: 1, brealtime: 1, brightfunnel: 1, brightspotcdn: 1, btloader: 1, btstatic: 1, bttrack: 1, btttag: 1, bumlam: 1, butterbulb: 1, buttonladybug: 1, buzzfeed: 1, buzzoola: 1, byside: 1, c3tag: 1, cabnnr: 1, calculatorstatement: 1, callrail: 1, calltracks: 1, capablecup: 1, "captcha-delivery": 1, carpentercomparison: 1, cartstack: 1, carvecakes: 1, casalemedia: 1, cattlecommittee: 1, cdninstagram: 1, cdnwidget: 1, channeladvisor: 1, chargecracker: 1, chartbeat: 1, chatango: 1, chaturbate: 1, cheqzone: 1, cherriescare: 1, chickensstation: 1, childlikecrowd: 1, childlikeform: 1, chocolateplatform: 1, cintnetworks: 1, circlelevel: 1, "ck-ie": 1, clcktrax: 1, cleanhaircut: 1, clearbit: 1, clearbitjs: 1, clickagy: 1, clickcease: 1, clickcertain: 1, clicktripz: 1, clientgear: 1, cloudflare: 1, cloudflareinsights: 1, cloudflarestream: 1, cobaltgroup: 1, cobrowser: 1, cognitivlabs: 1, colossusssp: 1, combativecar: 1, comm100: 1, googleapis: { commondatastorage: 1, imasdk: 1, storage: 1, fonts: 1, maps: 1, www: 1 }, "company-target": 1, condenastdigital: 1, confusedcart: 1, connatix: 1, contextweb: 1, conversionruler: 1, convertkit: 1, convertlanguage: 1, cootlogix: 1, coveo: 1, cpmstar: 1, cquotient: 1, crabbychin: 1, cratecamera: 1, crazyegg: 1, "creative-serving": 1, creativecdn: 1, criteo: 1, crowdedmass: 1, crowdriff: 1, crownpeak: 1, crsspxl: 1, ctnsnet: 1, cudasvc: 1, cuddlethehyena: 1, cumbersomecarpenter: 1, curalate: 1, curvedhoney: 1, cushiondrum: 1, cutechin: 1, cxense: 1, d28dc30335: 1, dailymotion: 1, damdoor: 1, dampdock: 1, dapperfloor: 1, "datadoghq-browser-agent": 1, decisivebase: 1, deepintent: 1, defybrick: 1, delivra: 1, demandbase: 1, detectdiscovery: 1, devilishdinner: 1, dimelochat: 1, disagreeabledrop: 1, discreetfield: 1, disqus: 1, dmpxs: 1, dockdigestion: 1, dotomi: 1, doubleverify: 1, drainpaste: 1, dramaticdirection: 1, driftt: 1, dtscdn: 1, dtscout: 1, dwin1: 1, dynamics: 1, dynamicyield: 1, dynatrace: 1, ebaystatic: 1, ecal: 1, eccmp: 1, elfsight: 1, elitrack: 1, eloqua: 1, en25: 1, encouragingthread: 1, enormousearth: 1, ensighten: 1, enviousshape: 1, eqads: 1, "ero-advertising": 1, esputnik: 1, evergage: 1, evgnet: 1, exdynsrv: 1, exelator: 1, exoclick: 1, exosrv: 1, expansioneggnog: 1, expedia: 1, expertrec: 1, exponea: 1, exponential: 1, extole: 1, ezodn: 1, ezoic: 1, ezoiccdn: 1, facebook: 1, "facil-iti": 1, fadewaves: 1, fallaciousfifth: 1, farmergoldfish: 1, "fastly-insights": 1, fearlessfaucet: 1, fiftyt: 1, financefear: 1, fitanalytics: 1, five9: 1, fixedfold: 1, fksnk: 1, flashtalking: 1, flipp: 1, flowerstreatment: 1, floweryflavor: 1, flutteringfireman: 1, "flux-cdn": 1, foresee: 1, fortunatemark: 1, fouanalytics: 1, fox: 1, fqtag: 1, frailfruit: 1, freezingbuilding: 1, fronttoad: 1, fullstory: 1, functionalfeather: 1, fuzzybasketball: 1, gammamaximum: 1, gbqofs: 1, geetest: 1, geistm: 1, geniusmonkey: 1, "geoip-js": 1, getbread: 1, getcandid: 1, getclicky: 1, getdrip: 1, getelevar: 1, getrockerbox: 1, getshogun: 1, getsitecontrol: 1, giraffepiano: 1, glassdoor: 1, gloriousbeef: 1, godpvqnszo: 1, "google-analytics": 1, google: 1, googleadservices: 1, googlehosted: 1, googleoptimize: 1, googlesyndication: 1, googletagmanager: 1, googletagservices: 1, gorgeousedge: 1, govx: 1, grainmass: 1, greasysquare: 1, greylabeldelivery: 1, groovehq: 1, growsumo: 1, gstatic: 1, "guarantee-cdn": 1, guiltlessbasketball: 1, gumgum: 1, haltingbadge: 1, hammerhearing: 1, handsomelyhealth: 1, harborcaption: 1, hawksearch: 1, amazonaws: { "us-east-2": { s3: { "hb-obv2": 1 } } }, heapanalytics: 1, hellobar: 1, hhbypdoecp: 1, hiconversion: 1, highwebmedia: 1, histats: 1, hlserve: 1, hocgeese: 1, hollowafterthought: 1, honorableland: 1, hotjar: 1, hp: 1, "hs-banner": 1, htlbid: 1, htplayground: 1, hubspot: 1, "ib-ibi": 1, "id5-sync": 1, igodigital: 1, iheart: 1, iljmp: 1, illiweb: 1, impactcdn: 1, "impactradius-event": 1, impressionmonster: 1, improvedcontactform: 1, improvedigital: 1, imrworldwide: 1, indexww: 1, infolinks: 1, infusionsoft: 1, inmobi: 1, inq: 1, "inside-graph": 1, instagram: 1, intentiq: 1, intergient: 1, investingchannel: 1, invocacdn: 1, iperceptions: 1, iplsc: 1, ipredictive: 1, iteratehq: 1, ivitrack: 1, j93557g: 1, jaavnacsdw: 1, jimstatic: 1, journity: 1, js7k: 1, jscache: 1, juiceadv: 1, juicyads: 1, justanswer: 1, justpremium: 1, jwpcdn: 1, kakao: 1, kampyle: 1, kargo: 1, kissmetrics: 1, klarnaservices: 1, klaviyo: 1, knottyswing: 1, krushmedia: 1, ktkjmp: 1, kxcdn: 1, laboredlocket: 1, ladesk: 1, ladsp: 1, laughablelizards: 1, leadsrx: 1, lendingtree: 1, levexis: 1, liadm: 1, licdn: 1, lightboxcdn: 1, lijit: 1, linkedin: 1, linksynergy: 1, "list-manage": 1, listrakbi: 1, livechatinc: 1, livejasmin: 1, localytics: 1, loggly: 1, loop11: 1, looseloaf: 1, lovelydrum: 1, lunchroomlock: 1, lwonclbench: 1, macromill: 1, maddeningpowder: 1, mailchimp: 1, mailchimpapp: 1, mailerlite: 1, "maillist-manage": 1, marinsm: 1, marketiq: 1, marketo: 1, marphezis: 1, marriedbelief: 1, materialparcel: 1, matheranalytics: 1, mathtag: 1, maxmind: 1, mczbf: 1, measlymiddle: 1, medallia: 1, meddleplant: 1, media6degrees: 1, mediacategory: 1, mediavine: 1, mediawallahscript: 1, medtargetsystem: 1, megpxs: 1, memberful: 1, memorizematch: 1, mentorsticks: 1, metaffiliation: 1, metricode: 1, metricswpsh: 1, mfadsrvr: 1, mgid: 1, micpn: 1, microadinc: 1, "minutemedia-prebid": 1, minutemediaservices: 1, mixpo: 1, mkt932: 1, mktoresp: 1, mktoweb: 1, ml314: 1, moatads: 1, mobtrakk: 1, monsido: 1, mookie1: 1, motionflowers: 1, mountain: 1, mouseflow: 1, mpeasylink: 1, mql5: 1, mrtnsvr: 1, murdoog: 1, mxpnl: 1, mybestpro: 1, myregistry: 1, nappyattack: 1, navistechnologies: 1, neodatagroup: 1, nervoussummer: 1, netmng: 1, newrelic: 1, newscgp: 1, nextdoor: 1, ninthdecimal: 1, nitropay: 1, noibu: 1, nondescriptnote: 1, nosto: 1, npttech: 1, ntvpwpush: 1, nuance: 1, nutritiousbean: 1, nxsttv: 1, omappapi: 1, omnisnippet1: 1, omnisrc: 1, omnitagjs: 1, ondemand: 1, oneall: 1, onesignal: 1, "onetag-sys": 1, "oo-syringe": 1, ooyala: 1, opecloud: 1, opentext: 1, opera: 1, opmnstr: 1, "opti-digital": 1, optimicdn: 1, optimizely: 1, optinmonster: 1, optmnstr: 1, optmstr: 1, optnmnstr: 1, optnmstr: 1, osano: 1, "otm-r": 1, outbrain: 1, overconfidentfood: 1, ownlocal: 1, pailpatch: 1, panickypancake: 1, panoramicplane: 1, parastorage: 1, pardot: 1, parsely: 1, partplanes: 1, patreon: 1, paypal: 1, pbstck: 1, pcmag: 1, peerius: 1, perfdrive: 1, perfectmarket: 1, permutive: 1, picreel: 1, pinterest: 1, pippio: 1, piwikpro: 1, pixlee: 1, placidperson: 1, pleasantpump: 1, plotrabbit: 1, pluckypocket: 1, pocketfaucet: 1, possibleboats: 1, postaffiliatepro: 1, postrelease: 1, potatoinvention: 1, powerfulcopper: 1, predictplate: 1, prepareplanes: 1, pricespider: 1, priceypies: 1, pricklydebt: 1, profusesupport: 1, proofpoint: 1, protoawe: 1, providesupport: 1, pswec: 1, psychedelicarithmetic: 1, psyma: 1, ptengine: 1, publir: 1, pubmatic: 1, pubmine: 1, pubnation: 1, qualaroo: 1, qualtrics: 1, quantcast: 1, quantserve: 1, quantummetric: 1, quietknowledge: 1, quizzicalpartner: 1, quizzicalzephyr: 1, quora: 1, r42tag: 1, radiateprose: 1, railwayreason: 1, rakuten: 1, rambunctiousflock: 1, rangeplayground: 1, "rating-widget": 1, realsrv: 1, rebelswing: 1, reconditerake: 1, reconditerespect: 1, recruitics: 1, reddit: 1, redditstatic: 1, rehabilitatereason: 1, repeatsweater: 1, reson8: 1, resonantrock: 1, resonate: 1, responsiveads: 1, restrainstorm: 1, restructureinvention: 1, retargetly: 1, revcontent: 1, rezync: 1, rfihub: 1, rhetoricalloss: 1, richaudience: 1, righteouscrayon: 1, rightfulfall: 1, riotgames: 1, riskified: 1, rkdms: 1, rlcdn: 1, rmtag: 1, rogersmedia: 1, rokt: 1, route: 1, rtbsystem: 1, rubiconproject: 1, ruralrobin: 1, "s-onetag": 1, saambaa: 1, sablesong: 1, "sail-horizon": 1, salesforceliveagent: 1, samestretch: 1, sascdn: 1, satisfycork: 1, savoryorange: 1, scarabresearch: 1, scaredsnakes: 1, scaredsong: 1, scaredstomach: 1, scarfsmash: 1, scene7: 1, scholarlyiq: 1, scintillatingsilver: 1, scorecardresearch: 1, screechingstove: 1, screenpopper: 1, scribblestring: 1, sddan: 1, seatsmoke: 1, securedvisit: 1, seedtag: 1, sefsdvc: 1, segment: 1, sekindo: 1, selectivesummer: 1, selfishsnake: 1, servebom: 1, servedbyadbutler: 1, servenobid: 1, serverbid: 1, "serving-sys": 1, shakegoldfish: 1, shamerain: 1, shapecomb: 1, shappify: 1, shareaholic: 1, sharethis: 1, sharethrough: 1, shopifyapps: 1, shopperapproved: 1, shrillspoon: 1, sibautomation: 1, sicksmash: 1, signifyd: 1, singroot: 1, site: 1, siteimprove: 1, siteimproveanalytics: 1, sitescout: 1, sixauthority: 1, skillfuldrop: 1, skimresources: 1, skisofa: 1, "sli-spark": 1, slickstream: 1, slopesoap: 1, smadex: 1, smartadserver: 1, smashquartz: 1, smashsurprise: 1, smg: 1, smilewanted: 1, smoggysnakes: 1, snapchat: 1, snapkit: 1, snigelweb: 1, socdm: 1, sojern: 1, songsterritory: 1, sonobi: 1, soundstocking: 1, spectacularstamp: 1, speedcurve: 1, sphereup: 1, spiceworks: 1, spookyexchange: 1, spookyskate: 1, spookysleet: 1, sportradarserving: 1, sportslocalmedia: 1, spotxchange: 1, springserve: 1, srvmath: 1, "ssl-images-amazon": 1, stackadapt: 1, stakingsmile: 1, statcounter: 1, steadfastseat: 1, steadfastsound: 1, steadfastsystem: 1, steelhousemedia: 1, steepsquirrel: 1, stereotypedsugar: 1, stickyadstv: 1, stiffgame: 1, stingycrush: 1, straightnest: 1, stripchat: 1, strivesquirrel: 1, strokesystem: 1, stupendoussleet: 1, stupendoussnow: 1, stupidscene: 1, sulkycook: 1, sumo: 1, sumologic: 1, sundaysky: 1, superficialeyes: 1, superficialsquare: 1, surveymonkey: 1, survicate: 1, svonm: 1, swankysquare: 1, symantec: 1, taboola: 1, tailtarget: 1, talkable: 1, tamgrt: 1, tangycover: 1, taobao: 1, tapad: 1, tapioni: 1, taptapnetworks: 1, taskanalytics: 1, tealiumiq: 1, "techlab-cdn": 1, technoratimedia: 1, techtarget: 1, tediousticket: 1, teenytinyshirt: 1, tendertest: 1, "the-ozone-project": 1, theadex: 1, themoneytizer: 1, theplatform: 1, thestar: 1, thinkitten: 1, threetruck: 1, thrtle: 1, tidaltv: 1, tidiochat: 1, tiktok: 1, tinypass: 1, tiqcdn: 1, tiresomethunder: 1, trackjs: 1, traffichaus: 1, trafficjunky: 1, trafmag: 1, travelaudience: 1, treasuredata: 1, tremorhub: 1, trendemon: 1, tribalfusion: 1, trovit: 1, trueleadid: 1, truoptik: 1, truste: 1, trustpilot: 1, trvdp: 1, tsyndicate: 1, tubemogul: 1, turn: 1, tvpixel: 1, tvsquared: 1, tweakwise: 1, twitter: 1, tynt: 1, typicalteeth: 1, u5e: 1, ubembed: 1, uidapi: 1, ultraoranges: 1, unbecominglamp: 1, unbxdapi: 1, undertone: 1, uninterestedquarter: 1, unpkg: 1, unrulymedia: 1, unwieldyhealth: 1, unwieldyplastic: 1, upsellit: 1, urbanairship: 1, usabilla: 1, usbrowserspeed: 1, usemessages: 1, userreport: 1, uservoice: 1, valuecommerce: 1, vengefulgrass: 1, vidazoo: 1, videoplayerhub: 1, vidoomy: 1, viglink: 1, visualwebsiteoptimizer: 1, vivaclix: 1, vk: 1, vlitag: 1, voicefive: 1, volatilevessel: 1, voraciousgrip: 1, voxmedia: 1, vrtcal: 1, w3counter: 1, walkme: 1, warmafterthought: 1, warmquiver: 1, webcontentassessor: 1, webengage: 1, webeyez: 1, webtraxs: 1, "webtrends-optimize": 1, webtrends: 1, wgplayer: 1, woosmap: 1, worldoftulo: 1, wpadmngr: 1, wpshsdk: 1, wpushsdk: 1, wsod: 1, "wt-safetag": 1, wysistat: 1, xg4ken: 1, xiti: 1, xlirdr: 1, xlivrdr: 1, "xnxx-cdn": 1, "y-track": 1, yahoo: 1, yandex: 1, yieldmo: 1, yieldoptimizer: 1, yimg: 1, yotpo: 1, yottaa: 1, "youtube-nocookie": 1, youtube: 1, zemanta: 1, zendesk: 1, zeotap: 1, zestycrime: 1, zonos: 1, zoominfo: 1, zopim: 1, createsend1: 1, veoxa: 1, parchedsofa: 1, sooqr: 1, adtraction: 1, addthisedge: 1, adsymptotic: 1, bootstrapcdn: 1, bugsnag: 1, dmxleo: 1, dtssrv: 1, fontawesome: 1, "hs-scripts": 1, jwpltx: 1, nereserv: 1, onaudience: 1, outbrainimg: 1, quantcount: 1, rtactivate: 1, shopifysvc: 1, stripe: 1, twimg: 1, vimeo: 1, vimeocdn: 1, wp: 1, "2znp09oa": 1, "4jnzhl0d0": 1, "6ldu6qa": 1, "82o9v830": 1, abilityscale: 1, aboardamusement: 1, aboardlevel: 1, abovechat: 1, abruptroad: 1, absentairport: 1, absorbingcorn: 1, absorbingprison: 1, abstractedamount: 1, absurdapple: 1, abundantcoin: 1, acceptableauthority: 1, accurateanimal: 1, accuratecoal: 1, achieverknee: 1, acidicstraw: 1, acridangle: 1, acridtwist: 1, actoramusement: 1, actuallysheep: 1, actuallysnake: 1, actuallything: 1, adamantsnail: 1, addictedattention: 1, adorableanger: 1, adorableattention: 1, adventurousamount: 1, afraidlanguage: 1, aftermathbrother: 1, agilebreeze: 1, agreeablearch: 1, agreeabletouch: 1, aheadday: 1, aheadgrow: 1, aheadmachine: 1, ak0gsh40: 1, alertarithmetic: 1, aliasanvil: 1, alleythecat: 1, aloofmetal: 1, alpineactor: 1, ambientdusk: 1, ambientlagoon: 1, ambiguousanger: 1, ambiguousdinosaurs: 1, ambiguousincome: 1, ambrosialsummit: 1, amethystzenith: 1, amuckafternoon: 1, amusedbucket: 1, analogwonder: 1, analyzecorona: 1, ancientact: 1, annoyingacoustics: 1, anxiousapples: 1, aquaticowl: 1, ar1nvz5: 1, archswimming: 1, aromamirror: 1, arrivegrowth: 1, artthevoid: 1, aspiringapples: 1, aspiringtoy: 1, astonishingfood: 1, astralhustle: 1, astrallullaby: 1, attendchase: 1, attractivecap: 1, audioarctic: 1, automaticturkey: 1, availablerest: 1, avalonalbum: 1, averageactivity: 1, awarealley: 1, awesomeagreement: 1, awzbijw: 1, axiomaticalley: 1, axiomaticanger: 1, azuremystique: 1, backupcat: 1, badgeboat: 1, badgerabbit: 1, baitbaseball: 1, balloonbelieve: 1, bananabarrel: 1, barbarousbase: 1, basilfish: 1, basketballbelieve: 1, baskettexture: 1, bawdybeast: 1, beamvolcano: 1, beancontrol: 1, bearmoonlodge: 1, beetleend: 1, begintrain: 1, berserkhydrant: 1, bespokesandals: 1, bestboundary: 1, bewilderedbattle: 1, bewilderedblade: 1, bhcumsc: 1, bikepaws: 1, bikesboard: 1, billowybead: 1, binspiredtees: 1, birthdaybelief: 1, blackbrake: 1, bleachbubble: 1, bleachscarecrow: 1, bleedlight: 1, blesspizzas: 1, blissfulcrescendo: 1, blissfullagoon: 1, blueeyedblow: 1, blushingbeast: 1, boatsvest: 1, boilingbeetle: 1, boostbehavior: 1, boredcrown: 1, bouncyproperty: 1, boundarybusiness: 1, boundlessargument: 1, boundlessbrake: 1, boundlessveil: 1, brainybasin: 1, brainynut: 1, branchborder: 1, brandsfive: 1, brandybison: 1, bravebone: 1, bravecalculator: 1, breadbalance: 1, breakableinsurance: 1, breakfastboat: 1, breezygrove: 1, brianwould: 1, brighttoe: 1, briskstorm: 1, broadborder: 1, broadboundary: 1, broadcastbed: 1, broaddoor: 1, brotherslocket: 1, bruisebaseball: 1, brunchforher: 1, buildingknife: 1, bulbbait: 1, burgersalt: 1, burlywhistle: 1, burnbubble: 1, bushesbag: 1, bustlingbath: 1, bustlingbook: 1, butterburst: 1, cakesdrum: 1, calculatingcircle: 1, calculatingtoothbrush: 1, callousbrake: 1, calmcactus: 1, calypsocapsule: 1, cannonchange: 1, capablecows: 1, capriciouscorn: 1, captivatingcanyon: 1, captivatingillusion: 1, captivatingpanorama: 1, captivatingperformance: 1, carefuldolls: 1, caringcast: 1, caringzinc: 1, carloforward: 1, carscannon: 1, cartkitten: 1, catalogcake: 1, catschickens: 1, causecherry: 1, cautiouscamera: 1, cautiouscherries: 1, cautiouscrate: 1, cautiouscredit: 1, cavecurtain: 1, ceciliavenus: 1, celestialeuphony: 1, celestialquasar: 1, celestialspectra: 1, chaireggnog: 1, chairscrack: 1, chairsdonkey: 1, chalkoil: 1, changeablecats: 1, channelcamp: 1, charmingplate: 1, charscroll: 1, cheerycraze: 1, chessbranch: 1, chesscolor: 1, chesscrowd: 1, childlikeexample: 1, chilledliquid: 1, chingovernment: 1, chinsnakes: 1, chipperisle: 1, chivalrouscord: 1, chubbycreature: 1, chunkycactus: 1, cicdserver: 1, cinemabonus: 1, clammychicken: 1, cloisteredcord: 1, cloisteredcurve: 1, closedcows: 1, closefriction: 1, cloudhustles: 1, cloudjumbo: 1, clovercabbage: 1, clumsycar: 1, coatfood: 1, cobaltoverture: 1, coffeesidehustle: 1, coldbalance: 1, coldcreatives: 1, colorfulafterthought: 1, colossalclouds: 1, colossalcoat: 1, colossalcry: 1, combativedetail: 1, combbit: 1, combcattle: 1, combcompetition: 1, cometquote: 1, comfortablecheese: 1, comfygoodness: 1, companyparcel: 1, comparereaction: 1, compiledoctor: 1, concernedchange: 1, concernedchickens: 1, condemnedcomb: 1, conditionchange: 1, conditioncrush: 1, confesschairs: 1, configchain: 1, connectashelf: 1, consciouschairs: 1, consciouscheese: 1, consciousdirt: 1, consumerzero: 1, controlcola: 1, controlhall: 1, convertbatch: 1, cooingcoal: 1, coordinatedbedroom: 1, coordinatedcoat: 1, copycarpenter: 1, copyrightaccesscontrols: 1, coralreverie: 1, corgibeachday: 1, cosmicsculptor: 1, cosmosjackson: 1, courageousbaby: 1, coverapparatus: 1, coverlayer: 1, cozydusk: 1, cozyhillside: 1, cozytryst: 1, crackedsafe: 1, crafthenry: 1, crashchance: 1, craterbox: 1, creatorcherry: 1, creatorpassenger: 1, creaturecabbage: 1, crimsonmeadow: 1, critictruck: 1, crookedcreature: 1, cruisetourist: 1, cryptvalue: 1, crystalboulevard: 1, crystalstatus: 1, cubchannel: 1, cubepins: 1, cuddlycake: 1, cuddlylunchroom: 1, culturedcamera: 1, culturedfeather: 1, cumbersomecar: 1, cumbersomecloud: 1, curiouschalk: 1, curioussuccess: 1, curlycannon: 1, currentcollar: 1, curtaincows: 1, curvycord: 1, curvycry: 1, cushionpig: 1, cutcurrent: 1, cyclopsdial: 1, dailydivision: 1, damagedadvice: 1, damageddistance: 1, dancemistake: 1, dandydune: 1, dandyglow: 1, dapperdiscussion: 1, datastoried: 1, daughterstone: 1, daymodern: 1, dazzlingbook: 1, deafeningdock: 1, deafeningdowntown: 1, debonairdust: 1, debonairtree: 1, debugentity: 1, decidedrum: 1, decisivedrawer: 1, decisiveducks: 1, decoycreation: 1, deerbeginner: 1, defeatedbadge: 1, defensevest: 1, degreechariot: 1, delegatediscussion: 1, delicatecascade: 1, deliciousducks: 1, deltafault: 1, deluxecrate: 1, dependenttrip: 1, desirebucket: 1, desiredirt: 1, detailedgovernment: 1, detailedkitten: 1, detectdinner: 1, detourgame: 1, deviceseal: 1, deviceworkshop: 1, dewdroplagoon: 1, difficultfog: 1, digestiondrawer: 1, dinnerquartz: 1, diplomahawaii: 1, direfuldesk: 1, discreetquarter: 1, distributionneck: 1, distributionpocket: 1, distributiontomatoes: 1, disturbedquiet: 1, divehope: 1, dk4ywix: 1, dogsonclouds: 1, dollardelta: 1, doubledefend: 1, doubtdrawer: 1, dq95d35: 1, dreamycanyon: 1, driftpizza: 1, drollwharf: 1, drydrum: 1, dustydime: 1, dustyhammer: 1, eagereden: 1, eagerflame: 1, eagerknight: 1, earthyfarm: 1, eatablesquare: 1, echochief: 1, echoinghaven: 1, effervescentcoral: 1, effervescentvista: 1, effulgentnook: 1, effulgenttempest: 1, ejyymghi: 1, elasticchange: 1, elderlybean: 1, elderlytown: 1, elephantqueue: 1, elusivebreeze: 1, elusivecascade: 1, elysiantraverse: 1, embellishedmeadow: 1, embermosaic: 1, emberwhisper: 1, eminentbubble: 1, eminentend: 1, emptyescort: 1, enchantedskyline: 1, enchantingdiscovery: 1, enchantingenchantment: 1, enchantingmystique: 1, enchantingtundra: 1, enchantingvalley: 1, encourageshock: 1, endlesstrust: 1, endurablebulb: 1, energeticexample: 1, energeticladybug: 1, engineergrape: 1, engineertrick: 1, enigmaticblossom: 1, enigmaticcanyon: 1, enigmaticvoyage: 1, enormousfoot: 1, enterdrama: 1, entertainskin: 1, enthusiastictemper: 1, enviousthread: 1, equablekettle: 1, etherealbamboo: 1, ethereallagoon: 1, etherealpinnacle: 1, etherealquasar: 1, etherealripple: 1, evanescentedge: 1, evasivejar: 1, eventexistence: 1, exampleshake: 1, excitingtub: 1, exclusivebrass: 1, executeknowledge: 1, exhibitsneeze: 1, exquisiteartisanship: 1, extractobservation: 1, extralocker: 1, extramonies: 1, exuberantedge: 1, facilitatebreakfast: 1, fadechildren: 1, fadedsnow: 1, fairfeeling: 1, fairiesbranch: 1, fairytaleflame: 1, falseframe: 1, familiarrod: 1, fancyactivity: 1, fancydune: 1, fancygrove: 1, fangfeeling: 1, fantastictone: 1, farethief: 1, farshake: 1, farsnails: 1, fastenfather: 1, fasterfineart: 1, fasterjson: 1, fatcoil: 1, faucetfoot: 1, faultycanvas: 1, fearfulfish: 1, fearfulmint: 1, fearlesstramp: 1, featherstage: 1, feeblestamp: 1, feignedfaucet: 1, fernwaycloud: 1, fertilefeeling: 1, fewjuice: 1, fewkittens: 1, finalizeforce: 1, finestpiece: 1, finitecube: 1, firecatfilms: 1, fireworkcamp: 1, firstendpoint: 1, firstfrogs: 1, firsttexture: 1, fitmessage: 1, fivesidedsquare: 1, flakyfeast: 1, flameuncle: 1, flimsycircle: 1, flimsythought: 1, flippedfunnel: 1, floodprincipal: 1, flourishingcollaboration: 1, flourishingendeavor: 1, flourishinginnovation: 1, flourishingpartnership: 1, flowersornament: 1, flowerycreature: 1, floweryfact: 1, floweryoperation: 1, foambench: 1, followborder: 1, forecasttiger: 1, foretellfifth: 1, forevergears: 1, forgetfulflowers: 1, forgetfulsnail: 1, fractalcoast: 1, framebanana: 1, franticroof: 1, frantictrail: 1, frazzleart: 1, freakyglass: 1, frequentflesh: 1, friendlycrayon: 1, friendlyfold: 1, friendwool: 1, frightenedpotato: 1, frogator: 1, frogtray: 1, frugalfiestas: 1, fumblingform: 1, functionalcrown: 1, funoverbored: 1, funoverflow: 1, furnstudio: 1, furryfork: 1, furryhorses: 1, futuristicapparatus: 1, futuristicfairies: 1, futuristicfifth: 1, futuristicframe: 1, fuzzyaudio: 1, fuzzyerror: 1, gardenovens: 1, gaudyairplane: 1, geekactive: 1, generalprose: 1, generateoffice: 1, giantsvessel: 1, giddycoat: 1, gitcrumbs: 1, givevacation: 1, gladglen: 1, gladysway: 1, glamhawk: 1, gleamingcow: 1, gleaminghaven: 1, glisteningguide: 1, glisteningsign: 1, glitteringbrook: 1, glowingmeadow: 1, gluedpixel: 1, goldfishgrowth: 1, gondolagnome: 1, goodbark: 1, gracefulmilk: 1, grandfatherguitar: 1, gravitygive: 1, gravitykick: 1, grayoranges: 1, grayreceipt: 1, greyinstrument: 1, gripcorn: 1, groovyornament: 1, grouchybrothers: 1, grouchypush: 1, grumpydime: 1, grumpydrawer: 1, guardeddirection: 1, guardedschool: 1, guessdetail: 1, guidecent: 1, guildalpha: 1, gulliblegrip: 1, gustocooking: 1, gustygrandmother: 1, habitualhumor: 1, halcyoncanyon: 1, halcyonsculpture: 1, hallowedinvention: 1, haltingdivision: 1, haltinggold: 1, handleteeth: 1, handnorth: 1, handsomehose: 1, handsomeindustry: 1, handsomelythumb: 1, handsomeyam: 1, handyfield: 1, handyfireman: 1, handyincrease: 1, haplesshydrant: 1, haplessland: 1, happysponge: 1, harborcub: 1, harmonicbamboo: 1, harmonywing: 1, hatefulrequest: 1, headydegree: 1, headyhook: 1, healflowers: 1, hearinglizards: 1, heartbreakingmind: 1, hearthorn: 1, heavydetail: 1, heavyplayground: 1, helpcollar: 1, helpflame: 1, hfc195b: 1, highfalutinbox: 1, highfalutinhoney: 1, hilariouszinc: 1, historicalbeam: 1, homelycrown: 1, honeybulb: 1, honeywhipped: 1, honorablehydrant: 1, horsenectar: 1, hospitablehall: 1, hospitablehat: 1, howdyinbox: 1, humdrumhobbies: 1, humdrumtouch: 1, hurtgrape: 1, hypnoticwound: 1, hystericalcloth: 1, hystericalfinger: 1, idolscene: 1, idyllicjazz: 1, illinvention: 1, illustriousoatmeal: 1, immensehoney: 1, imminentshake: 1, importantmeat: 1, importedincrease: 1, importedinsect: 1, importlocate: 1, impossibleexpansion: 1, impossiblemove: 1, impulsejewel: 1, impulselumber: 1, incomehippo: 1, incompetentjoke: 1, inconclusiveaction: 1, infamousstream: 1, innocentlamp: 1, innocentwax: 1, inputicicle: 1, inquisitiveice: 1, inquisitiveinvention: 1, intelligentscissors: 1, intentlens: 1, interestdust: 1, internalcondition: 1, internalsink: 1, iotapool: 1, irritatingfog: 1, itemslice: 1, ivykiosk: 1, jadeitite: 1, jaderooster: 1, jailbulb: 1, joblessdrum: 1, jollylens: 1, joyfulkeen: 1, joyoussurprise: 1, jubilantaura: 1, jubilantcanyon: 1, jubilantcascade: 1, jubilantglimmer: 1, jubilanttempest: 1, jubilantwhisper: 1, justicejudo: 1, kaputquill: 1, keenquill: 1, kindhush: 1, kitesquirrel: 1, knitstamp: 1, laboredlight: 1, lameletters: 1, lamplow: 1, largebrass: 1, lasttaco: 1, leaplunchroom: 1, leftliquid: 1, lemonpackage: 1, lemonsandjoy: 1, liftedknowledge: 1, lightenafterthought: 1, lighttalon: 1, livelumber: 1, livelylaugh: 1, livelyreward: 1, livingsleet: 1, lizardslaugh: 1, loadsurprise: 1, lonelyflavor: 1, longingtrees: 1, lorenzourban: 1, losslace: 1, loudlunch: 1, loveseashore: 1, lp3tdqle: 1, ludicrousarch: 1, lumberamount: 1, luminousboulevard: 1, luminouscatalyst: 1, luminoussculptor: 1, lumpygnome: 1, lumpylumber: 1, lustroushaven: 1, lyricshook: 1, madebyintent: 1, magicaljoin: 1, magnetairport: 1, majesticmountainrange: 1, majesticwaterscape: 1, majesticwilderness: 1, maliciousmusic: 1, managedpush: 1, mantrafox: 1, marblediscussion: 1, markahouse: 1, markedmeasure: 1, marketspiders: 1, marriedmailbox: 1, marriedvalue: 1, massivemark: 1, materialisticmoon: 1, materialmilk: 1, materialplayground: 1, meadowlullaby: 1, meatydime: 1, mediatescarf: 1, mediumshort: 1, mellowhush: 1, mellowmailbox: 1, melodiouschorus: 1, melodiouscomposition: 1, meltmilk: 1, memopilot: 1, memorizeneck: 1, meremark: 1, merequartz: 1, merryopal: 1, merryvault: 1, messagenovice: 1, messyoranges: 1, mightyspiders: 1, mimosamajor: 1, mindfulgem: 1, minorcattle: 1, minusmental: 1, minuteburst: 1, miscreantmoon: 1, mistyhorizon: 1, mittencattle: 1, mixedreading: 1, modularmental: 1, monacobeatles: 1, moorshoes: 1, motionlessbag: 1, motionlessbelief: 1, motionlessmeeting: 1, movemeal: 1, muddledaftermath: 1, muddledmemory: 1, mundanenail: 1, mundanepollution: 1, mushywaste: 1, muteknife: 1, mutemailbox: 1, mysticalagoon: 1, naivestatement: 1, nappyneck: 1, neatshade: 1, nebulacrescent: 1, nebulajubilee: 1, nebulousamusement: 1, nebulousgarden: 1, nebulousquasar: 1, nebulousripple: 1, needlessnorth: 1, needyneedle: 1, neighborlywatch: 1, niftygraphs: 1, niftyhospital: 1, niftyjelly: 1, nightwound: 1, nimbleplot: 1, nocturnalloom: 1, nocturnalmystique: 1, noiselessplough: 1, nonchalantnerve: 1, nondescriptcrowd: 1, nondescriptstocking: 1, nostalgicknot: 1, nostalgicneed: 1, notifyglass: 1, nudgeduck: 1, nullnorth: 1, numberlessring: 1, numerousnest: 1, nuttyorganization: 1, oafishchance: 1, oafishobservation: 1, obscenesidewalk: 1, observantice: 1, oldfashionedoffer: 1, omgthink: 1, omniscientfeeling: 1, onlywoofs: 1, opalquill: 1, operationchicken: 1, operationnail: 1, oppositeoperation: 1, optimallimit: 1, opulentsylvan: 1, orientedargument: 1, orionember: 1, ourblogthing: 1, outgoinggiraffe: 1, outsidevibe: 1, outstandingincome: 1, outstandingsnails: 1, overkick: 1, overratedchalk: 1, oxygenfuse: 1, pailcrime: 1, painstakingpickle: 1, paintpear: 1, paleleaf: 1, pamelarandom: 1, panickycurtain: 1, parallelbulb: 1, pardonpopular: 1, parentpicture: 1, parsimoniouspolice: 1, passivepolo: 1, pastoralroad: 1, pawsnug: 1, peacefullimit: 1, pedromister: 1, pedropanther: 1, perceivequarter: 1, perkyjade: 1, petiteumbrella: 1, philippinch: 1, photographpan: 1, piespower: 1, piquantgrove: 1, piquantmeadow: 1, piquantpigs: 1, piquantprice: 1, piquantvortex: 1, pixeledhub: 1, pizzasnut: 1, placeframe: 1, placidactivity: 1, planebasin: 1, plantdigestion: 1, playfulriver: 1, plotparent: 1, pluckyzone: 1, poeticpackage: 1, pointdigestion: 1, pointlesshour: 1, pointlesspocket: 1, pointlessprofit: 1, pointlessrifle: 1, polarismagnet: 1, polishedcrescent: 1, polishedfolly: 1, politeplanes: 1, politicalflip: 1, politicalporter: 1, popplantation: 1, possiblepencil: 1, powderjourney: 1, powerfulblends: 1, preciousplanes: 1, prefixpatriot: 1, presetrabbits: 1, previousplayground: 1, previouspotato: 1, pricklypollution: 1, pristinegale: 1, probablepartner: 1, processplantation: 1, producepickle: 1, productsurfer: 1, profitrumour: 1, promiseair: 1, proofconvert: 1, propertypotato: 1, protestcopy: 1, psychedelicchess: 1, publicsofa: 1, puffyloss: 1, puffypaste: 1, puffypull: 1, puffypurpose: 1, pulsatingmeadow: 1, pumpedpancake: 1, pumpedpurpose: 1, punyplant: 1, puppytooth: 1, purposepipe: 1, quacksquirrel: 1, quaintcan: 1, quaintlake: 1, quantumlagoon: 1, quantumshine: 1, queenskart: 1, quillkick: 1, quirkybliss: 1, quirkysugar: 1, quixoticnebula: 1, rabbitbreath: 1, rabbitrifle: 1, radiantcanopy: 1, radiantlullaby: 1, railwaygiraffe: 1, raintwig: 1, rainyhand: 1, rainyrule: 1, rangecake: 1, raresummer: 1, reactjspdf: 1, readingguilt: 1, readymoon: 1, readysnails: 1, realizedoor: 1, realizerecess: 1, rebelclover: 1, rebelhen: 1, rebelsubway: 1, receiptcent: 1, receptiveink: 1, receptivereaction: 1, recessrain: 1, reconditeprison: 1, reflectivestatement: 1, refundradar: 1, regularplants: 1, regulatesleet: 1, relationrest: 1, reloadphoto: 1, rememberdiscussion: 1, rentinfinity: 1, replaceroute: 1, resonantbrush: 1, respectrain: 1, resplendentecho: 1, retrievemint: 1, rhetoricalactivity: 1, rhetoricalveil: 1, rhymezebra: 1, rhythmrule: 1, richstring: 1, rigidrobin: 1, rigidveil: 1, rigorlab: 1, ringplant: 1, ringsrecord: 1, ritzykey: 1, ritzyrepresentative: 1, ritzyveil: 1, rockpebbles: 1, rollconnection: 1, roofrelation: 1, roseincome: 1, rottenray: 1, rusticprice: 1, ruthlessdegree: 1, ruthlessmilk: 1, sableloss: 1, sablesmile: 1, sadloaf: 1, saffronrefuge: 1, sagargift: 1, saltsacademy: 1, samesticks: 1, samplesamba: 1, scarcecard: 1, scarceshock: 1, scarcesign: 1, scarcestructure: 1, scarcesurprise: 1, scaredcomfort: 1, scaredsidewalk: 1, scaredslip: 1, scaredsnake: 1, scaredswing: 1, scarefowl: 1, scatteredheat: 1, scatteredquiver: 1, scatteredstream: 1, scenicapparel: 1, scientificshirt: 1, scintillatingscissors: 1, scissorsstatement: 1, scrapesleep: 1, scratchsofa: 1, screechingfurniture: 1, screechingstocking: 1, scribbleson: 1, scrollservice: 1, scrubswim: 1, seashoresociety: 1, secondhandfall: 1, secretivesheep: 1, secretspiders: 1, secretturtle: 1, seedscissors: 1, seemlysuggestion: 1, selfishsea: 1, sendingspire: 1, sensorsmile: 1, separatesort: 1, seraphichorizon: 1, seraphicjubilee: 1, serendipityecho: 1, serenecascade: 1, serenepebble: 1, serenesurf: 1, serioussuit: 1, serpentshampoo: 1, settleshoes: 1, shadeship: 1, shaggytank: 1, shakyseat: 1, shakysurprise: 1, shakytaste: 1, shallowblade: 1, sharkskids: 1, sheargovernor: 1, shesubscriptions: 1, shinypond: 1, shirtsidewalk: 1, shiveringspot: 1, shiverscissors: 1, shockinggrass: 1, shockingship: 1, shredquiz: 1, shydinosaurs: 1, sierrakermit: 1, signaturepod: 1, siliconslow: 1, sillyscrew: 1, simplesidewalk: 1, simulateswing: 1, sincerebuffalo: 1, sincerepelican: 1, sinceresubstance: 1, sinkbooks: 1, sixscissors: 1, sizzlingsmoke: 1, slaysweater: 1, slimyscarf: 1, slinksuggestion: 1, smallershops: 1, smashshoe: 1, smilewound: 1, smilingcattle: 1, smilingswim: 1, smilingwaves: 1, smoggysongs: 1, smoggystation: 1, snacktoken: 1, snakemineral: 1, snakeslang: 1, sneakwind: 1, sneakystew: 1, snoresmile: 1, snowmentor: 1, soggysponge: 1, soggyzoo: 1, solarislabyrinth: 1, somberscarecrow: 1, sombersea: 1, sombersquirrel: 1, sombersticks: 1, sombersurprise: 1, soothingglade: 1, sophisticatedstove: 1, sordidsmile: 1, soresidewalk: 1, soresneeze: 1, sorethunder: 1, soretrain: 1, sortsail: 1, sortsummer: 1, sowlettuce: 1, spadelocket: 1, sparkgoal: 1, sparklingshelf: 1, specialscissors: 1, spellmist: 1, spellsalsa: 1, spiffymachine: 1, spirebaboon: 1, spookystitch: 1, spoonsilk: 1, spotlessstamp: 1, spottednoise: 1, springolive: 1, springsister: 1, springsnails: 1, sproutingbag: 1, sprydelta: 1, sprysummit: 1, spuriousair: 1, spuriousbase: 1, spurioussquirrel: 1, spuriousstranger: 1, spysubstance: 1, squalidscrew: 1, squeakzinc: 1, squealingturn: 1, stakingbasket: 1, stakingshock: 1, staleshow: 1, stalesummer: 1, starkscale: 1, startingcars: 1, statshunt: 1, statuesqueship: 1, stayaction: 1, steadycopper: 1, stealsteel: 1, steepscale: 1, steepsister: 1, stepcattle: 1, stepplane: 1, stepwisevideo: 1, stereoproxy: 1, stewspiders: 1, stiffstem: 1, stimulatingsneeze: 1, stingsquirrel: 1, stingyshoe: 1, stingyspoon: 1, stockingsleet: 1, stockingsneeze: 1, stomachscience: 1, stonechin: 1, stopstomach: 1, stormyachiever: 1, stormyfold: 1, strangeclocks: 1, strangersponge: 1, strangesink: 1, streetsort: 1, stretchsister: 1, stretchsneeze: 1, stretchsquirrel: 1, stripedbat: 1, strivesidewalk: 1, sturdysnail: 1, subletyoke: 1, sublimequartz: 1, subsequentswim: 1, substantialcarpenter: 1, substantialgrade: 1, succeedscene: 1, successfulscent: 1, suddensoda: 1, sugarfriction: 1, suggestionbridge: 1, summerobject: 1, sunshinegates: 1, superchichair: 1, superficialspring: 1, superviseshoes: 1, supportwaves: 1, suspectmark: 1, swellstocking: 1, swelteringsleep: 1, swingslip: 1, swordgoose: 1, syllablesight: 1, synonymousrule: 1, synonymoussticks: 1, synthesizescarecrow: 1, tackytrains: 1, tacojournal: 1, talltouch: 1, tangibleteam: 1, tangyamount: 1, tastelesstrees: 1, tastelesstrucks: 1, tastesnake: 1, tawdryson: 1, tearfulglass: 1, techconverter: 1, tediousbear: 1, tedioustooth: 1, teenytinycellar: 1, teenytinytongue: 1, telephoneapparatus: 1, tempertrick: 1, tempttalk: 1, temptteam: 1, terriblethumb: 1, terrifictooth: 1, testadmiral: 1, texturetrick: 1, therapeuticcars: 1, thickticket: 1, thicktrucks: 1, thingsafterthought: 1, thingstaste: 1, thinkitwice: 1, thirdrespect: 1, thirstytwig: 1, thomastorch: 1, thoughtlessknot: 1, thrivingmarketplace: 1, ticketaunt: 1, ticklesign: 1, tidymitten: 1, tightpowder: 1, tinyswans: 1, tinytendency: 1, tiredthroat: 1, toolcapital: 1, toomanyalts: 1, torpidtongue: 1, trackcaddie: 1, tradetooth: 1, trafficviews: 1, tranquilamulet: 1, tranquilarchipelago: 1, tranquilcan: 1, tranquilcanyon: 1, tranquilplume: 1, tranquilside: 1, tranquilveil: 1, tranquilveranda: 1, trappush: 1, treadbun: 1, tremendousearthquake: 1, tremendousplastic: 1, tremendoustime: 1, tritebadge: 1, tritethunder: 1, tritetongue: 1, troubledtail: 1, troubleshade: 1, truckstomatoes: 1, truculentrate: 1, tumbleicicle: 1, tuneupcoffee: 1, twistloss: 1, twistsweater: 1, typicalairplane: 1, ubiquitoussea: 1, ubiquitousyard: 1, ultravalid: 1, unablehope: 1, unaccountablecreator: 1, unaccountablepie: 1, unarmedindustry: 1, unbecominghall: 1, uncoveredexpert: 1, understoodocean: 1, unequalbrake: 1, unequaltrail: 1, unknowncontrol: 1, unknowncrate: 1, unknowntray: 1, untidyquestion: 1, untidyrice: 1, unusedstone: 1, unusualtitle: 1, unwieldyimpulse: 1, uppitytime: 1, uselesslumber: 1, validmemo: 1, vanfireworks: 1, vanishmemory: 1, velvetnova: 1, velvetquasar: 1, venomousvessel: 1, venusgloria: 1, verdantanswer: 1, verdantlabyrinth: 1, verdantloom: 1, verdantsculpture: 1, verseballs: 1, vibrantcelebration: 1, vibrantgale: 1, vibranthaven: 1, vibrantpact: 1, vibrantsundown: 1, vibranttalisman: 1, vibrantvale: 1, victoriousrequest: 1, virtualvincent: 1, vividcanopy: 1, vividfrost: 1, vividmeadow: 1, vividplume: 1, voicelessvein: 1, voidgoo: 1, volatileprofit: 1, waitingnumber: 1, wantingwindow: 1, warnwing: 1, washbanana: 1, wateryvan: 1, waterywave: 1, waterywrist: 1, wearbasin: 1, websitesdude: 1, wellgroomedapparel: 1, wellgroomedhydrant: 1, wellmadefrog: 1, westpalmweb: 1, whimsicalcanyon: 1, whimsicalgrove: 1, whineattempt: 1, whirlwealth: 1, whiskyqueue: 1, whisperingcascade: 1, whisperingcrib: 1, whisperingquasar: 1, whisperingsummit: 1, whispermeeting: 1, wildcommittee: 1, wirecomic: 1, wiredforcoffee: 1, wirypaste: 1, wistfulwaste: 1, wittypopcorn: 1, wittyshack: 1, workoperation: 1, worldlever: 1, worriednumber: 1, worriedwine: 1, wretchedfloor: 1, wrongpotato: 1, wrongwound: 1, wtaccesscontrol: 1, xovq5nemr: 1, yieldingwoman: 1, zbwp6ghm: 1, zephyrcatalyst: 1, zephyrlabyrinth: 1, zestyhorizon: 1, zestyrover: 1, zestywire: 1, zipperxray: 1, zonewedgeshaft: 1 }, net: { "2mdn": 1, "2o7": 1, "3gl": 1, "a-mo": 1, acint: 1, adform: 1, adhigh: 1, admixer: 1, adobedc: 1, adspeed: 1, adverticum: 1, apicit: 1, appier: 1, akamaized: { "assets-momentum": 1 }, aticdn: 1, edgekey: { au: 1, ca: 1, ch: 1, cn: 1, "com-v1": 1, es: 1, ihg: 1, in: 1, io: 1, it: 1, jp: 1, net: 1, org: 1, com: { scene7: 1 }, "uk-v1": 1, uk: 1 }, azure: 1, azurefd: 1, bannerflow: 1, "bf-tools": 1, bidswitch: 1, bitsngo: 1, blueconic: 1, boldapps: 1, buysellads: 1, cachefly: 1, cedexis: 1, certona: 1, "confiant-integrations": 1, contentsquare: 1, criteo: 1, crwdcntrl: 1, cloudfront: { d1af033869koo7: 1, d1cr9zxt7u0sgu: 1, d1s87id6169zda: 1, d1vg5xiq7qffdj: 1, d1y068gyog18cq: 1, d214hhm15p4t1d: 1, d21gpk1vhmjuf5: 1, d2zah9y47r7bi2: 1, d38b8me95wjkbc: 1, d38xvr37kwwhcm: 1, d3fv2pqyjay52z: 1, d3i4yxtzktqr9n: 1, d3odp2r1osuwn0: 1, d5yoctgpv4cpx: 1, d6tizftlrpuof: 1, dbukjj6eu5tsf: 1, dn0qt3r0xannq: 1, dsh7ky7308k4b: 1, d2g3ekl4mwm40k: 1 }, demdex: 1, dotmetrics: 1, doubleclick: 1, durationmedia: 1, "e-planning": 1, edgecastcdn: 1, emsecure: 1, episerver: 1, esm1: 1, eulerian: 1, everestjs: 1, everesttech: 1, eyeota: 1, ezoic: 1, fastly: { global: { shared: { f2: 1 }, sni: { j: 1 } }, map: { "prisa-us-eu": 1, scribd: 1 }, ssl: { global: { "qognvtzku-x": 1 } } }, facebook: 1, fastclick: 1, fonts: 1, azureedge: { "fp-cdn": 1, sdtagging: 1 }, fuseplatform: 1, fwmrm: 1, "go-mpulse": 1, hadronid: 1, "hs-analytics": 1, hsleadflows: 1, "im-apps": 1, impervadns: 1, iocnt: 1, iprom: 1, jsdelivr: 1, "kanade-ad": 1, krxd: 1, "line-scdn": 1, listhub: 1, livecom: 1, livedoor: 1, liveperson: 1, lkqd: 1, llnwd: 1, lpsnmedia: 1, magnetmail: 1, marketo: 1, maxymiser: 1, media: 1, microad: 1, mobon: 1, monetate: 1, mxptint: 1, myfonts: 1, myvisualiq: 1, naver: 1, "nr-data": 1, ojrq: 1, omtrdc: 1, onecount: 1, openx: 1, openxcdn: 1, opta: 1, owneriq: 1, pages02: 1, pages03: 1, pages04: 1, pages05: 1, pages06: 1, pages08: 1, pingdom: 1, pmdstatic: 1, popads: 1, popcash: 1, primecaster: 1, "pro-market": 1, akamaihd: { "pxlclnmdecom-a": 1 }, rfihub: 1, sancdn: 1, "sc-static": 1, semasio: 1, sensic: 1, sexad: 1, smaato: 1, spreadshirts: 1, storygize: 1, tfaforms: 1, trackcmp: 1, trackedlink: 1, tradetracker: 1, "truste-svc": 1, uuidksinc: 1, viafoura: 1, visilabs: 1, visx: 1, w55c: 1, wdsvc: 1, witglobal: 1, yandex: 1, yastatic: 1, yieldlab: 1, zencdn: 1, zucks: 1, opencmp: 1, azurewebsites: { "app-fnsp-matomo-analytics-prod": 1 }, "ad-delivery": 1, chartbeat: 1, msecnd: 1, cloudfunctions: { "us-central1-adaptive-growth": 1 }, eviltracker: 1 }, co: { "6sc": 1, ayads: 1, getlasso: 1, idio: 1, increasingly: 1, jads: 1, nanorep: 1, nc0: 1, pcdn: 1, prmutv: 1, resetdigital: 1, t: 1, tctm: 1, zip: 1 }, gt: { ad: 1 }, ru: { adfox: 1, adriver: 1, digitaltarget: 1, mail: 1, mindbox: 1, rambler: 1, rutarget: 1, sape: 1, smi2: 1, "tns-counter": 1, top100: 1, ulogin: 1, yandex: 1, yadro: 1 }, jp: { adingo: 1, admatrix: 1, auone: 1, co: { dmm: 1, "i-mobile": 1, rakuten: 1, yahoo: 1 }, fout: 1, genieesspv: 1, "gmossp-sp": 1, gsspat: 1, gssprt: 1, ne: { hatena: 1 }, i2i: 1, "impact-ad": 1, microad: 1, nakanohito: 1, r10s: 1, "reemo-ad": 1, rtoaster: 1, shinobi: 1, "team-rec": 1, uncn: 1, yimg: 1, yjtag: 1 }, pl: { adocean: 1, gemius: 1, nsaudience: 1, onet: 1, salesmanago: 1, wp: 1 }, pro: { adpartner: 1, piwik: 1, usocial: 1 }, de: { adscale: 1, "auswaertiges-amt": 1, fiduciagad: 1, ioam: 1, itzbund: 1, vgwort: 1, werk21system: 1 }, re: { adsco: 1 }, info: { adxbid: 1, bitrix: 1, navistechnologies: 1, usergram: 1, webantenna: 1 }, tv: { affec: 1, attn: 1, iris: 1, ispot: 1, samba: 1, teads: 1, twitch: 1, videohub: 1 }, dev: { amazon: 1 }, us: { amung: 1, samplicio: 1, slgnt: 1, trkn: 1, owlsr: 1 }, media: { andbeyond: 1, nextday: 1, townsquare: 1, underdog: 1 }, link: { app: 1 }, cloud: { avct: 1, egain: 1, matomo: 1 }, delivery: { ay: 1, monu: 1 }, ly: { bit: 1 }, br: { com: { btg360: 1, clearsale: 1, jsuol: 1, shopconvert: 1, shoptarget: 1, soclminer: 1 }, org: { ivcbrasil: 1 } }, ch: { ch: 1, "da-services": 1, google: 1 }, me: { channel: 1, contentexchange: 1, grow: 1, line: 1, loopme: 1, t: 1 }, ms: { clarity: 1 }, my: { cnt: 1 }, se: { codigo: 1 }, to: { cpx: 1, tawk: 1 }, chat: { crisp: 1, gorgias: 1 }, fr: { "d-bi": 1, "open-system": 1, weborama: 1 }, uk: { co: { dailymail: 1, hsbc: 1 } }, gov: { dhs: 1 }, ai: { "e-volution": 1, hybrid: 1, m2: 1, nrich: 1, wknd: 1 }, be: { geoedge: 1 }, au: { com: { google: 1, news: 1, nine: 1, zipmoney: 1, telstra: 1 } }, stream: { ibclick: 1 }, cz: { imedia: 1, seznam: 1, trackad: 1 }, app: { infusionsoft: 1, permutive: 1, shop: 1 }, tech: { ingage: 1, primis: 1 }, eu: { kameleoon: 1, medallia: 1, media01: 1, ocdn: 1, rqtrk: 1, slgnt: 1 }, fi: { kesko: 1, simpli: 1 }, live: { lura: 1 }, services: { marketingautomation: 1 }, sg: { mediacorp: 1 }, bi: { newsroom: 1 }, fm: { pdst: 1 }, ad: { pixel: 1 }, xyz: { playground: 1 }, it: { plug: 1, repstatic: 1 }, cc: { popin: 1 }, network: { pub: 1 }, nl: { rijksoverheid: 1 }, fyi: { sda: 1 }, es: { socy: 1 }, im: { spot: 1 }, market: { spotim: 1 }, am: { tru: 1 }, no: { uio: 1, medietall: 1 }, at: { waust: 1 }, pe: { shop: 1 }, ca: { bc: { gov: 1 } }, gg: { clean: 1 }, example: { "ad-company": 1 }, site: { "ad-company": 1, "third-party": { bad: 1, broken: 1 } }, pw: { "5mcwl": 1, fvl1f: 1, h78xb: 1, i9w8p: 1, k54nw: 1, tdzvm: 1, tzwaw: 1, vq1qi: 1, zlp6s: 1 }, pub: { admiral: 1 } }; @@ -72,22 +73,36 @@ } } } - function getTabHostname() { - let framingOrigin = null; + function isBeingFramed() { + if (globalThis.location && "ancestorOrigins" in globalThis.location) { + return globalThis.location.ancestorOrigins.length > 0; + } + return globalThis.top !== globalThis.window; + } + function getTabUrl() { + let framingURLString = null; try { - framingOrigin = globalThis.top.location.href; + framingURLString = globalThis.top.location.href; } catch { - framingOrigin = globalThis.document.referrer; - } - if ("ancestorOrigins" in globalThis.location && globalThis.location.ancestorOrigins.length) { - framingOrigin = globalThis.location.ancestorOrigins.item(globalThis.location.ancestorOrigins.length - 1); + framingURLString = getTopLevelOriginFromFrameAncestors() ?? globalThis.document.referrer; } + let framingURL; try { - framingOrigin = new URL(framingOrigin).hostname; + framingURL = new URL(framingURLString); } catch { - framingOrigin = null; + framingURL = null; + } + return framingURL; + } + function getTopLevelOriginFromFrameAncestors() { + if ("ancestorOrigins" in globalThis.location && globalThis.location.ancestorOrigins.length) { + return globalThis.location.ancestorOrigins.item(globalThis.location.ancestorOrigins.length - 1); } - return framingOrigin; + return null; + } + function getTabHostname() { + const topURLString = getTabUrl()?.hostname; + return topURLString || null; } function matchHostname(hostname, exceptionDomain) { return hostname === exceptionDomain || hostname.endsWith(`.${exceptionDomain}`); @@ -132,7 +147,7 @@ return isPlatformSpecificFeature(feature) ? !args.site.enabledFeatures.includes(feature) : args.site.isBroken || args.site.allowlisted || !args.site.enabledFeatures.includes(feature); } function camelcase(dashCaseText) { - return dashCaseText.replace(/-(.)/g, (_, letter) => { + return dashCaseText.replace(/-(.)/g, (_2, letter) => { return letter.toUpperCase(); }); } @@ -315,9 +330,10 @@ return unprotectedDomain; } function computeLimitedSiteObject() { - const topLevelHostname = getTabHostname(); + const tabURL = getTabUrl(); return { - domain: topLevelHostname + domain: tabURL?.hostname || null, + url: tabURL?.href || null }; } function getPlatformVersion(preferences) { @@ -1747,8 +1763,8 @@ } // ../node_modules/immutable-json-patch/lib/esm/utils.js - function isEqual(a, b) { - return JSON.stringify(a) === JSON.stringify(b); + function isEqual(a, b2) { + return JSON.stringify(a) === JSON.stringify(b2); } function initial(array) { return array.slice(0, array.length - 1); @@ -2020,6 +2036,725 @@ return parseJSONPointer(fromPointer); } + // ../node_modules/urlpattern-polyfill/dist/urlpattern.js + var R = class { + constructor(t, r, n, o, c, l) { + __publicField(this, "type", 3); + __publicField(this, "name", ""); + __publicField(this, "prefix", ""); + __publicField(this, "value", ""); + __publicField(this, "suffix", ""); + __publicField(this, "modifier", 3); + this.type = t, this.name = r, this.prefix = n, this.value = o, this.suffix = c, this.modifier = l; + } + hasCustomName() { + return this.name !== "" && typeof this.name != "number"; + } + }; + var be = /[$_\p{ID_Start}]/u; + var Pe = /[$_\u200C\u200D\p{ID_Continue}]/u; + var M = ".*"; + function Re(e, t) { + return (t ? /^[\x00-\xFF]*$/ : /^[\x00-\x7F]*$/).test(e); + } + function v(e, t = false) { + let r = [], n = 0; + for (; n < e.length; ) { + let o = e[n], c = function(l) { + if (!t) throw new TypeError(l); + r.push({ type: "INVALID_CHAR", index: n, value: e[n++] }); + }; + if (o === "*") { + r.push({ type: "ASTERISK", index: n, value: e[n++] }); + continue; + } + if (o === "+" || o === "?") { + r.push({ type: "OTHER_MODIFIER", index: n, value: e[n++] }); + continue; + } + if (o === "\\") { + r.push({ type: "ESCAPED_CHAR", index: n++, value: e[n++] }); + continue; + } + if (o === "{") { + r.push({ type: "OPEN", index: n, value: e[n++] }); + continue; + } + if (o === "}") { + r.push({ type: "CLOSE", index: n, value: e[n++] }); + continue; + } + if (o === ":") { + let l = "", s = n + 1; + for (; s < e.length; ) { + let i = e.substr(s, 1); + if (s === n + 1 && be.test(i) || s !== n + 1 && Pe.test(i)) { + l += e[s++]; + continue; + } + break; + } + if (!l) { + c(`Missing parameter name at ${n}`); + continue; + } + r.push({ type: "NAME", index: n, value: l }), n = s; + continue; + } + if (o === "(") { + let l = 1, s = "", i = n + 1, a = false; + if (e[i] === "?") { + c(`Pattern cannot start with "?" at ${i}`); + continue; + } + for (; i < e.length; ) { + if (!Re(e[i], false)) { + c(`Invalid character '${e[i]}' at ${i}.`), a = true; + break; + } + if (e[i] === "\\") { + s += e[i++] + e[i++]; + continue; + } + if (e[i] === ")") { + if (l--, l === 0) { + i++; + break; + } + } else if (e[i] === "(" && (l++, e[i + 1] !== "?")) { + c(`Capturing groups are not allowed at ${i}`), a = true; + break; + } + s += e[i++]; + } + if (a) continue; + if (l) { + c(`Unbalanced pattern at ${n}`); + continue; + } + if (!s) { + c(`Missing pattern at ${n}`); + continue; + } + r.push({ type: "REGEX", index: n, value: s }), n = i; + continue; + } + r.push({ type: "CHAR", index: n, value: e[n++] }); + } + return r.push({ type: "END", index: n, value: "" }), r; + } + function D(e, t = {}) { + let r = v(e); + t.delimiter ??= "/#?", t.prefixes ??= "./"; + let n = `[^${S(t.delimiter)}]+?`, o = [], c = 0, l = 0, s = "", i = /* @__PURE__ */ new Set(), a = (h) => { + if (l < r.length && r[l].type === h) return r[l++].value; + }, f = () => a("OTHER_MODIFIER") ?? a("ASTERISK"), d = (h) => { + let u = a(h); + if (u !== void 0) return u; + let { type: p, index: A } = r[l]; + throw new TypeError(`Unexpected ${p} at ${A}, expected ${h}`); + }, T = () => { + let h = "", u; + for (; u = a("CHAR") ?? a("ESCAPED_CHAR"); ) h += u; + return h; + }, Se = (h) => h, L = t.encodePart || Se, I = "", U = (h) => { + I += h; + }, $ = () => { + I.length && (o.push(new R(3, "", "", L(I), "", 3)), I = ""); + }, V = (h, u, p, A, Y) => { + let g = 3; + switch (Y) { + case "?": + g = 1; + break; + case "*": + g = 0; + break; + case "+": + g = 2; + break; + } + if (!u && !p && g === 3) { + U(h); + return; + } + if ($(), !u && !p) { + if (!h) return; + o.push(new R(3, "", "", L(h), "", g)); + return; + } + let m; + p ? p === "*" ? m = M : m = p : m = n; + let O = 2; + m === n ? (O = 1, m = "") : m === M && (O = 0, m = ""); + let P; + if (u ? P = u : p && (P = c++), i.has(P)) throw new TypeError(`Duplicate name '${P}'.`); + i.add(P), o.push(new R(O, P, L(h), m, L(A), g)); + }; + for (; l < r.length; ) { + let h = a("CHAR"), u = a("NAME"), p = a("REGEX"); + if (!u && !p && (p = a("ASTERISK")), u || p) { + let g = h ?? ""; + t.prefixes.indexOf(g) === -1 && (U(g), g = ""), $(); + let m = f(); + V(g, u, p, "", m); + continue; + } + let A = h ?? a("ESCAPED_CHAR"); + if (A) { + U(A); + continue; + } + if (a("OPEN")) { + let g = T(), m = a("NAME"), O = a("REGEX"); + !m && !O && (O = a("ASTERISK")); + let P = T(); + d("CLOSE"); + let xe = f(); + V(g, m, O, P, xe); + continue; + } + $(), d("END"); + } + return o; + } + function S(e) { + return e.replace(/([.+*?^${}()[\]|/\\])/g, "\\$1"); + } + function X(e) { + return e && e.ignoreCase ? "ui" : "u"; + } + function Z(e, t, r) { + return F(D(e, r), t, r); + } + function k(e) { + switch (e) { + case 0: + return "*"; + case 1: + return "?"; + case 2: + return "+"; + case 3: + return ""; + } + } + function F(e, t, r = {}) { + r.delimiter ??= "/#?", r.prefixes ??= "./", r.sensitive ??= false, r.strict ??= false, r.end ??= true, r.start ??= true, r.endsWith = ""; + let n = r.start ? "^" : ""; + for (let s of e) { + if (s.type === 3) { + s.modifier === 3 ? n += S(s.value) : n += `(?:${S(s.value)})${k(s.modifier)}`; + continue; + } + t && t.push(s.name); + let i = `[^${S(r.delimiter)}]+?`, a = s.value; + if (s.type === 1 ? a = i : s.type === 0 && (a = M), !s.prefix.length && !s.suffix.length) { + s.modifier === 3 || s.modifier === 1 ? n += `(${a})${k(s.modifier)}` : n += `((?:${a})${k(s.modifier)})`; + continue; + } + if (s.modifier === 3 || s.modifier === 1) { + n += `(?:${S(s.prefix)}(${a})${S(s.suffix)})`, n += k(s.modifier); + continue; + } + n += `(?:${S(s.prefix)}`, n += `((?:${a})(?:`, n += S(s.suffix), n += S(s.prefix), n += `(?:${a}))*)${S(s.suffix)})`, s.modifier === 0 && (n += "?"); + } + let o = `[${S(r.endsWith)}]|$`, c = `[${S(r.delimiter)}]`; + if (r.end) return r.strict || (n += `${c}?`), r.endsWith.length ? n += `(?=${o})` : n += "$", new RegExp(n, X(r)); + r.strict || (n += `(?:${c}(?=${o}))?`); + let l = false; + if (e.length) { + let s = e[e.length - 1]; + s.type === 3 && s.modifier === 3 && (l = r.delimiter.indexOf(s) > -1); + } + return l || (n += `(?=${c}|${o})`), new RegExp(n, X(r)); + } + var x = { delimiter: "", prefixes: "", sensitive: true, strict: true }; + var B = { delimiter: ".", prefixes: "", sensitive: true, strict: true }; + var q = { delimiter: "/", prefixes: "/", sensitive: true, strict: true }; + function J(e, t) { + return e.length ? e[0] === "/" ? true : !t || e.length < 2 ? false : (e[0] == "\\" || e[0] == "{") && e[1] == "/" : false; + } + function Q(e, t) { + return e.startsWith(t) ? e.substring(t.length, e.length) : e; + } + function Ee(e, t) { + return e.endsWith(t) ? e.substr(0, e.length - t.length) : e; + } + function W(e) { + return !e || e.length < 2 ? false : e[0] === "[" || (e[0] === "\\" || e[0] === "{") && e[1] === "["; + } + var ee = ["ftp", "file", "http", "https", "ws", "wss"]; + function N(e) { + if (!e) return true; + for (let t of ee) if (e.test(t)) return true; + return false; + } + function te(e, t) { + if (e = Q(e, "#"), t || e === "") return e; + let r = new URL("https://example.com"); + return r.hash = e, r.hash ? r.hash.substring(1, r.hash.length) : ""; + } + function re(e, t) { + if (e = Q(e, "?"), t || e === "") return e; + let r = new URL("https://example.com"); + return r.search = e, r.search ? r.search.substring(1, r.search.length) : ""; + } + function ne(e, t) { + return t || e === "" ? e : W(e) ? j(e) : z(e); + } + function se(e, t) { + if (t || e === "") return e; + let r = new URL("https://example.com"); + return r.password = e, r.password; + } + function ie(e, t) { + if (t || e === "") return e; + let r = new URL("https://example.com"); + return r.username = e, r.username; + } + function ae(e, t, r) { + if (r || e === "") return e; + if (t && !ee.includes(t)) return new URL(`${t}:${e}`).pathname; + let n = e[0] == "/"; + return e = new URL(n ? e : "/-" + e, "https://example.com").pathname, n || (e = e.substring(2, e.length)), e; + } + function oe(e, t, r) { + return _(t) === e && (e = ""), r || e === "" ? e : K(e); + } + function ce(e, t) { + return e = Ee(e, ":"), t || e === "" ? e : y(e); + } + function _(e) { + switch (e) { + case "ws": + case "http": + return "80"; + case "wws": + case "https": + return "443"; + case "ftp": + return "21"; + default: + return ""; + } + } + function y(e) { + if (e === "") return e; + if (/^[-+.A-Za-z0-9]*$/.test(e)) return e.toLowerCase(); + throw new TypeError(`Invalid protocol '${e}'.`); + } + function le(e) { + if (e === "") return e; + let t = new URL("https://example.com"); + return t.username = e, t.username; + } + function fe(e) { + if (e === "") return e; + let t = new URL("https://example.com"); + return t.password = e, t.password; + } + function z(e) { + if (e === "") return e; + if (/[\t\n\r #%/:<>?@[\]^\\|]/g.test(e)) throw new TypeError(`Invalid hostname '${e}'`); + let t = new URL("https://example.com"); + return t.hostname = e, t.hostname; + } + function j(e) { + if (e === "") return e; + if (/[^0-9a-fA-F[\]:]/g.test(e)) throw new TypeError(`Invalid IPv6 hostname '${e}'`); + return e.toLowerCase(); + } + function K(e) { + if (e === "" || /^[0-9]*$/.test(e) && parseInt(e) <= 65535) return e; + throw new TypeError(`Invalid port '${e}'.`); + } + function he(e) { + if (e === "") return e; + let t = new URL("https://example.com"); + return t.pathname = e[0] !== "/" ? "/-" + e : e, e[0] !== "/" ? t.pathname.substring(2, t.pathname.length) : t.pathname; + } + function ue(e) { + return e === "" ? e : new URL(`data:${e}`).pathname; + } + function de(e) { + if (e === "") return e; + let t = new URL("https://example.com"); + return t.search = e, t.search.substring(1, t.search.length); + } + function pe(e) { + if (e === "") return e; + let t = new URL("https://example.com"); + return t.hash = e, t.hash.substring(1, t.hash.length); + } + var _i, _n, _t, _e, _s, _l, _o, _d, _p, _g, _H_instances, r_fn, R_fn, b_fn, u_fn, m_fn, a_fn, P_fn, E_fn, S_fn, O_fn, k_fn, x_fn, h_fn, f_fn, T_fn, A_fn, y_fn, w_fn, c_fn, C_fn, _a; + var H = (_a = class { + constructor(t) { + __privateAdd(this, _H_instances); + __privateAdd(this, _i); + __privateAdd(this, _n, []); + __privateAdd(this, _t, {}); + __privateAdd(this, _e, 0); + __privateAdd(this, _s, 1); + __privateAdd(this, _l, 0); + __privateAdd(this, _o, 0); + __privateAdd(this, _d, 0); + __privateAdd(this, _p, 0); + __privateAdd(this, _g, false); + __privateSet(this, _i, t); + } + get result() { + return __privateGet(this, _t); + } + parse() { + for (__privateSet(this, _n, v(__privateGet(this, _i), true)); __privateGet(this, _e) < __privateGet(this, _n).length; __privateSet(this, _e, __privateGet(this, _e) + __privateGet(this, _s))) { + if (__privateSet(this, _s, 1), __privateGet(this, _n)[__privateGet(this, _e)].type === "END") { + if (__privateGet(this, _o) === 0) { + __privateMethod(this, _H_instances, b_fn).call(this), __privateMethod(this, _H_instances, f_fn).call(this) ? __privateMethod(this, _H_instances, r_fn).call(this, 9, 1) : __privateMethod(this, _H_instances, h_fn).call(this) ? __privateMethod(this, _H_instances, r_fn).call(this, 8, 1) : __privateMethod(this, _H_instances, r_fn).call(this, 7, 0); + continue; + } else if (__privateGet(this, _o) === 2) { + __privateMethod(this, _H_instances, u_fn).call(this, 5); + continue; + } + __privateMethod(this, _H_instances, r_fn).call(this, 10, 0); + break; + } + if (__privateGet(this, _d) > 0) if (__privateMethod(this, _H_instances, A_fn).call(this)) __privateSet(this, _d, __privateGet(this, _d) - 1); + else continue; + if (__privateMethod(this, _H_instances, T_fn).call(this)) { + __privateSet(this, _d, __privateGet(this, _d) + 1); + continue; + } + switch (__privateGet(this, _o)) { + case 0: + __privateMethod(this, _H_instances, P_fn).call(this) && __privateMethod(this, _H_instances, u_fn).call(this, 1); + break; + case 1: + if (__privateMethod(this, _H_instances, P_fn).call(this)) { + __privateMethod(this, _H_instances, C_fn).call(this); + let t = 7, r = 1; + __privateMethod(this, _H_instances, E_fn).call(this) ? (t = 2, r = 3) : __privateGet(this, _g) && (t = 2), __privateMethod(this, _H_instances, r_fn).call(this, t, r); + } + break; + case 2: + __privateMethod(this, _H_instances, S_fn).call(this) ? __privateMethod(this, _H_instances, u_fn).call(this, 3) : (__privateMethod(this, _H_instances, x_fn).call(this) || __privateMethod(this, _H_instances, h_fn).call(this) || __privateMethod(this, _H_instances, f_fn).call(this)) && __privateMethod(this, _H_instances, u_fn).call(this, 5); + break; + case 3: + __privateMethod(this, _H_instances, O_fn).call(this) ? __privateMethod(this, _H_instances, r_fn).call(this, 4, 1) : __privateMethod(this, _H_instances, S_fn).call(this) && __privateMethod(this, _H_instances, r_fn).call(this, 5, 1); + break; + case 4: + __privateMethod(this, _H_instances, S_fn).call(this) && __privateMethod(this, _H_instances, r_fn).call(this, 5, 1); + break; + case 5: + __privateMethod(this, _H_instances, y_fn).call(this) ? __privateSet(this, _p, __privateGet(this, _p) + 1) : __privateMethod(this, _H_instances, w_fn).call(this) && __privateSet(this, _p, __privateGet(this, _p) - 1), __privateMethod(this, _H_instances, k_fn).call(this) && !__privateGet(this, _p) ? __privateMethod(this, _H_instances, r_fn).call(this, 6, 1) : __privateMethod(this, _H_instances, x_fn).call(this) ? __privateMethod(this, _H_instances, r_fn).call(this, 7, 0) : __privateMethod(this, _H_instances, h_fn).call(this) ? __privateMethod(this, _H_instances, r_fn).call(this, 8, 1) : __privateMethod(this, _H_instances, f_fn).call(this) && __privateMethod(this, _H_instances, r_fn).call(this, 9, 1); + break; + case 6: + __privateMethod(this, _H_instances, x_fn).call(this) ? __privateMethod(this, _H_instances, r_fn).call(this, 7, 0) : __privateMethod(this, _H_instances, h_fn).call(this) ? __privateMethod(this, _H_instances, r_fn).call(this, 8, 1) : __privateMethod(this, _H_instances, f_fn).call(this) && __privateMethod(this, _H_instances, r_fn).call(this, 9, 1); + break; + case 7: + __privateMethod(this, _H_instances, h_fn).call(this) ? __privateMethod(this, _H_instances, r_fn).call(this, 8, 1) : __privateMethod(this, _H_instances, f_fn).call(this) && __privateMethod(this, _H_instances, r_fn).call(this, 9, 1); + break; + case 8: + __privateMethod(this, _H_instances, f_fn).call(this) && __privateMethod(this, _H_instances, r_fn).call(this, 9, 1); + break; + case 9: + break; + case 10: + break; + } + } + __privateGet(this, _t).hostname !== void 0 && __privateGet(this, _t).port === void 0 && (__privateGet(this, _t).port = ""); + } + }, _i = new WeakMap(), _n = new WeakMap(), _t = new WeakMap(), _e = new WeakMap(), _s = new WeakMap(), _l = new WeakMap(), _o = new WeakMap(), _d = new WeakMap(), _p = new WeakMap(), _g = new WeakMap(), _H_instances = new WeakSet(), r_fn = function(t, r) { + switch (__privateGet(this, _o)) { + case 0: + break; + case 1: + __privateGet(this, _t).protocol = __privateMethod(this, _H_instances, c_fn).call(this); + break; + case 2: + break; + case 3: + __privateGet(this, _t).username = __privateMethod(this, _H_instances, c_fn).call(this); + break; + case 4: + __privateGet(this, _t).password = __privateMethod(this, _H_instances, c_fn).call(this); + break; + case 5: + __privateGet(this, _t).hostname = __privateMethod(this, _H_instances, c_fn).call(this); + break; + case 6: + __privateGet(this, _t).port = __privateMethod(this, _H_instances, c_fn).call(this); + break; + case 7: + __privateGet(this, _t).pathname = __privateMethod(this, _H_instances, c_fn).call(this); + break; + case 8: + __privateGet(this, _t).search = __privateMethod(this, _H_instances, c_fn).call(this); + break; + case 9: + __privateGet(this, _t).hash = __privateMethod(this, _H_instances, c_fn).call(this); + break; + case 10: + break; + } + __privateGet(this, _o) !== 0 && t !== 10 && ([1, 2, 3, 4].includes(__privateGet(this, _o)) && [6, 7, 8, 9].includes(t) && (__privateGet(this, _t).hostname ??= ""), [1, 2, 3, 4, 5, 6].includes(__privateGet(this, _o)) && [8, 9].includes(t) && (__privateGet(this, _t).pathname ??= __privateGet(this, _g) ? "/" : ""), [1, 2, 3, 4, 5, 6, 7].includes(__privateGet(this, _o)) && t === 9 && (__privateGet(this, _t).search ??= "")), __privateMethod(this, _H_instances, R_fn).call(this, t, r); + }, R_fn = function(t, r) { + __privateSet(this, _o, t), __privateSet(this, _l, __privateGet(this, _e) + r), __privateSet(this, _e, __privateGet(this, _e) + r), __privateSet(this, _s, 0); + }, b_fn = function() { + __privateSet(this, _e, __privateGet(this, _l)), __privateSet(this, _s, 0); + }, u_fn = function(t) { + __privateMethod(this, _H_instances, b_fn).call(this), __privateSet(this, _o, t); + }, m_fn = function(t) { + return t < 0 && (t = __privateGet(this, _n).length - t), t < __privateGet(this, _n).length ? __privateGet(this, _n)[t] : __privateGet(this, _n)[__privateGet(this, _n).length - 1]; + }, a_fn = function(t, r) { + let n = __privateMethod(this, _H_instances, m_fn).call(this, t); + return n.value === r && (n.type === "CHAR" || n.type === "ESCAPED_CHAR" || n.type === "INVALID_CHAR"); + }, P_fn = function() { + return __privateMethod(this, _H_instances, a_fn).call(this, __privateGet(this, _e), ":"); + }, E_fn = function() { + return __privateMethod(this, _H_instances, a_fn).call(this, __privateGet(this, _e) + 1, "/") && __privateMethod(this, _H_instances, a_fn).call(this, __privateGet(this, _e) + 2, "/"); + }, S_fn = function() { + return __privateMethod(this, _H_instances, a_fn).call(this, __privateGet(this, _e), "@"); + }, O_fn = function() { + return __privateMethod(this, _H_instances, a_fn).call(this, __privateGet(this, _e), ":"); + }, k_fn = function() { + return __privateMethod(this, _H_instances, a_fn).call(this, __privateGet(this, _e), ":"); + }, x_fn = function() { + return __privateMethod(this, _H_instances, a_fn).call(this, __privateGet(this, _e), "/"); + }, h_fn = function() { + if (__privateMethod(this, _H_instances, a_fn).call(this, __privateGet(this, _e), "?")) return true; + if (__privateGet(this, _n)[__privateGet(this, _e)].value !== "?") return false; + let t = __privateMethod(this, _H_instances, m_fn).call(this, __privateGet(this, _e) - 1); + return t.type !== "NAME" && t.type !== "REGEX" && t.type !== "CLOSE" && t.type !== "ASTERISK"; + }, f_fn = function() { + return __privateMethod(this, _H_instances, a_fn).call(this, __privateGet(this, _e), "#"); + }, T_fn = function() { + return __privateGet(this, _n)[__privateGet(this, _e)].type == "OPEN"; + }, A_fn = function() { + return __privateGet(this, _n)[__privateGet(this, _e)].type == "CLOSE"; + }, y_fn = function() { + return __privateMethod(this, _H_instances, a_fn).call(this, __privateGet(this, _e), "["); + }, w_fn = function() { + return __privateMethod(this, _H_instances, a_fn).call(this, __privateGet(this, _e), "]"); + }, c_fn = function() { + let t = __privateGet(this, _n)[__privateGet(this, _e)], r = __privateMethod(this, _H_instances, m_fn).call(this, __privateGet(this, _l)).index; + return __privateGet(this, _i).substring(r, t.index); + }, C_fn = function() { + let t = {}; + Object.assign(t, x), t.encodePart = y; + let r = Z(__privateMethod(this, _H_instances, c_fn).call(this), void 0, t); + __privateSet(this, _g, N(r)); + }, _a); + var G = ["protocol", "username", "password", "hostname", "port", "pathname", "search", "hash"]; + var E = "*"; + function ge(e, t) { + if (typeof e != "string") throw new TypeError("parameter 1 is not of type 'string'."); + let r = new URL(e, t); + return { protocol: r.protocol.substring(0, r.protocol.length - 1), username: r.username, password: r.password, hostname: r.hostname, port: r.port, pathname: r.pathname, search: r.search !== "" ? r.search.substring(1, r.search.length) : void 0, hash: r.hash !== "" ? r.hash.substring(1, r.hash.length) : void 0 }; + } + function b(e, t) { + return t ? C(e) : e; + } + function w(e, t, r) { + let n; + if (typeof t.baseURL == "string") try { + n = new URL(t.baseURL), t.protocol === void 0 && (e.protocol = b(n.protocol.substring(0, n.protocol.length - 1), r)), !r && t.protocol === void 0 && t.hostname === void 0 && t.port === void 0 && t.username === void 0 && (e.username = b(n.username, r)), !r && t.protocol === void 0 && t.hostname === void 0 && t.port === void 0 && t.username === void 0 && t.password === void 0 && (e.password = b(n.password, r)), t.protocol === void 0 && t.hostname === void 0 && (e.hostname = b(n.hostname, r)), t.protocol === void 0 && t.hostname === void 0 && t.port === void 0 && (e.port = b(n.port, r)), t.protocol === void 0 && t.hostname === void 0 && t.port === void 0 && t.pathname === void 0 && (e.pathname = b(n.pathname, r)), t.protocol === void 0 && t.hostname === void 0 && t.port === void 0 && t.pathname === void 0 && t.search === void 0 && (e.search = b(n.search.substring(1, n.search.length), r)), t.protocol === void 0 && t.hostname === void 0 && t.port === void 0 && t.pathname === void 0 && t.search === void 0 && t.hash === void 0 && (e.hash = b(n.hash.substring(1, n.hash.length), r)); + } catch { + throw new TypeError(`invalid baseURL '${t.baseURL}'.`); + } + if (typeof t.protocol == "string" && (e.protocol = ce(t.protocol, r)), typeof t.username == "string" && (e.username = ie(t.username, r)), typeof t.password == "string" && (e.password = se(t.password, r)), typeof t.hostname == "string" && (e.hostname = ne(t.hostname, r)), typeof t.port == "string" && (e.port = oe(t.port, e.protocol, r)), typeof t.pathname == "string") { + if (e.pathname = t.pathname, n && !J(e.pathname, r)) { + let o = n.pathname.lastIndexOf("/"); + o >= 0 && (e.pathname = b(n.pathname.substring(0, o + 1), r) + e.pathname); + } + e.pathname = ae(e.pathname, e.protocol, r); + } + return typeof t.search == "string" && (e.search = re(t.search, r)), typeof t.hash == "string" && (e.hash = te(t.hash, r)), e; + } + function C(e) { + return e.replace(/([+*?:{}()\\])/g, "\\$1"); + } + function Oe(e) { + return e.replace(/([.+*?^${}()[\]|/\\])/g, "\\$1"); + } + function ke(e, t) { + t.delimiter ??= "/#?", t.prefixes ??= "./", t.sensitive ??= false, t.strict ??= false, t.end ??= true, t.start ??= true, t.endsWith = ""; + let r = ".*", n = `[^${Oe(t.delimiter)}]+?`, o = /[$_\u200C\u200D\p{ID_Continue}]/u, c = ""; + for (let l = 0; l < e.length; ++l) { + let s = e[l]; + if (s.type === 3) { + if (s.modifier === 3) { + c += C(s.value); + continue; + } + c += `{${C(s.value)}}${k(s.modifier)}`; + continue; + } + let i = s.hasCustomName(), a = !!s.suffix.length || !!s.prefix.length && (s.prefix.length !== 1 || !t.prefixes.includes(s.prefix)), f = l > 0 ? e[l - 1] : null, d = l < e.length - 1 ? e[l + 1] : null; + if (!a && i && s.type === 1 && s.modifier === 3 && d && !d.prefix.length && !d.suffix.length) if (d.type === 3) { + let T = d.value.length > 0 ? d.value[0] : ""; + a = o.test(T); + } else a = !d.hasCustomName(); + if (!a && !s.prefix.length && f && f.type === 3) { + let T = f.value[f.value.length - 1]; + a = t.prefixes.includes(T); + } + a && (c += "{"), c += C(s.prefix), i && (c += `:${s.name}`), s.type === 2 ? c += `(${s.value})` : s.type === 1 ? i || (c += `(${n})`) : s.type === 0 && (!i && (!f || f.type === 3 || f.modifier !== 3 || a || s.prefix !== "") ? c += "*" : c += `(${r})`), s.type === 1 && i && s.suffix.length && o.test(s.suffix[0]) && (c += "\\"), c += C(s.suffix), a && (c += "}"), s.modifier !== 3 && (c += k(s.modifier)); + } + return c; + } + var _i2, _n2, _t2, _e2, _s2, _l2, _a2; + var me = (_a2 = class { + constructor(t = {}, r, n) { + __privateAdd(this, _i2); + __privateAdd(this, _n2, {}); + __privateAdd(this, _t2, {}); + __privateAdd(this, _e2, {}); + __privateAdd(this, _s2, {}); + __privateAdd(this, _l2, false); + try { + let o; + if (typeof r == "string" ? o = r : n = r, typeof t == "string") { + let i = new H(t); + if (i.parse(), t = i.result, o === void 0 && typeof t.protocol != "string") throw new TypeError("A base URL must be provided for a relative constructor string."); + t.baseURL = o; + } else { + if (!t || typeof t != "object") throw new TypeError("parameter 1 is not of type 'string' and cannot convert to dictionary."); + if (o) throw new TypeError("parameter 1 is not of type 'string'."); + } + typeof n > "u" && (n = { ignoreCase: false }); + let c = { ignoreCase: n.ignoreCase === true }, l = { pathname: E, protocol: E, username: E, password: E, hostname: E, port: E, search: E, hash: E }; + __privateSet(this, _i2, w(l, t, true)), _(__privateGet(this, _i2).protocol) === __privateGet(this, _i2).port && (__privateGet(this, _i2).port = ""); + let s; + for (s of G) { + if (!(s in __privateGet(this, _i2))) continue; + let i = {}, a = __privateGet(this, _i2)[s]; + switch (__privateGet(this, _t2)[s] = [], s) { + case "protocol": + Object.assign(i, x), i.encodePart = y; + break; + case "username": + Object.assign(i, x), i.encodePart = le; + break; + case "password": + Object.assign(i, x), i.encodePart = fe; + break; + case "hostname": + Object.assign(i, B), W(a) ? i.encodePart = j : i.encodePart = z; + break; + case "port": + Object.assign(i, x), i.encodePart = K; + break; + case "pathname": + N(__privateGet(this, _n2).protocol) ? (Object.assign(i, q, c), i.encodePart = he) : (Object.assign(i, x, c), i.encodePart = ue); + break; + case "search": + Object.assign(i, x, c), i.encodePart = de; + break; + case "hash": + Object.assign(i, x, c), i.encodePart = pe; + break; + } + try { + __privateGet(this, _s2)[s] = D(a, i), __privateGet(this, _n2)[s] = F(__privateGet(this, _s2)[s], __privateGet(this, _t2)[s], i), __privateGet(this, _e2)[s] = ke(__privateGet(this, _s2)[s], i), __privateSet(this, _l2, __privateGet(this, _l2) || __privateGet(this, _s2)[s].some((f) => f.type === 2)); + } catch { + throw new TypeError(`invalid ${s} pattern '${__privateGet(this, _i2)[s]}'.`); + } + } + } catch (o) { + throw new TypeError(`Failed to construct 'URLPattern': ${o.message}`); + } + } + test(t = {}, r) { + let n = { pathname: "", protocol: "", username: "", password: "", hostname: "", port: "", search: "", hash: "" }; + if (typeof t != "string" && r) throw new TypeError("parameter 1 is not of type 'string'."); + if (typeof t > "u") return false; + try { + typeof t == "object" ? n = w(n, t, false) : n = w(n, ge(t, r), false); + } catch { + return false; + } + let o; + for (o of G) if (!__privateGet(this, _n2)[o].exec(n[o])) return false; + return true; + } + exec(t = {}, r) { + let n = { pathname: "", protocol: "", username: "", password: "", hostname: "", port: "", search: "", hash: "" }; + if (typeof t != "string" && r) throw new TypeError("parameter 1 is not of type 'string'."); + if (typeof t > "u") return; + try { + typeof t == "object" ? n = w(n, t, false) : n = w(n, ge(t, r), false); + } catch { + return null; + } + let o = {}; + r ? o.inputs = [t, r] : o.inputs = [t]; + let c; + for (c of G) { + let l = __privateGet(this, _n2)[c].exec(n[c]); + if (!l) return null; + let s = {}; + for (let [i, a] of __privateGet(this, _t2)[c].entries()) if (typeof a == "string" || typeof a == "number") { + let f = l[i + 1]; + s[a] = f; + } + o[c] = { input: n[c] ?? "", groups: s }; + } + return o; + } + static compareComponent(t, r, n) { + let o = (i, a) => { + for (let f of ["type", "modifier", "prefix", "value", "suffix"]) { + if (i[f] < a[f]) return -1; + if (i[f] === a[f]) continue; + return 1; + } + return 0; + }, c = new R(3, "", "", "", "", 3), l = new R(0, "", "", "", "", 3), s = (i, a) => { + let f = 0; + for (; f < Math.min(i.length, a.length); ++f) { + let d = o(i[f], a[f]); + if (d) return d; + } + return i.length === a.length ? 0 : o(i[f] ?? c, a[f] ?? c); + }; + return !__privateGet(r, _e2)[t] && !__privateGet(n, _e2)[t] ? 0 : __privateGet(r, _e2)[t] && !__privateGet(n, _e2)[t] ? s(__privateGet(r, _s2)[t], [l]) : !__privateGet(r, _e2)[t] && __privateGet(n, _e2)[t] ? s([l], __privateGet(n, _s2)[t]) : s(__privateGet(r, _s2)[t], __privateGet(n, _s2)[t]); + } + get protocol() { + return __privateGet(this, _e2).protocol; + } + get username() { + return __privateGet(this, _e2).username; + } + get password() { + return __privateGet(this, _e2).password; + } + get hostname() { + return __privateGet(this, _e2).hostname; + } + get port() { + return __privateGet(this, _e2).port; + } + get pathname() { + return __privateGet(this, _e2).pathname; + } + get search() { + return __privateGet(this, _e2).search; + } + get hash() { + return __privateGet(this, _e2).hash; + } + get hasRegExpGroups() { + return __privateGet(this, _l2); + } + }, _i2 = new WeakMap(), _n2 = new WeakMap(), _t2 = new WeakMap(), _e2 = new WeakMap(), _s2 = new WeakMap(), _l2 = new WeakMap(), _a2); + + // ../node_modules/urlpattern-polyfill/index.js + if (!globalThis.URLPattern) { + globalThis.URLPattern = me; + } + // src/config-feature.js var _bundledConfig, _args; var ConfigFeature = class { @@ -2043,6 +2778,15 @@ __privateGet(this, _args).featureSettings = parseFeatureSettings(bundledConfig, enabledFeatures); } } + /** + * Call this when the top URL has changed, to recompute the site object. + * This is used to update the path matching for urlPattern. + */ + recomputeSiteObject() { + if (__privateGet(this, _args)) { + __privateGet(this, _args).site = computeLimitedSiteObject(); + } + } get args() { return __privateGet(this, _args); } @@ -2053,25 +2797,99 @@ return __privateGet(this, _args)?.featureSettings; } /** - * Given a config key, interpret the value as a list of domain overrides, and return the elements that match the current page - * Consider using patchSettings instead as per `getFeatureSetting`. + * Given a config key, interpret the value as a list of conditionals objects, and return the elements that match the current page + * Consider in your feature using patchSettings instead as per `getFeatureSetting`. * @param {string} featureKeyName * @return {any[]} * @protected */ - matchDomainFeatureSetting(featureKeyName) { - const domain = this.args?.site.domain; - if (!domain) return []; - const domains = this._getFeatureSettings()?.[featureKeyName] || []; - return domains.filter((rule) => { - if (Array.isArray(rule.domain)) { - return rule.domain.some((domainRule) => { - return matchHostname(domain, domainRule); - }); + matchConditionalFeatureSetting(featureKeyName) { + const conditionalChanges = this._getFeatureSettings()?.[featureKeyName] || []; + return conditionalChanges.filter((rule) => { + let condition = rule.condition; + if (condition === void 0 && "domain" in rule) { + condition = this._domainToConditonBlocks(rule.domain); } - return matchHostname(domain, rule.domain); + return this._matchConditionalBlockOrArray(condition); }); } + /** + * Takes a list of domains and returns a list of condition blocks + * @param {string|string[]} domain + * @returns {ConditionBlock[]} + */ + _domainToConditonBlocks(domain) { + if (Array.isArray(domain)) { + return domain.map((domain2) => ({ domain: domain2 })); + } else { + return [{ domain }]; + } + } + /** + * Used to match conditional changes for a settings feature. + * @typedef {object} ConditionBlock + * @property {string[] | string} [domain] + * @property {object} [urlPattern] + */ + /** + * Takes multiple conditional blocks and returns true if any apply. + * @param {ConditionBlock|ConditionBlock[]} conditionBlock + * @returns {boolean} + */ + _matchConditionalBlockOrArray(conditionBlock) { + if (Array.isArray(conditionBlock)) { + return conditionBlock.some((block) => this._matchConditionalBlock(block)); + } + return this._matchConditionalBlock(conditionBlock); + } + /** + * Takes a conditional block and returns true if it applies. + * All conditions must be met to return true. + * @param {ConditionBlock} conditionBlock + * @returns {boolean} + */ + _matchConditionalBlock(conditionBlock) { + const conditionChecks = { + domain: this._matchDomainConditional, + urlPattern: this._matchUrlPatternConditional + }; + for (const key in conditionBlock) { + if (!conditionChecks[key]) { + return false; + } else if (!conditionChecks[key].call(this, conditionBlock)) { + return false; + } + } + return true; + } + /** + * Takes a condtion block and returns true if the current url matches the urlPattern. + * @param {ConditionBlock} conditionBlock + * @returns {boolean} + */ + _matchUrlPatternConditional(conditionBlock) { + const url = this.args?.site.url; + if (!url) return false; + if (typeof conditionBlock.urlPattern === "string") { + return new me(conditionBlock.urlPattern, url).test(url); + } + const pattern = new me(conditionBlock.urlPattern); + return pattern.test(url); + } + /** + * Takes a condition block and returns true if the current domain matches the domain. + * @param {ConditionBlock} conditionBlock + * @returns {boolean} + */ + _matchDomainConditional(conditionBlock) { + if (!conditionBlock.domain) return false; + const domain = this.args?.site.domain; + if (!domain) return false; + if (Array.isArray(conditionBlock.domain)) { + return false; + } + return matchHostname(domain, conditionBlock.domain); + } /** * Return the settings object for a feature * @param {string} [featureName] - The name of the feature to get the settings for; defaults to the name of the feature @@ -2113,40 +2931,83 @@ return result === "enabled"; } /** - * Return a specific setting from the feature settings - * If the "settings" key within the config has a "domains" key, it will be used to override the settings. - * This uses JSONPatch to apply the patches to settings before getting the setting value. - * For example.com getFeatureSettings('val') will return 1: - * ```json - * { - * "settings": { - * "domains": [ - * { - * "domain": "example.com", - * "patchSettings": [ - * { "op": "replace", "path": "/val", "value": 1 } - * ] - * } - * ] - * } - * } - * ``` - * "domain" can either be a string or an array of strings. - - * For boolean states you should consider using getFeatureSettingEnabled. - * @param {string} featureKeyName - * @param {string} [featureName] - * @returns {any} - */ + * Return a specific setting from the feature settings + * If the "settings" key within the config has a "conditionalChanges" key, it will be used to override the settings. + * This uses JSONPatch to apply the patches to settings before getting the setting value. + * For example.com getFeatureSettings('val') will return 1: + * ```json + * { + * "settings": { + * "conditionalChanges": [ + * { + * "domain": "example.com", + * "patchSettings": [ + * { "op": "replace", "path": "/val", "value": 1 } + * ] + * } + * ] + * } + * } + * ``` + * "domain" can either be a string or an array of strings. + * Additionally we support urlPattern for more complex matching. + * For example.com getFeatureSettings('val') will return 1: + * ```json + * { + * "settings": { + * "conditionalChanges": [ + * { + * "condition": { + * "urlPattern": "https://example.com/*", + * }, + * "patchSettings": [ + * { "op": "replace", "path": "/val", "value": 1 } + * ] + * } + * ] + * } + * } + * ``` + * We also support multiple conditions: + * ```json + * { + * "settings": { + * "conditionalChanges": [ + * { + * "condition": [ + * { + * "urlPattern": "https://example.com/*", + * }, + * { + * "urlPattern": "https://other.com/path/something", + * }, + * ], + * "patchSettings": [ + * { "op": "replace", "path": "/val", "value": 1 } + * ] + * } + * ] + * } + * } + * ``` + * + * For boolean states you should consider using getFeatureSettingEnabled. + * @param {string} featureKeyName + * @param {string} [featureName] + * @returns {any} + */ getFeatureSetting(featureKeyName, featureName) { let result = this._getFeatureSettings(featureName); - if (featureKeyName === "domains") { - throw new Error("domains is a reserved feature setting key name"); + if (featureKeyName in ["domains", "conditionalChanges"]) { + throw new Error(`${featureKeyName} is a reserved feature setting key name`); } - const domainMatch = [...this.matchDomainFeatureSetting("domains")].sort((a, b) => { - return a.domain.length - b.domain.length; - }); - for (const match of domainMatch) { + let conditionalMatches = []; + if (result?.conditionalChanges) { + conditionalMatches = this.matchConditionalFeatureSetting("conditionalChanges"); + } else { + conditionalMatches = this.matchConditionalFeatureSetting("domains"); + } + for (const match of conditionalMatches) { if (match.patchSettings === void 0) { continue; } @@ -2179,6 +3040,11 @@ __privateAdd(this, _messaging); /** @type {boolean} */ __privateAdd(this, _isDebugFlagSet, false); + /** + * Set this to true if you wish to listen to top level URL changes for config matching. + * @type {boolean} + */ + __publicField(this, "listenForUrlChanges", false); /** @type {ImportMeta} */ __privateAdd(this, _importConfig); this.setArgs(this.args); @@ -2344,7 +3210,7 @@ this.messaging?.notify("addDebugFlag", { flag: this.name }); - } catch (_e) { + } catch (_e3) { } } /** @@ -2355,17 +3221,17 @@ * @param {import('./wrapper-utils').StrictPropertyDescriptor} descriptor - requires all descriptor options to be defined because we can't validate correctness based on TS types */ defineProperty(object, propertyName, descriptor) { - ["value", "get", "set"].forEach((k) => { - const descriptorProp = descriptor[k]; + ["value", "get", "set"].forEach((k2) => { + const descriptorProp = descriptor[k2]; if (typeof descriptorProp === "function") { const addDebugFlag = this.addDebugFlag.bind(this); const wrapper = new Proxy2(descriptorProp, { - apply(_, thisArg, argumentsList) { + apply(_2, thisArg, argumentsList) { addDebugFlag(); return Reflect2.apply(descriptorProp, thisArg, argumentsList); } }); - descriptor[k] = wrapToString(wrapper, descriptorProp); + descriptor[k2] = wrapToString(wrapper, descriptorProp); } }); return defineProperty(object, propertyName, descriptor); @@ -2819,21 +3685,15 @@ __privateSet(this, _signInButtonSettings, this.getFeatureSetting("signInButton")); __privateSet(this, _settingsButtonSettings, this.getFeatureSetting("settingsButton")); } + urlChanged() { + this.handlePath(window.location.pathname); + } init() { + if (isBeingFramed()) { + return; + } this.setButtonSettings(); const handlePath = this.handlePath.bind(this); - const historyMethodProxy = new DDGProxy(this, History.prototype, "pushState", { - async apply(target, thisArg, args) { - const path = args[1] === "" ? args[2].split("?")[0] : args[1]; - await handlePath(path); - return DDGReflect.apply(target, thisArg, args); - } - }); - historyMethodProxy.overload(); - window.addEventListener("popstate", async () => { - const path = window.location.pathname; - await handlePath(path); - }); __privateSet(this, _domLoaded, new Promise((resolve) => { if (document.readyState !== "loading") { resolve(); @@ -2865,6 +3725,43 @@ ddg_feature_autofillPasswordImport: AutofillPasswordImport }; + // src/url-change.js + var urlChangeListeners = /* @__PURE__ */ new Set(); + function registerForURLChanges(listener) { + if (urlChangeListeners.size === 0) { + listenForURLChanges(); + } + urlChangeListeners.add(listener); + } + function handleURLChange() { + for (const listener of urlChangeListeners) { + listener(); + } + } + function listenForURLChanges() { + const urlChangedInstance = new ContentFeature("urlChanged", {}, {}); + if ("navigation" in globalThis && "addEventListener" in globalThis.navigation) { + globalThis.navigation.addEventListener("navigatesuccess", () => { + handleURLChange(); + }); + return; + } + if (isBeingFramed()) { + return; + } + const historyMethodProxy = new DDGProxy(urlChangedInstance, History.prototype, "pushState", { + apply(target, thisArg, args) { + const changeResult = DDGReflect.apply(target, thisArg, args); + handleURLChange(); + return changeResult; + } + }); + historyMethodProxy.overload(); + window.addEventListener("popstate", () => { + handleURLChange(); + }); + } + // src/content-scope-features.js var initArgs = null; var updates = []; @@ -2905,6 +3802,12 @@ resolvedFeatures.forEach(({ featureInstance, featureName }) => { if (!isFeatureBroken(args, featureName) || alwaysInitExtensionFeatures(args, featureName)) { featureInstance.callInit(args); + if (featureInstance.listenForUrlChanges || featureInstance.urlChanged) { + registerForURLChanges(() => { + featureInstance.recomputeSiteObject(); + featureInstance?.urlChanged(); + }); + } } }); while (updates.length) { diff --git a/node_modules/@duckduckgo/content-scope-scripts/build/android/brokerProtection.js b/node_modules/@duckduckgo/content-scope-scripts/build/android/brokerProtection.js index e4b83a63c888..a5ddfef605c5 100644 --- a/node_modules/@duckduckgo/content-scope-scripts/build/android/brokerProtection.js +++ b/node_modules/@duckduckgo/content-scope-scripts/build/android/brokerProtection.js @@ -11,11 +11,11 @@ throw TypeError(msg); }; var __defNormalProp = (obj, key, value) => key in obj ? __defProp(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value; - var __require = /* @__PURE__ */ ((x) => typeof require !== "undefined" ? require : typeof Proxy !== "undefined" ? new Proxy(x, { - get: (a, b) => (typeof require !== "undefined" ? require : a)[b] - }) : x)(function(x) { + var __require = /* @__PURE__ */ ((x2) => typeof require !== "undefined" ? require : typeof Proxy !== "undefined" ? new Proxy(x2, { + get: (a, b2) => (typeof require !== "undefined" ? require : a)[b2] + }) : x2)(function(x2) { if (typeof require !== "undefined") return require.apply(this, arguments); - throw Error('Dynamic require of "' + x + '" is not supported'); + throw Error('Dynamic require of "' + x2 + '" is not supported'); }); var __esm = (fn, res) => function __init() { return fn && (res = (0, fn[__getOwnPropNames(fn)[0]])(fn = 0)), res; @@ -44,6 +44,7 @@ var __privateGet = (obj, member, getter) => (__accessCheck(obj, member, "read from private field"), getter ? getter.call(obj) : member.get(obj)); var __privateAdd = (obj, member, value) => member.has(obj) ? __typeError("Cannot add the same private member more than once") : member instanceof WeakSet ? member.add(obj) : member.set(obj, value); var __privateSet = (obj, member, value, setter) => (__accessCheck(obj, member, "write to private field"), setter ? setter.call(obj, value) : member.set(obj, value), value); + var __privateMethod = (obj, member, method) => (__accessCheck(obj, member, "access private method"), method); // var define_import_meta_trackerLookup_default; @@ -1383,21 +1384,21 @@ return Object.keys(o); } function values(o) { - var v = []; - keys(o).forEach(function(k) { - v.push(o[k]); + var v2 = []; + keys(o).forEach(function(k2) { + v2.push(o[k2]); }); - return v; + return v2; } function each(o, fn) { - keys(o).forEach(function(k) { - fn(o[k], k); + keys(o).forEach(function(k2) { + fn(o[k2], k2); }); } function invert(o) { var o1 = {}; - keys(o).forEach(function(k) { - o1[o[k]] = k; + keys(o).forEach(function(k2) { + o1[o[k2]] = k2; }); return o1; } @@ -1411,13 +1412,13 @@ initialized = true; Direction_Code = invert(Directional); Addr_Match = { - type: flatten(Street_Type).sort().filter(function(v, i, arr) { - return arr.indexOf(v) === i; + type: flatten(Street_Type).sort().filter(function(v2, i, arr) { + return arr.indexOf(v2) === i; }).join("|"), fraction: "\\d+\\/\\d+", state: "\\b(?:" + keys(State_Code).concat(values(State_Code)).map(XRegExp.escape).join("|") + ")\\b", - direct: values(Directional).sort(function(a, b) { - return a.length < b.length; + direct: values(Directional).sort(function(a, b2) { + return a.length < b2.length; }).reduce(function(prev, curr) { return prev.concat([XRegExp.escape(curr.replace(/\w/g, "$&.")), curr]); }, keys(Directional)).join("|"), @@ -1444,12 +1445,12 @@ if (!parts) return null; var parsed = {}; - Object.keys(parts).forEach(function(k) { - if (["input", "index"].indexOf(k) !== -1 || isFinite(k)) + Object.keys(parts).forEach(function(k2) { + if (["input", "index"].indexOf(k2) !== -1 || isFinite(k2)) return; - var key = isFinite(k.split("_").pop()) ? k.split("_").slice(0, -1).join("_") : k; - if (parts[k]) - parsed[key] = parts[k].trim().replace(/^\s+|\s+$|[^\w\s\-#&]/g, ""); + var key = isFinite(k2.split("_").pop()) ? k2.split("_").slice(0, -1).join("_") : k2; + if (parts[k2]) + parsed[key] = parts[k2].trim().replace(/^\s+|\s+$|[^\w\s\-#&]/g, ""); }); each(Normalize_Map, function(map, key) { if (parsed[key] && map[parsed[key].toLowerCase()]) { @@ -1577,6 +1578,14 @@ return globalObj; } var exemptionLists = {}; + function shouldExemptUrl(type, url) { + for (const regex of exemptionLists[type]) { + if (regex.test(url)) { + return true; + } + } + return false; + } var debug = false; function initStringExemptionLists(args) { const { stringExemptionLists } = args; @@ -1588,31 +1597,81 @@ } } } - function getTabHostname() { - let framingOrigin = null; + function isBeingFramed() { + if (globalThis.location && "ancestorOrigins" in globalThis.location) { + return globalThis.location.ancestorOrigins.length > 0; + } + return globalThis.top !== globalThis.window; + } + function getTabUrl() { + let framingURLString = null; try { - framingOrigin = globalThis.top.location.href; + framingURLString = globalThis.top.location.href; } catch { - framingOrigin = globalThis.document.referrer; - } - if ("ancestorOrigins" in globalThis.location && globalThis.location.ancestorOrigins.length) { - framingOrigin = globalThis.location.ancestorOrigins.item(globalThis.location.ancestorOrigins.length - 1); + framingURLString = getTopLevelOriginFromFrameAncestors() ?? globalThis.document.referrer; } + let framingURL; try { - framingOrigin = new URL(framingOrigin).hostname; + framingURL = new URL(framingURLString); } catch { - framingOrigin = null; + framingURL = null; } - return framingOrigin; + return framingURL; + } + function getTopLevelOriginFromFrameAncestors() { + if ("ancestorOrigins" in globalThis.location && globalThis.location.ancestorOrigins.length) { + return globalThis.location.ancestorOrigins.item(globalThis.location.ancestorOrigins.length - 1); + } + return null; + } + function getTabHostname() { + const topURLString = getTabUrl()?.hostname; + return topURLString || null; } function matchHostname(hostname, exceptionDomain) { return hostname === exceptionDomain || hostname.endsWith(`.${exceptionDomain}`); } + var lineTest = /(\()?(https?:[^)]+):[0-9]+:[0-9]+(\))?/; + function getStackTraceUrls(stack) { + const urls = new Set2(); + try { + const errorLines = stack.split("\n"); + for (const line of errorLines) { + const res = line.match(lineTest); + if (res) { + urls.add(new URL(res[2], location.href)); + } + } + } catch (e) { + } + return urls; + } + function getStackTraceOrigins(stack) { + const urls = getStackTraceUrls(stack); + const origins = new Set2(); + for (const url of urls) { + origins.add(url.hostname); + } + return origins; + } + function shouldExemptMethod(type) { + if (!(type in exemptionLists) || exemptionLists[type].length === 0) { + return false; + } + const stack = getStack(); + const errorFiles = getStackTraceUrls(stack); + for (const path of errorFiles) { + if (shouldExemptUrl(type, path.href)) { + return true; + } + } + return false; + } function isFeatureBroken(args, feature) { return isPlatformSpecificFeature(feature) ? !args.site.enabledFeatures.includes(feature) : args.site.isBroken || args.site.allowlisted || !args.site.enabledFeatures.includes(feature); } function camelcase(dashCaseText) { - return dashCaseText.replace(/-(.)/g, (_, letter) => { + return dashCaseText.replace(/-(.)/g, (_2, letter) => { return letter.toUpperCase(); }); } @@ -1673,6 +1732,112 @@ return defaultValue; } } + function getStack() { + return new Error3().stack; + } + function debugSerialize(argsArray) { + const maxSerializedSize = 1e3; + const serializedArgs = argsArray.map((arg) => { + try { + const serializableOut = JSON.stringify(arg); + if (serializableOut.length > maxSerializedSize) { + return ``; + } + return serializableOut; + } catch (e) { + return ""; + } + }); + return JSON.stringify(serializedArgs); + } + var DDGProxy = class { + /** + * @param {import('./content-feature').default} feature + * @param {P} objectScope + * @param {string} property + * @param {ProxyObject

} proxyObject + */ + constructor(feature, objectScope, property, proxyObject) { + this.objectScope = objectScope; + this.property = property; + this.feature = feature; + this.featureName = feature.name; + this.camelFeatureName = camelcase(this.featureName); + const outputHandler = (...args) => { + this.feature.addDebugFlag(); + const isExempt = shouldExemptMethod(this.camelFeatureName); + if (debug) { + postDebugMessage(this.camelFeatureName, { + isProxy: true, + action: isExempt ? "ignore" : "restrict", + kind: this.property, + documentUrl: document.location.href, + stack: getStack(), + args: debugSerialize(args[2]) + }); + } + if (isExempt) { + return DDGReflect.apply(args[0], args[1], args[2]); + } + return proxyObject.apply(...args); + }; + const getMethod = (target, prop, receiver) => { + this.feature.addDebugFlag(); + if (prop === "toString") { + const method = Reflect.get(target, prop, receiver).bind(target); + Object.defineProperty(method, "toString", { + value: String.toString.bind(String.toString), + enumerable: false + }); + return method; + } + return DDGReflect.get(target, prop, receiver); + }; + this._native = objectScope[property]; + const handler = {}; + handler.apply = outputHandler; + handler.get = getMethod; + this.internal = new globalObj.Proxy(objectScope[property], handler); + } + // Actually apply the proxy to the native property + overload() { + this.objectScope[this.property] = this.internal; + } + overloadDescriptor() { + this.feature.defineProperty(this.objectScope, this.property, { + value: this.internal, + writable: true, + enumerable: true, + configurable: true + }); + } + }; + var maxCounter = /* @__PURE__ */ new Map(); + function numberOfTimesDebugged(feature) { + if (!maxCounter.has(feature)) { + maxCounter.set(feature, 1); + } else { + maxCounter.set(feature, maxCounter.get(feature) + 1); + } + return maxCounter.get(feature); + } + var DEBUG_MAX_TIMES = 5e3; + function postDebugMessage(feature, message, allowNonDebug = false) { + if (!debug && !allowNonDebug) { + return; + } + if (numberOfTimesDebugged(feature) > DEBUG_MAX_TIMES) { + return; + } + if (message.stack) { + const scriptOrigins = [...getStackTraceOrigins(message.stack)]; + message.scriptOrigins = scriptOrigins; + } + globalObj.postMessage({ + action: feature, + message + }); + } var DDGPromise = globalObj.Promise; var DDGReflect = globalObj.Reflect; function isUnprotectedDomain(topLevelHostname, featureList) { @@ -1689,9 +1854,10 @@ return unprotectedDomain; } function computeLimitedSiteObject() { - const topLevelHostname = getTabHostname(); + const tabURL = getTabUrl(); return { - domain: topLevelHostname + domain: tabURL?.hostname || null, + url: tabURL?.href || null }; } function getPlatformVersion(preferences) { @@ -3135,8 +3301,8 @@ // ../node_modules/immutable-json-patch/lib/esm/utils.js init_define_import_meta_trackerLookup(); - function isEqual(a, b) { - return JSON.stringify(a) === JSON.stringify(b); + function isEqual(a, b2) { + return JSON.stringify(a) === JSON.stringify(b2); } function initial(array) { return array.slice(0, array.length - 1); @@ -3409,6 +3575,729 @@ return parseJSONPointer(fromPointer); } + // ../node_modules/urlpattern-polyfill/index.js + init_define_import_meta_trackerLookup(); + + // ../node_modules/urlpattern-polyfill/dist/urlpattern.js + init_define_import_meta_trackerLookup(); + var R = class { + constructor(t, r, n, o, c, l) { + __publicField(this, "type", 3); + __publicField(this, "name", ""); + __publicField(this, "prefix", ""); + __publicField(this, "value", ""); + __publicField(this, "suffix", ""); + __publicField(this, "modifier", 3); + this.type = t, this.name = r, this.prefix = n, this.value = o, this.suffix = c, this.modifier = l; + } + hasCustomName() { + return this.name !== "" && typeof this.name != "number"; + } + }; + var be = /[$_\p{ID_Start}]/u; + var Pe = /[$_\u200C\u200D\p{ID_Continue}]/u; + var M = ".*"; + function Re(e, t) { + return (t ? /^[\x00-\xFF]*$/ : /^[\x00-\x7F]*$/).test(e); + } + function v(e, t = false) { + let r = [], n = 0; + for (; n < e.length; ) { + let o = e[n], c = function(l) { + if (!t) throw new TypeError(l); + r.push({ type: "INVALID_CHAR", index: n, value: e[n++] }); + }; + if (o === "*") { + r.push({ type: "ASTERISK", index: n, value: e[n++] }); + continue; + } + if (o === "+" || o === "?") { + r.push({ type: "OTHER_MODIFIER", index: n, value: e[n++] }); + continue; + } + if (o === "\\") { + r.push({ type: "ESCAPED_CHAR", index: n++, value: e[n++] }); + continue; + } + if (o === "{") { + r.push({ type: "OPEN", index: n, value: e[n++] }); + continue; + } + if (o === "}") { + r.push({ type: "CLOSE", index: n, value: e[n++] }); + continue; + } + if (o === ":") { + let l = "", s = n + 1; + for (; s < e.length; ) { + let i = e.substr(s, 1); + if (s === n + 1 && be.test(i) || s !== n + 1 && Pe.test(i)) { + l += e[s++]; + continue; + } + break; + } + if (!l) { + c(`Missing parameter name at ${n}`); + continue; + } + r.push({ type: "NAME", index: n, value: l }), n = s; + continue; + } + if (o === "(") { + let l = 1, s = "", i = n + 1, a = false; + if (e[i] === "?") { + c(`Pattern cannot start with "?" at ${i}`); + continue; + } + for (; i < e.length; ) { + if (!Re(e[i], false)) { + c(`Invalid character '${e[i]}' at ${i}.`), a = true; + break; + } + if (e[i] === "\\") { + s += e[i++] + e[i++]; + continue; + } + if (e[i] === ")") { + if (l--, l === 0) { + i++; + break; + } + } else if (e[i] === "(" && (l++, e[i + 1] !== "?")) { + c(`Capturing groups are not allowed at ${i}`), a = true; + break; + } + s += e[i++]; + } + if (a) continue; + if (l) { + c(`Unbalanced pattern at ${n}`); + continue; + } + if (!s) { + c(`Missing pattern at ${n}`); + continue; + } + r.push({ type: "REGEX", index: n, value: s }), n = i; + continue; + } + r.push({ type: "CHAR", index: n, value: e[n++] }); + } + return r.push({ type: "END", index: n, value: "" }), r; + } + function D(e, t = {}) { + let r = v(e); + t.delimiter ??= "/#?", t.prefixes ??= "./"; + let n = `[^${S(t.delimiter)}]+?`, o = [], c = 0, l = 0, s = "", i = /* @__PURE__ */ new Set(), a = (h) => { + if (l < r.length && r[l].type === h) return r[l++].value; + }, f = () => a("OTHER_MODIFIER") ?? a("ASTERISK"), d = (h) => { + let u = a(h); + if (u !== void 0) return u; + let { type: p, index: A } = r[l]; + throw new TypeError(`Unexpected ${p} at ${A}, expected ${h}`); + }, T = () => { + let h = "", u; + for (; u = a("CHAR") ?? a("ESCAPED_CHAR"); ) h += u; + return h; + }, Se = (h) => h, L = t.encodePart || Se, I = "", U = (h) => { + I += h; + }, $ = () => { + I.length && (o.push(new R(3, "", "", L(I), "", 3)), I = ""); + }, V = (h, u, p, A, Y) => { + let g = 3; + switch (Y) { + case "?": + g = 1; + break; + case "*": + g = 0; + break; + case "+": + g = 2; + break; + } + if (!u && !p && g === 3) { + U(h); + return; + } + if ($(), !u && !p) { + if (!h) return; + o.push(new R(3, "", "", L(h), "", g)); + return; + } + let m; + p ? p === "*" ? m = M : m = p : m = n; + let O = 2; + m === n ? (O = 1, m = "") : m === M && (O = 0, m = ""); + let P; + if (u ? P = u : p && (P = c++), i.has(P)) throw new TypeError(`Duplicate name '${P}'.`); + i.add(P), o.push(new R(O, P, L(h), m, L(A), g)); + }; + for (; l < r.length; ) { + let h = a("CHAR"), u = a("NAME"), p = a("REGEX"); + if (!u && !p && (p = a("ASTERISK")), u || p) { + let g = h ?? ""; + t.prefixes.indexOf(g) === -1 && (U(g), g = ""), $(); + let m = f(); + V(g, u, p, "", m); + continue; + } + let A = h ?? a("ESCAPED_CHAR"); + if (A) { + U(A); + continue; + } + if (a("OPEN")) { + let g = T(), m = a("NAME"), O = a("REGEX"); + !m && !O && (O = a("ASTERISK")); + let P = T(); + d("CLOSE"); + let xe = f(); + V(g, m, O, P, xe); + continue; + } + $(), d("END"); + } + return o; + } + function S(e) { + return e.replace(/([.+*?^${}()[\]|/\\])/g, "\\$1"); + } + function X(e) { + return e && e.ignoreCase ? "ui" : "u"; + } + function Z(e, t, r) { + return F(D(e, r), t, r); + } + function k(e) { + switch (e) { + case 0: + return "*"; + case 1: + return "?"; + case 2: + return "+"; + case 3: + return ""; + } + } + function F(e, t, r = {}) { + r.delimiter ??= "/#?", r.prefixes ??= "./", r.sensitive ??= false, r.strict ??= false, r.end ??= true, r.start ??= true, r.endsWith = ""; + let n = r.start ? "^" : ""; + for (let s of e) { + if (s.type === 3) { + s.modifier === 3 ? n += S(s.value) : n += `(?:${S(s.value)})${k(s.modifier)}`; + continue; + } + t && t.push(s.name); + let i = `[^${S(r.delimiter)}]+?`, a = s.value; + if (s.type === 1 ? a = i : s.type === 0 && (a = M), !s.prefix.length && !s.suffix.length) { + s.modifier === 3 || s.modifier === 1 ? n += `(${a})${k(s.modifier)}` : n += `((?:${a})${k(s.modifier)})`; + continue; + } + if (s.modifier === 3 || s.modifier === 1) { + n += `(?:${S(s.prefix)}(${a})${S(s.suffix)})`, n += k(s.modifier); + continue; + } + n += `(?:${S(s.prefix)}`, n += `((?:${a})(?:`, n += S(s.suffix), n += S(s.prefix), n += `(?:${a}))*)${S(s.suffix)})`, s.modifier === 0 && (n += "?"); + } + let o = `[${S(r.endsWith)}]|$`, c = `[${S(r.delimiter)}]`; + if (r.end) return r.strict || (n += `${c}?`), r.endsWith.length ? n += `(?=${o})` : n += "$", new RegExp(n, X(r)); + r.strict || (n += `(?:${c}(?=${o}))?`); + let l = false; + if (e.length) { + let s = e[e.length - 1]; + s.type === 3 && s.modifier === 3 && (l = r.delimiter.indexOf(s) > -1); + } + return l || (n += `(?=${c}|${o})`), new RegExp(n, X(r)); + } + var x = { delimiter: "", prefixes: "", sensitive: true, strict: true }; + var B = { delimiter: ".", prefixes: "", sensitive: true, strict: true }; + var q = { delimiter: "/", prefixes: "/", sensitive: true, strict: true }; + function J(e, t) { + return e.length ? e[0] === "/" ? true : !t || e.length < 2 ? false : (e[0] == "\\" || e[0] == "{") && e[1] == "/" : false; + } + function Q(e, t) { + return e.startsWith(t) ? e.substring(t.length, e.length) : e; + } + function Ee(e, t) { + return e.endsWith(t) ? e.substr(0, e.length - t.length) : e; + } + function W(e) { + return !e || e.length < 2 ? false : e[0] === "[" || (e[0] === "\\" || e[0] === "{") && e[1] === "["; + } + var ee = ["ftp", "file", "http", "https", "ws", "wss"]; + function N(e) { + if (!e) return true; + for (let t of ee) if (e.test(t)) return true; + return false; + } + function te(e, t) { + if (e = Q(e, "#"), t || e === "") return e; + let r = new URL("https://example.com"); + return r.hash = e, r.hash ? r.hash.substring(1, r.hash.length) : ""; + } + function re(e, t) { + if (e = Q(e, "?"), t || e === "") return e; + let r = new URL("https://example.com"); + return r.search = e, r.search ? r.search.substring(1, r.search.length) : ""; + } + function ne(e, t) { + return t || e === "" ? e : W(e) ? j(e) : z(e); + } + function se(e, t) { + if (t || e === "") return e; + let r = new URL("https://example.com"); + return r.password = e, r.password; + } + function ie(e, t) { + if (t || e === "") return e; + let r = new URL("https://example.com"); + return r.username = e, r.username; + } + function ae(e, t, r) { + if (r || e === "") return e; + if (t && !ee.includes(t)) return new URL(`${t}:${e}`).pathname; + let n = e[0] == "/"; + return e = new URL(n ? e : "/-" + e, "https://example.com").pathname, n || (e = e.substring(2, e.length)), e; + } + function oe(e, t, r) { + return _(t) === e && (e = ""), r || e === "" ? e : K(e); + } + function ce(e, t) { + return e = Ee(e, ":"), t || e === "" ? e : y(e); + } + function _(e) { + switch (e) { + case "ws": + case "http": + return "80"; + case "wws": + case "https": + return "443"; + case "ftp": + return "21"; + default: + return ""; + } + } + function y(e) { + if (e === "") return e; + if (/^[-+.A-Za-z0-9]*$/.test(e)) return e.toLowerCase(); + throw new TypeError(`Invalid protocol '${e}'.`); + } + function le(e) { + if (e === "") return e; + let t = new URL("https://example.com"); + return t.username = e, t.username; + } + function fe(e) { + if (e === "") return e; + let t = new URL("https://example.com"); + return t.password = e, t.password; + } + function z(e) { + if (e === "") return e; + if (/[\t\n\r #%/:<>?@[\]^\\|]/g.test(e)) throw new TypeError(`Invalid hostname '${e}'`); + let t = new URL("https://example.com"); + return t.hostname = e, t.hostname; + } + function j(e) { + if (e === "") return e; + if (/[^0-9a-fA-F[\]:]/g.test(e)) throw new TypeError(`Invalid IPv6 hostname '${e}'`); + return e.toLowerCase(); + } + function K(e) { + if (e === "" || /^[0-9]*$/.test(e) && parseInt(e) <= 65535) return e; + throw new TypeError(`Invalid port '${e}'.`); + } + function he(e) { + if (e === "") return e; + let t = new URL("https://example.com"); + return t.pathname = e[0] !== "/" ? "/-" + e : e, e[0] !== "/" ? t.pathname.substring(2, t.pathname.length) : t.pathname; + } + function ue(e) { + return e === "" ? e : new URL(`data:${e}`).pathname; + } + function de(e) { + if (e === "") return e; + let t = new URL("https://example.com"); + return t.search = e, t.search.substring(1, t.search.length); + } + function pe(e) { + if (e === "") return e; + let t = new URL("https://example.com"); + return t.hash = e, t.hash.substring(1, t.hash.length); + } + var _i, _n, _t, _e, _s, _l, _o, _d, _p, _g, _H_instances, r_fn, R_fn, b_fn, u_fn, m_fn, a_fn, P_fn, E_fn, S_fn, O_fn, k_fn, x_fn, h_fn, f_fn, T_fn, A_fn, y_fn, w_fn, c_fn, C_fn, _a; + var H = (_a = class { + constructor(t) { + __privateAdd(this, _H_instances); + __privateAdd(this, _i); + __privateAdd(this, _n, []); + __privateAdd(this, _t, {}); + __privateAdd(this, _e, 0); + __privateAdd(this, _s, 1); + __privateAdd(this, _l, 0); + __privateAdd(this, _o, 0); + __privateAdd(this, _d, 0); + __privateAdd(this, _p, 0); + __privateAdd(this, _g, false); + __privateSet(this, _i, t); + } + get result() { + return __privateGet(this, _t); + } + parse() { + for (__privateSet(this, _n, v(__privateGet(this, _i), true)); __privateGet(this, _e) < __privateGet(this, _n).length; __privateSet(this, _e, __privateGet(this, _e) + __privateGet(this, _s))) { + if (__privateSet(this, _s, 1), __privateGet(this, _n)[__privateGet(this, _e)].type === "END") { + if (__privateGet(this, _o) === 0) { + __privateMethod(this, _H_instances, b_fn).call(this), __privateMethod(this, _H_instances, f_fn).call(this) ? __privateMethod(this, _H_instances, r_fn).call(this, 9, 1) : __privateMethod(this, _H_instances, h_fn).call(this) ? __privateMethod(this, _H_instances, r_fn).call(this, 8, 1) : __privateMethod(this, _H_instances, r_fn).call(this, 7, 0); + continue; + } else if (__privateGet(this, _o) === 2) { + __privateMethod(this, _H_instances, u_fn).call(this, 5); + continue; + } + __privateMethod(this, _H_instances, r_fn).call(this, 10, 0); + break; + } + if (__privateGet(this, _d) > 0) if (__privateMethod(this, _H_instances, A_fn).call(this)) __privateSet(this, _d, __privateGet(this, _d) - 1); + else continue; + if (__privateMethod(this, _H_instances, T_fn).call(this)) { + __privateSet(this, _d, __privateGet(this, _d) + 1); + continue; + } + switch (__privateGet(this, _o)) { + case 0: + __privateMethod(this, _H_instances, P_fn).call(this) && __privateMethod(this, _H_instances, u_fn).call(this, 1); + break; + case 1: + if (__privateMethod(this, _H_instances, P_fn).call(this)) { + __privateMethod(this, _H_instances, C_fn).call(this); + let t = 7, r = 1; + __privateMethod(this, _H_instances, E_fn).call(this) ? (t = 2, r = 3) : __privateGet(this, _g) && (t = 2), __privateMethod(this, _H_instances, r_fn).call(this, t, r); + } + break; + case 2: + __privateMethod(this, _H_instances, S_fn).call(this) ? __privateMethod(this, _H_instances, u_fn).call(this, 3) : (__privateMethod(this, _H_instances, x_fn).call(this) || __privateMethod(this, _H_instances, h_fn).call(this) || __privateMethod(this, _H_instances, f_fn).call(this)) && __privateMethod(this, _H_instances, u_fn).call(this, 5); + break; + case 3: + __privateMethod(this, _H_instances, O_fn).call(this) ? __privateMethod(this, _H_instances, r_fn).call(this, 4, 1) : __privateMethod(this, _H_instances, S_fn).call(this) && __privateMethod(this, _H_instances, r_fn).call(this, 5, 1); + break; + case 4: + __privateMethod(this, _H_instances, S_fn).call(this) && __privateMethod(this, _H_instances, r_fn).call(this, 5, 1); + break; + case 5: + __privateMethod(this, _H_instances, y_fn).call(this) ? __privateSet(this, _p, __privateGet(this, _p) + 1) : __privateMethod(this, _H_instances, w_fn).call(this) && __privateSet(this, _p, __privateGet(this, _p) - 1), __privateMethod(this, _H_instances, k_fn).call(this) && !__privateGet(this, _p) ? __privateMethod(this, _H_instances, r_fn).call(this, 6, 1) : __privateMethod(this, _H_instances, x_fn).call(this) ? __privateMethod(this, _H_instances, r_fn).call(this, 7, 0) : __privateMethod(this, _H_instances, h_fn).call(this) ? __privateMethod(this, _H_instances, r_fn).call(this, 8, 1) : __privateMethod(this, _H_instances, f_fn).call(this) && __privateMethod(this, _H_instances, r_fn).call(this, 9, 1); + break; + case 6: + __privateMethod(this, _H_instances, x_fn).call(this) ? __privateMethod(this, _H_instances, r_fn).call(this, 7, 0) : __privateMethod(this, _H_instances, h_fn).call(this) ? __privateMethod(this, _H_instances, r_fn).call(this, 8, 1) : __privateMethod(this, _H_instances, f_fn).call(this) && __privateMethod(this, _H_instances, r_fn).call(this, 9, 1); + break; + case 7: + __privateMethod(this, _H_instances, h_fn).call(this) ? __privateMethod(this, _H_instances, r_fn).call(this, 8, 1) : __privateMethod(this, _H_instances, f_fn).call(this) && __privateMethod(this, _H_instances, r_fn).call(this, 9, 1); + break; + case 8: + __privateMethod(this, _H_instances, f_fn).call(this) && __privateMethod(this, _H_instances, r_fn).call(this, 9, 1); + break; + case 9: + break; + case 10: + break; + } + } + __privateGet(this, _t).hostname !== void 0 && __privateGet(this, _t).port === void 0 && (__privateGet(this, _t).port = ""); + } + }, _i = new WeakMap(), _n = new WeakMap(), _t = new WeakMap(), _e = new WeakMap(), _s = new WeakMap(), _l = new WeakMap(), _o = new WeakMap(), _d = new WeakMap(), _p = new WeakMap(), _g = new WeakMap(), _H_instances = new WeakSet(), r_fn = function(t, r) { + switch (__privateGet(this, _o)) { + case 0: + break; + case 1: + __privateGet(this, _t).protocol = __privateMethod(this, _H_instances, c_fn).call(this); + break; + case 2: + break; + case 3: + __privateGet(this, _t).username = __privateMethod(this, _H_instances, c_fn).call(this); + break; + case 4: + __privateGet(this, _t).password = __privateMethod(this, _H_instances, c_fn).call(this); + break; + case 5: + __privateGet(this, _t).hostname = __privateMethod(this, _H_instances, c_fn).call(this); + break; + case 6: + __privateGet(this, _t).port = __privateMethod(this, _H_instances, c_fn).call(this); + break; + case 7: + __privateGet(this, _t).pathname = __privateMethod(this, _H_instances, c_fn).call(this); + break; + case 8: + __privateGet(this, _t).search = __privateMethod(this, _H_instances, c_fn).call(this); + break; + case 9: + __privateGet(this, _t).hash = __privateMethod(this, _H_instances, c_fn).call(this); + break; + case 10: + break; + } + __privateGet(this, _o) !== 0 && t !== 10 && ([1, 2, 3, 4].includes(__privateGet(this, _o)) && [6, 7, 8, 9].includes(t) && (__privateGet(this, _t).hostname ??= ""), [1, 2, 3, 4, 5, 6].includes(__privateGet(this, _o)) && [8, 9].includes(t) && (__privateGet(this, _t).pathname ??= __privateGet(this, _g) ? "/" : ""), [1, 2, 3, 4, 5, 6, 7].includes(__privateGet(this, _o)) && t === 9 && (__privateGet(this, _t).search ??= "")), __privateMethod(this, _H_instances, R_fn).call(this, t, r); + }, R_fn = function(t, r) { + __privateSet(this, _o, t), __privateSet(this, _l, __privateGet(this, _e) + r), __privateSet(this, _e, __privateGet(this, _e) + r), __privateSet(this, _s, 0); + }, b_fn = function() { + __privateSet(this, _e, __privateGet(this, _l)), __privateSet(this, _s, 0); + }, u_fn = function(t) { + __privateMethod(this, _H_instances, b_fn).call(this), __privateSet(this, _o, t); + }, m_fn = function(t) { + return t < 0 && (t = __privateGet(this, _n).length - t), t < __privateGet(this, _n).length ? __privateGet(this, _n)[t] : __privateGet(this, _n)[__privateGet(this, _n).length - 1]; + }, a_fn = function(t, r) { + let n = __privateMethod(this, _H_instances, m_fn).call(this, t); + return n.value === r && (n.type === "CHAR" || n.type === "ESCAPED_CHAR" || n.type === "INVALID_CHAR"); + }, P_fn = function() { + return __privateMethod(this, _H_instances, a_fn).call(this, __privateGet(this, _e), ":"); + }, E_fn = function() { + return __privateMethod(this, _H_instances, a_fn).call(this, __privateGet(this, _e) + 1, "/") && __privateMethod(this, _H_instances, a_fn).call(this, __privateGet(this, _e) + 2, "/"); + }, S_fn = function() { + return __privateMethod(this, _H_instances, a_fn).call(this, __privateGet(this, _e), "@"); + }, O_fn = function() { + return __privateMethod(this, _H_instances, a_fn).call(this, __privateGet(this, _e), ":"); + }, k_fn = function() { + return __privateMethod(this, _H_instances, a_fn).call(this, __privateGet(this, _e), ":"); + }, x_fn = function() { + return __privateMethod(this, _H_instances, a_fn).call(this, __privateGet(this, _e), "/"); + }, h_fn = function() { + if (__privateMethod(this, _H_instances, a_fn).call(this, __privateGet(this, _e), "?")) return true; + if (__privateGet(this, _n)[__privateGet(this, _e)].value !== "?") return false; + let t = __privateMethod(this, _H_instances, m_fn).call(this, __privateGet(this, _e) - 1); + return t.type !== "NAME" && t.type !== "REGEX" && t.type !== "CLOSE" && t.type !== "ASTERISK"; + }, f_fn = function() { + return __privateMethod(this, _H_instances, a_fn).call(this, __privateGet(this, _e), "#"); + }, T_fn = function() { + return __privateGet(this, _n)[__privateGet(this, _e)].type == "OPEN"; + }, A_fn = function() { + return __privateGet(this, _n)[__privateGet(this, _e)].type == "CLOSE"; + }, y_fn = function() { + return __privateMethod(this, _H_instances, a_fn).call(this, __privateGet(this, _e), "["); + }, w_fn = function() { + return __privateMethod(this, _H_instances, a_fn).call(this, __privateGet(this, _e), "]"); + }, c_fn = function() { + let t = __privateGet(this, _n)[__privateGet(this, _e)], r = __privateMethod(this, _H_instances, m_fn).call(this, __privateGet(this, _l)).index; + return __privateGet(this, _i).substring(r, t.index); + }, C_fn = function() { + let t = {}; + Object.assign(t, x), t.encodePart = y; + let r = Z(__privateMethod(this, _H_instances, c_fn).call(this), void 0, t); + __privateSet(this, _g, N(r)); + }, _a); + var G = ["protocol", "username", "password", "hostname", "port", "pathname", "search", "hash"]; + var E = "*"; + function ge(e, t) { + if (typeof e != "string") throw new TypeError("parameter 1 is not of type 'string'."); + let r = new URL(e, t); + return { protocol: r.protocol.substring(0, r.protocol.length - 1), username: r.username, password: r.password, hostname: r.hostname, port: r.port, pathname: r.pathname, search: r.search !== "" ? r.search.substring(1, r.search.length) : void 0, hash: r.hash !== "" ? r.hash.substring(1, r.hash.length) : void 0 }; + } + function b(e, t) { + return t ? C(e) : e; + } + function w(e, t, r) { + let n; + if (typeof t.baseURL == "string") try { + n = new URL(t.baseURL), t.protocol === void 0 && (e.protocol = b(n.protocol.substring(0, n.protocol.length - 1), r)), !r && t.protocol === void 0 && t.hostname === void 0 && t.port === void 0 && t.username === void 0 && (e.username = b(n.username, r)), !r && t.protocol === void 0 && t.hostname === void 0 && t.port === void 0 && t.username === void 0 && t.password === void 0 && (e.password = b(n.password, r)), t.protocol === void 0 && t.hostname === void 0 && (e.hostname = b(n.hostname, r)), t.protocol === void 0 && t.hostname === void 0 && t.port === void 0 && (e.port = b(n.port, r)), t.protocol === void 0 && t.hostname === void 0 && t.port === void 0 && t.pathname === void 0 && (e.pathname = b(n.pathname, r)), t.protocol === void 0 && t.hostname === void 0 && t.port === void 0 && t.pathname === void 0 && t.search === void 0 && (e.search = b(n.search.substring(1, n.search.length), r)), t.protocol === void 0 && t.hostname === void 0 && t.port === void 0 && t.pathname === void 0 && t.search === void 0 && t.hash === void 0 && (e.hash = b(n.hash.substring(1, n.hash.length), r)); + } catch { + throw new TypeError(`invalid baseURL '${t.baseURL}'.`); + } + if (typeof t.protocol == "string" && (e.protocol = ce(t.protocol, r)), typeof t.username == "string" && (e.username = ie(t.username, r)), typeof t.password == "string" && (e.password = se(t.password, r)), typeof t.hostname == "string" && (e.hostname = ne(t.hostname, r)), typeof t.port == "string" && (e.port = oe(t.port, e.protocol, r)), typeof t.pathname == "string") { + if (e.pathname = t.pathname, n && !J(e.pathname, r)) { + let o = n.pathname.lastIndexOf("/"); + o >= 0 && (e.pathname = b(n.pathname.substring(0, o + 1), r) + e.pathname); + } + e.pathname = ae(e.pathname, e.protocol, r); + } + return typeof t.search == "string" && (e.search = re(t.search, r)), typeof t.hash == "string" && (e.hash = te(t.hash, r)), e; + } + function C(e) { + return e.replace(/([+*?:{}()\\])/g, "\\$1"); + } + function Oe(e) { + return e.replace(/([.+*?^${}()[\]|/\\])/g, "\\$1"); + } + function ke(e, t) { + t.delimiter ??= "/#?", t.prefixes ??= "./", t.sensitive ??= false, t.strict ??= false, t.end ??= true, t.start ??= true, t.endsWith = ""; + let r = ".*", n = `[^${Oe(t.delimiter)}]+?`, o = /[$_\u200C\u200D\p{ID_Continue}]/u, c = ""; + for (let l = 0; l < e.length; ++l) { + let s = e[l]; + if (s.type === 3) { + if (s.modifier === 3) { + c += C(s.value); + continue; + } + c += `{${C(s.value)}}${k(s.modifier)}`; + continue; + } + let i = s.hasCustomName(), a = !!s.suffix.length || !!s.prefix.length && (s.prefix.length !== 1 || !t.prefixes.includes(s.prefix)), f = l > 0 ? e[l - 1] : null, d = l < e.length - 1 ? e[l + 1] : null; + if (!a && i && s.type === 1 && s.modifier === 3 && d && !d.prefix.length && !d.suffix.length) if (d.type === 3) { + let T = d.value.length > 0 ? d.value[0] : ""; + a = o.test(T); + } else a = !d.hasCustomName(); + if (!a && !s.prefix.length && f && f.type === 3) { + let T = f.value[f.value.length - 1]; + a = t.prefixes.includes(T); + } + a && (c += "{"), c += C(s.prefix), i && (c += `:${s.name}`), s.type === 2 ? c += `(${s.value})` : s.type === 1 ? i || (c += `(${n})`) : s.type === 0 && (!i && (!f || f.type === 3 || f.modifier !== 3 || a || s.prefix !== "") ? c += "*" : c += `(${r})`), s.type === 1 && i && s.suffix.length && o.test(s.suffix[0]) && (c += "\\"), c += C(s.suffix), a && (c += "}"), s.modifier !== 3 && (c += k(s.modifier)); + } + return c; + } + var _i2, _n2, _t2, _e2, _s2, _l2, _a2; + var me = (_a2 = class { + constructor(t = {}, r, n) { + __privateAdd(this, _i2); + __privateAdd(this, _n2, {}); + __privateAdd(this, _t2, {}); + __privateAdd(this, _e2, {}); + __privateAdd(this, _s2, {}); + __privateAdd(this, _l2, false); + try { + let o; + if (typeof r == "string" ? o = r : n = r, typeof t == "string") { + let i = new H(t); + if (i.parse(), t = i.result, o === void 0 && typeof t.protocol != "string") throw new TypeError("A base URL must be provided for a relative constructor string."); + t.baseURL = o; + } else { + if (!t || typeof t != "object") throw new TypeError("parameter 1 is not of type 'string' and cannot convert to dictionary."); + if (o) throw new TypeError("parameter 1 is not of type 'string'."); + } + typeof n > "u" && (n = { ignoreCase: false }); + let c = { ignoreCase: n.ignoreCase === true }, l = { pathname: E, protocol: E, username: E, password: E, hostname: E, port: E, search: E, hash: E }; + __privateSet(this, _i2, w(l, t, true)), _(__privateGet(this, _i2).protocol) === __privateGet(this, _i2).port && (__privateGet(this, _i2).port = ""); + let s; + for (s of G) { + if (!(s in __privateGet(this, _i2))) continue; + let i = {}, a = __privateGet(this, _i2)[s]; + switch (__privateGet(this, _t2)[s] = [], s) { + case "protocol": + Object.assign(i, x), i.encodePart = y; + break; + case "username": + Object.assign(i, x), i.encodePart = le; + break; + case "password": + Object.assign(i, x), i.encodePart = fe; + break; + case "hostname": + Object.assign(i, B), W(a) ? i.encodePart = j : i.encodePart = z; + break; + case "port": + Object.assign(i, x), i.encodePart = K; + break; + case "pathname": + N(__privateGet(this, _n2).protocol) ? (Object.assign(i, q, c), i.encodePart = he) : (Object.assign(i, x, c), i.encodePart = ue); + break; + case "search": + Object.assign(i, x, c), i.encodePart = de; + break; + case "hash": + Object.assign(i, x, c), i.encodePart = pe; + break; + } + try { + __privateGet(this, _s2)[s] = D(a, i), __privateGet(this, _n2)[s] = F(__privateGet(this, _s2)[s], __privateGet(this, _t2)[s], i), __privateGet(this, _e2)[s] = ke(__privateGet(this, _s2)[s], i), __privateSet(this, _l2, __privateGet(this, _l2) || __privateGet(this, _s2)[s].some((f) => f.type === 2)); + } catch { + throw new TypeError(`invalid ${s} pattern '${__privateGet(this, _i2)[s]}'.`); + } + } + } catch (o) { + throw new TypeError(`Failed to construct 'URLPattern': ${o.message}`); + } + } + test(t = {}, r) { + let n = { pathname: "", protocol: "", username: "", password: "", hostname: "", port: "", search: "", hash: "" }; + if (typeof t != "string" && r) throw new TypeError("parameter 1 is not of type 'string'."); + if (typeof t > "u") return false; + try { + typeof t == "object" ? n = w(n, t, false) : n = w(n, ge(t, r), false); + } catch { + return false; + } + let o; + for (o of G) if (!__privateGet(this, _n2)[o].exec(n[o])) return false; + return true; + } + exec(t = {}, r) { + let n = { pathname: "", protocol: "", username: "", password: "", hostname: "", port: "", search: "", hash: "" }; + if (typeof t != "string" && r) throw new TypeError("parameter 1 is not of type 'string'."); + if (typeof t > "u") return; + try { + typeof t == "object" ? n = w(n, t, false) : n = w(n, ge(t, r), false); + } catch { + return null; + } + let o = {}; + r ? o.inputs = [t, r] : o.inputs = [t]; + let c; + for (c of G) { + let l = __privateGet(this, _n2)[c].exec(n[c]); + if (!l) return null; + let s = {}; + for (let [i, a] of __privateGet(this, _t2)[c].entries()) if (typeof a == "string" || typeof a == "number") { + let f = l[i + 1]; + s[a] = f; + } + o[c] = { input: n[c] ?? "", groups: s }; + } + return o; + } + static compareComponent(t, r, n) { + let o = (i, a) => { + for (let f of ["type", "modifier", "prefix", "value", "suffix"]) { + if (i[f] < a[f]) return -1; + if (i[f] === a[f]) continue; + return 1; + } + return 0; + }, c = new R(3, "", "", "", "", 3), l = new R(0, "", "", "", "", 3), s = (i, a) => { + let f = 0; + for (; f < Math.min(i.length, a.length); ++f) { + let d = o(i[f], a[f]); + if (d) return d; + } + return i.length === a.length ? 0 : o(i[f] ?? c, a[f] ?? c); + }; + return !__privateGet(r, _e2)[t] && !__privateGet(n, _e2)[t] ? 0 : __privateGet(r, _e2)[t] && !__privateGet(n, _e2)[t] ? s(__privateGet(r, _s2)[t], [l]) : !__privateGet(r, _e2)[t] && __privateGet(n, _e2)[t] ? s([l], __privateGet(n, _s2)[t]) : s(__privateGet(r, _s2)[t], __privateGet(n, _s2)[t]); + } + get protocol() { + return __privateGet(this, _e2).protocol; + } + get username() { + return __privateGet(this, _e2).username; + } + get password() { + return __privateGet(this, _e2).password; + } + get hostname() { + return __privateGet(this, _e2).hostname; + } + get port() { + return __privateGet(this, _e2).port; + } + get pathname() { + return __privateGet(this, _e2).pathname; + } + get search() { + return __privateGet(this, _e2).search; + } + get hash() { + return __privateGet(this, _e2).hash; + } + get hasRegExpGroups() { + return __privateGet(this, _l2); + } + }, _i2 = new WeakMap(), _n2 = new WeakMap(), _t2 = new WeakMap(), _e2 = new WeakMap(), _s2 = new WeakMap(), _l2 = new WeakMap(), _a2); + + // ../node_modules/urlpattern-polyfill/index.js + if (!globalThis.URLPattern) { + globalThis.URLPattern = me; + } + // src/config-feature.js var _bundledConfig, _args; var ConfigFeature = class { @@ -3432,6 +4321,15 @@ __privateGet(this, _args).featureSettings = parseFeatureSettings(bundledConfig, enabledFeatures); } } + /** + * Call this when the top URL has changed, to recompute the site object. + * This is used to update the path matching for urlPattern. + */ + recomputeSiteObject() { + if (__privateGet(this, _args)) { + __privateGet(this, _args).site = computeLimitedSiteObject(); + } + } get args() { return __privateGet(this, _args); } @@ -3442,25 +4340,99 @@ return __privateGet(this, _args)?.featureSettings; } /** - * Given a config key, interpret the value as a list of domain overrides, and return the elements that match the current page - * Consider using patchSettings instead as per `getFeatureSetting`. + * Given a config key, interpret the value as a list of conditionals objects, and return the elements that match the current page + * Consider in your feature using patchSettings instead as per `getFeatureSetting`. * @param {string} featureKeyName * @return {any[]} * @protected */ - matchDomainFeatureSetting(featureKeyName) { - const domain = this.args?.site.domain; - if (!domain) return []; - const domains = this._getFeatureSettings()?.[featureKeyName] || []; - return domains.filter((rule) => { - if (Array.isArray(rule.domain)) { - return rule.domain.some((domainRule) => { - return matchHostname(domain, domainRule); - }); - } - return matchHostname(domain, rule.domain); + matchConditionalFeatureSetting(featureKeyName) { + const conditionalChanges = this._getFeatureSettings()?.[featureKeyName] || []; + return conditionalChanges.filter((rule) => { + let condition = rule.condition; + if (condition === void 0 && "domain" in rule) { + condition = this._domainToConditonBlocks(rule.domain); + } + return this._matchConditionalBlockOrArray(condition); }); } + /** + * Takes a list of domains and returns a list of condition blocks + * @param {string|string[]} domain + * @returns {ConditionBlock[]} + */ + _domainToConditonBlocks(domain) { + if (Array.isArray(domain)) { + return domain.map((domain2) => ({ domain: domain2 })); + } else { + return [{ domain }]; + } + } + /** + * Used to match conditional changes for a settings feature. + * @typedef {object} ConditionBlock + * @property {string[] | string} [domain] + * @property {object} [urlPattern] + */ + /** + * Takes multiple conditional blocks and returns true if any apply. + * @param {ConditionBlock|ConditionBlock[]} conditionBlock + * @returns {boolean} + */ + _matchConditionalBlockOrArray(conditionBlock) { + if (Array.isArray(conditionBlock)) { + return conditionBlock.some((block) => this._matchConditionalBlock(block)); + } + return this._matchConditionalBlock(conditionBlock); + } + /** + * Takes a conditional block and returns true if it applies. + * All conditions must be met to return true. + * @param {ConditionBlock} conditionBlock + * @returns {boolean} + */ + _matchConditionalBlock(conditionBlock) { + const conditionChecks = { + domain: this._matchDomainConditional, + urlPattern: this._matchUrlPatternConditional + }; + for (const key in conditionBlock) { + if (!conditionChecks[key]) { + return false; + } else if (!conditionChecks[key].call(this, conditionBlock)) { + return false; + } + } + return true; + } + /** + * Takes a condtion block and returns true if the current url matches the urlPattern. + * @param {ConditionBlock} conditionBlock + * @returns {boolean} + */ + _matchUrlPatternConditional(conditionBlock) { + const url = this.args?.site.url; + if (!url) return false; + if (typeof conditionBlock.urlPattern === "string") { + return new me(conditionBlock.urlPattern, url).test(url); + } + const pattern = new me(conditionBlock.urlPattern); + return pattern.test(url); + } + /** + * Takes a condition block and returns true if the current domain matches the domain. + * @param {ConditionBlock} conditionBlock + * @returns {boolean} + */ + _matchDomainConditional(conditionBlock) { + if (!conditionBlock.domain) return false; + const domain = this.args?.site.domain; + if (!domain) return false; + if (Array.isArray(conditionBlock.domain)) { + return false; + } + return matchHostname(domain, conditionBlock.domain); + } /** * Return the settings object for a feature * @param {string} [featureName] - The name of the feature to get the settings for; defaults to the name of the feature @@ -3502,40 +4474,83 @@ return result === "enabled"; } /** - * Return a specific setting from the feature settings - * If the "settings" key within the config has a "domains" key, it will be used to override the settings. - * This uses JSONPatch to apply the patches to settings before getting the setting value. - * For example.com getFeatureSettings('val') will return 1: - * ```json - * { - * "settings": { - * "domains": [ - * { - * "domain": "example.com", - * "patchSettings": [ - * { "op": "replace", "path": "/val", "value": 1 } - * ] - * } - * ] - * } - * } - * ``` - * "domain" can either be a string or an array of strings. - - * For boolean states you should consider using getFeatureSettingEnabled. - * @param {string} featureKeyName - * @param {string} [featureName] - * @returns {any} - */ + * Return a specific setting from the feature settings + * If the "settings" key within the config has a "conditionalChanges" key, it will be used to override the settings. + * This uses JSONPatch to apply the patches to settings before getting the setting value. + * For example.com getFeatureSettings('val') will return 1: + * ```json + * { + * "settings": { + * "conditionalChanges": [ + * { + * "domain": "example.com", + * "patchSettings": [ + * { "op": "replace", "path": "/val", "value": 1 } + * ] + * } + * ] + * } + * } + * ``` + * "domain" can either be a string or an array of strings. + * Additionally we support urlPattern for more complex matching. + * For example.com getFeatureSettings('val') will return 1: + * ```json + * { + * "settings": { + * "conditionalChanges": [ + * { + * "condition": { + * "urlPattern": "https://example.com/*", + * }, + * "patchSettings": [ + * { "op": "replace", "path": "/val", "value": 1 } + * ] + * } + * ] + * } + * } + * ``` + * We also support multiple conditions: + * ```json + * { + * "settings": { + * "conditionalChanges": [ + * { + * "condition": [ + * { + * "urlPattern": "https://example.com/*", + * }, + * { + * "urlPattern": "https://other.com/path/something", + * }, + * ], + * "patchSettings": [ + * { "op": "replace", "path": "/val", "value": 1 } + * ] + * } + * ] + * } + * } + * ``` + * + * For boolean states you should consider using getFeatureSettingEnabled. + * @param {string} featureKeyName + * @param {string} [featureName] + * @returns {any} + */ getFeatureSetting(featureKeyName, featureName) { let result = this._getFeatureSettings(featureName); - if (featureKeyName === "domains") { - throw new Error("domains is a reserved feature setting key name"); + if (featureKeyName in ["domains", "conditionalChanges"]) { + throw new Error(`${featureKeyName} is a reserved feature setting key name`); } - const domainMatch = [...this.matchDomainFeatureSetting("domains")].sort((a, b) => { - return a.domain.length - b.domain.length; - }); - for (const match of domainMatch) { + let conditionalMatches = []; + if (result?.conditionalChanges) { + conditionalMatches = this.matchConditionalFeatureSetting("conditionalChanges"); + } else { + conditionalMatches = this.matchConditionalFeatureSetting("domains"); + } + for (const match of conditionalMatches) { if (match.patchSettings === void 0) { continue; } @@ -3568,6 +4583,11 @@ __privateAdd(this, _messaging); /** @type {boolean} */ __privateAdd(this, _isDebugFlagSet, false); + /** + * Set this to true if you wish to listen to top level URL changes for config matching. + * @type {boolean} + */ + __publicField(this, "listenForUrlChanges", false); /** @type {ImportMeta} */ __privateAdd(this, _importConfig); this.setArgs(this.args); @@ -3733,7 +4753,7 @@ this.messaging?.notify("addDebugFlag", { flag: this.name }); - } catch (_e) { + } catch (_e3) { } } /** @@ -3744,17 +4764,17 @@ * @param {import('./wrapper-utils').StrictPropertyDescriptor} descriptor - requires all descriptor options to be defined because we can't validate correctness based on TS types */ defineProperty(object, propertyName, descriptor) { - ["value", "get", "set"].forEach((k) => { - const descriptorProp = descriptor[k]; + ["value", "get", "set"].forEach((k2) => { + const descriptorProp = descriptor[k2]; if (typeof descriptorProp === "function") { const addDebugFlag = this.addDebugFlag.bind(this); const wrapper = new Proxy2(descriptorProp, { - apply(_, thisArg, argumentsList) { + apply(_2, thisArg, argumentsList) { addDebugFlag(); return Reflect2.apply(descriptorProp, thisArg, argumentsList); } }); - descriptor[k] = wrapToString(wrapper, descriptorProp); + descriptor[k2] = wrapToString(wrapper, descriptorProp); } }); return defineProperty(object, propertyName, descriptor); @@ -3945,27 +4965,27 @@ if (typeof input !== "string") return false; return input.trim().length > 0; } - function matchingPair(a, b) { + function matchingPair(a, b2) { if (!nonEmptyString(a)) return false; - if (!nonEmptyString(b)) return false; - return a.toLowerCase().trim() === b.toLowerCase().trim(); + if (!nonEmptyString(b2)) return false; + return a.toLowerCase().trim() === b2.toLowerCase().trim(); } function sortAddressesByStateAndCity(addresses) { - return addresses.sort((a, b) => { - if (a.state < b.state) { + return addresses.sort((a, b2) => { + if (a.state < b2.state) { return -1; } - if (a.state > b.state) { + if (a.state > b2.state) { return 1; } - return a.city.localeCompare(b.city); + return a.city.localeCompare(b2.city); }); } async function hashObject(profile) { const msgUint8 = new TextEncoder().encode(JSON.stringify(profile)); const hashBuffer = await crypto.subtle.digest("SHA-1", msgUint8); const hashArray = Array.from(new Uint8Array(hashBuffer)); - const hashHex = hashArray.map((b) => b.toString(16).padStart(2, "0")).join(""); + const hashHex = hashArray.map((b2) => b2.toString(16).padStart(2, "0")).join(""); return hashHex; } @@ -5577,7 +6597,7 @@ * @returns {string[]} */ extract(strs, extractorParams) { - return strs.map((x) => stringToList(x, extractorParams.separator)).flat(); + return strs.map((x2) => stringToList(x2, extractorParams.separator)).flat(); } }; @@ -5649,7 +6669,7 @@ * @param {import('../actions/extract.js').ExtractorParams} extractorParams */ extract(strs, extractorParams) { - return strs.map((x) => stringToList(x, extractorParams.separator)).flat().map((x) => x.split(",")[0]); + return strs.map((x2) => stringToList(x2, extractorParams.separator)).flat().map((x2) => x2.split(",")[0]); } }; @@ -5713,7 +6733,7 @@ if ("error" in extractResult) { return new ErrorResponse({ actionID: action.id, message: extractResult.error }); } - const filteredPromises = extractResult.results.filter((x) => x.result === true).map((x) => aggregateFields(x.scrapedData)).map((profile) => applyPostTransforms(profile, action.profile)); + const filteredPromises = extractResult.results.filter((x2) => x2.result === true).map((x2) => aggregateFields(x2.scrapedData)).map((profile) => applyPostTransforms(profile, action.profile)); const filtered = await Promise.all(filteredPromises); const debugResults = extractResult.results.map((result) => result.asData()); return new SuccessResponse({ @@ -5739,7 +6759,7 @@ } return { results: profilesElementList.map((element) => { - const elementFactory = (_, value) => { + const elementFactory = (_2, value) => { return value?.findElements ? cleanArray(getElements(element, value.selector)) : cleanArray(getElement(element, value.selector) || getElementMatches(element, value.selector)); }; const scrapedData = createProfile(elementFactory, action.profile); @@ -5832,7 +6852,7 @@ const addresses = sortAddressesByStateAndCity([...addressMap.values()]); const phoneArray = profile.phone || []; const phoneListArray = profile.phoneList || []; - const phoneNumbers = [.../* @__PURE__ */ new Set([...phoneArray, ...phoneListArray])].sort((a, b) => parseInt(a) - parseInt(b)); + const phoneNumbers = [.../* @__PURE__ */ new Set([...phoneArray, ...phoneListArray])].sort((a, b2) => parseInt(a) - parseInt(b2)); const relatives = [...new Set(profile.relativesList)].sort(); const alternativeNames = [...new Set(profile.alternativeNamesList)].sort(); return { @@ -5975,8 +6995,8 @@ if (!userData) return new ErrorResponse({ actionID: action.id, message: "user data was absent" }); form.scrollIntoView?.(); const results = fillMany(form, action.elements, userData); - const errors = results.filter((x) => x.result === false).map((x) => { - if ("error" in x) return x.error; + const errors = results.filter((x2) => x2.result === false).map((x2) => { + if ("error" in x2) return x2.error; return "unknown error"; }); if (errors.length > 0) { @@ -6144,7 +7164,7 @@ ["defaultIfEmpty", (value, argument) => value || argument || ""], [ "ageRange", - (value, _, action) => { + (value, _2, action) => { if (!action.ageRange) return value; const ageNumber = Number(value); const ageRange = action.ageRange.find((range) => { @@ -6166,7 +7186,7 @@ return pathname.split("/").filter(Boolean).map((segment) => processTemplateStringWithUserData(segment, action, userData)).join("/"); } function processTemplateStringWithUserData(input, action, userData) { - return String(input).replace(/\$%7B(.+?)%7D|\$\{(.+?)}/g, (_, encodedValue, plainValue) => { + return String(input).replace(/\$%7B(.+?)%7D|\$\{(.+?)}/g, (_2, encodedValue, plainValue) => { const comparison = encodedValue ?? plainValue; const [dataKey, ...transforms] = comparison.split(/\||%7C/); const data2 = userData[dataKey]; @@ -6251,7 +7271,7 @@ if (clickElement.parent.profileMatch) { const extraction = extractProfiles(clickElement.parent.profileMatch, userData, root); if ("results" in extraction) { - const sorted = extraction.results.filter((x) => x.result === true).sort((a, b) => b.score - a.score); + const sorted = extraction.results.filter((x2) => x2.result === true).sort((a, b2) => b2.score - a.score); const first = sorted[0]; if (first && first.element) { return first.element; @@ -6265,18 +7285,18 @@ case "=": case "==": case "===": - return (a, b) => a === b; + return (a, b2) => a === b2; case "!=": case "!==": - return (a, b) => a !== b; + return (a, b2) => a !== b2; case "<": - return (a, b) => a < b; + return (a, b2) => a < b2; case "<=": - return (a, b) => a <= b; + return (a, b2) => a <= b2; case ">": - return (a, b) => a > b; + return (a, b2) => a > b2; case ">=": - return (a, b) => a >= b; + return (a, b2) => a >= b2; default: throw new Error(`Invalid operator: ${operator}`); } @@ -6335,17 +7355,17 @@ init_define_import_meta_trackerLookup(); function expectation(action, root = document) { const results = expectMany(action.expectations, root); - const errors = results.filter((x, index) => { - if (x.result === true) return false; + const errors = results.filter((x2, index) => { + if (x2.result === true) return false; if (action.expectations[index].failSilently) return false; return true; - }).map((x) => { - return "error" in x ? x.error : "unknown error"; + }).map((x2) => { + return "error" in x2 ? x2.error : "unknown error"; }); if (errors.length > 0) { return new ErrorResponse({ actionID: action.id, message: errors.join(", ") }); } - const runActions = results.every((x) => x.result === true); + const runActions = results.every((x2) => x2.result === true); if (action.actions?.length && runActions) { return new SuccessResponse({ actionID: action.id, @@ -7064,7 +8084,7 @@ return { error: "Error: No url provided." }; } try { - const _ = new URL(action.url); + const _2 = new URL(action.url); } catch (e) { return { error: "Error: Invalid URL provided." }; } @@ -7169,11 +8189,11 @@ const { results, exceptions } = await this.exec(action, data2); if (results) { const parent = results[0]; - const errors = results.filter((x) => "error" in x); + const errors = results.filter((x2) => "error" in x2); if (results.length === 1 || errors.length === 0) { return this.messaging.notify("actionCompleted", { result: parent }); } - const joinedErrors = errors.map((x) => x.error.message).join(", "); + const joinedErrors = errors.map((x2) => x2.error.message).join(", "); const response = new ErrorResponse({ actionID: action.id, message: "Secondary actions failed: " + joinedErrors @@ -7228,7 +8248,7 @@ }; } if (!retryConfig && action.actionType === "expectation") { - if (action.expectations.some((x) => x.type === "element")) { + if (action.expectations.some((x2) => x2.type === "element")) { return { interval: { ms: 1e3 }, maxAttempts: 30 @@ -7244,6 +8264,44 @@ ddg_feature_brokerProtection: BrokerProtection }; + // src/url-change.js + init_define_import_meta_trackerLookup(); + var urlChangeListeners = /* @__PURE__ */ new Set(); + function registerForURLChanges(listener) { + if (urlChangeListeners.size === 0) { + listenForURLChanges(); + } + urlChangeListeners.add(listener); + } + function handleURLChange() { + for (const listener of urlChangeListeners) { + listener(); + } + } + function listenForURLChanges() { + const urlChangedInstance = new ContentFeature("urlChanged", {}, {}); + if ("navigation" in globalThis && "addEventListener" in globalThis.navigation) { + globalThis.navigation.addEventListener("navigatesuccess", () => { + handleURLChange(); + }); + return; + } + if (isBeingFramed()) { + return; + } + const historyMethodProxy = new DDGProxy(urlChangedInstance, History.prototype, "pushState", { + apply(target, thisArg, args) { + const changeResult = DDGReflect.apply(target, thisArg, args); + handleURLChange(); + return changeResult; + } + }); + historyMethodProxy.overload(); + window.addEventListener("popstate", () => { + handleURLChange(); + }); + } + // src/content-scope-features.js var initArgs = null; var updates = []; @@ -7284,6 +8342,12 @@ resolvedFeatures.forEach(({ featureInstance, featureName }) => { if (!isFeatureBroken(args, featureName) || alwaysInitExtensionFeatures(args, featureName)) { featureInstance.callInit(args); + if (featureInstance.listenForUrlChanges || featureInstance.urlChanged) { + registerForURLChanges(() => { + featureInstance.recomputeSiteObject(); + featureInstance?.urlChanged(); + }); + } } }); while (updates.length) { diff --git a/node_modules/@duckduckgo/content-scope-scripts/build/android/contentScope.js b/node_modules/@duckduckgo/content-scope-scripts/build/android/contentScope.js index 2ed919ebe368..878228b9de66 100644 --- a/node_modules/@duckduckgo/content-scope-scripts/build/android/contentScope.js +++ b/node_modules/@duckduckgo/content-scope-scripts/build/android/contentScope.js @@ -42,6 +42,7 @@ var __privateGet = (obj, member, getter) => (__accessCheck(obj, member, "read from private field"), getter ? getter.call(obj) : member.get(obj)); var __privateAdd = (obj, member, value) => member.has(obj) ? __typeError("Cannot add the same private member more than once") : member instanceof WeakSet ? member.add(obj) : member.set(obj, value); var __privateSet = (obj, member, value, setter) => (__accessCheck(obj, member, "write to private field"), setter ? setter.call(obj, value) : member.set(obj, value), value); + var __privateMethod = (obj, member, method) => (__accessCheck(obj, member, "access private method"), method); // var define_import_meta_trackerLookup_default; @@ -76,28 +77,28 @@ //! THE SOFTWARE. (function(global, module2, define2) { function Alea(seed) { - var me = this, mash = Mash(); - me.next = function() { - var t = 2091639 * me.s0 + me.c * 23283064365386963e-26; - me.s0 = me.s1; - me.s1 = me.s2; - return me.s2 = t - (me.c = t | 0); + var me2 = this, mash = Mash(); + me2.next = function() { + var t = 2091639 * me2.s0 + me2.c * 23283064365386963e-26; + me2.s0 = me2.s1; + me2.s1 = me2.s2; + return me2.s2 = t - (me2.c = t | 0); }; - me.c = 1; - me.s0 = mash(" "); - me.s1 = mash(" "); - me.s2 = mash(" "); - me.s0 -= mash(seed); - if (me.s0 < 0) { - me.s0 += 1; + me2.c = 1; + me2.s0 = mash(" "); + me2.s1 = mash(" "); + me2.s2 = mash(" "); + me2.s0 -= mash(seed); + if (me2.s0 < 0) { + me2.s0 += 1; } - me.s1 -= mash(seed); - if (me.s1 < 0) { - me.s1 += 1; + me2.s1 -= mash(seed); + if (me2.s1 < 0) { + me2.s1 += 1; } - me.s2 -= mash(seed); - if (me.s2 < 0) { - me.s2 += 1; + me2.s2 -= mash(seed); + if (me2.s2 < 0) { + me2.s2 += 1; } mash = null; } @@ -168,26 +169,26 @@ init_define_import_meta_trackerLookup(); (function(global, module2, define2) { function XorGen(seed) { - var me = this, strseed = ""; - me.x = 0; - me.y = 0; - me.z = 0; - me.w = 0; - me.next = function() { - var t = me.x ^ me.x << 11; - me.x = me.y; - me.y = me.z; - me.z = me.w; - return me.w ^= me.w >>> 19 ^ t ^ t >>> 8; + var me2 = this, strseed = ""; + me2.x = 0; + me2.y = 0; + me2.z = 0; + me2.w = 0; + me2.next = function() { + var t = me2.x ^ me2.x << 11; + me2.x = me2.y; + me2.y = me2.z; + me2.z = me2.w; + return me2.w ^= me2.w >>> 19 ^ t ^ t >>> 8; }; if (seed === (seed | 0)) { - me.x = seed; + me2.x = seed; } else { strseed += seed; } - for (var k = 0; k < strseed.length + 64; k++) { - me.x ^= strseed.charCodeAt(k) | 0; - me.next(); + for (var k2 = 0; k2 < strseed.length + 64; k2++) { + me2.x ^= strseed.charCodeAt(k2) | 0; + me2.next(); } } function copy2(f, t) { @@ -242,31 +243,31 @@ init_define_import_meta_trackerLookup(); (function(global, module2, define2) { function XorGen(seed) { - var me = this, strseed = ""; - me.next = function() { - var t = me.x ^ me.x >>> 2; - me.x = me.y; - me.y = me.z; - me.z = me.w; - me.w = me.v; - return (me.d = me.d + 362437 | 0) + (me.v = me.v ^ me.v << 4 ^ (t ^ t << 1)) | 0; + var me2 = this, strseed = ""; + me2.next = function() { + var t = me2.x ^ me2.x >>> 2; + me2.x = me2.y; + me2.y = me2.z; + me2.z = me2.w; + me2.w = me2.v; + return (me2.d = me2.d + 362437 | 0) + (me2.v = me2.v ^ me2.v << 4 ^ (t ^ t << 1)) | 0; }; - me.x = 0; - me.y = 0; - me.z = 0; - me.w = 0; - me.v = 0; + me2.x = 0; + me2.y = 0; + me2.z = 0; + me2.w = 0; + me2.v = 0; if (seed === (seed | 0)) { - me.x = seed; + me2.x = seed; } else { strseed += seed; } - for (var k = 0; k < strseed.length + 64; k++) { - me.x ^= strseed.charCodeAt(k) | 0; - if (k == strseed.length) { - me.d = me.x << 10 ^ me.x >>> 4; + for (var k2 = 0; k2 < strseed.length + 64; k2++) { + me2.x ^= strseed.charCodeAt(k2) | 0; + if (k2 == strseed.length) { + me2.d = me2.x << 10 ^ me2.x >>> 4; } - me.next(); + me2.next(); } } function copy2(f, t) { @@ -323,46 +324,46 @@ init_define_import_meta_trackerLookup(); (function(global, module2, define2) { function XorGen(seed) { - var me = this; - me.next = function() { - var X = me.x, i = me.i, t, v, w; - t = X[i]; + var me2 = this; + me2.next = function() { + var X2 = me2.x, i = me2.i, t, v2, w2; + t = X2[i]; t ^= t >>> 7; - v = t ^ t << 24; - t = X[i + 1 & 7]; - v ^= t ^ t >>> 10; - t = X[i + 3 & 7]; - v ^= t ^ t >>> 3; - t = X[i + 4 & 7]; - v ^= t ^ t << 7; - t = X[i + 7 & 7]; + v2 = t ^ t << 24; + t = X2[i + 1 & 7]; + v2 ^= t ^ t >>> 10; + t = X2[i + 3 & 7]; + v2 ^= t ^ t >>> 3; + t = X2[i + 4 & 7]; + v2 ^= t ^ t << 7; + t = X2[i + 7 & 7]; t = t ^ t << 13; - v ^= t ^ t << 9; - X[i] = v; - me.i = i + 1 & 7; - return v; + v2 ^= t ^ t << 9; + X2[i] = v2; + me2.i = i + 1 & 7; + return v2; }; - function init2(me2, seed2) { - var j, w, X = []; + function init2(me3, seed2) { + var j2, w2, X2 = []; if (seed2 === (seed2 | 0)) { - w = X[0] = seed2; + w2 = X2[0] = seed2; } else { seed2 = "" + seed2; - for (j = 0; j < seed2.length; ++j) { - X[j & 7] = X[j & 7] << 15 ^ seed2.charCodeAt(j) + X[j + 1 & 7] << 13; + for (j2 = 0; j2 < seed2.length; ++j2) { + X2[j2 & 7] = X2[j2 & 7] << 15 ^ seed2.charCodeAt(j2) + X2[j2 + 1 & 7] << 13; } } - while (X.length < 8) X.push(0); - for (j = 0; j < 8 && X[j] === 0; ++j) ; - if (j == 8) w = X[7] = -1; - else w = X[j]; - me2.x = X; - me2.i = 0; - for (j = 256; j > 0; --j) { - me2.next(); + while (X2.length < 8) X2.push(0); + for (j2 = 0; j2 < 8 && X2[j2] === 0; ++j2) ; + if (j2 == 8) w2 = X2[7] = -1; + else w2 = X2[j2]; + me3.x = X2; + me3.i = 0; + for (j2 = 256; j2 > 0; --j2) { + me3.next(); } } - init2(me, seed); + init2(me2, seed); } function copy2(f, t) { t.x = f.x.slice(); @@ -415,61 +416,61 @@ init_define_import_meta_trackerLookup(); (function(global, module2, define2) { function XorGen(seed) { - var me = this; - me.next = function() { - var w = me.w, X = me.X, i = me.i, t, v; - me.w = w = w + 1640531527 | 0; - v = X[i + 34 & 127]; - t = X[i = i + 1 & 127]; - v ^= v << 13; + var me2 = this; + me2.next = function() { + var w2 = me2.w, X2 = me2.X, i = me2.i, t, v2; + me2.w = w2 = w2 + 1640531527 | 0; + v2 = X2[i + 34 & 127]; + t = X2[i = i + 1 & 127]; + v2 ^= v2 << 13; t ^= t << 17; - v ^= v >>> 15; + v2 ^= v2 >>> 15; t ^= t >>> 12; - v = X[i] = v ^ t; - me.i = i; - return v + (w ^ w >>> 16) | 0; + v2 = X2[i] = v2 ^ t; + me2.i = i; + return v2 + (w2 ^ w2 >>> 16) | 0; }; - function init2(me2, seed2) { - var t, v, i, j, w, X = [], limit = 128; + function init2(me3, seed2) { + var t, v2, i, j2, w2, X2 = [], limit = 128; if (seed2 === (seed2 | 0)) { - v = seed2; + v2 = seed2; seed2 = null; } else { seed2 = seed2 + "\0"; - v = 0; + v2 = 0; limit = Math.max(limit, seed2.length); } - for (i = 0, j = -32; j < limit; ++j) { - if (seed2) v ^= seed2.charCodeAt((j + 32) % seed2.length); - if (j === 0) w = v; - v ^= v << 10; - v ^= v >>> 15; - v ^= v << 4; - v ^= v >>> 13; - if (j >= 0) { - w = w + 1640531527 | 0; - t = X[j & 127] ^= v + w; + for (i = 0, j2 = -32; j2 < limit; ++j2) { + if (seed2) v2 ^= seed2.charCodeAt((j2 + 32) % seed2.length); + if (j2 === 0) w2 = v2; + v2 ^= v2 << 10; + v2 ^= v2 >>> 15; + v2 ^= v2 << 4; + v2 ^= v2 >>> 13; + if (j2 >= 0) { + w2 = w2 + 1640531527 | 0; + t = X2[j2 & 127] ^= v2 + w2; i = 0 == t ? i + 1 : 0; } } if (i >= 128) { - X[(seed2 && seed2.length || 0) & 127] = -1; + X2[(seed2 && seed2.length || 0) & 127] = -1; } i = 127; - for (j = 4 * 128; j > 0; --j) { - v = X[i + 34 & 127]; - t = X[i = i + 1 & 127]; - v ^= v << 13; + for (j2 = 4 * 128; j2 > 0; --j2) { + v2 = X2[i + 34 & 127]; + t = X2[i = i + 1 & 127]; + v2 ^= v2 << 13; t ^= t << 17; - v ^= v >>> 15; + v2 ^= v2 >>> 15; t ^= t >>> 12; - X[i] = v ^ t; + X2[i] = v2 ^ t; } - me2.w = w; - me2.X = X; - me2.i = i; + me3.w = w2; + me3.X = X2; + me3.i = i; } - init2(me, seed); + init2(me2, seed); } function copy2(f, t) { t.i = f.i; @@ -525,31 +526,31 @@ init_define_import_meta_trackerLookup(); (function(global, module2, define2) { function XorGen(seed) { - var me = this, strseed = ""; - me.next = function() { - var b = me.b, c = me.c, d = me.d, a = me.a; - b = b << 25 ^ b >>> 7 ^ c; + var me2 = this, strseed = ""; + me2.next = function() { + var b2 = me2.b, c = me2.c, d = me2.d, a = me2.a; + b2 = b2 << 25 ^ b2 >>> 7 ^ c; c = c - d | 0; d = d << 24 ^ d >>> 8 ^ a; - a = a - b | 0; - me.b = b = b << 20 ^ b >>> 12 ^ c; - me.c = c = c - d | 0; - me.d = d << 16 ^ c >>> 16 ^ a; - return me.a = a - b | 0; + a = a - b2 | 0; + me2.b = b2 = b2 << 20 ^ b2 >>> 12 ^ c; + me2.c = c = c - d | 0; + me2.d = d << 16 ^ c >>> 16 ^ a; + return me2.a = a - b2 | 0; }; - me.a = 0; - me.b = 0; - me.c = 2654435769 | 0; - me.d = 1367130551; + me2.a = 0; + me2.b = 0; + me2.c = 2654435769 | 0; + me2.d = 1367130551; if (seed === Math.floor(seed)) { - me.a = seed / 4294967296 | 0; - me.b = seed | 0; + me2.a = seed / 4294967296 | 0; + me2.b = seed | 0; } else { strseed += seed; } - for (var k = 0; k < strseed.length + 20; k++) { - me.b ^= strseed.charCodeAt(k) | 0; - me.next(); + for (var k2 = 0; k2 < strseed.length + 20; k2++) { + me2.b ^= strseed.charCodeAt(k2) | 0; + me2.next(); } } function copy2(f, t) { @@ -644,18 +645,18 @@ ), key); var arc4 = new ARC4(key); var prng = function() { - var n = arc4.g(chunks), d = startdenom, x = 0; + var n = arc4.g(chunks), d = startdenom, x2 = 0; while (n < significance) { - n = (n + x) * width; + n = (n + x2) * width; d *= width; - x = arc4.g(1); + x2 = arc4.g(1); } while (n >= overflow) { n /= 2; d /= 2; - x >>>= 1; + x2 >>>= 1; } - return (n + x) / d; + return (n + x2) / d; }; prng.int32 = function() { return arc4.g(4) | 0; @@ -686,7 +687,7 @@ ); } function ARC4(key) { - var t, keylen = key.length, me = this, i = 0, j = me.i = me.j = 0, s = me.S = []; + var t, keylen = key.length, me2 = this, i = 0, j2 = me2.i = me2.j = 0, s = me2.S = []; if (!keylen) { key = [keylen++]; } @@ -694,17 +695,17 @@ s[i] = i++; } for (i = 0; i < width; i++) { - s[i] = s[j = mask & j + key[i % keylen] + (t = s[i])]; - s[j] = t; + s[i] = s[j2 = mask & j2 + key[i % keylen] + (t = s[i])]; + s[j2] = t; } - (me.g = function(count) { - var t2, r = 0, i2 = me.i, j2 = me.j, s2 = me.S; + (me2.g = function(count) { + var t2, r = 0, i2 = me2.i, j3 = me2.j, s2 = me2.S; while (count--) { t2 = s2[i2 = mask & i2 + 1]; - r = r * width + s2[mask & (s2[i2] = s2[j2 = mask & j2 + t2]) + (s2[j2] = t2)]; + r = r * width + s2[mask & (s2[i2] = s2[j3 = mask & j3 + t2]) + (s2[j3] = t2)]; } - me.i = i2; - me.j = j2; + me2.i = i2; + me2.j = j3; return r; })(width); } @@ -728,9 +729,9 @@ return result.length ? result : typ == "string" ? obj : obj + "\0"; } function mixkey(seed, key) { - var stringseed = seed + "", smear, j = 0; - while (j < stringseed.length) { - key[mask & j] = mask & (smear ^= key[mask & j] * 19) + stringseed.charCodeAt(j++); + var stringseed = seed + "", smear, j2 = 0; + while (j2 < stringseed.length) { + key[mask & j2] = mask & (smear ^= key[mask & j2] * 19) + stringseed.charCodeAt(j2++); } return tostring(key); } @@ -888,8 +889,8 @@ function getGlobal() { return globalObj; } - function nextRandom(v) { - return Math.abs(v >> 1 | (v << 62 ^ v << 61) & ~(~0 << 63) << 62); + function nextRandom(v2) { + return Math.abs(v2 >> 1 | (v2 << 62 ^ v2 << 61) & ~(~0 << 63) << 62); } var exemptionLists = {}; function shouldExemptUrl(type, url) { @@ -917,22 +918,30 @@ } return globalThis.top !== globalThis.window; } - function getTabHostname() { - let framingOrigin = null; + function getTabUrl() { + let framingURLString = null; try { - framingOrigin = globalThis.top.location.href; + framingURLString = globalThis.top.location.href; } catch { - framingOrigin = globalThis.document.referrer; - } - if ("ancestorOrigins" in globalThis.location && globalThis.location.ancestorOrigins.length) { - framingOrigin = globalThis.location.ancestorOrigins.item(globalThis.location.ancestorOrigins.length - 1); + framingURLString = getTopLevelOriginFromFrameAncestors() ?? globalThis.document.referrer; } + let framingURL; try { - framingOrigin = new URL(framingOrigin).hostname; + framingURL = new URL(framingURLString); } catch { - framingOrigin = null; + framingURL = null; } - return framingOrigin; + return framingURL; + } + function getTopLevelOriginFromFrameAncestors() { + if ("ancestorOrigins" in globalThis.location && globalThis.location.ancestorOrigins.length) { + return globalThis.location.ancestorOrigins.item(globalThis.location.ancestorOrigins.length - 1); + } + return null; + } + function getTabHostname() { + const topURLString = getTabUrl()?.hostname; + return topURLString || null; } function matchHostname(hostname, exceptionDomain) { return hostname === exceptionDomain || hostname.endsWith(`.${exceptionDomain}`); @@ -977,7 +986,7 @@ let item = key.charCodeAt(0); for (const i in key) { let byte = key.charCodeAt(i); - for (let j = 8; j >= 0; j--) { + for (let j2 = 8; j2 >= 0; j2--) { const res = callback(item, byte); if (res === null) { return; @@ -991,7 +1000,7 @@ return isPlatformSpecificFeature(feature) ? !args.site.enabledFeatures.includes(feature) : args.site.isBroken || args.site.allowlisted || !args.site.enabledFeatures.includes(feature); } function camelcase(dashCaseText) { - return dashCaseText.replace(/-(.)/g, (_, letter) => { + return dashCaseText.replace(/-(.)/g, (_2, letter) => { return letter.toUpperCase(); }); } @@ -1174,9 +1183,10 @@ return unprotectedDomain; } function computeLimitedSiteObject() { - const topLevelHostname = getTabHostname(); + const tabURL = getTabUrl(); return { - domain: topLevelHostname + domain: tabURL?.hostname || null, + url: tabURL?.href || null }; } function getPlatformVersion(preferences) { @@ -1493,13 +1503,13 @@ * @return {Number} The requested slice. */ extract: function(a, bstart, blength) { - var x, sh = Math.floor(-bstart - blength & 31); + var x2, sh = Math.floor(-bstart - blength & 31); if ((bstart + blength - 1 ^ bstart) & -32) { - x = a[bstart / 32 | 0] << 32 - sh ^ a[bstart / 32 + 1 | 0] >>> sh; + x2 = a[bstart / 32 | 0] << 32 - sh ^ a[bstart / 32 + 1 | 0] >>> sh; } else { - x = a[bstart / 32 | 0] >>> sh; + x2 = a[bstart / 32 | 0] >>> sh; } - return x & (1 << blength) - 1; + return x2 & (1 << blength) - 1; }, /** * Concatenate two bit arrays. @@ -1524,12 +1534,12 @@ * @return {Number} The length of a, in bits. */ bitLength: function(a) { - var l = a.length, x; + var l = a.length, x2; if (l === 0) { return 0; } - x = a[l - 1]; - return (l - 1) * 32 + sjcl2.bitArray.getPartial(x); + x2 = a[l - 1]; + return (l - 1) * 32 + sjcl2.bitArray.getPartial(x2); }, /** * Truncate an array. @@ -1556,19 +1566,19 @@ * @param {Number} [_end=0] Pass 1 if x has already been shifted to the high side. * @return {Number} The partial word. */ - partial: function(len, x, _end) { + partial: function(len, x2, _end) { if (len === 32) { - return x; + return x2; } - return (_end ? x | 0 : x << 32 - len) + len * 1099511627776; + return (_end ? x2 | 0 : x2 << 32 - len) + len * 1099511627776; }, /** * Get the number of bits used by a partial word. * @param {Number} x The partial word. * @return {Number} The number of bits used by the partial word. */ - getPartial: function(x) { - return Math.round(x / 1099511627776) || 32; + getPartial: function(x2) { + return Math.round(x2 / 1099511627776) || 32; }, /** * Compare two arrays for equality in a predictable amount of time. @@ -1576,15 +1586,15 @@ * @param {bitArray} b The second array. * @return {boolean} true if a == b; false otherwise. */ - equal: function(a, b) { - if (sjcl2.bitArray.bitLength(a) !== sjcl2.bitArray.bitLength(b)) { + equal: function(a, b2) { + if (sjcl2.bitArray.bitLength(a) !== sjcl2.bitArray.bitLength(b2)) { return false; } - var x = 0, i; + var x2 = 0, i; for (i = 0; i < a.length; i++) { - x |= a[i] ^ b[i]; + x2 |= a[i] ^ b2[i]; } - return x === 0; + return x2 === 0; }, /** Shift an array right. * @param {bitArray} a The array to shift. @@ -1617,8 +1627,8 @@ /** xor a block of 4 words together. * @private */ - _xor4: function(x, y) { - return [x[0] ^ y[0], x[1] ^ y[1], x[2] ^ y[2], x[3] ^ y[3]]; + _xor4: function(x2, y2) { + return [x2[0] ^ y2[0], x2[1] ^ y2[1], x2[2] ^ y2[2], x2[3] ^ y2[3]]; }, /** byteswap a word array inplace. * (does not handle partial words) @@ -1626,10 +1636,10 @@ * @return {sjcl.bitArray} byteswapped array */ byteswapM: function(a) { - var i, v, m = 65280; + var i, v2, m = 65280; for (i = 0; i < a.length; ++i) { - v = a[i]; - a[i] = v >>> 24 | v >>> 8 & m | (v & m) << 8 | v << 24; + v2 = a[i]; + a[i] = v2 >>> 24 | v2 >>> 8 & m | (v2 & m) << 8 | v2 << 24; } return a; } @@ -1725,21 +1735,21 @@ if (typeof data === "string") { data = sjcl2.codec.utf8String.toBits(data); } - var i, b = this._buffer = sjcl2.bitArray.concat(this._buffer, data), ol = this._length, nl = this._length = ol + sjcl2.bitArray.bitLength(data); + var i, b2 = this._buffer = sjcl2.bitArray.concat(this._buffer, data), ol = this._length, nl = this._length = ol + sjcl2.bitArray.bitLength(data); if (nl > 9007199254740991) { throw new sjcl2.exception.invalid("Cannot hash more than 2^53 - 1 bits"); } if (typeof Uint32Array !== "undefined") { - var c = new Uint32Array(b); - var j = 0; + var c = new Uint32Array(b2); + var j2 = 0; for (i = 512 + ol - (512 + ol & 511); i <= nl; i += 512) { - this._block(c.subarray(16 * j, 16 * (j + 1))); - j += 1; + this._block(c.subarray(16 * j2, 16 * (j2 + 1))); + j2 += 1; } - b.splice(0, 16 * j); + b2.splice(0, 16 * j2); } else { for (i = 512 + ol - (512 + ol & 511); i <= nl; i += 512) { - this._block(b.splice(0, 16)); + this._block(b2.splice(0, 16)); } } return this; @@ -1749,15 +1759,15 @@ * @return {bitArray} The hash value, an array of 8 big-endian words. */ finalize: function() { - var i, b = this._buffer, h = this._h; - b = sjcl2.bitArray.concat(b, [sjcl2.bitArray.partial(1, 1)]); - for (i = b.length + 2; i & 15; i++) { - b.push(0); + var i, b2 = this._buffer, h = this._h; + b2 = sjcl2.bitArray.concat(b2, [sjcl2.bitArray.partial(1, 1)]); + for (i = b2.length + 2; i & 15; i++) { + b2.push(0); } - b.push(Math.floor(this._length / 4294967296)); - b.push(this._length | 0); - while (b.length) { - this._block(b.splice(0, 16)); + b2.push(Math.floor(this._length / 4294967296)); + b2.push(this._length | 0); + while (b2.length) { + this._block(b2.splice(0, 16)); } this.reset(); return h; @@ -1792,8 +1802,8 @@ */ _precompute: function() { var i = 0, prime = 2, factor, isPrime; - function frac(x) { - return (x - Math.floor(x)) * 4294967296 | 0; + function frac(x2) { + return (x2 - Math.floor(x2)) * 4294967296 | 0; } for (; i < 64; prime++) { isPrime = true; @@ -1817,17 +1827,17 @@ * @param {Uint32Array|bitArray} w one block of words. * @private */ - _block: function(w) { - var i, tmp, a, b, h = this._h, k = this._key, h0 = h[0], h1 = h[1], h2 = h[2], h3 = h[3], h4 = h[4], h5 = h[5], h6 = h[6], h7 = h[7]; + _block: function(w2) { + var i, tmp, a, b2, h = this._h, k2 = this._key, h0 = h[0], h1 = h[1], h2 = h[2], h3 = h[3], h4 = h[4], h5 = h[5], h6 = h[6], h7 = h[7]; for (i = 0; i < 64; i++) { if (i < 16) { - tmp = w[i]; + tmp = w2[i]; } else { - a = w[i + 1 & 15]; - b = w[i + 14 & 15]; - tmp = w[i & 15] = (a >>> 7 ^ a >>> 18 ^ a >>> 3 ^ a << 25 ^ a << 14) + (b >>> 17 ^ b >>> 19 ^ b >>> 10 ^ b << 15 ^ b << 13) + w[i & 15] + w[i + 9 & 15] | 0; + a = w2[i + 1 & 15]; + b2 = w2[i + 14 & 15]; + tmp = w2[i & 15] = (a >>> 7 ^ a >>> 18 ^ a >>> 3 ^ a << 25 ^ a << 14) + (b2 >>> 17 ^ b2 >>> 19 ^ b2 >>> 10 ^ b2 << 15 ^ b2 << 13) + w2[i & 15] + w2[i + 9 & 15] | 0; } - tmp = tmp + h7 + (h4 >>> 6 ^ h4 >>> 11 ^ h4 >>> 25 ^ h4 << 26 ^ h4 << 21 ^ h4 << 7) + (h6 ^ h4 & (h5 ^ h6)) + k[i]; + tmp = tmp + h7 + (h4 >>> 6 ^ h4 >>> 11 ^ h4 >>> 25 ^ h4 << 26 ^ h4 << 21 ^ h4 << 7) + (h6 ^ h4 & (h5 ^ h6)) + k2[i]; h7 = h6; h6 = h5; h5 = h4; @@ -1879,7 +1889,7 @@ this._resultHash.update(data); }; sjcl2.misc.hmac.prototype.digest = function() { - var w = this._resultHash.finalize(), result = new this._hash(this._baseHash[1]).update(w).finalize(); + var w2 = this._resultHash.finalize(), result = new this._hash(this._baseHash[1]).update(w2).finalize(); this.reset(); return result; }; @@ -3131,8 +3141,8 @@ // ../node_modules/immutable-json-patch/lib/esm/utils.js init_define_import_meta_trackerLookup(); - function isEqual(a, b) { - return JSON.stringify(a) === JSON.stringify(b); + function isEqual(a, b2) { + return JSON.stringify(a) === JSON.stringify(b2); } function initial(array) { return array.slice(0, array.length - 1); @@ -3405,6 +3415,729 @@ return parseJSONPointer(fromPointer); } + // ../node_modules/urlpattern-polyfill/index.js + init_define_import_meta_trackerLookup(); + + // ../node_modules/urlpattern-polyfill/dist/urlpattern.js + init_define_import_meta_trackerLookup(); + var R = class { + constructor(t, r, n, o, c, l) { + __publicField(this, "type", 3); + __publicField(this, "name", ""); + __publicField(this, "prefix", ""); + __publicField(this, "value", ""); + __publicField(this, "suffix", ""); + __publicField(this, "modifier", 3); + this.type = t, this.name = r, this.prefix = n, this.value = o, this.suffix = c, this.modifier = l; + } + hasCustomName() { + return this.name !== "" && typeof this.name != "number"; + } + }; + var be = /[$_\p{ID_Start}]/u; + var Pe = /[$_\u200C\u200D\p{ID_Continue}]/u; + var M = ".*"; + function Re(e, t) { + return (t ? /^[\x00-\xFF]*$/ : /^[\x00-\x7F]*$/).test(e); + } + function v(e, t = false) { + let r = [], n = 0; + for (; n < e.length; ) { + let o = e[n], c = function(l) { + if (!t) throw new TypeError(l); + r.push({ type: "INVALID_CHAR", index: n, value: e[n++] }); + }; + if (o === "*") { + r.push({ type: "ASTERISK", index: n, value: e[n++] }); + continue; + } + if (o === "+" || o === "?") { + r.push({ type: "OTHER_MODIFIER", index: n, value: e[n++] }); + continue; + } + if (o === "\\") { + r.push({ type: "ESCAPED_CHAR", index: n++, value: e[n++] }); + continue; + } + if (o === "{") { + r.push({ type: "OPEN", index: n, value: e[n++] }); + continue; + } + if (o === "}") { + r.push({ type: "CLOSE", index: n, value: e[n++] }); + continue; + } + if (o === ":") { + let l = "", s = n + 1; + for (; s < e.length; ) { + let i = e.substr(s, 1); + if (s === n + 1 && be.test(i) || s !== n + 1 && Pe.test(i)) { + l += e[s++]; + continue; + } + break; + } + if (!l) { + c(`Missing parameter name at ${n}`); + continue; + } + r.push({ type: "NAME", index: n, value: l }), n = s; + continue; + } + if (o === "(") { + let l = 1, s = "", i = n + 1, a = false; + if (e[i] === "?") { + c(`Pattern cannot start with "?" at ${i}`); + continue; + } + for (; i < e.length; ) { + if (!Re(e[i], false)) { + c(`Invalid character '${e[i]}' at ${i}.`), a = true; + break; + } + if (e[i] === "\\") { + s += e[i++] + e[i++]; + continue; + } + if (e[i] === ")") { + if (l--, l === 0) { + i++; + break; + } + } else if (e[i] === "(" && (l++, e[i + 1] !== "?")) { + c(`Capturing groups are not allowed at ${i}`), a = true; + break; + } + s += e[i++]; + } + if (a) continue; + if (l) { + c(`Unbalanced pattern at ${n}`); + continue; + } + if (!s) { + c(`Missing pattern at ${n}`); + continue; + } + r.push({ type: "REGEX", index: n, value: s }), n = i; + continue; + } + r.push({ type: "CHAR", index: n, value: e[n++] }); + } + return r.push({ type: "END", index: n, value: "" }), r; + } + function D(e, t = {}) { + let r = v(e); + t.delimiter ??= "/#?", t.prefixes ??= "./"; + let n = `[^${S(t.delimiter)}]+?`, o = [], c = 0, l = 0, s = "", i = /* @__PURE__ */ new Set(), a = (h) => { + if (l < r.length && r[l].type === h) return r[l++].value; + }, f = () => a("OTHER_MODIFIER") ?? a("ASTERISK"), d = (h) => { + let u = a(h); + if (u !== void 0) return u; + let { type: p, index: A } = r[l]; + throw new TypeError(`Unexpected ${p} at ${A}, expected ${h}`); + }, T = () => { + let h = "", u; + for (; u = a("CHAR") ?? a("ESCAPED_CHAR"); ) h += u; + return h; + }, Se = (h) => h, L = t.encodePart || Se, I = "", U = (h) => { + I += h; + }, $ = () => { + I.length && (o.push(new R(3, "", "", L(I), "", 3)), I = ""); + }, V = (h, u, p, A, Y) => { + let g = 3; + switch (Y) { + case "?": + g = 1; + break; + case "*": + g = 0; + break; + case "+": + g = 2; + break; + } + if (!u && !p && g === 3) { + U(h); + return; + } + if ($(), !u && !p) { + if (!h) return; + o.push(new R(3, "", "", L(h), "", g)); + return; + } + let m; + p ? p === "*" ? m = M : m = p : m = n; + let O = 2; + m === n ? (O = 1, m = "") : m === M && (O = 0, m = ""); + let P; + if (u ? P = u : p && (P = c++), i.has(P)) throw new TypeError(`Duplicate name '${P}'.`); + i.add(P), o.push(new R(O, P, L(h), m, L(A), g)); + }; + for (; l < r.length; ) { + let h = a("CHAR"), u = a("NAME"), p = a("REGEX"); + if (!u && !p && (p = a("ASTERISK")), u || p) { + let g = h ?? ""; + t.prefixes.indexOf(g) === -1 && (U(g), g = ""), $(); + let m = f(); + V(g, u, p, "", m); + continue; + } + let A = h ?? a("ESCAPED_CHAR"); + if (A) { + U(A); + continue; + } + if (a("OPEN")) { + let g = T(), m = a("NAME"), O = a("REGEX"); + !m && !O && (O = a("ASTERISK")); + let P = T(); + d("CLOSE"); + let xe = f(); + V(g, m, O, P, xe); + continue; + } + $(), d("END"); + } + return o; + } + function S(e) { + return e.replace(/([.+*?^${}()[\]|/\\])/g, "\\$1"); + } + function X(e) { + return e && e.ignoreCase ? "ui" : "u"; + } + function Z(e, t, r) { + return F(D(e, r), t, r); + } + function k(e) { + switch (e) { + case 0: + return "*"; + case 1: + return "?"; + case 2: + return "+"; + case 3: + return ""; + } + } + function F(e, t, r = {}) { + r.delimiter ??= "/#?", r.prefixes ??= "./", r.sensitive ??= false, r.strict ??= false, r.end ??= true, r.start ??= true, r.endsWith = ""; + let n = r.start ? "^" : ""; + for (let s of e) { + if (s.type === 3) { + s.modifier === 3 ? n += S(s.value) : n += `(?:${S(s.value)})${k(s.modifier)}`; + continue; + } + t && t.push(s.name); + let i = `[^${S(r.delimiter)}]+?`, a = s.value; + if (s.type === 1 ? a = i : s.type === 0 && (a = M), !s.prefix.length && !s.suffix.length) { + s.modifier === 3 || s.modifier === 1 ? n += `(${a})${k(s.modifier)}` : n += `((?:${a})${k(s.modifier)})`; + continue; + } + if (s.modifier === 3 || s.modifier === 1) { + n += `(?:${S(s.prefix)}(${a})${S(s.suffix)})`, n += k(s.modifier); + continue; + } + n += `(?:${S(s.prefix)}`, n += `((?:${a})(?:`, n += S(s.suffix), n += S(s.prefix), n += `(?:${a}))*)${S(s.suffix)})`, s.modifier === 0 && (n += "?"); + } + let o = `[${S(r.endsWith)}]|$`, c = `[${S(r.delimiter)}]`; + if (r.end) return r.strict || (n += `${c}?`), r.endsWith.length ? n += `(?=${o})` : n += "$", new RegExp(n, X(r)); + r.strict || (n += `(?:${c}(?=${o}))?`); + let l = false; + if (e.length) { + let s = e[e.length - 1]; + s.type === 3 && s.modifier === 3 && (l = r.delimiter.indexOf(s) > -1); + } + return l || (n += `(?=${c}|${o})`), new RegExp(n, X(r)); + } + var x = { delimiter: "", prefixes: "", sensitive: true, strict: true }; + var B = { delimiter: ".", prefixes: "", sensitive: true, strict: true }; + var q = { delimiter: "/", prefixes: "/", sensitive: true, strict: true }; + function J(e, t) { + return e.length ? e[0] === "/" ? true : !t || e.length < 2 ? false : (e[0] == "\\" || e[0] == "{") && e[1] == "/" : false; + } + function Q(e, t) { + return e.startsWith(t) ? e.substring(t.length, e.length) : e; + } + function Ee(e, t) { + return e.endsWith(t) ? e.substr(0, e.length - t.length) : e; + } + function W(e) { + return !e || e.length < 2 ? false : e[0] === "[" || (e[0] === "\\" || e[0] === "{") && e[1] === "["; + } + var ee = ["ftp", "file", "http", "https", "ws", "wss"]; + function N(e) { + if (!e) return true; + for (let t of ee) if (e.test(t)) return true; + return false; + } + function te(e, t) { + if (e = Q(e, "#"), t || e === "") return e; + let r = new URL("https://example.com"); + return r.hash = e, r.hash ? r.hash.substring(1, r.hash.length) : ""; + } + function re(e, t) { + if (e = Q(e, "?"), t || e === "") return e; + let r = new URL("https://example.com"); + return r.search = e, r.search ? r.search.substring(1, r.search.length) : ""; + } + function ne(e, t) { + return t || e === "" ? e : W(e) ? j(e) : z(e); + } + function se(e, t) { + if (t || e === "") return e; + let r = new URL("https://example.com"); + return r.password = e, r.password; + } + function ie(e, t) { + if (t || e === "") return e; + let r = new URL("https://example.com"); + return r.username = e, r.username; + } + function ae(e, t, r) { + if (r || e === "") return e; + if (t && !ee.includes(t)) return new URL(`${t}:${e}`).pathname; + let n = e[0] == "/"; + return e = new URL(n ? e : "/-" + e, "https://example.com").pathname, n || (e = e.substring(2, e.length)), e; + } + function oe(e, t, r) { + return _(t) === e && (e = ""), r || e === "" ? e : K(e); + } + function ce(e, t) { + return e = Ee(e, ":"), t || e === "" ? e : y(e); + } + function _(e) { + switch (e) { + case "ws": + case "http": + return "80"; + case "wws": + case "https": + return "443"; + case "ftp": + return "21"; + default: + return ""; + } + } + function y(e) { + if (e === "") return e; + if (/^[-+.A-Za-z0-9]*$/.test(e)) return e.toLowerCase(); + throw new TypeError(`Invalid protocol '${e}'.`); + } + function le(e) { + if (e === "") return e; + let t = new URL("https://example.com"); + return t.username = e, t.username; + } + function fe(e) { + if (e === "") return e; + let t = new URL("https://example.com"); + return t.password = e, t.password; + } + function z(e) { + if (e === "") return e; + if (/[\t\n\r #%/:<>?@[\]^\\|]/g.test(e)) throw new TypeError(`Invalid hostname '${e}'`); + let t = new URL("https://example.com"); + return t.hostname = e, t.hostname; + } + function j(e) { + if (e === "") return e; + if (/[^0-9a-fA-F[\]:]/g.test(e)) throw new TypeError(`Invalid IPv6 hostname '${e}'`); + return e.toLowerCase(); + } + function K(e) { + if (e === "" || /^[0-9]*$/.test(e) && parseInt(e) <= 65535) return e; + throw new TypeError(`Invalid port '${e}'.`); + } + function he(e) { + if (e === "") return e; + let t = new URL("https://example.com"); + return t.pathname = e[0] !== "/" ? "/-" + e : e, e[0] !== "/" ? t.pathname.substring(2, t.pathname.length) : t.pathname; + } + function ue(e) { + return e === "" ? e : new URL(`data:${e}`).pathname; + } + function de(e) { + if (e === "") return e; + let t = new URL("https://example.com"); + return t.search = e, t.search.substring(1, t.search.length); + } + function pe(e) { + if (e === "") return e; + let t = new URL("https://example.com"); + return t.hash = e, t.hash.substring(1, t.hash.length); + } + var _i, _n, _t, _e, _s, _l, _o, _d, _p, _g, _H_instances, r_fn, R_fn, b_fn, u_fn, m_fn, a_fn, P_fn, E_fn, S_fn, O_fn, k_fn, x_fn, h_fn, f_fn, T_fn, A_fn, y_fn, w_fn, c_fn, C_fn, _a; + var H = (_a = class { + constructor(t) { + __privateAdd(this, _H_instances); + __privateAdd(this, _i); + __privateAdd(this, _n, []); + __privateAdd(this, _t, {}); + __privateAdd(this, _e, 0); + __privateAdd(this, _s, 1); + __privateAdd(this, _l, 0); + __privateAdd(this, _o, 0); + __privateAdd(this, _d, 0); + __privateAdd(this, _p, 0); + __privateAdd(this, _g, false); + __privateSet(this, _i, t); + } + get result() { + return __privateGet(this, _t); + } + parse() { + for (__privateSet(this, _n, v(__privateGet(this, _i), true)); __privateGet(this, _e) < __privateGet(this, _n).length; __privateSet(this, _e, __privateGet(this, _e) + __privateGet(this, _s))) { + if (__privateSet(this, _s, 1), __privateGet(this, _n)[__privateGet(this, _e)].type === "END") { + if (__privateGet(this, _o) === 0) { + __privateMethod(this, _H_instances, b_fn).call(this), __privateMethod(this, _H_instances, f_fn).call(this) ? __privateMethod(this, _H_instances, r_fn).call(this, 9, 1) : __privateMethod(this, _H_instances, h_fn).call(this) ? __privateMethod(this, _H_instances, r_fn).call(this, 8, 1) : __privateMethod(this, _H_instances, r_fn).call(this, 7, 0); + continue; + } else if (__privateGet(this, _o) === 2) { + __privateMethod(this, _H_instances, u_fn).call(this, 5); + continue; + } + __privateMethod(this, _H_instances, r_fn).call(this, 10, 0); + break; + } + if (__privateGet(this, _d) > 0) if (__privateMethod(this, _H_instances, A_fn).call(this)) __privateSet(this, _d, __privateGet(this, _d) - 1); + else continue; + if (__privateMethod(this, _H_instances, T_fn).call(this)) { + __privateSet(this, _d, __privateGet(this, _d) + 1); + continue; + } + switch (__privateGet(this, _o)) { + case 0: + __privateMethod(this, _H_instances, P_fn).call(this) && __privateMethod(this, _H_instances, u_fn).call(this, 1); + break; + case 1: + if (__privateMethod(this, _H_instances, P_fn).call(this)) { + __privateMethod(this, _H_instances, C_fn).call(this); + let t = 7, r = 1; + __privateMethod(this, _H_instances, E_fn).call(this) ? (t = 2, r = 3) : __privateGet(this, _g) && (t = 2), __privateMethod(this, _H_instances, r_fn).call(this, t, r); + } + break; + case 2: + __privateMethod(this, _H_instances, S_fn).call(this) ? __privateMethod(this, _H_instances, u_fn).call(this, 3) : (__privateMethod(this, _H_instances, x_fn).call(this) || __privateMethod(this, _H_instances, h_fn).call(this) || __privateMethod(this, _H_instances, f_fn).call(this)) && __privateMethod(this, _H_instances, u_fn).call(this, 5); + break; + case 3: + __privateMethod(this, _H_instances, O_fn).call(this) ? __privateMethod(this, _H_instances, r_fn).call(this, 4, 1) : __privateMethod(this, _H_instances, S_fn).call(this) && __privateMethod(this, _H_instances, r_fn).call(this, 5, 1); + break; + case 4: + __privateMethod(this, _H_instances, S_fn).call(this) && __privateMethod(this, _H_instances, r_fn).call(this, 5, 1); + break; + case 5: + __privateMethod(this, _H_instances, y_fn).call(this) ? __privateSet(this, _p, __privateGet(this, _p) + 1) : __privateMethod(this, _H_instances, w_fn).call(this) && __privateSet(this, _p, __privateGet(this, _p) - 1), __privateMethod(this, _H_instances, k_fn).call(this) && !__privateGet(this, _p) ? __privateMethod(this, _H_instances, r_fn).call(this, 6, 1) : __privateMethod(this, _H_instances, x_fn).call(this) ? __privateMethod(this, _H_instances, r_fn).call(this, 7, 0) : __privateMethod(this, _H_instances, h_fn).call(this) ? __privateMethod(this, _H_instances, r_fn).call(this, 8, 1) : __privateMethod(this, _H_instances, f_fn).call(this) && __privateMethod(this, _H_instances, r_fn).call(this, 9, 1); + break; + case 6: + __privateMethod(this, _H_instances, x_fn).call(this) ? __privateMethod(this, _H_instances, r_fn).call(this, 7, 0) : __privateMethod(this, _H_instances, h_fn).call(this) ? __privateMethod(this, _H_instances, r_fn).call(this, 8, 1) : __privateMethod(this, _H_instances, f_fn).call(this) && __privateMethod(this, _H_instances, r_fn).call(this, 9, 1); + break; + case 7: + __privateMethod(this, _H_instances, h_fn).call(this) ? __privateMethod(this, _H_instances, r_fn).call(this, 8, 1) : __privateMethod(this, _H_instances, f_fn).call(this) && __privateMethod(this, _H_instances, r_fn).call(this, 9, 1); + break; + case 8: + __privateMethod(this, _H_instances, f_fn).call(this) && __privateMethod(this, _H_instances, r_fn).call(this, 9, 1); + break; + case 9: + break; + case 10: + break; + } + } + __privateGet(this, _t).hostname !== void 0 && __privateGet(this, _t).port === void 0 && (__privateGet(this, _t).port = ""); + } + }, _i = new WeakMap(), _n = new WeakMap(), _t = new WeakMap(), _e = new WeakMap(), _s = new WeakMap(), _l = new WeakMap(), _o = new WeakMap(), _d = new WeakMap(), _p = new WeakMap(), _g = new WeakMap(), _H_instances = new WeakSet(), r_fn = function(t, r) { + switch (__privateGet(this, _o)) { + case 0: + break; + case 1: + __privateGet(this, _t).protocol = __privateMethod(this, _H_instances, c_fn).call(this); + break; + case 2: + break; + case 3: + __privateGet(this, _t).username = __privateMethod(this, _H_instances, c_fn).call(this); + break; + case 4: + __privateGet(this, _t).password = __privateMethod(this, _H_instances, c_fn).call(this); + break; + case 5: + __privateGet(this, _t).hostname = __privateMethod(this, _H_instances, c_fn).call(this); + break; + case 6: + __privateGet(this, _t).port = __privateMethod(this, _H_instances, c_fn).call(this); + break; + case 7: + __privateGet(this, _t).pathname = __privateMethod(this, _H_instances, c_fn).call(this); + break; + case 8: + __privateGet(this, _t).search = __privateMethod(this, _H_instances, c_fn).call(this); + break; + case 9: + __privateGet(this, _t).hash = __privateMethod(this, _H_instances, c_fn).call(this); + break; + case 10: + break; + } + __privateGet(this, _o) !== 0 && t !== 10 && ([1, 2, 3, 4].includes(__privateGet(this, _o)) && [6, 7, 8, 9].includes(t) && (__privateGet(this, _t).hostname ??= ""), [1, 2, 3, 4, 5, 6].includes(__privateGet(this, _o)) && [8, 9].includes(t) && (__privateGet(this, _t).pathname ??= __privateGet(this, _g) ? "/" : ""), [1, 2, 3, 4, 5, 6, 7].includes(__privateGet(this, _o)) && t === 9 && (__privateGet(this, _t).search ??= "")), __privateMethod(this, _H_instances, R_fn).call(this, t, r); + }, R_fn = function(t, r) { + __privateSet(this, _o, t), __privateSet(this, _l, __privateGet(this, _e) + r), __privateSet(this, _e, __privateGet(this, _e) + r), __privateSet(this, _s, 0); + }, b_fn = function() { + __privateSet(this, _e, __privateGet(this, _l)), __privateSet(this, _s, 0); + }, u_fn = function(t) { + __privateMethod(this, _H_instances, b_fn).call(this), __privateSet(this, _o, t); + }, m_fn = function(t) { + return t < 0 && (t = __privateGet(this, _n).length - t), t < __privateGet(this, _n).length ? __privateGet(this, _n)[t] : __privateGet(this, _n)[__privateGet(this, _n).length - 1]; + }, a_fn = function(t, r) { + let n = __privateMethod(this, _H_instances, m_fn).call(this, t); + return n.value === r && (n.type === "CHAR" || n.type === "ESCAPED_CHAR" || n.type === "INVALID_CHAR"); + }, P_fn = function() { + return __privateMethod(this, _H_instances, a_fn).call(this, __privateGet(this, _e), ":"); + }, E_fn = function() { + return __privateMethod(this, _H_instances, a_fn).call(this, __privateGet(this, _e) + 1, "/") && __privateMethod(this, _H_instances, a_fn).call(this, __privateGet(this, _e) + 2, "/"); + }, S_fn = function() { + return __privateMethod(this, _H_instances, a_fn).call(this, __privateGet(this, _e), "@"); + }, O_fn = function() { + return __privateMethod(this, _H_instances, a_fn).call(this, __privateGet(this, _e), ":"); + }, k_fn = function() { + return __privateMethod(this, _H_instances, a_fn).call(this, __privateGet(this, _e), ":"); + }, x_fn = function() { + return __privateMethod(this, _H_instances, a_fn).call(this, __privateGet(this, _e), "/"); + }, h_fn = function() { + if (__privateMethod(this, _H_instances, a_fn).call(this, __privateGet(this, _e), "?")) return true; + if (__privateGet(this, _n)[__privateGet(this, _e)].value !== "?") return false; + let t = __privateMethod(this, _H_instances, m_fn).call(this, __privateGet(this, _e) - 1); + return t.type !== "NAME" && t.type !== "REGEX" && t.type !== "CLOSE" && t.type !== "ASTERISK"; + }, f_fn = function() { + return __privateMethod(this, _H_instances, a_fn).call(this, __privateGet(this, _e), "#"); + }, T_fn = function() { + return __privateGet(this, _n)[__privateGet(this, _e)].type == "OPEN"; + }, A_fn = function() { + return __privateGet(this, _n)[__privateGet(this, _e)].type == "CLOSE"; + }, y_fn = function() { + return __privateMethod(this, _H_instances, a_fn).call(this, __privateGet(this, _e), "["); + }, w_fn = function() { + return __privateMethod(this, _H_instances, a_fn).call(this, __privateGet(this, _e), "]"); + }, c_fn = function() { + let t = __privateGet(this, _n)[__privateGet(this, _e)], r = __privateMethod(this, _H_instances, m_fn).call(this, __privateGet(this, _l)).index; + return __privateGet(this, _i).substring(r, t.index); + }, C_fn = function() { + let t = {}; + Object.assign(t, x), t.encodePart = y; + let r = Z(__privateMethod(this, _H_instances, c_fn).call(this), void 0, t); + __privateSet(this, _g, N(r)); + }, _a); + var G = ["protocol", "username", "password", "hostname", "port", "pathname", "search", "hash"]; + var E = "*"; + function ge(e, t) { + if (typeof e != "string") throw new TypeError("parameter 1 is not of type 'string'."); + let r = new URL(e, t); + return { protocol: r.protocol.substring(0, r.protocol.length - 1), username: r.username, password: r.password, hostname: r.hostname, port: r.port, pathname: r.pathname, search: r.search !== "" ? r.search.substring(1, r.search.length) : void 0, hash: r.hash !== "" ? r.hash.substring(1, r.hash.length) : void 0 }; + } + function b(e, t) { + return t ? C(e) : e; + } + function w(e, t, r) { + let n; + if (typeof t.baseURL == "string") try { + n = new URL(t.baseURL), t.protocol === void 0 && (e.protocol = b(n.protocol.substring(0, n.protocol.length - 1), r)), !r && t.protocol === void 0 && t.hostname === void 0 && t.port === void 0 && t.username === void 0 && (e.username = b(n.username, r)), !r && t.protocol === void 0 && t.hostname === void 0 && t.port === void 0 && t.username === void 0 && t.password === void 0 && (e.password = b(n.password, r)), t.protocol === void 0 && t.hostname === void 0 && (e.hostname = b(n.hostname, r)), t.protocol === void 0 && t.hostname === void 0 && t.port === void 0 && (e.port = b(n.port, r)), t.protocol === void 0 && t.hostname === void 0 && t.port === void 0 && t.pathname === void 0 && (e.pathname = b(n.pathname, r)), t.protocol === void 0 && t.hostname === void 0 && t.port === void 0 && t.pathname === void 0 && t.search === void 0 && (e.search = b(n.search.substring(1, n.search.length), r)), t.protocol === void 0 && t.hostname === void 0 && t.port === void 0 && t.pathname === void 0 && t.search === void 0 && t.hash === void 0 && (e.hash = b(n.hash.substring(1, n.hash.length), r)); + } catch { + throw new TypeError(`invalid baseURL '${t.baseURL}'.`); + } + if (typeof t.protocol == "string" && (e.protocol = ce(t.protocol, r)), typeof t.username == "string" && (e.username = ie(t.username, r)), typeof t.password == "string" && (e.password = se(t.password, r)), typeof t.hostname == "string" && (e.hostname = ne(t.hostname, r)), typeof t.port == "string" && (e.port = oe(t.port, e.protocol, r)), typeof t.pathname == "string") { + if (e.pathname = t.pathname, n && !J(e.pathname, r)) { + let o = n.pathname.lastIndexOf("/"); + o >= 0 && (e.pathname = b(n.pathname.substring(0, o + 1), r) + e.pathname); + } + e.pathname = ae(e.pathname, e.protocol, r); + } + return typeof t.search == "string" && (e.search = re(t.search, r)), typeof t.hash == "string" && (e.hash = te(t.hash, r)), e; + } + function C(e) { + return e.replace(/([+*?:{}()\\])/g, "\\$1"); + } + function Oe(e) { + return e.replace(/([.+*?^${}()[\]|/\\])/g, "\\$1"); + } + function ke(e, t) { + t.delimiter ??= "/#?", t.prefixes ??= "./", t.sensitive ??= false, t.strict ??= false, t.end ??= true, t.start ??= true, t.endsWith = ""; + let r = ".*", n = `[^${Oe(t.delimiter)}]+?`, o = /[$_\u200C\u200D\p{ID_Continue}]/u, c = ""; + for (let l = 0; l < e.length; ++l) { + let s = e[l]; + if (s.type === 3) { + if (s.modifier === 3) { + c += C(s.value); + continue; + } + c += `{${C(s.value)}}${k(s.modifier)}`; + continue; + } + let i = s.hasCustomName(), a = !!s.suffix.length || !!s.prefix.length && (s.prefix.length !== 1 || !t.prefixes.includes(s.prefix)), f = l > 0 ? e[l - 1] : null, d = l < e.length - 1 ? e[l + 1] : null; + if (!a && i && s.type === 1 && s.modifier === 3 && d && !d.prefix.length && !d.suffix.length) if (d.type === 3) { + let T = d.value.length > 0 ? d.value[0] : ""; + a = o.test(T); + } else a = !d.hasCustomName(); + if (!a && !s.prefix.length && f && f.type === 3) { + let T = f.value[f.value.length - 1]; + a = t.prefixes.includes(T); + } + a && (c += "{"), c += C(s.prefix), i && (c += `:${s.name}`), s.type === 2 ? c += `(${s.value})` : s.type === 1 ? i || (c += `(${n})`) : s.type === 0 && (!i && (!f || f.type === 3 || f.modifier !== 3 || a || s.prefix !== "") ? c += "*" : c += `(${r})`), s.type === 1 && i && s.suffix.length && o.test(s.suffix[0]) && (c += "\\"), c += C(s.suffix), a && (c += "}"), s.modifier !== 3 && (c += k(s.modifier)); + } + return c; + } + var _i2, _n2, _t2, _e2, _s2, _l2, _a2; + var me = (_a2 = class { + constructor(t = {}, r, n) { + __privateAdd(this, _i2); + __privateAdd(this, _n2, {}); + __privateAdd(this, _t2, {}); + __privateAdd(this, _e2, {}); + __privateAdd(this, _s2, {}); + __privateAdd(this, _l2, false); + try { + let o; + if (typeof r == "string" ? o = r : n = r, typeof t == "string") { + let i = new H(t); + if (i.parse(), t = i.result, o === void 0 && typeof t.protocol != "string") throw new TypeError("A base URL must be provided for a relative constructor string."); + t.baseURL = o; + } else { + if (!t || typeof t != "object") throw new TypeError("parameter 1 is not of type 'string' and cannot convert to dictionary."); + if (o) throw new TypeError("parameter 1 is not of type 'string'."); + } + typeof n > "u" && (n = { ignoreCase: false }); + let c = { ignoreCase: n.ignoreCase === true }, l = { pathname: E, protocol: E, username: E, password: E, hostname: E, port: E, search: E, hash: E }; + __privateSet(this, _i2, w(l, t, true)), _(__privateGet(this, _i2).protocol) === __privateGet(this, _i2).port && (__privateGet(this, _i2).port = ""); + let s; + for (s of G) { + if (!(s in __privateGet(this, _i2))) continue; + let i = {}, a = __privateGet(this, _i2)[s]; + switch (__privateGet(this, _t2)[s] = [], s) { + case "protocol": + Object.assign(i, x), i.encodePart = y; + break; + case "username": + Object.assign(i, x), i.encodePart = le; + break; + case "password": + Object.assign(i, x), i.encodePart = fe; + break; + case "hostname": + Object.assign(i, B), W(a) ? i.encodePart = j : i.encodePart = z; + break; + case "port": + Object.assign(i, x), i.encodePart = K; + break; + case "pathname": + N(__privateGet(this, _n2).protocol) ? (Object.assign(i, q, c), i.encodePart = he) : (Object.assign(i, x, c), i.encodePart = ue); + break; + case "search": + Object.assign(i, x, c), i.encodePart = de; + break; + case "hash": + Object.assign(i, x, c), i.encodePart = pe; + break; + } + try { + __privateGet(this, _s2)[s] = D(a, i), __privateGet(this, _n2)[s] = F(__privateGet(this, _s2)[s], __privateGet(this, _t2)[s], i), __privateGet(this, _e2)[s] = ke(__privateGet(this, _s2)[s], i), __privateSet(this, _l2, __privateGet(this, _l2) || __privateGet(this, _s2)[s].some((f) => f.type === 2)); + } catch { + throw new TypeError(`invalid ${s} pattern '${__privateGet(this, _i2)[s]}'.`); + } + } + } catch (o) { + throw new TypeError(`Failed to construct 'URLPattern': ${o.message}`); + } + } + test(t = {}, r) { + let n = { pathname: "", protocol: "", username: "", password: "", hostname: "", port: "", search: "", hash: "" }; + if (typeof t != "string" && r) throw new TypeError("parameter 1 is not of type 'string'."); + if (typeof t > "u") return false; + try { + typeof t == "object" ? n = w(n, t, false) : n = w(n, ge(t, r), false); + } catch { + return false; + } + let o; + for (o of G) if (!__privateGet(this, _n2)[o].exec(n[o])) return false; + return true; + } + exec(t = {}, r) { + let n = { pathname: "", protocol: "", username: "", password: "", hostname: "", port: "", search: "", hash: "" }; + if (typeof t != "string" && r) throw new TypeError("parameter 1 is not of type 'string'."); + if (typeof t > "u") return; + try { + typeof t == "object" ? n = w(n, t, false) : n = w(n, ge(t, r), false); + } catch { + return null; + } + let o = {}; + r ? o.inputs = [t, r] : o.inputs = [t]; + let c; + for (c of G) { + let l = __privateGet(this, _n2)[c].exec(n[c]); + if (!l) return null; + let s = {}; + for (let [i, a] of __privateGet(this, _t2)[c].entries()) if (typeof a == "string" || typeof a == "number") { + let f = l[i + 1]; + s[a] = f; + } + o[c] = { input: n[c] ?? "", groups: s }; + } + return o; + } + static compareComponent(t, r, n) { + let o = (i, a) => { + for (let f of ["type", "modifier", "prefix", "value", "suffix"]) { + if (i[f] < a[f]) return -1; + if (i[f] === a[f]) continue; + return 1; + } + return 0; + }, c = new R(3, "", "", "", "", 3), l = new R(0, "", "", "", "", 3), s = (i, a) => { + let f = 0; + for (; f < Math.min(i.length, a.length); ++f) { + let d = o(i[f], a[f]); + if (d) return d; + } + return i.length === a.length ? 0 : o(i[f] ?? c, a[f] ?? c); + }; + return !__privateGet(r, _e2)[t] && !__privateGet(n, _e2)[t] ? 0 : __privateGet(r, _e2)[t] && !__privateGet(n, _e2)[t] ? s(__privateGet(r, _s2)[t], [l]) : !__privateGet(r, _e2)[t] && __privateGet(n, _e2)[t] ? s([l], __privateGet(n, _s2)[t]) : s(__privateGet(r, _s2)[t], __privateGet(n, _s2)[t]); + } + get protocol() { + return __privateGet(this, _e2).protocol; + } + get username() { + return __privateGet(this, _e2).username; + } + get password() { + return __privateGet(this, _e2).password; + } + get hostname() { + return __privateGet(this, _e2).hostname; + } + get port() { + return __privateGet(this, _e2).port; + } + get pathname() { + return __privateGet(this, _e2).pathname; + } + get search() { + return __privateGet(this, _e2).search; + } + get hash() { + return __privateGet(this, _e2).hash; + } + get hasRegExpGroups() { + return __privateGet(this, _l2); + } + }, _i2 = new WeakMap(), _n2 = new WeakMap(), _t2 = new WeakMap(), _e2 = new WeakMap(), _s2 = new WeakMap(), _l2 = new WeakMap(), _a2); + + // ../node_modules/urlpattern-polyfill/index.js + if (!globalThis.URLPattern) { + globalThis.URLPattern = me; + } + // src/config-feature.js var _bundledConfig, _args; var ConfigFeature = class { @@ -3428,6 +4161,15 @@ __privateGet(this, _args).featureSettings = parseFeatureSettings(bundledConfig, enabledFeatures); } } + /** + * Call this when the top URL has changed, to recompute the site object. + * This is used to update the path matching for urlPattern. + */ + recomputeSiteObject() { + if (__privateGet(this, _args)) { + __privateGet(this, _args).site = computeLimitedSiteObject(); + } + } get args() { return __privateGet(this, _args); } @@ -3438,25 +4180,99 @@ return __privateGet(this, _args)?.featureSettings; } /** - * Given a config key, interpret the value as a list of domain overrides, and return the elements that match the current page - * Consider using patchSettings instead as per `getFeatureSetting`. + * Given a config key, interpret the value as a list of conditionals objects, and return the elements that match the current page + * Consider in your feature using patchSettings instead as per `getFeatureSetting`. * @param {string} featureKeyName * @return {any[]} * @protected */ - matchDomainFeatureSetting(featureKeyName) { - const domain = this.args?.site.domain; - if (!domain) return []; - const domains = this._getFeatureSettings()?.[featureKeyName] || []; - return domains.filter((rule) => { - if (Array.isArray(rule.domain)) { - return rule.domain.some((domainRule) => { - return matchHostname(domain, domainRule); - }); + matchConditionalFeatureSetting(featureKeyName) { + const conditionalChanges = this._getFeatureSettings()?.[featureKeyName] || []; + return conditionalChanges.filter((rule) => { + let condition = rule.condition; + if (condition === void 0 && "domain" in rule) { + condition = this._domainToConditonBlocks(rule.domain); } - return matchHostname(domain, rule.domain); + return this._matchConditionalBlockOrArray(condition); }); } + /** + * Takes a list of domains and returns a list of condition blocks + * @param {string|string[]} domain + * @returns {ConditionBlock[]} + */ + _domainToConditonBlocks(domain) { + if (Array.isArray(domain)) { + return domain.map((domain2) => ({ domain: domain2 })); + } else { + return [{ domain }]; + } + } + /** + * Used to match conditional changes for a settings feature. + * @typedef {object} ConditionBlock + * @property {string[] | string} [domain] + * @property {object} [urlPattern] + */ + /** + * Takes multiple conditional blocks and returns true if any apply. + * @param {ConditionBlock|ConditionBlock[]} conditionBlock + * @returns {boolean} + */ + _matchConditionalBlockOrArray(conditionBlock) { + if (Array.isArray(conditionBlock)) { + return conditionBlock.some((block) => this._matchConditionalBlock(block)); + } + return this._matchConditionalBlock(conditionBlock); + } + /** + * Takes a conditional block and returns true if it applies. + * All conditions must be met to return true. + * @param {ConditionBlock} conditionBlock + * @returns {boolean} + */ + _matchConditionalBlock(conditionBlock) { + const conditionChecks = { + domain: this._matchDomainConditional, + urlPattern: this._matchUrlPatternConditional + }; + for (const key in conditionBlock) { + if (!conditionChecks[key]) { + return false; + } else if (!conditionChecks[key].call(this, conditionBlock)) { + return false; + } + } + return true; + } + /** + * Takes a condtion block and returns true if the current url matches the urlPattern. + * @param {ConditionBlock} conditionBlock + * @returns {boolean} + */ + _matchUrlPatternConditional(conditionBlock) { + const url = this.args?.site.url; + if (!url) return false; + if (typeof conditionBlock.urlPattern === "string") { + return new me(conditionBlock.urlPattern, url).test(url); + } + const pattern = new me(conditionBlock.urlPattern); + return pattern.test(url); + } + /** + * Takes a condition block and returns true if the current domain matches the domain. + * @param {ConditionBlock} conditionBlock + * @returns {boolean} + */ + _matchDomainConditional(conditionBlock) { + if (!conditionBlock.domain) return false; + const domain = this.args?.site.domain; + if (!domain) return false; + if (Array.isArray(conditionBlock.domain)) { + return false; + } + return matchHostname(domain, conditionBlock.domain); + } /** * Return the settings object for a feature * @param {string} [featureName] - The name of the feature to get the settings for; defaults to the name of the feature @@ -3498,40 +4314,83 @@ return result === "enabled"; } /** - * Return a specific setting from the feature settings - * If the "settings" key within the config has a "domains" key, it will be used to override the settings. - * This uses JSONPatch to apply the patches to settings before getting the setting value. - * For example.com getFeatureSettings('val') will return 1: - * ```json - * { - * "settings": { - * "domains": [ - * { - * "domain": "example.com", - * "patchSettings": [ - * { "op": "replace", "path": "/val", "value": 1 } - * ] - * } - * ] - * } - * } - * ``` - * "domain" can either be a string or an array of strings. - - * For boolean states you should consider using getFeatureSettingEnabled. - * @param {string} featureKeyName - * @param {string} [featureName] - * @returns {any} - */ + * Return a specific setting from the feature settings + * If the "settings" key within the config has a "conditionalChanges" key, it will be used to override the settings. + * This uses JSONPatch to apply the patches to settings before getting the setting value. + * For example.com getFeatureSettings('val') will return 1: + * ```json + * { + * "settings": { + * "conditionalChanges": [ + * { + * "domain": "example.com", + * "patchSettings": [ + * { "op": "replace", "path": "/val", "value": 1 } + * ] + * } + * ] + * } + * } + * ``` + * "domain" can either be a string or an array of strings. + * Additionally we support urlPattern for more complex matching. + * For example.com getFeatureSettings('val') will return 1: + * ```json + * { + * "settings": { + * "conditionalChanges": [ + * { + * "condition": { + * "urlPattern": "https://example.com/*", + * }, + * "patchSettings": [ + * { "op": "replace", "path": "/val", "value": 1 } + * ] + * } + * ] + * } + * } + * ``` + * We also support multiple conditions: + * ```json + * { + * "settings": { + * "conditionalChanges": [ + * { + * "condition": [ + * { + * "urlPattern": "https://example.com/*", + * }, + * { + * "urlPattern": "https://other.com/path/something", + * }, + * ], + * "patchSettings": [ + * { "op": "replace", "path": "/val", "value": 1 } + * ] + * } + * ] + * } + * } + * ``` + * + * For boolean states you should consider using getFeatureSettingEnabled. + * @param {string} featureKeyName + * @param {string} [featureName] + * @returns {any} + */ getFeatureSetting(featureKeyName, featureName) { let result = this._getFeatureSettings(featureName); - if (featureKeyName === "domains") { - throw new Error("domains is a reserved feature setting key name"); + if (featureKeyName in ["domains", "conditionalChanges"]) { + throw new Error(`${featureKeyName} is a reserved feature setting key name`); } - const domainMatch = [...this.matchDomainFeatureSetting("domains")].sort((a, b) => { - return a.domain.length - b.domain.length; - }); - for (const match of domainMatch) { + let conditionalMatches = []; + if (result?.conditionalChanges) { + conditionalMatches = this.matchConditionalFeatureSetting("conditionalChanges"); + } else { + conditionalMatches = this.matchConditionalFeatureSetting("domains"); + } + for (const match of conditionalMatches) { if (match.patchSettings === void 0) { continue; } @@ -3564,6 +4423,11 @@ __privateAdd(this, _messaging); /** @type {boolean} */ __privateAdd(this, _isDebugFlagSet, false); + /** + * Set this to true if you wish to listen to top level URL changes for config matching. + * @type {boolean} + */ + __publicField(this, "listenForUrlChanges", false); /** @type {ImportMeta} */ __privateAdd(this, _importConfig); this.setArgs(this.args); @@ -3729,7 +4593,7 @@ this.messaging?.notify("addDebugFlag", { flag: this.name }); - } catch (_e) { + } catch (_e3) { } } /** @@ -3740,17 +4604,17 @@ * @param {import('./wrapper-utils').StrictPropertyDescriptor} descriptor - requires all descriptor options to be defined because we can't validate correctness based on TS types */ defineProperty(object, propertyName, descriptor) { - ["value", "get", "set"].forEach((k) => { - const descriptorProp = descriptor[k]; + ["value", "get", "set"].forEach((k2) => { + const descriptorProp = descriptor[k2]; if (typeof descriptorProp === "function") { const addDebugFlag = this.addDebugFlag.bind(this); const wrapper = new Proxy2(descriptorProp, { - apply(_, thisArg, argumentsList) { + apply(_2, thisArg, argumentsList) { addDebugFlag(); return Reflect2.apply(descriptorProp, thisArg, argumentsList); } }); - descriptor[k] = wrapToString(wrapper, descriptorProp); + descriptor[k2] = wrapToString(wrapper, descriptorProp); } }); return defineProperty(object, propertyName, descriptor); @@ -3812,8 +4676,8 @@ let { audioKey } = getCachedResponse(thisArg, args); if (!audioKey) { let cdSum = 0; - for (const k in channelData) { - cdSum += channelData[k]; + for (const k2 in channelData) { + cdSum += channelData[k2]; } if (cdSum === 0) { return; @@ -3924,7 +4788,7 @@ this.defineProperty(BatteryManager.prototype, eventProp, { enumerable: true, configurable: true, - set: (x) => x, + set: (x2) => x2, // noop get: () => { return null; @@ -3996,9 +4860,9 @@ } function adjacentSame(imageData, index, width) { const widthPixel = width * 4; - const x = index % widthPixel; + const x2 = index % widthPixel; const maxLength = imageData.length; - if (x < widthPixel) { + if (x2 < widthPixel) { const right = index + 4; if (!pixelsSame(imageData, index, right)) { return false; @@ -4012,7 +4876,7 @@ return false; } } - if (x > 0) { + if (x2 > 0) { const left = index - 4; if (!pixelsSame(imageData, index, left)) { return false; @@ -4813,7 +5677,7 @@ // src/features/navigator-interface.js var NavigatorInterface = class extends ContentFeature { load(args) { - if (this.matchDomainFeatureSetting("privilegedDomains").length) { + if (this.matchConditionalFeatureSetting("privilegedDomains").length) { this.injectNavigatorInterface(args); } } @@ -5049,9 +5913,9 @@ unhideTimeouts = this.getFeatureSetting("unhideTimeouts") || unhideTimeouts; mediaAndFormSelectors = this.getFeatureSetting("mediaAndFormSelectors") || mediaAndFormSelectors; if (shouldInjectStyleTag) { - shouldInjectStyleTag = this.matchDomainFeatureSetting("styleTagExceptions").length === 0; + shouldInjectStyleTag = this.matchConditionalFeatureSetting("styleTagExceptions").length === 0; } - const activeDomainRules = this.matchDomainFeatureSetting("domains").flatMap((item) => item.rules); + const activeDomainRules = this.matchConditionalFeatureSetting("domains").flatMap((item) => item.rules); const overrideRules = activeDomainRules.filter((rule) => { return rule.type === "override"; }); @@ -5078,16 +5942,12 @@ } else { applyRules(activeRules); } - const historyMethodProxy = new DDGProxy(this, History.prototype, "pushState", { - apply(target, thisArg, args) { - applyRules(activeRules); - return DDGReflect.apply(target, thisArg, args); - } - }); - historyMethodProxy.overload(); - window.addEventListener("popstate", () => { - applyRules(activeRules); - }); + this.activeRules = activeRules; + } + urlChanged() { + if (this.activeRules) { + this.applyRules(this.activeRules); + } } /** * Apply relevant hiding rules to page at set intervals @@ -5097,7 +5957,7 @@ */ applyRules(rules) { const timeoutRules = extractTimeoutRules(rules); - const clearCacheTimer = unhideTimeouts.concat(hideTimeouts).reduce((a, b) => Math.max(a, b), 0) + 100; + const clearCacheTimer = unhideTimeouts.concat(hideTimeouts).reduce((a, b2) => Math.max(a, b2), 0) + 100; hideTimeouts.forEach((timeout) => { setTimeout(() => { hideAdNodes(timeoutRules); @@ -5142,6 +6002,10 @@ // src/features/api-manipulation.js init_define_import_meta_trackerLookup(); var ApiManipulation = class extends ContentFeature { + constructor() { + super(...arguments); + __publicField(this, "listenForUrlChanges", true); + } init() { const apiChanges = this.getFeatureSetting("apiChanges"); if (apiChanges) { @@ -5154,6 +6018,9 @@ } } } + urlChanged() { + this.init(); + } /** * Checks if the config API change is valid. * @param {any} change @@ -6102,8 +6969,8 @@ init_define_import_meta_trackerLookup(); function appendImageAsBackground(parent, targetSelector, imageUrl) { const canceled = false; - fetch(imageUrl, { method: "HEAD" }).then((x) => { - const status = String(x.status); + fetch(imageUrl, { method: "HEAD" }).then((x2) => { + const status = String(x2.status); if (canceled) return console.warn("not adding image, cancelled"); if (status.startsWith("2")) { if (!canceled) { @@ -8163,6 +9030,44 @@ ddg_feature_messageBridge: message_bridge_default }; + // src/url-change.js + init_define_import_meta_trackerLookup(); + var urlChangeListeners = /* @__PURE__ */ new Set(); + function registerForURLChanges(listener) { + if (urlChangeListeners.size === 0) { + listenForURLChanges(); + } + urlChangeListeners.add(listener); + } + function handleURLChange() { + for (const listener of urlChangeListeners) { + listener(); + } + } + function listenForURLChanges() { + const urlChangedInstance = new ContentFeature("urlChanged", {}, {}); + if ("navigation" in globalThis && "addEventListener" in globalThis.navigation) { + globalThis.navigation.addEventListener("navigatesuccess", () => { + handleURLChange(); + }); + return; + } + if (isBeingFramed()) { + return; + } + const historyMethodProxy = new DDGProxy(urlChangedInstance, History.prototype, "pushState", { + apply(target, thisArg, args) { + const changeResult = DDGReflect.apply(target, thisArg, args); + handleURLChange(); + return changeResult; + } + }); + historyMethodProxy.overload(); + window.addEventListener("popstate", () => { + handleURLChange(); + }); + } + // src/content-scope-features.js var initArgs = null; var updates = []; @@ -8203,6 +9108,12 @@ resolvedFeatures.forEach(({ featureInstance: featureInstance2, featureName }) => { if (!isFeatureBroken(args, featureName) || alwaysInitExtensionFeatures(args, featureName)) { featureInstance2.callInit(args); + if (featureInstance2.listenForUrlChanges || featureInstance2.urlChanged) { + registerForURLChanges(() => { + featureInstance2.recomputeSiteObject(); + featureInstance2?.urlChanged(); + }); + } } }); while (updates.length) { diff --git a/package-lock.json b/package-lock.json index a009c7b1403e..72a6b365f7df 100644 --- a/package-lock.json +++ b/package-lock.json @@ -10,7 +10,7 @@ "dependencies": { "@duckduckgo/autoconsent": "^12.17.0", "@duckduckgo/autofill": "github:duckduckgo/duckduckgo-autofill#17.1.0", - "@duckduckgo/content-scope-scripts": "github:duckduckgo/content-scope-scripts#8.14.0", + "@duckduckgo/content-scope-scripts": "github:duckduckgo/content-scope-scripts#8.16.0", "@duckduckgo/privacy-dashboard": "github:duckduckgo/privacy-dashboard#8.4.0", "@duckduckgo/privacy-reference-tests": "github:duckduckgo/privacy-reference-tests#1743747763" }, @@ -26,6 +26,7 @@ "resolved": "https://registry.npmjs.org/@babel/code-frame/-/code-frame-7.26.2.tgz", "integrity": "sha512-RJlIHRueQgwWitWgF8OdFYGZX328Ax5BCemNGlqHfplnRT9ESi8JkFlvaVYbS+UubVY6dpv87Fs2u5M29iNFVQ==", "dev": true, + "license": "MIT", "dependencies": { "@babel/helper-validator-identifier": "^7.25.9", "js-tokens": "^4.0.0", @@ -40,6 +41,7 @@ "resolved": "https://registry.npmjs.org/@babel/helper-validator-identifier/-/helper-validator-identifier-7.25.9.tgz", "integrity": "sha512-Ed61U6XJc3CVRfkERJWDz4dJwKe7iLmmJsbOGu9wSloNSFttHV0I8g6UAgb7qnK5ly5bGLPd4oXZlxCdANBOWQ==", "dev": true, + "license": "MIT", "engines": { "node": ">=6.9.0" } @@ -56,12 +58,12 @@ } }, "node_modules/@duckduckgo/autofill": { - "resolved": "git+ssh://git@github.com/duckduckgo/duckduckgo-autofill.git#8e89de49b4003d449b65faef19254ed5aaaf7def", + "resolved": "git+ssh://git@github.com/duckduckgo/duckduckgo-autofill.git#90541ed7d3a69733fc37e9c51bd92f21e0d56a57", "hasInstallScript": true, "license": "Apache-2.0" }, "node_modules/@duckduckgo/content-scope-scripts": { - "resolved": "git+ssh://git@github.com/duckduckgo/content-scope-scripts.git#3ddfbc576d7168ac6a3fec6372d99c12fc8ee15e", + "resolved": "git+ssh://git@github.com/duckduckgo/content-scope-scripts.git#ddc78d855112340fafab591fe93d442962f871ed", "license": "Apache-2.0", "workspaces": [ "injected", @@ -86,36 +88,40 @@ "license": "Apache-2.0" }, "node_modules/@ghostery/adblocker": { - "version": "2.5.0", - "resolved": "https://registry.npmjs.org/@ghostery/adblocker/-/adblocker-2.5.0.tgz", - "integrity": "sha512-CcmWiTLKxDqYiTlPyOAWr3xeZYXjWlpu6UOCDkk33k0w7jTgVrdvwbXf8Tv4XE0m3uNX6Idfj4H+Umv8L3AiUw==", + "version": "2.5.1", + "resolved": "https://registry.npmjs.org/@ghostery/adblocker/-/adblocker-2.5.1.tgz", + "integrity": "sha512-/sSSVLwb3ojIFw0owwffsGdCDOeMI02L/nXFIJD2exRAwG8hOETYwCGO7KwSyH2bnVTHtnIQYD1+hfeqQN+I5A==", + "license": "MPL-2.0", "dependencies": { - "@ghostery/adblocker-content": "^2.5.0", - "@ghostery/adblocker-extended-selectors": "^2.5.0", - "@remusao/guess-url-type": "^1.3.0", - "@remusao/small": "^1.2.1", - "@remusao/smaz": "^1.9.1", + "@ghostery/adblocker-content": "^2.5.1", + "@ghostery/adblocker-extended-selectors": "^2.5.1", + "@remusao/guess-url-type": "^2.0.0", + "@remusao/small": "^2.0.0", + "@remusao/smaz": "^2.1.0", "tldts-experimental": "^6.0.14" } }, "node_modules/@ghostery/adblocker-content": { - "version": "2.5.0", - "resolved": "https://registry.npmjs.org/@ghostery/adblocker-content/-/adblocker-content-2.5.0.tgz", - "integrity": "sha512-Gn9fslZdacx1m1e3/2LSUPWagLObYmIDbkgvZTtgqT/OHc17VbM71AxWEjtC/xzo5K4PI25958PjvidoEH7ufw==", + "version": "2.5.1", + "resolved": "https://registry.npmjs.org/@ghostery/adblocker-content/-/adblocker-content-2.5.1.tgz", + "integrity": "sha512-Im0GiRxKdyWWWiIQBBOzA4nHecvPjOvMvT+GqsTHjcVqz+xFC22Jw1BPoniOjVYnOhS/XxtQZOdjm6A2Cbffew==", + "license": "MPL-2.0", "dependencies": { - "@ghostery/adblocker-extended-selectors": "^2.5.0" + "@ghostery/adblocker-extended-selectors": "^2.5.1" } }, "node_modules/@ghostery/adblocker-extended-selectors": { - "version": "2.5.0", - "resolved": "https://registry.npmjs.org/@ghostery/adblocker-extended-selectors/-/adblocker-extended-selectors-2.5.0.tgz", - "integrity": "sha512-/GBAwErjktcBKLjCMl/n+jz2MxXFfTmEGw+hcPtAhEin49eSC09PK1TAdzDPDXkCTF4Jmb/zC+MYtbX1eZ1WsQ==" + "version": "2.5.1", + "resolved": "https://registry.npmjs.org/@ghostery/adblocker-extended-selectors/-/adblocker-extended-selectors-2.5.1.tgz", + "integrity": "sha512-UR9p/uEUmTXyQKkfCKwYesLkqJAGIyeFS2jDzIGgYDRyHGVlxu7Gcl/cdZehikTzBtrGtzc3X69amaUjvUyUJw==", + "license": "MPL-2.0" }, "node_modules/@jridgewell/gen-mapping": { "version": "0.3.8", "resolved": "https://registry.npmjs.org/@jridgewell/gen-mapping/-/gen-mapping-0.3.8.tgz", "integrity": "sha512-imAbBGkb+ebQyxKgzv5Hu2nmROxoDOXHh80evxdoXNOrvAnVx7zimzc1Oo5h9RlfV4vPXaE2iM5pOFbvOCClWA==", "dev": true, + "license": "MIT", "dependencies": { "@jridgewell/set-array": "^1.2.1", "@jridgewell/sourcemap-codec": "^1.4.10", @@ -130,6 +136,7 @@ "resolved": "https://registry.npmjs.org/@jridgewell/resolve-uri/-/resolve-uri-3.1.2.tgz", "integrity": "sha512-bRISgCIjP20/tbWSPWMEi54QVPRZExkuD9lJL+UIxUKtwVJA8wW1Trb1jMs1RFXo1CBTNZ/5hpC9QvmKWdopKw==", "dev": true, + "license": "MIT", "engines": { "node": ">=6.0.0" } @@ -139,6 +146,7 @@ "resolved": "https://registry.npmjs.org/@jridgewell/set-array/-/set-array-1.2.1.tgz", "integrity": "sha512-R8gLRTZeyp03ymzP/6Lil/28tGeGEzhx1q2k703KGWRAI1VdvPIXdG70VJc2pAMw3NA6JKL5hhFu1sJX0Mnn/A==", "dev": true, + "license": "MIT", "engines": { "node": ">=6.0.0" } @@ -148,6 +156,7 @@ "resolved": "https://registry.npmjs.org/@jridgewell/source-map/-/source-map-0.3.6.tgz", "integrity": "sha512-1ZJTZebgqllO79ue2bm3rIGud/bOe0pP5BjSRCRxxYkEZS8STV7zN84UBbiYu7jy+eCKSnVIUgoWWE/tt+shMQ==", "dev": true, + "license": "MIT", "dependencies": { "@jridgewell/gen-mapping": "^0.3.5", "@jridgewell/trace-mapping": "^0.3.25" @@ -157,60 +166,69 @@ "version": "1.5.0", "resolved": "https://registry.npmjs.org/@jridgewell/sourcemap-codec/-/sourcemap-codec-1.5.0.tgz", "integrity": "sha512-gv3ZRaISU3fjPAgNsriBRqGWQL6quFx04YMPW/zD8XMLsU32mhCCbfbO6KZFLjvYpCZ8zyDEgqsgf+PwPaM7GQ==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/@jridgewell/trace-mapping": { "version": "0.3.25", "resolved": "https://registry.npmjs.org/@jridgewell/trace-mapping/-/trace-mapping-0.3.25.tgz", "integrity": "sha512-vNk6aEwybGtawWmy/PzwnGDOjCkLWSD2wqvjGGAgOAwCGWySYXfYoxt00IJkTF+8Lb57DwOb3Aa0o9CApepiYQ==", "dev": true, + "license": "MIT", "dependencies": { "@jridgewell/resolve-uri": "^3.1.0", "@jridgewell/sourcemap-codec": "^1.4.14" } }, "node_modules/@remusao/guess-url-type": { - "version": "1.3.0", - "resolved": "https://registry.npmjs.org/@remusao/guess-url-type/-/guess-url-type-1.3.0.tgz", - "integrity": "sha512-SNSJGxH5ckvxb3EUHj4DqlAm/bxNxNv2kx/AESZva/9VfcBokwKNS+C4D1lQdWIDM1R3d3UG+xmVzlkNG8CPTQ==" + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/@remusao/guess-url-type/-/guess-url-type-2.0.0.tgz", + "integrity": "sha512-L98gV/X/GESt5Tgqq/PxpZYClVqeq6/5InrRKl4elq4qXbdZjHlNTgRhXb1xIaUBkikzv410sXw3QaBUYyXt8g==", + "license": "MPL-2.0" }, "node_modules/@remusao/small": { - "version": "1.3.0", - "resolved": "https://registry.npmjs.org/@remusao/small/-/small-1.3.0.tgz", - "integrity": "sha512-bydAhJI+ywmg5xMUcbqoR8KahetcfkFywEZpsyFZ8EBofilvWxbXnMSe4vnjDI1Y+SWxnNhR4AL/2BAXkf4b8A==" + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/@remusao/small/-/small-2.0.0.tgz", + "integrity": "sha512-1ksGCbl1hSeO4CV/uk0qv2vUdZ1ZRdIMzSn0HFsHTJnmWSDk2li+T5eCI9BtweYe0uVQhCvbMjk/3qwsN6fuYg==", + "license": "MPL-2.0" }, "node_modules/@remusao/smaz": { - "version": "1.10.0", - "resolved": "https://registry.npmjs.org/@remusao/smaz/-/smaz-1.10.0.tgz", - "integrity": "sha512-GQzCxmmMpLkyZwcwNgz8TpuBEWl0RUQa8IcvKiYlPxuyYKqyqPkCr0hlHI15ckn3kDUPS68VmTVgyPnLNrdVmg==", + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/@remusao/smaz/-/smaz-2.1.0.tgz", + "integrity": "sha512-hTn/ZuBY4LYaqvprTdW3U+uU4xrw5JusxqHIhUzroQlrT6l4LFQRi+aJE/SOv09iS7eO/pqg6Ec3Go+gKiWH8A==", + "license": "MPL-2.0", "dependencies": { - "@remusao/smaz-compress": "^1.10.0", - "@remusao/smaz-decompress": "^1.10.0" + "@remusao/smaz-compress": "^2.1.0", + "@remusao/smaz-decompress": "^2.1.0" } }, "node_modules/@remusao/smaz-compress": { - "version": "1.10.0", - "resolved": "https://registry.npmjs.org/@remusao/smaz-compress/-/smaz-compress-1.10.0.tgz", - "integrity": "sha512-E/lC8OSU+3bQrUl64vlLyPzIxo7dxF2RvNBe9KzcM4ax43J/d+YMinmMztHyCIHqRbz7rBCtkp3c0KfeIbHmEg==", + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/@remusao/smaz-compress/-/smaz-compress-2.1.0.tgz", + "integrity": "sha512-IyuzXxd5F1p5WAvA6Td9ny+wh3sj9szMmdZtQ8Fb5/yE4lIwujXCz0e702u62r3XU47qsQcR/CjSRaw65u7iGA==", + "license": "MPL-2.0", "dependencies": { - "@remusao/trie": "^1.5.0" + "@remusao/trie": "^2.0.0" } }, "node_modules/@remusao/smaz-decompress": { - "version": "1.10.0", - "resolved": "https://registry.npmjs.org/@remusao/smaz-decompress/-/smaz-decompress-1.10.0.tgz", - "integrity": "sha512-aA5ImUH480Pcs5/cOgToKmFnzi7osSNG6ft+7DdmQTaQEEst3nLq3JLlBEk+gwidURymjbx6DYs60LHaZ415VQ==" + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/@remusao/smaz-decompress/-/smaz-decompress-2.1.0.tgz", + "integrity": "sha512-TlM/ibBOMiCRniuBjv4x4nIcVbOb1o6DdK+p5OM+zHNndEu9za2C1Bd+PSqnsVCn15Fv2HcLVWGpqh2hKs9uuw==", + "license": "MPL-2.0" }, "node_modules/@remusao/trie": { - "version": "1.5.0", - "resolved": "https://registry.npmjs.org/@remusao/trie/-/trie-1.5.0.tgz", - "integrity": "sha512-UX+3utJKgwCsg6sUozjxd38gNMVRXrY4TNX9VvCdSrlZBS1nZjRPi98ON3QjRAdf6KCguJFyQARRsulTeqQiPg==" + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/@remusao/trie/-/trie-2.0.0.tgz", + "integrity": "sha512-YmVfZrd+igKXJMuAvsNdDnUAyoNw7M+9e2ij6UsaZFZGQzLd75pbxhiuFmdphEXi/s3uXe25+wtFRWjLA2Ho0Q==", + "license": "MPL-2.0" }, "node_modules/@rollup/plugin-json": { "version": "4.1.0", "resolved": "https://registry.npmjs.org/@rollup/plugin-json/-/plugin-json-4.1.0.tgz", "integrity": "sha512-yfLbTdNS6amI/2OpmbiBoW12vngr5NW2jCJVZSBEz+H5KfUJZ2M7sDjk0U6GOOdCWFVScShte29o9NezJ53TPw==", "dev": true, + "license": "MIT", "dependencies": { "@rollup/pluginutils": "^3.0.8" }, @@ -223,6 +241,7 @@ "resolved": "https://registry.npmjs.org/@rollup/plugin-node-resolve/-/plugin-node-resolve-13.3.0.tgz", "integrity": "sha512-Lus8rbUo1eEcnS4yTFKLZrVumLPY+YayBdWXgFSHYhTT2iJbMhoaaBL3xl5NCdeRytErGr8tZ0L71BMRmnlwSw==", "dev": true, + "license": "MIT", "dependencies": { "@rollup/pluginutils": "^3.1.0", "@types/resolve": "1.17.1", @@ -243,6 +262,7 @@ "resolved": "https://registry.npmjs.org/@rollup/pluginutils/-/pluginutils-3.1.0.tgz", "integrity": "sha512-GksZ6pr6TpIjHm8h9lSQ8pi8BE9VeubNT0OMJ3B5uZJ8pz73NPiqOtCog/x2/QzM1ENChPKxMDhiQuRHsqc+lg==", "dev": true, + "license": "MIT", "dependencies": { "@types/estree": "0.0.39", "estree-walker": "^1.0.1", @@ -259,13 +279,15 @@ "version": "0.0.39", "resolved": "https://registry.npmjs.org/@types/estree/-/estree-0.0.39.tgz", "integrity": "sha512-EYNwp3bU+98cpU4lAWYYL7Zz+2gryWH1qbdDTidVd6hkiR6weksdbMadyXKXNPEkQFhXM+hVO9ZygomHXp+AIw==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/@types/node": { - "version": "22.14.0", - "resolved": "https://registry.npmjs.org/@types/node/-/node-22.14.0.tgz", - "integrity": "sha512-Kmpl+z84ILoG+3T/zQFyAJsU6EPTmOCj8/2+83fSN6djd6I4o7uOuGIH6vq3PrjY5BGitSbFuMN18j3iknubbA==", + "version": "22.14.1", + "resolved": "https://registry.npmjs.org/@types/node/-/node-22.14.1.tgz", + "integrity": "sha512-u0HuPQwe/dHrItgHHpmw3N2fYCR6x4ivMNbPHRkBVP4CvN+kiRrKHWk3i8tXiO/joPwXLMYvF9TTF0eqgHIuOw==", "dev": true, + "license": "MIT", "dependencies": { "undici-types": "~6.21.0" } @@ -275,6 +297,7 @@ "resolved": "https://registry.npmjs.org/@types/resolve/-/resolve-1.17.1.tgz", "integrity": "sha512-yy7HuzQhj0dhGpD8RLXSZWEkLsV9ibvxvi6EiJ3bkqLAO1RGo0WbkWQiwpRlSFymTJRz0d3k5LM3kkx8ArDbLw==", "dev": true, + "license": "MIT", "dependencies": { "@types/node": "*" } @@ -284,6 +307,7 @@ "resolved": "https://registry.npmjs.org/acorn/-/acorn-8.14.1.tgz", "integrity": "sha512-OvQ/2pUDKmgfCg++xsTX1wGxfTaszcHVcTctW4UJB4hibJx2HXxxO5UmVgyjMa+ZDsiaf5wWLXYpRWMmBI0QHg==", "dev": true, + "license": "MIT", "bin": { "acorn": "bin/acorn" }, @@ -295,13 +319,15 @@ "version": "1.1.2", "resolved": "https://registry.npmjs.org/buffer-from/-/buffer-from-1.1.2.tgz", "integrity": "sha512-E+XQCRwSbaaiChtv6k6Dwgc+bx+Bs6vuKJHHl5kox/BaKbhiXzqQOwK4cO22yElGp2OCmjwVhT3HmxgyPGnJfQ==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/builtin-modules": { "version": "3.3.0", "resolved": "https://registry.npmjs.org/builtin-modules/-/builtin-modules-3.3.0.tgz", "integrity": "sha512-zhaCDicdLuWN5UbN5IMnFqNMhNfo919sH85y2/ea+5Yg9TsTkeZxpL+JLbp6cgYFS4sRLp3YV4S6yDuqVWHYOw==", "dev": true, + "license": "MIT", "engines": { "node": ">=6" }, @@ -313,13 +339,15 @@ "version": "2.20.3", "resolved": "https://registry.npmjs.org/commander/-/commander-2.20.3.tgz", "integrity": "sha512-GpVkmM8vF2vQUkj2LvZmD35JxeJOLCwJ9cUkugyk2nuhbv3+mJvpLYYt+0+USMxE+oj+ey/lJEnhZw75x/OMcQ==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/deepmerge": { "version": "4.3.1", "resolved": "https://registry.npmjs.org/deepmerge/-/deepmerge-4.3.1.tgz", "integrity": "sha512-3sUqbMEc77XqpdNO7FRyRog+eW3ph+GYCbj+rK+uYyRMuwsVy0rMiVtPn+QJlKFvWP/1PYpapqYn0Me2knFn+A==", "dev": true, + "license": "MIT", "engines": { "node": ">=0.10.0" } @@ -328,7 +356,8 @@ "version": "1.0.1", "resolved": "https://registry.npmjs.org/estree-walker/-/estree-walker-1.0.1.tgz", "integrity": "sha512-1fMXF3YP4pZZVozF8j/ZLfvnR8NSIljt56UhbZ5PeeDmmGHpgpdwQt7ITlGvYaQukCvuBRMLEiKiYC+oeIg4cg==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/fsevents": { "version": "2.3.3", @@ -336,6 +365,7 @@ "integrity": "sha512-5xoDfX+fL7faATnagmWPpbFtwh/R77WmMMqqHGS65C3vvB0YHrgF+B1YmZ3441tMj5n63k0212XNoJwzlhffQw==", "dev": true, "hasInstallScript": true, + "license": "MIT", "optional": true, "os": [ "darwin" @@ -349,6 +379,7 @@ "resolved": "https://registry.npmjs.org/function-bind/-/function-bind-1.1.2.tgz", "integrity": "sha512-7XHNxH7qX9xG5mIwxkhumTox/MIRNcOgDrxWsMt2pAr23WHp6MrRlN7FBSFpCpr+oVO0F744iUgR82nJMfG2SA==", "dev": true, + "license": "MIT", "funding": { "url": "https://github.com/sponsors/ljharb" } @@ -358,6 +389,7 @@ "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", "dev": true, + "license": "MIT", "engines": { "node": ">=8" } @@ -367,6 +399,7 @@ "resolved": "https://registry.npmjs.org/hasown/-/hasown-2.0.2.tgz", "integrity": "sha512-0hJU9SCPvmMzIBdZFqNPXWa6dqh7WdH0cII9y+CyS8rG3nL48Bclra9HmKhVVUHyPWNH5Y7xDwAB7bfgSjkUMQ==", "dev": true, + "license": "MIT", "dependencies": { "function-bind": "^1.1.2" }, @@ -377,13 +410,15 @@ "node_modules/immutable-json-patch": { "version": "6.0.1", "resolved": "https://registry.npmjs.org/immutable-json-patch/-/immutable-json-patch-6.0.1.tgz", - "integrity": "sha512-BHL/cXMjwFZlTOffiWNdY8ZTvNyYLrutCnWxrcKPHr5FqpAb6vsO6WWSPnVSys3+DruFN6lhHJJPHi8uELQL5g==" + "integrity": "sha512-BHL/cXMjwFZlTOffiWNdY8ZTvNyYLrutCnWxrcKPHr5FqpAb6vsO6WWSPnVSys3+DruFN6lhHJJPHi8uELQL5g==", + "license": "ISC" }, "node_modules/is-builtin-module": { "version": "3.2.1", "resolved": "https://registry.npmjs.org/is-builtin-module/-/is-builtin-module-3.2.1.tgz", "integrity": "sha512-BSLE3HnV2syZ0FK0iMA/yUGplUeMmNz4AW5fnTunbCIqZi4vG3WjJT9FHMy5D69xmAYBHXQhJdALdpwVxV501A==", "dev": true, + "license": "MIT", "dependencies": { "builtin-modules": "^3.3.0" }, @@ -399,6 +434,7 @@ "resolved": "https://registry.npmjs.org/is-core-module/-/is-core-module-2.16.1.tgz", "integrity": "sha512-UfoeMA6fIJ8wTYFEUjelnaGI67v6+N7qXJEvQuIGa99l4xsCruSYOVSQ0uPANn4dAzm8lkYPaKLrrijLq7x23w==", "dev": true, + "license": "MIT", "dependencies": { "hasown": "^2.0.2" }, @@ -413,13 +449,15 @@ "version": "1.0.0", "resolved": "https://registry.npmjs.org/is-module/-/is-module-1.0.0.tgz", "integrity": "sha512-51ypPSPCoTEIN9dy5Oy+h4pShgJmPCygKfyRCISBI+JoWT/2oJvK8QPxmwv7b/p239jXrm9M1mlQbyKJ5A152g==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/jest-worker": { "version": "26.6.2", "resolved": "https://registry.npmjs.org/jest-worker/-/jest-worker-26.6.2.tgz", "integrity": "sha512-KWYVV1c4i+jbMpaBC+U++4Va0cp8OisU185o73T1vo99hqi7w8tSJfUXYswwqqrjzwxa6KpRK54WhPvwf5w6PQ==", "dev": true, + "license": "MIT", "dependencies": { "@types/node": "*", "merge-stream": "^2.0.0", @@ -433,31 +471,36 @@ "version": "4.0.0", "resolved": "https://registry.npmjs.org/js-tokens/-/js-tokens-4.0.0.tgz", "integrity": "sha512-RdJUflcE3cUzKiMqQgsCu06FPu9UdIJO0beYbPhHN4k6apgJtifcoCtT9bcxOpYBtpD2kCM6Sbzg4CausW/PKQ==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/merge-stream": { "version": "2.0.0", "resolved": "https://registry.npmjs.org/merge-stream/-/merge-stream-2.0.0.tgz", "integrity": "sha512-abv/qOcuPfk3URPfDzmZU1LKmuw8kT+0nIHvKrKgFrwifol/doWcdA4ZqsWQ8ENrFKkd67Mfpo/LovbIUsbt3w==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/path-parse": { "version": "1.0.7", "resolved": "https://registry.npmjs.org/path-parse/-/path-parse-1.0.7.tgz", "integrity": "sha512-LDJzPVEEEPR+y48z93A0Ed0yXb8pAByGWo/k5YYdYgpY2/2EsOsksJrq7lOHxryrVOn1ejG6oAp8ahvOIQD8sw==", - "dev": true + "dev": true, + "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==", - "dev": true + "dev": true, + "license": "ISC" }, "node_modules/picomatch": { "version": "2.3.1", "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-2.3.1.tgz", "integrity": "sha512-JU3teHTNjmE2VCGFzuY8EXzCDVwEqB2a8fsIvwaStHhAWJEeVd1o1QD80CU6+ZdEXXSLbSsuLwJjkCBWqRQUVA==", "dev": true, + "license": "MIT", "engines": { "node": ">=8.6" }, @@ -470,6 +513,7 @@ "resolved": "https://registry.npmjs.org/randombytes/-/randombytes-2.1.0.tgz", "integrity": "sha512-vYl3iOX+4CKUWuxGi9Ukhie6fsqXqS9FE2Zaic4tNFD2N2QQaXOMFbuKK4QmDHC0JO6B1Zp41J0LpT0oR68amQ==", "dev": true, + "license": "MIT", "dependencies": { "safe-buffer": "^5.1.0" } @@ -479,6 +523,7 @@ "resolved": "https://registry.npmjs.org/resolve/-/resolve-1.22.10.tgz", "integrity": "sha512-NPRy+/ncIMeDlTAsuqwKIiferiawhefFJtkNSW0qZJEqMEb+qBt/77B/jGeeek+F0uOeN05CDa6HXbbIgtVX4w==", "dev": true, + "license": "MIT", "dependencies": { "is-core-module": "^2.16.0", "path-parse": "^1.0.7", @@ -499,6 +544,7 @@ "resolved": "https://registry.npmjs.org/rollup/-/rollup-2.79.2.tgz", "integrity": "sha512-fS6iqSPZDs3dr/y7Od6y5nha8dW1YnbgtsyotCVvoFGKbERG++CVRFv1meyGDE1SNItQA8BrnCw7ScdAhRJ3XQ==", "dev": true, + "license": "MIT", "bin": { "rollup": "dist/bin/rollup" }, @@ -515,6 +561,7 @@ "integrity": "sha512-w3iIaU4OxcF52UUXiZNsNeuXIMDvFrr+ZXK6bFZ0Q60qyVfq4uLptoS4bbq3paG3x216eQllFZX7zt6TIImguQ==", "deprecated": "This package has been deprecated and is no longer maintained. Please use @rollup/plugin-terser", "dev": true, + "license": "MIT", "dependencies": { "@babel/code-frame": "^7.10.4", "jest-worker": "^26.2.1", @@ -543,13 +590,15 @@ "type": "consulting", "url": "https://feross.org/support" } - ] + ], + "license": "MIT" }, "node_modules/serialize-javascript": { "version": "4.0.0", "resolved": "https://registry.npmjs.org/serialize-javascript/-/serialize-javascript-4.0.0.tgz", "integrity": "sha512-GaNA54380uFefWghODBWEGisLZFj00nS5ACs6yHa9nLqlLpVLO8ChDGeKRjZnV4Nh4n0Qi7nhYZD/9fCPzEqkw==", "dev": true, + "license": "BSD-3-Clause", "dependencies": { "randombytes": "^2.1.0" } @@ -559,6 +608,7 @@ "resolved": "https://registry.npmjs.org/source-map/-/source-map-0.6.1.tgz", "integrity": "sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g==", "dev": true, + "license": "BSD-3-Clause", "engines": { "node": ">=0.10.0" } @@ -568,6 +618,7 @@ "resolved": "https://registry.npmjs.org/source-map-support/-/source-map-support-0.5.21.tgz", "integrity": "sha512-uBHU3L3czsIyYXKX88fdrGovxdSCoTGDRZ6SYXtSRxLZUzHg5P/66Ht6uoUlHu9EZod+inXhKo3qQgwXUT/y1w==", "dev": true, + "license": "MIT", "dependencies": { "buffer-from": "^1.0.0", "source-map": "^0.6.0" @@ -578,6 +629,7 @@ "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", "dev": true, + "license": "MIT", "dependencies": { "has-flag": "^4.0.0" }, @@ -590,6 +642,7 @@ "resolved": "https://registry.npmjs.org/supports-preserve-symlinks-flag/-/supports-preserve-symlinks-flag-1.0.0.tgz", "integrity": "sha512-ot0WnXS9fgdkgIcePe6RHNk1WA8+muPa6cSjeR3V8K27q9BB1rTE3R1p7Hv0z1ZyAc8s6Vvv8DIyWf681MAt0w==", "dev": true, + "license": "MIT", "engines": { "node": ">= 0.4" }, @@ -602,6 +655,7 @@ "resolved": "https://registry.npmjs.org/terser/-/terser-5.39.0.tgz", "integrity": "sha512-LBAhFyLho16harJoWMg/nZsQYgTrg5jXOn2nCYjRUcZZEdE3qa2zb8QEDRUGVZBW4rlazf2fxkg8tztybTaqWw==", "dev": true, + "license": "BSD-2-Clause", "dependencies": { "@jridgewell/source-map": "^0.3.3", "acorn": "^8.8.2", @@ -616,18 +670,18 @@ } }, "node_modules/tldts-core": { - "version": "6.1.85", - "resolved": "https://registry.npmjs.org/tldts-core/-/tldts-core-6.1.85.tgz", - "integrity": "sha512-DTjUVvxckL1fIoPSb3KE7ISNtkWSawZdpfxGxwiIrZoO6EbHVDXXUIlIuWympPaeS+BLGyggozX/HTMsRAdsoA==", + "version": "6.1.86", + "resolved": "https://registry.npmjs.org/tldts-core/-/tldts-core-6.1.86.tgz", + "integrity": "sha512-Je6p7pkk+KMzMv2XXKmAE3McmolOQFdxkKw0R8EYNr7sELW46JqnNeTX8ybPiQgvg1ymCoF8LXs5fzFaZvJPTA==", "license": "MIT" }, "node_modules/tldts-experimental": { - "version": "6.1.85", - "resolved": "https://registry.npmjs.org/tldts-experimental/-/tldts-experimental-6.1.85.tgz", - "integrity": "sha512-oM+m5GnOdxgbnfSfix98YvzAIgkKZbdqMD/BTLbnbL349MyaEeNo6z8jVX9/lrL6DvnjgW7RV+sIVojrFvB+hw==", + "version": "6.1.86", + "resolved": "https://registry.npmjs.org/tldts-experimental/-/tldts-experimental-6.1.86.tgz", + "integrity": "sha512-X3N3+SrwSajvANDyIBFa6tf/nO0VoqaXvvINSnQkZMGbzNlD+9G7Xb24Mtk3ZBVZJRGY7UynAJJL8kRVt6Z46Q==", "license": "MIT", "dependencies": { - "tldts-core": "^6.1.85" + "tldts-core": "^6.1.86" } }, "node_modules/undici-types": { diff --git a/package.json b/package.json index db14e2cac0b9..7f83d90edb6e 100644 --- a/package.json +++ b/package.json @@ -15,7 +15,7 @@ "dependencies": { "@duckduckgo/autoconsent": "^12.17.0", "@duckduckgo/autofill": "github:duckduckgo/duckduckgo-autofill#17.1.0", - "@duckduckgo/content-scope-scripts": "github:duckduckgo/content-scope-scripts#8.14.0", + "@duckduckgo/content-scope-scripts": "github:duckduckgo/content-scope-scripts#8.16.0", "@duckduckgo/privacy-dashboard": "github:duckduckgo/privacy-dashboard#8.4.0", "@duckduckgo/privacy-reference-tests": "github:duckduckgo/privacy-reference-tests#1743747763" }