Upgrade JavaScript dependencies
- Bumps Bootstrap to v4.6.1 - Bumps CodeMirror to v5.63.3 - Bumps OpenLayers to v6.9.0 Signed-off-by: Maurício Meneghini Fauth <mauricio@fauth.dev>
This commit is contained in:
parent
451563c823
commit
3f279e47ea
@ -292,6 +292,7 @@ var Console = {
|
||||
Console.setConfig('Mode', 'show');
|
||||
|
||||
var pmaConsoleHeight = Math.max(92, Console.config.Height);
|
||||
// eslint-disable-next-line compat/compat
|
||||
pmaConsoleHeight = Math.min(Console.config.Height, (window.innerHeight || document.documentElement.clientHeight || document.body.clientHeight) - 25);
|
||||
Console.$consoleContent.css({ display:'block' });
|
||||
if (Console.$consoleToolbar.hasClass('collapsed')) {
|
||||
|
||||
@ -95,7 +95,9 @@ if (isIe) {
|
||||
}
|
||||
|
||||
DesignerMove.mouseDown = function (e) {
|
||||
// eslint-disable-next-line compat/compat
|
||||
globX = isIe ? e.clientX + document.body.scrollLeft : e.pageX;
|
||||
// eslint-disable-next-line compat/compat
|
||||
globY = isIe ? e.clientY + document.body.scrollTop : e.pageY;
|
||||
|
||||
if (e.target.tagName === 'SPAN') {
|
||||
@ -119,7 +121,9 @@ DesignerMove.mouseMove = function (e) {
|
||||
e.preventDefault();
|
||||
}
|
||||
|
||||
// eslint-disable-next-line compat/compat
|
||||
var newDx = isIe ? e.clientX + document.body.scrollLeft : e.pageX;
|
||||
// eslint-disable-next-line compat/compat
|
||||
var newDy = isIe ? e.clientY + document.body.scrollTop : e.pageY;
|
||||
|
||||
var deltaX = globX - newDx;
|
||||
@ -1489,7 +1493,9 @@ DesignerMove.canvasClick = function (id, event) {
|
||||
var key;
|
||||
var key2;
|
||||
var key3;
|
||||
// eslint-disable-next-line compat/compat
|
||||
var localX = isIe ? event.clientX + document.body.scrollLeft : event.pageX;
|
||||
// eslint-disable-next-line compat/compat
|
||||
var localY = isIe ? event.clientY + document.body.scrollTop : event.pageY;
|
||||
localX -= $('#osn_tab').offset().left;
|
||||
localY -= $('#osn_tab').offset().top;
|
||||
@ -1697,7 +1703,9 @@ DesignerMove.generalScroll = function () {
|
||||
clearTimeout(timeoutId);
|
||||
timeoutId = setTimeout(
|
||||
function () {
|
||||
// eslint-disable-next-line compat/compat
|
||||
document.getElementById('top_menu').style.left = document.body.scrollLeft + 'px';
|
||||
// eslint-disable-next-line compat/compat
|
||||
document.getElementById('top_menu').style.top = document.body.scrollTop + 'px';
|
||||
},
|
||||
200
|
||||
|
||||
@ -145,6 +145,7 @@ var ErrorReport = {
|
||||
$buttons.html(buttonHtml);
|
||||
|
||||
$div.append($buttons);
|
||||
// eslint-disable-next-line compat/compat
|
||||
$div.appendTo(document.body);
|
||||
$(document).on('click', '#change_error_settings', ErrorReport.redirectToSettings);
|
||||
$(document).on('click', '#show_error_report', ErrorReport.createReportDialog);
|
||||
|
||||
@ -3995,6 +3995,7 @@ AJAX.registerOnload('functions.js', function () {
|
||||
|
||||
Functions.mainMenuResizerCallback = function () {
|
||||
// 5 px margin for jumping menu in Chrome
|
||||
// eslint-disable-next-line compat/compat
|
||||
return $(document.body).width() - 5;
|
||||
};
|
||||
|
||||
|
||||
@ -94,6 +94,7 @@ var makeGrid = function (t, enableResize, enableReorder, enableVisib, enableGrid
|
||||
objLeft: $(obj).position().left,
|
||||
objWidth: $(g.t).find('th.draggable:visible').eq(n).find('span').outerWidth()
|
||||
};
|
||||
// eslint-disable-next-line compat/compat
|
||||
$(document.body).css('cursor', 'col-resize').noSelect();
|
||||
if (g.isCellEditActive) {
|
||||
g.hideEditCell();
|
||||
@ -133,6 +134,7 @@ var makeGrid = function (t, enableResize, enableReorder, enableVisib, enableGrid
|
||||
objLeft: objPos.left
|
||||
};
|
||||
|
||||
// eslint-disable-next-line compat/compat
|
||||
$(document.body).css('cursor', 'move').noSelect();
|
||||
if (g.isCellEditActive) {
|
||||
g.hideEditCell();
|
||||
@ -229,6 +231,7 @@ var makeGrid = function (t, enableResize, enableReorder, enableVisib, enableGrid
|
||||
|
||||
g.colReorder = false;
|
||||
}
|
||||
// eslint-disable-next-line compat/compat
|
||||
$(document.body).css('cursor', 'inherit').noSelect(false);
|
||||
},
|
||||
|
||||
|
||||
@ -72,6 +72,7 @@
|
||||
totalLen += $($li[i]).outerWidth(true);
|
||||
}
|
||||
|
||||
// eslint-disable-next-line compat/compat
|
||||
var hasVScroll = document.body.scrollHeight > document.body.clientHeight;
|
||||
if (hasVScroll) {
|
||||
windowWidth += 15;
|
||||
|
||||
@ -1312,6 +1312,7 @@ AJAX.registerOnload('server/status/monitor.js', function () {
|
||||
$('#selection_box').remove();
|
||||
}
|
||||
var selectionBox = $('<div id="selection_box" >');
|
||||
// eslint-disable-next-line compat/compat
|
||||
$(document.body).append(selectionBox);
|
||||
selectionStartX = ev.pageX;
|
||||
selectionStartY = ev.pageY;
|
||||
@ -1360,6 +1361,7 @@ AJAX.registerOnload('server/status/monitor.js', function () {
|
||||
drawTimeSpan = false;
|
||||
});
|
||||
|
||||
// eslint-disable-next-line compat/compat
|
||||
$(document.body).on('mouseup', function () {
|
||||
if ($('#selection_box').length) {
|
||||
$('#selection_box').remove();
|
||||
|
||||
@ -381,6 +381,7 @@ AJAX.registerOnload('sql.js', function () {
|
||||
textArea.value += '\n';
|
||||
});
|
||||
|
||||
// eslint-disable-next-line compat/compat
|
||||
document.body.appendChild(textArea);
|
||||
|
||||
textArea.select();
|
||||
@ -391,6 +392,7 @@ AJAX.registerOnload('sql.js', function () {
|
||||
alert('Sorry! Unable to copy');
|
||||
}
|
||||
|
||||
// eslint-disable-next-line compat/compat
|
||||
document.body.removeChild(textArea);
|
||||
}); // end of Copy to Clipboard action
|
||||
|
||||
|
||||
4
js/vendor/bootstrap/bootstrap.bundle.min.js
vendored
4
js/vendor/bootstrap/bootstrap.bundle.min.js
vendored
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
20
js/vendor/codemirror/addon/hint/show-hint.js
vendored
20
js/vendor/codemirror/addon/hint/show-hint.js
vendored
@ -224,6 +224,7 @@
|
||||
}
|
||||
|
||||
function Widget(completion, data) {
|
||||
this.id = "cm-complete-" + Math.floor(Math.random(1e6))
|
||||
this.completion = completion;
|
||||
this.data = data;
|
||||
this.picked = false;
|
||||
@ -232,6 +233,9 @@
|
||||
var parentWindow = ownerDocument.defaultView || ownerDocument.parentWindow;
|
||||
|
||||
var hints = this.hints = ownerDocument.createElement("ul");
|
||||
hints.setAttribute("role", "listbox")
|
||||
hints.setAttribute("aria-expanded", "true")
|
||||
hints.id = this.id
|
||||
var theme = completion.cm.options.theme;
|
||||
hints.className = "CodeMirror-hints " + theme;
|
||||
this.selectedHint = data.selectedHint || 0;
|
||||
@ -242,6 +246,9 @@
|
||||
var className = HINT_ELEMENT_CLASS + (i != this.selectedHint ? "" : " " + ACTIVE_HINT_ELEMENT_CLASS);
|
||||
if (cur.className != null) className = cur.className + " " + className;
|
||||
elt.className = className;
|
||||
if (i == this.selectedHint) elt.setAttribute("aria-selected", "true")
|
||||
elt.id = this.id + "-" + i
|
||||
elt.setAttribute("role", "option")
|
||||
if (cur.render) cur.render(elt, data, cur);
|
||||
else elt.appendChild(ownerDocument.createTextNode(cur.displayText || getText(cur)));
|
||||
elt.hintId = i;
|
||||
@ -267,6 +274,9 @@
|
||||
var winW = parentWindow.innerWidth || Math.max(ownerDocument.body.offsetWidth, ownerDocument.documentElement.offsetWidth);
|
||||
var winH = parentWindow.innerHeight || Math.max(ownerDocument.body.offsetHeight, ownerDocument.documentElement.offsetHeight);
|
||||
container.appendChild(hints);
|
||||
cm.getInputField().setAttribute("aria-autocomplete", "list")
|
||||
cm.getInputField().setAttribute("aria-owns", this.id)
|
||||
cm.getInputField().setAttribute("aria-activedescendant", this.id + "-" + this.selectedHint)
|
||||
|
||||
var box = completion.options.moveOnOverlap ? hints.getBoundingClientRect() : new DOMRect();
|
||||
var scrolls = completion.options.paddingForScrollbar ? hints.scrollHeight > hints.clientHeight + 1 : false;
|
||||
@ -364,6 +374,9 @@
|
||||
this.completion.widget = null;
|
||||
if (this.hints.parentNode) this.hints.parentNode.removeChild(this.hints);
|
||||
this.completion.cm.removeKeyMap(this.keyMap);
|
||||
var input = this.completion.cm.getInputField()
|
||||
input.removeAttribute("aria-activedescendant")
|
||||
input.removeAttribute("aria-owns")
|
||||
|
||||
var cm = this.completion.cm;
|
||||
if (this.completion.options.closeOnUnfocus) {
|
||||
@ -391,9 +404,14 @@
|
||||
i = avoidWrap ? 0 : this.data.list.length - 1;
|
||||
if (this.selectedHint == i) return;
|
||||
var node = this.hints.childNodes[this.selectedHint];
|
||||
if (node) node.className = node.className.replace(" " + ACTIVE_HINT_ELEMENT_CLASS, "");
|
||||
if (node) {
|
||||
node.className = node.className.replace(" " + ACTIVE_HINT_ELEMENT_CLASS, "");
|
||||
node.removeAttribute("aria-selected")
|
||||
}
|
||||
node = this.hints.childNodes[this.selectedHint = i];
|
||||
node.className += " " + ACTIVE_HINT_ELEMENT_CLASS;
|
||||
node.setAttribute("aria-selected", "true")
|
||||
this.completion.cm.getInputField().setAttribute("aria-activedescendant", node.id)
|
||||
this.scrollToActive()
|
||||
CodeMirror.signal(this.data, "select", this.data.list[this.selectedHint], node);
|
||||
},
|
||||
|
||||
8
js/vendor/codemirror/addon/lint/lint.css
vendored
8
js/vendor/codemirror/addon/lint/lint.css
vendored
@ -69,3 +69,11 @@
|
||||
background-position: right bottom;
|
||||
width: 100%; height: 100%;
|
||||
}
|
||||
|
||||
.CodeMirror-lint-line-error {
|
||||
background-color: rgba(183, 76, 81, 0.08);
|
||||
}
|
||||
|
||||
.CodeMirror-lint-line-warning {
|
||||
background-color: rgba(255, 211, 0, 0.1);
|
||||
}
|
||||
|
||||
68
js/vendor/codemirror/addon/lint/lint.js
vendored
68
js/vendor/codemirror/addon/lint/lint.js
vendored
@ -11,6 +11,7 @@
|
||||
})(function(CodeMirror) {
|
||||
"use strict";
|
||||
var GUTTER_ID = "CodeMirror-lint-markers";
|
||||
var LINT_LINE_ID = "CodeMirror-lint-line-";
|
||||
|
||||
function showTooltip(cm, e, content) {
|
||||
var tt = document.createElement("div");
|
||||
@ -58,29 +59,54 @@
|
||||
CodeMirror.on(node, "mouseout", hide);
|
||||
}
|
||||
|
||||
function LintState(cm, options, hasGutter) {
|
||||
function LintState(cm, conf, hasGutter) {
|
||||
this.marked = [];
|
||||
this.options = options;
|
||||
if (conf instanceof Function) conf = {getAnnotations: conf};
|
||||
if (!conf || conf === true) conf = {};
|
||||
this.options = {};
|
||||
this.linterOptions = conf.options || {};
|
||||
for (var prop in defaults) this.options[prop] = defaults[prop];
|
||||
for (var prop in conf) {
|
||||
if (defaults.hasOwnProperty(prop)) {
|
||||
if (conf[prop] != null) this.options[prop] = conf[prop];
|
||||
} else if (!conf.options) {
|
||||
this.linterOptions[prop] = conf[prop];
|
||||
}
|
||||
}
|
||||
this.timeout = null;
|
||||
this.hasGutter = hasGutter;
|
||||
this.onMouseOver = function(e) { onMouseOver(cm, e); };
|
||||
this.waitingFor = 0
|
||||
}
|
||||
|
||||
function parseOptions(_cm, options) {
|
||||
if (options instanceof Function) return {getAnnotations: options};
|
||||
if (!options || options === true) options = {};
|
||||
return options;
|
||||
var defaults = {
|
||||
highlightLines: false,
|
||||
tooltips: true,
|
||||
delay: 500,
|
||||
lintOnChange: true,
|
||||
getAnnotations: null,
|
||||
async: false,
|
||||
selfContain: null,
|
||||
formatAnnotation: null,
|
||||
onUpdateLinting: null
|
||||
}
|
||||
|
||||
function clearMarks(cm) {
|
||||
var state = cm.state.lint;
|
||||
if (state.hasGutter) cm.clearGutter(GUTTER_ID);
|
||||
if (state.options.highlightLines) clearErrorLines(cm);
|
||||
for (var i = 0; i < state.marked.length; ++i)
|
||||
state.marked[i].clear();
|
||||
state.marked.length = 0;
|
||||
}
|
||||
|
||||
function clearErrorLines(cm) {
|
||||
cm.eachLine(function(line) {
|
||||
var has = line.wrapClass && /\bCodeMirror-lint-line-\w+\b/.exec(line.wrapClass);
|
||||
if (has) cm.removeLineClass(line, "wrap", has[0]);
|
||||
})
|
||||
}
|
||||
|
||||
function makeMarker(cm, labels, severity, multiple, tooltips) {
|
||||
var marker = document.createElement("div"), inner = marker;
|
||||
marker.className = "CodeMirror-lint-marker CodeMirror-lint-marker-" + severity;
|
||||
@ -123,7 +149,7 @@
|
||||
return tip;
|
||||
}
|
||||
|
||||
function lintAsync(cm, getAnnotations, passOptions) {
|
||||
function lintAsync(cm, getAnnotations) {
|
||||
var state = cm.state.lint
|
||||
var id = ++state.waitingFor
|
||||
function abort() {
|
||||
@ -136,22 +162,23 @@
|
||||
if (state.waitingFor != id) return
|
||||
if (arg2 && annotations instanceof CodeMirror) annotations = arg2
|
||||
cm.operation(function() {updateLinting(cm, annotations)})
|
||||
}, passOptions, cm);
|
||||
}, state.linterOptions, cm);
|
||||
}
|
||||
|
||||
function startLinting(cm) {
|
||||
var state = cm.state.lint, options = state.options;
|
||||
var state = cm.state.lint;
|
||||
if (!state) return;
|
||||
var options = state.options;
|
||||
/*
|
||||
* Passing rules in `options` property prevents JSHint (and other linters) from complaining
|
||||
* about unrecognized rules like `onUpdateLinting`, `delay`, `lintOnChange`, etc.
|
||||
*/
|
||||
var passOptions = options.options || options;
|
||||
var getAnnotations = options.getAnnotations || cm.getHelper(CodeMirror.Pos(0, 0), "lint");
|
||||
if (!getAnnotations) return;
|
||||
if (options.async || getAnnotations.async) {
|
||||
lintAsync(cm, getAnnotations, passOptions)
|
||||
lintAsync(cm, getAnnotations)
|
||||
} else {
|
||||
var annotations = getAnnotations(cm.getValue(), passOptions, cm);
|
||||
var annotations = getAnnotations(cm.getValue(), state.linterOptions, cm);
|
||||
if (!annotations) return;
|
||||
if (annotations.then) annotations.then(function(issues) {
|
||||
cm.operation(function() {updateLinting(cm, issues)})
|
||||
@ -161,8 +188,10 @@
|
||||
}
|
||||
|
||||
function updateLinting(cm, annotationsNotSorted) {
|
||||
var state = cm.state.lint;
|
||||
if (!state) return;
|
||||
var options = state.options;
|
||||
clearMarks(cm);
|
||||
var state = cm.state.lint, options = state.options;
|
||||
|
||||
var annotations = groupByLine(annotationsNotSorted);
|
||||
|
||||
@ -194,7 +223,10 @@
|
||||
// use original annotations[line] to show multiple messages
|
||||
if (state.hasGutter)
|
||||
cm.setGutterMarker(line, GUTTER_ID, makeMarker(cm, tipLabel, maxSeverity, annotations[line].length > 1,
|
||||
state.options.tooltips));
|
||||
options.tooltips));
|
||||
|
||||
if (options.highlightLines)
|
||||
cm.addLineClass(line, "wrap", LINT_LINE_ID + maxSeverity);
|
||||
}
|
||||
if (options.onUpdateLinting) options.onUpdateLinting(annotationsNotSorted, annotations, cm);
|
||||
}
|
||||
@ -203,7 +235,7 @@
|
||||
var state = cm.state.lint;
|
||||
if (!state) return;
|
||||
clearTimeout(state.timeout);
|
||||
state.timeout = setTimeout(function(){startLinting(cm);}, state.options.delay || 500);
|
||||
state.timeout = setTimeout(function(){startLinting(cm);}, state.options.delay);
|
||||
}
|
||||
|
||||
function popupTooltips(cm, annotations, e) {
|
||||
@ -243,8 +275,8 @@
|
||||
if (val) {
|
||||
var gutters = cm.getOption("gutters"), hasLintGutter = false;
|
||||
for (var i = 0; i < gutters.length; ++i) if (gutters[i] == GUTTER_ID) hasLintGutter = true;
|
||||
var state = cm.state.lint = new LintState(cm, parseOptions(cm, val), hasLintGutter);
|
||||
if (state.options.lintOnChange !== false)
|
||||
var state = cm.state.lint = new LintState(cm, val, hasLintGutter);
|
||||
if (state.options.lintOnChange)
|
||||
cm.on("change", onChange);
|
||||
if (state.options.tooltips != false && state.options.tooltips != "gutter")
|
||||
CodeMirror.on(cm.getWrapperElement(), "mouseover", state.onMouseOver);
|
||||
@ -254,6 +286,6 @@
|
||||
});
|
||||
|
||||
CodeMirror.defineExtension("performLint", function() {
|
||||
if (this.state.lint) startLinting(this);
|
||||
startLinting(this);
|
||||
});
|
||||
});
|
||||
|
||||
1
js/vendor/codemirror/lib/codemirror.css
vendored
1
js/vendor/codemirror/lib/codemirror.css
vendored
@ -68,7 +68,6 @@
|
||||
}
|
||||
.cm-animate-fat-cursor {
|
||||
width: auto;
|
||||
border: 0;
|
||||
-webkit-animation: blink 1.06s steps(1) infinite;
|
||||
-moz-animation: blink 1.06s steps(1) infinite;
|
||||
animation: blink 1.06s steps(1) infinite;
|
||||
|
||||
44
js/vendor/codemirror/lib/codemirror.js
vendored
44
js/vendor/codemirror/lib/codemirror.js
vendored
@ -3172,6 +3172,13 @@
|
||||
cursor.style.top = pos.top + "px";
|
||||
cursor.style.height = Math.max(0, pos.bottom - pos.top) * cm.options.cursorHeight + "px";
|
||||
|
||||
if (/\bcm-fat-cursor\b/.test(cm.getWrapperElement().className)) {
|
||||
var charPos = charCoords(cm, head, "div", null, null);
|
||||
if (charPos.right - charPos.left > 0) {
|
||||
cursor.style.width = (charPos.right - charPos.left) + "px";
|
||||
}
|
||||
}
|
||||
|
||||
if (pos.other) {
|
||||
// Secondary cursor, shown when on a 'jump' in bi-directional text
|
||||
var otherCursor = output.appendChild(elt("div", "\u00a0", "CodeMirror-cursor CodeMirror-secondarycursor"));
|
||||
@ -3344,10 +3351,14 @@
|
||||
function updateHeightsInViewport(cm) {
|
||||
var display = cm.display;
|
||||
var prevBottom = display.lineDiv.offsetTop;
|
||||
var viewTop = Math.max(0, display.scroller.getBoundingClientRect().top);
|
||||
var oldHeight = display.lineDiv.getBoundingClientRect().top;
|
||||
var mustScroll = 0;
|
||||
for (var i = 0; i < display.view.length; i++) {
|
||||
var cur = display.view[i], wrapping = cm.options.lineWrapping;
|
||||
var height = (void 0), width = 0;
|
||||
if (cur.hidden) { continue }
|
||||
oldHeight += cur.line.height;
|
||||
if (ie && ie_version < 8) {
|
||||
var bot = cur.node.offsetTop + cur.node.offsetHeight;
|
||||
height = bot - prevBottom;
|
||||
@ -3362,6 +3373,7 @@
|
||||
}
|
||||
var diff = cur.line.height - height;
|
||||
if (diff > .005 || diff < -.005) {
|
||||
if (oldHeight < viewTop) { mustScroll -= diff; }
|
||||
updateLineHeight(cur.line, height);
|
||||
updateWidgetHeight(cur.line);
|
||||
if (cur.rest) { for (var j = 0; j < cur.rest.length; j++)
|
||||
@ -3376,6 +3388,7 @@
|
||||
}
|
||||
}
|
||||
}
|
||||
if (Math.abs(mustScroll) > 2) { display.scroller.scrollTop += mustScroll; }
|
||||
}
|
||||
|
||||
// Read and store the height of line widgets associated with the
|
||||
@ -4386,6 +4399,10 @@
|
||||
// The element in which the editor lives.
|
||||
d.wrapper = elt("div", [d.scrollbarFiller, d.gutterFiller, d.scroller], "CodeMirror");
|
||||
|
||||
// This attribute is respected by automatic translation systems such as Google Translate,
|
||||
// and may also be respected by tools used by human translators.
|
||||
d.wrapper.setAttribute('translate', 'no');
|
||||
|
||||
// Work around IE7 z-index bug (not perfect, hence IE7 not really being supported)
|
||||
if (ie && ie_version < 8) { d.gutters.style.zIndex = -1; d.scroller.style.paddingRight = 0; }
|
||||
if (!webkit && !(gecko && mobile)) { d.scroller.draggable = true; }
|
||||
@ -4483,6 +4500,12 @@
|
||||
|
||||
function onScrollWheel(cm, e) {
|
||||
var delta = wheelEventDelta(e), dx = delta.x, dy = delta.y;
|
||||
var pixelsPerUnit = wheelPixelsPerUnit;
|
||||
if (e.deltaMode === 0) {
|
||||
dx = e.deltaX;
|
||||
dy = e.deltaY;
|
||||
pixelsPerUnit = 1;
|
||||
}
|
||||
|
||||
var display = cm.display, scroll = display.scroller;
|
||||
// Quit if there's nothing to scroll here
|
||||
@ -4511,10 +4534,10 @@
|
||||
// estimated pixels/delta value, we just handle horizontal
|
||||
// scrolling entirely here. It'll be slightly off from native, but
|
||||
// better than glitching out.
|
||||
if (dx && !gecko && !presto && wheelPixelsPerUnit != null) {
|
||||
if (dx && !gecko && !presto && pixelsPerUnit != null) {
|
||||
if (dy && canScrollY)
|
||||
{ updateScrollTop(cm, Math.max(0, scroll.scrollTop + dy * wheelPixelsPerUnit)); }
|
||||
setScrollLeft(cm, Math.max(0, scroll.scrollLeft + dx * wheelPixelsPerUnit));
|
||||
{ updateScrollTop(cm, Math.max(0, scroll.scrollTop + dy * pixelsPerUnit)); }
|
||||
setScrollLeft(cm, Math.max(0, scroll.scrollLeft + dx * pixelsPerUnit));
|
||||
// Only prevent default scrolling if vertical scrolling is
|
||||
// actually possible. Otherwise, it causes vertical scroll
|
||||
// jitter on OSX trackpads when deltaX is small and deltaY
|
||||
@ -4527,15 +4550,15 @@
|
||||
|
||||
// 'Project' the visible viewport to cover the area that is being
|
||||
// scrolled into view (if we know enough to estimate it).
|
||||
if (dy && wheelPixelsPerUnit != null) {
|
||||
var pixels = dy * wheelPixelsPerUnit;
|
||||
if (dy && pixelsPerUnit != null) {
|
||||
var pixels = dy * pixelsPerUnit;
|
||||
var top = cm.doc.scrollTop, bot = top + display.wrapper.clientHeight;
|
||||
if (pixels < 0) { top = Math.max(0, top + pixels - 50); }
|
||||
else { bot = Math.min(cm.doc.height, bot + pixels + 50); }
|
||||
updateDisplaySimple(cm, {top: top, bottom: bot});
|
||||
}
|
||||
|
||||
if (wheelSamples < 20) {
|
||||
if (wheelSamples < 20 && e.deltaMode !== 0) {
|
||||
if (display.wheelStartX == null) {
|
||||
display.wheelStartX = scroll.scrollLeft; display.wheelStartY = scroll.scrollTop;
|
||||
display.wheelDX = dx; display.wheelDY = dy;
|
||||
@ -6143,6 +6166,7 @@
|
||||
getRange: function(from, to, lineSep) {
|
||||
var lines = getBetween(this, clipPos(this, from), clipPos(this, to));
|
||||
if (lineSep === false) { return lines }
|
||||
if (lineSep === '') { return lines.join('') }
|
||||
return lines.join(lineSep || this.lineSeparator())
|
||||
},
|
||||
|
||||
@ -8211,7 +8235,7 @@
|
||||
}
|
||||
|
||||
function hiddenTextarea() {
|
||||
var te = elt("textarea", null, null, "position: absolute; bottom: -1em; padding: 0; width: 1px; height: 1em; outline: none");
|
||||
var te = elt("textarea", null, null, "position: absolute; bottom: -1em; padding: 0; width: 1px; height: 1em; min-height: 1em; outline: none");
|
||||
var div = elt("div", [te], null, "overflow: hidden; position: relative; width: 3px; height: 0px;");
|
||||
// The textarea is kept positioned near the cursor to prevent the
|
||||
// fact that it'll be scrolled into view on input from scrolling
|
||||
@ -8975,9 +8999,11 @@
|
||||
ContentEditableInput.prototype.supportsTouch = function () { return true };
|
||||
|
||||
ContentEditableInput.prototype.receivedFocus = function () {
|
||||
var this$1 = this;
|
||||
|
||||
var input = this;
|
||||
if (this.selectionInEditor())
|
||||
{ this.pollSelection(); }
|
||||
{ setTimeout(function () { return this$1.pollSelection(); }, 20); }
|
||||
else
|
||||
{ runInOp(this.cm, function () { return input.cm.curOp.selectionChanged = true; }); }
|
||||
|
||||
@ -9806,7 +9832,7 @@
|
||||
|
||||
addLegacyProps(CodeMirror);
|
||||
|
||||
CodeMirror.version = "5.61.1";
|
||||
CodeMirror.version = "5.63.3";
|
||||
|
||||
return CodeMirror;
|
||||
|
||||
|
||||
@ -482,7 +482,7 @@ CodeMirror.defineMode("javascript", function(config, parserConfig) {
|
||||
function quasi(type, value) {
|
||||
if (type != "quasi") return pass();
|
||||
if (value.slice(value.length - 2) != "${") return cont(quasi);
|
||||
return cont(expression, continueQuasi);
|
||||
return cont(maybeexpression, continueQuasi);
|
||||
}
|
||||
function continueQuasi(type) {
|
||||
if (type == "}") {
|
||||
|
||||
18
js/vendor/codemirror/mode/xml/xml.js
vendored
18
js/vendor/codemirror/mode/xml/xml.js
vendored
@ -187,6 +187,10 @@ CodeMirror.defineMode("xml", function(editorConf, config_) {
|
||||
};
|
||||
}
|
||||
|
||||
function lower(tagName) {
|
||||
return tagName && tagName.toLowerCase();
|
||||
}
|
||||
|
||||
function Context(state, tagName, startOfLine) {
|
||||
this.prev = state.context;
|
||||
this.tagName = tagName || "";
|
||||
@ -205,8 +209,8 @@ CodeMirror.defineMode("xml", function(editorConf, config_) {
|
||||
return;
|
||||
}
|
||||
parentTagName = state.context.tagName;
|
||||
if (!config.contextGrabbers.hasOwnProperty(parentTagName) ||
|
||||
!config.contextGrabbers[parentTagName].hasOwnProperty(nextTagName)) {
|
||||
if (!config.contextGrabbers.hasOwnProperty(lower(parentTagName)) ||
|
||||
!config.contextGrabbers[lower(parentTagName)].hasOwnProperty(lower(nextTagName))) {
|
||||
return;
|
||||
}
|
||||
popContext(state);
|
||||
@ -240,7 +244,7 @@ CodeMirror.defineMode("xml", function(editorConf, config_) {
|
||||
if (type == "word") {
|
||||
var tagName = stream.current();
|
||||
if (state.context && state.context.tagName != tagName &&
|
||||
config.implicitlyClosed.hasOwnProperty(state.context.tagName))
|
||||
config.implicitlyClosed.hasOwnProperty(lower(state.context.tagName)))
|
||||
popContext(state);
|
||||
if ((state.context && state.context.tagName == tagName) || config.matchClosing === false) {
|
||||
setStyle = "tag";
|
||||
@ -279,7 +283,7 @@ CodeMirror.defineMode("xml", function(editorConf, config_) {
|
||||
var tagName = state.tagName, tagStart = state.tagStart;
|
||||
state.tagName = state.tagStart = null;
|
||||
if (type == "selfcloseTag" ||
|
||||
config.autoSelfClosers.hasOwnProperty(tagName)) {
|
||||
config.autoSelfClosers.hasOwnProperty(lower(tagName))) {
|
||||
maybePopContext(state, tagName);
|
||||
} else {
|
||||
maybePopContext(state, tagName);
|
||||
@ -359,7 +363,7 @@ CodeMirror.defineMode("xml", function(editorConf, config_) {
|
||||
if (context.tagName == tagAfter[2]) {
|
||||
context = context.prev;
|
||||
break;
|
||||
} else if (config.implicitlyClosed.hasOwnProperty(context.tagName)) {
|
||||
} else if (config.implicitlyClosed.hasOwnProperty(lower(context.tagName))) {
|
||||
context = context.prev;
|
||||
} else {
|
||||
break;
|
||||
@ -367,8 +371,8 @@ CodeMirror.defineMode("xml", function(editorConf, config_) {
|
||||
}
|
||||
} else if (tagAfter) { // Opening tag spotted
|
||||
while (context) {
|
||||
var grabbers = config.contextGrabbers[context.tagName];
|
||||
if (grabbers && grabbers.hasOwnProperty(tagAfter[2]))
|
||||
var grabbers = config.contextGrabbers[lower(context.tagName)];
|
||||
if (grabbers && grabbers.hasOwnProperty(lower(tagAfter[2])))
|
||||
context = context.prev;
|
||||
else
|
||||
break;
|
||||
|
||||
4
js/vendor/openlayers/OpenLayers.js
vendored
4
js/vendor/openlayers/OpenLayers.js
vendored
File diff suppressed because one or more lines are too long
2
js/vendor/openlayers/OpenLayers.js.map
vendored
2
js/vendor/openlayers/OpenLayers.js.map
vendored
File diff suppressed because one or more lines are too long
26
js/vendor/openlayers/theme/ol.css
vendored
26
js/vendor/openlayers/theme/ol.css
vendored
@ -1,7 +1,8 @@
|
||||
.ol-box {
|
||||
box-sizing: border-box;
|
||||
border-radius: 2px;
|
||||
border: 2px solid blue;
|
||||
border: 1.5px solid rgb(179,197,219);
|
||||
background-color: rgba(255,255,255,0.4);
|
||||
}
|
||||
|
||||
.ol-mouse-position {
|
||||
@ -130,9 +131,9 @@
|
||||
margin: 1px;
|
||||
padding: 0;
|
||||
color: white;
|
||||
font-size: 1.14em;
|
||||
font-weight: bold;
|
||||
text-decoration: none;
|
||||
font-size: inherit;
|
||||
text-align: center;
|
||||
height: 1.375em;
|
||||
width: 1.375em;
|
||||
@ -178,13 +179,20 @@
|
||||
bottom: .5em;
|
||||
right: .5em;
|
||||
max-width: calc(100% - 1.3em);
|
||||
display: flex;
|
||||
flex-flow: row-reverse;
|
||||
align-items: center;
|
||||
}
|
||||
.ol-attribution a {
|
||||
color: rgba(0,60,136,0.7);
|
||||
text-decoration: none;
|
||||
}
|
||||
|
||||
.ol-attribution ul {
|
||||
margin: 0;
|
||||
padding: 0 .5em;
|
||||
padding: 1px .5em;
|
||||
color: #000;
|
||||
text-shadow: 0 0 2px #fff;
|
||||
font-size: 12px;
|
||||
}
|
||||
.ol-attribution li {
|
||||
display: inline;
|
||||
@ -198,8 +206,8 @@
|
||||
max-width: inherit;
|
||||
vertical-align: middle;
|
||||
}
|
||||
.ol-attribution ul, .ol-attribution button {
|
||||
display: inline-block;
|
||||
.ol-attribution button {
|
||||
flex-shrink: 0;
|
||||
}
|
||||
.ol-attribution.ol-collapsed ul {
|
||||
display: none;
|
||||
@ -245,7 +253,7 @@
|
||||
}
|
||||
.ol-overviewmap .ol-overviewmap-map,
|
||||
.ol-overviewmap button {
|
||||
display: inline-block;
|
||||
display: block;
|
||||
}
|
||||
.ol-overviewmap .ol-overviewmap-map {
|
||||
border: 1px solid #7b98bc;
|
||||
@ -253,8 +261,8 @@
|
||||
margin: 2px;
|
||||
width: 150px;
|
||||
}
|
||||
.ol-overviewmap:not(.ol-collapsed) button{
|
||||
bottom: 1px;
|
||||
.ol-overviewmap:not(.ol-collapsed) button {
|
||||
bottom: 2px;
|
||||
left: 2px;
|
||||
position: absolute;
|
||||
}
|
||||
|
||||
30
package.json
30
package.json
@ -10,12 +10,12 @@
|
||||
"node": ">=10"
|
||||
},
|
||||
"dependencies": {
|
||||
"@babel/cli": "^7.13.10",
|
||||
"@babel/core": "^7.13.10",
|
||||
"@babel/preset-env": "^7.13.12",
|
||||
"@babel/cli": "^7.15.7",
|
||||
"@babel/core": "^7.15.8",
|
||||
"@babel/preset-env": "^7.15.8",
|
||||
"blueimp-md5": "^2.18.0",
|
||||
"bootstrap": "4.6.0",
|
||||
"codemirror": "5.61.1",
|
||||
"bootstrap": "4.6.1",
|
||||
"codemirror": "5.63.3",
|
||||
"jquery": "3.6.0",
|
||||
"jquery-debounce-throttle": "^1.0.6-rc.0",
|
||||
"jquery-fullscreen-plugin": "^1.1.5",
|
||||
@ -29,7 +29,7 @@
|
||||
"js-cookie": "2.2.1",
|
||||
"kbwood-jquery-svg": "https://github.com/kbwood/svg/archive/1.5.0.tar.gz",
|
||||
"locutus.sprintf": "^2.0.14-code-lts.2",
|
||||
"ol": "6.4.3",
|
||||
"ol": "6.9.0",
|
||||
"popper.js": "^1.16.1",
|
||||
"sass": "^1.32.8",
|
||||
"stickyfilljs": "2.1.0",
|
||||
@ -41,22 +41,18 @@
|
||||
},
|
||||
"devDependencies": {
|
||||
"babel-jest": "^26.6.3",
|
||||
"eslint": "^7.22.0",
|
||||
"eslint-plugin-compat": "^3.9.0",
|
||||
"eslint-plugin-no-jquery": "^2.5.0",
|
||||
"eslint": "^7.32.0",
|
||||
"eslint-plugin-compat": "^3.13.0",
|
||||
"eslint-plugin-no-jquery": "^2.7.0",
|
||||
"jest": "^26.6.3",
|
||||
"stylelint": "^13.12.0",
|
||||
"stylelint-config-recommended-scss": "^4.2.0",
|
||||
"stylelint": "^13.13.1",
|
||||
"stylelint-config-recommended-scss": "^4.3.0",
|
||||
"stylelint-config-standard": "^22.0.0",
|
||||
"stylelint-scss": "^3.19.0"
|
||||
},
|
||||
"resolutions": {
|
||||
"kind-of": "^6.0.3",
|
||||
"lodash": "^4.17.21"
|
||||
"stylelint-scss": "^3.21.0"
|
||||
},
|
||||
"scripts": {
|
||||
"postinstall": "yarn run build",
|
||||
"build": "yarn run css-compile --quiet --style=compressed && yarn run js-compile",
|
||||
"build": "yarn run css-compile --style=compressed && yarn run js-compile",
|
||||
"css-compile": "sass themes/pmahomme/scss:themes/pmahomme/css themes/original/scss:themes/original/css themes/metro/scss:themes/metro/css themes/bootstrap/scss:themes/bootstrap/css",
|
||||
"css-lint": "stylelint --syntax scss \"themes/**/scss/*.scss\"",
|
||||
"js-lint": "eslint js/src test/javascript test/jest jest.config.js",
|
||||
|
||||
@ -2432,8 +2432,8 @@ input#auto_increment_opt {
|
||||
|
||||
height: $height;
|
||||
width: $width;
|
||||
margin-top: $height / -2;
|
||||
margin-#{$left}: $width / -2;
|
||||
margin-top: $height * -0.5;
|
||||
margin-#{$left}: $width * -0.5;
|
||||
background: url("../img/col_pointer.png");
|
||||
position: absolute;
|
||||
}
|
||||
|
||||
@ -2409,8 +2409,8 @@ form.append_fields_form .tblFooters {
|
||||
|
||||
height: $height;
|
||||
width: $width;
|
||||
margin-#{$left}: $height / -2;
|
||||
margin-top: $width / -2;
|
||||
margin-#{$left}: $height * -0.5;
|
||||
margin-top: $width * -0.5;
|
||||
position: absolute;
|
||||
background: url("../img/col_pointer.png");
|
||||
}
|
||||
|
||||
@ -2113,8 +2113,8 @@ input#auto_increment_opt {
|
||||
|
||||
height: $height;
|
||||
width: $width;
|
||||
margin-top: $height / -2;
|
||||
margin-#{$left}: $width / -2;
|
||||
margin-top: $height * -0.5;
|
||||
margin-#{$left}: $width * -0.5;
|
||||
position: absolute;
|
||||
background: url("../img/col_pointer.png");
|
||||
}
|
||||
|
||||
@ -2496,8 +2496,8 @@ input#auto_increment_opt {
|
||||
|
||||
height: $height;
|
||||
width: $width;
|
||||
margin-top: $height / -2;
|
||||
margin-#{$left}: $width / -2;
|
||||
margin-top: $height * -0.5;
|
||||
margin-#{$left}: $width * -0.5;
|
||||
background: url("../img/col_pointer.png");
|
||||
position: absolute;
|
||||
}
|
||||
|
||||
Loading…
Reference in New Issue
Block a user