Skip to main content
Version: v2.x



A default theme is provided with NLUX, as well as a sophisticated theming system that allows you to create your own themes.

Theme Id

A theme ID can be provided to AiChat as part of displayOptions to define the theme to use.
If not present, the default nova theme will be used.

<AiChat displayOptions={{
themeId: 'nova'
}} />

Color Scheme

The color scheme of the theme can be set to light, dark, or auto using the colorScheme property in displayOptions.
If not present, auto will be used and the theme will switch between light and dark modes based on the user's system preferences.

You can override the color scheme by setting colorScheme as follows:

<AiChat displayOptions={{
colorScheme: 'dark'
}} />


The CSS for the theme being used should also be imported into the project, or included as part of the build process. For NLUX standard themes, the CSS can be imported from the @nlux/themes package.

Here is an example of how to import the CSS for the nova theme, in a project that supports CSS imports:

import '@nlux/themes/nova.css';

Themes Available

Default Theme

The default theme that comes with NLUX v2.x is called nova. It's available in both light and dark modes and supports all the features of NLUX, such as bubble vs list layout, custom renderers, and more.

Nova Theme Overview

In order to use the nova theme, you can import the CSS file from the @nlux/themes package:

import '@nlux/themes/nova.css';

And you don't have to provide a theme ID to AiChat.

Legacy Theme

The legacy theme that comes with NLUX v1.x is called luna. It's a simple theme that only supports light mode.
It's provided for backwards compatibility with projects that were using NLUX v1.x, and it will be deprecated in the future.

Nova Theme Overview

In order to use the luna theme, you can import the CSS file from the @nlux/themes package:

import '@nlux/themes/luna.css';

And you have to provide the theme ID luna to AiChat:

<AiChat displayOptions={{
themeId: 'luna'
}} />