Bug in text default colour

There appears to be a bug in the Text control’s default colour value when adding it to Views and Dialogs.

If I add a text control on a drawer and leave the colour property empty, then it will default to the primary text colour defined in the theme, which is what I would expect.
However, if I do the same and add a text control to either a dialog or a view, then the default colour will be plain black, even though we have defined another colour in our theme. Would be great if this could default to primary text colour as well :slight_smile:

Hi,

Can you specify what you mean by “text control” color?

If I understand your problem correctly the color you set as the primary text color in the theme is not being updated in dialogs and views, but defaults to black. If this is the case, I have not managed to recreate the bug, but would be great with some more context to understand your problem better.

If you can provide some screenshots to show what happens that would be useful :slight_smile:

Yes, you are correct! I meant the Text UI Component - Control is the name from Power Apps, so was a slight mix up on my part.

That is strange, I will add some screenshots.
I have set my theme primary colour to signal red to make it easier to spot the difference:

image

When I add the Text UI Component to a view, it automatically becomes black unless I override the colour manually:
image

However, when adding it inside a drawer, it automatically adopts the primary colour:
image

Hope this isn’t something that is just happening in our solution

Interesting. I think I discovered the problem here.

This appears if you have given your view/container a background color “manually.” In other words, when not adopting the default background color set by the theme, the color of the text will change to either black or white, depending on which best contrasts with the background.

I am not sure if this is on purpose, but I will report the case. I recommend that you either use the default background color or manually change the color of the text.

Hope this solves your issue!

Actually, what you can do is add a color to the specific text you are using in the theme. This will always overwrite the text color.

1 Like

Amazing, thanks for the tip! :smiley: