by Groxx · 15y ago · 0 comments
Link is available on the FAQ wiki page - it should really be on the readme.
edit: I don't think I like it... some details as to why:
grid.css
.line:after, .lastUnit:after {
clear: both;
content: " x x x x x x x x x x x x x x x x x x x x x x x x x x x x x x x x x x x x x x x x x x x x x x x x x x x x x x x x x x x x x x x x x x x x x x x x x x x x x x x x x x x x x x x x x x x x ";
display: block;
font-size: xx-large;
height: 0 !important;
line-height: 0;
overflow: hidden;
visibility: hidden;
}
Anyone care to explain that one? Disabling it causes some sections of the page to overlap. grid.css
.size1of1 {float: none;}
.size1of2 {width: 50%;}
.size1of3 {width: 33.3333%;}
... etc
content.css
.f105 {font-size: 105%;}
.p0 {padding: 0;}
.p15 {padding: 15px;}
.pt0 {padding-top: 0;}
.pt25 {padding-top: 25px;}
.pl0 {padding-left: 0;}
.pl15 {padding-left: 15px;}
... etc
They've achieved "object oriented" by moving the styles from the CSS to the class attribute. ie, you might as well write `style="padding:0"`, it's the same thing. No doubt HTML-veterans who never really got the whole CSS thing would like it, it's very nearly equivalent to using tables for layout, but with floats instead of <td>s.That said, I have not used it, or any similar CSS frameworks. Anyone who has care to comment on usability / reusability?
var foo = new Animal Brown Quadruped Barking();
Even if styles could be inherited, this seems to be taking the wrong approach. Most of use realise that classes should be used to denote identity, and not behaviour (or in this case, styling). CSS preprocessors seem to fix the same problem in a much nicer way. /* Define classes used in HTML */
.sidebar {
@include bordered-box;
}
#special-offer {
@include bordered-box;
position: absolute;
top: 0;
right: 0;
}
/* Define theme information */
@mixin bordered-box {
h3 {
background: red;
color: white;
}
border: 1px solid red;
}At least there's Less. Anyone use it, or know of a better system?
http://www.stubbornella.org/content/2010/12/09/the-hacktasti...
Edit: I also agree with your sentiment. This seems to move away from what CSS classes are intended for, and gives things naming conventions that are tied directly to their internal CSS code instead of to their semantic meaning on the page. That said, I haven't used it either, so maybe it's way better this way, but something doesn't sit right with me.
Though I would be interested in seeing some profiling data demonstrating one way or the other. Even if it's relatively transient data, as it relies heavily on the rendering code.