Beiträge von David Scotson

One last reply, and it mostly isn't possible from within themes but I think there's lots of CSS in Moodle that's simply not needed, or is not used. or is only there to work around bugs that could be fixed in the PHP. Getting some attention on those would be good.

Like the first 3 and last 2 lines of this file for example:

https://github.com/moodle/moodle/blob/master/blocks/tags/styles.css

Or this:

https://tracker.moodle.org/browse/MDL-41646

etc.

more ideas linked from MDL-39094

Individually, it's a line here or a couple of lines there, but across the whole of Moodle, and across all Moodle sites, and every user visiting them, it starts to add up. Possibly more importantly it makes Moodle easier to understand for developers and themers.

I shared a script here that strips out RTL specific, and IE6&7 specific code:

https://moodle.org/mod/forum/discuss.php?d=244984

I was intending to expand it to strip out -webkit and -moz declarations that aren't needed for modern browsers too.

With some minor changes to the guidlines for RTL and IE6&7 CSS in Moodle, this would be a lot easier. That is, if the CSS for these things didn't also apply to other stuff and always started a line with specific characters like .dir-rtl or .ie6 the regexes would be a lot less scary.
Wouldn't the same process for custom_css work? Except instead of replacing the placeholder_text with css entered from the user interface, you pull in one of the 6 files based on a setting?

edit: I see Danny has already suggested this in more detail above.