Priority: Enhancement
Current State: No Action Required
Released In: n/a
Target Release: n/a
Hello,
the css files of the PatternSkinTheme in the /pub directory are bad formatted. Therefore I ran csstidy but that works not that well for instance in colors.css. There are some issues with the a:hover elements in the WebLeftBar for example. They aren't blue anymore. But it works fine for most of the files.
It would be nice if you are able to change the format of all css files as they are in the old (PatternSkinTheme2009) source files. I guess that would be much easier for many users like me who would like to customize the css files.
--
KevinKaiser - 09 Nov 2010
I am not sure what you mean by "badly formatted" and "as they are in the old source files". What is the change you are looking for?
--
ArthurClemens - 09 Nov 2010
Thanks for your reply! I try to be more specific.
I'm refering to the css files in
Foswiki-1.1.1/pub/System/PatternSkinTheme/
For instance style.css look to me like this:
html body{font-size:104%;voice-family:"\"}\"";voice-family:inherit;font-size:small;}html>body{font-size:small;}th{line-height:1.15em;}label{padding:.15em .3em .15em 0;}hr{height:1px;border:none;}pre{width:auto;margin:1em 0;border-style:solid;border-width:1px;padding:1em;}pre, code, tt{font-family:"Bitstream Vera Sans Mono","Andale Mono",Courier,monospace;font-size:86%;}html>body pre{/*\*/overflow:auto !important;/**/overflow:scroll;width:auto;
The whole file looks like this (I hope this snippet explains hat I meant with bad formatted) and it's just one line without spaces and newlines. When I'm watching style_src.css in the same directory it looks fine:
/* GENERAL HTML ELEMENTS */
html body {
font-size:104%; /* to change the site's font size, change .foswikiPage below */
voice-family:"\"}\"";
voice-family:inherit;
font-size:small;
}
html>body { /* Mozilla */
font-size:small;
}
th {
line-height:1.15em;
}
label {
padding:.15em .3em .15em 0; /* same vertical padding as foswikiInputField */
}
hr {
height:1px;
border:none;
}
/* put overflow pre in a scroll area */
pre {
width:auto;
margin:1em 0; /* Win IE tries to make this bigger otherwise */
border-style:solid;
border-width:1px;
padding:1em;
}
pre, code, tt {
font-family: "Bitstream Vera Sans Mono","Andale Mono",Courier,monospace;
font-size:86%;
}
/* IE behavior for pre is defined in css.pattern.tmpl in conditional comment */
html>body pre { /* hide from IE */
/*\*/ overflow:auto !important; /* */ overflow:scroll; width:auto; /* for Mac Safari */
}
Both
snippets got the same content. But I wasn't sure if both
files are also the same execpt for the layout. It looks to me that style_src.css is the "older" file of the
PatternSkinTheme2009.
Thats why I tried the package
csstidy. It's an optimiser for css files. Unfortunately the functionality of colors.css was affected. I'm not sure why but that was the reason why I asked the support.
In the end it's just a cosmetic issue but i guess it's much easier ro read and edit the second example and you are interested in keeping your files readable.
--
KevinKaiser - 09 Nov 2010
Since Foswiki 1.1 the css and javascript files are optimized for faster loading. The package installer creates compressed css (with
CPAN:CSS::Minifier) from
_src.css
files. In our SVN repository we keep the expanded css with newlines - for easier maintenance.
That doesn't answer your problem with your links, but it explains that the files are not badly formatted. You are seeing the minified files.
--
ArthurClemens - 10 Nov 2010
I already expected something like that. Thanks for your advice.
It's nice to know that the
_src,css
are still the same just without the comments etc.
Just one last question is there an easier way to generate the optimized file without a self written perlscript. For instance can I just remove the
style.css
and edit
style_src.css
and afterwards I got a new compressed
style.css.gz
file?
If it's easy to implement to the foswiki core it would be a nice feauture. Just a thought. Otherwise you can close this support ticket or item or however you call it.
Thanks for the help!
--
KevinKaiser - 10 Nov 2010