From 1fa701c436f18e73ab0a335cd826805bd3344e0e Mon Sep 17 00:00:00 2001 From: qsm-odoo Date: Tue, 7 Nov 2023 12:58:00 +0100 Subject: [PATCH] [FIX] website: properly allow to edit header texts and links The text and links in the header configurations were always the root elements that were editable. For them to be properly editable, we need their container (at minimum) to be the root editable element. Indeed, on root editable elements, only the class and style can be changed (if not dynamic). But changing a link requires to change the href, the target. Changing a text style requires to change the tag entirely, etc. For this to work, the `_link_class` configuration was removed, it was in fact mostly useless and actually even breaking some layouts. So doing this fix actually improves the design as well. For the layout were it made sense, it actually became useless by refactoring the templates. This was necessary anyway for texts which did not use `_link_class` but were root editable nodes anyway because of the `t-if` conditions laying around. closes odoo/odoo#140869 Signed-off-by: Quentin Smetz (qsm) --- addons/website/views/website_templates.xml | 57 +++++++++++++--------- 1 file changed, 35 insertions(+), 22 deletions(-) diff --git a/addons/website/views/website_templates.xml b/addons/website/views/website_templates.xml index 28df25f5c9c..dd71a041fe7 100644 --- a/addons/website/views/website_templates.xml +++ b/addons/website/views/website_templates.xml @@ -352,7 +352,6 @@ - @@ -564,7 +563,6 @@ - @@ -660,8 +658,8 @@