From deaed1b81acc044530fbd45d44e42c25ccf6e3a6 Mon Sep 17 00:00:00 2001 From: Cilibiu Bogdan Date: Wed, 29 Nov 2017 22:34:25 +0200 Subject: [PATCH] [ACA-770] Long file names break the application (#98) --- .../favorites/favorites.component.html | 8 +- src/app/components/files/files.component.html | 6 +- .../libraries/libraries.component.html | 12 +-- .../recent-files/recent-files.component.html | 7 +- .../shared-files/shared-files.component.html | 9 +- .../components/sidenav/sidenav.component.scss | 5 +- .../trashcan/trashcan.component.html | 8 +- src/app/ui/_layout.scss | 4 + .../ui/overrides/_alfresco-document-list.scss | 85 +++++++------------ 9 files changed, 53 insertions(+), 91 deletions(-) diff --git a/src/app/components/favorites/favorites.component.html b/src/app/components/favorites/favorites.component.html index aaf50b5cb..d9ab25982 100644 --- a/src/app/components/favorites/favorites.component.html +++ b/src/app/components/favorites/favorites.component.html @@ -104,12 +104,9 @@ - - {{ value }} - - diff --git a/src/app/components/files/files.component.html b/src/app/components/files/files.component.html index b2b693d66..54cca4ee1 100644 --- a/src/app/components/files/files.component.html +++ b/src/app/components/files/files.component.html @@ -110,12 +110,9 @@ - - {{ value }} - diff --git a/src/app/components/libraries/libraries.component.html b/src/app/components/libraries/libraries.component.html index 076fb6d81..a23bcfc1c 100644 --- a/src/app/components/libraries/libraries.component.html +++ b/src/app/components/libraries/libraries.component.html @@ -37,14 +37,9 @@ - - - {{ makeLibraryTitle(context.row.obj.entry) }} - - + title="APP.DOCUMENT_LIST.COLUMNS.TITLE"> - diff --git a/src/app/components/recent-files/recent-files.component.html b/src/app/components/recent-files/recent-files.component.html index e6373f5a3..891fcaca9 100644 --- a/src/app/components/recent-files/recent-files.component.html +++ b/src/app/components/recent-files/recent-files.component.html @@ -98,12 +98,9 @@ - - {{ value }} - - diff --git a/src/app/components/shared-files/shared-files.component.html b/src/app/components/shared-files/shared-files.component.html index 898f606ba..031f5f924 100644 --- a/src/app/components/shared-files/shared-files.component.html +++ b/src/app/components/shared-files/shared-files.component.html @@ -96,12 +96,9 @@ - - {{ value }} - - diff --git a/src/app/components/sidenav/sidenav.component.scss b/src/app/components/sidenav/sidenav.component.scss index 33d0be7e0..9cf5af4c3 100644 --- a/src/app/components/sidenav/sidenav.component.scss +++ b/src/app/components/sidenav/sidenav.component.scss @@ -40,10 +40,9 @@ $sidenav-menu-item--icon-size: 24px; list-style-type: none; &__item { + padding: $sidenav-menu-item--v-padding 0; + &-link { - padding: - $sidenav-menu-item--v-padding - $sidenav-menu-item--h-padding; padding-left: $sidenav-menu-item--h-padding + 16px + 24px; position: relative; diff --git a/src/app/components/trashcan/trashcan.component.html b/src/app/components/trashcan/trashcan.component.html index 3ac971eea..059044ac2 100644 --- a/src/app/components/trashcan/trashcan.component.html +++ b/src/app/components/trashcan/trashcan.component.html @@ -56,12 +56,9 @@ - - {{ value }} - @@ -94,7 +92,7 @@ - diff --git a/src/app/ui/_layout.scss b/src/app/ui/_layout.scss index 8bcb6cd30..fb54980ad 100644 --- a/src/app/ui/_layout.scss +++ b/src/app/ui/_layout.scss @@ -40,6 +40,10 @@ $app-inner-layout--footer-height: 48px; } .inner-layout { + .no-border { + border: unset + } + display: flex; flex: 1; flex-direction: column; diff --git a/src/app/ui/overrides/_alfresco-document-list.scss b/src/app/ui/overrides/_alfresco-document-list.scss index 718908bf1..a73705b0d 100644 --- a/src/app/ui/overrides/_alfresco-document-list.scss +++ b/src/app/ui/overrides/_alfresco-document-list.scss @@ -7,80 +7,28 @@ adf-document-list { overflow: auto; & > adf-datatable { - display: flex; - flex-direction: column; - flex: 1; - overflow: auto; + height: 100%; } } + .adf-data-table { border: none !important; - .sr-only { - display: none; - } - - th, td { - color: $alfresco-secondary-text-color; - } - - th.adf-data-table-cell--text:nth-child(n+3) { - text-align: center; - } - th, tr, td { + color: $alfresco-secondary-text-color; &:focus { outline: none !important; } } - // TODO: Remove tr background-color once it gets to ADF tbody tr { &:hover, &:focus { background-color: $alfresco-app-color--hue-1; } - } - tr { - &.is-selected { + &.is-selected, &.is-selected:hover { background-color: $alfresco-app-color--hue-1; - - &:hover { - background-color: $alfresco-app-color--hue-1; - } - - .image-table-cell { - position: relative; - - &:before { - content: "\E876"; /* "done" */ - font-family: "Material Icons"; - font-size: 24px; - line-height: 32px; - text-align: center; - color: white; - position: absolute; - width: 32px; - height: 32px; - top: 50%; - left: 50%; - margin-top: -16px; - margin-left: -14px; - border-radius: 100%; - background: #00bcd4; - } - } - } - - .app-name-column { - width: 100%; - - .cell-container { - max-width: 45vw; - text-overflow: ellipsis; - overflow: hidden; - } } } @@ -109,6 +57,31 @@ adf-document-list { .adf-no-content-container { border: none !important; } + + + .adf-data-table-cell--ellipsis { + width: 100%; + } + + .adf-data-table-cell--ellipsis__name { + width: 85%; + } + + .adf-data-table-cell--ellipsis .cell-value, + .adf-data-table-cell--ellipsis__name .cell-value { + display: flex; + align-items: center; + } + + .adf-data-table-cell--ellipsis .adf-datatable-cell, + .adf-data-table-cell--ellipsis__name .adf-datatable-cell { + white-space: nowrap; + display: block; + position: absolute; + max-width: calc(100% - 2em); + overflow: hidden; + text-overflow: ellipsis; + } } .empty-list {