Edit

Theming

Provides the API for platform-provided modern theming

Available for

Model-driven and canvas apps

Syntax

context.fluentDesignLanguage

Properties

tokenTheme

Fluent v9 theme tokens resolved and provided by the platform. The token values reflect the current app theme. In model-driven apps, supported spacing token values also reflect the current display density.

For implementation guidance, see Style components with modern theming.

Type: Theme

typographyTokens

Fluent v9 typography tokens provided by the platform.

Type: TypographyStyles

brand

Fluent v9 BrandVariants based on which Fluent v9 theme was generated.

Type: BrandVariants

isDarkTheme

Indicates whether the current theme is dark or not.

Type: boolean

Example

const fluentDesignLanguage = props.context.fluentDesignLanguage;

return (
  <FluentProvider theme={props.theme}>
    <Label weight="semibold">{"Theming provided by the control."}</Label>
  </FluentProvider>
);

Sample controls

Modern Theming API control

Use modern themes in canvas apps (preview)
Power Apps component framework API reference
Power Apps component framework overview