From b16e0cf2484e482105f236f5f3155e467cf71a2f Mon Sep 17 00:00:00 2001 From: Ms Kimsible <1877318+kimsible@users.noreply.github.com> Date: Wed, 8 Sep 2021 10:12:38 +0200 Subject: [PATCH] Fix broken delete buttons of admin federation lists (#4378) * Add ellipsis on my-delete button of federation admin * Add ellipsis on button label to define (max-)width on host component Co-authored-by: Ms Kimsible --- .../follows/followers-list/followers-list.component.scss | 4 ++++ .../follows/following-list/following-list.component.html | 2 +- .../follows/following-list/following-list.component.scss | 4 ++++ .../app/shared/shared-main/buttons/button.component.scss | 7 +++++++ 4 files changed, 16 insertions(+), 1 deletion(-) diff --git a/client/src/app/+admin/follows/followers-list/followers-list.component.scss b/client/src/app/+admin/follows/followers-list/followers-list.component.scss index c29b20493..3a7bf2ef8 100644 --- a/client/src/app/+admin/follows/followers-list/followers-list.component.scss +++ b/client/src/app/+admin/follows/followers-list/followers-list.component.scss @@ -21,3 +21,7 @@ a { @include margin-right(10px); } } + +my-delete-button { + max-width: 130px; +} diff --git a/client/src/app/+admin/follows/following-list/following-list.component.html b/client/src/app/+admin/follows/following-list/following-list.component.html index 75b0efca8..c73469295 100644 --- a/client/src/app/+admin/follows/following-list/following-list.component.html +++ b/client/src/app/+admin/follows/following-list/following-list.component.html @@ -38,7 +38,7 @@ - + diff --git a/client/src/app/+admin/follows/following-list/following-list.component.scss b/client/src/app/+admin/follows/following-list/following-list.component.scss index ef24b38cc..0de80e563 100644 --- a/client/src/app/+admin/follows/following-list/following-list.component.scss +++ b/client/src/app/+admin/follows/following-list/following-list.component.scss @@ -19,3 +19,7 @@ a { .follow-button { @include create-button; } + +my-delete-button { + max-width: 130px; +} diff --git a/client/src/app/shared/shared-main/buttons/button.component.scss b/client/src/app/shared/shared-main/buttons/button.component.scss index e74ba0221..c782ac3ef 100644 --- a/client/src/app/shared/shared-main/buttons/button.component.scss +++ b/client/src/app/shared/shared-main/buttons/button.component.scss @@ -13,6 +13,7 @@ :host { outline: none; + display: inline-block; } my-small-loader ::ng-deep .root { @@ -31,6 +32,8 @@ span[class$=-button] { .action-button { @include peertube-button-link; @include button-with-icon(21px); + + width: 100%; // useful for ellipsis, allow to define a max-width on host component } .orange-button { @@ -53,6 +56,10 @@ span[class$=-button] { @include grey-button; } +.button-label { + @include ellipsis; +} + // In a table, try to minimize the space taken by this button @media screen and (max-width: 1400px) { :host-context(td) { -- 2.41.0