From f35ac3d95f3c775faea6327d0edac3880112024c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Adina=20=C8=9Aeudan?= Date: Tue, 24 Nov 2020 23:18:39 +0200 Subject: [PATCH] UI updates --- .../file-actions/file-actions.component.html | 2 +- .../initials-avatar.component.ts | 3 +++ .../annotation-icon.component.scss | 1 + .../chevron-button.component.scss | 3 +-- .../circle-button.component.html | 1 + .../circle-button.component.scss | 6 +++++ .../circle-button/circle-button.component.ts | 1 + .../user-button/user-button.component.html | 2 +- .../user-button/user-button.component.scss | 3 +-- .../table-col-name.component.scss | 2 +- .../type-filter/type-filter.component.scss | 2 +- .../file-preview-screen.component.html | 5 +++- .../file-preview-screen.component.scss | 6 ++--- .../project-listing-details.component.html | 4 ++- .../project-listing-details.component.scss | 10 +++++-- .../project-listing-screen.component.html | 2 +- .../project-listing-screen.component.scss | 6 +++-- .../project-details.component.html | 27 ++++++++++++++----- .../project-details.component.scss | 1 - .../project-overview-screen.component.html | 3 +-- .../project-overview-screen.component.scss | 21 +++++++++++++++ .../project-overview-screen.component.ts | 2 +- apps/red-ui/src/assets/i18n/en.json | 10 ++++--- .../src/assets/icons/general/download.svg | 23 +++------------- .../src/assets/icons/general/refresh.svg | 27 ++++++------------- .../src/assets/styles/red-components.scss | 9 +++++++ apps/red-ui/src/assets/styles/red-grid.scss | 6 +++-- apps/red-ui/src/assets/styles/red-menu.scss | 2 ++ .../src/assets/styles/red-page-layout.scss | 4 --- apps/red-ui/src/assets/styles/red-tables.scss | 4 +-- 30 files changed, 119 insertions(+), 79 deletions(-) mode change 100755 => 100644 apps/red-ui/src/assets/icons/general/download.svg diff --git a/apps/red-ui/src/app/common/file-actions/file-actions.component.html b/apps/red-ui/src/app/common/file-actions/file-actions.component.html index e0a6fc4dc..0df3d294f 100644 --- a/apps/red-ui/src/app/common/file-actions/file-actions.component.html +++ b/apps/red-ui/src/app/common/file-actions/file-actions.component.html @@ -44,7 +44,7 @@ (action)="assignReviewer($event, fileStatus)" *ngIf="permissionsService.canAssignReviewer(fileStatus)" [tooltipPosition]="tooltipPosition" - tooltip="project-overview.assign.action" + [tooltip]="permissionsService.isManagerAndOwner() ? 'project-overview.assign' : 'project-overview.assign-me'" [icon]="permissionsService.isManagerAndOwner() ? 'red:assign' : 'red-assign-me'" [type]="buttonType" > diff --git a/apps/red-ui/src/app/common/initials-avatar/initials-avatar.component.ts b/apps/red-ui/src/app/common/initials-avatar/initials-avatar.component.ts index f35d6db32..927d596de 100644 --- a/apps/red-ui/src/app/common/initials-avatar/initials-avatar.component.ts +++ b/apps/red-ui/src/app/common/initials-avatar/initials-avatar.component.ts @@ -49,6 +49,9 @@ export class InitialsAvatarComponent implements OnInit, OnChanges { } public get colorClass() { + if (this._userService.userId === this.userId) { + return 'red-white'; + } if (this.color.includes('-')) { return this.color; } diff --git a/apps/red-ui/src/app/components/annotation-icon/annotation-icon.component.scss b/apps/red-ui/src/app/components/annotation-icon/annotation-icon.component.scss index a04e54e21..754a6ca5d 100644 --- a/apps/red-ui/src/app/components/annotation-icon/annotation-icon.component.scss +++ b/apps/red-ui/src/app/components/annotation-icon/annotation-icon.component.scss @@ -19,6 +19,7 @@ transform: scale(0.8) rotate(45deg); span { + font-size: 9px; transform: scale(1.6) rotate(-45deg); } } diff --git a/apps/red-ui/src/app/components/buttons/chevron-button/chevron-button.component.scss b/apps/red-ui/src/app/components/buttons/chevron-button/chevron-button.component.scss index efc59ac7f..d92b062a9 100644 --- a/apps/red-ui/src/app/components/buttons/chevron-button/chevron-button.component.scss +++ b/apps/red-ui/src/app/components/buttons/chevron-button/chevron-button.component.scss @@ -2,7 +2,6 @@ button { padding: 0 10px 0 14px; mat-icon { - width: 7px; - margin: 0 3.5px; + width: 14px; } } diff --git a/apps/red-ui/src/app/components/buttons/circle-button/circle-button.component.html b/apps/red-ui/src/app/components/buttons/circle-button/circle-button.component.html index 5ec714b6f..4743f6ed0 100644 --- a/apps/red-ui/src/app/components/buttons/circle-button/circle-button.component.html +++ b/apps/red-ui/src/app/components/buttons/circle-button/circle-button.component.html @@ -5,6 +5,7 @@ [class.primary]="type === 'primary'" [class.warn]="type === 'warn'" [disabled]="disabled" + [class.small]="small" mat-icon-button > diff --git a/apps/red-ui/src/app/components/buttons/circle-button/circle-button.component.scss b/apps/red-ui/src/app/components/buttons/circle-button/circle-button.component.scss index 9f927a1ae..d63b4b056 100644 --- a/apps/red-ui/src/app/components/buttons/circle-button/circle-button.component.scss +++ b/apps/red-ui/src/app/components/buttons/circle-button/circle-button.component.scss @@ -5,6 +5,12 @@ button { width: 34px; line-height: 34px; + &.small { + height: 32px; + width: 32px; + line-height: 32px; + } + mat-icon { width: 14px; } diff --git a/apps/red-ui/src/app/components/buttons/circle-button/circle-button.component.ts b/apps/red-ui/src/app/components/buttons/circle-button/circle-button.component.ts index d9d067a0f..ee2280b3c 100644 --- a/apps/red-ui/src/app/components/buttons/circle-button/circle-button.component.ts +++ b/apps/red-ui/src/app/components/buttons/circle-button/circle-button.component.ts @@ -11,6 +11,7 @@ export class CircleButtonComponent implements OnInit { @Input() tooltipPosition: 'above' | 'below' | 'before' | 'after' = 'above'; @Input() tooltipClass: string; @Input() disabled = false; + @Input() small = false; @Input() type: 'default' | 'primary' | 'warn' | 'dark-bg' = 'default'; @Output() action = new EventEmitter(); diff --git a/apps/red-ui/src/app/components/buttons/user-button/user-button.component.html b/apps/red-ui/src/app/components/buttons/user-button/user-button.component.html index 2aaa65363..96be18c96 100644 --- a/apps/red-ui/src/app/components/buttons/user-button/user-button.component.html +++ b/apps/red-ui/src/app/components/buttons/user-button/user-button.component.html @@ -1,4 +1,4 @@ diff --git a/apps/red-ui/src/app/components/buttons/user-button/user-button.component.scss b/apps/red-ui/src/app/components/buttons/user-button/user-button.component.scss index 1da22f3b7..b91354af0 100644 --- a/apps/red-ui/src/app/components/buttons/user-button/user-button.component.scss +++ b/apps/red-ui/src/app/components/buttons/user-button/user-button.component.scss @@ -10,8 +10,7 @@ } mat-icon { - width: 7px; - margin: 0 3.5px; + width: 14px; } } diff --git a/apps/red-ui/src/app/components/table-col-name/table-col-name.component.scss b/apps/red-ui/src/app/components/table-col-name/table-col-name.component.scss index db3f92bf2..24380c470 100644 --- a/apps/red-ui/src/app/components/table-col-name/table-col-name.component.scss +++ b/apps/red-ui/src/app/components/table-col-name/table-col-name.component.scss @@ -10,7 +10,7 @@ display: flex; font-weight: 600; gap: 8px; - padding: 8px 16px; + padding: 8px 24px; } .sort-arrows-container { diff --git a/apps/red-ui/src/app/components/type-filter/type-filter.component.scss b/apps/red-ui/src/app/components/type-filter/type-filter.component.scss index be9b54e1a..a5827e8f2 100644 --- a/apps/red-ui/src/app/components/type-filter/type-filter.component.scss +++ b/apps/red-ui/src/app/components/type-filter/type-filter.component.scss @@ -2,5 +2,5 @@ display: flex; justify-content: center; align-items: center; - gap: 4px; + gap: 8px; } diff --git a/apps/red-ui/src/app/screens/file/file-preview-screen/file-preview-screen.component.html b/apps/red-ui/src/app/screens/file/file-preview-screen/file-preview-screen.component.html index fa0022e55..fa0a5a6a6 100644 --- a/apps/red-ui/src/app/screens/file/file-preview-screen/file-preview-screen.component.html +++ b/apps/red-ui/src/app/screens/file/file-preview-screen/file-preview-screen.component.html @@ -129,7 +129,10 @@ >
- {{ activeViewerPage }} + {{ activeViewerPage }} - {{ displayedAnnotations[activeViewerPage]?.annotations?.length || 0 }} +
diff --git a/apps/red-ui/src/app/screens/file/file-preview-screen/file-preview-screen.component.scss b/apps/red-ui/src/app/screens/file/file-preview-screen/file-preview-screen.component.scss index 43fa82073..94c6eed1f 100644 --- a/apps/red-ui/src/app/screens/file/file-preview-screen/file-preview-screen.component.scss +++ b/apps/red-ui/src/app/screens/file/file-preview-screen/file-preview-screen.component.scss @@ -76,11 +76,11 @@ redaction-pdf-viewer { .page-separator { border-bottom: 1px solid $separator; - height: 40px; + height: 32px; box-sizing: border-box; - padding: 8px 10px; + padding: 0 10px; display: flex; - align-items: flex-end; + align-items: center; background-color: $grey-6; } diff --git a/apps/red-ui/src/app/screens/project-listing-screen/project-listing-details/project-listing-details.component.html b/apps/red-ui/src/app/screens/project-listing-screen/project-listing-details/project-listing-details.component.html index ee6dcd1e0..a4c2073f8 100644 --- a/apps/red-ui/src/app/screens/project-listing-screen/project-listing-details/project-listing-details.component.html +++ b/apps/red-ui/src/app/screens/project-listing-screen/project-listing-details/project-listing-details.component.html @@ -2,12 +2,13 @@
- +
{{ totalPages | number }}
@@ -27,6 +28,7 @@ div { display: flex; + flex: 1; flex-direction: column; align-items: center; + padding-top: 50px; + + &:first-child { + border-right: 1px solid $separator; + } .project-stats-container { - width: fit-content; - .project-stats-item { display: flex; width: fit-content; diff --git a/apps/red-ui/src/app/screens/project-listing-screen/project-listing-screen.component.html b/apps/red-ui/src/app/screens/project-listing-screen/project-listing-screen.component.html index 006e86cf7..ee2c62b7f 100644 --- a/apps/red-ui/src/app/screens/project-listing-screen/project-listing-screen.component.html +++ b/apps/red-ui/src/app/screens/project-listing-screen/project-listing-screen.component.html @@ -63,7 +63,7 @@ [class.pointer]="canOpenProject(pw)" >
-
+
{{ pw.project.projectName }}
diff --git a/apps/red-ui/src/app/screens/project-listing-screen/project-listing-screen.component.scss b/apps/red-ui/src/app/screens/project-listing-screen/project-listing-screen.component.scss index 218ff3640..df804a69e 100644 --- a/apps/red-ui/src/app/screens/project-listing-screen/project-listing-screen.component.scss +++ b/apps/red-ui/src/app/screens/project-listing-screen/project-listing-screen.component.scss @@ -1,4 +1,5 @@ @import '../../../assets/styles/red-mixins'; +@import '../../../assets/styles/red-variables'; .left-container { width: calc(100vw - #{$right-container-width} - 90px); @@ -18,6 +19,7 @@ .right-fixed-container { display: flex; - width: 430px; - padding-top: 50px; + width: calc(430px + 2 * #{$right-container-horizontal-padding}); + height: calc(100vh - 110px); + padding: 0; } diff --git a/apps/red-ui/src/app/screens/project-overview-screen/project-details/project-details.component.html b/apps/red-ui/src/app/screens/project-overview-screen/project-details/project-details.component.html index a944e3bfe..664f65a7f 100644 --- a/apps/red-ui/src/app/screens/project-overview-screen/project-details/project-details.component.html +++ b/apps/red-ui/src/app/screens/project-overview-screen/project-details/project-details.component.html @@ -5,7 +5,12 @@
- +
@@ -13,14 +18,22 @@
- +
+{{ overflowCount }}
-
-
+
-
+ + + + +
@@ -29,7 +42,7 @@ (toggleFilter)="toggleFilter('statusFilters', $event)" [config]="translateChartService.translateStatus(documentsChartData)" [filter]="filters.statusFilters" - [radius]="70" + [radius]="63" [strokeWidth]="15" [subtitle]="'project-overview.project-details.charts.documents-in-project'" direction="row" @@ -71,7 +84,7 @@
-
+
{{ appStateService.activeProject.project.description }}
diff --git a/apps/red-ui/src/app/screens/project-overview-screen/project-details/project-details.component.scss b/apps/red-ui/src/app/screens/project-overview-screen/project-details/project-details.component.scss index 5d103ffd2..5b557b11c 100644 --- a/apps/red-ui/src/app/screens/project-overview-screen/project-details/project-details.component.scss +++ b/apps/red-ui/src/app/screens/project-overview-screen/project-details/project-details.component.scss @@ -12,7 +12,6 @@ > div { display: flex; - gap: 8px; align-items: center; border-radius: 4px; cursor: pointer; diff --git a/apps/red-ui/src/app/screens/project-overview-screen/project-overview-screen.component.html b/apps/red-ui/src/app/screens/project-overview-screen/project-overview-screen.component.html index 3fdee5740..89952af01 100644 --- a/apps/red-ui/src/app/screens/project-overview-screen/project-overview-screen.component.html +++ b/apps/red-ui/src/app/screens/project-overview-screen/project-overview-screen.component.html @@ -164,7 +164,7 @@
-
+
{{ fileStatus.filename }} @@ -213,7 +213,6 @@ class="mr-4" > - - - - - - - - - - - - - + + download + + - diff --git a/apps/red-ui/src/assets/icons/general/refresh.svg b/apps/red-ui/src/assets/icons/general/refresh.svg index 51cc16f7b..018632553 100644 --- a/apps/red-ui/src/assets/icons/general/refresh.svg +++ b/apps/red-ui/src/assets/icons/general/refresh.svg @@ -1,20 +1,9 @@ - - - - - + + + reanalyse + + + + + diff --git a/apps/red-ui/src/assets/styles/red-components.scss b/apps/red-ui/src/assets/styles/red-components.scss index b0c7112e9..5a48d3531 100644 --- a/apps/red-ui/src/assets/styles/red-components.scss +++ b/apps/red-ui/src/assets/styles/red-components.scss @@ -21,6 +21,15 @@ font-size: 13px; } + &.gray-dark { + background-color: $grey-6; + } + + &.gray-red { + background-color: $grey-6; + color: $red-1; + } + &.lightgray-dark { background-color: $grey-4; } diff --git a/apps/red-ui/src/assets/styles/red-grid.scss b/apps/red-ui/src/assets/styles/red-grid.scss index 0f2dc749c..416046ea9 100644 --- a/apps/red-ui/src/assets/styles/red-grid.scss +++ b/apps/red-ui/src/assets/styles/red-grid.scss @@ -3,13 +3,15 @@ .header-item { background-color: $grey-6; height: 50px; - padding: 0 16px; + padding: 0 24px; display: flex; align-items: center; z-index: 1; position: sticky; top: 50px; - gap: 16px; + gap: 10px; + border-bottom: 1px solid $separator; + box-sizing: border-box; .actions { display: flex; diff --git a/apps/red-ui/src/assets/styles/red-menu.scss b/apps/red-ui/src/assets/styles/red-menu.scss index eda490c58..a08b46ba5 100644 --- a/apps/red-ui/src/assets/styles/red-menu.scss +++ b/apps/red-ui/src/assets/styles/red-menu.scss @@ -4,6 +4,8 @@ border-radius: 8px !important; box-shadow: 0 2px 6px 0 rgba(40, 50, 65, 0.3); max-width: none !important; + min-width: 180px !important; + margin-top: 4px; .mat-menu-item { font-family: 'Inter', sans-serif; diff --git a/apps/red-ui/src/assets/styles/red-page-layout.scss b/apps/red-ui/src/assets/styles/red-page-layout.scss index 1782fe506..c3f2516c8 100644 --- a/apps/red-ui/src/assets/styles/red-page-layout.scss +++ b/apps/red-ui/src/assets/styles/red-page-layout.scss @@ -48,9 +48,6 @@ body { .right-fixed-container { border-left: 1px solid $grey-4; background: $white; - height: calc(100vh - 110px - 2 * #{$right-container-vertical-padding}); - width: $right-container-inside-width; - padding: $right-container-vertical-padding $right-container-horizontal-padding; position: fixed; right: 0; z-index: 2; @@ -83,7 +80,6 @@ body { .left-container { height: calc(100vh - 61px - 50px); - width: calc(100vw - #{$right-container-width}); } .break-20 { diff --git a/apps/red-ui/src/assets/styles/red-tables.scss b/apps/red-ui/src/assets/styles/red-tables.scss index 20354ada4..58d592ca6 100644 --- a/apps/red-ui/src/assets/styles/red-tables.scss +++ b/apps/red-ui/src/assets/styles/red-tables.scss @@ -42,7 +42,7 @@ redaction-table-col-name, > div { height: 80px; border-bottom: 1px solid $separator; - padding: 0 16px; + padding: 0 24px; } .action-buttons { @@ -55,7 +55,7 @@ redaction-table-col-name, flex-direction: row; align-items: center; padding-left: 100px; - padding-right: 8px; + padding-right: 24px; background: linear-gradient(to right, rgba(244, 245, 247, 0) 0%, #f4f5f7 35%); mat-icon {