Global

Members

(constant) maxPartySize :number

The maximum allowed number of Pokémon in a party
Type:
  • number
Source:

(constant) party :Array.<string>

An array of Pokémon dex IDs currently in the party.
Type:
  • Array.<string>
Source:

(constant) results :HTMLElement

The container where filtered Pokémon are displayed
Type:
  • HTMLElement
Source:

(constant) selectedEvolution :HTMLSelectElement

Filter for showing only final-evolution Pokémon
Type:
  • HTMLSelectElement
Source:

(constant) selectedEvolve :HTMLSelectElement

Filter for excluding Pokémon that evolve by trade
Type:
  • HTMLSelectElement
Source:

(constant) selectedLegendary :HTMLSelectElement

Filter for excluding legendary Pokémon
Type:
  • HTMLSelectElement
Source:

(constant) selectedSprites :HTMLSelectElement

Dropdown for choosing sprite style
Type:
  • HTMLSelectElement
Source:

(constant) selectedUnobtainable :HTMLSelectElement

Filter for hiding unobtainable Pokémon
Type:
  • HTMLSelectElement
Source:

(constant) selectedVersion :HTMLSelectElement

Version filter: red, blue, or yellow
Type:
  • HTMLSelectElement
Source:

(constant) typeChart :Object.<string, Object.<string, number>>

Gen 1 type matchup chart showing effectiveness multipliers.
Type:
  • Object.<string, Object.<string, number>>
Source:

Methods

ViewPokemon(dexResults) → {void}

Renders filtered Pokémon sprites based on selected version, evolution, and other options. Appends the images to the results container.
Parameters:
Name Type Description
dexResults Object The full Dex dataset including image base path and Pokémon list
Source:
Returns:
Type
void

calculateTeamWeaknesses() → {void}

Calculates how many party Pokémon have each type (e.g., water, fire). Sends the results to `displayTeamWeaknessTable` for rendering.
Source:
Returns:
Type
void

clearParty() → {void}

Clears all Pokémon from the party and hides the Clear Party button. Also re-renders the (empty) party area.
Source:
Returns:
Type
void

displayTeamWeaknessTable(typeCounts) → {void}

Displays a table summarizing the number of Pokémon per type in the current team.
Parameters:
Name Type Description
typeCounts Object.<string, number> An object mapping each type (e.g., 'fire') to its count
Source:
Returns:
Type
void

fetchDexEntries() → {Promise.<Object>}

Fetches the Gen 1 Pokédex entries from a local JSON file.
Source:
Returns:
A Promise resolving to parsed Dex data including images and Pokémon.
Type
Promise.<Object>

getIndividualTypeAnalysis(types, pokemonData) → {Object}

Processes a Pokémon's effectiveness map (from JSON) into categorized matchups.
Parameters:
Name Type Description
types Array.<string> Array of Pokémon types (e.g., ['fire', 'flying'])
pokemonData Object Full Pokémon object from the JSON data
Properties
Name Type Description
weaknesses Object.<string, number> Type effectiveness multipliers
Source:
Returns:
Breakdown of type matchups: - weaknesses: string[] - resistances: string[] - neutral: string[] - strongAgainst: string[] - noEffect: string[]
Type
Object

getIndividualTypeAnalysis(types) → {Object}

Analyzes how a given type or type combination fares against all other types.
Parameters:
Name Type Description
types Array.<string> Array of a Pokémon's types (e.g., ['water', 'ice'])
Source:
Returns:
Object with keys: - weaknesses: string[] - resistances: string[] - immunities: string[] - neutral: string[] - strongAgainst: string[]
Type
Object

updatePartyDisplay() → {void}

Updates the party display area with current party Pokémon. Loads sprites and shows a breakdown of type matchups.
Source:
Returns:
Type
void