phase2: add modular apps, auth scaffolding, and base template routing

This commit is contained in:
Alfredo Di Stasio
2026-03-10 10:27:40 +01:00
parent 35686bdb66
commit f47ffe6c15
63 changed files with 594 additions and 24 deletions

39
templates/base.html Normal file
View File

@ -0,0 +1,39 @@
{% load static %}
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<title>{% block title %}HoopScout{% endblock %}</title>
<link rel="stylesheet" href="{% static 'css/main.css' %}">
<script src="https://unpkg.com/htmx.org@1.9.12" defer></script>
</head>
<body>
<header class="site-header">
<div class="container row-between">
<a class="brand" href="{% url 'core:home' %}">HoopScout</a>
<nav class="row-gap">
<a href="{% url 'players:index' %}">Players</a>
<a href="{% url 'competitions:index' %}">Competitions</a>
<a href="{% url 'teams:index' %}">Teams</a>
<a href="{% url 'scouting:index' %}">Scouting</a>
{% if request.user.is_authenticated %}
<a href="{% url 'core:dashboard' %}">Dashboard</a>
<form method="post" action="{% url 'users:logout' %}">
{% csrf_token %}
<button type="submit" class="link-button">Logout</button>
</form>
{% else %}
<a href="{% url 'users:login' %}">Login</a>
<a href="{% url 'users:signup' %}">Signup</a>
{% endif %}
</nav>
</div>
</header>
<main class="container">
{% include 'partials/messages.html' %}
{% block content %}{% endblock %}
</main>
</body>
</html>

View File

@ -0,0 +1,10 @@
{% extends "base.html" %}
{% block title %}HoopScout | Competitions{% endblock %}
{% block content %}
<section class="panel">
<h1>Competitions</h1>
<p>Competitions module scaffolding for upcoming phases.</p>
</section>
{% endblock %}

View File

@ -0,0 +1,11 @@
{% extends 'base.html' %}
{% block title %}HoopScout | Dashboard{% endblock %}
{% block content %}
<section class="panel">
<h1>Dashboard</h1>
<p>Welcome, {{ request.user.username }}.</p>
<p>This is the authenticated control center for saved searches and watchlists.</p>
</section>
{% endblock %}

18
templates/core/home.html Normal file
View File

@ -0,0 +1,18 @@
{% extends 'base.html' %}
{% block title %}HoopScout | Home{% endblock %}
{% block content %}
<section class="panel">
<h1>Basketball scouting, server-rendered.</h1>
<p>Search players and track targets using a Django + HTMX workflow.</p>
<div class="actions">
<a class="button" href="{% url 'players:index' %}">Browse players</a>
{% if request.user.is_authenticated %}
<a class="button ghost" href="{% url 'core:dashboard' %}">Go to dashboard</a>
{% else %}
<a class="button ghost" href="{% url 'users:signup' %}">Create account</a>
{% endif %}
</div>
</section>
{% endblock %}

View File

@ -0,0 +1,10 @@
{% extends "base.html" %}
{% block title %}HoopScout | Ingestion{% endblock %}
{% block content %}
<section class="panel">
<h1>Ingestion</h1>
<p>Ingestion module scaffolding for upcoming phases.</p>
</section>
{% endblock %}

View File

@ -0,0 +1,7 @@
{% if messages %}
<section class="messages">
{% for message in messages %}
<div class="message {{ message.tags }}">{{ message }}</div>
{% endfor %}
</section>
{% endif %}

View File

@ -0,0 +1,10 @@
{% extends "base.html" %}
{% block title %}HoopScout | Players{% endblock %}
{% block content %}
<section class="panel">
<h1>Players</h1>
<p>Players module scaffolding for upcoming phases.</p>
</section>
{% endblock %}

View File

@ -0,0 +1,10 @@
{% extends "base.html" %}
{% block title %}HoopScout | Providers{% endblock %}
{% block content %}
<section class="panel">
<h1>Providers</h1>
<p>Providers module scaffolding for upcoming phases.</p>
</section>
{% endblock %}

View File

@ -0,0 +1,10 @@
{% extends "base.html" %}
{% block title %}HoopScout | Scouting{% endblock %}
{% block content %}
<section class="panel">
<h1>Scouting</h1>
<p>Scouting module scaffolding for upcoming phases.</p>
</section>
{% endblock %}

View File

@ -0,0 +1,10 @@
{% extends "base.html" %}
{% block title %}HoopScout | Stats{% endblock %}
{% block content %}
<section class="panel">
<h1>Stats</h1>
<p>Stats module scaffolding for upcoming phases.</p>
</section>
{% endblock %}

View File

@ -0,0 +1,10 @@
{% extends "base.html" %}
{% block title %}HoopScout | Teams{% endblock %}
{% block content %}
<section class="panel">
<h1>Teams</h1>
<p>Teams module scaffolding for upcoming phases.</p>
</section>
{% endblock %}

View File

@ -0,0 +1,14 @@
{% extends 'base.html' %}
{% block title %}HoopScout | Login{% endblock %}
{% block content %}
<section class="panel narrow">
<h1>Login</h1>
<form method="post" class="stack">
{% csrf_token %}
{{ form.as_p }}
<button type="submit" class="button">Sign in</button>
</form>
</section>
{% endblock %}

View File

@ -0,0 +1,10 @@
{% extends 'base.html' %}
{% block title %}HoopScout | Profile{% endblock %}
{% block content %}
<section class="panel">
<h1>Profile</h1>
<p>Profile management scaffolding for future phases.</p>
</section>
{% endblock %}

View File

@ -0,0 +1,14 @@
{% extends 'base.html' %}
{% block title %}HoopScout | Signup{% endblock %}
{% block content %}
<section class="panel narrow">
<h1>Create account</h1>
<form method="post" class="stack">
{% csrf_token %}
{{ form.as_p }}
<button type="submit" class="button">Create account</button>
</form>
</section>
{% endblock %}