control browser dependent CSS with javascript or something
control browser dependent CSS with javascript or something
| Issue ID: | 1022 |
| Issue Category: | bug |
| Component: | ui |
| Priority: | normal |
| Status: | fixed |
| Assigned: | evan |
| Version: | 0.7 |
| Milestone: | 1.0 |
The specific example is border-radius, -moz-border-radius, and -webkit-border-radius. Each of these do the same thing, but only work with a specific set of browsers. It would be nice to have CSS like this to be controlled by javascript and the correct attribute only injected based upon browser type.

Updates
#1
I know it‘s kinda radical, but I would suggest dropping proprietary CSS completely. Why not sticking to standards?
#2
the great thing about standards is that there are so many to choose from :). Heck, there isn't even a standard way to fire up AJAX across all browsers but we still do that. Sometimes there are nice features that make things look or feel nicer that you need to do a tap dance for.
#3
You‘ll find me amongst the first who beg for better laconica user experience with javascript disabled. And yet, Ajax is quite the same for all browsers except IE prior 7. This does obviously not apply for CSS.
#4
If this is a 'standards' or 'best practises' concern, then I don't think JavaScript offers a better solution because:
* These styles are not intended to be available if JavaScript is enabled.
* UA-sniffing is not always reliable.
* This is overcomplicating the problem then it really needs to be.
This is an interim solution (i.e., putting proprietary CSS with the base stylesheet -- except in the case of IE which is dealt with a separate stylesheet using conditional comments) until the "border-radius" property is widely supported. When the time is right, we just need to remove a few lines.
The way I see it is that given the minimum usage, this is not 'bad' in any way.
Alternative to current method (i.e., border-radius) is to use extra markup and introduce images into the equation. I personally see this as a poor solution.
Of course we could drop rounded corners altogether, but, I don't think many will fancy that idea =)
I'm going to close this bug but I encourage anyone to reopen and come forward with a better solution.
You can also subscribe to the
RSS feed for updates to this issue.