MCPcopy Create free account
hub / github.com/tree-sitter/tree-sitter-javascript / vendorPropName

Function vendorPropName

examples/jquery.js:5712–5732  ·  view source on GitHub ↗
( style, name )

Source from the content-addressed store, hash-verified

5710
5711// return a css property mapped to a potentially vendor prefixed property
5712function vendorPropName( style, name ) {
5713
5714 // shortcut for names that are not vendor prefixed
5715 if ( name in style ) {
5716 return name;
5717 }
5718
5719 // check for vendor prefixed names
5720 var capName = name[0].toUpperCase() + name.slice(1),
5721 origName = name,
5722 i = cssPrefixes.length;
5723
5724 while ( i-- ) {
5725 name = cssPrefixes[ i ] + capName;
5726 if ( name in style ) {
5727 return name;
5728 }
5729 }
5730
5731 return origName;
5732}
5733
5734function setPositiveNumber( elem, value, subtract ) {
5735 var matches = rnumsplit.exec( value );

Callers 1

jquery.jsFile · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…