Generally, you can use the default theme to create a dashboard. However, there may be situations where you may need a customized view of a particular dashboard, and need to maintain different custom themes per dashboard. In such situations, you can create your own custom theme and apply it to a particular dashboard.
Creating a custom theme for a specific dashboard
Follow the instructions below to create a custom theme for a specific dashboard:
Create a custom theme file.
Create a custom theme file as a Carbon archive file, which has the
dashboards/themeas the artifact type of the theme file.
For example, the
artifact.xmlfile for a custom theme is as follows:
The folder structure for the custom theme file is as follows:
cssfolder can contain any stylesheets with the
.cssextension. However, the
templatefolders should contain the files defined in the above structure.
Deploy the custom theme.
Sign into the WSO2 Data Analytics Server (WSO2 DAS) Management Console.
- Click Main, navigate to Carbon Application and click Add.
- Select the Carbon Application Artifact (
.car) file and upload it.
The uploaded custom theme appears as follows:
Applying the custom theme to a dashboard
You can use one of the following methods to apply your custom theme to a specific dashboard.
- When creating a dashboard, you can select the your custom theme.
You can also change the existing theme of a dashboard via the settings view of that respective dashboard.
After creating a custom dashboard theme and applying the theme, you can preview the final view of the dashboard using the dashboard view option.