[FIX] website: fix editor message missing in empty wrap
Steps to reproduce the bug: - Open an empty page (e.g. the home page) in Website edit mode. - The "DRAG BUILDING BLOCKS HERE" message is missing in the '#wrap'. Since the commit [1], we have made modifications to the '%o-editor-messages' mixin, which is used on the '#wrap' element, to hide the editor message if the element is not the only child. However, another commit [2] was added afterwards, which introduced a new div called '#o_shared_blocks' next to the '#wrap' element. As a result, the '#wrap' element is no longer the only child, and the message is never displayed again. To fix this, we took the rule out of the mixin to only use it where we need to (for '.oe_drop_zone'). [1]: https://github.com/odoo/odoo/commit/6ee778fdbcd92dbefd08c8551ea654d352ad0dc0 [2]: https://github.com/odoo/odoo/commit/6007264afb83dcfed1693d72179cb156ff2254b6 task-3270409 closes odoo/odoo#119621 X-original-commit: d4b7a9e877804cd6bbdc0d15b1ab1c03561a4a86 Signed-off-by: Romain Derie (rde) <rde@odoo.com>
This commit is contained in:
@@ -10,7 +10,7 @@ $-editor-messages-margin-x: 2%;
|
||||
font-size: 20px;
|
||||
}
|
||||
// Show the default editor message only for "empty" elements
|
||||
&:not(:empty), &:not(:only-child) {
|
||||
&:not(:empty) {
|
||||
&[data-editor-message-default]:before {
|
||||
content: none;
|
||||
}
|
||||
@@ -91,8 +91,13 @@ $-editor-messages-margin-x: 2%;
|
||||
padding: 12px 0px;
|
||||
}
|
||||
|
||||
&:not(:only-child)::before {
|
||||
font-size: 16px;
|
||||
&:not(:only-child) {
|
||||
&::before {
|
||||
font-size: 16px;
|
||||
}
|
||||
&[data-editor-message-default]::before {
|
||||
content: none;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user