In today’s article, I would like to share a quick solution i’ve put in place for one of my projects, where the colours keep changing and I wanted to be ready for any theme changes when required.
The different theme colours would be stored in a collection which will be referenced by the different Power Apps controls instead of hard coded.
I have created a simple screen, which allows me to set the different colours such as:
- Button fill,
- Button text,
- Chevron background colour …etc.
I wanted also to view the rendering of the most used controls:
- Text input
The app has one screen only, with two containers:
In the left section, you will be able to set the different colours,
The colours values are expected in Hex format, we will use the ColorValue function to convert the colours to RGBA format.
If you want to learn more about ColorValue, ColorFade and different ways to convert hex to rgba and apply transparency, please visit the Microsoft reference ->
In addition, this panel, will render the collection definition, which you can just copy and paste in your project.
This area is the preview area, it allows you to view and amend the colours if you are not happy with the results.
Download from GitHub
The app code is available from –>