Utilities for https://github.com/anutron/behavior integration with django.
This app provides template filters that can alter data attributes of the form fields required for behavior. It also have a ‘behavior’ and ‘behavior-more’ libraries bundled for use with django.contrib.staticfiles.
The license is MIT.
Installation
pip install django-mootools-behavior
Configuration
Add ‘mootools_behavior’ to INSTALLED_APPS;
(optional) run python manage.py collectstatic in order to get ‘behavior’ javascript files;
include the necessary js into html and use provided template filters in order to set attributes for form elements.
Filters
behave
Sets ‘data-behavior-…’ attribute to a form field:
{% load mootools_behavior %}
<!-- data-behavior:"OverText" will be added to input field -->
{{ form.title|behave:"OverText" }}
set_data
Sets HTML5 data attribute ( http://ejohn.org/blog/html-5-data-attributes/ ).
Example:
{% load mootools_behavior %}
<!-- data-behavior:"OverText" will be added to input field -->
{{ form.title|set_data:"behavior:OverText" }}
Contributing
If you’ve found a bug, implemented a feature or have a suggestion, do not hesitate to contact me, fire an issue or send a pull request.
Source code:
Report bugs:
Metadata
Release files for django-mootools-behavior 0.1.1
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| django-mootools-behavior-0.1.1.tar.gz | 17.3 kB | Without provenance | Details for django-mootools-behavior-0.1.1.tar.gz |
Release files / django-mootools-behavior-0.1.1.tar.gz
| Download URL | django-mootools-behavior-0.1.1.tar.gz |
|---|---|
| Size | 17.3 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
31b1e94f8b80afe0b838ea967b1d4f384807026d1e729d1eceb6e4b386e3f7af
|
|
BLAKE2b-256 checksum How to use checksums |
2b6abd8a22d8009e917ad682b478392d93df0e32a983794296b66217fccbdaeb
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
Security for django-mootools-behavior 0.1.1
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.