Skip to main content

Wagtail Extra Icons

Add extra icons to your Wagtail project.

Versions

Version 3.X.X

Is for use with Wagtail versions 3.0 and above. This uses Wagtail's updated module paths from version 3.0.

Version 2.X.X

Is for use with Wagtail versions 2.15 and above. This version uses wagtail's new Svg icon system.

This version works with Wagtail versions 3.0 and 4.*, but is deprecated for those.

Version 1.X.X

Is for use with Wagtail versions below 2.15. This version uses wagtail's old Icon font system.


Install

pip install wagtailextraicons

Then add wagtailextraicons to your installed apps:

INSTALLED_APPS = [
    ...
    'wagtailextraicons'
]

Usage

The full list of icons is available at docs/icons.md. All icons are namespaced as extraicons-- to avoid clashing with existing Wagtail icons. You can add the extra icons to your StreamField blocks like any other:

content = StreamField(
    [
        ('paragraph', blocks.RichTextBlock(icon='extraicons--paragraph')),
    ],
    use_json_field=True,    
)

You can also add the extra icons to your own custom StructBlock classes:

class PersonBlock(blocks.StructBlock):
    person = SnippetChooserBlock('app.Person')
    text = blocks.RichTextBlock()

    class Meta:
        icon = 'extraicons--person'

Reference the Wagtail docs for all the ways to include icons.

Authors

Contributing

The icon fonts are compiled from the list of SVG files in static_src/wagtailextraicons/extraicons. This makes it very easy to add new icons. All that's needed is an appropriate SVG file, so pull requests with new icons are always welcome. There are a few constraints on the icons however:

  • The icons must fit within their view box. Icons which don't will cause the fonts view box to have negative values, which results in invalid .ttf and .woff files.
  • Try to avoid using strokes, rects, etc. in your SVG. Some of these may work, but plain paths will always work, so prefer paths where possible.
  • Don't set colours on your SVG.

Code pull requests are also welcome.

License

This project is licensed under the BSD License - see the LICENSE.txt file for details.

Release files for wagtailextraicons 3.0.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for wagtailextraicons 3.0.0
File Size Uploaded
wagtailextraicons-3.0.0.tar.gz 14.3 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for wagtailextraicons 3.0.0
File Interpreter ABI Platform
wagtailextraicons-3.0.0-py3-none-any.whl Python 3 none any Details

Total release size: 43.5 kB

Release files / wagtailextraicons-3.0.0.tar.gz

Download URL wagtailextraicons-3.0.0.tar.gz
Size 14.3 kB
Tags Source
SHA-256 checksum
How to use checksums
3f6754afd9a3cb29b973b5df8cb8503a8589d13225aa41cac1fb1510e07ebc50
BLAKE2b-256 checksum
How to use checksums
60052990826353ce2bb8236df0f789411bb32ff9cd017b7ab8270acb91686249
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.2 CPython/3.10.12

Release files / wagtailextraicons-3.0.0-py3-none-any.whl

Download URL wagtailextraicons-3.0.0-py3-none-any.whl
Size 29.1 kB
Tags Python 3
SHA-256 checksum
How to use checksums
12a7d622d0f04fd63c7f7941840ff3ad237f926f1f559abb007e8892b2ef881e
BLAKE2b-256 checksum
How to use checksums
728b568a0b1809f5c29b313792325f6f3458a276df90d26ef8c91dff8bdc13e7
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.2 CPython/3.10.12

Release history Release notifications | RSS feed

This release

3.0.0 This release

2 release files

2.0.0

2 release files

1.0.0

2 release files

0.1.7

2 release files

0.1.6

2 release files

0.1.5

2 release files

0.1.4

2 release files

0.1.3

2 release files

0.1.2

2 release files

0.1.1

1 release file

0.1.0

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page