Open mo8it opened 3 years ago
+
Not sure about the "not optimal" bit. But an upgrade to BootStrap 5 would be appreciated.
Not sure about the "not optimal" bit. But an upgrade to BootStrap 5 would be appreciated.
I did mean bugs like this which I did finally manage to fix: https://github.com/flask-admin/flask-admin/pull/2233
Anyone knows how hard would it be to override flask-admin templates and use Bootstrap 5?
somebody?
@ealtamir It doesn't look that hard. Give it a whirl.
@mrjoes would you merge a done PR to Bootstrap 5? I am not trying to put any pressure, thank you anyway. Just to not waste time ;)
Following also. We also would be interested in Bootstrap 5.
BootStrap 5 supports LTR (Left-To-Right) direction for RTL languages such as Arabic, Hebrew...etc. BootStrap 5 would be much appreciated.
Any one want to collaborate on making this happen? I've started playing with the bootswatch update to bootstrap 5.2.3
This Flask-Admin project is so much useful, Can anyone please guide how to add support for bootstrap-5.3.3 it would be cool!
I think the approaches I'd suggest would be either of these two:
I think either could work well, but I'm sure everyone will have their opinion or preference on which would work better or be easier. I've been bugged by the same thing, and wouldn't mind contributing or helping to test on a work project.
It's not as easy as it sounds, I have about 60% advanced (I don't use inlines so I haven't got around that), but the main problem is that support for BS4 is not complete, so upgrading it to bs5 is a bit difficult.
Indeed. If there's a branch I could help test for you, or contribute to, I'd be happy to do so. I'm hoping we can get a new release out, since there's an important (to me) bugfix in master that isn't released yet, and this would be a great one to have released soon. It's been three years since Bootstrap 5 came out, and v4 is now six years old, and v3 is ten years old. It's time and I think we can get this working now.
Indeed. If there's a branch I could help test for you, or contribute to, I'd be happy to do so. I'm hoping we can get a new release out, since there's an important (to me) bugfix in master that isn't released yet, and this would be a great one to have released soon. It's been three years since Bootstrap 5 came out, and v4 is now six years old, and v3 is ten years old. It's time and I think we can get this working now.
Anyone knows how hard would it be to override flask-admin templates and use Bootstrap 5?
I don't think it's too hard. Check out these projects:
It's not as easy as it sounds, I have about 60% advanced (I don't use inlines so I haven't got around that), but the main problem is that support for BS4 is not complete, so upgrading it to bs5 is a bit difficult.
X-editable has some problems with BS5, so I used a fork.
Also, what do you mean by "support for BS4 is not complete"? It seems OK to me, what's missing?
Anyone knows how hard would it be to override flask-admin templates and use Bootstrap 5?
I don't think it's too hard. Check out these projects:
I didn't know about this one, i'll check it out.
I contribute to this project and because it was impossible to upgrade there, I decided to include it as a PR here :) i guess i'm back there
I contribute to this project and because it was impossible to upgrade there, I decided to include it as a PR here :) i guess i'm back there
Why was it impossible to upgrade there? 🤓
:param template_mode:
Base template path. Defaults to `bootstrap2`. If you want to use
Bootstrap 3 or 4 integration, change it to `bootstrap3` or `bootstrap4`.
At first i just tried to put None or bs5 but a folder with the name is needed. This parameter loads the base javascript and styles to work with bootswatch, if I just ignore it and make the template regardless, i still get those javascript and styles, with the bugs and fixes for that specific version of bootstrap.
I'm not an expert in front-end, so if there is another workaround it and try to make it work with both javascript loaded (bootstrap 4 and 5), i'll take it, i guess eventually the team here will make their own upgrade.
At first i just tried to put None or bs5 but a folder with the name is needed. This parameter loads the base javascript and styles to work with bootswatch, if I just ignore it and make the template regardless, i still get those javascript and styles, with the bugs and fixes for that specific version of bootstrap.
Hmm. I use template_mode="boostrap4"
because it is irrelevant if you override the templates. On the other hand, you are supposed to add the Bootstrap5 Bootswatch files right?
I'm not an expert in front-end, so if there is another workaround it and try to make it work with both javascript loaded (bootstrap 4 and 5), i'll take it, i guess eventually the team here will make their own upgrade.
Why not just override the <script>
and <link>
tags?
Bootstrap 4 is not optimal in flask-admin. The Bootstrap 3 support is better. Maybe just drop Bootstrap 4 and start with Bootstrap 5 which has been released months ago? Thanks for the awesome package!