# josephmerza/gin446-jm- architecture

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

- Interactive diagram: https://gitdiagram.com/josephmerza/gin446-jm-
- Repository: https://github.com/josephmerza/gin446-jm-

## Overview

This is a small Flask portfolio site that serves a home page, history pages, a student-profile form, and a JavaScript quiz. The main workflow is a visitor requesting a page; Flask routes either render a template or, for profile submissions, pass submitted fields into the profile view. The quiz’s question navigation, answer tracking, scoring, and results are client-side. The quiz template and other templates were not excerpted, so links from them to browser assets are not asserted.

Main entry points: [`app.py`](https://github.com/josephmerza/gin446-jm-/blob/main/app.py) (Flask routes), [`static/quiz.js`](https://github.com/josephmerza/gin446-jm-/blob/main/static/quiz.js) (Quiz engine), [`templates/index.html`](https://github.com/josephmerza/gin446-jm-/blob/main/templates/index.html) (Portfolio home), [`templates`](https://github.com/josephmerza/gin446-jm-/tree/main/templates) (History pages)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_routing["Flask routing"]
  node_flask["Flask routes<br/>[app.py]"]
end

subgraph group_pages["Portfolio pages"]
  node_home["Portfolio home<br/>[index.html]"]
  node_history["History pages"]
  node_profile_form["Profile form<br/>[profile-form.html]"]
  node_profile["Profile view<br/>[profile.html]"]
end

subgraph group_quiz["Quiz experience"]
  node_quiz_page["Quiz page<br/>[quiz.html]"]
  node_quiz_engine["Quiz engine<br/>[quiz.js]"]
  node_question_nav["Question navigation<br/>[quiz.js]"]
  node_answer_state["Answer tracking<br/>[quiz.js]"]
  node_scoring["Scoring and feedback<br/>[quiz.js]"]
  node_results["Quiz results<br/>[quiz.js]"]
end

node_visitor(("Site visitor"))

node_visitor -->|"requests pages"| node_flask
node_flask -->|"renders"| node_home
node_flask -->|"renders"| node_history
node_flask -->|"renders on GET"| node_profile_form
node_flask -->|"renders on POST"| node_profile
node_flask -->|"renders"| node_quiz_page
node_quiz_engine -->|"defines"| node_question_nav
node_quiz_engine -->|"stores answers"| node_answer_state
node_quiz_engine -->|"calculates results"| node_scoring
node_quiz_engine -->|"displays results"| node_results
node_question_nav -->|"saves selections"| node_answer_state
node_scoring -->|"passes feedback"| node_results

click node_flask "https://github.com/josephmerza/gin446-jm-/blob/main/app.py"
click node_home "https://github.com/josephmerza/gin446-jm-/blob/main/templates/index.html"
click node_history "https://github.com/josephmerza/gin446-jm-/tree/main/templates"
click node_profile_form "https://github.com/josephmerza/gin446-jm-/blob/main/templates/profile-form.html"
click node_profile "https://github.com/josephmerza/gin446-jm-/blob/main/templates/profile.html"
click node_quiz_page "https://github.com/josephmerza/gin446-jm-/blob/main/templates/quiz.html"
click node_quiz_engine "https://github.com/josephmerza/gin446-jm-/blob/main/static/quiz.js"
click node_question_nav "https://github.com/josephmerza/gin446-jm-/blob/main/static/quiz.js"
click node_answer_state "https://github.com/josephmerza/gin446-jm-/blob/main/static/quiz.js"
click node_scoring "https://github.com/josephmerza/gin446-jm-/blob/main/static/quiz.js"
click node_results "https://github.com/josephmerza/gin446-jm-/blob/main/static/quiz.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_flask toneBlue
class node_home,node_history,node_profile_form,node_profile toneAmber
class node_quiz_page,node_quiz_engine,node_question_nav,node_answer_state,node_scoring,node_results toneMint
class node_visitor toneIndigo
```

## Components

### Flask routing

- [Flask routes](https://github.com/josephmerza/gin446-jm-/blob/main/app.py): `app.py`

### Portfolio pages

- [Portfolio home](https://github.com/josephmerza/gin446-jm-/blob/main/templates/index.html): `templates/index.html`
- [History pages](https://github.com/josephmerza/gin446-jm-/tree/main/templates): `templates`
- [Profile form](https://github.com/josephmerza/gin446-jm-/blob/main/templates/profile-form.html): `templates/profile-form.html`
- [Profile view](https://github.com/josephmerza/gin446-jm-/blob/main/templates/profile.html): `templates/profile.html`

### Quiz experience

- [Quiz page](https://github.com/josephmerza/gin446-jm-/blob/main/templates/quiz.html): `templates/quiz.html`
- [Quiz engine](https://github.com/josephmerza/gin446-jm-/blob/main/static/quiz.js): `static/quiz.js`
- [Question navigation](https://github.com/josephmerza/gin446-jm-/blob/main/static/quiz.js): `static/quiz.js`
- [Answer tracking](https://github.com/josephmerza/gin446-jm-/blob/main/static/quiz.js): `static/quiz.js`
- [Scoring and feedback](https://github.com/josephmerza/gin446-jm-/blob/main/static/quiz.js): `static/quiz.js`
- [Quiz results](https://github.com/josephmerza/gin446-jm-/blob/main/static/quiz.js): `static/quiz.js`

### Other components

- **Site visitor**

## Connections

- Site visitor → Flask routes: requests pages (evidence: `app.py`)
- Flask routes → Portfolio home: renders (evidence: `app.py`)
- Flask routes → History pages: renders (evidence: `app.py`)
- Flask routes → Profile form: renders on GET (evidence: `app.py`)
- Flask routes → Profile view: renders on POST (evidence: `app.py`)
- Flask routes → Quiz page: renders (evidence: `app.py`)
- Quiz engine → Question navigation: defines (evidence: `static/quiz.js`)
- Quiz engine → Answer tracking: stores answers (evidence: `static/quiz.js`)
- Quiz engine → Scoring and feedback: calculates results (evidence: `static/quiz.js`)
- Quiz engine → Quiz results: displays results (evidence: `static/quiz.js`)
- Question navigation → Answer tracking: saves selections (evidence: `static/quiz.js`)
- Scoring and feedback → Quiz results: passes feedback (evidence: `static/quiz.js`)
