ueditor裏有這麼斷代碼,javascript
1.初始顯示狀態下(非全屏),修改一下代碼的z-indexcss
UE.Editor.defaultOptions = function(editor){ var _url = editor.options.UEDITOR_HOME_URL; return { isShow: true, initialContent: '', initialStyle:'', autoClearinitialContent: false, iframeCssUrl: _url + 'themes/iframe.css', textarea: 'editorValue', focus: false, focusInEnd: true, autoClearEmptyNode: true, fullscreen: false, readonly: false, zIndex: 10052,//大於彈出模擬框便可 imagePopup: true, enterTag: 'p', customDomain: false, lang: 'zh-cn', langPath: _url + 'lang/', theme: 'default', themePath: _url + 'themes/', allHtmlEnabled: false, scaleEnabled: false, tableNativeEditInFF: false, autoSyncData : true, fileNameFormat: '{time}{rand:6}' } };
2.這裏是全屏狀態下的,修改後,點擊全屏就不會出現被其餘層遮住的狀況,關鍵字_updateFullScreenjava
_updateFullScreen:function () { if (this._fullscreen) { var vpRect = uiUtils.getViewportRect(); this.getDom().style.cssText = 'border:0;position:absolute;left:0;top:' + (this.editor.options.topOffset || 0) + 'px;width:' + vpRect.width + 'px;height:' + vpRect.height + 'px;z-index:' + (this.getDom().style.zIndex * 1 + 1000); uiUtils.setViewportOffset(this.getDom(), { left:0, top:this.editor.options.topOffset || 0 }); this.editor.setHeight(vpRect.height - this.getDom('toolbarbox').offsetHeight - this.getDom('bottombar').offsetHeight - (this.editor.options.topOffset || 0),true); //不手動調一下,會致使全屏失效 if(browser.gecko){ try{ window.onresize(); }catch(e){ } } } },
只須要把z-index的值修改大點便可,詳細看項目須要ui
(this.getDom().style.zIndex * 1 + 10000)