@flesh-and-blood/search 2.0.143 → 2.0.144

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/dist/index.js +1 -1
  2. package/package.json +4 -4
package/dist/index.js CHANGED
@@ -1,2 +1,2 @@
1
- var Kr=Object.create;var ce=Object.defineProperty,Ur=Object.defineProperties,Yr=Object.getOwnPropertyDescriptor,Vr=Object.getOwnPropertyDescriptors,Qr=Object.getOwnPropertyNames,bt=Object.getOwnPropertySymbols,Jr=Object.getPrototypeOf,Mt=Object.prototype.hasOwnProperty,Zr=Object.prototype.propertyIsEnumerable;var At=(e,t,r)=>t in e?ce(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,ne=(e,t)=>{for(var r in t||(t={}))Mt.call(t,r)&&At(e,r,t[r]);if(bt)for(var r of bt(t))Zr.call(t,r)&&At(e,r,t[r]);return e},Ct=(e,t)=>Ur(e,Vr(t));var kt=(e,t)=>()=>(t||e((t={exports:{}}).exports,t),t.exports),Xr=(e,t)=>{for(var r in t)ce(e,r,{get:t[r],enumerable:!0})},Ft=(e,t,r,i)=>{if(t&&typeof t=="object"||typeof t=="function")for(let n of Qr(t))!Mt.call(e,n)&&n!==r&&ce(e,n,{get:()=>t[n],enumerable:!(i=Yr(t,n))||i.enumerable});return e};var W=(e,t,r)=>(r=e!=null?Kr(Jr(e)):{},Ft(t||!e||!e.__esModule?ce(r,"default",{value:e,enumerable:!0}):r,e)),qr=e=>Ft(ce({},"__esModule",{value:!0}),e);var j=kt((Ja,Gt)=>{var fe=Object.defineProperty,ei=Object.defineProperties,ti=Object.getOwnPropertyDescriptor,ri=Object.getOwnPropertyDescriptors,ii=Object.getOwnPropertyNames,Tt=Object.getOwnPropertySymbols,xt=Object.prototype.hasOwnProperty,ni=Object.prototype.propertyIsEnumerable,St=(e,t,r)=>t in e?fe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,ai=(e,t)=>{for(var r in t||(t={}))xt.call(t,r)&&St(e,r,t[r]);if(Tt)for(var r of Tt(t))ni.call(t,r)&&St(e,r,t[r]);return e},oi=(e,t)=>ei(e,ri(t)),si=(e,t)=>{for(var r in t)fe(e,r,{get:t[r],enumerable:!0})},li=(e,t,r,i)=>{if(t&&typeof t=="object"||typeof t=="function")for(let n of ii(t))!xt.call(e,n)&&n!==r&&fe(e,n,{get:()=>t[n],enumerable:!(i=ti(t,n))||i.enumerable});return e},ci=e=>li(fe({},"__esModule",{value:!0}),e),Lt={};si(Lt,{Class:()=>Pt,Foiling:()=>wt,Format:()=>Dt,Fusion:()=>Rt,Hero:()=>Ht,Keyword:()=>$t,Rarity:()=>It,Release:()=>Et,ReleaseEdition:()=>_t,Subtype:()=>Nt,Talent:()=>Ot,Treatment:()=>Bt,Type:()=>zt,fullSetIdentifiers:()=>Wt,getPrint:()=>di,setIdentifierToSetMappings:()=>jt,setToSetIdentifierMappings:()=>pi});Gt.exports=ci(Lt);var wt=(e=>(e.C="Cold",e.G="Gold",e.R="Rainbow",e))(wt||{}),Bt=(e=>(e.AB="Alternate Border",e.AA="Alternate Art",e.AT="Alternate Text",e.EA="Extended Art",e.FA="Full Art",e))(Bt||{}),Pt=(e=>(e.NotClassed="NotClassed",e.Generic="Generic",e.Adjudicator="Adjudicator",e.Assassin="Assassin",e.Bard="Bard",e.Brute="Brute",e.Guardian="Guardian",e.Illusionist="Illusionist",e.Mechanologist="Mechanologist",e.Merchant="Merchant",e.Ninja="Ninja",e.Ranger="Ranger",e.Runeblade="Runeblade",e.Shapeshifter="Shapeshifter",e.Warrior="Warrior",e.Wizard="Wizard",e))(Pt||{}),Dt=(e=>(e.Blitz="Blitz",e.BlitzLivingLegend="Blitz (Living Legend)",e.Clash="Clash",e.ClassicConstructed="Classic Constructed",e.ClassicConstructedLivingLegend="Classic Constructed (Living Legend)",e.Commoner="Commoner",e.Draft="Draft",e.Open="Open",e.Sealed="Sealed",e.UltimatePitFight="Ultimate Pit Fight",e))(Dt||{}),Rt=(e=>(e.Earth="Earth",e.Ice="Ice",e.Lightning="Lightning",e))(Rt||{}),It=(e=>(e.Token="Token",e.Common="Common",e.Rare="Rare",e.SuperRare="Super Rare",e.Majestic="Majestic",e.Marvel="Marvel",e.Legendary="Legendary",e.Fabled="Fabled",e.Promo="Promo",e))(It||{}),Et=(e=>(e.ArcaneRising="Arcane Rising",e.BrightLights="Bright Lights",e.CrucibleOfWar="Crucible of War",e.DuskTillDawn="Dusk till Dawn",e.Dynasty="Dynasty",e.Everfest="Everfest",e.HeavyHitters="Heavy Hitters",e.HistoryPack1="History Pack 1",e.Monarch="Monarch",e.Outsiders="Outsiders",e.PartTheMistveil="Part the Mistveil",e.TalesOfAria="Tales of Aria",e.Uprising="Uprising",e.WelcomeToRathe="Welcome to Rathe",e.ArmoryDeckKayo="Armory Deck: Kayo",e.ArmoryDeckBoltyn="Armory Deck: Boltyn",e.ArakniBlitzDeck="Arakni Blitz Deck",e.AzaleaBlitzDeck="Azalea Blitz Deck",e.BenjiBlitzDeck="Benji Blitz Deck",e.BetsyBlitzDeck="Betsy Blitz Deck",e.BoltynBlitzDeck="Boltyn Blitz Deck",e.BriarBlitzDeck="Briar Blitz Deck",e.BravoBlitzDeck="Bravo Blitz Deck",e.ChaneBlitzDeck="Chane Blitz Deck",e.DromaiBlitzDeck="Dromai Blitz Deck",e.EnigmaBlitzDeck="Enigma Blitz Deck",e.FaiBlitzDeck="Fai Blitz Deck",e.KassaiBlitzDeck="Kassai Blitz Deck",e.KatsuBlitzDeck="Katsu Blitz Deck",e.KayoBlitzDeck="Kayo Blitz Deck",e.LeviaBlitzDeck="Levia Blitz Deck",e.LexiBlitzDeck="Lexi Blitz Deck",e.NuuBlitzDeck="Nuu Blitz Deck",e.OldhimBlitzDeck="Oldhim Blitz Deck",e.OlympiaBlitzDeck="Olympia Blitz Deck",e.PrismBlitzDeck="Prism Blitz Deck",e.RhinarBlitzDeck="Rhinar Blitz Deck",e.RiptideBlitzDeck="Riptide Blitz Deck",e.UzuriBlitzDeck="Uzuri Blitz Deck",e.VictorBlitzDeck="Victor Blitz Deck",e.ZenBlitzDeck="Zen Blitz Deck",e.DorintheaHeroDeck="Dorinthea Hero Deck",e.KatsuHeroDeck="Katsu Hero Deck",e.RhinarHeroDeck="Rhinar Hero Deck",e.ClassicBattlesRhinarDorinthea="Classic Battles: Rhinar vs Dorinthea",e.IraWelcomeDeck="Ira Welcome Deck",e.RoundTheTable="Round the Table",e.Promos="Promos",e))(Et||{}),_t=(e=>(e.Alpha="Alpha",e.First="First",e.Unlimited="Unlimited",e.Promo="Promo",e))(_t||{}),Ot=(e=>(e.Draconic="Draconic",e.Earth="Earth",e.Elemental="Elemental",e.Ice="Ice",e.Light="Light",e.Lightning="Lightning",e.Mystic="Mystic",e.Royal="Royal",e.Shadow="Shadow",e))(Ot||{}),zt=(e=>(e.Action="Action",e.AttackReaction="Attack Reaction",e.Block="Block",e.DefenseReaction="Defense Reaction",e.DemiHero="Demi-Hero",e.Equipment="Equipment",e.Hero="Hero",e.Instant="Instant",e.Mentor="Mentor",e.Resource="Resource",e.Token="Token",e.Weapon="Weapon",e))(zt||{}),Nt=(e=>(e.OneHanded="1H",e.TwoHanded="2H",e.Affliction="Affliction",e.Ally="Ally",e.Angel="Angel",e.Arms="Arms",e.Arrow="Arrow",e.Ash="Ash",e.Attack="Attack",e.Aura="Aura",e.Axe="Axe",e.Base="Base",e.Book="Book",e.Bow="Bow",e.Chest="Chest",e.Chi="Chi",e.Claw="Claw",e.Club="Club",e.Construct="Construct",e.Dagger="Dagger",e.Demon="Demon",e.Dragon="Dragon",e.Evo="Evo",e.Fiddle="Fiddle",e.Figment="Figment",e.Flail="Flail",e.Gem="Gem",e.Gun="Gun",e.Hammer="Hammer",e.Head="Head",e.Invocation="Invocation",e.Item="Item",e.Landmark="Landmark",e.Lute="Lute",e.Legs="Legs",e.NonAttack="Non-Attack",e.OffHand="Off-Hand",e.Orb="Orb",e.Pistol="Pistol",e.Quiver="Quiver",e.Rock="Rock",e.Shuriken="Shuriken",e.Scepter="Scepter",e.Scroll="Scroll",e.Scythe="Scythe",e.Song="Song",e.Staff="Staff",e.Sword="Sword",e.Trap="Trap",e.Wrench="Wrench",e.Young="Young",e))(Nt||{}),Ht=(e=>(e.Arakni="Arakni",e.Azalea="Azalea",e.Benji="Benji",e.Betsy="Betsy",e.Boltyn="Boltyn",e.Bravo="Bravo",e.Brevant="Brevant",e.Briar="Briar",e.Brutus="Brutus",e.Chane="Chane",e.Dash="Dash",e.DataDoll="Data Doll",e.Dorinthea="Dorinthea",e.Dromai="Dromai",e.Emperor="Emperor",e.Enigma="Enigma",e.Fai="Fai",e.GenisWotchuneed="Genis Wotchuneed",e.Ira="Ira",e.Iyslander="Iyslander",e.Kano="Kano",e.Kassai="Kassai",e.Katsu="Katsu",e.Kavdaen="Kavdaen",e.Kayo="Kayo",e.Levia="Levia",e.Lexi="Lexi",e.Maxx="Maxx",e.Melody="Melody",e.Nuu="Nuu",e.Oldhim="Oldhim",e.Olympia="Olympia",e.Prism="Prism",e.Rhinar="Rhinar",e.Riptide="Riptide",e.Ruudi="Ruu'di",e.Shiyana="Shiyana",e.Squizzy="Squizzy",e.Taipanis="Taipanis",e.Taylor="Taylor",e.Teklovossen="Teklovossen",e.Theryon="Theryon",e.Uzuri="Uzuri",e.Valda="Valda",e.Victor="Victor",e.Vynnset="Vynnset",e.Viserai="Viserai",e.Yorick="Yorick",e.Yoji="Yoji",e.Zen="Zen",e))(Ht||{}),$t=(e=>(e.Ambush="Ambush",e.Amp="Amp",e.ArcaneBarrier="Arcane Barrier",e.Awaken="Awaken",e.Battleworn="Battleworn",e.BeatChest="Beat Chest",e.BladeBreak="Blade Break",e.BloodDebt="Blood Debt",e.Boost="Boost",e.Channel="Channel",e.Charge="Charge",e.Clash="Clash",e.Cloaked="Cloaked",e.Combo="Combo",e.Contract="Contract",e.Crank="Crank",e.Crush="Crush",e.Dominate="Dominate",e.Ephemeral="Ephemeral",e.Essence="Essence",e.EvoUpgrade="Evo Upgrade",e.Freeze="Freeze",e.Fusion="Fusion",e.Galvanize="Galvanize",e.GoAgain="Go again",e.Guardwell="Guardwell",e.Heave="Heave",e.Intimidate="Intimidate",e.Legendary="Legendary",e.Material="Material",e.Modular="Modular",e.Mirage="Mirage",e.Negate="Negate",e.Opt="Opt",e.Overpower="Overpower",e.Pairs="Pairs",e.Piercing="Piercing",e.Phantasm="Phantasm",e.Protect="Protect",e.Quell="Quell",e.Reload="Reload",e.Reprise="Reprise",e.RuneGate="Rune Gate",e.Rupture="Rupture",e.Scrap="Scrap",e.Solflare="Solflare",e.Specialization="Specialization",e.Spectra="Spectra",e.Spellvoid="Spellvoid",e.Stealth="Stealth",e.Surge="Surge",e.Temper="Temper",e.Tower="Tower",e.Transform="Transform",e.Transcend="Transcend",e.Universal="Universal",e.Unfreeze="Unfreeze",e.Unity="Unity",e.Wager="Wager",e.Ward="Ward",e))($t||{}),ui={"Rhinar Blitz Deck":"-Blitz"},di=e=>{var t;let r=ui[e.set]||"",i=`${e.identifier}${r}`,n=e.edition?`-${e.edition}`:"",a=e.foiling?`-${e.foiling}`:"",s=e.treatment?`-${e.treatment}`:"",o=(t=e.image)!=null&&t.toLowerCase().includes("back")?"-Back":"";return`${i}${n}${a}${s}${o}`},Wt={wtr:"Welcome to Rathe",arc:"Arcane Rising",cru:"Crucible of War",mon:"Monarch",ele:"Tales of Aria",evr:"Everfest","1hp":"History Pack 1",hp1:"History Pack 1",upr:"Uprising",dyn:"Dynasty",out:"Outsiders",dtd:"Dusk till Dawn",evo:"Bright Lights",hvy:"Heavy Hitters",mst:"Part the Mistveil"},jt=oi(ai({},Wt),{ako:"Armory Deck: Kayo",asb:"Armory Deck: Boltyn",ara:"Arakni Blitz Deck",azl:"Azalea Blitz Deck",ben:"Benji Blitz Deck",bet:"Betsy Blitz Deck",bol:"Boltyn Blitz Deck",bri:"Briar Blitz Deck",bvo:"Bravo Blitz Deck",chn:"Chane Blitz Deck",dro:"Dromai Blitz Deck",eng:"Enigma Blitz Deck",fai:"Fai Blitz Deck",kat:"Katsu Blitz Deck",ksi:"Kassai Blitz Deck",kyo:"Kayo Blitz Deck",lev:"Levia Blitz Deck",lxi:"Lexi Blitz Deck",nuu:"Nuu Blitz Deck",old:"Oldhim Blitz Deck",ola:"Olympia Blitz Deck",psm:"Prism Blitz Deck",rip:"Riptide Blitz Deck",rnr:"Rhinar Blitz Deck",uzu:"Uzuri Blitz Deck",vic:"Victor Blitz Deck",zen:"Zen Blitz Deck",dvr:"Classic Battles: Rhinar vs Dorinthea",rvd:"Classic Battles: Rhinar vs Dorinthea",ira:"Ira Welcome Deck",tcc:"Round the Table",tea:"Dorinthea Hero Deck",ksu:"Katsu Hero Deck",rnr2:"Rhinar Hero Deck",fab:"Promos",her:"Promos",jdg:"Promos",lgs:"Promos",lss:"Promos",oxo:"Promos",xxx:"Promos",win:"Promos"}),Ee={};for(let[e,t]of Object.entries(jt)){let r=Ee[t];r?r.push(e):Ee[t]=[e]}var pi=Ee});var lr=kt((Za,sr)=>{"use strict";function Kt(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);t&&(i=i.filter(function(n){return Object.getOwnPropertyDescriptor(e,n).enumerable})),r.push.apply(r,i)}return r}function ae(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?Kt(Object(r),!0).forEach(function(i){ze(e,i,r[i])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):Kt(Object(r)).forEach(function(i){Object.defineProperty(e,i,Object.getOwnPropertyDescriptor(r,i))})}return e}function Oe(e){"@babel/helpers - typeof";return Oe=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Oe(e)}function _(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Ut(e,t){for(var r=0;r<t.length;r++){var i=t[r];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(e,i.key,i)}}function O(e,t,r){return t&&Ut(e.prototype,t),r&&Ut(e,r),Object.defineProperty(e,"prototype",{writable:!1}),e}function ze(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function Q(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");Object.defineProperty(e,"prototype",{value:Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),writable:!1}),t&&Ne(e,t)}function me(e){return me=Object.setPrototypeOf?Object.getPrototypeOf:function(r){return r.__proto__||Object.getPrototypeOf(r)},me(e)}function Ne(e,t){return Ne=Object.setPrototypeOf||function(i,n){return i.__proto__=n,i},Ne(e,t)}function hi(){if(typeof Reflect=="undefined"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch(e){return!1}}function fi(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function gi(e,t){if(t&&(typeof t=="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return fi(e)}function J(e){var t=hi();return function(){var i=me(e),n;if(t){var a=me(this).constructor;n=Reflect.construct(i,arguments,a)}else n=i.apply(this,arguments);return gi(this,n)}}function te(e){return mi(e)||yi(e)||vi(e)||bi()}function mi(e){if(Array.isArray(e))return He(e)}function yi(e){if(typeof Symbol!="undefined"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function vi(e,t){if(e){if(typeof e=="string")return He(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if(r==="Object"&&e.constructor&&(r=e.constructor.name),r==="Map"||r==="Set")return Array.from(e);if(r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return He(e,t)}}function He(e,t){(t==null||t>e.length)&&(t=e.length);for(var r=0,i=new Array(t);r<t;r++)i[r]=e[r];return i}function bi(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
1
+ var Kr=Object.create;var ce=Object.defineProperty,Ur=Object.defineProperties,Yr=Object.getOwnPropertyDescriptor,Vr=Object.getOwnPropertyDescriptors,Qr=Object.getOwnPropertyNames,bt=Object.getOwnPropertySymbols,Jr=Object.getPrototypeOf,Mt=Object.prototype.hasOwnProperty,Zr=Object.prototype.propertyIsEnumerable;var At=(e,t,r)=>t in e?ce(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,ne=(e,t)=>{for(var r in t||(t={}))Mt.call(t,r)&&At(e,r,t[r]);if(bt)for(var r of bt(t))Zr.call(t,r)&&At(e,r,t[r]);return e},Ct=(e,t)=>Ur(e,Vr(t));var kt=(e,t)=>()=>(t||e((t={exports:{}}).exports,t),t.exports),Xr=(e,t)=>{for(var r in t)ce(e,r,{get:t[r],enumerable:!0})},Ft=(e,t,r,i)=>{if(t&&typeof t=="object"||typeof t=="function")for(let n of Qr(t))!Mt.call(e,n)&&n!==r&&ce(e,n,{get:()=>t[n],enumerable:!(i=Yr(t,n))||i.enumerable});return e};var W=(e,t,r)=>(r=e!=null?Kr(Jr(e)):{},Ft(t||!e||!e.__esModule?ce(r,"default",{value:e,enumerable:!0}):r,e)),qr=e=>Ft(ce({},"__esModule",{value:!0}),e);var j=kt((Ja,Gt)=>{var fe=Object.defineProperty,ei=Object.defineProperties,ti=Object.getOwnPropertyDescriptor,ri=Object.getOwnPropertyDescriptors,ii=Object.getOwnPropertyNames,Tt=Object.getOwnPropertySymbols,xt=Object.prototype.hasOwnProperty,ni=Object.prototype.propertyIsEnumerable,St=(e,t,r)=>t in e?fe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,ai=(e,t)=>{for(var r in t||(t={}))xt.call(t,r)&&St(e,r,t[r]);if(Tt)for(var r of Tt(t))ni.call(t,r)&&St(e,r,t[r]);return e},oi=(e,t)=>ei(e,ri(t)),si=(e,t)=>{for(var r in t)fe(e,r,{get:t[r],enumerable:!0})},li=(e,t,r,i)=>{if(t&&typeof t=="object"||typeof t=="function")for(let n of ii(t))!xt.call(e,n)&&n!==r&&fe(e,n,{get:()=>t[n],enumerable:!(i=ti(t,n))||i.enumerable});return e},ci=e=>li(fe({},"__esModule",{value:!0}),e),Lt={};si(Lt,{Class:()=>Pt,Foiling:()=>wt,Format:()=>Dt,Fusion:()=>Rt,Hero:()=>Ht,Keyword:()=>$t,Rarity:()=>It,Release:()=>Et,ReleaseEdition:()=>_t,Subtype:()=>Nt,Talent:()=>Ot,Treatment:()=>Bt,Type:()=>zt,fullSetIdentifiers:()=>Wt,getPrint:()=>di,setIdentifierToSetMappings:()=>jt,setToSetIdentifierMappings:()=>pi});Gt.exports=ci(Lt);var wt=(e=>(e.C="Cold",e.G="Gold",e.R="Rainbow",e))(wt||{}),Bt=(e=>(e.AB="Alternate Border",e.AA="Alternate Art",e.AT="Alternate Text",e.EA="Extended Art",e.FA="Full Art",e))(Bt||{}),Pt=(e=>(e.NotClassed="NotClassed",e.Generic="Generic",e.Adjudicator="Adjudicator",e.Assassin="Assassin",e.Bard="Bard",e.Brute="Brute",e.Guardian="Guardian",e.Illusionist="Illusionist",e.Mechanologist="Mechanologist",e.Merchant="Merchant",e.Ninja="Ninja",e.Ranger="Ranger",e.Runeblade="Runeblade",e.Shapeshifter="Shapeshifter",e.Warrior="Warrior",e.Wizard="Wizard",e))(Pt||{}),Dt=(e=>(e.Blitz="Blitz",e.BlitzLivingLegend="Blitz (Living Legend)",e.Clash="Clash",e.ClassicConstructed="Classic Constructed",e.ClassicConstructedLivingLegend="Classic Constructed (Living Legend)",e.Commoner="Commoner",e.Draft="Draft",e.Open="Open",e.Sealed="Sealed",e.UltimatePitFight="Ultimate Pit Fight",e))(Dt||{}),Rt=(e=>(e.Earth="Earth",e.Ice="Ice",e.Lightning="Lightning",e))(Rt||{}),It=(e=>(e.Token="Token",e.Common="Common",e.Rare="Rare",e.SuperRare="Super Rare",e.Majestic="Majestic",e.Marvel="Marvel",e.Legendary="Legendary",e.Fabled="Fabled",e.Promo="Promo",e))(It||{}),Et=(e=>(e.ArcaneRising="Arcane Rising",e.BrightLights="Bright Lights",e.CrucibleOfWar="Crucible of War",e.DuskTillDawn="Dusk till Dawn",e.Dynasty="Dynasty",e.Everfest="Everfest",e.HeavyHitters="Heavy Hitters",e.HistoryPack1="History Pack 1",e.Monarch="Monarch",e.Outsiders="Outsiders",e.PartTheMistveil="Part the Mistveil",e.TalesOfAria="Tales of Aria",e.Uprising="Uprising",e.WelcomeToRathe="Welcome to Rathe",e.ArmoryDeckKayo="Armory Deck: Kayo",e.ArmoryDeckBoltyn="Armory Deck: Boltyn",e.ArakniBlitzDeck="Arakni Blitz Deck",e.AzaleaBlitzDeck="Azalea Blitz Deck",e.BenjiBlitzDeck="Benji Blitz Deck",e.BetsyBlitzDeck="Betsy Blitz Deck",e.BoltynBlitzDeck="Boltyn Blitz Deck",e.BriarBlitzDeck="Briar Blitz Deck",e.BravoBlitzDeck="Bravo Blitz Deck",e.ChaneBlitzDeck="Chane Blitz Deck",e.DromaiBlitzDeck="Dromai Blitz Deck",e.EnigmaBlitzDeck="Enigma Blitz Deck",e.FaiBlitzDeck="Fai Blitz Deck",e.KassaiBlitzDeck="Kassai Blitz Deck",e.KatsuBlitzDeck="Katsu Blitz Deck",e.KayoBlitzDeck="Kayo Blitz Deck",e.LeviaBlitzDeck="Levia Blitz Deck",e.LexiBlitzDeck="Lexi Blitz Deck",e.NuuBlitzDeck="Nuu Blitz Deck",e.OldhimBlitzDeck="Oldhim Blitz Deck",e.OlympiaBlitzDeck="Olympia Blitz Deck",e.PrismBlitzDeck="Prism Blitz Deck",e.RhinarBlitzDeck="Rhinar Blitz Deck",e.RiptideBlitzDeck="Riptide Blitz Deck",e.UzuriBlitzDeck="Uzuri Blitz Deck",e.VictorBlitzDeck="Victor Blitz Deck",e.ZenBlitzDeck="Zen Blitz Deck",e.DorintheaHeroDeck="Dorinthea Hero Deck",e.KatsuHeroDeck="Katsu Hero Deck",e.RhinarHeroDeck="Rhinar Hero Deck",e.ClassicBattlesRhinarDorinthea="Classic Battles: Rhinar vs Dorinthea",e.IraWelcomeDeck="Ira Welcome Deck",e.RoundTheTable="Round the Table",e.Promos="Promos",e))(Et||{}),_t=(e=>(e.Alpha="Alpha",e.First="First",e.Unlimited="Unlimited",e.Promo="Promo",e))(_t||{}),Ot=(e=>(e.Draconic="Draconic",e.Earth="Earth",e.Elemental="Elemental",e.Ice="Ice",e.Light="Light",e.Lightning="Lightning",e.Mystic="Mystic",e.Royal="Royal",e.Shadow="Shadow",e))(Ot||{}),zt=(e=>(e.Action="Action",e.AttackReaction="Attack Reaction",e.Block="Block",e.DefenseReaction="Defense Reaction",e.DemiHero="Demi-Hero",e.Equipment="Equipment",e.Hero="Hero",e.Instant="Instant",e.Mentor="Mentor",e.Resource="Resource",e.Token="Token",e.Weapon="Weapon",e))(zt||{}),Nt=(e=>(e.OneHanded="1H",e.TwoHanded="2H",e.Affliction="Affliction",e.Ally="Ally",e.Angel="Angel",e.Arms="Arms",e.Arrow="Arrow",e.Ash="Ash",e.Attack="Attack",e.Aura="Aura",e.Axe="Axe",e.Base="Base",e.Book="Book",e.Bow="Bow",e.Chest="Chest",e.Chi="Chi",e.Claw="Claw",e.Club="Club",e.Construct="Construct",e.Dagger="Dagger",e.Demon="Demon",e.Dragon="Dragon",e.Evo="Evo",e.Fiddle="Fiddle",e.Figment="Figment",e.Flail="Flail",e.Gem="Gem",e.Gun="Gun",e.Hammer="Hammer",e.Head="Head",e.Invocation="Invocation",e.Item="Item",e.Landmark="Landmark",e.Lute="Lute",e.Legs="Legs",e.NonAttack="Non-Attack",e.OffHand="Off-Hand",e.Orb="Orb",e.Pistol="Pistol",e.Quiver="Quiver",e.Rock="Rock",e.Shuriken="Shuriken",e.Scepter="Scepter",e.Scroll="Scroll",e.Scythe="Scythe",e.Song="Song",e.Staff="Staff",e.Sword="Sword",e.Trap="Trap",e.Wrench="Wrench",e.Young="Young",e))(Nt||{}),Ht=(e=>(e.Arakni="Arakni",e.Azalea="Azalea",e.Benji="Benji",e.Betsy="Betsy",e.Boltyn="Boltyn",e.Bravo="Bravo",e.Brevant="Brevant",e.Briar="Briar",e.Brutus="Brutus",e.Chane="Chane",e.Dash="Dash",e.DataDoll="Data Doll",e.Dorinthea="Dorinthea",e.Dromai="Dromai",e.Emperor="Emperor",e.Enigma="Enigma",e.Fai="Fai",e.GenisWotchuneed="Genis Wotchuneed",e.Ira="Ira",e.Iyslander="Iyslander",e.Kano="Kano",e.Kassai="Kassai",e.Katsu="Katsu",e.Kavdaen="Kavdaen",e.Kayo="Kayo",e.Levia="Levia",e.Lexi="Lexi",e.Maxx="Maxx",e.Melody="Melody",e.Nuu="Nuu",e.Oldhim="Oldhim",e.Olympia="Olympia",e.Prism="Prism",e.Rhinar="Rhinar",e.Riptide="Riptide",e.Ruudi="Ruu'di",e.Shiyana="Shiyana",e.Squizzy="Squizzy",e.Taipanis="Taipanis",e.Taylor="Taylor",e.Teklovossen="Teklovossen",e.Theryon="Theryon",e.Uzuri="Uzuri",e.Valda="Valda",e.Victor="Victor",e.Vynnset="Vynnset",e.Viserai="Viserai",e.Yorick="Yorick",e.Yoji="Yoji",e.Zen="Zen",e))(Ht||{}),$t=(e=>(e.Ambush="Ambush",e.Amp="Amp",e.ArcaneBarrier="Arcane Barrier",e.Awaken="Awaken",e.Battleworn="Battleworn",e.BeatChest="Beat Chest",e.BladeBreak="Blade Break",e.BloodDebt="Blood Debt",e.Boost="Boost",e.Channel="Channel",e.Charge="Charge",e.Clash="Clash",e.Cloaked="Cloaked",e.Combo="Combo",e.Contract="Contract",e.Crank="Crank",e.Crush="Crush",e.Dominate="Dominate",e.Ephemeral="Ephemeral",e.Essence="Essence",e.EvoUpgrade="Evo Upgrade",e.Freeze="Freeze",e.Fusion="Fusion",e.Galvanize="Galvanize",e.GoAgain="Go again",e.Guardwell="Guardwell",e.Heave="Heave",e.Intimidate="Intimidate",e.Legendary="Legendary",e.Material="Material",e.Modular="Modular",e.Mirage="Mirage",e.Negate="Negate",e.Opt="Opt",e.Overpower="Overpower",e.Pairs="Pairs",e.Piercing="Piercing",e.Phantasm="Phantasm",e.Protect="Protect",e.Quell="Quell",e.Reload="Reload",e.Reprise="Reprise",e.RuneGate="Rune Gate",e.Rupture="Rupture",e.Scrap="Scrap",e.Solflare="Solflare",e.Specialization="Specialization",e.Spectra="Spectra",e.Spellvoid="Spellvoid",e.Stealth="Stealth",e.Surge="Surge",e.Temper="Temper",e.Tower="Tower",e.Transform="Transform",e.Transcend="Transcend",e.Universal="Universal",e.Unfreeze="Unfreeze",e.Unity="Unity",e.Wager="Wager",e.Ward="Ward",e))($t||{}),ui={"Rhinar Blitz Deck":"-Blitz"},di=e=>{var t,r;let i=ui[e.set]||"",n=`${e.identifier}${i}`,a=e.edition?`-${e.edition}`:"",s=e.foiling?`-${e.foiling}`:"",o=e.treatment?`-${e.treatment}`:"",c=(t=e.image)!=null&&t.toLowerCase().includes("back")?"-Back":"",u=(r=e.image)!=null&&r.toLowerCase().includes("_v3")?"-V3":"";return`${n}${a}${s}${o}${c}${u}`},Wt={wtr:"Welcome to Rathe",arc:"Arcane Rising",cru:"Crucible of War",mon:"Monarch",ele:"Tales of Aria",evr:"Everfest","1hp":"History Pack 1",hp1:"History Pack 1",upr:"Uprising",dyn:"Dynasty",out:"Outsiders",dtd:"Dusk till Dawn",evo:"Bright Lights",hvy:"Heavy Hitters",mst:"Part the Mistveil"},jt=oi(ai({},Wt),{ako:"Armory Deck: Kayo",asb:"Armory Deck: Boltyn",ara:"Arakni Blitz Deck",azl:"Azalea Blitz Deck",ben:"Benji Blitz Deck",bet:"Betsy Blitz Deck",bol:"Boltyn Blitz Deck",bri:"Briar Blitz Deck",bvo:"Bravo Blitz Deck",chn:"Chane Blitz Deck",dro:"Dromai Blitz Deck",eng:"Enigma Blitz Deck",fai:"Fai Blitz Deck",kat:"Katsu Blitz Deck",ksi:"Kassai Blitz Deck",kyo:"Kayo Blitz Deck",lev:"Levia Blitz Deck",lxi:"Lexi Blitz Deck",nuu:"Nuu Blitz Deck",old:"Oldhim Blitz Deck",ola:"Olympia Blitz Deck",psm:"Prism Blitz Deck",rip:"Riptide Blitz Deck",rnr:"Rhinar Blitz Deck",uzu:"Uzuri Blitz Deck",vic:"Victor Blitz Deck",zen:"Zen Blitz Deck",dvr:"Classic Battles: Rhinar vs Dorinthea",rvd:"Classic Battles: Rhinar vs Dorinthea",ira:"Ira Welcome Deck",tcc:"Round the Table",tea:"Dorinthea Hero Deck",ksu:"Katsu Hero Deck",rnr2:"Rhinar Hero Deck",fab:"Promos",her:"Promos",jdg:"Promos",lgs:"Promos",lss:"Promos",oxo:"Promos",xxx:"Promos",win:"Promos"}),Ee={};for(let[e,t]of Object.entries(jt)){let r=Ee[t];r?r.push(e):Ee[t]=[e]}var pi=Ee});var lr=kt((Za,sr)=>{"use strict";function Kt(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);t&&(i=i.filter(function(n){return Object.getOwnPropertyDescriptor(e,n).enumerable})),r.push.apply(r,i)}return r}function ae(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?Kt(Object(r),!0).forEach(function(i){ze(e,i,r[i])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):Kt(Object(r)).forEach(function(i){Object.defineProperty(e,i,Object.getOwnPropertyDescriptor(r,i))})}return e}function Oe(e){"@babel/helpers - typeof";return Oe=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Oe(e)}function _(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Ut(e,t){for(var r=0;r<t.length;r++){var i=t[r];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(e,i.key,i)}}function O(e,t,r){return t&&Ut(e.prototype,t),r&&Ut(e,r),Object.defineProperty(e,"prototype",{writable:!1}),e}function ze(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function Q(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");Object.defineProperty(e,"prototype",{value:Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),writable:!1}),t&&Ne(e,t)}function me(e){return me=Object.setPrototypeOf?Object.getPrototypeOf:function(r){return r.__proto__||Object.getPrototypeOf(r)},me(e)}function Ne(e,t){return Ne=Object.setPrototypeOf||function(i,n){return i.__proto__=n,i},Ne(e,t)}function hi(){if(typeof Reflect=="undefined"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch(e){return!1}}function fi(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function gi(e,t){if(t&&(typeof t=="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return fi(e)}function J(e){var t=hi();return function(){var i=me(e),n;if(t){var a=me(this).constructor;n=Reflect.construct(i,arguments,a)}else n=i.apply(this,arguments);return gi(this,n)}}function te(e){return mi(e)||yi(e)||vi(e)||bi()}function mi(e){if(Array.isArray(e))return He(e)}function yi(e){if(typeof Symbol!="undefined"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function vi(e,t){if(e){if(typeof e=="string")return He(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if(r==="Object"&&e.constructor&&(r=e.constructor.name),r==="Map"||r==="Set")return Array.from(e);if(r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return He(e,t)}}function He(e,t){(t==null||t>e.length)&&(t=e.length);for(var r=0,i=new Array(t);r<t;r++)i[r]=e[r];return i}function bi(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
2
2
  In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function Y(e){return Array.isArray?Array.isArray(e):er(e)==="[object Array]"}var Ai=1/0;function Mi(e){if(typeof e=="string")return e;var t=e+"";return t=="0"&&1/e==-Ai?"-0":t}function Ci(e){return e==null?"":Mi(e)}function G(e){return typeof e=="string"}function Xt(e){return typeof e=="number"}function ki(e){return e===!0||e===!1||Fi(e)&&er(e)=="[object Boolean]"}function qt(e){return Oe(e)==="object"}function Fi(e){return qt(e)&&e!==null}function z(e){return e!=null}function _e(e){return!e.trim().length}function er(e){return e==null?e===void 0?"[object Undefined]":"[object Null]":Object.prototype.toString.call(e)}var Ti="Incorrect 'index' type",Si=function(t){return"Invalid value for key ".concat(t)},xi=function(t){return"Pattern length exceeds max of ".concat(t,".")},Li=function(t){return"Missing ".concat(t," property in key")},wi=function(t){return"Property 'weight' in key '".concat(t,"' must be a positive integer")},Yt=Object.prototype.hasOwnProperty,Bi=function(){function e(t){var r=this;_(this,e),this._keys=[],this._keyMap={};var i=0;t.forEach(function(n){var a=tr(n);i+=a.weight,r._keys.push(a),r._keyMap[a.id]=a,i+=a.weight}),this._keys.forEach(function(n){n.weight/=i})}return O(e,[{key:"get",value:function(r){return this._keyMap[r]}},{key:"keys",value:function(){return this._keys}},{key:"toJSON",value:function(){return JSON.stringify(this._keys)}}]),e}();function tr(e){var t=null,r=null,i=null,n=1,a=null;if(G(e)||Y(e))i=e,t=Vt(e),r=$e(e);else{if(!Yt.call(e,"name"))throw new Error(Li("name"));var s=e.name;if(i=s,Yt.call(e,"weight")&&(n=e.weight,n<=0))throw new Error(wi(s));t=Vt(s),r=$e(s),a=e.getFn}return{path:t,id:r,weight:n,src:i,getFn:a}}function Vt(e){return Y(e)?e:e.split(".")}function $e(e){return Y(e)?e.join("."):e}function Pi(e,t){var r=[],i=!1,n=function a(s,o,c){if(z(s))if(!o[c])r.push(s);else{var u=o[c],d=s[u];if(!z(d))return;if(c===o.length-1&&(G(d)||Xt(d)||ki(d)))r.push(Ci(d));else if(Y(d)){i=!0;for(var f=0,p=d.length;f<p;f+=1)a(d[f],o,c+1)}else o.length&&a(d,o,c+1)}};return n(e,G(t)?t.split("."):t,0),i?r:r[0]}var Di={includeMatches:!1,findAllMatches:!1,minMatchCharLength:1},Ri={isCaseSensitive:!1,includeScore:!1,keys:[],shouldSort:!0,sortFn:function(t,r){return t.score===r.score?t.idx<r.idx?-1:1:t.score<r.score?-1:1}},Ii={location:0,threshold:.6,distance:100},Ei={useExtendedSearch:!1,getFn:Pi,ignoreLocation:!1,ignoreFieldNorm:!1,fieldNormWeight:1},M=ae(ae(ae(ae({},Ri),Di),Ii),Ei),_i=/[^ ]+/g;function Oi(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:1,t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:3,r=new Map,i=Math.pow(10,t);return{get:function(a){var s=a.match(_i).length;if(r.has(s))return r.get(s);var o=1/Math.pow(s,.5*e),c=parseFloat(Math.round(o*i)/i);return r.set(s,c),c},clear:function(){r.clear()}}}var Ue=function(){function e(){var t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},r=t.getFn,i=r===void 0?M.getFn:r,n=t.fieldNormWeight,a=n===void 0?M.fieldNormWeight:n;_(this,e),this.norm=Oi(a,3),this.getFn=i,this.isCreated=!1,this.setIndexRecords()}return O(e,[{key:"setSources",value:function(){var r=arguments.length>0&&arguments[0]!==void 0?arguments[0]:[];this.docs=r}},{key:"setIndexRecords",value:function(){var r=arguments.length>0&&arguments[0]!==void 0?arguments[0]:[];this.records=r}},{key:"setKeys",value:function(){var r=this,i=arguments.length>0&&arguments[0]!==void 0?arguments[0]:[];this.keys=i,this._keysMap={},i.forEach(function(n,a){r._keysMap[n.id]=a})}},{key:"create",value:function(){var r=this;this.isCreated||!this.docs.length||(this.isCreated=!0,G(this.docs[0])?this.docs.forEach(function(i,n){r._addString(i,n)}):this.docs.forEach(function(i,n){r._addObject(i,n)}),this.norm.clear())}},{key:"add",value:function(r){var i=this.size();G(r)?this._addString(r,i):this._addObject(r,i)}},{key:"removeAt",value:function(r){this.records.splice(r,1);for(var i=r,n=this.size();i<n;i+=1)this.records[i].i-=1}},{key:"getValueForItemAtKeyId",value:function(r,i){return r[this._keysMap[i]]}},{key:"size",value:function(){return this.records.length}},{key:"_addString",value:function(r,i){if(!(!z(r)||_e(r))){var n={v:r,i,n:this.norm.get(r)};this.records.push(n)}}},{key:"_addObject",value:function(r,i){var n=this,a={i,$:{}};this.keys.forEach(function(s,o){var c=s.getFn?s.getFn(r):n.getFn(r,s.path);if(z(c)){if(Y(c))(function(){for(var d=[],f=[{nestedArrIndex:-1,value:c}];f.length;){var p=f.pop(),m=p.nestedArrIndex,y=p.value;if(z(y))if(G(y)&&!_e(y)){var g={v:y,i:m,n:n.norm.get(y)};d.push(g)}else Y(y)&&y.forEach(function(h,v){f.push({nestedArrIndex:v,value:h})})}a.$[o]=d})();else if(G(c)&&!_e(c)){var u={v:c,n:n.norm.get(c)};a.$[o]=u}}}),this.records.push(a)}},{key:"toJSON",value:function(){return{keys:this.keys,records:this.records}}}]),e}();function rr(e,t){var r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},i=r.getFn,n=i===void 0?M.getFn:i,a=r.fieldNormWeight,s=a===void 0?M.fieldNormWeight:a,o=new Ue({getFn:n,fieldNormWeight:s});return o.setKeys(e.map(tr)),o.setSources(t),o.create(),o}function zi(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},r=t.getFn,i=r===void 0?M.getFn:r,n=t.fieldNormWeight,a=n===void 0?M.fieldNormWeight:n,s=e.keys,o=e.records,c=new Ue({getFn:i,fieldNormWeight:a});return c.setKeys(s),c.setIndexRecords(o),c}function ge(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},r=t.errors,i=r===void 0?0:r,n=t.currentLocation,a=n===void 0?0:n,s=t.expectedLocation,o=s===void 0?0:s,c=t.distance,u=c===void 0?M.distance:c,d=t.ignoreLocation,f=d===void 0?M.ignoreLocation:d,p=i/e.length;if(f)return p;var m=Math.abs(o-a);return u?p+m/u:m?1:p}function Ni(){for(var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:[],t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:M.minMatchCharLength,r=[],i=-1,n=-1,a=0,s=e.length;a<s;a+=1){var o=e[a];o&&i===-1?i=a:!o&&i!==-1&&(n=a-1,n-i+1>=t&&r.push([i,n]),i=-1)}return e[a-1]&&a-i>=t&&r.push([i,a-1]),r}var ee=32;function Hi(e,t,r){var i=arguments.length>3&&arguments[3]!==void 0?arguments[3]:{},n=i.location,a=n===void 0?M.location:n,s=i.distance,o=s===void 0?M.distance:s,c=i.threshold,u=c===void 0?M.threshold:c,d=i.findAllMatches,f=d===void 0?M.findAllMatches:d,p=i.minMatchCharLength,m=p===void 0?M.minMatchCharLength:p,y=i.includeMatches,g=y===void 0?M.includeMatches:y,h=i.ignoreLocation,v=h===void 0?M.ignoreLocation:h;if(t.length>ee)throw new Error(xi(ee));for(var C=t.length,S=e.length,k=Math.max(0,Math.min(a,S)),x=u,F=k,w=m>1||g,D=w?Array(S):[],P;(P=e.indexOf(t,F))>-1;){var N=ge(t,{currentLocation:P,expectedLocation:k,distance:o,ignoreLocation:v});if(x=Math.min(N,x),F=P+C,w)for(var E=0;E<C;)D[P+E]=1,E+=1}F=-1;for(var R=[],H=1,re=C+S,Wr=1<<C-1,q=0;q<C;q+=1){for(var pe=0,V=re;pe<V;){var jr=ge(t,{errors:q,currentLocation:k+V,expectedLocation:k,distance:o,ignoreLocation:v});jr<=x?pe=V:re=V,V=Math.floor((re-pe)/2+pe)}re=V;var mt=Math.max(1,k-V+1),Re=f?S:Math.min(k+V,S)+C,ie=Array(Re+2);ie[Re+1]=(1<<q)-1;for(var $=Re;$>=mt;$-=1){var he=$-1,yt=r[e.charAt(he)];if(w&&(D[he]=+!!yt),ie[$]=(ie[$+1]<<1|1)&yt,q&&(ie[$]|=(R[$+1]|R[$])<<1|1|R[$+1]),ie[$]&Wr&&(H=ge(t,{errors:q,currentLocation:he,expectedLocation:k,distance:o,ignoreLocation:v}),H<=x)){if(x=H,F=he,F<=k)break;mt=Math.max(1,2*k-F)}}var Gr=ge(t,{errors:q+1,currentLocation:k,expectedLocation:k,distance:o,ignoreLocation:v});if(Gr>x)break;R=ie}var Ie={isMatch:F>=0,score:Math.max(.001,H)};if(w){var vt=Ni(D,m);vt.length?g&&(Ie.indices=vt):Ie.isMatch=!1}return Ie}function $i(e){for(var t={},r=0,i=e.length;r<i;r+=1){var n=e.charAt(r);t[n]=(t[n]||0)|1<<i-r-1}return t}var ir=function(){function e(t){var r=this,i=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},n=i.location,a=n===void 0?M.location:n,s=i.threshold,o=s===void 0?M.threshold:s,c=i.distance,u=c===void 0?M.distance:c,d=i.includeMatches,f=d===void 0?M.includeMatches:d,p=i.findAllMatches,m=p===void 0?M.findAllMatches:p,y=i.minMatchCharLength,g=y===void 0?M.minMatchCharLength:y,h=i.isCaseSensitive,v=h===void 0?M.isCaseSensitive:h,C=i.ignoreLocation,S=C===void 0?M.ignoreLocation:C;if(_(this,e),this.options={location:a,threshold:o,distance:u,includeMatches:f,findAllMatches:m,minMatchCharLength:g,isCaseSensitive:v,ignoreLocation:S},this.pattern=v?t:t.toLowerCase(),this.chunks=[],!!this.pattern.length){var k=function(E,R){r.chunks.push({pattern:E,alphabet:$i(E),startIndex:R})},x=this.pattern.length;if(x>ee){for(var F=0,w=x%ee,D=x-w;F<D;)k(this.pattern.substr(F,ee),F),F+=ee;if(w){var P=x-ee;k(this.pattern.substr(P),P)}}else k(this.pattern,0)}}return O(e,[{key:"searchIn",value:function(r){var i=this.options,n=i.isCaseSensitive,a=i.includeMatches;if(n||(r=r.toLowerCase()),this.pattern===r){var s={isMatch:!0,score:0};return a&&(s.indices=[[0,r.length-1]]),s}var o=this.options,c=o.location,u=o.distance,d=o.threshold,f=o.findAllMatches,p=o.minMatchCharLength,m=o.ignoreLocation,y=[],g=0,h=!1;this.chunks.forEach(function(C){var S=C.pattern,k=C.alphabet,x=C.startIndex,F=Hi(r,S,k,{location:c+x,distance:u,threshold:d,findAllMatches:f,minMatchCharLength:p,includeMatches:a,ignoreLocation:m}),w=F.isMatch,D=F.score,P=F.indices;w&&(h=!0),g+=D,w&&P&&(y=[].concat(te(y),te(P)))});var v={isMatch:h,score:h?g/this.chunks.length:1};return h&&a&&(v.indices=y),v}}]),e}(),Z=function(){function e(t){_(this,e),this.pattern=t}return O(e,[{key:"search",value:function(){}}],[{key:"isMultiMatch",value:function(r){return Qt(r,this.multiRegex)}},{key:"isSingleMatch",value:function(r){return Qt(r,this.singleRegex)}}]),e}();function Qt(e,t){var r=e.match(t);return r?r[1]:null}var Wi=function(e){Q(r,e);var t=J(r);function r(i){return _(this,r),t.call(this,i)}return O(r,[{key:"search",value:function(n){var a=n===this.pattern;return{isMatch:a,score:a?0:1,indices:[0,this.pattern.length-1]}}}],[{key:"type",get:function(){return"exact"}},{key:"multiRegex",get:function(){return/^="(.*)"$/}},{key:"singleRegex",get:function(){return/^=(.*)$/}}]),r}(Z),ji=function(e){Q(r,e);var t=J(r);function r(i){return _(this,r),t.call(this,i)}return O(r,[{key:"search",value:function(n){var a=n.indexOf(this.pattern),s=a===-1;return{isMatch:s,score:s?0:1,indices:[0,n.length-1]}}}],[{key:"type",get:function(){return"inverse-exact"}},{key:"multiRegex",get:function(){return/^!"(.*)"$/}},{key:"singleRegex",get:function(){return/^!(.*)$/}}]),r}(Z),Gi=function(e){Q(r,e);var t=J(r);function r(i){return _(this,r),t.call(this,i)}return O(r,[{key:"search",value:function(n){var a=n.startsWith(this.pattern);return{isMatch:a,score:a?0:1,indices:[0,this.pattern.length-1]}}}],[{key:"type",get:function(){return"prefix-exact"}},{key:"multiRegex",get:function(){return/^\^"(.*)"$/}},{key:"singleRegex",get:function(){return/^\^(.*)$/}}]),r}(Z),Ki=function(e){Q(r,e);var t=J(r);function r(i){return _(this,r),t.call(this,i)}return O(r,[{key:"search",value:function(n){var a=!n.startsWith(this.pattern);return{isMatch:a,score:a?0:1,indices:[0,n.length-1]}}}],[{key:"type",get:function(){return"inverse-prefix-exact"}},{key:"multiRegex",get:function(){return/^!\^"(.*)"$/}},{key:"singleRegex",get:function(){return/^!\^(.*)$/}}]),r}(Z),Ui=function(e){Q(r,e);var t=J(r);function r(i){return _(this,r),t.call(this,i)}return O(r,[{key:"search",value:function(n){var a=n.endsWith(this.pattern);return{isMatch:a,score:a?0:1,indices:[n.length-this.pattern.length,n.length-1]}}}],[{key:"type",get:function(){return"suffix-exact"}},{key:"multiRegex",get:function(){return/^"(.*)"\$$/}},{key:"singleRegex",get:function(){return/^(.*)\$$/}}]),r}(Z),Yi=function(e){Q(r,e);var t=J(r);function r(i){return _(this,r),t.call(this,i)}return O(r,[{key:"search",value:function(n){var a=!n.endsWith(this.pattern);return{isMatch:a,score:a?0:1,indices:[0,n.length-1]}}}],[{key:"type",get:function(){return"inverse-suffix-exact"}},{key:"multiRegex",get:function(){return/^!"(.*)"\$$/}},{key:"singleRegex",get:function(){return/^!(.*)\$$/}}]),r}(Z),nr=function(e){Q(r,e);var t=J(r);function r(i){var n,a=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},s=a.location,o=s===void 0?M.location:s,c=a.threshold,u=c===void 0?M.threshold:c,d=a.distance,f=d===void 0?M.distance:d,p=a.includeMatches,m=p===void 0?M.includeMatches:p,y=a.findAllMatches,g=y===void 0?M.findAllMatches:y,h=a.minMatchCharLength,v=h===void 0?M.minMatchCharLength:h,C=a.isCaseSensitive,S=C===void 0?M.isCaseSensitive:C,k=a.ignoreLocation,x=k===void 0?M.ignoreLocation:k;return _(this,r),n=t.call(this,i),n._bitapSearch=new ir(i,{location:o,threshold:u,distance:f,includeMatches:m,findAllMatches:g,minMatchCharLength:v,isCaseSensitive:S,ignoreLocation:x}),n}return O(r,[{key:"search",value:function(n){return this._bitapSearch.searchIn(n)}}],[{key:"type",get:function(){return"fuzzy"}},{key:"multiRegex",get:function(){return/^"(.*)"$/}},{key:"singleRegex",get:function(){return/^(.*)$/}}]),r}(Z),ar=function(e){Q(r,e);var t=J(r);function r(i){return _(this,r),t.call(this,i)}return O(r,[{key:"search",value:function(n){for(var a=0,s,o=[],c=this.pattern.length;(s=n.indexOf(this.pattern,a))>-1;)a=s+c,o.push([s,a-1]);var u=!!o.length;return{isMatch:u,score:u?0:1,indices:o}}}],[{key:"type",get:function(){return"include"}},{key:"multiRegex",get:function(){return/^'"(.*)"$/}},{key:"singleRegex",get:function(){return/^'(.*)$/}}]),r}(Z),We=[Wi,ar,Gi,Ki,Yi,Ui,ji,nr],Jt=We.length,Vi=/ +(?=(?:[^\"]*\"[^\"]*\")*[^\"]*$)/,Qi="|";function Ji(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};return e.split(Qi).map(function(r){for(var i=r.trim().split(Vi).filter(function(y){return y&&!!y.trim()}),n=[],a=0,s=i.length;a<s;a+=1){for(var o=i[a],c=!1,u=-1;!c&&++u<Jt;){var d=We[u],f=d.isMultiMatch(o);f&&(n.push(new d(f,t)),c=!0)}if(!c)for(u=-1;++u<Jt;){var p=We[u],m=p.isSingleMatch(o);if(m){n.push(new p(m,t));break}}}return n})}var Zi=new Set([nr.type,ar.type]),Xi=function(){function e(t){var r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},i=r.isCaseSensitive,n=i===void 0?M.isCaseSensitive:i,a=r.includeMatches,s=a===void 0?M.includeMatches:a,o=r.minMatchCharLength,c=o===void 0?M.minMatchCharLength:o,u=r.ignoreLocation,d=u===void 0?M.ignoreLocation:u,f=r.findAllMatches,p=f===void 0?M.findAllMatches:f,m=r.location,y=m===void 0?M.location:m,g=r.threshold,h=g===void 0?M.threshold:g,v=r.distance,C=v===void 0?M.distance:v;_(this,e),this.query=null,this.options={isCaseSensitive:n,includeMatches:s,minMatchCharLength:c,findAllMatches:p,ignoreLocation:d,location:y,threshold:h,distance:C},this.pattern=n?t:t.toLowerCase(),this.query=Ji(this.pattern,this.options)}return O(e,[{key:"searchIn",value:function(r){var i=this.query;if(!i)return{isMatch:!1,score:1};var n=this.options,a=n.includeMatches,s=n.isCaseSensitive;r=s?r:r.toLowerCase();for(var o=0,c=[],u=0,d=0,f=i.length;d<f;d+=1){var p=i[d];c.length=0,o=0;for(var m=0,y=p.length;m<y;m+=1){var g=p[m],h=g.search(r),v=h.isMatch,C=h.indices,S=h.score;if(v){if(o+=1,u+=S,a){var k=g.constructor.type;Zi.has(k)?c=[].concat(te(c),te(C)):c.push(C)}}else{u=0,o=0,c.length=0;break}}if(o){var x={isMatch:!0,score:u/o};return a&&(x.indices=c),x}}return{isMatch:!1,score:1}}}],[{key:"condition",value:function(r,i){return i.useExtendedSearch}}]),e}(),ye=[];function qi(){ye.push.apply(ye,arguments)}function je(e,t){for(var r=0,i=ye.length;r<i;r+=1){var n=ye[r];if(n.condition(e,t))return new n(e,t)}return new ir(e,t)}var ve={AND:"$and",OR:"$or"},Ge={PATH:"$path",PATTERN:"$val"},Ke=function(t){return!!(t[ve.AND]||t[ve.OR])},en=function(t){return!!t[Ge.PATH]},tn=function(t){return!Y(t)&&qt(t)&&!Ke(t)},Zt=function(t){return ze({},ve.AND,Object.keys(t).map(function(r){return ze({},r,t[r])}))};function or(e,t){var r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},i=r.auto,n=i===void 0?!0:i,a=function s(o){var c=Object.keys(o),u=en(o);if(!u&&c.length>1&&!Ke(o))return s(Zt(o));if(tn(o)){var d=u?o[Ge.PATH]:c[0],f=u?o[Ge.PATTERN]:o[d];if(!G(f))throw new Error(Si(d));var p={keyId:$e(d),pattern:f};return n&&(p.searcher=je(f,t)),p}var m={children:[],operator:c[0]};return c.forEach(function(y){var g=o[y];Y(g)&&g.forEach(function(h){m.children.push(s(h))})}),m};return Ke(e)||(e=Zt(e)),a(e)}function rn(e,t){var r=t.ignoreFieldNorm,i=r===void 0?M.ignoreFieldNorm:r;e.forEach(function(n){var a=1;n.matches.forEach(function(s){var o=s.key,c=s.norm,u=s.score,d=o?o.weight:null;a*=Math.pow(u===0&&d?Number.EPSILON:u,(d||1)*(i?1:c))}),n.score=a})}function nn(e,t){var r=e.matches;t.matches=[],z(r)&&r.forEach(function(i){if(!(!z(i.indices)||!i.indices.length)){var n=i.indices,a=i.value,s={indices:n,value:a};i.key&&(s.key=i.key.src),i.idx>-1&&(s.refIndex=i.idx),t.matches.push(s)}})}function an(e,t){t.score=e.score}function on(e,t){var r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},i=r.includeMatches,n=i===void 0?M.includeMatches:i,a=r.includeScore,s=a===void 0?M.includeScore:a,o=[];return n&&o.push(nn),s&&o.push(an),e.map(function(c){var u=c.idx,d={item:t[u],refIndex:u};return o.length&&o.forEach(function(f){f(c,d)}),d})}var oe=function(){function e(t){var r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},i=arguments.length>2?arguments[2]:void 0;_(this,e),this.options=ae(ae({},M),r),this.options.useExtendedSearch,this._keyStore=new Bi(this.options.keys),this.setCollection(t,i)}return O(e,[{key:"setCollection",value:function(r,i){if(this._docs=r,i&&!(i instanceof Ue))throw new Error(Ti);this._myIndex=i||rr(this.options.keys,this._docs,{getFn:this.options.getFn,fieldNormWeight:this.options.fieldNormWeight})}},{key:"add",value:function(r){z(r)&&(this._docs.push(r),this._myIndex.add(r))}},{key:"remove",value:function(){for(var r=arguments.length>0&&arguments[0]!==void 0?arguments[0]:function(){return!1},i=[],n=0,a=this._docs.length;n<a;n+=1){var s=this._docs[n];r(s,n)&&(this.removeAt(n),n-=1,a-=1,i.push(s))}return i}},{key:"removeAt",value:function(r){this._docs.splice(r,1),this._myIndex.removeAt(r)}},{key:"getIndex",value:function(){return this._myIndex}},{key:"search",value:function(r){var i=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},n=i.limit,a=n===void 0?-1:n,s=this.options,o=s.includeMatches,c=s.includeScore,u=s.shouldSort,d=s.sortFn,f=s.ignoreFieldNorm,p=G(r)?G(this._docs[0])?this._searchStringList(r):this._searchObjectList(r):this._searchLogical(r);return rn(p,{ignoreFieldNorm:f}),u&&p.sort(d),Xt(a)&&a>-1&&(p=p.slice(0,a)),on(p,this._docs,{includeMatches:o,includeScore:c})}},{key:"_searchStringList",value:function(r){var i=je(r,this.options),n=this._myIndex.records,a=[];return n.forEach(function(s){var o=s.v,c=s.i,u=s.n;if(z(o)){var d=i.searchIn(o),f=d.isMatch,p=d.score,m=d.indices;f&&a.push({item:o,idx:c,matches:[{score:p,value:o,norm:u,indices:m}]})}}),a}},{key:"_searchLogical",value:function(r){var i=this,n=or(r,this.options),a=function u(d,f,p){if(!d.children){var m=d.keyId,y=d.searcher,g=i._findMatches({key:i._keyStore.get(m),value:i._myIndex.getValueForItemAtKeyId(f,m),searcher:y});return g&&g.length?[{idx:p,item:f,matches:g}]:[]}for(var h=[],v=0,C=d.children.length;v<C;v+=1){var S=d.children[v],k=u(S,f,p);if(k.length)h.push.apply(h,te(k));else if(d.operator===ve.AND)return[]}return h},s=this._myIndex.records,o={},c=[];return s.forEach(function(u){var d=u.$,f=u.i;if(z(d)){var p=a(n,d,f);p.length&&(o[f]||(o[f]={idx:f,item:d,matches:[]},c.push(o[f])),p.forEach(function(m){var y,g=m.matches;(y=o[f].matches).push.apply(y,te(g))}))}}),c}},{key:"_searchObjectList",value:function(r){var i=this,n=je(r,this.options),a=this._myIndex,s=a.keys,o=a.records,c=[];return o.forEach(function(u){var d=u.$,f=u.i;if(z(d)){var p=[];s.forEach(function(m,y){p.push.apply(p,te(i._findMatches({key:m,value:d[y],searcher:n})))}),p.length&&c.push({idx:f,item:d,matches:p})}}),c}},{key:"_findMatches",value:function(r){var i=r.key,n=r.value,a=r.searcher;if(!z(n))return[];var s=[];if(Y(n))n.forEach(function(m){var y=m.v,g=m.i,h=m.n;if(z(y)){var v=a.searchIn(y),C=v.isMatch,S=v.score,k=v.indices;C&&s.push({score:S,key:i,value:y,idx:g,norm:h,indices:k})}});else{var o=n.v,c=n.n,u=a.searchIn(o),d=u.isMatch,f=u.score,p=u.indices;d&&s.push({score:f,key:i,value:o,norm:c,indices:p})}return s}}]),e}();oe.version="6.6.2";oe.createIndex=rr;oe.parseIndex=zi;oe.config=M;oe.parseQuery=or;qi(Xi);var sn=oe;sr.exports=sn});var Va={};Xr(Va,{PUNCTUATION:()=>L,abbreviations:()=>Qe,availableExclusions:()=>Ir,availableModifiers:()=>Rr,clashBannedCards:()=>Ye,clashSpecializationOverrides:()=>Ve,default:()=>Or,filterCard:()=>zr,filtersToCardPropertyMappings:()=>Be,getAbbreviation:()=>Ae,getAbbreviationByCard:()=>ln,getCardByName:()=>ct,getDeckFilters:()=>fa,getExcludedMetaFilters:()=>rt,getHeroBreakdown:()=>Ga,getKeywordsAndAppliedFiltersFromText:()=>lt,getMetaFilters:()=>tt,getRelatedCards:()=>gt,getRelatedCardsByName:()=>Pe,getTokensReferencedByCards:()=>Ya,heroHasFilters:()=>ga,shorthands:()=>it});module.exports=qr(Va);var B=W(j()),ut=W(lr());var be=W(j()),Ye=["Amulet of Ice","Ball Lightning","Belittle","Drone of Brutality","Duskblade","Rosetta Thorn","Stubby Hammerers"],Ve=[{heroes:[be.Hero.Briar],cardIdentifiers:["rosetta-thorn"]},{heroes:[be.Hero.Emperor],cardIdentifiers:["command-and-conquer-red"]},{heroes:[be.Hero.Prism],cardIdentifiers:["figment-of-erudition-yellow","figment-of-judgment-yellow","figment-of-protection-yellow","figment-of-ravages-yellow","figment-of-rebirth-yellow","figment-of-tenacity-yellow","figment-of-triumph-yellow","figment-of-war-yellow"]}];var L=/[!"#$%&'’()+,-./:;<=>?@[\]^_`|~]/g;var T=W(j());var Ae=e=>Qe.find(({abbreviations:t})=>t.find(r=>r.toLowerCase()===e)),ln=e=>Qe.find(({card:t})=>t.toLowerCase()===e.name.toLowerCase()),Qe=[{abbreviations:["10k"],card:"10,000 Year Reunion"},{abbreviations:["3oak"],card:"Three of a Kind"},{abbreviations:["ALS"],card:"Arc Light Sentinel"},{abbreviations:["AoW"],card:"Art of War"},{abbreviations:["BBD"],card:"Barraging Beatdown"},{abbreviations:["Starvo"],card:"Bravo, Star of the Show"},{abbreviations:["BEB"],card:"Bull's Eye Bracers"},{abbreviations:["BLW"],card:"Be Like Water"},{abbreviations:["BoJ"],card:"Balance of Justice"},{abbreviations:["BOHH"],card:"Blood on Her Hands"},{abbreviations:["BRB"],card:"Bloodrush Bellow"},{abbreviations:["Breezies"],card:"Breeze Rider Boots"},{abbreviations:["BTA"],card:"Burn Them All"},{abbreviations:["\u{1F382}","Cake"],card:"Ninth Blade of the Blood Oath"},{abbreviations:["CLF"],card:"Channel Lake Frigid"},{abbreviations:["CMH"],card:"Channel Mount Heroic"},{abbreviations:["C&C","CnC"],card:"Command and Conquer"},{abbreviations:["CStrike","C-Strike","C Strike"],card:"Celestial Cataclysm"},{abbreviations:["Cat","Kitty"],card:"Crouching Tiger"},{abbreviations:["CoD"],card:"Crown of Dominion"},{abbreviations:["CoP"],card:"Crown of Providence"},{abbreviations:["CtW"],card:"Crush the Weak"},{abbreviations:["DD"],card:"Death Dealer"},{abbreviations:["DPot","D Pot"],card:"Potion of Deja Vu"},{abbreviations:["Dullcap"],card:"Arcanite Skullcap"},{abbreviations:["EBTT"],card:"Even Bigger Than That!"},{abbreviations:["EPot","E Pot"],card:"Energy Potion"},{abbreviations:["EStrike","E-Strike","E Strike"],card:"Enlightened Strike"},{abbreviations:["FFS"],card:"Fyendal's Fighting Spirit"},{abbreviations:["FoN"],card:"Force of Nature"},{abbreviations:["Frosty","\u{1F976}","\u{1F9CA}","\u2744\uFE0F"],card:"Frostbite"},{abbreviations:["Frosty Hammer"],card:"Winter's Wail"},{abbreviations:["GnT"],card:"Give and Take"},{abbreviations:["HMH"],card:"Hope Merchant's Hood"},{abbreviations:["HoI"],card:"Heart of Ice"},{abbreviations:["KKBB"],card:"Knick Knack Bric-a-brac"},{abbreviations:["LAG","Twominaris"],card:"Luminaris, Angel's Glow"},{abbreviations:["LCF","Newminaris"],card:"Luminaris, Celestial Fury"},{abbreviations:["LDE"],card:"Last Ditch Effort"},{abbreviations:["LFaL","L4aL"],card:"Life for a Life"},{abbreviations:["LiT"],card:"Lost in Thought"},{abbreviations:["LNW"],card:"Leave No Witnesses"},{abbreviations:["LoW"],card:"Lord of Wind"},{abbreviations:["LtC"],card:"Lead the Charge"},{abbreviations:["MaxV"],card:"Maximum Velocity"},{abbreviations:["MMB"],card:"Mage Master Boots"},{abbreviations:["MnG"],card:"Meat and Greet"},{abbreviations:["MoM"],card:"Mask of Momentum"},{abbreviations:["PJs","Pajamas"],card:"Alluvion Constellas"},{abbreviations:["Ponder Run"],card:"Premeditate"},{abbreviations:["PF","\u{1F525}"],card:"Phoenix Flame"},{abbreviations:["PoM"],card:"Peace of Mind"},{abbreviations:["Pumpkin"],card:"Jack-o'-lantern"},{abbreviations:["Qi Unbound"],card:"Qi Unleashed"},{abbreviations:["RitL"],card:"Red in the Ledger"},{abbreviations:["SFaF","S4aS"],card:"Scar for a Scar"},{abbreviations:["SWOMB"],card:"Shifting Winds of the Mystic Beast"},{abbreviations:["SWK"],card:"Spinning Wheel Kick"},{abbreviations:["SSP"],card:"Sand Sketched Plan"},{abbreviations:["SFTL"],card:"Swing Fist, Think Later"},{abbreviations:["Thanos","Infinity Gauntlet"],card:"Polarity Reversal Script"},{abbreviations:["TAYG"],card:"That All You Got?"},{abbreviations:["ToS"],card:"Test of Strength"},{abbreviations:["TROM"],card:"This Round's on Me"},{abbreviations:["TTT"],card:"Take the Tempo"},{abbreviations:["Ultron"],card:"Teklovossen, the Mechropotent"},{abbreviations:["Pox Malone","Post Malone"],card:"Virulent Touch"},{abbreviations:["ZTS"],card:"Zero to Sixty"}];var l=W(j());var Te=Array.from(Array(50).keys()).map(e=>`${e}`),b=(e,t=[])=>{let r=[...e,l.Class.Generic];return t.length>0&&r.push(l.Class.NotClassed),[{filterToPropertyMapping:{property:"classes",isArray:!0},values:r.map(i=>i.toLowerCase()),isOr:!0},cn(t)]},A=(e,t=[])=>{let r=Object.values(l.Hero).filter(i=>i!==e&&!t.includes(i)).map(i=>i.toLowerCase());return[{filterToPropertyMapping:{property:"hero",isString:!0},values:r,excluded:!0,isOr:!0},{filterToPropertyMapping:{property:"specializations",isArray:!0},values:r,excluded:!0,isOr:!0}]},cn=e=>{let t=Object.values(l.Talent).filter(r=>!e.includes(r)).map(r=>r.toLowerCase());return{filterToPropertyMapping:{property:"talents",isArray:!0},values:t,excluded:!0}},Se=[l.Talent.Draconic],un=[l.Talent.Elemental,l.Talent.Earth,l.Talent.Ice,l.Talent.Lightning],dn=[l.Talent.Elemental,l.Talent.Earth,l.Talent.Ice],pn=[l.Talent.Elemental,l.Talent.Earth,l.Talent.Lightning],hn=[l.Talent.Elemental,l.Talent.Ice],fn=[l.Talent.Elemental,l.Talent.Ice,l.Talent.Lightning],Xe=[l.Talent.Light],qe=[l.Talent.Mystic],et=[l.Talent.Shadow],gn=[...b([l.Class.Assassin]),...A(l.Hero.Arakni)],mn=[...b([l.Class.Ranger]),...A(l.Hero.Azalea)],yn=[...b([l.Class.Ninja]),...A(l.Hero.Benji)],vn=[...b([l.Class.Guardian]),...A(l.Hero.Betsy)],bn=[...b([l.Class.Warrior],Xe),{filterToPropertyMapping:{property:"subtypes",isArray:!0,partialMatch:!0},values:["angel"],excluded:!0,isOr:!0},...A(l.Hero.Boltyn)],An=[...b([l.Class.Guardian]),...A(l.Hero.Bravo)],Mn=[...b([l.Class.Guardian]),...A(l.Hero.Brevant)],Cn=[...b([l.Class.Runeblade],pn),...A(l.Hero.Briar)],kn=[...b([l.Class.Adjudicator]),...A(l.Hero.Brutus)],Fn=[...b([l.Class.Runeblade],et),...A(l.Hero.Chane)],Tn=[...b([l.Class.Mechanologist]),...A(l.Hero.Dash)],Je=[...b([l.Class.Mechanologist]),...A(l.Hero.DataDoll)],cr=[...b([l.Class.Warrior]),...A(l.Hero.Dorinthea)],Sn=[...b([l.Class.Illusionist],Se),...A(l.Hero.Dromai,[l.Hero.Fai])],xn=[...b([l.Class.Warrior,l.Class.Wizard],Se),{filterToPropertyMapping:{property:"pitch",isNumber:!0},values:[void 0,"0","2","3"],cardTypes:[l.Type.Action,l.Type.AttackReaction,l.Type.DefenseReaction,l.Type.Instant,l.Type.Mentor,l.Type.Resource],excluded:!0,isOr:!0},{filterToPropertyMapping:{property:"types",isArray:!0,partialMatch:!0},values:["hero","mentor"],excluded:!0,isOr:!0},...A(l.Hero.Emperor)],Ln=[...b([l.Class.Illusionist],qe),...A(l.Hero.Enigma)],wn=[...b([l.Class.Ninja],Se),...A(l.Hero.Fai,[l.Hero.Dromai])],ur=[...b([l.Class.Merchant]),...A(l.Hero.GenisWotchuneed)],Bn=[...b([l.Class.Ninja]),...A(l.Hero.Ira)],dr=[...b([l.Class.Wizard],hn),...A(l.Hero.Iyslander)],Pn=[...b([l.Class.Wizard])],Dn=[...b([l.Class.Warrior]),...A(l.Hero.Kassai)],Rn=[...b([l.Class.Ninja]),...A(l.Hero.Katsu)],In=[...b([l.Class.Merchant]),...A(l.Hero.Kavdaen)],En=[...b([l.Class.Brute]),...A(l.Hero.Kayo)],_n=[...b([l.Class.Brute],et),...A(l.Hero.Levia)],On=[...b([l.Class.Ranger],fn),...A(l.Hero.Lexi)],zn=[...b([l.Class.Mechanologist]),...A(l.Hero.Maxx)],Nn=[...b([l.Class.Bard]),...A(l.Hero.Melody)],Hn=[...b([l.Class.Assassin],qe),...A(l.Hero.Nuu)],$n=[...b([l.Class.Guardian],dn),...A(l.Hero.Oldhim)],Wn=[...b([l.Class.Warrior]),...A(l.Hero.Olympia)],jn=[...b([l.Class.Illusionist],Xe),...A(l.Hero.Prism)],Gn=[...b([l.Class.Brute]),...A(l.Hero.Rhinar)],Kn=[...b([l.Class.Ranger]),...A(l.Hero.Riptide)],Un=[...b([l.Class.Merchant]),...A(l.Hero.Ruudi)],Yn=[{filterToPropertyMapping:{property:"classes",isArray:!0},values:["generic"],isOr:!0}],Vn=[...b([l.Class.Merchant]),...A(l.Hero.Squizzy)],Qn=[...b([l.Class.Guardian],un),...A(l.Hero.Bravo)],Jn=[...b([l.Class.Adjudicator],Se),...A(l.Hero.Taipanis)],Zn=[...b([]),...A(l.Hero.Taylor)],Xn=[...b([l.Class.Mechanologist]),...A(l.Hero.Teklovossen)],qn=[...b([l.Class.Adjudicator],Xe),...A(l.Hero.Theryon)],ea=[...b([l.Class.Assassin]),...A(l.Hero.Uzuri)],ta=[...b([l.Class.Guardian]),...A(l.Hero.Valda)],ra=[...b([l.Class.Guardian]),...A(l.Hero.Victor)],ia=[...b([l.Class.Runeblade]),...A(l.Hero.Viserai)],na=[...b([l.Class.Runeblade],et),...A(l.Hero.Vynnset)],aa=[...b([l.Class.Bard]),...A(l.Hero.Yorick)],oa=[...b([l.Class.Guardian]),...A(l.Hero.Yoji)],sa=[...b([l.Class.Ninja],qe),...A(l.Hero.Zen)],la=[{filterToPropertyMapping:{property:"bannedFormats",isArray:!0},values:["blitz"],excluded:!0},{filterToPropertyMapping:{property:"young",isBoolean:!0},values:[],cardTypes:["hero"]}],pr=[{filterToPropertyMapping:{property:"bannedFormats",isArray:!0},values:["blitz (living legend)"],excluded:!0},{filterToPropertyMapping:{property:"young",isBoolean:!0},values:[],cardTypes:["hero"]}],ca=[{filterToPropertyMapping:{property:"rarities",isArray:!0},values:["super rare","majestic","legendary","fabled"],excluded:!0},{filterToPropertyMapping:{property:"young",isBoolean:!0},values:[],cardTypes:["hero"]}],Me=[{filterToPropertyMapping:{property:"bannedFormats",isArray:!0},values:["classic constructed"],excluded:!0},{filterToPropertyMapping:{property:"young",isBoolean:!0},values:[],cardTypes:["hero"],excluded:!0}],se=[{filterToPropertyMapping:{property:"bannedFormats",isArray:!0},values:["classic constructed (living legend)"],excluded:!0},{filterToPropertyMapping:{property:"young",isBoolean:!0},values:[],cardTypes:["hero"],excluded:!0}],ua=[{filterToPropertyMapping:{property:"bannedFormats",isArray:!0},values:["commoner"],excluded:!0},{filterToPropertyMapping:{property:"young",isBoolean:!0},values:[],cardTypes:["hero"]}],Ze=[{filterToPropertyMapping:{property:"young",isBoolean:!0},values:[],cardTypes:["hero"]}],ue={blitz:la,"blitz ll":pr,"blitz living legend":pr,clash:ca,cc:Me,classic:Me,"classic constructed":Me,ll:se,"living legend":se,"cc ll":se,"ll cc":se,"classic constructed ll":se,"classic constructed living legend":se,constructed:Me,commoner:ua,upf:Ze,ultimate:Ze,"ultimate pit fight":Ze,arakni:gn,azalea:mn,benji:yn,betsy:vn,boltyn:bn,bravo:An,brevant:Mn,briar:Cn,brutus:kn,chane:Fn,dash:Tn,data:Je,"data doll":Je,datadoll:Je,dori:cr,dorinthea:cr,dromai:Sn,emperor:xn,enigma:Ln,fai:wn,genis:ur,geniswotchuneed:ur,ira:Bn,iyslander:dr,islander:dr,kano:Pn,kassai:Dn,katsu:Rn,kavdaen:In,kayo:En,levia:_n,lexi:On,maxx:zn,melody:Nn,nuu:Hn,oldhim:$n,olympia:Wn,prism:jn,rhinar:Gn,riptide:Kn,ruudi:Un,shiyana:Yn,squizzy:Vn,starvo:Qn,taipanis:Jn,taylor:Zn,teklovossen:Xn,theryon:qn,uzuri:ea,valda:ta,victor:ra,viserai:ia,vynnset:na,yorick:aa,yoji:oa,zen:sa},Ce=["common","rare","super rare","majestic","legendary","fabled"],da=(e,t,r)=>{let i=[];if(!t)i.push(...e);else for(let n of e)switch(t){case">=":let a=!1;for(let u of Ce)a?i.push(u):u===n&&(a=!0,i.push(u));break;case">":let s=!1;for(let u of Ce)s?i.push(u):u===n&&(s=!0);break;case"<=":let o=!1;for(let u of Ce.slice().reverse())o?i.push(u):u===n&&(o=!0,i.push(u));break;case"<":let c=!1;for(let u of Ce.slice().reverse())c?i.push(u):u===n&&(c=!0);break;default:break}return{filterToPropertyMapping:{property:"rarities",isArray:!0},isOr:!0,values:i,excluded:r}},pa=(e,t)=>{let r=[];for(let i of e)if(ue[i]){let n=ue[i];for(let a of n){let s=ne({},a);t&&!a.filterToPropertyMapping.isString&&(s.excluded=!a.excluded),r.push(s)}}return r},tt=(e,t,r,i)=>{let n=[];return ya(t)?n.push(...pa(r,e)):ba(t)&&n.push(da(r,i,e)),n},le=[{filterToPropertyMapping:{property:"cost",isNumber:!0},values:Te,excluded:!0},{filterToPropertyMapping:{property:"specialCost",isString:!0,partialMatch:!0},values:["*","x"],excluded:!0},{filterToPropertyMapping:{property:"types",isArray:!0,partialMatch:!0},values:["equipment","hero","placeholder","token","weapon"],excluded:!0}],K=[{filterToPropertyMapping:{property:"defense",isNumber:!0},values:Te,excluded:!0},{filterToPropertyMapping:{property:"specialDefense",isString:!0,partialMatch:!0},values:["*","x"],excluded:!0},{filterToPropertyMapping:{property:"types",isArray:!0,partialMatch:!0},values:["hero","placeholder","token","weapon"],excluded:!0}],ke=[{filterToPropertyMapping:{property:"pitch",isNumber:!0},excluded:!0,values:Te},{filterToPropertyMapping:{property:"types",isArray:!0,partialMatch:!0},values:["equipment","hero","placeholder","token","weapon"],excluded:!0},{filterToPropertyMapping:{property:"isCardBack",isBoolean:!0},values:["true"],excluded:!0}],X=[{filterToPropertyMapping:{property:"power",isNumber:!0},excluded:!0,values:Te},{filterToPropertyMapping:{property:"specialPower",isString:!0,partialMatch:!0},values:["*","x"],excluded:!0},{filterToPropertyMapping:{property:"types",isArray:!0,partialMatch:!0},values:["equipment","hero","placeholder","token"],excluded:!0}],Fe=[{filterToPropertyMapping:{property:"talents",isArray:!0},excluded:!0,values:Object.values(l.Talent).map(e=>e.toLowerCase())}],ha={"!co":le,"-co":le,"!cost":le,"-cost":le,"!color":le,"-color":le,"!b":K,"-b":K,"!block":K,"-block":K,"!d":K,"-d":K,"!def":K,"-def":K,"!defense":K,"-defense":K,"!pitch":ke,"-pitch":ke,"!p":ke,"-p":ke,"!attack":X,"-attack":X,"!power":X,"-power":X,"!pwr":X,"-pwr":X,"!pow":X,"-pow":X,"!talents":Fe,"-talents":Fe,"!tal":Fe,"-tal":Fe},rt=e=>{let t=[],r=ha[e];return r&&t.push(...r),t},fa=(e,t)=>[...ue[e.toLowerCase()],...t?ue[t.toLowerCase()]:[]],ga=e=>{var t;return((t=ue[e.toLowerCase().split(" ")[0]])==null?void 0:t.length)>0},ma=["l","legal","hero"],ya=e=>ma.includes(e),va=["r","rarity"],ba=e=>va.includes(e);var it={aa:["st:attack"],ab:['k:"arcane barrier"'],ar:['t:"attack reaction"'],dr:['t:"defense reaction"'],ga:['k:"go again"'],naa:["t:action","st:nonattack"],poppers:["!c:illusionist","st:attack","pwr:>=6","def:>=0"],popper:["!c:illusionist","st:attack","pwr:>=6","def:>=0"],sv:['k:"spellvoid"']};var Rr=[">=",">","<=","<"],Ir=["!","-"],nt={property:"artists",isArray:!0,partialMatch:!0},Aa={property:"n/a"},hr={property:"classes",isArray:!0,partialMatch:!0},fr={property:"cost",specialProperty:"specialCost",isNumber:!0,partialMatch:!0},de={property:"defense",specialProperty:"specialDefense",isNumber:!0},gr={nestedProperty:"foiling",property:"printings",isArray:!0},mr={property:"fusions",isArray:!0},yr={property:"intellect",isNumber:!0},vr={property:"keywords",isArray:!0,partialMatch:!0},at={property:"n/a",isMeta:!0},br={property:"life",specialProperty:"specialLife",isNumber:!0},Ar={property:"name",isString:!0},ot={property:"pitch",isNumber:!0},xe={property:"power",specialProperty:"specialPower",isNumber:!0},Mr={property:"n/a",isMeta:!0},Ma={property:"n/a"},Ca={property:"n/a"},Cr={property:"restrictedFormats",isArray:!0,partialMatch:!0},kr={property:"sets",isArray:!0,partialMatch:!0},Le={property:"specializations",isArray:!0,partialMatch:!0},Fr={property:"subtypes",isArray:!0},Tr={property:"types",isArray:!0},Sr={property:"talents",isArray:!0},ka={property:"functionalText",isString:!0,partialMatch:!0},Fa={property:"typeText",isString:!0,partialMatch:!0},we={nestedProperty:"treatment",property:"printings",isArray:!0},Be={a:nt,artist:nt,art:nt,attack:xe,b:de,block:de,c:hr,class:hr,chain:Aa,co:fr,cost:fr,color:ot,d:de,def:de,defense:de,f:mr,fusion:mr,foil:gr,foiling:gr,i:yr,intellect:yr,k:vr,keyword:vr,l:at,legal:at,hero:at,li:br,life:br,n:Ar,name:Ar,p:ot,pitch:ot,pwr:xe,pow:xe,power:xe,r:Mr,rarity:Mr,referencedby:Ma,references:Ca,rf:Cr,restricted:Cr,s:kr,set:kr,sp:Le,spec:Le,specialization:Le,specializations:Le,st:Fr,subtype:Fr,t:Tr,type:Tr,tal:Sr,talent:Sr,text:ka,treat:we,treatment:we,var:we,variation:we,x:Fa},Ta=[{text:T.Release.ClassicBattlesRhinarDorinthea.toLowerCase(),override:T.Release.ClassicBattlesRhinarDorinthea.toLowerCase().replaceAll(L,"")}],Sa=e=>{var n;let t=[],r=e.trim().toLowerCase();for(let{text:a,override:s}of Ta)r.includes(a)&&(r=r.replace(a,s));if((n=Ae(r))==null?void 0:n.card)t.push(r);else{let a=r.split(/[ ]+/),s="",o=0;for(let c of a)o===2&&(t.push(s.trim().replaceAll('"',"")),s="",o=0),o<2&&c.split('"').length===2?(s+=" "+c,o++):o===0&&s===""?t.push(c):o===1&&(s+=" "+c);o===2&&(t.push(s.trim().replaceAll('"',"")),s="",o=0)}return t},xa=[T.Hero.Briar,T.Hero.Brutus,T.Hero.Emperor,T.Hero.Prism,T.Hero.Shiyana,T.Hero.Taylor,T.Hero.Yorick],lt=(e,t)=>{var f;let r=Sa(e),i=[];for(let p of r){let m=it[p];m?i.push(...m):i.push(p)}let n=[],a=[],s=[],o=[],c=[],u=[],d={isClash:!1,heroes:[]};for(let p of i)if(_a(p)){let[m,y]=p.split(":"),{modifier:g,values:h,isAnd:v,isOr:C}=Ia(y),{filterKey:S,excluded:k,isMeta:x}=Ea(m);if(x){if(["rarity","r"].includes(S)&&(h=Ra(h)),["legal","l","hero"].includes(S)){for(let F of xa)y.includes(F.toLowerCase())&&(d.heroes.includes(F)||d.heroes.push(F));y.includes("clash")&&(d.isClash=!0)}n.push(...tt(k,S,h,g))}else{if(["chain"].includes(S)){let F=R=>R.name.toLowerCase().replaceAll(L,""),w=h.map(R=>ct(R,t)).filter(R=>!!R).map(F),D=new Set(w);S="name",C=!0;let P=20,N=0,E=R=>{if(!R.types.includes(T.Type.Hero)){let H=F(R);D.add(H),w.includes(H)||w.push(H)}};for(let R of w){if(N>P)break;let{referencedBy:H,references:re}=Pe(R,t);re.forEach(E),N===0&&H.forEach(E),N++}h=Array.from(D)}else if(["referencedby","references"].includes(S)){let F=S,w=[...h].filter(D=>!!D);h=[],S="name",C=!0;for(let D of w){let{referencedBy:P,references:N}=Pe(D,t);["referencedby"].includes(F)?h.push(...N.map(({name:E})=>E.toLowerCase().replaceAll(L,""))):["references"].includes(F)&&h.push(...P.map(({name:E})=>E.toLowerCase().replaceAll(L,"")))}}else["art","artist"].includes(S)?a=h:["foiling","foil"].includes(S)?(o=Pa(h),h=o.map(F=>F.toLowerCase())):["treat","treatment","var","variation"].includes(S)?(u=Da(h),h=u.map(F=>F.toLowerCase())):["set","s"].includes(S)?(c=La(h),h=c.map(F=>F.toLowerCase().replaceAll(L,""))):["pitch","p","color"].includes(S)&&(h=Ba(h));Be[S]&&n.push({filterToPropertyMapping:Be[S],values:h,isAnd:v,isOr:C,modifier:g,excluded:k})}}else if(p){let m=(f=Ae(p))==null?void 0:f.card,y=rt(p);m?s.push(`"${m.toLowerCase().replace(L,"")}"`):y&&y.length>0?n.push(...y):s.push(p.replace(L,""))}return{appliedFilters:n,attributes:{artists:a,foilings:o,releases:c,treatments:u},keywords:s,specialConditions:d}},La=e=>{let t=[];for(let r of e)t.push(...wa(r));return t},wa=e=>{let t=[],r=Object.values(T.Release).find(i=>i.toLowerCase().replaceAll(L,"")===e);if(r&&t.push(r),t.length===0){let i=T.setIdentifierToSetMappings[e];i&&t.push(i)}if(t.length===0){let i=Object.values(T.Release).filter(n=>n.toLowerCase().includes(e));i.length>0&&t.push(...i)}return t},st={blue:3,yellow:2,red:1,white:0},Ba=e=>{let t=[];for(let r of e)st[r]||st[r]===0?t.push(st[r].toString()):t.push(r);return t},xr={r:T.Foiling.R,rf:T.Foiling.R,rainbow:T.Foiling.R,c:T.Foiling.C,cf:T.Foiling.C,cold:T.Foiling.C,g:T.Foiling.G,gf:T.Foiling.G,gold:T.Foiling.G},Pa=e=>{let t=[];for(let r of e)xr[r]&&t.push(xr[r]);return t},Lr=Ct(ne({},Object.values(T.Treatment).reduce((e,t)=>(e[t.toLowerCase()]=t,e),{})),{aa:T.Treatment.AA,alt:T.Treatment.AA,"alt art":T.Treatment.AA,ab:T.Treatment.AB,"alt border":T.Treatment.AB,at:T.Treatment.AT,"alt text":T.Treatment.AT,ea:T.Treatment.EA,extended:T.Treatment.EA,"extended art":T.Treatment.EA,fa:T.Treatment.FA,full:T.Treatment.FA,"full art":T.Treatment.FA}),Da=e=>{let t=[];for(let r of e)Lr[r]?t.push(Lr[r]):T.Treatment[r.toUpperCase()]&&t.push(T.Treatment[r.toUpperCase()]);return t},wr={c:"common",f:"fabled",l:"legendary",m:"majestic",v:"marvel",r:"rare",s:"super rare",t:"token"},Ra=e=>{let t=[];for(let r of e)wr[r]?t.push(wr[r]):t.push(r);return t},Ia=e=>{let t=[],r,i,n=Rr.find(a=>e.includes(a));if(n){let[,a]=e.split(n);Br(a)?(r=!0,t.push(...a.trim().split("+").map(s=>s.replace(L,"")))):Pr(a)?(i=!0,t.push(...a.trim().split(",").map(s=>s.replace(L,"")))):t.push(a.trim().replace(L,""))}else Br(e)?(r=!0,t.push(...e.trim().split("+").map(a=>a.replace(L,"")))):Pr(e)?(i=!0,t.push(...e.trim().split(",").map(a=>a.replace(L,"")))):e.startsWith('"')&&e.endsWith('"')?t.push(e.trim().replaceAll('"',"").replace(L,"")):t.push(e.trim().replace(L,""));return{modifier:n,values:t,isAnd:r,isOr:i}},Ea=e=>{let t=Oa(e);if(t){let[,r]=e.split(t);return{excluded:!0,filterKey:r,isMeta:Dr(r)}}else return{excluded:!1,filterKey:e,isMeta:Dr(e)}},_a=e=>e.indexOf(":")>=0,Br=e=>e.indexOf("+")>=0,Pr=e=>e.indexOf(",")>=0,Dr=e=>{var t;return!!((t=Be[e])!=null&&t.isMeta)},Oa=e=>{var t;return(t=Ir.find(r=>e.includes(r)))==null?void 0:t.slice(0,1)};var I=W(j()),Er={artists:["Hoodwill"],cardIdentifier:"fangs-a-lot-blue",classes:[I.Class.Generic],defaultImage:"FNG000",functionalText:"If Fangs A Lot is put into your banished zone from your graveyard, instead put it into your hand.",printings:[{artist:"Hoodwill",identifier:"FNG000",image:"FNG000",print:"FNG000",set:I.Release.Promos},{artist:"Hoodwill",identifier:"FNG000",image:"FNG000_Marvel",print:`FNG000-${I.Treatment.FA}`,set:I.Release.Promos,treatment:I.Treatment.FA}],name:"Fangs A Lot",rarities:[I.Rarity.Rare],rarity:I.Rarity.Rare,sets:[I.Release.Promos],setIdentifiers:["FNG000"],specialImage:"FNG000_Marvel",subtypes:[I.Subtype.Attack],types:[I.Type.Action],typeText:"Generic Action - Attack"},_r=[{keyword:Er.name.toLowerCase(),card:Er}];var dt=W(j());var pt=class{constructor(t){this.search=(t,r)=>{let i,{appliedFilters:n,attributes:a,keywords:s,specialConditions:o}=lt(t,this.cards),c=s.join(" "),u=r?_r.filter(g=>g.keyword===c):[];if(u.length>0?i=u.map(({card:g})=>g):s.length?i=this.fuse.search(c).map(g=>g.item):i=[...this.cards],n.length&&(i=i.filter(g=>g&&zr(g,n,o)),n.some(({excluded:g,values:h})=>!g&&h.includes(B.Format.ClassicConstructed.toLowerCase()))&&(i=i.filter(g=>!g.young)),n.some(({excluded:g,values:h})=>!g&&(h.includes(B.Format.Blitz.toLowerCase())||h.includes(B.Format.Commoner.toLowerCase())))&&(i=i.filter(g=>{let{types:h,young:v}=g;return!(h.includes(B.Type.Hero)&&!v)}))),s.length===0){let g="";if(a.releases.length===1)try{let h=a.releases[0];g=B.setToSetIdentifierMappings[h][0].toUpperCase()}catch(h){console.error("Error getting set identifier from search",h)}g?i.sort((h,v)=>{var k,x;let C=(k=h.setIdentifiers.find(F=>F.includes(g)))==null?void 0:k.replace(g,""),S=(x=v.setIdentifiers.find(F=>F.includes(g)))==null?void 0:x.replace(g,"");return C&&S?C.localeCompare(S):-1}):i.sort((h,v)=>h.name===v.name?`${h.pitch}`.localeCompare(`${v.pitch}`):h.name.localeCompare(v.name))}else{let g=[],h=[],v=s.map(C=>C.toLowerCase().replace(L,"")).join(" ");for(let C of i)C.name.toLowerCase().replace(L,"")===v?g.push(C):h.push(C);i=[...g,...h]}let d,{artists:f,foilings:p,releases:m,treatments:y}=a;return(f.length>0||p.length>0||m.length>0||y.length>0)&&(d=i.map(g=>{let h=g.printings.filter(v=>{let C=!!v.image,S=f.length===0||f.some(w=>v.artist.replace(L,"").toLowerCase().includes(w)),k=p.length===0||p.includes(v.foiling),x=m.length===0||m.includes(v.set),F=y.length===0||y.includes(v.treatment);return C&&S&&k&&x&&F});return ne({matchingPrintings:h},g)})),{appliedFilters:n,attributes:a,keywords:s,searchResults:d||i}};let r={getFn:(i,n)=>{let a=ut.default.config.getFn(i,n);return a&&(Array.isArray(a)?a.map(s=>s.replace(L,"")):a.replace(L,""))},ignoreLocation:!0,includeScore:!0,keys:[{name:"name",weight:10},{name:"functionalText",weight:6},{name:"setIdentifiers",weight:2},{name:"typeText",weight:6}],threshold:.15,useExtendedSearch:!0};this.cards=[...t],this.fuse=new ut.default([...t],r)}},Or=pt,zr=(e,t,r)=>{var n,a,s,o;let i=!0;for(let c of t){let{isNumber:u,isString:d,isArray:f,isBoolean:p,property:m}=c.filterToPropertyMapping;if((u&&!za(e,c)||d&&!Na(e,c)||f&&!Ha(e,c)||p&&!$a(e,c))&&(i=!1),r.isClash&&["rarities","bannedFormats"].includes(m)){let k=[B.Rarity.SuperRare,B.Rarity.Majestic,B.Rarity.Legendary,B.Rarity.Fabled].some(P=>e.rarities.includes(P)),x=!1;for(let{cardIdentifiers:P,heroes:N}of Ve)for(let E of r.heroes)N.includes(E)&&P.includes(e.cardIdentifier)&&(x=!0);let F=!!e.specializations&&e.specializations.length>0||x,w=[B.Type.Mentor,B.Type.Weapon].some(P=>e.types.includes(P)),D=Ye.includes(e.name);!i&&!D&&(F||w)&&k&&(i=!0),D&&(i=!1)}if(r.isClash&&r.heroes.includes(B.Hero.Briar)&&e.name==="Rosetta Thorn"&&(i=!0),!i&&r.heroes.includes(B.Hero.Brutus)){let k=((n=e.specializations)==null?void 0:n.length)>0;((a=e.keywords)==null?void 0:a.includes(dt.Keyword.Clash))&&!k&&(i=!0)}if(!i&&r.heroes.includes(B.Hero.Shiyana)&&["classes"].includes(m)){let k=((s=e.specializations)==null?void 0:s.length)>0,x=e.types.includes(B.Type.Token),F=e.cardIdentifier==="cracked-bauble-yellow",w=(o=e.keywords)==null?void 0:o.includes(dt.Keyword.Ephemeral);(k||x||F||w)&&(i=!0)}let v=e.types.includes(B.Type.Equipment);if(!i&&r.heroes.includes(B.Hero.Taylor)&&v&&v&&(i=!0),!i&&r.heroes.includes(B.Hero.Yorick)&&(["classes"].includes(m)||["talents"].includes(m))&&e.types.includes(B.Type.Token)&&(i=!0),!i)break}return i},za=(e,t)=>{var r;if(De(t,e)){let{values:i,modifier:n,excluded:a,filterToPropertyMapping:{partialMatch:s}}=t,o=ht(e,t);if(o!=null&&!isNaN(o))if(o=parseInt(o),n)switch(n){case">=":let c=i==null?void 0:i.some(p=>o>=parseInt(p));return a?!c:c;case">":let u=i==null?void 0:i.some(p=>o>parseInt(p));return a?!u:u;case"<=":let d=i==null?void 0:i.some(p=>o<=parseInt(p));return a?!d:d;case"<":let f=i==null?void 0:i.some(p=>o<parseInt(p));return a?!f:f;default:return!1}else{let c=i==null?void 0:i.some(u=>o===parseInt(u));return a?!c:c}else{let c=(r=ja(e,t))==null?void 0:r.toLowerCase(),u=s?i==null?void 0:i.some(d=>c==null?void 0:c.includes(d)):i==null?void 0:i.some(d=>c===d);return a?!u:u}}else return!0},Na=(e,t)=>{var r;if(De(t,e)){let{values:i,isAnd:n,excluded:a,filterToPropertyMapping:{partialMatch:s}}=t,o=(r=ht(e,t))==null?void 0:r.replaceAll(L,"");if(s){let c=n?i==null?void 0:i.every(u=>o==null?void 0:o.toLowerCase().includes(u)):i==null?void 0:i.some(u=>o==null?void 0:o.toLowerCase().includes(u));return a?!c:c}else{let c=n?i==null?void 0:i.every(u=>(o==null?void 0:o.toLowerCase())===u):i==null?void 0:i.some(u=>(o==null?void 0:o.toLowerCase())===u);return a?!c:c}}else return!0},Ha=(e,t)=>{if(De(t,e)){let{values:r,isAnd:i,excluded:n,filterToPropertyMapping:{partialMatch:a}}=t,s=Wa(e,t).map(o=>o==null?void 0:o.replaceAll(L,""));if(a){let o=i?r.every(u=>s==null?void 0:s.some(d=>d==null?void 0:d.toLowerCase().includes(u))):r.some(u=>s==null?void 0:s.some(d=>d==null?void 0:d.toLowerCase().includes(u))),c=s.length===0;return n?!o||c:o}else{let o=i?r.every(c=>s==null?void 0:s.some(u=>(u==null?void 0:u.toLowerCase())===c)):r.some(c=>s==null?void 0:s.some(u=>(u==null?void 0:u.toLowerCase())===c));return n?!o:o}}else return!0},$a=(e,t)=>{if(De(t,e)){let{excluded:r}=t,i=ht(e,t);return r?!i:i}else return!0},ht=(e,t)=>{let{filterToPropertyMapping:r}=t;return e[r.property]},Wa=(e,t)=>{let{filterToPropertyMapping:{nestedProperty:r,property:i}}=t,n=e[i]||[];return r?n.map(a=>a[r]).filter(a=>!!a):n},ja=(e,t)=>{let{filterToPropertyMapping:r}=t;return e[r.specialProperty]},De=({cardTypes:e},{types:t,subtypes:r})=>!e||(e==null?void 0:e.some(i=>t.map(n=>n.toLowerCase()).includes(i.toLowerCase())||r.map(n=>n.toLowerCase()).includes(i.toLowerCase())));var ct=(e,t)=>{let r=t.find(i=>i.name.toLowerCase().replace(L,"")===e);return r||(r=t.find(i=>i.name.toLowerCase().replace(L,"").includes(e))),r};var U=W(j()),Ga=e=>{let t=e.filter(o=>o.types.includes(U.Type.Hero)).sort((o,c)=>o.name.localeCompare(c.name)),r=t.filter(o=>!o.young&&!o.classes.includes(U.Class.Adjudicator)),i=t.filter(o=>{let c=o.rarities.some(d=>d!==U.Rarity.Promo),u=o.sets.some(d=>d!==U.Release.Promos);return c||u}),n=t.filter(o=>{let c=o.rarities.every(d=>d===U.Rarity.Promo),u=o.sets.every(d=>d===U.Release.Promos);return c&&u}),a=t.filter(o=>o.young),s=a.filter(({hero:o})=>!r.find(c=>c.hero===o));return{all:t,adult:r,nonPromo:i,promoOnly:n,young:a,youngOnly:s}};var $r=W(j());var ft=W(j()),Ka={"Dawnblade, Resplendent":"Dawnblade"},Nr=e=>Ka[e.name]||e.name,Hr=e=>{var t;return(t=e.functionalText)==null?void 0:t.replaceAll(e.name,"")},Pe=(e,t)=>{let r=t.find(i=>i.name.toLowerCase().replace(L,"")===e);return r||(r=t.find(i=>i.name.toLowerCase().replace(L,"").includes(e))),gt(r,t)},gt=(e,t)=>{var a,s;let r=[],i=[],n=[];if(e){let o=[],c=[],u=Nr(e);for(let d of t){let f=Nr(d),p=u===f,m=e.pitch!==d.pitch;if(p&&m)r.push(d);else if(!p){let y=e.name==="Seismic Surge",g=(a=d.keywords)==null?void 0:a.includes(ft.Keyword.Heave),h=y&&g,v=Hr(d),C=v==null?void 0:v.includes(u),S=Hr(e),k=S==null?void 0:S.includes(f);(C||h)&&o.push(d);let x=d.name==="Seismic Surge",F=(s=e.keywords)==null?void 0:s.includes(ft.Keyword.Heave);(k||x&&F)&&c.push(d)}}for(let d of o)i.push(d);for(let d of c){let f=d.name;u!==f&&!c.some(p=>{let m=p.name;return m!==f&&m.includes(f)})&&n.push(d)}}return{otherPitches:r,referencedBy:i,references:n}},Ua=["cash-in-yellow"],Ya=(e,t,r)=>{let i=new Set;for(let n of e.filter(({cardIdentifier:a})=>!Ua.includes(a))){let{references:a}=gt(n,t);for(let s of a.filter(o=>{let c=o.name==="Hyper Driver",u=r===$r.Hero.Maxx;return!c||u}))i.add(s)}return Array.from(i)};0&&(module.exports={PUNCTUATION,abbreviations,availableExclusions,availableModifiers,clashBannedCards,clashSpecializationOverrides,filterCard,filtersToCardPropertyMappings,getAbbreviation,getAbbreviationByCard,getCardByName,getDeckFilters,getExcludedMetaFilters,getHeroBreakdown,getKeywordsAndAppliedFiltersFromText,getMetaFilters,getRelatedCards,getRelatedCardsByName,getTokensReferencedByCards,heroHasFilters,shorthands});
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@flesh-and-blood/search",
3
3
  "description": "TypeScript search engine for Flesh and Blood cards",
4
- "version": "2.0.143",
4
+ "version": "2.0.144",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",
7
7
  "scripts": {
@@ -12,11 +12,11 @@
12
12
  "full": "npm run build"
13
13
  },
14
14
  "dependencies": {
15
- "@flesh-and-blood/types": "^2.0.94",
15
+ "@flesh-and-blood/types": "^2.0.144",
16
16
  "fuse.js": "^6.6.2"
17
17
  },
18
18
  "devDependencies": {
19
- "@flesh-and-blood/cards": "^2.0.143",
19
+ "@flesh-and-blood/cards": "^2.0.144",
20
20
  "@types/jest": "^29.5.11",
21
21
  "@types/node": "^20.10.5",
22
22
  "esbuild": "^0.19.10",
@@ -46,5 +46,5 @@
46
46
  "FAB",
47
47
  "FABTCG"
48
48
  ],
49
- "gitHead": "9359c5d956573a036ef4849595788a5a26a9398f"
49
+ "gitHead": "e1eb8b3d0da196d916db47d7edfd8cd9f4fcf4ac"
50
50
  }