+ // sorts node children by the best axis for split
_chooseSplitAxis: function(node, m, M) {
var compareMinX = node.leaf ? this.compareMinX : compareNodeMinX, compareMinY = node.leaf ? this.compareMinY : compareNodeMinY, xMargin = this._allDistMargin(node, m, M, compareMinX), yMargin = this._allDistMargin(node, m, M, compareMinY);
if (xMargin < yMargin)
node.children.sort(compareMinX);
},
_chooseSplitAxis: function(node, m, M) {
var compareMinX = node.leaf ? this.compareMinX : compareNodeMinX, compareMinY = node.leaf ? this.compareMinY : compareNodeMinY, xMargin = this._allDistMargin(node, m, M, compareMinX), yMargin = this._allDistMargin(node, m, M, compareMinY);
if (xMargin < yMargin)
node.children.sort(compareMinX);
},
+ // total margin of all possible split distributions where each node is at least m full
_allDistMargin: function(node, m, M, compare) {
node.children.sort(compare);
var toBBox = this.toBBox, leftBBox = distBBox(node, 0, m, toBBox), rightBBox = distBBox(node, M - m, M, toBBox), margin = bboxMargin(leftBBox) + bboxMargin(rightBBox), i2, child;
_allDistMargin: function(node, m, M, compare) {
node.children.sort(compare);
var toBBox = this.toBBox, leftBBox = distBBox(node, 0, m, toBBox), rightBBox = distBBox(node, M - m, M, toBBox), margin = bboxMargin(leftBBox) + bboxMargin(rightBBox), i2, child;
+ var allowUpperCaseTagValues = /network|taxon|genus|species|brand|grape_variety|royal_cypher|listed_status|booth|rating|stars|:output|_hours|_times|_ref|manufacturer|country|target|brewery|cai_scale|traffic_sign/;
+ console.warn("marked(): callback is deprecated since version 5.0.0, should not be used and will be removed in the future. Read more here: https://marked.js.org/using_pro#async");
+ }
+ if (opt.sanitize || opt.sanitizer) {
console.warn("marked(): sanitize and sanitizer parameters are deprecated since version 0.7.0, should not be used and will be removed in the future. Read more here: https://marked.js.org/#/USING_ADVANCED.md#options");
}
console.warn("marked(): sanitize and sanitizer parameters are deprecated since version 0.7.0, should not be used and will be removed in the future. Read more here: https://marked.js.org/#/USING_ADVANCED.md#options");
}
- }
- function repeatString(pattern, count) {
- if (count < 1) {
- return "";
+ if (opt.highlight || opt.langPrefix !== "language-") {
+ console.warn("marked(): highlight and langPrefix parameters are deprecated since version 5.0.0, should not be used and will be removed in the future. Instead use https://www.npmjs.com/package/marked-highlight.");
}
}
- let result = "";
- while (count > 1) {
- if (count & 1) {
- result += pattern;
- }
- count >>= 1;
- pattern += pattern;
+ if (opt.mangle) {
+ console.warn("marked(): mangle parameter is enabled by default, but is deprecated since version 5.0.0, and will be removed in the future. To clear this warning, install https://www.npmjs.com/package/marked-mangle, or disable by setting `{mangle: false}`.");
+ }
+ if (opt.baseUrl) {
+ console.warn("marked(): baseUrl parameter is deprecated since version 5.0.0, should not be used and will be removed in the future. Instead use https://www.npmjs.com/package/marked-base-url.");
+ }
+ if (opt.smartypants) {
+ console.warn("marked(): smartypants parameter is deprecated since version 5.0.0, should not be used and will be removed in the future. Instead use https://www.npmjs.com/package/marked-smartypants.");
+ }
+ if (opt.xhtml) {
+ console.warn("marked(): xhtml parameter is deprecated since version 5.0.0, should not be used and will be removed in the future. Instead use https://www.npmjs.com/package/marked-xhtml.");
+ }
+ if (opt.headerIds || opt.headerPrefix) {
+ console.warn("marked(): headerIds and headerPrefix parameters enabled by default, but are deprecated since version 5.0.0, and will be removed in the future. To clear this warning, install https://www.npmjs.com/package/marked-gfm-heading-id, or disable by setting `{headerIds: false}`.");
- return t === "flags" || t === "transit" || k === "landuse" || v === "atm" || v === "bicycle_parking" || v === "car_sharing" || v === "caravan_site" || v === "charging_station" || v === "dog_park" || v === "parking" || v === "phone" || v === "playground" || v === "post_box" || v === "public_bookcase" || v === "recycling" || v === "vending_machine";
+ return (/* @__PURE__ */ new Date()).getTime() - _pointer.startTime <= _maxTimespan && // all pointer events must occur within a small distance of the first pointerdown
+ that.warnings.push(`Duplicate cache key "${kvnsimple}" in trees "${t}" and "${existing}", check items: ${items}`);
+ return;
}
}
+ seenTree.set(kvnsimple, t);
}
}
- });
- _map.on("drawn.zoomToEntity", () => {
- if (!context.hasEntity(entityID))
- return;
- _map.on("drawn.zoomToEntity", null);
- context.on("enter.zoomToEntity", null);
- context.enter(modeSelect(context, [entityID]));
- });
- context.on("enter.zoomToEntity", () => {
- if (_mode.id !== "browse") {
- _map.on("drawn.zoomToEntity", null);
- context.on("enter.zoomToEntity", null);
- }
- });
- };
- let _minEditableZoom = 16;
- context.minEditableZoom = function(val) {
- if (!arguments.length)
- return _minEditableZoom;
- _minEditableZoom = val;
- if (_connection) {
- _connection.tileZoom(val);
}
}
- return context;
- };
- context.maxCharsForTagKey = () => 255;
- context.maxCharsForTagValue = () => 255;
- context.maxCharsForRelationRole = () => 255;
- function cleanOsmString(val, maxChars) {
- if (val === void 0 || val === null) {
- val = "";
- } else {
- val = val.toString();
+ function skipGenericKVMatches(t, k, v) {
+ return t === "flags" || t === "transit" || k === "landuse" || v === "atm" || v === "bicycle_parking" || v === "car_sharing" || v === "caravan_site" || v === "charging_station" || v === "dog_park" || v === "parking" || v === "phone" || v === "playground" || v === "post_box" || v === "public_bookcase" || v === "recycling" || v === "vending_machine";
- var re2 = /network|taxon|genus|species|brand|grape_variety|royal_cypher|listed_status|booth|rating|stars|:output|_hours|_times|_ref|manufacturer|country|target|brewery|cai_scale/;
- var allowUpperCase = re2.test(params.key);
+ var allowUpperCase = allowUpperCaseTagValues.test(params.key);
var f2 = filterValues(allowUpperCase);
var result = d.data.filter(f2).map(valKeyDescription);
_taginfoCache[url] = result;
var f2 = filterValues(allowUpperCase);
var result = d.data.filter(f2).map(valKeyDescription);