window.editormd&&(editormd.fn.setToolbarAutoFixed=function(a){var b,c=this.state,d=this.editor,e=this.toolbar,f=this.settings;return"undefined"!=typeof a&&(f.toolbarAutoFixed=a),b=function(){var a,b=$(window),c=b.scrollTop();return f.toolbarAutoFixed?(c-d.offset().top>10&&c<d.height()?(a=(b.width()-d.width())/2+"px",$(".layui-form").length&&(a=$(".layui-form").position().left+1+"px"),e.css({position:"fixed",width:d.width()+"px",left:a})):e.css({position:"absolute",width:"100%",left:0}),void 0):!1},!c.fullscreen&&!c.preview&&f.toolbar&&f.toolbarAutoFixed&&$(window).bind("scroll resize",b),this});