# Change md-switch color of default icon

**URL:** <https://discourse.nodered.org/t/change-md-switch-color-of-default-icon/48499>\
**Category:** Dashboard\
**Created:** [16 July 2021 16:48 UTC](https://discourse.nodered.org/t/change-md-switch-color-of-default-icon/48499 "2021-07-16T16:48:41Z")\
**Posts on this page:** 1\
**Showing post:** 22

<div class="post-metadata">

**Author:** ![jbudd](https://avatars.discourse-cdn.com/v4/letter/j/5f8ce5/32.png) [@jbudd](https://discourse.nodered.org/u/jbudd)\
**Post date:** [17 July 2021 11:37 UTC](https://discourse.nodered.org/t/change-md-switch-color-of-default-icon/48499/22 "2021-07-17T11:37:56Z")

</div>

Thanks.  
So the work-around (from Steve-Mcl at [https://discourse.nodered.org/t/dashboard-element-css-classes/46447](https://discourse.nodered.org/t/dashboard-element-css-classes/46447) is to use the node id.  
It's perfectly fine except:  
Unnecessary repetition of CSS to style each element seperately.  
Quite difficult to work out from the node id in the CSS which node in the editor it applies to - node id is (rightfully) largely out of sight.

Alternative 1 - Add a CSS class field to the node properties.  
Ideal for me. dceejay dislikes adding another field for each UI node type.

Alternative 2 - Use the node's Name field as a CSS class.  
Ugly and confusing.

Alternative 3 - There is no alternative 3?

---

_[View the full topic](https://discourse.nodered.org/t/change-md-switch-color-of-default-icon/48499)._
