0
0
mirror of https://github.com/naturalcrit/homebrewery.git synced 2026-03-23 19:38:12 +00:00

renamed client to src

This commit is contained in:
Víctor Losada Hernández
2026-02-01 17:34:50 +01:00
parent 820160d0f5
commit c28736bd01
140 changed files with 0 additions and 0 deletions

View File

@@ -1,26 +0,0 @@
export default {
registerHomebreweryHelper : function(CodeMirror) {
CodeMirror.registerHelper('fold', 'homebrewery', function(cm, start) {
const matcher = /^\\page.*/;
const prevLine = cm.getLine(start.line - 1);
if(start.line === cm.firstLine() || prevLine.match(matcher)) {
const lastLineNo = cm.lastLine();
let end = start.line;
while (end < lastLineNo) {
if(cm.getLine(end + 1).match(matcher))
break;
++end;
}
return {
from : CodeMirror.Pos(start.line, 0),
to : CodeMirror.Pos(end, cm.getLine(end).length)
};
}
return null;
});
}
};