Bug Tracker

Opened 6 years ago

Closed 6 years ago

#12967 closed feature (plugin)

Automatically prefix CSS values

Reported by: m_gol Owned by: m_gol
Priority: undecided Milestone: None
Component: unfiled Version: 1.8.3
Keywords: Cc:
Blocked by: Blocking:

Description

Now that jQuery automatically prefixes CSS properties, auto-prefixing values would be useful, too. I'm talking about things like transition, transform, calc etc.

Change History (3)

comment:1 Changed 6 years ago by dmethvin

Owner: set to m_gol
Status: newpending

Can you provide some examples of what you are looking for?

comment:2 Changed 6 years ago by m_gol

Status: pendingnew

For example so that using: $('#id').css('width', 'calc(50% - 30px)'); would cause the following in Chrome: document.getElementById('id').style.width === '-webkit-calc(50% - 30px)'

Actually, I made a mistake mentioning transitions and transforms, they are obviously values, not properties.

Another useful value waiting to be handled this way is linear-gradient to be interpreted as -webkit-linear-gradient in WebKit browsers.

Obviously it can't be done so 'pretty' as auto-prefixing values, you'd have to keep a white-list of accepted properties; there aren't a lot of them, though. Lea Verou keeps four of them in -prefix-free; apart from mentioned they're 'element' and 'cross-fade'.

comment:3 Changed 6 years ago by dmethvin

Resolution: plugin
Status: newclosed

I think this is beyond what core would do, especially since it couldn't be implemented economically in all our supported browsers.

Note: See TracTickets for help on using tickets.