# Dashboard 'button' label normal/capital text

**URL:** <https://discourse.nodered.org/t/dashboard-button-label-normal-capital-text/77339>\
**Category:** General\
**Tags:** node-red-dashboard\
**Created:** [7 April 2023 13:24 UTC](https://discourse.nodered.org/t/dashboard-button-label-normal-capital-text/77339 "2023-04-07T13:24:11Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![gNeandr](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/gneandr/32/73947_2.png) [@gNeandr](https://discourse.nodered.org/u/gNeandr)\
**Post date:** [7 April 2023 13:24 UTC](https://discourse.nodered.org/t/dashboard-button-label-normal-capital-text/77339/1 "2023-04-07T13:24:11Z")

</div>

The label of a button in the dashboard always seems to use capital letters ... afais!?  
Need to change the 'label' dynamically with {{msg.payload}}. The generated string has "kWh", but the button on the dashboard shows "KWH" ... not nice!  
How do I get it the way it is set with the string?

---

<div class="post-metadata">

**Author:** ![dynamicdave](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/dynamicdave/32/96_2.png) [@dynamicdave](https://discourse.nodered.org/u/dynamicdave)\
**Post date:** [7 April 2023 15:13 UTC](https://discourse.nodered.org/t/dashboard-button-label-normal-capital-text/77339/2 "2023-04-07T15:13:15Z")

</div>

I use a ui-template node with some CSS styling to stop Node-RED from transforming the text.

![dont_transform](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/3X/7/7/77f666a811c3654f87b14161ca23ba1fc7fc6df7.png)

**Set the Template Type to Widget in Group** at the top of the node.

![template](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/3X/d/0/d043d43c87b6d3cc7ed8318e6dc5a19e1d826d0a.png)

Obviously you can leave out .masonary-container part.

This is what the text looks like on a button.  
 ![sample button text](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/3X/d/1/d17a52193ddbc6c52f39009620930eabf6478421.png)

---

<div class="post-metadata">

**Author:** ![gNeandr](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/gneandr/32/73947_2.png) [@gNeandr](https://discourse.nodered.org/u/gNeandr)\
**Post date:** [7 April 2023 17:16 UTC](https://discourse.nodered.org/t/dashboard-button-label-normal-capital-text/77339/3 "2023-04-07T17:16:25Z")

</div>

Yes, the 'ui-template' don't capitalize the text ... also without the extra `<style>`.  
But I need (would like) to display the string on two lines. With the Dashboard button the use of `<br>` will brake to two lines, I didn't found a possibility to break it to two lines with the 'ui-template' and using `<button> </button>` ... which I think is normal with HTML/CSS 🤭

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/1X/d073cd938eafa2e558d7c2cd59003b3ef4963033.png) [@system](https://discourse.nodered.org/u/system)\
**Post date:** [6 June 2023 17:16 UTC](https://discourse.nodered.org/t/dashboard-button-label-normal-capital-text/77339/4 "2023-06-06T17:16:31Z")

</div>

This topic was automatically closed 60 days after the last reply. New replies are no longer allowed.
