zostera / django-icons

Icons for Django
http://django-icons.readthedocs.io/en/latest/index.html
BSD 3-Clause "New" or "Revised" License
76 stars 11 forks source link

version 4.0.0 does not work #65

Closed catborise closed 3 years ago

catborise commented 3 years ago

Hi, we are using django-icons 3.0.0 without any problem but if we update it to 4.0.0 icons does not seen. documents do not contain any info with migrate. is there a major change?

thanks

requirements.txt
django-icons==4.0.0

settings.conf
INSTALLED_APPS = [
....
"bootstrap4",
"django_icons",
...
]

html page:
{% load icons %}
<a class="btn btn-sm btn-secondary disabled" title="{% trans "Suspend" %}">{% icon 'pause' %}</a>

in that example, icon empty.

dyve commented 3 years ago

Hi, thanks for reaching out. In the CHANGELOG:

Set IconRenderer as default renderer (#58).

Your pause icon would be rendered as FontAwesome4 <i class="fa fa-pause"></i> in 3.0.0.

In 4.0.0, it would render as just the pause class <i class="pause"></i>.

To fix this, you can set the FontAwesome4Renderer as default, and/or explicitly define icons in your settings. See https://django-icons.readthedocs.io/en/latest/settings.html