The value parts in the JSS definitions may have one of the following types:

  • Number
  • String
  • Array
  • Object

All other types are ignored.

The value does not have to be a literal. It can be the result of a JavaScript expression if the result is of one of the types above.

Numbers ...

... are interpreted as pixel dimensions and the value is output as string with added "px".

Sample:

padding: 5

produces:

padding: 5px;

Strings ...

... are not interpreted and output as specified.

Arrays ...

... are interpreted as multiple values of the same CSS property.

Sample:

background_image: [

"-moz-linear-gradient(white, gray)",

"-webkit-linear-gradient(white, gray)"

]

will produce:

background-image: -moz-linear-gradient(white, gray);

background-image: -webkit-linear-gradient(white, gray);

Objects ...

... are interpreted as CSS definition of a CSS selector specified by the property. The generated CSS selector is full qualified. Object values are processed recursively.

Sample:

a: {

color: "red",

span: {

display: "none"

}

}

will produce

a {

color: red;

}

a span {

display: none;

}