Most of the work already done on bootstrap 3, foundation 5, etc. can be reused. The DOM manipulating parts are also bound to be useful - as an example of what can be done, if nothing else.
I'm using the plugin_layout_<cssfw> functionality to keep bootstrap 2 & 3, bootswatch 2 & 3 and foundation 5 playing along within a single app. I'm aiming for slightly different bs2, bs3, foundation5, etc. welcome apps, that can be packed as plugin_layout_<cssfw> and updated as someone needs them.
About the other part of the equation - the support for different CSS frameworks from within gluon or contrib - there was a discussion about how to implement all this a while ago and I think we really ought to finish it...
My thoughts as far as functionality goes:
-
user would set a global variable (ie. styleserializer=bootstrap3 ..or
bootstrap2, foundation5 or some other predefined style) and thus define
the serialization of menus, forms, tables, grid, flash messages, etc. all in one place
- existing
menu, formstyle, etc. functionality stays, this is needed for
backward compatibility and is also useful. User
could ie. use the global variable to set everything to bootstrap3, then
override the formstyle setting for one specific form to, let's say,
bootstrap3-inline.
All that is left for a user is to drop in a correct welcome app and voila, foundation 5 or bootstrap 3 based web2py.
The implementation is something I'm not clear
about. Should everything be kept in gluon, as it is now..? Should old formstyles (table3cols, etc.) stay within gluon, while
bootstrap, bootstrap3 (it's already done, since recently) and future ones get moved to
contrib? Should MENU() be deprecated, keeping it as is, or should it be extended to accomodate more CSS frameworks? Perhaps a new menu function altogether,
in contrib?
What else am I not thinking of..?