An application providing some template-tags to add buttons on pages
Project description
django-buttons
This application provides some simple template tags to insert buttons into templates.
Installation
Install application with pypi:
$ pip install django-buttons[fa5] # Installs django-fontawesome5
$ pip install django-buttons[fa6] # Installs django-fontawesome6
Add application to your INSTALLED_APPS:
INSTALLED_APPS = [
...
'buttons',
...
]
BUTTONS_FONTAWESOME_VERSION = 4 # Use 5 to use fontawesome-5 as icon library
Use buttons in your templates
{% load buttons_tags %}
...
{% btn_home %}
Buttons can have some parameters :
- url: target url
- title: displayed text
- icon: fa aware name, ie. 'home' for fa-home
- icon_position: Position of the icon, 'right', 'left' or 'none' (no icon displayed) ...
Enjoy !
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
django_buttons-1.0.4.tar.gz
(20.7 kB
view details)
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters