# waleedtarbosh/advanced-pre-work-prosports architecture

> Architecture diagram of the GitHub repository waleedtarbosh/advanced-pre-work-prosports, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-10-13). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/waleedtarbosh/advanced-pre-work-prosports
- Repository: https://github.com/waleedtarbosh/advanced-pre-work-prosports

## Overview

ProSports is a multi-page football statistics website. A visitor chooses a statistics page, enters search criteria, and the page JavaScript requests API-Football data and renders results in that page. The feature pages cover fixtures, tables, teams, player details and history, squads, transfers, trophies, injuries, and player leaderboards. The excerpts show this request-and-render flow directly for several pages; README descriptions establish the other product capabilities. Those unsampled pages are included, but their individual call details are not inferred.

Main entry points: [`index.html`](https://github.com/waleedtarbosh/advanced-pre-work-prosports/blob/main/index.html) (Homepage), [`fixtures/fixtures.js`](https://github.com/waleedtarbosh/advanced-pre-work-prosports/blob/main/fixtures/fixtures.js) (Fixtures and results), [`standings/standings.js`](https://github.com/waleedtarbosh/advanced-pre-work-prosports/blob/main/standings/standings.js) (League standings), [`teams/teams.js`](https://github.com/waleedtarbosh/advanced-pre-work-prosports/blob/main/teams/teams.js) (Team information)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_navigation["Site navigation"]
  node_home["Homepage<br/>[index.html]"]
  node_site_ui["Navigation UI<br/>[main.js]"]
end

subgraph group_match_team["Matches and teams"]
  node_fixtures["Fixtures and results<br/>[fixtures.js]"]
  node_standings["League standings<br/>[standings.js]"]
  node_teams["Team information<br/>[teams.js]"]
  node_injuries["Player injuries<br/>[injuries.js]"]
end

subgraph group_player["Player information"]
  node_player_stats["Player statistics<br/>[get_players.js]"]
  node_player_detail["Player details<br/>[player_name.js]"]
  node_seasons["Player seasons<br/>[season.js]"]
  node_player_history["Team history<br/>[player_history.js]"]
  node_squads["Team squads<br/>[team_squad.js]"]
  node_transfers["Transfers"]
  node_trophies["Trophies<br/>[player_trophies.js]"]
end

subgraph group_leaders["Player leaderboards"]
  node_top_scorers["Top scorers<br/>[top_scorers.js]"]
  node_top_assists["Top assists<br/>[top_assists.js]"]
  node_top_yellows["Top yellow cards"]
  node_top_reds["Top red cards<br/>[top_red_cards.js]"]
end

node_visitor(("Visitor"))
node_football_api["API-Football"]

node_visitor -->|"opens"| node_home
node_home -->|"initializes"| node_site_ui
node_visitor -->|"searches"| node_fixtures
node_visitor -->|"searches"| node_standings
node_visitor -->|"searches"| node_teams
node_visitor -->|"searches"| node_injuries
node_visitor -->|"searches"| node_player_stats
node_visitor -->|"views"| node_player_detail
node_visitor -->|"searches"| node_seasons
node_visitor -->|"searches"| node_player_history
node_visitor -->|"searches"| node_squads
node_visitor -->|"searches"| node_transfers
node_visitor -->|"searches"| node_trophies
node_visitor -->|"searches"| node_top_scorers
node_visitor -->|"searches"| node_top_assists
node_visitor -->|"searches"| node_top_yellows
node_visitor -->|"searches"| node_top_reds
node_fixtures -->|"fetches fixtures"| node_football_api
node_standings -->|"fetches standings"| node_football_api
node_teams -->|"fetches teams"| node_football_api
node_injuries -->|"fetches injuries"| node_football_api
node_player_stats -->|"fetches stats"| node_football_api
node_player_detail -->|"fetches details"| node_football_api
node_seasons -->|"fetches seasons"| node_football_api
node_player_history -->|"fetches history"| node_football_api
node_squads -->|"fetches squads"| node_football_api
node_transfers -->|"fetches transfers"| node_football_api
node_trophies -->|"fetches trophies"| node_football_api
node_top_scorers -->|"fetches leaders"| node_football_api
node_top_assists -->|"fetches leaders"| node_football_api
node_top_yellows -->|"fetches leaders"| node_football_api
node_top_reds -->|"fetches leaders"| node_football_api

click node_home "https://github.com/waleedtarbosh/advanced-pre-work-prosports/blob/main/index.html"
click node_site_ui "https://github.com/waleedtarbosh/advanced-pre-work-prosports/blob/main/main.js"
click node_fixtures "https://github.com/waleedtarbosh/advanced-pre-work-prosports/blob/main/fixtures/fixtures.js"
click node_standings "https://github.com/waleedtarbosh/advanced-pre-work-prosports/blob/main/standings/standings.js"
click node_teams "https://github.com/waleedtarbosh/advanced-pre-work-prosports/blob/main/teams/teams.js"
click node_injuries "https://github.com/waleedtarbosh/advanced-pre-work-prosports/blob/main/injuries/injuries.js"
click node_player_stats "https://github.com/waleedtarbosh/advanced-pre-work-prosports/blob/main/get_players/get_players.js"
click node_player_detail "https://github.com/waleedtarbosh/advanced-pre-work-prosports/blob/main/player_name/player_name.js"
click node_seasons "https://github.com/waleedtarbosh/advanced-pre-work-prosports/blob/main/season/season.js"
click node_player_history "https://github.com/waleedtarbosh/advanced-pre-work-prosports/blob/main/player_history/player_history.js"
click node_squads "https://github.com/waleedtarbosh/advanced-pre-work-prosports/blob/main/team_squad/team_squad.js"
click node_transfers "https://github.com/waleedtarbosh/advanced-pre-work-prosports/blob/main/player_transfers/player_transfers.js"
click node_trophies "https://github.com/waleedtarbosh/advanced-pre-work-prosports/blob/main/player_trophies/player_trophies.js"
click node_top_scorers "https://github.com/waleedtarbosh/advanced-pre-work-prosports/blob/main/top_scorers/top_scorers.js"
click node_top_assists "https://github.com/waleedtarbosh/advanced-pre-work-prosports/blob/main/top_assists/top_assists.js"
click node_top_yellows "https://github.com/waleedtarbosh/advanced-pre-work-prosports/blob/main/top_yellow_cards/top_yellow_cards.js"
click node_top_reds "https://github.com/waleedtarbosh/advanced-pre-work-prosports/blob/main/top_red_cards/top_red_cards.js"

classDef toneNeutral fill:#f8fafc,stroke:#334155,stroke-width:1.5px,color:#0f172a
classDef toneBlue fill:#dbeafe,stroke:#2563eb,stroke-width:1.5px,color:#172554
classDef toneAmber fill:#fef3c7,stroke:#d97706,stroke-width:1.5px,color:#78350f
classDef toneMint fill:#dcfce7,stroke:#16a34a,stroke-width:1.5px,color:#14532d
classDef toneRose fill:#ffe4e6,stroke:#e11d48,stroke-width:1.5px,color:#881337
classDef toneIndigo fill:#e0e7ff,stroke:#4f46e5,stroke-width:1.5px,color:#312e81
classDef toneTeal fill:#ccfbf1,stroke:#0f766e,stroke-width:1.5px,color:#134e4a
class node_home,node_site_ui toneBlue
class node_fixtures,node_standings,node_teams,node_injuries toneAmber
class node_player_stats,node_player_detail,node_seasons,node_player_history,node_squads,node_transfers,node_trophies,node_football_api toneMint
class node_top_scorers,node_top_assists,node_top_yellows,node_top_reds toneRose
class node_visitor toneIndigo
```

## Components

### Site navigation

- [Homepage](https://github.com/waleedtarbosh/advanced-pre-work-prosports/blob/main/index.html): `index.html`
- [Navigation UI](https://github.com/waleedtarbosh/advanced-pre-work-prosports/blob/main/main.js): `main.js`

### Matches and teams

- [Fixtures and results](https://github.com/waleedtarbosh/advanced-pre-work-prosports/blob/main/fixtures/fixtures.js): `fixtures/fixtures.js`
- [League standings](https://github.com/waleedtarbosh/advanced-pre-work-prosports/blob/main/standings/standings.js): `standings/standings.js`
- [Team information](https://github.com/waleedtarbosh/advanced-pre-work-prosports/blob/main/teams/teams.js): `teams/teams.js`
- [Player injuries](https://github.com/waleedtarbosh/advanced-pre-work-prosports/blob/main/injuries/injuries.js): `injuries/injuries.js`

### Player information

- [Player statistics](https://github.com/waleedtarbosh/advanced-pre-work-prosports/blob/main/get_players/get_players.js): `get_players/get_players.js`
- [Player details](https://github.com/waleedtarbosh/advanced-pre-work-prosports/blob/main/player_name/player_name.js): `player_name/player_name.js`
- [Player seasons](https://github.com/waleedtarbosh/advanced-pre-work-prosports/blob/main/season/season.js): `season/season.js`
- [Team history](https://github.com/waleedtarbosh/advanced-pre-work-prosports/blob/main/player_history/player_history.js): `player_history/player_history.js`
- [Team squads](https://github.com/waleedtarbosh/advanced-pre-work-prosports/blob/main/team_squad/team_squad.js): `team_squad/team_squad.js`
- [Transfers](https://github.com/waleedtarbosh/advanced-pre-work-prosports/blob/main/player_transfers/player_transfers.js): `player_transfers/player_transfers.js`
- [Trophies](https://github.com/waleedtarbosh/advanced-pre-work-prosports/blob/main/player_trophies/player_trophies.js): `player_trophies/player_trophies.js`

### Player leaderboards

- [Top scorers](https://github.com/waleedtarbosh/advanced-pre-work-prosports/blob/main/top_scorers/top_scorers.js): `top_scorers/top_scorers.js`
- [Top assists](https://github.com/waleedtarbosh/advanced-pre-work-prosports/blob/main/top_assists/top_assists.js): `top_assists/top_assists.js`
- [Top yellow cards](https://github.com/waleedtarbosh/advanced-pre-work-prosports/blob/main/top_yellow_cards/top_yellow_cards.js): `top_yellow_cards/top_yellow_cards.js`
- [Top red cards](https://github.com/waleedtarbosh/advanced-pre-work-prosports/blob/main/top_red_cards/top_red_cards.js): `top_red_cards/top_red_cards.js`

### Other components

- **Visitor**
- **API-Football**

## Connections

- Visitor → Homepage: opens (evidence: `README.md`)
- Homepage → Navigation UI: initializes (evidence: `main.js`)
- Visitor → Fixtures and results: searches (evidence: `README.md`)
- Visitor → League standings: searches (evidence: `README.md`)
- Visitor → Team information: searches (evidence: `README.md`)
- Visitor → Player injuries: searches (evidence: `README.md`)
- Visitor → Player statistics: searches (evidence: `README.md`)
- Visitor → Player details: views (evidence: `README.md`)
- Visitor → Player seasons: searches (evidence: `README.md`)
- Visitor → Team history: searches (evidence: `README.md`)
- Visitor → Team squads: searches (evidence: `README.md`)
- Visitor → Transfers: searches (evidence: `README.md`)
- Visitor → Trophies: searches (evidence: `README.md`)
- Visitor → Top scorers: searches (evidence: `README.md`)
- Visitor → Top assists: searches (evidence: `README.md`)
- Visitor → Top yellow cards: searches (evidence: `README.md`)
- Visitor → Top red cards: searches (evidence: `README.md`)
- Fixtures and results → API-Football: fetches fixtures (evidence: `README.md`)
- League standings → API-Football: fetches standings (evidence: `standings/standings.js`)
- Team information → API-Football: fetches teams (evidence: `teams/teams.js`)
- Player injuries → API-Football: fetches injuries (evidence: `injuries/injuries.js`)
- Player statistics → API-Football: fetches stats (evidence: `get_players/get_players.js`)
- Player details → API-Football: fetches details (evidence: `README.md`)
- Player seasons → API-Football: fetches seasons (evidence: `README.md`)
- Team history → API-Football: fetches history (evidence: `README.md`)
- Team squads → API-Football: fetches squads (evidence: `team_squad/team_squad.js`)
- Transfers → API-Football: fetches transfers (evidence: `player_transfers/player_transfers.js`)
- Trophies → API-Football: fetches trophies (evidence: `player_trophies/player_trophies.js`)
- Top scorers → API-Football: fetches leaders (evidence: `README.md`)
- Top assists → API-Football: fetches leaders (evidence: `top_assists/top_assists.js`)
- Top yellow cards → API-Football: fetches leaders (evidence: `top_yellow_cards/top_yellow_cards.js`)
- Top red cards → API-Football: fetches leaders (evidence: `top_red_cards/top_red_cards.js`)
