ReadonlyheightThe height of the size.
ReadonlywidthThe width of the size.
Applies a transformation to the point by scaling to the dimension [width, height]
Returns a new size with width and height rounded to a number which is greater than or equal
to the current value.
A new Size.
Returns a new instance of this Record type with all values set to their default values.
Returns a new instance of this Record type with the value for the specific key set to its default value.
Returns a new size with width and height rounded to a number which is smaller than or equal
to the current value.
A new Size.
Returns the value associated with the provided key, which may be the default value defined when creating the Record factory function.
If the requested key is not defined by this Record type, then notSetValue will be returned if provided. Note that this scenario would produce an error when using Flow or TypeScript.
OptionalnotSetValue: anyScales the width and height by a given factor.
The scale factor.
A new Size.
Returns a new size with the width set to the current height value and the height
set to the current width value.
A new Size.
Deeply converts this Record to equivalent native JavaScript Object.
Note: This method may not be overridden. Objects with custom serialization to plain JS may override toJSON() instead.
The height of the size.
The width of the size.
A size is a 2D vector that describes the size of an element. It has the values
widthandheight. Provided values are defined in same units used by the page, point units. Point units are only equal to pixels when zoom value is1.It is an https://facebook.github.io/immutable-js/docs/#/Record|Immutable.Record and thus can be updated using
set(key, value), for example:size.set("width", 20).Example
Create and update a size.
Param: args
An object used to initialize the size. If
widthorheightis omitted,0will be used instead.Default