YUI js framework uses the similar approach, called BorderLayout. Thout it is an interesting solution for creating layouts, I preffer RUZEE BorderLayout [http://www.ruzee.com/blog/ruzeelayoutmanager/].
brave1979, 2007/12/31 17:25:
Great thing. I only don't like how the content sticks out of its box when box is too small. I'd prefer content to force its box to have height sufficient to keep content inside. But I definitely have to give a closer look to ruzee layout manager and yui BorderLayout as well.
Toby Inkster, 2008/01/03 11:51:
Looks good. However, you seem to be using both jQuery *and* prototype.js to build up your BraveLayout object. You could probably cut your file sizes down significantly by choosing one of them and sticking to it.
Also, reliance on quirks mode is evil.
brave1979, 2008/01/03 12:48:
Currently I offer two versions. First, standalone that has some parts of protoype.js inside it. Second, relying on jQuery, without any parts of prototype, jQuery or any other libs inside.
I'd like to offer also third version for prototype users (currently I don't because of a bug in protoype). Also maybe fourth for mootools users.
Currently preferred version in all cases is standalone version. But if you are using jQuery you may try special version for jQuery as well.
Basically I must rely on some other lib (or embed part of it inside my lib) because I need function getElementsByCSSSelector.
As for reliance on quirks mode: it is considered evil because it's not described by any standard docs. But it is highly consistent across different modern browsers (in parts that I use) and I know no other way how to achieve desired functionality especially in IE standards mode. So I'm afraid it's necessary evil.
Discussion
Opinions and questions welcomed
YUI js framework uses the similar approach, called BorderLayout. Thout it is an interesting solution for creating layouts, I preffer RUZEE BorderLayout [http://www.ruzee.com/blog/ruzeelayoutmanager/].
Great thing. I only don't like how the content sticks out of its box when box is too small. I'd prefer content to force its box to have height sufficient to keep content inside. But I definitely have to give a closer look to ruzee layout manager and yui BorderLayout as well.
Looks good. However, you seem to be using both jQuery *and* prototype.js to build up your BraveLayout object. You could probably cut your file sizes down significantly by choosing one of them and sticking to it.
Also, reliance on quirks mode is evil.
Currently I offer two versions. First, standalone that has some parts of protoype.js inside it. Second, relying on jQuery, without any parts of prototype, jQuery or any other libs inside.
I'd like to offer also third version for prototype users (currently I don't because of a bug in protoype). Also maybe fourth for mootools users.
Currently preferred version in all cases is standalone version. But if you are using jQuery you may try special version for jQuery as well.
Basically I must rely on some other lib (or embed part of it inside my lib) because I need function getElementsByCSSSelector.
As for reliance on quirks mode: it is considered evil because it's not described by any standard docs. But it is highly consistent across different modern browsers (in parts that I use) and I know no other way how to achieve desired functionality especially in IE standards mode. So I'm afraid it's necessary evil.