Bootstrap 4: Prettier File Inputs
See original GitHub issueFile inputs don’t look too great
They should look more like:
Ours:
<input type="file" name="photo" class="clearablefileinput" id="id_photo">
What it should be closer to:
<label class="custom-file">
<input type="file" name="photo" id="id_photo" class="custom-file-input">
<span class="custom-file-control"></span>
</label>
Issue Analytics
- State:
- Created 6 years ago
- Reactions:4
- Comments:9 (2 by maintainers)
Top Results From Across the Web
Plugins - Prettier
Plugins are ways of adding new languages or formatting rules to Prettier. Prettier's own implementations of all languages are expressed using the plugin...
Read more >Form controls · Bootstrap v5.0
Give textual form controls like <input> s and <textarea> s an upgrade with custom styles, sizing, focus states, and more. ... Disabled file...
Read more >Make the blog prettier with Bootstrap and Blacktie - FooBar
In this blog post we will make the blog look nicer, we will go from the basic non stylish view to a really...
Read more >Formatting code with Prettier - GeeksforGeeks
Even if you have your old codebase, you can run Prettier on your codebase which will reformat all your massive code files in...
Read more >Prettier not formatting HTML files in VS Code - Stack Overflow
defaultFormatter": "vscode.html-language-features" },. And try formatting again. This time Prettier will have better input to work with. The ...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Hey! I think that here is proper place to put this, even if its closed.
The template at
crispy_forms/templates/bootstrap4/layouts/field_file.html
, has this content on the branchmaster
:Which is great, but needs
{% include 'bootstrap4/layout/help_text_and_errors.html' %}
at the end to show the errors. So it will become:I checked the
dev
branch and this file doesn’t exist, even the branch is more recent thanmaster
. On the network insight graph it shows that is 28 behindmaster
and 5 ahead. But that belongs to another issue.Should I open a new issue (and request) to add the fix? From which branch should I do it?
Thanks!
EDIT: forgot a ‘that’ before ‘belongs’.
HI! I had the same problem today. I solved it as follows:
image_thumbnail.html
forms.py
forms.py
Resutl 🎉
I hope that can be helpful to those in a similar situation