Completed
Last Updated: 04 Sep 2019 15:57 by ADMIN
ADMIN
Slav
Created on: 13 Dec 2013 14:24
Category: Editor
Type: Bug Report
0
When RadEditor is resized beyond the boundaries of the browser's viewport, it becomes absolutely positioned
When you resize the RadEditor beyond the boundaries of the browser's viewport, absolute positioning will be applied to the control, which could result in problems with the layout in certain cases.

You can use the following workaround to fix the positioning of the editor until the problem is resolved. Just add the script below at the end of your page:

<script type="text/javascript">
                var onResizeStart = Telerik.Web.UI.RadEditor.prototype.onResizeStart;
                Telerik.Web.UI.RadEditor.prototype.onResizeStart = function() {
                                var editorWrapper = this.get_element();
                                this.resizeStartPosition = {
                                                position: editorWrapper.style.position,
                                                top: editorWrapper.style.top,
                                                left: editorWrapper.style.left
                                };
                                onResizeStart.call(this);
                }

                var onResizeEnd = Telerik.Web.UI.RadEditor.prototype.onResizeEnd;
                Telerik.Web.UI.RadEditor.prototype.onResizeEnd = function() {
                                var editorWrapper = this.get_element();
                                if (this.resizeStartPosition && this.resizeStartPosition.position != editorWrapper.style.position) {                                             
                                                $telerik.$(editorWrapper).css({
                                                                position: this.resizeStartPosition.position,
                                                                top: this.resizeStartPosition.top,
                                                                left: this.resizeStartPosition.left
                                                });
                                }
                                onResizeEnd.call(this);
                }
</script>
0 comments