diff --git a/allianceauth/framework/templates/framework/svg/sprite.svg b/allianceauth/framework/templates/framework/svg/sprite.svg new file mode 100644 index 00000000..f9ab2f65 --- /dev/null +++ b/allianceauth/framework/templates/framework/svg/sprite.svg @@ -0,0 +1,23 @@ + + + + + + + + + + + + + + + + + + diff --git a/allianceauth/static/allianceauth/images/auth-logo.png b/allianceauth/static/allianceauth/images/auth-logo.png deleted file mode 100644 index b45de9c8..00000000 Binary files a/allianceauth/static/allianceauth/images/auth-logo.png and /dev/null differ diff --git a/allianceauth/static/allianceauth/images/auth-logo.svg b/allianceauth/static/allianceauth/images/auth-logo.svg deleted file mode 100644 index 9d0c92e2..00000000 --- a/allianceauth/static/allianceauth/images/auth-logo.svg +++ /dev/null @@ -1,56 +0,0 @@ - - - - - - - - - - - - - diff --git a/allianceauth/templates/allianceauth/base-bs5.html b/allianceauth/templates/allianceauth/base-bs5.html index d96049f1..6066ce5e 100644 --- a/allianceauth/templates/allianceauth/base-bs5.html +++ b/allianceauth/templates/allianceauth/base-bs5.html @@ -159,5 +159,7 @@ {% block extra_script %} {% endblock extra_script %} + + {% include "framework/svg/sprite.svg" %} diff --git a/allianceauth/templates/bundles/image-auth-logo.html b/allianceauth/templates/bundles/image-auth-logo.html index 47281028..be25d833 100644 --- a/allianceauth/templates/bundles/image-auth-logo.html +++ b/allianceauth/templates/bundles/image-auth-logo.html @@ -1,3 +1,3 @@ -{% load static %} - -{{ SITE_NAME }} + diff --git a/docs/development/custom/aa-framework.md b/docs/development/custom/aa-framework.md index 12084d2b..92e55de7 100644 --- a/docs/development/custom/aa-framework.md +++ b/docs/development/custom/aa-framework.md @@ -14,4 +14,5 @@ The Alliance Auth framework is split into several submodules, each of which is d framework/api framework/css framework/templates +framework/svg-sprite ::: diff --git a/docs/development/custom/framework/svg-sprite.md b/docs/development/custom/framework/svg-sprite.md new file mode 100644 index 00000000..81ca95fa --- /dev/null +++ b/docs/development/custom/framework/svg-sprite.md @@ -0,0 +1,50 @@ +# SVG Sprite + +An SVG sprite is a collection of SVG images combined into a single SVG file. This allows for efficient loading and management of icons in web applications. + +The Alliance Auth framework provides a built-in SVG sprite that contains a selection of icons used in Alliance Auth. This sprite is automatically included in the base template, so you don't need to do anything special to use it. + +## Using the SVG Sprite + +To use an icon from the SVG sprite, you can use the following HTML syntax: + +```html + + + +``` + +Replace `[icon-name]` with the name of the icon you want to use. For example, to use the Alliance Auth logo, you would write: + +```html + + + +``` + +## Available Icons + +The following icons are available in the Alliance Auth SVG sprite: + +- `aa-logo`: The Alliance Auth logo +- `aa-loading-spinner`: A loading spinner icon + +### Alliance Auth Logo + +The Alliance Auth logo can be used with the following code: + +```html + + + +``` + +### Loading Spinner + +The loading spinner can be used with the following code: + +```html + + + +```