A Django wrapper for the Bootstrap Select library
Project description
A Django wrapper for the Bootstrap Select library
Documentation
The full documentation is at https://django-bootstrap-select.readthedocs.io.
Quickstart
Install Django Bootstrap Select:
pip install django-bootstrap-select
Add it to your INSTALLED_APPS:
INSTALLED_APPS = (
...
'bootstrap_select.apps.BootstrapSelectConfig',
...
)
Using it in a form:
def get_choices():
choices = (('face.jpg', escape('<img src="path-to-face.jpg"/>'),)
return choices
class IconForm(forms.Form):
icon = forms.URLField(widget=BootstrapSelect(choices=get_choices()))
Features
Renders labels from form choices as custom-content.
Running Tests
Does the code actually work?
source <YOURVIRTUALENV>/bin/activate (myenv) $ pip install tox (myenv) $ tox
Credits
Tools used in rendering this package:
History
0.1.0 (2017-08-20)
First release on PyPI.
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
Built Distribution
Close
Hashes for django-bootstrap-select-0.1.1.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | 5420b4bfd66aa574afab59a1d51e75e7d6dc2135dae4293042530bc54885f100 |
|
MD5 | 4728e7e48fb2b1c4b3a60fcce3c39d22 |
|
BLAKE2b-256 | 5f805e4fae8c63039ab9f77c5e522f43ced6ceacdd8185bfafa5c941815cb748 |
Close
Hashes for django_bootstrap_select-0.1.1-py2.py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | bd864fa763f3c2c582a071cbf5ca4ba07fd7025704dbd52a6798fb8e202ec9b0 |
|
MD5 | 87ffe5f5c24a40c670e1fb0d148a25b6 |
|
BLAKE2b-256 | 283b37e70dca0ed664484ecba2f82680c127c8c3178cdc4f8063f05553bcd892 |