diff --git a/authentik/core/templates/base/skeleton.html b/authentik/core/templates/base/skeleton.html index ae41d82ea..4c47e0476 100644 --- a/authentik/core/templates/base/skeleton.html +++ b/authentik/core/templates/base/skeleton.html @@ -14,6 +14,7 @@ + {% block head %} {% endblock %} diff --git a/authentik/providers/proxy/api.py b/authentik/providers/proxy/api.py index 4e3090c81..1fc0a56f2 100644 --- a/authentik/providers/proxy/api.py +++ b/authentik/providers/proxy/api.py @@ -1,7 +1,7 @@ """ProxyProvider API Views""" from drf_yasg.utils import swagger_serializer_method from rest_framework.fields import CharField, ListField, SerializerMethodField -from rest_framework.serializers import ModelSerializer, Serializer +from rest_framework.serializers import ModelSerializer from rest_framework.viewsets import ModelViewSet from authentik.core.api.providers import ProviderSerializer diff --git a/web/rollup.config.js b/web/rollup.config.js index 2a0f7fae2..3517791e9 100644 --- a/web/rollup.config.js +++ b/web/rollup.config.js @@ -26,10 +26,6 @@ const resources = [ const isProdBuild = process.env.NODE_ENV === "production"; // eslint-disable-next-line @typescript-eslint/explicit-module-boundary-types function manualChunks(id) { - if (id.includes("construct-style-sheets-polyfill")) { - // Keep polyfills in the main file so they are loaded when dependencies are loaded - return "vendor-poly"; - } if (id.includes("node_modules")) { if (id.includes("codemirror")) { return "vendor-cm"; @@ -64,6 +60,33 @@ export default [ clearScreen: false, }, }, + // Polyfills (imported first) + { + input: [ + "construct-style-sheets-polyfill" + ], + output: [ + { + format: "es", + dir: "dist", + sourcemap: true, + } + ], + plugins: [ + cssimport(), + typescript(), + externalGlobals({ + django: "django", + }), + resolve({ browser: true }), + commonjs(), + sourcemaps(), + isProdBuild && terser(), + ].filter(p => p), + watch: { + clearScreen: false, + }, + }, // Main Application { input: "./src/interfaces/AdminInterface.ts", diff --git a/web/src/interfaces/AdminInterface.ts b/web/src/interfaces/AdminInterface.ts index 16ebea9e5..9badde036 100644 --- a/web/src/interfaces/AdminInterface.ts +++ b/web/src/interfaces/AdminInterface.ts @@ -1,5 +1,3 @@ -import "construct-style-sheets-polyfill"; - import "../elements/messages/MessageContainer"; import { customElement } from "lit-element"; import { me } from "../api/Users"; diff --git a/web/src/interfaces/admin/index.html b/web/src/interfaces/admin/index.html index dcaad682b..37e6199e4 100644 --- a/web/src/interfaces/admin/index.html +++ b/web/src/interfaces/admin/index.html @@ -8,6 +8,7 @@ + authentik diff --git a/web/src/interfaces/flow/index.html b/web/src/interfaces/flow/index.html index ceec0869c..395b8867b 100644 --- a/web/src/interfaces/flow/index.html +++ b/web/src/interfaces/flow/index.html @@ -8,6 +8,7 @@ + authentik