Properly truncate system notices (#11714)
* Properly truncate system notices As noted in #11658 the system notifications list will always suffix system notices with ... even when the notice is longer than 120 characters. Instead we should use .text.truncate to auto truncate and make the notices clickable to view their details. Signed-off-by: Andrew Thornton <art27@cantab.net> * As per @CirnoT make table cell clickable * ensure that pre wraps Signed-off-by: Andrew Thornton <art27@cantab.net> Co-authored-by: techknowlogick <techknowlogick@gitea.io>
This commit is contained in:
parent
3af51f1ab7
commit
fe2cacf5ea
3 changed files with 25 additions and 6 deletions
|
@ -1862,7 +1862,8 @@ function initAdmin() {
|
|||
|
||||
// Attach view detail modals
|
||||
$('.view-detail').on('click', function () {
|
||||
$detailModal.find('.content pre').text($(this).data('content'));
|
||||
$detailModal.find('.content pre').text($(this).parents('tr').find('.notice-description').text());
|
||||
$detailModal.find('.sub.header').text($(this).parents('tr').find('.notice-created-time').text());
|
||||
$detailModal.modal('show');
|
||||
return false;
|
||||
});
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue