Skip to content

Commit 5b76633

Browse files
committed
Basic homepage and footer
1 parent e11f917 commit 5b76633

File tree

4 files changed

+43
-1
lines changed

4 files changed

+43
-1
lines changed

pypi_browser/static/favicon.png

1.55 KB
Loading

pypi_browser/templates/_base.html

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@
33
<head>
44
<meta charset="utf-8" />
55
<meta name="viewport" content="width=device-width, initial-scale=1" />
6+
<link rel="icon" href="{{url_for('static', path='/favicon.png')}}" />
67
<link rel="stylesheet" href="{{url_for('static', path='/bootstrap-5.2.1.min.css')}}" />
78
<link rel="stylesheet" href="{{url_for('static', path='/site.css')}}" />
89
<title>{% block title %}{% endblock %}</title>
@@ -30,6 +31,18 @@
3031
{% block content %}{% endblock %}
3132
</div>
3233

34+
<div class="container mt-5 mb-3">
35+
<footer class="border-top py-3 px-3">
36+
<p class="text-muted small">
37+
PyPI Browser is an open source project.
38+
<br />
39+
<a href="{{url_for('package', package='pypibrowser')}}">View its files with PyPI Browser</a>
40+
<br />
41+
<a href="https://github.com/chriskuehl/pypi-browser">View it on GitHub</a>
42+
</p>
43+
</footer>
44+
</div>
45+
3346
<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.6.1/jquery.min.js"></script>
3447
<script src="{{url_for('static', path='/bootstrap-5.2.1.min.js')}}"></script>
3548
<script src="{{url_for('static', path='/site.js')}}"></script>

pypi_browser/templates/home.html

Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,5 +3,34 @@
33

44
{% block title %}PyPI Browser{% endblock %}
55

6+
{% block content %}
7+
<div class="px-4 py-4 my-4 mx-5">
8+
<div class="card">
9+
<div class="card-body text-center py-5 px-5">
10+
<h4 class="mb-4">Enter a Python project name to browse its files:</h4>
11+
<form method="GET" action="{{url_for('search')}}">
12+
<div class="row px-5 mb-4">
13+
<div class="col">
14+
<input type="text" name="package" class="form-control form-control-lg" />
15+
</div>
16+
<div class="col-auto">
17+
<button type="submit" class="btn btn-lg btn-primary">Browse Package</button>
18+
</div>
19+
</div>
20+
</form>
21+
22+
<h6>Or try it out with one of these popular packages:</h6>
23+
<p class="mb-0">
24+
<a href="{{url_for('package', package='django')}}">django</a>
25+
&bull;
26+
<a href="{{url_for('package', package='numpy')}}">numpy</a>
27+
&bull;
28+
<a href="{{url_for('package', package='requests')}}">requests</a>
29+
</p>
30+
</div>
31+
</div>
32+
</div>
33+
{% endblock %}
34+
635
{# vim: ft=jinja
736
#}

pyproject.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
[tool.poetry]
2-
name = "pypi-browser"
2+
name = "pypibrowser"
33
version = "0.0.0"
44
description = "PyPI package browsing web application"
55
authors = ["Chris Kuehl <[email protected]>"]

0 commit comments

Comments
 (0)