From 6e534d754362e63425b84a49e56860db3e51c935 Mon Sep 17 00:00:00 2001 From: Dmitriy Novash Date: Tue, 30 Apr 2024 15:54:28 +0300 Subject: [PATCH] fix display of tables with a large number of rows --- client/components/settings/adminReports.jade | 114 ++++++++++-------- client/components/settings/peopleBody.jade | 20 +-- client/components/settings/settingBody.css | 4 + .../components/settings/translationBody.jade | 3 +- 4 files changed, 80 insertions(+), 61 deletions(-) diff --git a/client/components/settings/adminReports.jade b/client/components/settings/adminReports.jade index 5fc99f0b5..955709ef8 100644 --- a/client/components/settings/adminReports.jade +++ b/client/components/settings/adminReports.jade @@ -58,18 +58,20 @@ template(name="rulesReport") h1 {{_ 'rulesReportTitle'}} if resultsCount table - tr - th Rule Title - th Board Title - th actionType - th activityType + thead + tr + th Rule Title + th Board Title + th actionType + th activityType each rule in results - tr - td {{ rule.title }} - td {{ rule.boardTitle }} - td {{ rule.action.actionType }} - td {{ rule.trigger.activityType }} + tbody + tr + td {{ rule.title }} + td {{ rule.boardTitle }} + td {{ rule.action.actionType }} + td {{ rule.trigger.activityType }} else div {{_ 'no-results' }} @@ -77,22 +79,24 @@ template(name="filesReport") h1 {{_ 'filesReportTitle'}} if resultsCount table - tr - th Filename - th.right Size (kB) - th MIME Type - th Attachment ID - th Board ID - th Card ID + thead + tr + th Filename + th.right Size (kB) + th MIME Type + th Attachment ID + th Board ID + th Card ID each att in results - tr - td {{ att.name }} - td.right {{ fileSize att.size }} - td {{ att.type }} - td {{ att._id }} - td {{ att.meta.boardId }} - td {{ att.meta.cardId }} + tbody + tr + td {{ att.name }} + td.right {{ fileSize att.size }} + td {{ att.type }} + td {{ att._id }} + td {{ att.meta.boardId }} + td {{ att.meta.cardId }} else div {{_ 'no-results' }} @@ -100,22 +104,24 @@ template(name="cardsReport") h1 {{_ 'cardsReportTitle'}} if resultsCount table.table - tr - th Card Title - th Board - th Swimlane - th List - th Members - th Assignees + thead + tr + th Card Title + th Board + th Swimlane + th List + th Members + th Assignees each card in results - tr - td {{abbreviate card.title }} - td {{abbreviate card.board.title }} - td {{abbreviate card.swimlane.title }} - td {{abbreviate card.list.title }} - td {{userNames card.members }} - td {{userNames card.assignees }} + tbody + tr + td {{abbreviate card.title }} + td {{abbreviate card.board.title }} + td {{abbreviate card.swimlane.title }} + td {{abbreviate card.list.title }} + td {{userNames card.members }} + td {{userNames card.assignees }} else div {{_ 'no-results' }} @@ -123,22 +129,24 @@ template(name="boardsReport") h1 {{_ 'boardsReportTitle'}} if resultsCount table.table - tr - th Title - th Id - th Permission - th Archived? - th Members - th Organizations - th Teams + thead + tr + th Title + th Id + th Permission + th Archived? + th Members + th Organizations + th Teams each board in results - tr - td {{abbreviate board.title }} - td {{abbreviate board._id }} - td {{ board.permission }} - td - = yesOrNo(board.archived) - td {{userNames board.members }} + tbody + tr + td {{abbreviate board.title }} + td {{abbreviate board._id }} + td {{ board.permission }} + td + = yesOrNo(board.archived) + td {{userNames board.members }} else div {{_ 'no-results' }} diff --git a/client/components/settings/peopleBody.jade b/client/components/settings/peopleBody.jade index 2e4fe5021..eca5eeab5 100644 --- a/client/components/settings/peopleBody.jade +++ b/client/components/settings/peopleBody.jade @@ -73,7 +73,7 @@ template(name="people") template(name="orgGeneral") table - tbody + thead tr th {{_ 'displayName'}} th {{_ 'description'}} @@ -84,12 +84,14 @@ template(name="orgGeneral") th {{_ 'active'}} th +newOrgRow - each org in orgList - +orgRow(orgId=org._id) + tbody + tr + each org in orgList + +orgRow(orgId=org._id) template(name="teamGeneral") table - tbody + thead tr th {{_ 'displayName'}} th {{_ 'description'}} @@ -99,14 +101,16 @@ template(name="teamGeneral") th {{_ 'active'}} th +newTeamRow - each team in teamList - +teamRow(teamId=team._id) + tbody + tr + each team in teamList + +teamRow(teamId=team._id) template(name="peopleGeneral") #divAddOrRemoveTeamContainer +modifyTeamsUsers table - tbody + thead tr th +selectAllUser @@ -124,6 +128,8 @@ template(name="peopleGeneral") th {{_ 'teams'}} th +newUserRow + tbody + tr each user in peopleList +peopleRow(userId=user._id) diff --git a/client/components/settings/settingBody.css b/client/components/settings/settingBody.css index 11abe1d6d..aceef5186 100644 --- a/client/components/settings/settingBody.css +++ b/client/components/settings/settingBody.css @@ -7,11 +7,13 @@ display: -moz-flex; display: -ms-flexbox; display: flex; + height: 100%; } .setting-content { color: #727479; background: #dedede; width: 100%; + height: 100%; position: absolute; } .setting-content .content-title { @@ -56,6 +58,8 @@ -moz-user-select: text; -ms-user-select: text; user-select: text; + max-height: 100%; + overflow: auto; } .setting-content .content-body .main-body ul li { padding: 0.5rem 0.5rem; diff --git a/client/components/settings/translationBody.jade b/client/components/settings/translationBody.jade index 073207bde..46d41d011 100644 --- a/client/components/settings/translationBody.jade +++ b/client/components/settings/translationBody.jade @@ -34,13 +34,14 @@ template(name="translation") template(name="translationGeneral") table - tbody + thead tr th {{_ 'language'}} th {{_ 'text'}} th {{_ 'translation-text'}} th +newTranslationRow + tbody each translation in translationList +translationRow(translationId=translation._id)