From 2fa8292d256cad567dd15f9324a56e9136a87bb3 Mon Sep 17 00:00:00 2001 From: trisdoan Date: Mon, 5 Aug 2024 08:46:56 +0700 Subject: [PATCH] fixup! [IMP] web_chatter_position: improve function compile --- .../static/src/js/web_chatter_position.esm.js | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/web_chatter_position/static/src/js/web_chatter_position.esm.js b/web_chatter_position/static/src/js/web_chatter_position.esm.js index 544fb1279449..42582fc4b836 100644 --- a/web_chatter_position/static/src/js/web_chatter_position.esm.js +++ b/web_chatter_position/static/src/js/web_chatter_position.esm.js @@ -40,11 +40,11 @@ patch(FormCompiler.prototype, { // (except if there is an attachment viewer, as we have to force bottom) } else if (odoo.web_chatter_position === "sided") { setAttributes(chatterContainerXml, { - isInFormSheetBg: "false", - isChatterAside: "true", + isInFormSheetBg: `__comp__.uiService.size < ${SIZES.XXL}`, + isChatterAside: `__comp__.uiService.size >= ${SIZES.XXL}`, }); setAttributes(chatterContainerHookXml, { - "t-attf-class": "o-aside", + "t-attf-class": `{{ __comp__.uiService.size >= ${SIZES.XXL} ? "o-aside" : "" }}`, }); // For "bottom", we keep the chatter in the form sheet // (the one used for the attachment viewer case)