Liferay.Loader.define("liferay!layout-content-page-editor-web$codemirror@5.65.2/addon/display/rulers",["module","exports","require","../../lib/codemirror"],(function(e,r,t){window,function(e){"use strict";function drawRulers(r){r.state.rulerDiv.textContent="";var t=r.getOption("rulers"),l=r.defaultCharWidth(),i=r.charCoords(e.Pos(r.firstLine(),0),"div").left;r.state.rulerDiv.style.minHeight=r.display.scroller.offsetHeight+30+"px";for(var o=0;o<t.length;o++){var a=document.createElement("div");a.className="CodeMirror-ruler";var s,n=t[o];"number"==typeof n?s=n:(s=n.column,n.className&&(a.className+=" "+n.className),n.color&&(a.style.borderColor=n.color),n.lineStyle&&(a.style.borderLeftStyle=n.lineStyle),n.width&&(a.style.borderLeftWidth=n.width)),a.style.left=i+s*l+"px",r.state.rulerDiv.appendChild(a)}}e.defineOption("rulers",!1,(function(e,r){e.state.rulerDiv&&(e.state.rulerDiv.parentElement.removeChild(e.state.rulerDiv),e.state.rulerDiv=null,e.off("refresh",drawRulers)),r&&r.length&&(e.state.rulerDiv=e.display.lineSpace.parentElement.insertBefore(document.createElement("div"),e.display.lineSpace),e.state.rulerDiv.className="CodeMirror-rulers",drawRulers(e),e.on("refresh",drawRulers))}))}("object"==typeof r&&"object"==typeof e?t("../../lib/codemirror"):CodeMirror)}));
//# sourceMappingURL=rulers.js.map