Skip to content

Theme

Type class

A base class for an amCharts theme.

More info: Themes

Sources

Theme can be used (imported) via one of the following packages.

// Import Theme
import * as am5 from "@amcharts/amcharts5";
// Create Theme
am5.Theme.new(root, {
// ... config if applicable
});

Inheritance

Theme does not extend any other symbol.

Theme is extended by ColorblindTheme, EmberTheme, MidnightTheme, NordDarkTheme, NordTheme, PastelDarkTheme, PastelTheme, PatternsDarkTheme, PatternsTheme, PetroleumTheme, ResponsiveTheme, SavannaTheme.

Properties

Theme does not have any properties.

Methods

constructor(root: Root,
isReal: boolean
)

Returns Theme

new(root: Root)

StaticReturns InstanceType

Use this method to create an instance of this class.

More info: Getting started: new element syntax

rule(themeClass: K,
themeTags: Array
)

Returns Template

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 Template

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

More info: Themes

Events

Theme does not have any events.