dojox/mobile/_css3 (version 1.10)

Summary

This module provide some cross-browser support for CSS3 properties.

See the dojox/mobile/_css3 reference documentation for more information.

Method Summary

  • add(styles,css3Styles) Prefixes all property names in "css3Styles" and adds the prefixed properties in "styles".
  • name(p,hyphen) Returns the name of a CSS3 property with the correct prefix depending on the browser.

Methods

add(styles,css3Styles)
Defined by dojox/mobile/_css3

Prefixes all property names in "css3Styles" and adds the prefixed properties in "styles". Used as a convenience when an object is passed to domStyle.set to set multiple styles.

Parameter Type Description
styles Object
css3Styles Object
Returns:any | Object

The "styles" argument where the CSS3 styles have been added.

Examples

Example 1

domStyle.set(bar, css3.add({ opacity: 0.6, position: "absolute", backgroundColor: "#606060" }, { borderRadius: "2px", transformOrigin: "0 0" }));

name(p,hyphen)
Defined by dojox/mobile/_css3

Returns the name of a CSS3 property with the correct prefix depending on the browser.

Parameter Type Description
p String

The (non-prefixed) property name. The property name is assumed to be consistent with the hyphen argument, for example "transition-property" if hyphen is true, or "transitionProperty" if hyphen is false. If the browser supports the non-prefixed property, the property name will be returned unchanged.

hyphen Boolean
Optional

Optional, true if hyphen notation should be used (for example "transition-property" or "-webkit-transition-property"), false for camel-case notation (for example "transitionProperty" or "webkitTransitionProperty").

Returns:String

The (non-prefixed) property name. The property name is assumed to be consistent with the hyphen argument, for example "transition-property" if hyphen is true, or "transitionProperty" if hyphen is false. If the browser supports the non-prefixed property, the property name will be returned unchanged.

Error in the documentation? Can’t find what you are looking for? Let us know!