To change the nm-applet icon to a dark theme in polybar, you can follow these steps:
-
Open your polybar configuration file. Usually, it is located at
~/.config/polybar/config. -
Find the module section for the nm-applet in the configuration file. It should look something like this:
[module/nm-applet] type = internal/network interface = wlan0 format-connected = <label-connected> format-disconnected = <label-disconnected> label-connected = %essid% %ip% label-disconnected = Disconnected -
Add the
label-connected-foregroundandlabel-disconnected-foregroundoptions to the module section. Set the values to the desired color for the connected and disconnected states. For example:[module/nm-applet] type = internal/network interface = wlan0 format-connected = <label-connected> format-disconnected = <label-disconnected> label-connected = %essid% %ip% label-disconnected = Disconnected label-connected-foreground = #FFFFFF label-disconnected-foreground = #AAAAAAReplace
#FFFFFFand#AAAAAAwith the appropriate color codes for your dark theme. -
Save the configuration file and restart polybar for the changes to take effect.
Now, the nm-applet icon in polybar should be displayed with the dark theme colors you specified.