This commit is contained in:
Jake Howard 2022-09-01 08:36:39 +01:00
parent 5d370a0712
commit 54af457d8e
Signed by: jake
GPG key ID: 57AFB45680EDD477
7 changed files with 21 additions and 16 deletions

View file

@ -21,6 +21,7 @@ drf-yasg
django-plausible django-plausible
sentry-sdk sentry-sdk
wagtail-favicon wagtail-favicon
django-sri
# Pinned due to lack of Wagtail 3 support # Pinned due to lack of Wagtail 3 support
git+https://github.com/wagtail/wagtail-autocomplete@03f46a0c256989690d0a43fc21fe0f37f9ede765 git+https://github.com/wagtail/wagtail-autocomplete@03f46a0c256989690d0a43fc21fe0f37f9ede765

View file

@ -15,7 +15,7 @@ click==8.1.3 # via rq
coreapi==2.3.3 # via drf-yasg coreapi==2.3.3 # via drf-yasg
coreschema==0.0.4 # via coreapi, drf-yasg coreschema==0.0.4 # via coreapi, drf-yasg
deprecated==1.2.13 # via redis deprecated==1.2.13 # via redis
django==4.0.6 # via -r requirements/base.in, django-filter, django-htmx, django-modelcluster, django-permissionedforms, django-plausible, django-redis, django-rq, django-taggit, django-treebeard, djangorestframework, drf-yasg, wagtail django==4.0.6 # via -r requirements/base.in, django-filter, django-htmx, django-modelcluster, django-permissionedforms, django-plausible, django-redis, django-rq, django-sri, django-taggit, django-treebeard, djangorestframework, drf-yasg, wagtail
django-environ==0.9.0 # via -r requirements/base.in django-environ==0.9.0 # via -r requirements/base.in
django-filter==21.1 # via wagtail django-filter==21.1 # via wagtail
django-htmx==1.12.1 # via -r requirements/base.in django-htmx==1.12.1 # via -r requirements/base.in
@ -24,6 +24,7 @@ django-permissionedforms==0.1 # via wagtail
django-plausible==0.3.0 # via -r requirements/base.in django-plausible==0.3.0 # via -r requirements/base.in
django-redis==5.2.0 # via -r requirements/base.in django-redis==5.2.0 # via -r requirements/base.in
django-rq==2.5.1 # via -r requirements/base.in django-rq==2.5.1 # via -r requirements/base.in
django-sri==0.4.0 # via -r requirements/base.in
django-taggit==2.1.0 # via wagtail django-taggit==2.1.0 # via wagtail
django-treebeard==4.5.1 # via wagtail django-treebeard==4.5.1 # via wagtail
djangorestframework==3.13.1 # via -r requirements/base.in, drf-yasg, wagtail djangorestframework==3.13.1 # via -r requirements/base.in, drf-yasg, wagtail

View file

@ -20,7 +20,7 @@ coreschema==0.0.4 # via -r requirements/base.txt, coreapi, drf-yasg
coverage==6.4.4 # via -r requirements/dev.in coverage==6.4.4 # via -r requirements/dev.in
curlylint==0.13.1 # via -r requirements/dev.in curlylint==0.13.1 # via -r requirements/dev.in
deprecated==1.2.13 # via -r requirements/base.txt, redis deprecated==1.2.13 # via -r requirements/base.txt, redis
django==4.0.6 # via -r requirements/base.txt, django-browser-reload, django-debug-toolbar, django-filter, django-htmx, django-modelcluster, django-permissionedforms, django-plausible, django-redis, django-rq, django-taggit, django-treebeard, djangorestframework, drf-yasg, wagtail django==4.0.6 # via -r requirements/base.txt, django-browser-reload, django-debug-toolbar, django-filter, django-htmx, django-modelcluster, django-permissionedforms, django-plausible, django-redis, django-rq, django-sri, django-taggit, django-treebeard, djangorestframework, drf-yasg, wagtail
django-browser-reload==1.6.0 # via -r requirements/dev.in django-browser-reload==1.6.0 # via -r requirements/dev.in
django-debug-toolbar==3.5.0 # via -r requirements/dev.in django-debug-toolbar==3.5.0 # via -r requirements/dev.in
django-environ==0.9.0 # via -r requirements/base.txt django-environ==0.9.0 # via -r requirements/base.txt
@ -31,6 +31,7 @@ django-permissionedforms==0.1 # via -r requirements/base.txt, wagtail
django-plausible==0.3.0 # via -r requirements/base.txt django-plausible==0.3.0 # via -r requirements/base.txt
django-redis==5.2.0 # via -r requirements/base.txt django-redis==5.2.0 # via -r requirements/base.txt
django-rq==2.5.1 # via -r requirements/base.txt django-rq==2.5.1 # via -r requirements/base.txt
django-sri==0.4.0 # via -r requirements/base.txt
django-taggit==2.1.0 # via -r requirements/base.txt, wagtail django-taggit==2.1.0 # via -r requirements/base.txt, wagtail
django-treebeard==4.5.1 # via -r requirements/base.txt, wagtail django-treebeard==4.5.1 # via -r requirements/base.txt, wagtail
djangorestframework==3.13.1 # via -r requirements/base.txt, drf-yasg, wagtail djangorestframework==3.13.1 # via -r requirements/base.txt, drf-yasg, wagtail

View file

@ -1,4 +1,4 @@
{% load static wagtailcore_tags wagtailuserbar navbar_tags footer_tags cache plausible_wagtail favicon_tags %} {% load static wagtailcore_tags wagtailuserbar navbar_tags footer_tags cache plausible_wagtail favicon_tags sri %}
<!DOCTYPE html> <!DOCTYPE html>
<html lang="en-GB"> <html lang="en-GB">
@ -23,9 +23,9 @@
{% block extra_head %}{% endblock %} {% block extra_head %}{% endblock %}
<link rel="stylesheet" type="text/css" href="{% static 'css/base.css' %}"> {% sri_static "css/base.css" %}
<link rel="stylesheet" type="text/css" href="{% static 'contrib/fontawesome/css/all.min.css' %}"> {% sri_static "contrib/fontawesome/css/all.min.css" %}
<link rel="stylesheet" type="text/css" href="{% static 'contrib/fira-code/fira_code.css' %}"> {% sri_static "contrib/fira-code/fira_code.css" %}
{% block extra_css %}{% endblock %} {% block extra_css %}{% endblock %}
</head> </head>
@ -47,11 +47,11 @@
{% footer %} {% footer %}
{% endcache %} {% endcache %}
<script async defer type="text/javascript" src="{% static 'js/base.js' %}"></script> <script async defer type="text/javascript" src="{% static 'js/base.js' %}" integrity="{% sri_integrity_static 'js/base.js' %}"></script>
<script async defer type="text/javascript" src="{% static 'contrib/htmx/htmx.min.js' %}"></script> <script async defer type="text/javascript" src="{% static 'contrib/htmx/htmx.min.js' %}" integrity="{% sri_integrity_static 'contrib/htmx/htmx.min.js' %}"></script>
{# Not async to avoid bright flashes #} {# Not async to avoid bright flashes #}
<script type="text/javascript" src="{% static 'js/dark-mode.js' %}"></script> <script type="text/javascript" src="{% static 'js/dark-mode.js' %}" integrity="{% sri_integrity_static 'js/dark-mode.js' %}"></script>
{% block extra_js %}{% endblock %} {% block extra_js %}{% endblock %}

View file

@ -1,6 +1,6 @@
{% extends "wagtail_base.html" %} {% extends "wagtail_base.html" %}
{% load static %} {% load static sri %}
{% block content %} {% block content %}
{% if page.body_html %} {% if page.body_html %}
@ -11,12 +11,13 @@
{% endblock %} {% endblock %}
{% block extra_css %} {% block extra_css %}
<link rel="stylesheet" type="text/css" href="{% static 'css/lite-youtube-embed.css' %}"> {% sri_static "css/lite-youtube-embed.css" %}
<link rel="stylesheet" type="text/css" href="{% static 'contrib/shareon/shareon.min.css' %}"> {% sri_static "contrib/shareon/shareon.min.css" %}
<link rel="stylesheet" type="text/css" href="{% url 'code-block:styles' %}"> <link rel="stylesheet" type="text/css" href="{% url 'code-block:styles' %}">
{% endblock %} {% endblock %}
{% block extra_js %} {% block extra_js %}
<script async defer type="text/javascript" src="{% static 'js/lite-youtube-embed.js' %}"></script> <script async defer type="text/javascript" src="{% static 'js/lite-youtube-embed.js' %}" integrity="{% sri_integrity_static 'js/lite-youtube-embed.js' %}"></script>
<script async defer type="text/javascript" src="{% static 'contrib/shareon/shareon.iife.js' %}" init></script> <script async defer type="text/javascript" src="{% static 'contrib/shareon/shareon.iife.js' %}" integrity="{% sri_integrity_static 'contrib/shareon/shareon.iife.js' %}" init></script>
{% endblock %} {% endblock %}

View file

@ -1,6 +1,6 @@
{% extends "common/content_page.html" %} {% extends "common/content_page.html" %}
{% load static %} {% load static sri %}
{% block post_content %} {% block post_content %}
<section class="container search-controls"> <section class="container search-controls">
@ -41,5 +41,5 @@
{% block extra_js %} {% block extra_js %}
{{ block.super }} {{ block.super }}
<script async defer type="text/javascript" src="{% static 'js/search.js' %}"></script> <script async defer type="text/javascript" src="{% static 'js/search.js' %}" integrity="{% sri_integrity_static 'js/search.js' %}"></script>
{% endblock %} {% endblock %}

View file

@ -68,6 +68,7 @@ INSTALLED_APPS = [
"wagtail_favicon", "wagtail_favicon",
"plausible", "plausible",
"plausible.contrib.wagtail", "plausible.contrib.wagtail",
"sri",
"django.contrib.auth", "django.contrib.auth",
"django.contrib.contenttypes", "django.contrib.contenttypes",
"django.contrib.sessions", "django.contrib.sessions",