Textpattern CMS support forum
You are not logged in. Register | Login | Help
- Topics: Active | Unanswered
Use Normalize and Formalize to provide a consistent CSS base
This is proposal #3 for the TXP5 admin-side structure project
Forego a traditional ‘CSS reset everything’ and use Normalize (public domain) and Formalize (GPL/MIT licenses) instead to provide a consistent browser base set of CSS rules on the admin-side – edited down to the rules we actually will need (obviously we have no need for things such as audio and video tag styling so can safely omit those rules).
Advantages are:
- Extensive work and research has been done already with these 2 projects to iron-out many rendering inconsistencies between the various browsers.
- Gives admin theme authors a good fixed base to build their own design on top of (means they will not have to reinvent the wheel every time and provide rules for every single tag imaginable. Of course any of the Normalize/Formalize rules can be overridden later in the cascade if authors wish.
Any feedback for and against (or suggestions for a different method) welcome.
Offline
Re: Use Normalize and Formalize to provide a consistent CSS base
I like this idea. I never really bought into resets, even though I use them (mostly to not have to say margin:0; padding:0;
on everything).
I wasn’t aware of these. Thanks for pointing them out, Phil.
Offline
Re: Use Normalize and Formalize to provide a consistent CSS base
Personally I far prefer to leave form controls to the user / OS default. That is, I never style them, with the exception of occasionally styling a submit button. It would annoy me, as a theme author, if I have to go through hoops to neutralise that css file (that is, if Textpattern admin loads that stylesheet no matter what – if the way stylesheets are loaded remains the same as current, I don’t care, I never see the default Textpattern theme for more than 10 minutes after installation).
As for Normalize, a quick glance tells me it mostly contains stuff that you’d add to any stylesheet anyway. It is miles ahead of those waste-of-bandwidth reset stylesheets, though; kudos to the author for that.
Where is that emoji for a solar powered submarine when you need it ?
Sand space – admin theme for Textpattern
Offline
Re: Use Normalize and Formalize to provide a consistent CSS base
phiw13 wrote:
Personally I far prefer to leave form controls to the user / OS default. That is, I never style them, with the exception of occasionally styling a submit button. It would annoy me, as a theme author, if I have to go through hoops to neutralise that css file
The Formalize styling is so minimal that you would not have to jump through hoops to change it – it’s more about sorting alignment inconsistencies between browsers.
As for Normalize, a quick glance tells me it mostly contains stuff that you’d add to any stylesheet anyway.
Precisely why it should be included, why make authors rewrite the same rules again and again? And as above, it’s about fixing inconsistencies between browsers so you start from the same base for everything. If it’s good enough for HTML5 Boilerplate then it’s good enough for us too.
Offline
Re: Use Normalize and Formalize to provide a consistent CSS base
Agreed on both points, I roll out both of these fairly often lately. There’s no point in making other themers like Phil go through these inconsistencies.
Offline
Re: Use Normalize and Formalize to provide a consistent CSS base
My initial plan for the reset (Normalize/Formalize) was to have it always load before any theme, via a CSS file, for example like so…
@import 'reset.css';
@import 'themes/default/textpattern.css';
…but thinking about it further (and from comments here) that might upset some themers that want to build their CSS totally from scratch. So the best option would be to instead have it as an @import at the top of the default theme’s main CSS file and then themers have the option of including that import in their themes or not.
Offline