-
Notifications
You must be signed in to change notification settings - Fork 40
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
css does not work for radio buttons #43
Comments
@preisleistung Please try with version 1.1.15 and let me know if it works. You could also try creating the radio buttons via the {{ form.FIELD_NAME|materializecss:'s12 m6, icon=person' }} syntax. |
Hi, The problem is that the labels text needs a span tag to work, as @bartoszkoper said: <label for="id_input">
<input type="radio" id="id_input" ... >
<span> Label Text </span>
</label> The naive solution I found is to insert this tag using Javascript by modifying labels innerHTML property. |
If it helps somebody, there is dirty hack:
details: https://stackoverflow.com/questions/44675550/django-widget-override-template
there is {{ widget.label }} wrapped into |
Thank you! |
The package does not work for me
I installed the package with
pip install django-materializecss-form
I added the package in the installed apps
INSTALLED_APPS = ( 'materializecssform', ... )
I added to the
<head>
in the template, I load the package with
{% load materializecss %}
and then I use it in my template as
but the style does not change.
Am I doing something wrong?
I have the version 1.1.14, with Django 3.0 and Python 3.6
The text was updated successfully, but these errors were encountered: