-
Notifications
You must be signed in to change notification settings - Fork 58
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
Base input style #8
base: main
Are you sure you want to change the base?
Base input style #8
Conversation
Not sure why there's 9 commits instead of just the last 3 😮 |
@@ -2,7 +2,7 @@ | |||
name="{% if input.name|wordcount > 1 %}{{ input.name|slugify }}{% else %}{{ input.name }}{% endif %}" | |||
value="{{ input.value }}" | |||
{% if input.input_type != "hidden" %} | |||
class="{{ input.field_classes }}" | |||
class="{{ input.field_classes }} bg-white focus:outline-none focus:shadow-outline border border-gray-300 rounded-lg py-2 px-4 block w-full appearance-none leading-normal" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Say the form has two buttons, submit / cancel. Does this allow users to still adjust colour by adding additional classes? (seems to me like the most likely use case).
"fileinput": "fileinput fileUpload", | ||
"passwordinput": "textinput textInput", | ||
"emailinput": "bg-white focus:outline-none border border-gray-300 rounded-lg py-2 px-4 block w-full \ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can we add these classes to the default_styles
dict on the class instead?
Will need to drop the trailing input/widget from from the widget type.
Thanks for this! Sorry I've been a bit quiet the last week. I've added your styling to most of the widget classes which are text inputs. The image below shows where we're currently at (not quite sure what's not happening with the labels they should be styled but it's not working on the test project) I'm still not sure about the buttons - so may merge the first commit and leave this pull request open with the buttons. On the tests, whilst I think it worked to show how it works initially I think we're reaching the point where this isn't a good long term solution. Also as there are |
d9008d4
to
9e339c6
Compare
Co-authored-by: Jonathan Grahl <[email protected]>
Co-authored-by: Jonathan Grahl <[email protected]>
9e339c6
to
2051d48
Compare
Hey @bittermandel I've pushed the base styles in this commit. dd3f497 We're therefore currently at this with |
Hi @bittermandel and @smithdc1! Is this PR still relevant? I saw that you pushed some commits regarding these changes ages ago. Best |
It would be nice if the base styles defaulted by this library were adapted at least similar to those of https://tailwindui.com/components/ |
Hi @blasferna! Carltons approach to requests like this is usually: "This is a suggetion / template, customize it as much as you want in your own project." Nevertheless, if you have some concrete ideas, I'd be happy to discuss them in a PR. 🙂 |
Hello @GitRon! Thank you for your response. I have the time available to dedicate to the project and would be delighted to work on it. Regarding the default suggestion/template, I think we could make some adjustments to enhance its appearance. I am open to suggestions and eager to collaborate with you. Best regards! 😊 |
Hi @blasferna ! That sounds great having you on board ❤️ I'm always a fan of starting small instead of reinventing the world in one PR. Maybe you could identify one or two smaller issues and create a PR for that? I'd suggest we start with "broken" or "anti-pattern" stuff and move then to the best practices. What do you think? Best from Cologne |
Absolutely, let's start with smaller tasks. I'll be working on some issues. |
This PR applies some basic styling for text, email and base inputs. It includes some rounded borders, some outlines on focus and just prettier defaults.