Skip to content

ResponsiveTheme

Type class

A theme that changes chart settings as the chart's size changes, so charts fit small spaces. new() comes with built-in rules for the common chart types; newEmpty() starts with none, for rules of your own.

More info: Responsive theme

Sources

This information about ResponsiveTheme is provided for reference only and is not available through exported packages and thus should not be imported or used on its own.

Inheritance

ResponsiveTheme extends ResponsiveBaseTheme.

ResponsiveTheme is not extended by any other symbol.

Properties

36 inherited items
heightL

StaticType (width: number, height: number) => booleanInherited from ResponsiveBaseTheme

true when the height is at most L (600 pixels).

heightM

StaticType (width: number, height: number) => booleanInherited from ResponsiveBaseTheme

true when the height is at most M (400 pixels).

heightS

StaticType (width: number, height: number) => booleanInherited from ResponsiveBaseTheme

true when the height is at most S (300 pixels).

heightXL

StaticType (width: number, height: number) => booleanInherited from ResponsiveBaseTheme

true when the height is at most XL (800 pixels).

heightXS

StaticType (width: number, height: number) => booleanInherited from ResponsiveBaseTheme

true when the height is at most XS (200 pixels).

heightXXL

StaticType (width: number, height: number) => booleanInherited from ResponsiveBaseTheme

true when the height is at most XXL (1000 pixels).

heightXXS

StaticType (width: number, height: number) => booleanInherited from ResponsiveBaseTheme

true when the height is at most XXS (100 pixels).

isL

StaticType (width: number, height: number) => booleanInherited from ResponsiveBaseTheme

true when both the width and the height are at most L (600 pixels).

isM

StaticType (width: number, height: number) => booleanInherited from ResponsiveBaseTheme

true when both the width and the height are at most M (400 pixels).

isS

StaticType (width: number, height: number) => booleanInherited from ResponsiveBaseTheme

true when both the width and the height are at most S (300 pixels).

isXL

StaticType (width: number, height: number) => booleanInherited from ResponsiveBaseTheme

true when both the width and the height are at most XL (800 pixels).

isXS

StaticType (width: number, height: number) => booleanInherited from ResponsiveBaseTheme

true when both the width and the height are at most XS (200 pixels).

isXXL

StaticType (width: number, height: number) => booleanInherited from ResponsiveBaseTheme

true when both the width and the height are at most XXL (1000 pixels).

isXXS

StaticType (width: number, height: number) => booleanInherited from ResponsiveBaseTheme

true when both the width and the height are at most XXS (100 pixels).

L

StaticType numberInherited from ResponsiveBaseTheme

Breakpoint of 600 pixels.

M

StaticType numberInherited from ResponsiveBaseTheme

Breakpoint of 400 pixels.

maybeL

StaticType (width: number, height: number) => booleanInherited from ResponsiveBaseTheme

true when the width or the height is at most L (600 pixels).

maybeM

StaticType (width: number, height: number) => booleanInherited from ResponsiveBaseTheme

true when the width or the height is at most M (400 pixels).

maybeS

StaticType (width: number, height: number) => booleanInherited from ResponsiveBaseTheme

true when the width or the height is at most S (300 pixels).

maybeXL

StaticType (width: number, height: number) => booleanInherited from ResponsiveBaseTheme

true when the width or the height is at most XL (800 pixels).

maybeXS

StaticType (width: number, height: number) => booleanInherited from ResponsiveBaseTheme

true when the width or the height is at most XS (200 pixels).

maybeXXL

StaticType (width: number, height: number) => booleanInherited from ResponsiveBaseTheme

true when the width or the height is at most XXL (1000 pixels).

maybeXXS

StaticType (width: number, height: number) => booleanInherited from ResponsiveBaseTheme

true when the width or the height is at most XXS (100 pixels).

responsiveRules

Type IResponsiveRule[]Default []Inherited from ResponsiveBaseTheme

Rules added to the theme.

S

StaticType numberInherited from ResponsiveBaseTheme

Breakpoint of 300 pixels.

widthL

StaticType (width: number, height: number) => booleanInherited from ResponsiveBaseTheme

true when the width is at most L (600 pixels).

widthM

StaticType (width: number, height: number) => booleanInherited from ResponsiveBaseTheme

true when the width is at most M (400 pixels).

widthS

StaticType (width: number, height: number) => booleanInherited from ResponsiveBaseTheme

true when the width is at most S (300 pixels).

widthXL

StaticType (width: number, height: number) => booleanInherited from ResponsiveBaseTheme

true when the width is at most XL (800 pixels).

widthXS

StaticType (width: number, height: number) => booleanInherited from ResponsiveBaseTheme

true when the width is at most XS (200 pixels).

widthXXL

StaticType (width: number, height: number) => booleanInherited from ResponsiveBaseTheme

true when the width is at most XXL (1000 pixels).

widthXXS

StaticType (width: number, height: number) => booleanInherited from ResponsiveBaseTheme

true when the width is at most XXS (100 pixels).

XL

StaticType numberInherited from ResponsiveBaseTheme

Breakpoint of 800 pixels.

XS

StaticType numberInherited from ResponsiveBaseTheme

Breakpoint of 200 pixels.

XXL

StaticType numberInherited from ResponsiveBaseTheme

Breakpoint of 1000 pixels.

XXS

StaticType numberInherited from ResponsiveBaseTheme

Breakpoint of 100 pixels.

Methods

constructor(root: Root,
isReal: boolean
)

Returns ResponsiveTheme

7 inherited items
addRule(rule: IResponsiveRule)

Returns IResponsiveRuleInherited from ResponsiveBaseTheme

Adds a responsive rule and returns it. It applies at once if it is relevant.

More info: Responsive theme

dispose()

Returns voidInherited from ResponsiveBaseTheme

new(root: Root)

StaticReturns InstanceTypeInherited from Theme

Use this method to create an instance of this class.

More info: Getting started: new element syntax

newEmpty(root: Root)

StaticReturns InstanceTypeInherited from ResponsiveBaseTheme

Creates the theme without its built-in rules, for rules of your own.

removeRule(rule: IResponsiveRule)

Returns voidInherited from ResponsiveBaseTheme

Removes a responsive rule from the theme.

rule(themeClass: K,
themeTags: Array
)

Returns TemplateInherited from Theme

Returns the rule for a class and theme tags, as a Template. Settings set on it go to every element of that class (or a class extending it) that has all of these tags. The same class and tags return the same rule.

More info: Themes

ruleRaw(themeClass: string,
themeTags: Array
)

Returns TemplateInherited from Theme

Same as rule(), but takes any class name, without type checks.

More info: Themes

Events

ResponsiveTheme does not have any events.