Hi Pascal,
You can set the colors using the following properties,
To make this dynamic you would have to customize this widget a little like changing these property of the above from ype=”string” to type=”attribute” in the Counter.xml and updating the Counter.js accordingly. Hope this helps, if you are not able to customize it reach out to the dev or raise a request in Git
https://github.com/mendixlabs/Counter/tree/master/src/Counter