# Stupid CSS Question

**URL:** <https://discourse.nodered.org/t/stupid-css-question/90488>\
**Category:** General\
**Tags:** dashboard-2\
**Created:** [27 August 2024 18:48 UTC](https://discourse.nodered.org/t/stupid-css-question/90488 "2024-08-27T18:48:34Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![kpmn819](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/kpmn819/32/92062_2.png) [@kpmn819](https://discourse.nodered.org/u/kpmn819)\
**Post date:** [27 August 2024 18:48 UTC](https://discourse.nodered.org/t/stupid-css-question/90488/1 "2024-08-27T18:48:34Z")

</div>

I'm trying to do something that is vexing me. I have a text field that I am feeding a very long string to and I want it to word-wrap. So far I have tried putting this in a ui-template node.

```auto
.word-wrap {
        color: rgb(74, 63, 196);
        white-space: pre-wrap;
        word-wrap: break-word;

    }

```

Which changes the font color but nothing else. Sorry not too familiar with CSS yet.

---

<div class="post-metadata">

**Author:** ![TotallyInformation](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/totallyinformation/32/31_2.png) [@TotallyInformation](https://discourse.nodered.org/u/TotallyInformation)\
**Post date:** [27 August 2024 19:15 UTC](https://discourse.nodered.org/t/stupid-css-question/90488/2 "2024-08-27T19:15:10Z")

</div>

Have you checked whether something more specific means that your CSS is being ignored? You can check in the browser dev tools?

---

<div class="post-metadata">

**Author:** ![kpmn819](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/kpmn819/32/92062_2.png) [@kpmn819](https://discourse.nodered.org/u/kpmn819)\
**Post date:** [28 August 2024 00:11 UTC](https://discourse.nodered.org/t/stupid-css-question/90488/3 "2024-08-28T00:11:43Z")

</div>

Thanks for the suggestion turns out I had to plug in some HTML going into the text node.

```auto
<div style="white-space: pre-wrap; word-wrap: break-word;font-size: 30px;">
    {{msg.payload}}
</div>

```

did it.

---

<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:** [26 November 2024 00:12 UTC](https://discourse.nodered.org/t/stupid-css-question/90488/4 "2024-11-26T00:12:40Z")

</div>

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