From 4a38bf292772322daaabc256ffd20ecdea0ee58d Mon Sep 17 00:00:00 2001 From: "Anh Thao Pham (pta)" Date: Mon, 31 Jul 2023 12:47:36 +0000 Subject: [PATCH] [FIX] analytic: limit width of analytic tag to 200px Steps to reproduce: - Activate "Analytic Accounting" in Accounting settings - Go to Accounting / Configuration / Analytic Accounting / Analytic Accounts - Create an Analytic Account with a very long name (i.e. +100 chars) - Go to Expenses - Create an Expense with the created Analytic Account in the Analytic field The display of the labels in the form view should break because the badge is too long and is taking all the available width. Solution: Limit the width of tag badges in "analytic_distribution" widget as it is done in "many2many_tags" widget. https://github.com/odoo/odoo/blob/2f47df6663b65c4f6b6ec61f956c453e97563462/addons/web/static/src/views/fields/many2many_tags/many2many_tags_field.scss#L47-L49 opw-3322688 closes odoo/odoo#131136 X-original-commit: 32fc4d44446a15b215c3f61cb2b35fa6f4ecb95b Signed-off-by: John Laterre (jol) Signed-off-by: Anh Thao Pham (pta) --- .../analytic_distribution/analytic_distribution.scss | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/addons/analytic/static/src/components/analytic_distribution/analytic_distribution.scss b/addons/analytic/static/src/components/analytic_distribution/analytic_distribution.scss index 19bb30a7434..d7226a65a06 100644 --- a/addons/analytic/static/src/components/analytic_distribution/analytic_distribution.scss +++ b/addons/analytic/static/src/components/analytic_distribution/analytic_distribution.scss @@ -33,6 +33,11 @@ .o_delete { padding-left: 4px; } + + .o_tag_badge_text { + @include o-text-overflow(inline-block); + max-width: 200px; + } } .analytic_distribution_popup {