diff options
Diffstat (limited to 'addons/website/static/src/js/editor/snippets.editor.js')
| -rw-r--r-- | addons/website/static/src/js/editor/snippets.editor.js | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/addons/website/static/src/js/editor/snippets.editor.js b/addons/website/static/src/js/editor/snippets.editor.js index 04de692f2fd..24b950afc8c 100644 --- a/addons/website/static/src/js/editor/snippets.editor.js +++ b/addons/website/static/src/js/editor/snippets.editor.js @@ -33,6 +33,19 @@ weSnippetEditor.Class.include({ /** * @override */ + _getScrollOptions(options = {}) { + const finalOptions = this._super(...arguments); + if (!options.offsetElements || !options.offsetElements.$top) { + const $header = $('#top'); + if ($header.length) { + finalOptions.offsetElements.$top = $header; + } + } + return finalOptions; + }, + /** + * @override + */ _updateLeftPanelContent: function ({content, tab}) { this._super(...arguments); this.$('.o_we_customize_theme_btn').toggleClass('active', tab === this.tabs.THEME); |
