Skip to main content

Django library to alter css classes and html attributes.

Project description

[![Build Status](https://travis-ci.org/c-bata/django-label-tag-attr.svg?branch=master)](https://travis-ci.org/c-bata/django-label-tag-attr)

More easy to alter css classes and html attributes. This library can render a form label like django-widget-tweaks

The license is MIT.

Installation

$ pip install django-widget-tweaks

Then add ‘label_tag_attr’ to INSTALLED_APPS.

Usage

Prev

{% load widget_tweaks %}

<label id="{{ form.text.id_for_label }}" class="control-label">{{ form.text.label }}</label>
{% render_label form.text class="form-control" %}

Use django-label-tag-attr

render_field template tag for customizing form fields by using an HTML-like syntax.

{% load label_tag_attr %}
{% load widget_tweaks %}

{% render_label form.text class="control-label" %}
{% render_field form.text class="form-control" %}

Resources

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

django-label-tag-attr-1.0.0.tar.gz (2.5 kB view details)

Uploaded Source

Built Distribution

django_label_tag_attr-1.0.0-py3-none-any.whl (3.5 kB view details)

Uploaded Python 3

File details

Details for the file django-label-tag-attr-1.0.0.tar.gz.

File metadata

File hashes

Hashes for django-label-tag-attr-1.0.0.tar.gz
Algorithm Hash digest
SHA256 5665c8b1bcc2a4cd38ca4ab137ad75428420f05e1475d6c424379ce5cedb2f58
MD5 8507b59c89328c34406436b041964098
BLAKE2b-256 446e7651b6edbff903fa7c30f8fca4ba547d55494c1d540fed93c981599e665f

See more details on using hashes here.

Provenance

File details

Details for the file django_label_tag_attr-1.0.0-py3-none-any.whl.

File metadata

File hashes

Hashes for django_label_tag_attr-1.0.0-py3-none-any.whl
Algorithm Hash digest
SHA256 48a97433d8178d6af9b0f9876399e3daa7389b1bba930fcbf3f7976e8741d335
MD5 686d3852170efaae6b0f278f35ee4af7
BLAKE2b-256 568ff38bad547ea0084d88daf29fd59284f1eaa3fd2d663f2942402d4341064f

See more details on using hashes here.

Provenance

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page