Material Theme

Apply the perfect look and feel to your apps with the styles supported by the Telerik and Kendo UI Material theme.

Variables

The Telerik and Kendo UI Material theme employs multiple variables that you can use to customize the theme.

Color Palette

As this theme follows the Material Design guidelines, it sets itself apart from the other Telerik and Kendo UI themes by implementing color palettes and the option to choose between dark and light theme variants. This helps you to customize the theme while following the Material Design guidelines. The preferred way for customizing the theme is by changing the primary, secondary, and tertiary palette and also by switching between the light and dark variants.

The following example shows how to customize the primary and secondary color palettes and make your theme dark.

// High level variables
$primary-palette-name: purple;
$secondary-palette-name: cyan;
$theme-type: dark;

// Import the theme after your customization
@import "@progress/kendo-theme-material/dist/all.scss";

If you need more flexibility and you do not insist on following the Material guidelines strictly, you can customize the theme variables in the same way as with the other Telerik and Kendo UI themes.

Variables by Scope

When it comes to the effect that a specific change in a variable's value causes, variables are not equal. Changing some values will have a much wider impact on the theme than changing others.

Depending on the extent of the styles that each variable controls, the variables fall into three main groups:

  • Global variables—They control globally used theme colors like $kendo-color-primary$kendo-color-secondary$kendo-color-success$kendo-color-error.
  • Variables affecting all UI components—For example,  $kendo-component-text$kendo-component-bg.
  • Variables affecting individual UI components—For example, $kendo-grid-bg$kendo-tabstrip-font-size.

Most component-level variables link to generic variables that are higher in the hierarchy. For instance, you can customize the background of the Grid component both through the $kendo-component-bg and $kendo-grid-bg variables. In this case, consider that the $kendo-grid-bg variable references $kendo-component-bg.

Here is a quick example on how to customize the Telerik and Kendo UI Material theme:

// Change primary color of the theme
$kendo-color-primary: #b5026d;

// Increase the line height
$kendo-line-height: math-div( 30, 14 );

// Import the theme after your variables customization
@import "@progress/kendo-theme-material/dist/all.scss";

// Note: the variables bellow this point will not take effect,
// because the theme is already imported

$kendo-component-border: blue;

List of Variables

The following tables represent the variables in the Telerik and Kendo UI Material theme by the type of styles that they control.

Typography Variables

The typography Sass variables set the styles related to fonts and text.

VariableDefault ValueComputed ValueValue
kendo-font-size14px14pxDefault: 14pxComputed: 14px
Description: Base font size across all components.
kendo-font-family-sans-serifRoboto, "Helvetica Neue", sans-serifRoboto, "Helvetica Neue", sans-serifDefault: Roboto, "Helvetica Neue", sans-serifComputed: Roboto, "Helvetica Neue", sans-serif
Description: Font family for text.
kendo-font-family-monospaceConsolas, "Ubuntu Mono", "Lucida Console", "Courier New", monospaceConsolas, "Ubuntu Mono", "Lucida Console", "Courier New", monospaceDefault: Consolas, "Ubuntu Mono", "Lucida Console", "Courier New", monospaceComputed: Consolas, "Ubuntu Mono", "Lucida Console", "Courier New", monospace
Description: Font family for monospaced text. Used for styling the code.
kendo-font-familyRoboto, "Helvetica Neue", sans-serifRoboto, "Helvetica Neue", sans-serifDefault: Roboto, "Helvetica Neue", sans-serifComputed: Roboto, "Helvetica Neue", sans-serif
Description: Font family across all components.
kendo-line-heightk-math-div( 28, 14 )2Default: k-math-div( 28, 14 )Computed: 2
Description: Line height used along with $kendo-font-size.

Common Variables

The common Sass variables control a wide range of styles that are not related to a specific UI component.

VariableDefault ValueComputed ValueValue

Component Variables

The component Sass variables are dedicated to a specific UI component and control its styles.

VariableDefault ValueComputed ValueValue
kendo-component-bgk-map-get( $theme, component-bg ) #ffffffDefault: k-map-get( $theme, component-bg )Computed: #ffffff
Description: Background color of a component. Note: do not use this variable directly. Instead derive it as `$component-name-bg` e.g. `$kendo-grid-bg: $kendo-component-bg !default;`.
kendo-component-textk-map-get( $theme, component-text ) rgba(0, 0, 0, 0.87)Default: k-map-get( $theme, component-text )Computed: rgba(0, 0, 0, 0.87)
Description: Text color of a component. Note: do not use this variable directly. Instead derive it as `$component-name-text` e.g. `$kendo-grid-text: $kendo-component-text !default;`.
kendo-component-borderk-map-get( $theme, component-border ) rgba(0, 0, 0, 0.12)Default: k-map-get( $theme, component-border )Computed: rgba(0, 0, 0, 0.12)
Description: Border color of a component. Note: do not use this variable directly. Instead derive it as `$component-name-border` e.g. `$kendo-grid-border: $kendo-component-border !default;`.

Color-System Variables

The color-system Sass variables control the theme styles related to color.

VariableDefault ValueComputed ValueValue
kendo-color-primarymaterial-color( $primary-palette, main ) #3f51b5Default: material-color( $primary-palette, main )Computed: #3f51b5
Description: The color that focuses the user attention. Used for primary buttons and for elements of primary importance across the theme.
kendo-color-primary-contrastmaterial-color( $primary-palette, main-contrast ) whiteDefault: material-color( $primary-palette, main-contrast )Computed: white
Description: The color used along with the primary color denoted by $kendo-color-primary. Used to provide contrast between the background and foreground colors.
kendo-color-secondarymaterial-color( $secondary-palette, main ) #e51a5fDefault: material-color( $secondary-palette, main )Computed: #e51a5f
Description: The secondary color of the theme.
kendo-color-secondary-contrastmaterial-color( $secondary-palette, main-contrast ) whiteDefault: material-color( $secondary-palette, main-contrast )Computed: white
Description: The color used along with the secondary color denoted by $kendo-color-secondary. Used to provide contrast between the background and foreground colors.
kendo-color-tertiarymaterial-color($tertiary-palette, main) #00695cDefault: material-color($tertiary-palette, main)Computed: #00695c
Description: The tertiary color of the theme.
kendo-color-tertiary-contrastmaterial-color($tertiary-palette, main-contrast) whiteDefault: material-color($tertiary-palette, main-contrast)Computed: white
Description: The color used along with the tertiary color denoted by $kendo-color-tertiary. Used to provide contrast between the background and foreground colors.
kendo-color-info #0058e9 #0058e9Default: #0058e9Computed: #0058e9
Description: The color for informational messages and states.
kendo-color-success #37b400 #37b400Default: #37b400Computed: #37b400
Description: The color for success messages and states.
kendo-color-warning #ffc000 #ffc000Default: #ffc000Computed: #ffc000
Description: The color for warning messages and states.
kendo-color-error #f31700 #f31700Default: #f31700Computed: #f31700
Description: The color for error messages and states.
kendo-color-darkget-base-hue( gray, 800 ) #424242Default: get-base-hue( gray, 800 )Computed: #424242
Description: The dark color of the theme.
kendo-color-lightget-base-hue( gray, 100 ) #f5f5f5Default: get-base-hue( gray, 100 )Computed: #f5f5f5
Description: The light color of the theme.
kendo-color-inverseif( $kendo-is-dark-theme, $kendo-color-light, $kendo-color-dark ) #424242Default: if( $kendo-is-dark-theme, $kendo-color-light, $kendo-color-dark )Computed: #424242
Description: Inverse color of the theme. Depending on the theme luminance dark or light, it will be light or dark

Charts Variables

The Chart Sass variables are specific to the Chart UI component. They do not affect other components.

VariableDefault ValueComputed ValueValue
kendo-series-aif($kendo-enable-color-system, k-color( series-a ), get-base-hue( purple, 500 )) #9c27b0Default: if($kendo-enable-color-system, k-color( series-a ), get-base-hue( purple, 500 ))Computed: #9c27b0
Description: The first base series color and its light and dark shades.
kendo-series-bif($kendo-enable-color-system, k-color( series-b ), get-base-hue( blue, 500 )) #2196f3Default: if($kendo-enable-color-system, k-color( series-b ), get-base-hue( blue, 500 ))Computed: #2196f3
Description: The second base series color and its light and dark shades.
kendo-series-cif($kendo-enable-color-system, k-color( series-c ), get-base-hue( teal, 500 )) #009688Default: if($kendo-enable-color-system, k-color( series-c ), get-base-hue( teal, 500 ))Computed: #009688
Description: The third base series color and its light and dark shades.
kendo-series-dif($kendo-enable-color-system, k-color( series-d ), get-base-hue( yellow, 500 )) #ffeb3bDefault: if($kendo-enable-color-system, k-color( series-d ), get-base-hue( yellow, 500 ))Computed: #ffeb3b
Description: The fourth base series color and its light and dark shades.
kendo-series-eif($kendo-enable-color-system, k-color( series-e ), get-base-hue( red, 500 )) #f44336Default: if($kendo-enable-color-system, k-color( series-e ), get-base-hue( red, 500 ))Computed: #f44336
Description: The fifth base series color and its light and dark shades.
kendo-series-fif($kendo-enable-color-system, k-color( series-f ), get-base-hue( green, 500 )) #4caf50Default: if($kendo-enable-color-system, k-color( series-f ), get-base-hue( green, 500 ))Computed: #4caf50
Description: The sixth base series color and its light and dark shades.
kendo-series-1$kendo-series-a #9c27b0Default: $kendo-series-aComputed: #9c27b0
Description: The series colors in order: base, light, dark, lighter, darker
kendo-chart-major-linesrgba( if($kendo-enable-color-system, k-color( on-app-surface, true ), if( $kendo-is-dark-theme, $kendo-color-white, $kendo-color-black )), .08 ) rgba(0, 0, 0, 0.08)Default: rgba( if($kendo-enable-color-system, k-color( on-app-surface, true ), if( $kendo-is-dark-theme, $kendo-color-white, $kendo-color-black )), .08 )Computed: rgba(0, 0, 0, 0.08)
Description: The color of the Chart grid lines (major).
kendo-chart-minor-linesrgba( if($kendo-enable-color-system, k-color( on-app-surface, true ), if( $kendo-is-dark-theme, $kendo-color-white, $kendo-color-black )), .04 ) rgba(0, 0, 0, 0.04)Default: rgba( if($kendo-enable-color-system, k-color( on-app-surface, true ), if( $kendo-is-dark-theme, $kendo-color-white, $kendo-color-black )), .04 )Computed: rgba(0, 0, 0, 0.04)
Description: The color of the Chart grid lines (minor).