web api interface
CSSNumericValue
The CSSNumericValue interface of the CSS Typed Object Model API represents operations that all numeric values can perform.
Interfaces based on CSSNumericValue
Below is a list of interfaces based on the CSSNumericValue interface.
CSSMathClampCSSMathInvertCSSMathMaxCSSMathMinCSSMathNegateCSSMathProductCSSMathSumCSSMathValueCSSNumericArrayCSSUnitValue
Instance properties
None.
Static methods
CSSNumericValue.parse- : Allows a
CSSNumericValueto be constructed directly from a string containing CSS.
- : Allows a
Instance methods
add- : Adds a supplied number to the
CSSNumericValue.
- : Adds a supplied number to the
sub- : Subtracts a supplied number from the
CSSNumericValue.
- : Subtracts a supplied number from the
mul- : Multiplies the
CSSNumericValueby the supplied value.
- : Multiplies the
div- : Divides the
CSSNumericValueby the supplied value.
- : Divides the
min- : Returns the minimum value passed
max- : Returns the maximum value passed
equals- : True if all the values are the exact same type and value, in the same order. Otherwise, false.
to- : Converts
valueinto another one with the specified unit.
- : Converts
toSum- : Converts an existing
CSSNumericValueinto aCSSMathSumobject with values of a specified unit.
- : Converts an existing
type- : Returns the type of
CSSNumericValue, one ofangle,flex,frequency,length,resolution,percent,percentHint, ortime.
- : Returns the type of
Specifications
SpecificationsStandards references are available on the canonical MDN page.
Browser compatibility
Browser compatibilityCompatibility data is available on the canonical MDN page.