issue with long label overlap

Hi,

I know im not the first one to ask that, but i did not find any answers on this forum concerning this issue for the moment.

When you long label for a field (it dont have to be really long, depend of your screen size), the label name is overlaped by the field. I would like to find a way to make the label display on multiple line maybe, or juste move the field more on the right.

The best would be to find a full solution, but if someone know a quick fixe it would be great until this is fixed. Maybe doing modification on how the label is display, like counting how much char there is, and tuning it to do a jump line when the number of char in the label is to hight.

Any idea or link to a way to fix this is what im looking for.

I found a way, but i dont really like it. I directly modify the langage file where the label name is write and put a
where is i think is good. It cant work from the studio because it transforme all special char with the html value (something like ‘<’ is &something).

So im going to fix it like that for the moment. im doing the change in the custom folder and then quick repair.

Hi,

Long label display can be wrapped to multiple lines by customizing the detailview , adding the css code for enable wordwrap on label’s.

Path of file:-
custom/modules/MODULE_NAME/views/view.detail.php

Function to override:-

function PreDisplay() {
echo ’
.detail508 tr td[scope=“col”] {
white-space: inherit;
}
';
parent::PreDisplay();
}
}

here, ‘detail508 tr td[scope=“col”]’ is the class of labels, can find through inspect element(may differ)

This works for me while wrappping the long labels fields on my meetings module,

1 Like

you can try as in style.css – .edit-view-row .label by default white-space:nowrap replace it with white-space:inherit