Remove logic of the topic truncation and fix the docs

This commit is contained in:
GogoVega 2024-11-25 21:45:00 +01:00
parent 3a27a756cc
commit 6a13d2d544
No known key found for this signature in database
GPG Key ID: E1E048B63AC5AC2B
2 changed files with 7 additions and 8 deletions

View File

@ -134,11 +134,14 @@ RED.utils = (function() {
}
/**
* Truncates a string to a specified maximum length, adding ellipsis if truncated.
* Truncates a string to a specified maximum length, adding ellipsis
* if truncated.
*
* @param {string} str - The string to be truncated.
* @param {number} maxLength - The maximum length of the truncated string. Default `120`.
* @returns {string} The truncated string with ellipsis if it exceeds the maximum length.
* @param {string} str The string to be truncated.
* @param {number} [maxLength = 120] The maximum length of the truncated
* string. Default `120`.
* @returns {string} The truncated string with ellipsis if it exceeds the
* maximum length.
*/
function truncateString(str, maxLength = 120) {
return str.length > maxLength ? str.slice(0, maxLength) + "..." : str;

View File

@ -131,10 +131,6 @@
}
.red-ui-debug-msg-topic {
display: block;
max-width: 100%;
overflow: hidden;
white-space: nowrap;
text-overflow: ellipsis;
color: var(--red-ui-debug-message-text-color-meta);
}
.red-ui-debug-msg-name {