jackmoore / colorbox

A light-weight, customizable lightbox plugin for jQuery
http://www.jacklmoore.com/colorbox/
MIT License
4.75k stars 1.14k forks source link

Please cleanup bloated html structure #165

Open lhwparis opened 12 years ago

lhwparis commented 12 years ago

is there a chance for getting a less bloatet html structure in one of the following updates? with modern browsers we can do things like box-shadows and rounded corners with pure css so no need to set so much divs (cboxTopLeft, cboxTopRight, cboxTopCenter, cboxMiddleLeft, cboxMiddleRight and much more) think u shoud provide a config option to get cleaner html for people only supporting modern browsers in there projects

suit commented 12 years ago

Maybe a Template would be an option - it should be possible to define a string via settings to define the created template - just like the 'current' option

the appropriate function for doing this ia apperently "appendHTML()"

Anahkiasen commented 12 years ago

+1

jamesshannon commented 12 years ago

+1. I'd really like to see this. In fact, I came here to file this request as, besides being bloated, I fnd that the rounded corners and shadow break or look odd when at zoom level = -1 in chrome (the breaking is when using inline HTML with a very small div).

jackmoore commented 12 years ago

I would like to do this as part of a larger rewrite that drops support for older browsers. A lot of what you are seeing is there in order to have the same level of support in, say, IE6 as there is in Chrome. It's time for these browsers to be dropped, and all those corner elements dropped in favor of border-radius, but I just haven't gotten around to it yet. Sorry everyone.

jamesshannon commented 12 years ago

I agree with the principle of support for older browsers using one set of code (ie, not a lot of if/else statements and different chunks of code). But, yeah, sometime in the next few weeks, Google is dropping support for IE7 (ie, only >= IE8) and it appears that the current version of cbox is stable enough that if a designer really needs legacy browser support then they're well served with the current version.

So... I'm in agreement, would like to see this, and.... now that I know that Jack supports this change I might submit a pull request if I find the time.

On 8 Oct 2012, at 15:45 , Jack Moore wrote:

I would like to do this as part of a larger rewrite that drops support for older browsers. A lot of what you are seeing is there in order to have the same level of support in, say, IE6 as there is in Chrome. It's time for these browsers to be dropped, and all those corner elements dropped in favor of border-radius, but I just haven't gotten around to it yet. Sorry everyone.

— Reply to this email directly or view it on GitHub.