CoreFiles by mySites.guru
foldgutter.min.js1 lines, 2,424 bytes, from Joomla_4.0.0-alpha2-Alpha-Full_Package.zip
Raw History Compare with 3.10.0-alpha9
md5
d7f4fcf55b73714a58f3896eeefbeef1
sha1
7c60b65f779022c43a5cd9ea8e0813e831bdad8c
sha256
c0bf4349330b8abec7e4f294129cc390da1fb93b4c301d8a79ea38e084cdff4c
!function(o){"object"==typeof exports&&"object"==typeof module?o(require("../../lib/codemirror"),require("./foldcode")):"function"==typeof define&&define.amd?define(["../../lib/codemirror","./foldcode"],o):o(CodeMirror)}(function(o){"use strict";function t(o,t){for(var e=o.findMarks(u(t,0),u(t+1,0)),r=0;r<e.length;++r)if(e[r].__isFold&&e[r].find().from.line==t)return e[r]}function e(o){if("string"==typeof o){var t=document.createElement("div");return t.className=o+" CodeMirror-guttermarker-subtle",t}return o.cloneNode(!0)}function r(o,r,n){var i=o.state.foldGutter.options,f=r,d=o.foldOption(i,"minFoldSize"),a=o.foldOption(i,"rangeFinder");o.eachLine(r,n,function(r){var n=null;if(t(o,f))n=e(i.indicatorFolded);else{var l=u(f,0),c=a&&a(o,l);c&&c.to.line-c.from.line>=d&&(n=e(i.indicatorOpen))}o.setGutterMarker(r,i.gutter,n),++f})}function n(o){var t=o.getViewport(),e=o.state.foldGutter;e&&(o.operation(function(){r(o,t.from,t.to)}),e.from=t.from,e.to=t.to)}function i(o,e,r){var n=o.state.foldGutter;if(n){var i=n.options;if(r==i.gutter){var f=t(o,e);f?f.clear():o.foldCode(u(e,0),i.rangeFinder)}}}function f(o){var t=o.state.foldGutter;if(t){var e=t.options;t.from=t.to=0,clearTimeout(t.changeUpdate),t.changeUpdate=setTimeout(function(){n(o)},e.foldOnChangeTimeSpan||600)}}function d(o){var t=o.state.foldGutter;if(t){var e=t.options;clearTimeout(t.changeUpdate),t.changeUpdate=setTimeout(function(){var e=o.getViewport();t.from==t.to||e.from-t.to>20||t.from-e.to>20?n(o):o.operation(function(){e.from<t.from&&(r(o,e.from,t.from),t.from=e.from),e.to>t.to&&(r(o,t.to,e.to),t.to=e.to)})},e.updateViewportTimeSpan||400)}}function a(o,t){var e=o.state.foldGutter;if(e){var n=t.line;n>=e.from&&n<e.to&&r(o,n,n+1)}}o.defineOption("foldGutter",!1,function(t,e,r){r&&r!=o.Init&&(t.clearGutter(t.state.foldGutter.options.gutter),t.state.foldGutter=null,t.off("gutterClick",i),t.off("change",f),t.off("viewportChange",d),t.off("fold",a),t.off("unfold",a),t.off("swapDoc",f)),e&&(t.state.foldGutter=new function(o){this.options=o,this.from=this.to=0}(function(o){return!0===o&&(o={}),null==o.gutter&&(o.gutter="CodeMirror-foldgutter"),null==o.indicatorOpen&&(o.indicatorOpen="CodeMirror-foldgutter-open"),null==o.indicatorFolded&&(o.indicatorFolded="CodeMirror-foldgutter-folded"),o}(e)),n(t),t.on("gutterClick",i),t.on("change",f),t.on("viewportChange",d),t.on("fold",a),t.on("unfold",a),t.on("swapDoc",f))});var u=o.Pos});

No other release has this exact content. See every version of this file.