[static assets] finally bloddy django finds and serves pico.min.css
also includes a favicon because the browser kept asking for one
This commit is contained in:
parent
7028a03f5c
commit
2b7e478a40
5 changed files with 17 additions and 4 deletions
BIN
assets/favicon-32x32.png
Normal file
BIN
assets/favicon-32x32.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 1.3 KiB |
4
assets/pico.min.css
vendored
Normal file
4
assets/pico.min.css
vendored
Normal file
File diff suppressed because one or more lines are too long
|
|
@ -1,14 +1,19 @@
|
||||||
|
{% load static %}
|
||||||
<!DOCTYPE html>
|
<!DOCTYPE html>
|
||||||
<html lang="en">
|
<html lang="en">
|
||||||
<head>
|
<head>
|
||||||
<meta charset="UTF-8">
|
<meta charset="UTF-8">
|
||||||
<meta name="viewport" content="width=device-width, initial-scale=1">
|
<meta name="viewport" content="width=device-width, initial-scale=1">
|
||||||
|
<meta name="color-scheme" content="light dark">
|
||||||
|
<link href="{% static 'pico.min.css' %}" rel="stylesheet">
|
||||||
|
<link rel="icon" type="image/png" href="{% static 'favicon-32x32.png' %}">
|
||||||
<title>Teilchensammler</title>
|
<title>Teilchensammler</title>
|
||||||
<!-- <link href="css/style.css" rel="stylesheet"> -->
|
|
||||||
</head>
|
</head>
|
||||||
<body>
|
<body>
|
||||||
|
<main class="container">
|
||||||
{% block content %}
|
{% block content %}
|
||||||
|
|
||||||
{% endblock content %}
|
{% endblock content %}
|
||||||
|
</main>
|
||||||
</body>
|
</body>
|
||||||
</html>
|
</html>
|
||||||
|
|
|
||||||
|
|
@ -105,6 +105,9 @@ USE_TZ = True
|
||||||
# Static files (CSS, JavaScript, Images)
|
# Static files (CSS, JavaScript, Images)
|
||||||
# https://docs.djangoproject.com/en/5.1/howto/static-files/
|
# https://docs.djangoproject.com/en/5.1/howto/static-files/
|
||||||
STATIC_URL = "static/"
|
STATIC_URL = "static/"
|
||||||
|
STATIC_ROOT = BASE_DIR / "static"
|
||||||
|
STATICFILES_DIRS = [BASE_DIR / "assets"]
|
||||||
|
|
||||||
|
|
||||||
# Default primary key field type
|
# Default primary key field type
|
||||||
# https://docs.djangoproject.com/en/5.1/ref/settings/#default-auto-field
|
# https://docs.djangoproject.com/en/5.1/ref/settings/#default-auto-field
|
||||||
|
|
|
||||||
|
|
@ -16,13 +16,14 @@ Including another URLconf
|
||||||
"""
|
"""
|
||||||
|
|
||||||
from django.conf import settings
|
from django.conf import settings
|
||||||
|
from django.conf.urls.static import static
|
||||||
from django.contrib import admin
|
from django.contrib import admin
|
||||||
from django.urls import include, path
|
from django.urls import include, path
|
||||||
|
|
||||||
urlpatterns = [
|
urlpatterns = [
|
||||||
path("", include("collector.urls")),
|
path("", include("collector.urls")),
|
||||||
path("admin/", admin.site.urls),
|
path("admin/", admin.site.urls),
|
||||||
]
|
] + static(settings.STATIC_URL, document_root=settings.STATIC_ROOT)
|
||||||
|
|
||||||
if settings.DEBUG:
|
if settings.DEBUG:
|
||||||
from debug_toolbar.toolbar import debug_toolbar_urls
|
from debug_toolbar.toolbar import debug_toolbar_urls
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue