[FIX] web_editor, *: remove some inner content dropzones in Carousel
*: website When dragging inner contents, dropzones appear in the Carousel snippet, allowing to drop them directly in the element with the `row` class, where it should not be the case. This is due to the `content` class present on these elements and to the drop-in rule for inner contents that allows them to be dropped in elements having this class. This commit fixes this issue: - in stable: as the XML files cannot be modified, the drop-in rule is patched in JS to exclude the elements having both the `content` and `row` classes. - in master: it removes the `content` classes from the rows of the Carousel snippet. It also removes this class from the drop-in rule, as only Carousel was concerned by it. See [1] for the following of this fix in design-themes. [1]: https://github.com/odoo/design-themes/pull/603 task-3011192 closes odoo/odoo#108646 X-original-commit: 882c483ec1107879cd1c5693ea5cfce08e3220cc Related: odoo/design-themes#628 Signed-off-by: Vray Benjamin (bvr) <bvr@odoo.com> Signed-off-by: Quentin Smetz (qsm) <qsm@odoo.com>
This commit is contained in:
@@ -16,7 +16,7 @@
|
||||
<!-- #01 -->
|
||||
<div class="carousel-item active oe_img_bg o_bg_img_center pt152 pb152" style="background-image: url('/web/image/website.s_carousel_default_image_1');" data-name="Slide">
|
||||
<div class="container oe_unremovable">
|
||||
<div class="row content">
|
||||
<div class="row">
|
||||
<div class="carousel-content col-lg-6">
|
||||
<h2><font style="font-size: 62px;">Slide Title</font></h2>
|
||||
<p class="lead">Use this snippet to presents your content in a slideshow-like format. Don't write about products or services here, write about solutions.</p>
|
||||
@@ -30,7 +30,7 @@
|
||||
<!-- #02 -->
|
||||
<div class="carousel-item oe_img_bg o_bg_img_center pt96 pb96" style="background-image: url('/web/image/website.s_carousel_default_image_2');" data-name="Slide">
|
||||
<div class="container oe_unremovable">
|
||||
<div class="row content">
|
||||
<div class="row">
|
||||
<div class="carousel-content col-lg-8 offset-lg-2 bg-black-50 text-center pt48 pb40">
|
||||
<h2 style="font-size: 62px;">Clever Slogan</h2>
|
||||
<div class="s_hr pt8 pb24" data-snippet="s_hr" data-name="Separator">
|
||||
@@ -45,7 +45,7 @@
|
||||
<!-- #03 -->
|
||||
<div class="carousel-item oe_img_bg o_bg_img_center pt128 pb128" style="background-image: url('/web/image/website.s_carousel_default_image_3');" data-name="Slide">
|
||||
<div class="container oe_unremovable">
|
||||
<div class="row content">
|
||||
<div class="row">
|
||||
<div class="carousel-content col-lg-6 offset-lg-6">
|
||||
<h2><font style="font-size: 62px; background-color: rgb(255, 255, 255);">Edit this title</font></h2>
|
||||
<h4><font style="background-color: rgb(255, 255, 255);">Good writing is simple, but not simplistic.</font></h4>
|
||||
|
||||
@@ -641,7 +641,7 @@
|
||||
<div id="so_content_addition"
|
||||
t-att-data-selector="so_content_addition_selector"
|
||||
t-attf-data-drop-near="p, h1, h2, h3, ul, ol, .row > div:not(.o_grid_item_image) > img, #{so_content_addition_selector}"
|
||||
data-drop-in=".content, nav"/>
|
||||
data-drop-in="nav"/>
|
||||
|
||||
<div data-js="SnippetSave"
|
||||
data-selector="[data-snippet]"
|
||||
|
||||
Reference in New Issue
Block a user