From fea3c719afd0e0dfc5ca3c8113654902339d4b00 Mon Sep 17 00:00:00 2001 From: Molkobain Date: Wed, 1 Sep 2021 14:56:21 +0200 Subject: [PATCH] Top bar: Force page title to stay on 1 line --- application/dashboard.class.inc.php | 2 +- css/backoffice/layout/_top-bar.scss | 4 ++++ 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/application/dashboard.class.inc.php b/application/dashboard.class.inc.php index 637162b5e..700bce0e9 100644 --- a/application/dashboard.class.inc.php +++ b/application/dashboard.class.inc.php @@ -543,7 +543,7 @@ EOF if ($bFromDasboardPage) { $sTitleForHTML = utils::HtmlEntities(Dict::S($this->sTitle)); - $sHtml = "
{$sTitleForHTML}
"; + $sHtml = "
{$sTitleForHTML}
"; if ($oPage instanceof iTopWebPage) { $oTopBar = $oPage->GetTopBarLayout(); $oToolbar = ToolbarUIBlockFactory::MakeStandard(); diff --git a/css/backoffice/layout/_top-bar.scss b/css/backoffice/layout/_top-bar.scss index e51033137..3f29967ed 100644 --- a/css/backoffice/layout/_top-bar.scss +++ b/css/backoffice/layout/_top-bar.scss @@ -26,6 +26,8 @@ $ibo-top-bar--elements-spacing: 32px !default; $ibo-top-bar--quick-actions--margin-right: $ibo-top-bar--elements-spacing !default; +$ibo-top-bar--toolbar-dashboard-title--max-width: 350px !default; + /* CSS variables (can be changed directly from the browser) */ :root{ --ibo-top-bar--height: #{$ibo-top-bar--height}; @@ -65,6 +67,8 @@ $ibo-top-bar--quick-actions--margin-right: $ibo-top-bar--elements-spacing !defau .ibo-top-bar--toolbar-dashboard-title { @extend %ibo-font-size-250; + @extend %ibo-text-truncated-with-ellipsis; + max-width: $ibo-top-bar--toolbar-dashboard-title--max-width; } .ibo-top-bar--toolbar-dashboard-menu-toggler {