Help identifying theme item(s)

Hello - I am using a dark theme (dark_teal) and when I change the name of a device, the dialog box looks like the attached. I can barely see the white text in the almost white box. Is it possible to change the text color for just these input boxes? Or if not, is it possible to change the background color so that I can read the text? Can someone please tell me (or better, tell me how to figure out) which items in the theme need to be edited to make this change? Thanks.

You can use developer tools in your browser of choice to select the input field html element and look at the styles it uses.

I found that the background colour for the input boxes uses --mdc-text-field-fill-color and possibly --input-fill-color.

Hopefully this helps!

Thanks very much! I did as you suggest and changed the value of --mdc-text-field-fill-color, which only changed the color of the third input box.

Strangely, the third one (which is picking up the style) is a ha-labels-picker while the first one (which is not picking up the style) is a ha-textfield. I would at least think that the ha-textfield would pick up the text field formatting. I tried changing --mdc-select-fill-color and --input-fill-color in my theme .yaml file, but those made no difference.

I have drilled into those three items in the inspector as much as I can, and for the life of me, I can’t figure out where the fill color of the first two is coming from.

I am kinda stuck here…

I frequently feel the same when trying to card-mod things. Keep trying, it’s always hiding somewhere under Styles.

If you’re really stuck, copy all the styles from the ha-textfieldand paste it into an AI and ask ‘which variable changes the background colour?’. Then copy the variable it gives you and use ctrl+f in dec tools to search for it and test it. Often it picks up the variable we humans scrolled past.

I can’t find it for you unfortunately… as you saw, it worked on mine.

Much appreciated! I will keep drilling… One learns by doing such things, albeit sometimes slowly. I wonder why yours and mine are different. I am on the current version. Maybe you are running an older version?

I’m on 2026.3.3. I always stay one update behind to avoid bugs haha.

Turns out I was NOT on 2026.3.3, I was on 2026.2.3 :woman_facepalming:.

Am now on 2026.4.3 and have the same trouble as you with finding the variable. Something in my theme must cover it though, because mine isn’t funny colours!

Hi again. I found it…
Here’s a short summary as I know others had the same issue.

2026.4.3 mdc input field theme variables

Text fields and dropdowns
--ha-color-form-background
Label fields
--mdc-text-field-fill-color

Other notable ones are

--ha-color-form-background-hover and
--ha-color-form-background-disabled