[FIX] mail: remove unnecessary css in chatter

This commit removes the css that was creating two layout issues :
[1] When the chatter was rendered under the form view with the
`isInFormSheetBg` class, it added an unwanted background and border.

[2] When an attachment was uploaded and created a preview (eg. in
approvals), it created an unwanted border.

This commit fixes these issues.

task-3334866
Part of task-3326263

closes odoo/odoo#123095

X-original-commit: 5171b0bb2054f4755d0ba70b6820806c5253774d
Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com>
This commit is contained in:
Brieuc-brd
2023-05-31 17:26:14 +02:00
parent db68392f77
commit 40dea12b02
3 changed files with 3 additions and 4 deletions
@@ -4,7 +4,6 @@
flex: 1 0 auto;
overflow: hidden;
width: $o-mail-Chatter-minWidth;
border-left: 1px solid map-get($grays, '400');
> .o-mail-Attachment {
position: relative;
@@ -112,7 +112,7 @@ patch(FormCompiler.prototype, "mail", {
"t-if": `__comp__.hasFileViewer() and __comp__.uiService.size >= ${SIZES.XXL}`,
});
const sheetBgChatterContainerHookXml = chatterContainerHookXml.cloneNode(true);
sheetBgChatterContainerHookXml.classList.add("o-isInFormSheetBg");
sheetBgChatterContainerHookXml.classList.add("o-isInFormSheetBg", "w-auto");
setAttributes(sheetBgChatterContainerHookXml, {
"t-if": `__comp__.hasFileViewer() and __comp__.uiService.size >= ${SIZES.XXL}`,
});
@@ -26,8 +26,8 @@
}
&.o-isInFormSheetBg {
background-color: $white;
border-top: 1px solid $border-color;
margin-left: calc(var(--formView-sheetBg-padding-x) * -1);
margin-right: calc(var(--formView-sheetBg-padding-x) * -1);
}
&:not(.o-aside):not(.o-full-width) .o-mail-Chatter {