diff --git a/addons/web_editor/static/src/js/wysiwyg/wysiwyg.js b/addons/web_editor/static/src/js/wysiwyg/wysiwyg.js index 0f6ab42d5ee..3f47a6128f9 100644 --- a/addons/web_editor/static/src/js/wysiwyg/wysiwyg.js +++ b/addons/web_editor/static/src/js/wysiwyg/wysiwyg.js @@ -1758,7 +1758,7 @@ export class Wysiwyg extends Component { e.preventDefault(); e.stopImmediatePropagation(); e.stopPropagation(); - switch (e.target.id) { + switch (e.currentTarget.id) { case 'create-link': this.toggleLinkTools(); break; diff --git a/addons/web_editor/static/src/scss/wysiwyg_snippets.scss b/addons/web_editor/static/src/scss/wysiwyg_snippets.scss index d4c99720b48..b96d3fc4717 100644 --- a/addons/web_editor/static/src/scss/wysiwyg_snippets.scss +++ b/addons/web_editor/static/src/scss/wysiwyg_snippets.scss @@ -499,9 +499,21 @@ background: transparent; margin-top: $o-we-sidebar-content-field-spacing; padding: 0 $o-we-sidebar-content-padding-base 0 $o-we-sidebar-content-indent; - grid-template-areas: "typo typo style colors" "size align list link" "options options options options" "options2 options2 options2 options2"; - grid-template-columns: 1fr 1fr 1fr 1fr; - grid-template-rows: minmax($o-we-sidebar-content-field-height, auto) minmax($o-we-sidebar-content-field-height, auto) auto auto ; + grid-template-areas: + "typo typo style style colors" + "size align list list link" + "ai animate animate hilight hilight" + "options options options options options" + "options2 options2 options2 options2 options2" + "options3 options3 options3 options3 options3"; + grid-template-columns: 1fr 1fr 1fr 1fr 1fr; + grid-template-rows: + minmax($o-we-sidebar-content-field-height, auto) + minmax($o-we-sidebar-content-field-height, auto) + minmax($o-we-sidebar-content-field-height, auto) + auto + auto + auto; row-gap: $o-we-sidebar-content-field-spacing; column-gap: $o-we-sidebar-content-field-multi-spacing; width: 100%; @@ -626,8 +638,12 @@ } } - & + we-customizeblock-option { + & ~ we-customizeblock-option { grid-area: options2; + + & ~ we-customizeblock-option { + grid-area: options3; + } } } @@ -723,6 +739,20 @@ } } + #chatgpt { + grid-area: ai; + + span { + margin-left: 5px; + } + } + #animate { + grid-area: animate; + } + #highlight { + grid-area: hilight; + } + .dropdown-menu.colorpicker-menu { min-width: 0; max-height: none; diff --git a/addons/web_editor/static/src/xml/editor.xml b/addons/web_editor/static/src/xml/editor.xml index 659dde98eed..61f712959da 100644 --- a/addons/web_editor/static/src/xml/editor.xml +++ b/addons/web_editor/static/src/xml/editor.xml @@ -176,7 +176,9 @@