django-fontawesome
django-fontawesome copied to clipboard
Make the plugin font icon agnostic
The purpose of this pull request is to make the plugin font icon agnostic, which tenfold its usefulness :) Also people could create their own collection of icons if needed
I'm not sure it's enough but I wanted to see if you would be interested in it. The idea is that we could use other fonts ( and even custom ones ) instead of FA.
Mostly the function to fetch the icons is now a settings ( or yours if none ).
FONTAWESOME_CSS_URL = '/static/scss/icon-font.css' # relative url
FONTAWESOME_ICON_CHOICE = "path.to.function" # Should return a tuple [('icon-teacher', 'Teacher')]
FONTAWESOME_PREFIX = 'icon ' # default is 'fa'
FONTAWESOME_PREFIX_ICON = '' # default is 'fa-'
Below is an exemple of what those 3 settings produce