From 93d4bc5120584d236628cad30170f4d55446cc56 Mon Sep 17 00:00:00 2001 From: Andrii V Date: Mon, 16 Feb 2026 12:45:08 +0100 Subject: [PATCH] Cleanup, better handling for multiline comments in full commit view --- rhodecode/public/css/tables.less | 4 ++++ rhodecode/public/js/src/rhodecode/changelog.js | 12 +++++++++--- 2 files changed, 13 insertions(+), 3 deletions(-) diff --git a/rhodecode/public/css/tables.less b/rhodecode/public/css/tables.less index 24193123..9044342a 100644 --- a/rhodecode/public/css/tables.less +++ b/rhodecode/public/css/tables.less @@ -514,6 +514,10 @@ table.trending_language_tbl { padding-right: 0; cursor: pointer; width: 20px; + + &.open { + vertical-align: top; + } } } } diff --git a/rhodecode/public/js/src/rhodecode/changelog.js b/rhodecode/public/js/src/rhodecode/changelog.js index e831da01..6cf62b41 100644 --- a/rhodecode/public/js/src/rhodecode/changelog.js +++ b/rhodecode/public/js/src/rhodecode/changelog.js @@ -107,8 +107,12 @@ var CommitsController = function () { $('#graph_nodes').css({'padding-top': padding}); $.each($('.message.truncate'), function(idx, value) { + var expandTd = $(this).closest('td').siblings('.expand_commit'); + // Skip expanded commits — their overflow is visible so width comparison is invalid + if (expandTd.hasClass('open')) { + return; + } if(!(value.offsetWidth < value.scrollWidth)){ - var expandTd = $(this).closest('td').siblings('.expand_commit'); expandTd.find('i').hide(); expandTd.removeAttr('title'); expandTd.removeClass('expand_commit'); @@ -176,7 +180,8 @@ var CommitsController = function () { 'height': '1.5em', 'white-space': 'nowrap', 'text-overflow': 'ellipsis', - 'overflow': 'hidden' + 'overflow': 'hidden', + 'overflow-wrap': 'normal' }); $('#t-' + cid).css({ 'height': 'auto', @@ -192,7 +197,8 @@ var CommitsController = function () { 'height': 'auto', 'white-space': 'pre-line', 'text-overflow': 'initial', - 'overflow': 'visible' + 'overflow': 'visible', + 'overflow-wrap': 'break-word' }); $('#t-' + cid).css({ 'height': 'auto',