planning
All checks were successful
Publish To Prod / deploy_and_publish (push) Successful in 35s

This commit is contained in:
2024-10-14 09:15:30 +02:00
parent bcba00a730
commit 6e64e138e2
21059 changed files with 2317811 additions and 1 deletions

22
node_modules/ol/AssertionError.d.ts generated vendored Normal file
View File

@@ -0,0 +1,22 @@
export default AssertionError;
/**
* Error object thrown when an assertion failed. This is an ECMA-262 Error,
* extended with a `code` property.
* See https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Error.
*/
declare class AssertionError extends Error {
/**
* @param {number} code Error code.
*/
constructor(code: number);
/**
* Error code. The meaning of the code can be found on
* https://openlayers.org/en/latest/doc/errors/ (replace `latest` with
* the version found in the OpenLayers script's header comment if a version
* other than the latest is used).
* @type {number}
* @api
*/
code: number;
}
//# sourceMappingURL=AssertionError.d.ts.map

1
node_modules/ol/AssertionError.d.ts.map generated vendored Normal file
View File

@@ -0,0 +1 @@
{"version":3,"file":"AssertionError.d.ts","sourceRoot":"","sources":["src/AssertionError.js"],"names":[],"mappings":";AAKA;;;;GAIG;AACH;IACE;;OAEG;IACH,kBAFW,MAAM,EA8BhB;IAjBC;;;;;;;OAOG;IACH,MAHU,MAAM,CAGA;CAUnB"}

59
node_modules/ol/AssertionError.js generated vendored Normal file
View File

@@ -0,0 +1,59 @@
var __extends = (this && this.__extends) || (function () {
var extendStatics = function (d, b) {
extendStatics = Object.setPrototypeOf ||
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };
return extendStatics(d, b);
};
return function (d, b) {
if (typeof b !== "function" && b !== null)
throw new TypeError("Class extends value " + String(b) + " is not a constructor or null");
extendStatics(d, b);
function __() { this.constructor = d; }
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
};
})();
/**
* @module ol/AssertionError
*/
import { VERSION } from './util.js';
/**
* Error object thrown when an assertion failed. This is an ECMA-262 Error,
* extended with a `code` property.
* See https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Error.
*/
var AssertionError = /** @class */ (function (_super) {
__extends(AssertionError, _super);
/**
* @param {number} code Error code.
*/
function AssertionError(code) {
var _this = this;
var path = VERSION === 'latest' ? VERSION : 'v' + VERSION.split('-')[0];
var message = 'Assertion failed. See https://openlayers.org/en/' +
path +
'/doc/errors/#' +
code +
' for details.';
_this = _super.call(this, message) || this;
/**
* Error code. The meaning of the code can be found on
* https://openlayers.org/en/latest/doc/errors/ (replace `latest` with
* the version found in the OpenLayers script's header comment if a version
* other than the latest is used).
* @type {number}
* @api
*/
_this.code = code;
/**
* @type {string}
*/
_this.name = 'AssertionError';
// Re-assign message, see https://github.com/Rich-Harris/buble/issues/40
_this.message = message;
return _this;
}
return AssertionError;
}(Error));
export default AssertionError;
//# sourceMappingURL=AssertionError.js.map

1
node_modules/ol/AssertionError.js.map generated vendored Normal file
View File

@@ -0,0 +1 @@
{"version":3,"file":"AssertionError.js","sourceRoot":"","sources":["src/AssertionError.js"],"names":[],"mappings":";;;;;;;;;;;;;;;AAAA;;GAEG;AACH,OAAO,EAAC,OAAO,EAAC,MAAM,WAAW,CAAC;AAElC;;;;GAIG;AACH;IAA6B,kCAAK;IAChC;;OAEG;IACH,wBAAY,IAAI;QAAhB,iBA4BC;QA3BC,IAAM,IAAI,GAAG,OAAO,KAAK,QAAQ,CAAC,CAAC,CAAC,OAAO,CAAC,CAAC,CAAC,GAAG,GAAG,OAAO,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,CAAC;QAC1E,IAAM,OAAO,GACX,kDAAkD;YAClD,IAAI;YACJ,eAAe;YACf,IAAI;YACJ,eAAe,CAAC;gBAElB,kBAAM,OAAO,CAAC;QAEd;;;;;;;WAOG;QACH,KAAI,CAAC,IAAI,GAAG,IAAI,CAAC;QAEjB;;WAEG;QACH,KAAI,CAAC,IAAI,GAAG,gBAAgB,CAAC;QAE7B,wEAAwE;QACxE,KAAI,CAAC,OAAO,GAAG,OAAO,CAAC;;IACzB,CAAC;IACH,qBAAC;AAAD,CAAC,AAjCD,CAA6B,KAAK,GAiCjC;AAED,eAAe,cAAc,CAAC"}

192
node_modules/ol/Collection.d.ts generated vendored Normal file
View File

@@ -0,0 +1,192 @@
/**
* @classdesc
* Events emitted by {@link module:ol/Collection~Collection} instances are instances of this
* type.
*/
export class CollectionEvent extends Event {
/**
* @param {import("./CollectionEventType.js").default} type Type.
* @param {*} [opt_element] Element.
* @param {number} [opt_index] The index of the added or removed element.
*/
constructor(type: any, opt_element?: any, opt_index?: number | undefined);
/**
* The element that is added to or removed from the collection.
* @type {*}
* @api
*/
element: any;
/**
* The index of the added or removed element.
* @type {number}
* @api
*/
index: number;
}
export default Collection;
/**
* *
*/
export type CollectionOnSignature<Return> = import("./Observable").OnSignature<import("./Observable").EventTypes, import("./events/Event.js").default, Return> & import("./Observable").OnSignature<import("./ObjectEventType").Types | 'change:length', import("./Object").ObjectEvent, Return> & import("./Observable").OnSignature<'add' | 'remove', CollectionEvent, Return> & import("./Observable").CombinedOnSignature<import("./Observable").EventTypes | import("./ObjectEventType").Types | 'change:length' | 'add' | 'remove', Return>;
export type Options = {
/**
* Disallow the same item from being added to
* the collection twice.
*/
unique?: boolean | undefined;
};
import Event from "./events/Event.js";
/***
* @template Return
* @typedef {import("./Observable").OnSignature<import("./Observable").EventTypes, import("./events/Event.js").default, Return> &
* import("./Observable").OnSignature<import("./ObjectEventType").Types|'change:length', import("./Object").ObjectEvent, Return> &
* import("./Observable").OnSignature<'add'|'remove', CollectionEvent, Return> &
* import("./Observable").CombinedOnSignature<import("./Observable").EventTypes|import("./ObjectEventType").Types|
* 'change:length'|'add'|'remove',Return>} CollectionOnSignature
*/
/**
* @typedef {Object} Options
* @property {boolean} [unique=false] Disallow the same item from being added to
* the collection twice.
*/
/**
* @classdesc
* An expanded version of standard JS Array, adding convenience methods for
* manipulation. Add and remove changes to the Collection trigger a Collection
* event. Note that this does not cover changes to the objects _within_ the
* Collection; they trigger events on the appropriate object, not on the
* Collection as a whole.
*
* @fires CollectionEvent
*
* @template T
* @api
*/
declare class Collection<T> extends BaseObject {
/**
* @param {Array<T>} [opt_array] Array.
* @param {Options} [opt_options] Collection options.
*/
constructor(opt_array?: T[] | undefined, opt_options?: Options | undefined);
/***
* @type {CollectionOnSignature<import("./events").EventsKey>}
*/
on: CollectionOnSignature<import("./events").EventsKey>;
/***
* @type {CollectionOnSignature<import("./events").EventsKey>}
*/
once: CollectionOnSignature<import("./events").EventsKey>;
/***
* @type {CollectionOnSignature<void>}
*/
un: CollectionOnSignature<void>;
/**
* @private
* @type {boolean}
*/
private unique_;
/**
* @private
* @type {!Array<T>}
*/
private array_;
/**
* Remove all elements from the collection.
* @api
*/
clear(): void;
/**
* Add elements to the collection. This pushes each item in the provided array
* to the end of the collection.
* @param {!Array<T>} arr Array.
* @return {Collection<T>} This collection.
* @api
*/
extend(arr: Array<T>): Collection<T>;
/**
* Iterate over each element, calling the provided callback.
* @param {function(T, number, Array<T>): *} f The function to call
* for every element. This function takes 3 arguments (the element, the
* index and the array). The return value is ignored.
* @api
*/
forEach(f: (arg0: T, arg1: number, arg2: Array<T>) => any): void;
/**
* Get a reference to the underlying Array object. Warning: if the array
* is mutated, no events will be dispatched by the collection, and the
* collection's "length" property won't be in sync with the actual length
* of the array.
* @return {!Array<T>} Array.
* @api
*/
getArray(): Array<T>;
/**
* Get the element at the provided index.
* @param {number} index Index.
* @return {T} Element.
* @api
*/
item(index: number): T;
/**
* Get the length of this collection.
* @return {number} The length of the array.
* @observable
* @api
*/
getLength(): number;
/**
* Insert an element at the provided index.
* @param {number} index Index.
* @param {T} elem Element.
* @api
*/
insertAt(index: number, elem: T): void;
/**
* Remove the last element of the collection and return it.
* Return `undefined` if the collection is empty.
* @return {T|undefined} Element.
* @api
*/
pop(): T | undefined;
/**
* Insert the provided element at the end of the collection.
* @param {T} elem Element.
* @return {number} New length of the collection.
* @api
*/
push(elem: T): number;
/**
* Remove the first occurrence of an element from the collection.
* @param {T} elem Element.
* @return {T|undefined} The removed element or undefined if none found.
* @api
*/
remove(elem: T): T | undefined;
/**
* Remove the element at the provided index and return it.
* Return `undefined` if the collection does not contain this index.
* @param {number} index Index.
* @return {T|undefined} Value.
* @api
*/
removeAt(index: number): T | undefined;
/**
* Set the element at the provided index.
* @param {number} index Index.
* @param {T} elem Element.
* @api
*/
setAt(index: number, elem: T): void;
/**
* @private
*/
private updateLength_;
/**
* @private
* @param {T} elem Element.
* @param {number} [opt_except] Optional index to ignore.
*/
private assertUnique_;
}
import BaseObject from "./Object.js";
//# sourceMappingURL=Collection.d.ts.map

1
node_modules/ol/Collection.d.ts.map generated vendored Normal file
View File

@@ -0,0 +1 @@
{"version":3,"file":"Collection.d.ts","sourceRoot":"","sources":["src/Collection.js"],"names":[],"mappings":"AAgBA;;;;GAIG;AACH;IACE;;;;OAIG;IACH,0EAgBC;IAbC;;;;OAIG;IACH,aAA0B;IAE1B;;;;OAIG;IACH,OAHU,MAAM,CAGM;CAEzB;;;;;4CAIY,OAAO,cAAc,EAAE,WAAW,CAAC,OAAO,cAAc,EAAE,UAAU,EAAE,OAAO,mBAAmB,EAAE,OAAO,EAAE,MAAM,CAAC,GAC9H,OAAW,cAAc,EAAE,WAAW,CAAC,OAAO,mBAAmB,EAAE,KAAK,GAAC,eAAe,EAAE,OAAO,UAAU,EAAE,WAAW,EAAE,MAAM,CAAC,GACjI,OAAW,cAAc,EAAE,WAAW,CAAC,KAAK,GAAC,QAAQ,EAAE,eAAe,EAAE,MAAM,CAAC,GAC/E,OAAW,cAAc,EAAE,mBAAmB,CAAC,OAAO,cAAc,EAAE,UAAU,GAAC,OAAO,mBAAmB,EAAE,KAAK,GAClH,eAAqB,GAAC,KAAK,GAAC,QAAQ,EAAC,MAAM,CAAC;;;;;;;;;AAN7C;;;;;;;GAOG;AAEH;;;;GAIG;AAEH;;;;;;;;;;;;GAYG;AACH;IACE;;;OAGG;IACH,4EAuCC;IApCC;;OAEG;IACH,IAFU,sBAAsB,OAAO,UAAU,EAAE,SAAS,CAAC,CAEtD;IAEP;;OAEG;IACH,MAFU,sBAAsB,OAAO,UAAU,EAAE,SAAS,CAAC,CAEpD;IAET;;OAEG;IACH,IAFU,sBAAsB,IAAI,CAAC,CAE9B;IAIP;;;OAGG;IACH,gBAA+B;IAE/B;;;OAGG;IACH,eAAwC;IAW1C;;;OAGG;IACH,cAIC;IAED;;;;;;OAMG;IACH,YAJY,MAAM,CAAC,CAAC,GACR,WAAW,CAAC,CAAC,CAQxB;IAED;;;;;;OAMG;IACH,kBALoB,CAAC,QAAE,MAAM,QAAE,MAAM,CAAC,CAAC,gBAUtC;IAED;;;;;;;OAOG;IACH,YAHa,MAAM,CAAC,CAAC,CAKpB;IAED;;;;;OAKG;IACH,YAJW,MAAM,GACL,CAAC,CAKZ;IAED;;;;;OAKG;IACH,aAJY,MAAM,CAMjB;IAED;;;;;OAKG;IACH,gBAJW,MAAM,QACN,CAAC,QAYX;IAED;;;;;OAKG;IACH,OAHY,CAAC,GAAC,SAAS,CAKtB;IAED;;;;;OAKG;IACH,WAJW,CAAC,GACA,MAAM,CAUjB;IAED;;;;;OAKG;IACH,aAJW,CAAC,GACA,CAAC,GAAC,SAAS,CAWtB;IAED;;;;;;OAMG;IACH,gBAJW,MAAM,GACL,CAAC,GAAC,SAAS,CAWtB;IAED;;;;;OAKG;IACH,aAJW,MAAM,QACN,CAAC,QAuBX;IAED;;OAEG;IACH,sBAEC;IAED;;;;OAIG;IACH,sBAMC;CACF"}

301
node_modules/ol/Collection.js generated vendored Normal file
View File

@@ -0,0 +1,301 @@
var __extends = (this && this.__extends) || (function () {
var extendStatics = function (d, b) {
extendStatics = Object.setPrototypeOf ||
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };
return extendStatics(d, b);
};
return function (d, b) {
if (typeof b !== "function" && b !== null)
throw new TypeError("Class extends value " + String(b) + " is not a constructor or null");
extendStatics(d, b);
function __() { this.constructor = d; }
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
};
})();
/**
* @module ol/Collection
*/
import AssertionError from './AssertionError.js';
import BaseObject from './Object.js';
import CollectionEventType from './CollectionEventType.js';
import Event from './events/Event.js';
/**
* @enum {string}
* @private
*/
var Property = {
LENGTH: 'length',
};
/**
* @classdesc
* Events emitted by {@link module:ol/Collection~Collection} instances are instances of this
* type.
*/
var CollectionEvent = /** @class */ (function (_super) {
__extends(CollectionEvent, _super);
/**
* @param {import("./CollectionEventType.js").default} type Type.
* @param {*} [opt_element] Element.
* @param {number} [opt_index] The index of the added or removed element.
*/
function CollectionEvent(type, opt_element, opt_index) {
var _this = _super.call(this, type) || this;
/**
* The element that is added to or removed from the collection.
* @type {*}
* @api
*/
_this.element = opt_element;
/**
* The index of the added or removed element.
* @type {number}
* @api
*/
_this.index = opt_index;
return _this;
}
return CollectionEvent;
}(Event));
export { CollectionEvent };
/***
* @template Return
* @typedef {import("./Observable").OnSignature<import("./Observable").EventTypes, import("./events/Event.js").default, Return> &
* import("./Observable").OnSignature<import("./ObjectEventType").Types|'change:length', import("./Object").ObjectEvent, Return> &
* import("./Observable").OnSignature<'add'|'remove', CollectionEvent, Return> &
* import("./Observable").CombinedOnSignature<import("./Observable").EventTypes|import("./ObjectEventType").Types|
* 'change:length'|'add'|'remove',Return>} CollectionOnSignature
*/
/**
* @typedef {Object} Options
* @property {boolean} [unique=false] Disallow the same item from being added to
* the collection twice.
*/
/**
* @classdesc
* An expanded version of standard JS Array, adding convenience methods for
* manipulation. Add and remove changes to the Collection trigger a Collection
* event. Note that this does not cover changes to the objects _within_ the
* Collection; they trigger events on the appropriate object, not on the
* Collection as a whole.
*
* @fires CollectionEvent
*
* @template T
* @api
*/
var Collection = /** @class */ (function (_super) {
__extends(Collection, _super);
/**
* @param {Array<T>} [opt_array] Array.
* @param {Options} [opt_options] Collection options.
*/
function Collection(opt_array, opt_options) {
var _this = _super.call(this) || this;
/***
* @type {CollectionOnSignature<import("./events").EventsKey>}
*/
_this.on;
/***
* @type {CollectionOnSignature<import("./events").EventsKey>}
*/
_this.once;
/***
* @type {CollectionOnSignature<void>}
*/
_this.un;
var options = opt_options || {};
/**
* @private
* @type {boolean}
*/
_this.unique_ = !!options.unique;
/**
* @private
* @type {!Array<T>}
*/
_this.array_ = opt_array ? opt_array : [];
if (_this.unique_) {
for (var i = 0, ii = _this.array_.length; i < ii; ++i) {
_this.assertUnique_(_this.array_[i], i);
}
}
_this.updateLength_();
return _this;
}
/**
* Remove all elements from the collection.
* @api
*/
Collection.prototype.clear = function () {
while (this.getLength() > 0) {
this.pop();
}
};
/**
* Add elements to the collection. This pushes each item in the provided array
* to the end of the collection.
* @param {!Array<T>} arr Array.
* @return {Collection<T>} This collection.
* @api
*/
Collection.prototype.extend = function (arr) {
for (var i = 0, ii = arr.length; i < ii; ++i) {
this.push(arr[i]);
}
return this;
};
/**
* Iterate over each element, calling the provided callback.
* @param {function(T, number, Array<T>): *} f The function to call
* for every element. This function takes 3 arguments (the element, the
* index and the array). The return value is ignored.
* @api
*/
Collection.prototype.forEach = function (f) {
var array = this.array_;
for (var i = 0, ii = array.length; i < ii; ++i) {
f(array[i], i, array);
}
};
/**
* Get a reference to the underlying Array object. Warning: if the array
* is mutated, no events will be dispatched by the collection, and the
* collection's "length" property won't be in sync with the actual length
* of the array.
* @return {!Array<T>} Array.
* @api
*/
Collection.prototype.getArray = function () {
return this.array_;
};
/**
* Get the element at the provided index.
* @param {number} index Index.
* @return {T} Element.
* @api
*/
Collection.prototype.item = function (index) {
return this.array_[index];
};
/**
* Get the length of this collection.
* @return {number} The length of the array.
* @observable
* @api
*/
Collection.prototype.getLength = function () {
return this.get(Property.LENGTH);
};
/**
* Insert an element at the provided index.
* @param {number} index Index.
* @param {T} elem Element.
* @api
*/
Collection.prototype.insertAt = function (index, elem) {
if (this.unique_) {
this.assertUnique_(elem);
}
this.array_.splice(index, 0, elem);
this.updateLength_();
this.dispatchEvent(new CollectionEvent(CollectionEventType.ADD, elem, index));
};
/**
* Remove the last element of the collection and return it.
* Return `undefined` if the collection is empty.
* @return {T|undefined} Element.
* @api
*/
Collection.prototype.pop = function () {
return this.removeAt(this.getLength() - 1);
};
/**
* Insert the provided element at the end of the collection.
* @param {T} elem Element.
* @return {number} New length of the collection.
* @api
*/
Collection.prototype.push = function (elem) {
if (this.unique_) {
this.assertUnique_(elem);
}
var n = this.getLength();
this.insertAt(n, elem);
return this.getLength();
};
/**
* Remove the first occurrence of an element from the collection.
* @param {T} elem Element.
* @return {T|undefined} The removed element or undefined if none found.
* @api
*/
Collection.prototype.remove = function (elem) {
var arr = this.array_;
for (var i = 0, ii = arr.length; i < ii; ++i) {
if (arr[i] === elem) {
return this.removeAt(i);
}
}
return undefined;
};
/**
* Remove the element at the provided index and return it.
* Return `undefined` if the collection does not contain this index.
* @param {number} index Index.
* @return {T|undefined} Value.
* @api
*/
Collection.prototype.removeAt = function (index) {
var prev = this.array_[index];
this.array_.splice(index, 1);
this.updateLength_();
this.dispatchEvent(new CollectionEvent(CollectionEventType.REMOVE, prev, index));
return prev;
};
/**
* Set the element at the provided index.
* @param {number} index Index.
* @param {T} elem Element.
* @api
*/
Collection.prototype.setAt = function (index, elem) {
var n = this.getLength();
if (index < n) {
if (this.unique_) {
this.assertUnique_(elem, index);
}
var prev = this.array_[index];
this.array_[index] = elem;
this.dispatchEvent(new CollectionEvent(CollectionEventType.REMOVE, prev, index));
this.dispatchEvent(new CollectionEvent(CollectionEventType.ADD, elem, index));
}
else {
for (var j = n; j < index; ++j) {
this.insertAt(j, undefined);
}
this.insertAt(index, elem);
}
};
/**
* @private
*/
Collection.prototype.updateLength_ = function () {
this.set(Property.LENGTH, this.array_.length);
};
/**
* @private
* @param {T} elem Element.
* @param {number} [opt_except] Optional index to ignore.
*/
Collection.prototype.assertUnique_ = function (elem, opt_except) {
for (var i = 0, ii = this.array_.length; i < ii; ++i) {
if (this.array_[i] === elem && i !== opt_except) {
throw new AssertionError(58);
}
}
};
return Collection;
}(BaseObject));
export default Collection;
//# sourceMappingURL=Collection.js.map

1
node_modules/ol/Collection.js.map generated vendored Normal file
View File

@@ -0,0 +1 @@
{"version":3,"file":"Collection.js","sourceRoot":"","sources":["src/Collection.js"],"names":[],"mappings":";;;;;;;;;;;;;;;AAAA;;GAEG;AACH,OAAO,cAAc,MAAM,qBAAqB,CAAC;AACjD,OAAO,UAAU,MAAM,aAAa,CAAC;AACrC,OAAO,mBAAmB,MAAM,0BAA0B,CAAC;AAC3D,OAAO,KAAK,MAAM,mBAAmB,CAAC;AAEtC;;;GAGG;AACH,IAAM,QAAQ,GAAG;IACf,MAAM,EAAE,QAAQ;CACjB,CAAC;AAEF;;;;GAIG;AACH;IAAqC,mCAAK;IACxC;;;;OAIG;IACH,yBAAY,IAAI,EAAE,WAAW,EAAE,SAAS;QAAxC,YACE,kBAAM,IAAI,CAAC,SAeZ;QAbC;;;;WAIG;QACH,KAAI,CAAC,OAAO,GAAG,WAAW,CAAC;QAE3B;;;;WAIG;QACH,KAAI,CAAC,KAAK,GAAG,SAAS,CAAC;;IACzB,CAAC;IACH,sBAAC;AAAD,CAAC,AAvBD,CAAqC,KAAK,GAuBzC;;AAED;;;;;;;GAOG;AAEH;;;;GAIG;AAEH;;;;;;;;;;;;GAYG;AACH;IAAyB,8BAAU;IACjC;;;OAGG;IACH,oBAAY,SAAS,EAAE,WAAW;QAAlC,YACE,iBAAO,SAsCR;QApCC;;WAEG;QACH,KAAI,CAAC,EAAE,CAAC;QAER;;WAEG;QACH,KAAI,CAAC,IAAI,CAAC;QAEV;;WAEG;QACH,KAAI,CAAC,EAAE,CAAC;QAER,IAAM,OAAO,GAAG,WAAW,IAAI,EAAE,CAAC;QAElC;;;WAGG;QACH,KAAI,CAAC,OAAO,GAAG,CAAC,CAAC,OAAO,CAAC,MAAM,CAAC;QAEhC;;;WAGG;QACH,KAAI,CAAC,MAAM,GAAG,SA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,QAAQ,CAAC,CAAC,EAAE,SAAS,CAAC,CAAC;aAC7B;YACD,IAAI,CAAC,QAAQ,CAAC,KAAK,EAAE,IAAI,CAAC,CAAC;SAC5B;IACH,CAAC;IAED;;OAEG;IACH,kCAAa,GAAb;QACE,IAAI,CAAC,GAAG,CAAC,QAAQ,CAAC,MAAM,EAAE,IAAI,CAAC,MAAM,CAAC,MAAM,CAAC,CAAC;IAChD,CAAC;IAED;;;;OAIG;IACH,kCAAa,GAAb,UAAc,IAAI,EAAE,UAAU;QAC5B,KAAK,IAAI,CAAC,GAAG,CAAC,EAAE,EAAE,GAAG,IAAI,CAAC,MAAM,CAAC,MAAM,EAAE,CAAC,GAAG,EAAE,EAAE,EAAE,CAAC,EAAE;YACpD,IAAI,IAAI,CAAC,MAAM,CAAC,CAAC,CAAC,KAAK,IAAI,IAAI,CAAC,KAAK,UAAU,EAAE;gBAC/C,MAAM,IAAI,cAAc,CAAC,EAAE,CAAC,CAAC;aAC9B;SACF;IACH,CAAC;IACH,iBAAC;AAAD,CAAC,AA9OD,CAAyB,UAAU,GA8OlC;AAED,eAAe,UAAU,CAAC"}

6
node_modules/ol/CollectionEventType.d.ts generated vendored Normal file
View File

@@ -0,0 +1,6 @@
declare namespace _default {
const ADD: string;
const REMOVE: string;
}
export default _default;
//# sourceMappingURL=CollectionEventType.d.ts.map

1
node_modules/ol/CollectionEventType.d.ts.map generated vendored Normal file
View File

@@ -0,0 +1 @@
{"version":3,"file":"CollectionEventType.d.ts","sourceRoot":"","sources":["src/CollectionEventType.js"],"names":[],"mappings":""}

21
node_modules/ol/CollectionEventType.js generated vendored Normal file
View File

@@ -0,0 +1,21 @@
/**
* @module ol/CollectionEventType
*/
/**
* @enum {string}
*/
export default {
/**
* Triggered when an item is added to the collection.
* @event module:ol/Collection.CollectionEvent#add
* @api
*/
ADD: 'add',
/**
* Triggered when an item is removed from the collection.
* @event module:ol/Collection.CollectionEvent#remove
* @api
*/
REMOVE: 'remove',
};
//# sourceMappingURL=CollectionEventType.js.map

1
node_modules/ol/CollectionEventType.js.map generated vendored Normal file
View File

@@ -0,0 +1 @@
{"version":3,"file":"CollectionEventType.js","sourceRoot":"","sources":["src/CollectionEventType.js"],"names":[],"mappings":"AAAA;;GAEG;AAEH;;GAEG;AACH,eAAe;IACb;;;;OAIG;IACH,GAAG,EAAE,KAAK;IACV;;;;OAIG;IACH,MAAM,EAAE,QAAQ;CACjB,CAAC"}

91
node_modules/ol/DataTile.d.ts generated vendored Normal file
View File

@@ -0,0 +1,91 @@
export default DataTile;
/**
* Data that can be used with a DataTile. For increased browser compatibility, use
* Uint8Array instead of Uint8ClampedArray where possible.
*/
export type Data = Uint8Array | Uint8ClampedArray | Float32Array | DataView;
export type Options = {
/**
* Tile coordinate.
*/
tileCoord: import("./tilecoord.js").TileCoord;
/**
* Data loader.
*/
loader: () => Promise<Data>;
/**
* A duration for tile opacity
* transitions in milliseconds. A duration of 0 disables the opacity transition.
*/
transition?: number | undefined;
/**
* Use interpolated values when resampling. By default,
* the nearest neighbor is used when resampling.
*/
interpolate?: boolean | undefined;
/**
* Tile size.
*/
size?: import("./size.js").Size | undefined;
};
/**
* Data that can be used with a DataTile. For increased browser compatibility, use
* Uint8Array instead of Uint8ClampedArray where possible.
* @typedef {Uint8Array|Uint8ClampedArray|Float32Array|DataView} Data
*/
/**
* @typedef {Object} Options
* @property {import("./tilecoord.js").TileCoord} tileCoord Tile coordinate.
* @property {function(): Promise<Data>} loader Data loader.
* @property {number} [transition=250] A duration for tile opacity
* transitions in milliseconds. A duration of 0 disables the opacity transition.
* @property {boolean} [interpolate=false] Use interpolated values when resampling. By default,
* the nearest neighbor is used when resampling.
* @property {import('./size.js').Size} [size=[256, 256]] Tile size.
* @api
*/
declare class DataTile extends Tile {
/**
* @param {Options} options Tile options.
*/
constructor(options: Options);
/**
* @type {function(): Promise<Data>}
* @private
*/
private loader_;
/**
* @type {Data}
* @private
*/
private data_;
/**
* @type {Error}
* @private
*/
private error_;
/**
* @type {import('./size.js').Size}
* @private
*/
private size_;
/**
* Get the tile size.
* @return {import('./size.js').Size} Tile size.
*/
getSize(): import('./size.js').Size;
/**
* Get the data for the tile.
* @return {Data} Tile data.
* @api
*/
getData(): Data;
/**
* Get any loading error.
* @return {Error} Loading error.
* @api
*/
getError(): Error;
}
import Tile from "./Tile.js";
//# sourceMappingURL=DataTile.d.ts.map

1
node_modules/ol/DataTile.d.ts.map generated vendored Normal file
View File

@@ -0,0 +1 @@
{"version":3,"file":"DataTile.d.ts","sourceRoot":"","sources":["src/DataTile.js"],"names":[],"mappings":";;;;;mBASa,UAAU,GAAC,iBAAiB,GAAC,YAAY,GAAC,QAAQ;;;;;eAKjD,OAAO,gBAAgB,EAAE,SAAS;;;;kBACtB,QAAQ,IAAI,CAAC;;;;;;;;;;;;;;;;AATvC;;;;GAIG;AAEH;;;;;;;;;;GAUG;AAEH;IACE;;OAEG;IACH,qBAFW,OAAO,EAiCjB;IAvBC;;;OAGG;IACH,gBAA6B;IAE7B;;;OAGG;IACH,cAAiB;IAEjB;;;OAGG;IACH,eAAkB;IAElB;;;OAGG;IACH,cAAuC;IAGzC;;;OAGG;IACH,WAFY,OAAO,WAAW,EAAE,IAAI,CAInC;IAED;;;;OAIG;IACH,WAHY,IAAI,CAKf;IAED;;;;OAIG;IACH,YAHY,KAAK,CAKhB;CA0BF"}

120
node_modules/ol/DataTile.js generated vendored Normal file
View File

@@ -0,0 +1,120 @@
var __extends = (this && this.__extends) || (function () {
var extendStatics = function (d, b) {
extendStatics = Object.setPrototypeOf ||
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };
return extendStatics(d, b);
};
return function (d, b) {
if (typeof b !== "function" && b !== null)
throw new TypeError("Class extends value " + String(b) + " is not a constructor or null");
extendStatics(d, b);
function __() { this.constructor = d; }
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
};
})();
/**
* @module ol/DataTile
*/
import Tile from './Tile.js';
import TileState from './TileState.js';
/**
* Data that can be used with a DataTile. For increased browser compatibility, use
* Uint8Array instead of Uint8ClampedArray where possible.
* @typedef {Uint8Array|Uint8ClampedArray|Float32Array|DataView} Data
*/
/**
* @typedef {Object} Options
* @property {import("./tilecoord.js").TileCoord} tileCoord Tile coordinate.
* @property {function(): Promise<Data>} loader Data loader.
* @property {number} [transition=250] A duration for tile opacity
* transitions in milliseconds. A duration of 0 disables the opacity transition.
* @property {boolean} [interpolate=false] Use interpolated values when resampling. By default,
* the nearest neighbor is used when resampling.
* @property {import('./size.js').Size} [size=[256, 256]] Tile size.
* @api
*/
var DataTile = /** @class */ (function (_super) {
__extends(DataTile, _super);
/**
* @param {Options} options Tile options.
*/
function DataTile(options) {
var _this = this;
var state = TileState.IDLE;
_this = _super.call(this, options.tileCoord, state, {
transition: options.transition,
interpolate: options.interpolate,
}) || this;
/**
* @type {function(): Promise<Data>}
* @private
*/
_this.loader_ = options.loader;
/**
* @type {Data}
* @private
*/
_this.data_ = null;
/**
* @type {Error}
* @private
*/
_this.error_ = null;
/**
* @type {import('./size.js').Size}
* @private
*/
_this.size_ = options.size || [256, 256];
return _this;
}
/**
* Get the tile size.
* @return {import('./size.js').Size} Tile size.
*/
DataTile.prototype.getSize = function () {
return this.size_;
};
/**
* Get the data for the tile.
* @return {Data} Tile data.
* @api
*/
DataTile.prototype.getData = function () {
return this.data_;
};
/**
* Get any loading error.
* @return {Error} Loading error.
* @api
*/
DataTile.prototype.getError = function () {
return this.error_;
};
/**
* Load not yet loaded URI.
* @api
*/
DataTile.prototype.load = function () {
if (this.state !== TileState.IDLE && this.state !== TileState.ERROR) {
return;
}
this.state = TileState.LOADING;
this.changed();
var self = this;
this.loader_()
.then(function (data) {
self.data_ = data;
self.state = TileState.LOADED;
self.changed();
})
.catch(function (error) {
self.error_ = error;
self.state = TileState.ERROR;
self.changed();
});
};
return DataTile;
}(Tile));
export default DataTile;
//# sourceMappingURL=DataTile.js.map

1
node_modules/ol/DataTile.js.map generated vendored Normal file
View File

@@ -0,0 +1 @@
{"version":3,"file":"DataTile.js","sourceRoot":"","sources":["src/DataTile.js"],"names":[],"mappings":";;;;;;;;;;;;;;;AAAA;;GAEG;AACH,OAAO,IAAI,MAAM,WAAW,CAAC;AAC7B,OAAO,SAAS,MAAM,gBAAgB,CAAC;AAEvC;;;;GAIG;AAEH;;;;;;;;;;GAUG;AAEH;IAAuB,4BAAI;IACzB;;OAEG;IACH,kBAAY,OAAO;QAAnB,iBA+BC;QA9BC,IAAM,KAAK,GAAG,SAAS,CAAC,IAAI,CAAC;gBAE7B,kBAAM,OAAO,CAAC,SAAS,EAAE,KAAK,EAAE;YAC9B,UAAU,EAAE,OAAO,CAAC,UAAU;YAC9B,WAAW,EAAE,OAAO,CAAC,WAAW;SACjC,CAAC;QAEF;;;WAGG;QACH,KAAI,CAAC,OAAO,GAAG,OAAO,CAAC,MAAM,CAAC;QAE9B;;;WAGG;QACH,KAAI,CAAC,KAAK,GAAG,IAAI,CAAC;QAElB;;;WAGG;QACH,KAAI,CAAC,MAAM,GAAG,IAAI,CAAC;QAEnB;;;WAGG;QACH,KAAI,CAAC,KAAK,GAAG,OAAO,CAAC,IAAI,IAAI,CAAC,GAAG,EAAE,GAAG,CAAC,CAAC;;IAC1C,CAAC;IAED;;;OAGG;IACH,0BAAO,GAAP;QACE,OAAO,IAAI,CAAC,KAAK,CAAC;IACpB,CAAC;IAED;;;;OAIG;IACH,0BAAO,GAAP;QACE,OAAO,IAAI,CAAC,KAAK,CAAC;IACpB,CAAC;IAED;;;;OAIG;IACH,2BAAQ,GAAR;QACE,OAAO,IAAI,CAAC,MAAM,CAAC;IACrB,CAAC;IAED;;;OAGG;IACH,uBAAI,GAAJ;QACE,IAAI,IAAI,CAAC,KAAK,KAAK,SAAS,CAAC,IAAI,IAAI,IAAI,CAAC,KAAK,KAAK,SAAS,CAAC,KAAK,EAAE;YACnE,OAAO;SACR;QACD,IAAI,CAAC,KAAK,GAAG,SAAS,CAAC,OAAO,CAAC;QAC/B,IAAI,CAAC,OAAO,EAAE,CAAC;QAEf,IAAM,IAAI,GAAG,IAAI,CAAC;QAClB,IAAI,CAAC,OAAO,EAAE;aACX,IAAI,CAAC,UAAU,IAAI;YAClB,IAAI,CAAC,KAAK,GAAG,IAAI,CAAC;YAClB,IAAI,CAAC,KAAK,GAAG,SAAS,CAAC,MAAM,CAAC;YAC9B,IAAI,CAAC,OAAO,EAAE,CAAC;QACjB,CAAC,CAAC;aACD,KAAK,CAAC,UAAU,KAAK;YACpB,IAAI,CAAC,MAAM,GAAG,KAAK,CAAC;YACpB,IAAI,CAAC,KAAK,GAAG,SAAS,CAAC,KAAK,CAAC;YAC7B,IAAI,CAAC,OAAO,EAAE,CAAC;QACjB,CAAC,CAAC,CAAC;IACP,CAAC;IACH,eAAC;AAAD,CAAC,AAvFD,CAAuB,IAAI,GAuF1B;AAED,eAAe,QAAQ,CAAC"}

26
node_modules/ol/Disposable.d.ts generated vendored Normal file
View File

@@ -0,0 +1,26 @@
export default Disposable;
/**
* @module ol/Disposable
*/
/**
* @classdesc
* Objects that need to clean up after themselves.
*/
declare class Disposable {
/**
* The object has already been disposed.
* @type {boolean}
* @protected
*/
protected disposed: boolean;
/**
* Clean up.
*/
dispose(): void;
/**
* Extension point for disposable objects.
* @protected
*/
protected disposeInternal(): void;
}
//# sourceMappingURL=Disposable.d.ts.map

1
node_modules/ol/Disposable.d.ts.map generated vendored Normal file
View File

@@ -0,0 +1 @@
{"version":3,"file":"Disposable.d.ts","sourceRoot":"","sources":["src/Disposable.js"],"names":[],"mappings":";AAAA;;GAEG;AAEH;;;GAGG;AACH;IAEI;;;;OAIG;IACH,oBAHU,OAAO,CAGI;IAGvB;;OAEG;IACH,gBAKC;IAED;;;OAGG;IACH,kCAAoB;CACrB"}

34
node_modules/ol/Disposable.js generated vendored Normal file
View File

@@ -0,0 +1,34 @@
/**
* @module ol/Disposable
*/
/**
* @classdesc
* Objects that need to clean up after themselves.
*/
var Disposable = /** @class */ (function () {
function Disposable() {
/**
* The object has already been disposed.
* @type {boolean}
* @protected
*/
this.disposed = false;
}
/**
* Clean up.
*/
Disposable.prototype.dispose = function () {
if (!this.disposed) {
this.disposed = true;
this.disposeInternal();
}
};
/**
* Extension point for disposable objects.
* @protected
*/
Disposable.prototype.disposeInternal = function () { };
return Disposable;
}());
export default Disposable;
//# sourceMappingURL=Disposable.js.map

1
node_modules/ol/Disposable.js.map generated vendored Normal file
View File

@@ -0,0 +1 @@
{"version":3,"file":"Disposable.js","sourceRoot":"","sources":["src/Disposable.js"],"names":[],"mappings":"AAAA;;GAEG;AAEH;;;GAGG;AACH;IACE;QACE;;;;WAIG;QACH,IAAI,CAAC,QAAQ,GAAG,KAAK,CAAC;IACxB,CAAC;IAED;;OAEG;IACH,4BAAO,GAAP;QACE,IAAI,CAAC,IAAI,CAAC,QAAQ,EAAE;YAClB,IAAI,CAAC,QAAQ,GAAG,IAAI,CAAC;YACrB,IAAI,CAAC,eAAe,EAAE,CAAC;SACxB;IACH,CAAC;IAED;;;OAGG;IACH,oCAAe,GAAf,cAAmB,CAAC;IACtB,iBAAC;AAAD,CAAC,AAzBD,IAyBC;AAED,eAAe,UAAU,CAAC"}

225
node_modules/ol/Feature.d.ts generated vendored Normal file
View File

@@ -0,0 +1,225 @@
/**
* Convert the provided object into a feature style function. Functions passed
* through unchanged. Arrays of Style or single style objects wrapped
* in a new feature style function.
* @param {!import("./style/Style.js").StyleFunction|!Array<import("./style/Style.js").default>|!import("./style/Style.js").default} obj
* A feature style function, a single style, or an array of styles.
* @return {import("./style/Style.js").StyleFunction} A style function.
*/
export function createStyleFunction(obj: import("./style/Style.js").StyleFunction | Array<import("./style/Style.js").default> | import("./style/Style.js").default): import("./style/Style.js").StyleFunction;
export default Feature;
export type FeatureClass = typeof Feature | typeof import("./render/Feature.js").default;
export type FeatureLike = Feature | import("./render/Feature.js").default;
/**
* *
*/
export type FeatureOnSignature<Return> = import("./Observable").OnSignature<import("./Observable").EventTypes, import("./events/Event.js").default, Return> & import("./Observable").OnSignature<import("./ObjectEventType").Types | 'change:geometry', import("./Object").ObjectEvent, Return> & import("./Observable").CombinedOnSignature<import("./Observable").EventTypes | import("./ObjectEventType").Types | 'change:geometry', Return>;
/**
* *
*/
export type ObjectWithGeometry<Geometry> = {
[x: string]: any;
} & {
geometry?: Geometry;
};
/**
* @typedef {typeof Feature|typeof import("./render/Feature.js").default} FeatureClass
*/
/**
* @typedef {Feature|import("./render/Feature.js").default} FeatureLike
*/
/***
* @template Return
* @typedef {import("./Observable").OnSignature<import("./Observable").EventTypes, import("./events/Event.js").default, Return> &
* import("./Observable").OnSignature<import("./ObjectEventType").Types|'change:geometry', import("./Object").ObjectEvent, Return> &
* import("./Observable").CombinedOnSignature<import("./Observable").EventTypes|import("./ObjectEventType").Types
* |'change:geometry', Return>} FeatureOnSignature
*/
/***
* @template Geometry
* @typedef {Object<string, *> & { geometry?: Geometry }} ObjectWithGeometry
*/
/**
* @classdesc
* A vector object for geographic features with a geometry and other
* attribute properties, similar to the features in vector file formats like
* GeoJSON.
*
* Features can be styled individually with `setStyle`; otherwise they use the
* style of their vector layer.
*
* Note that attribute properties are set as {@link module:ol/Object~BaseObject} properties on
* the feature object, so they are observable, and have get/set accessors.
*
* Typically, a feature has a single geometry property. You can set the
* geometry using the `setGeometry` method and get it with `getGeometry`.
* It is possible to store more than one geometry on a feature using attribute
* properties. By default, the geometry used for rendering is identified by
* the property name `geometry`. If you want to use another geometry property
* for rendering, use the `setGeometryName` method to change the attribute
* property associated with the geometry for the feature. For example:
*
* ```js
*
* import Feature from 'ol/Feature';
* import Polygon from 'ol/geom/Polygon';
* import Point from 'ol/geom/Point';
*
* var feature = new Feature({
* geometry: new Polygon(polyCoords),
* labelPoint: new Point(labelCoords),
* name: 'My Polygon'
* });
*
* // get the polygon geometry
* var poly = feature.getGeometry();
*
* // Render the feature as a point using the coordinates from labelPoint
* feature.setGeometryName('labelPoint');
*
* // get the point geometry
* var point = feature.getGeometry();
* ```
*
* @api
* @template {import("./geom/Geometry.js").default} [Geometry=import("./geom/Geometry.js").default]
*/
declare class Feature<Geometry extends import("./geom/Geometry.js").default = import("./geom/Geometry.js").default> extends BaseObject {
/**
* @param {Geometry|ObjectWithGeometry<Geometry>} [opt_geometryOrProperties]
* You may pass a Geometry object directly, or an object literal containing
* properties. If you pass an object literal, you may include a Geometry
* associated with a `geometry` key.
*/
constructor(opt_geometryOrProperties?: Geometry | ObjectWithGeometry<Geometry> | undefined);
/***
* @type {FeatureOnSignature<import("./events").EventsKey>}
*/
on: FeatureOnSignature<import("./events").EventsKey>;
/***
* @type {FeatureOnSignature<import("./events").EventsKey>}
*/
once: FeatureOnSignature<import("./events").EventsKey>;
/***
* @type {FeatureOnSignature<void>}
*/
un: FeatureOnSignature<void>;
/**
* @private
* @type {number|string|undefined}
*/
private id_;
/**
* @type {string}
* @private
*/
private geometryName_;
/**
* User provided style.
* @private
* @type {import("./style/Style.js").StyleLike}
*/
private style_;
/**
* @private
* @type {import("./style/Style.js").StyleFunction|undefined}
*/
private styleFunction_;
/**
* @private
* @type {?import("./events.js").EventsKey}
*/
private geometryChangeKey_;
/**
* Clone this feature. If the original feature has a geometry it
* is also cloned. The feature id is not set in the clone.
* @return {Feature<Geometry>} The clone.
* @api
*/
clone(): Feature<Geometry>;
/**
* Get the feature's default geometry. A feature may have any number of named
* geometries. The "default" geometry (the one that is rendered by default) is
* set when calling {@link module:ol/Feature~Feature#setGeometry}.
* @return {Geometry|undefined} The default geometry for the feature.
* @api
* @observable
*/
getGeometry(): Geometry | undefined;
/**
* Get the feature identifier. This is a stable identifier for the feature and
* is either set when reading data from a remote source or set explicitly by
* calling {@link module:ol/Feature~Feature#setId}.
* @return {number|string|undefined} Id.
* @api
*/
getId(): number | string | undefined;
/**
* Get the name of the feature's default geometry. By default, the default
* geometry is named `geometry`.
* @return {string} Get the property name associated with the default geometry
* for this feature.
* @api
*/
getGeometryName(): string;
/**
* Get the feature's style. Will return what was provided to the
* {@link module:ol/Feature~Feature#setStyle} method.
* @return {import("./style/Style.js").StyleLike|undefined} The feature style.
* @api
*/
getStyle(): import("./style/Style.js").StyleLike | undefined;
/**
* Get the feature's style function.
* @return {import("./style/Style.js").StyleFunction|undefined} Return a function
* representing the current style of this feature.
* @api
*/
getStyleFunction(): import("./style/Style.js").StyleFunction | undefined;
/**
* @private
*/
private handleGeometryChange_;
/**
* @private
*/
private handleGeometryChanged_;
/**
* Set the default geometry for the feature. This will update the property
* with the name returned by {@link module:ol/Feature~Feature#getGeometryName}.
* @param {Geometry|undefined} geometry The new geometry.
* @api
* @observable
*/
setGeometry(geometry: Geometry | undefined): void;
/**
* Set the style for the feature to override the layer style. This can be a
* single style object, an array of styles, or a function that takes a
* resolution and returns an array of styles. To unset the feature style, call
* `setStyle()` without arguments or a falsey value.
* @param {import("./style/Style.js").StyleLike} [opt_style] Style for this feature.
* @api
* @fires module:ol/events/Event~BaseEvent#event:change
*/
setStyle(opt_style?: import("./style/Style.js").StyleLike | undefined): void;
/**
* Set the feature id. The feature id is considered stable and may be used when
* requesting features or comparing identifiers returned from a remote source.
* The feature id can be used with the
* {@link module:ol/source/Vector~VectorSource#getFeatureById} method.
* @param {number|string|undefined} id The feature id.
* @api
* @fires module:ol/events/Event~BaseEvent#event:change
*/
setId(id: number | string | undefined): void;
/**
* Set the property name to be used when getting the feature's default geometry.
* When calling {@link module:ol/Feature~Feature#getGeometry}, the value of the property with
* this name will be returned.
* @param {string} name The property name of the default geometry.
* @api
*/
setGeometryName(name: string): void;
}
import BaseObject from "./Object.js";
//# sourceMappingURL=Feature.d.ts.map

1
node_modules/ol/Feature.d.ts.map generated vendored Normal file
View File

@@ -0,0 +1 @@
{"version":3,"file":"Feature.d.ts","sourceRoot":"","sources":["src/Feature.js"],"names":[],"mappings":"AAoTA;;;;;;;GAOG;AACH,yCAJY,OAAO,kBAAkB,EAAE,aAAa,GAAE,MAAM,OAAO,kBAAkB,EAAE,OAAO,CA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;;;;OAMG;IACH,SAHY,MAAM,GAAC,MAAM,GAAC,SAAS,CAKlC;IAED;;;;;;OAMG;IACH,mBAJY,MAAM,CAMjB;IAED;;;;;OAKG;IACH,YAHY,OAAO,kBAAkB,EAAE,SAAS,GAAC,SAAS,CAKzD;IAED;;;;;OAKG;IACH,oBAJY,OAAO,kBAAkB,EAAE,aAAa,GAAC,SAAS,CAM7D;IAED;;OAEG;IACH,8BAEC;IAED;;OAEG;IACH,+BAeC;IAED;;;;;;OAMG;IACH,sBAJW,QAAQ,GAAC,SAAS,QAM5B;IAED;;;;;;;;OAQG;IACH,6EAMC;IAED;;;;;;;;OAQG;IACH,UAJW,MAAM,GAAC,MAAM,GAAC,SAAS,QAOjC;IAED;;;;;;OAMG;IACH,sBAHW,MAAM,QAQhB;CACF"}

321
node_modules/ol/Feature.js generated vendored Normal file
View File

@@ -0,0 +1,321 @@
var __extends = (this && this.__extends) || (function () {
var extendStatics = function (d, b) {
extendStatics = Object.setPrototypeOf ||
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };
return extendStatics(d, b);
};
return function (d, b) {
if (typeof b !== "function" && b !== null)
throw new TypeError("Class extends value " + String(b) + " is not a constructor or null");
extendStatics(d, b);
function __() { this.constructor = d; }
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
};
})();
/**
* @module ol/Feature
*/
import BaseObject from './Object.js';
import EventType from './events/EventType.js';
import { assert } from './asserts.js';
import { listen, unlistenByKey } from './events.js';
/**
* @typedef {typeof Feature|typeof import("./render/Feature.js").default} FeatureClass
*/
/**
* @typedef {Feature|import("./render/Feature.js").default} FeatureLike
*/
/***
* @template Return
* @typedef {import("./Observable").OnSignature<import("./Observable").EventTypes, import("./events/Event.js").default, Return> &
* import("./Observable").OnSignature<import("./ObjectEventType").Types|'change:geometry', import("./Object").ObjectEvent, Return> &
* import("./Observable").CombinedOnSignature<import("./Observable").EventTypes|import("./ObjectEventType").Types
* |'change:geometry', Return>} FeatureOnSignature
*/
/***
* @template Geometry
* @typedef {Object<string, *> & { geometry?: Geometry }} ObjectWithGeometry
*/
/**
* @classdesc
* A vector object for geographic features with a geometry and other
* attribute properties, similar to the features in vector file formats like
* GeoJSON.
*
* Features can be styled individually with `setStyle`; otherwise they use the
* style of their vector layer.
*
* Note that attribute properties are set as {@link module:ol/Object~BaseObject} properties on
* the feature object, so they are observable, and have get/set accessors.
*
* Typically, a feature has a single geometry property. You can set the
* geometry using the `setGeometry` method and get it with `getGeometry`.
* It is possible to store more than one geometry on a feature using attribute
* properties. By default, the geometry used for rendering is identified by
* the property name `geometry`. If you want to use another geometry property
* for rendering, use the `setGeometryName` method to change the attribute
* property associated with the geometry for the feature. For example:
*
* ```js
*
* import Feature from 'ol/Feature';
* import Polygon from 'ol/geom/Polygon';
* import Point from 'ol/geom/Point';
*
* var feature = new Feature({
* geometry: new Polygon(polyCoords),
* labelPoint: new Point(labelCoords),
* name: 'My Polygon'
* });
*
* // get the polygon geometry
* var poly = feature.getGeometry();
*
* // Render the feature as a point using the coordinates from labelPoint
* feature.setGeometryName('labelPoint');
*
* // get the point geometry
* var point = feature.getGeometry();
* ```
*
* @api
* @template {import("./geom/Geometry.js").default} [Geometry=import("./geom/Geometry.js").default]
*/
var Feature = /** @class */ (function (_super) {
__extends(Feature, _super);
/**
* @param {Geometry|ObjectWithGeometry<Geometry>} [opt_geometryOrProperties]
* You may pass a Geometry object directly, or an object literal containing
* properties. If you pass an object literal, you may include a Geometry
* associated with a `geometry` key.
*/
function Feature(opt_geometryOrProperties) {
var _this = _super.call(this) || this;
/***
* @type {FeatureOnSignature<import("./events").EventsKey>}
*/
_this.on;
/***
* @type {FeatureOnSignature<import("./events").EventsKey>}
*/
_this.once;
/***
* @type {FeatureOnSignature<void>}
*/
_this.un;
/**
* @private
* @type {number|string|undefined}
*/
_this.id_ = undefined;
/**
* @type {string}
* @private
*/
_this.geometryName_ = 'geometry';
/**
* User provided style.
* @private
* @type {import("./style/Style.js").StyleLike}
*/
_this.style_ = null;
/**
* @private
* @type {import("./style/Style.js").StyleFunction|undefined}
*/
_this.styleFunction_ = undefined;
/**
* @private
* @type {?import("./events.js").EventsKey}
*/
_this.geometryChangeKey_ = null;
_this.addChangeListener(_this.geometryName_, _this.handleGeometryChanged_);
if (opt_geometryOrProperties) {
if (typeof (
/** @type {?} */ (opt_geometryOrProperties).getSimplifiedGeometry) === 'function') {
var geometry = /** @type {Geometry} */ (opt_geometryOrProperties);
_this.setGeometry(geometry);
}
else {
/** @type {Object<string, *>} */
var properties = opt_geometryOrProperties;
_this.setProperties(properties);
}
}
return _this;
}
/**
* Clone this feature. If the original feature has a geometry it
* is also cloned. The feature id is not set in the clone.
* @return {Feature<Geometry>} The clone.
* @api
*/
Feature.prototype.clone = function () {
var clone = /** @type {Feature<Geometry>} */ (new Feature(this.hasProperties() ? this.getProperties() : null));
clone.setGeometryName(this.getGeometryName());
var geometry = this.getGeometry();
if (geometry) {
clone.setGeometry(/** @type {Geometry} */ (geometry.clone()));
}
var style = this.getStyle();
if (style) {
clone.setStyle(style);
}
return clone;
};
/**
* Get the feature's default geometry. A feature may have any number of named
* geometries. The "default" geometry (the one that is rendered by default) is
* set when calling {@link module:ol/Feature~Feature#setGeometry}.
* @return {Geometry|undefined} The default geometry for the feature.
* @api
* @observable
*/
Feature.prototype.getGeometry = function () {
return /** @type {Geometry|undefined} */ (this.get(this.geometryName_));
};
/**
* Get the feature identifier. This is a stable identifier for the feature and
* is either set when reading data from a remote source or set explicitly by
* calling {@link module:ol/Feature~Feature#setId}.
* @return {number|string|undefined} Id.
* @api
*/
Feature.prototype.getId = function () {
return this.id_;
};
/**
* Get the name of the feature's default geometry. By default, the default
* geometry is named `geometry`.
* @return {string} Get the property name associated with the default geometry
* for this feature.
* @api
*/
Feature.prototype.getGeometryName = function () {
return this.geometryName_;
};
/**
* Get the feature's style. Will return what was provided to the
* {@link module:ol/Feature~Feature#setStyle} method.
* @return {import("./style/Style.js").StyleLike|undefined} The feature style.
* @api
*/
Feature.prototype.getStyle = function () {
return this.style_;
};
/**
* Get the feature's style function.
* @return {import("./style/Style.js").StyleFunction|undefined} Return a function
* representing the current style of this feature.
* @api
*/
Feature.prototype.getStyleFunction = function () {
return this.styleFunction_;
};
/**
* @private
*/
Feature.prototype.handleGeometryChange_ = function () {
this.changed();
};
/**
* @private
*/
Feature.prototype.handleGeometryChanged_ = function () {
if (this.geometryChangeKey_) {
unlistenByKey(this.geometryChangeKey_);
this.geometryChangeKey_ = null;
}
var geometry = this.getGeometry();
if (geometry) {
this.geometryChangeKey_ = listen(geometry, EventType.CHANGE, this.handleGeometryChange_, this);
}
this.changed();
};
/**
* Set the default geometry for the feature. This will update the property
* with the name returned by {@link module:ol/Feature~Feature#getGeometryName}.
* @param {Geometry|undefined} geometry The new geometry.
* @api
* @observable
*/
Feature.prototype.setGeometry = function (geometry) {
this.set(this.geometryName_, geometry);
};
/**
* Set the style for the feature to override the layer style. This can be a
* single style object, an array of styles, or a function that takes a
* resolution and returns an array of styles. To unset the feature style, call
* `setStyle()` without arguments or a falsey value.
* @param {import("./style/Style.js").StyleLike} [opt_style] Style for this feature.
* @api
* @fires module:ol/events/Event~BaseEvent#event:change
*/
Feature.prototype.setStyle = function (opt_style) {
this.style_ = opt_style;
this.styleFunction_ = !opt_style
? undefined
: createStyleFunction(opt_style);
this.changed();
};
/**
* Set the feature id. The feature id is considered stable and may be used when
* requesting features or comparing identifiers returned from a remote source.
* The feature id can be used with the
* {@link module:ol/source/Vector~VectorSource#getFeatureById} method.
* @param {number|string|undefined} id The feature id.
* @api
* @fires module:ol/events/Event~BaseEvent#event:change
*/
Feature.prototype.setId = function (id) {
this.id_ = id;
this.changed();
};
/**
* Set the property name to be used when getting the feature's default geometry.
* When calling {@link module:ol/Feature~Feature#getGeometry}, the value of the property with
* this name will be returned.
* @param {string} name The property name of the default geometry.
* @api
*/
Feature.prototype.setGeometryName = function (name) {
this.removeChangeListener(this.geometryName_, this.handleGeometryChanged_);
this.geometryName_ = name;
this.addChangeListener(this.geometryName_, this.handleGeometryChanged_);
this.handleGeometryChanged_();
};
return Feature;
}(BaseObject));
/**
* Convert the provided object into a feature style function. Functions passed
* through unchanged. Arrays of Style or single style objects wrapped
* in a new feature style function.
* @param {!import("./style/Style.js").StyleFunction|!Array<import("./style/Style.js").default>|!import("./style/Style.js").default} obj
* A feature style function, a single style, or an array of styles.
* @return {import("./style/Style.js").StyleFunction} A style function.
*/
export function createStyleFunction(obj) {
if (typeof obj === 'function') {
return obj;
}
else {
/**
* @type {Array<import("./style/Style.js").default>}
*/
var styles_1;
if (Array.isArray(obj)) {
styles_1 = obj;
}
else {
assert(typeof ( /** @type {?} */(obj).getZIndex) === 'function', 41); // Expected an `import("./style/Style.js").Style` or an array of `import("./style/Style.js").Style`
var style = /** @type {import("./style/Style.js").default} */ (obj);
styles_1 = [style];
}
return function () {
return styles_1;
};
}
}
export default Feature;
//# sourceMappingURL=Feature.js.map

1
node_modules/ol/Feature.js.map generated vendored Normal file
View File

@@ -0,0 +1 @@
{"version":3,"file":"Feature.js","sourceRoot":"","sources":["src/Feature.js"],"names":[],"mappings":";;;;;;;;;;;;;;;AAAA;;GAEG;AACH,OAAO,UAAU,MAAM,aAAa,CAAC;AACrC,OAAO,SAAS,MAAM,uBAAuB,CAAC;AAC9C,OAAO,EAAC,MAAM,EAAC,MAAM,cAAc,CAAC;AACpC,OAAO,EAAC,MAAM,EAAE,aAAa,EAAC,MAAM,aAAa,CAAC;AAElD;;GAEG;AAEH;;GAEG;AAEH;;;;;;GAMG;AAEH;;;GAGG;AAEH;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA4CG;AACH;IAAsB,2BAAU;IAC9B;;;;;OAKG;IACH,iBAAY,wBAAwB;QAApC,YACE,iBAAO,SAgER;QA9DC;;WAEG;QACH,KAAI,CAAC,EAAE,CAAC;QAER;;WAEG;QACH,K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C,mGAAmG;YACzK,IAAM,KAAK,GAAG,iDAAiD,CAAC,CAAC,GAAG,CAAC,CAAC;YACtE,QAAM,GAAG,CAAC,KAAK,CAAC,CAAC;SAClB;QACD,OAAO;YACL,OAAO,QAAM,CAAC;QAChB,CAAC,CAAC;KACH;AACH,CAAC;AACD,eAAe,OAAO,CAAC"}

247
node_modules/ol/Geolocation.d.ts generated vendored Normal file
View File

@@ -0,0 +1,247 @@
export default Geolocation;
export type Options = {
/**
* Start Tracking right after
* instantiation.
*/
tracking?: boolean | undefined;
/**
* Tracking options.
* See https://www.w3.org/TR/geolocation-API/#position_options_interface.
*/
trackingOptions?: PositionOptions | undefined;
/**
* The projection the position
* is reported in.
*/
projection?: import("./proj.js").ProjectionLike;
};
export type GeolocationObjectEventTypes = import("./ObjectEventType").Types | 'change:accuracy' | 'change:accuracyGeometry' | 'change:altitude' | 'change:altitudeAccuracy' | 'change:heading' | 'change:position' | 'change:projection' | 'change:speed' | 'change:tracking' | 'change:trackingOptions';
/**
* *
*/
export type GeolocationOnSignature<Return> = import("./Observable").OnSignature<import("./Observable").EventTypes, import("./events/Event.js").default, Return> & import("./Observable").OnSignature<GeolocationObjectEventTypes, import("./Object").ObjectEvent, Return> & import("./Observable").OnSignature<'error', GeolocationError, Return> & import("./Observable").CombinedOnSignature<import("./Observable").EventTypes | GeolocationObjectEventTypes | 'error', Return>;
/**
* @typedef {Object} Options
* @property {boolean} [tracking=false] Start Tracking right after
* instantiation.
* @property {PositionOptions} [trackingOptions] Tracking options.
* See https://www.w3.org/TR/geolocation-API/#position_options_interface.
* @property {import("./proj.js").ProjectionLike} [projection] The projection the position
* is reported in.
*/
/**
* @typedef {import("./ObjectEventType").Types|'change:accuracy'|'change:accuracyGeometry'|'change:altitude'|
* 'change:altitudeAccuracy'|'change:heading'|'change:position'|'change:projection'|'change:speed'|'change:tracking'|
* 'change:trackingOptions'} GeolocationObjectEventTypes
*/
/***
* @template Return
* @typedef {import("./Observable").OnSignature<import("./Observable").EventTypes, import("./events/Event.js").default, Return> &
* import("./Observable").OnSignature<GeolocationObjectEventTypes, import("./Object").ObjectEvent, Return> &
* import("./Observable").OnSignature<'error', GeolocationError, Return> &
* import("./Observable").CombinedOnSignature<import("./Observable").EventTypes|GeolocationObjectEventTypes|
* 'error', Return>} GeolocationOnSignature
*/
/**
* @classdesc
* Helper class for providing HTML5 Geolocation capabilities.
* The [Geolocation API](https://www.w3.org/TR/geolocation-API/)
* is used to locate a user's position.
*
* To get notified of position changes, register a listener for the generic
* `change` event on your instance of {@link module:ol/Geolocation~Geolocation}.
*
* Example:
*
* var geolocation = new Geolocation({
* // take the projection to use from the map's view
* projection: view.getProjection()
* });
* // listen to changes in position
* geolocation.on('change', function(evt) {
* window.console.log(geolocation.getPosition());
* });
*
* @fires module:ol/events/Event~BaseEvent#event:error
* @api
*/
declare class Geolocation extends BaseObject {
/**
* @param {Options} [opt_options] Options.
*/
constructor(opt_options?: Options | undefined);
/***
* @type {GeolocationOnSignature<import("./events").EventsKey>}
*/
on: GeolocationOnSignature<import("./events").EventsKey>;
/***
* @type {GeolocationOnSignature<import("./events").EventsKey>}
*/
once: GeolocationOnSignature<import("./events").EventsKey>;
/***
* @type {GeolocationOnSignature<void>}
*/
un: GeolocationOnSignature<void>;
/**
* The unprojected (EPSG:4326) device position.
* @private
* @type {?import("./coordinate.js").Coordinate}
*/
private position_;
/**
* @private
* @type {import("./proj.js").TransformFunction}
*/
private transform_;
/**
* @private
* @type {number|undefined}
*/
private watchId_;
/**
* @private
*/
private handleProjectionChanged_;
/**
* @private
*/
private handleTrackingChanged_;
/**
* @private
* @param {GeolocationPosition} position position event.
*/
private positionChange_;
/**
* @private
* @param {GeolocationPositionError} error error object.
*/
private positionError_;
/**
* Get the accuracy of the position in meters.
* @return {number|undefined} The accuracy of the position measurement in
* meters.
* @observable
* @api
*/
getAccuracy(): number | undefined;
/**
* Get a geometry of the position accuracy.
* @return {?import("./geom/Polygon.js").default} A geometry of the position accuracy.
* @observable
* @api
*/
getAccuracyGeometry(): import("./geom/Polygon.js").default | null;
/**
* Get the altitude associated with the position.
* @return {number|undefined} The altitude of the position in meters above mean
* sea level.
* @observable
* @api
*/
getAltitude(): number | undefined;
/**
* Get the altitude accuracy of the position.
* @return {number|undefined} The accuracy of the altitude measurement in
* meters.
* @observable
* @api
*/
getAltitudeAccuracy(): number | undefined;
/**
* Get the heading as radians clockwise from North.
* Note: depending on the browser, the heading is only defined if the `enableHighAccuracy`
* is set to `true` in the tracking options.
* @return {number|undefined} The heading of the device in radians from north.
* @observable
* @api
*/
getHeading(): number | undefined;
/**
* Get the position of the device.
* @return {import("./coordinate.js").Coordinate|undefined} The current position of the device reported
* in the current projection.
* @observable
* @api
*/
getPosition(): import("./coordinate.js").Coordinate | undefined;
/**
* Get the projection associated with the position.
* @return {import("./proj/Projection.js").default|undefined} The projection the position is
* reported in.
* @observable
* @api
*/
getProjection(): import("./proj/Projection.js").default | undefined;
/**
* Get the speed in meters per second.
* @return {number|undefined} The instantaneous speed of the device in meters
* per second.
* @observable
* @api
*/
getSpeed(): number | undefined;
/**
* Determine if the device location is being tracked.
* @return {boolean} The device location is being tracked.
* @observable
* @api
*/
getTracking(): boolean;
/**
* Get the tracking options.
* See https://www.w3.org/TR/geolocation-API/#position-options.
* @return {PositionOptions|undefined} PositionOptions as defined by
* the [HTML5 Geolocation spec
* ](https://www.w3.org/TR/geolocation-API/#position_options_interface).
* @observable
* @api
*/
getTrackingOptions(): PositionOptions | undefined;
/**
* Set the projection to use for transforming the coordinates.
* @param {import("./proj.js").ProjectionLike} projection The projection the position is
* reported in.
* @observable
* @api
*/
setProjection(projection: import("./proj.js").ProjectionLike): void;
/**
* Enable or disable tracking.
* @param {boolean} tracking Enable tracking.
* @observable
* @api
*/
setTracking(tracking: boolean): void;
/**
* Set the tracking options.
* See http://www.w3.org/TR/geolocation-API/#position-options.
* @param {PositionOptions} options PositionOptions as defined by the
* [HTML5 Geolocation spec
* ](http://www.w3.org/TR/geolocation-API/#position_options_interface).
* @observable
* @api
*/
setTrackingOptions(options: PositionOptions): void;
}
/**
* @classdesc
* Events emitted on Geolocation error.
*/
declare class GeolocationError extends BaseEvent {
/**
* @param {GeolocationPositionError} error error object.
*/
constructor(error: GeolocationPositionError);
/**
* @type {number}
*/
code: number;
/**
* @type {string}
*/
message: string;
}
import BaseObject from "./Object.js";
import BaseEvent from "./events/Event.js";
//# sourceMappingURL=Geolocation.d.ts.map

1
node_modules/ol/Geolocation.d.ts.map generated vendored Normal file
View File

@@ -0,0 +1 @@
{"version":3,"file":"Geolocation.d.ts","sourceRoot":"","sources":["src/Geolocation.js"],"names":[],"mappings":";;;;;;;;;;;;;;;;iBA2Dc,OAAO,WAAW,EAAE,cAAc;;0CAKnC,OAAO,mBAAmB,EAAE,KAAK,GAAC,iBAAiB,GAAC,yBAAyB,GAAC,iBAAiB,GAC3G,yBAA8B,GAAC,gBAAgB,GAAC,iBAAiB,GAAC,mBAAmB,GAAC,cAAc,GAAC,iBAAiB,GACtH,wBAA6B;;;;6CAKjB,OAAO,cAAc,EAAE,WAAW,CAAC,OAAO,cAAc,EAAE,UAAU,EAAE,OAAO,mBAAmB,EAAE,OAAO,EAAE,MAAM,CAAC,GAC9H,OAAW,cAAc,EAAE,WAAW,CAAC,2BAA2B,EAAE,OAAO,UAAU,EAAE,WAAW,EAAE,MAAM,CAAC,GAC3G,OAAW,cAAc,EAAE,WAAW,CAAC,OAAO,EAAE,gBAAgB,EAAE,MAAM,CAAC,GACzE,OAAW,cAAc,EAAE,mBAAmB,CAAC,OAAO,cAAc,EAAE,UAAU,GAAC,2BAA2B,GAC5G,OAAa,EAAE,MAAM,CAAC;AAtBvB;;;;;;;;GAQG;AAEH;;;;GAIG;AAEH;;;;;;;GAOG;AAEH;;;;;;;;;;;;;;;;;;;;;;GAsBG;AACH;IACE;;OAEG;IACH,+CAkDC;IA/CC;;OAEG;IACH,IAFU,uBAAuB,OAAO,UAAU,EAAE,SAAS,CAAC,CAEvD;IAEP;;OAEG;IACH,MAFU,uBAAuB,OAAO,UAAU,EAAE,SAAS,CAAC,CAErD;IAET;;OAEG;IACH,IAFU,uBAAuB,IAAI,CAAC,CAE/B;IAIP;;;;OAIG;IACH,kBAAqB;IAErB;;;OAGG;IACH,mBAAmC;IAEnC;;;OAGG;IACH,iBAAyB;IAuB3B;;OAEG;IACH,iCAWC;IAED;;OAEG;IACH,+BAcC;IAED;;;OAGG;IACH,wBA4BC;IAED;;;OAGG;IACH,uBAEC;IAED;;;;;;OAMG;IACH,eALY,MAAM,GAAC,SAAS,CAO3B;IAED;;;;;OAKG;IACH,uBAJa,OAAO,mBAAmB,EAAE,OAAO,QAQ/C;IAED;;;;;;OAMG;IACH,eALY,MAAM,GAAC,SAAS,CAO3B;IAED;;;;;;OAMG;IACH,uBALY,MAAM,GAAC,SAAS,CAS3B;IAED;;;;;;;OAOG;IACH,cAJY,MAAM,GAAC,SAAS,CAM3B;IAED;;;;;;OAMG;IACH,eALY,OAAO,iBAAiB,EAAE,UAAU,GAAC,SAAS,CASzD;IAED;;;;;;OAMG;IACH,iBALY,OAAO,sBAAsB,EAAE,OAAO,GAAC,SAAS,CAS3D;IAED;;;;;;OAMG;IACH,YALY,MAAM,GAAC,SAAS,CAO3B;IAED;;;;;OAKG;IACH,eAJY,OAAO,CAMlB;IAED;;;;;;;;OAQG;IACH,sBANY,eAAe,GAAC,SAAS,CAUpC;IAED;;;;;;OAMG;IACH,0BALW,OAAO,WAAW,EAAE,cAAc,QAO5C;IAED;;;;;OAKG;IACH,sBAJW,OAAO,QAMjB;IAED;;;;;;;;OAQG;IACH,4BANW,eAAe,QAQzB;CACF;AA9WD;;;GAGG;AACH;IACE;;OAEG;IACH,mBAFW,wBAAwB,EAclC;IATC;;OAEG;IACH,MAFU,MAAM,CAEM;IAEtB;;OAEG;IACH,SAFU,MAAM,CAEY;CAE/B"}

356
node_modules/ol/Geolocation.js generated vendored Normal file
View File

@@ -0,0 +1,356 @@
var __extends = (this && this.__extends) || (function () {
var extendStatics = function (d, b) {
extendStatics = Object.setPrototypeOf ||
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };
return extendStatics(d, b);
};
return function (d, b) {
if (typeof b !== "function" && b !== null)
throw new TypeError("Class extends value " + String(b) + " is not a constructor or null");
extendStatics(d, b);
function __() { this.constructor = d; }
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
};
})();
/**
* @module ol/Geolocation
*/
import BaseEvent from './events/Event.js';
import BaseObject from './Object.js';
import EventType from './events/EventType.js';
import { circular as circularPolygon } from './geom/Polygon.js';
import { get as getProjection, getTransformFromProjections, identityTransform, } from './proj.js';
import { toRadians } from './math.js';
/**
* @enum {string}
*/
var Property = {
ACCURACY: 'accuracy',
ACCURACY_GEOMETRY: 'accuracyGeometry',
ALTITUDE: 'altitude',
ALTITUDE_ACCURACY: 'altitudeAccuracy',
HEADING: 'heading',
POSITION: 'position',
PROJECTION: 'projection',
SPEED: 'speed',
TRACKING: 'tracking',
TRACKING_OPTIONS: 'trackingOptions',
};
/**
* @classdesc
* Events emitted on Geolocation error.
*/
var GeolocationError = /** @class */ (function (_super) {
__extends(GeolocationError, _super);
/**
* @param {GeolocationPositionError} error error object.
*/
function GeolocationError(error) {
var _this = _super.call(this, EventType.ERROR) || this;
/**
* @type {number}
*/
_this.code = error.code;
/**
* @type {string}
*/
_this.message = error.message;
return _this;
}
return GeolocationError;
}(BaseEvent));
/**
* @typedef {Object} Options
* @property {boolean} [tracking=false] Start Tracking right after
* instantiation.
* @property {PositionOptions} [trackingOptions] Tracking options.
* See https://www.w3.org/TR/geolocation-API/#position_options_interface.
* @property {import("./proj.js").ProjectionLike} [projection] The projection the position
* is reported in.
*/
/**
* @typedef {import("./ObjectEventType").Types|'change:accuracy'|'change:accuracyGeometry'|'change:altitude'|
* 'change:altitudeAccuracy'|'change:heading'|'change:position'|'change:projection'|'change:speed'|'change:tracking'|
* 'change:trackingOptions'} GeolocationObjectEventTypes
*/
/***
* @template Return
* @typedef {import("./Observable").OnSignature<import("./Observable").EventTypes, import("./events/Event.js").default, Return> &
* import("./Observable").OnSignature<GeolocationObjectEventTypes, import("./Object").ObjectEvent, Return> &
* import("./Observable").OnSignature<'error', GeolocationError, Return> &
* import("./Observable").CombinedOnSignature<import("./Observable").EventTypes|GeolocationObjectEventTypes|
* 'error', Return>} GeolocationOnSignature
*/
/**
* @classdesc
* Helper class for providing HTML5 Geolocation capabilities.
* The [Geolocation API](https://www.w3.org/TR/geolocation-API/)
* is used to locate a user's position.
*
* To get notified of position changes, register a listener for the generic
* `change` event on your instance of {@link module:ol/Geolocation~Geolocation}.
*
* Example:
*
* var geolocation = new Geolocation({
* // take the projection to use from the map's view
* projection: view.getProjection()
* });
* // listen to changes in position
* geolocation.on('change', function(evt) {
* window.console.log(geolocation.getPosition());
* });
*
* @fires module:ol/events/Event~BaseEvent#event:error
* @api
*/
var Geolocation = /** @class */ (function (_super) {
__extends(Geolocation, _super);
/**
* @param {Options} [opt_options] Options.
*/
function Geolocation(opt_options) {
var _this = _super.call(this) || this;
/***
* @type {GeolocationOnSignature<import("./events").EventsKey>}
*/
_this.on;
/***
* @type {GeolocationOnSignature<import("./events").EventsKey>}
*/
_this.once;
/***
* @type {GeolocationOnSignature<void>}
*/
_this.un;
var options = opt_options || {};
/**
* The unprojected (EPSG:4326) device position.
* @private
* @type {?import("./coordinate.js").Coordinate}
*/
_this.position_ = null;
/**
* @private
* @type {import("./proj.js").TransformFunction}
*/
_this.transform_ = identityTransform;
/**
* @private
* @type {number|undefined}
*/
_this.watchId_ = undefined;
_this.addChangeListener(Property.PROJECTION, _this.handleProjectionChanged_);
_this.addChangeListener(Property.TRACKING, _this.handleTrackingChanged_);
if (options.projection !== undefined) {
_this.setProjection(options.projection);
}
if (options.trackingOptions !== undefined) {
_this.setTrackingOptions(options.trackingOptions);
}
_this.setTracking(options.tracking !== undefined ? options.tracking : false);
return _this;
}
/**
* Clean up.
*/
Geolocation.prototype.disposeInternal = function () {
this.setTracking(false);
_super.prototype.disposeInternal.call(this);
};
/**
* @private
*/
Geolocation.prototype.handleProjectionChanged_ = function () {
var projection = this.getProjection();
if (projection) {
this.transform_ = getTransformFromProjections(getProjection('EPSG:4326'), projection);
if (this.position_) {
this.set(Property.POSITION, this.transform_(this.position_));
}
}
};
/**
* @private
*/
Geolocation.prototype.handleTrackingChanged_ = function () {
if ('geolocation' in navigator) {
var tracking = this.getTracking();
if (tracking && this.watchId_ === undefined) {
this.watchId_ = navigator.geolocation.watchPosition(this.positionChange_.bind(this), this.positionError_.bind(this), this.getTrackingOptions());
}
else if (!tracking && this.watchId_ !== undefined) {
navigator.geolocation.clearWatch(this.watchId_);
this.watchId_ = undefined;
}
}
};
/**
* @private
* @param {GeolocationPosition} position position event.
*/
Geolocation.prototype.positionChange_ = function (position) {
var coords = position.coords;
this.set(Property.ACCURACY, coords.accuracy);
this.set(Property.ALTITUDE, coords.altitude === null ? undefined : coords.altitude);
this.set(Property.ALTITUDE_ACCURACY, coords.altitudeAccuracy === null ? undefined : coords.altitudeAccuracy);
this.set(Property.HEADING, coords.heading === null ? undefined : toRadians(coords.heading));
if (!this.position_) {
this.position_ = [coords.longitude, coords.latitude];
}
else {
this.position_[0] = coords.longitude;
this.position_[1] = coords.latitude;
}
var projectedPosition = this.transform_(this.position_);
this.set(Property.POSITION, projectedPosition);
this.set(Property.SPEED, coords.speed === null ? undefined : coords.speed);
var geometry = circularPolygon(this.position_, coords.accuracy);
geometry.applyTransform(this.transform_);
this.set(Property.ACCURACY_GEOMETRY, geometry);
this.changed();
};
/**
* @private
* @param {GeolocationPositionError} error error object.
*/
Geolocation.prototype.positionError_ = function (error) {
this.dispatchEvent(new GeolocationError(error));
};
/**
* Get the accuracy of the position in meters.
* @return {number|undefined} The accuracy of the position measurement in
* meters.
* @observable
* @api
*/
Geolocation.prototype.getAccuracy = function () {
return /** @type {number|undefined} */ (this.get(Property.ACCURACY));
};
/**
* Get a geometry of the position accuracy.
* @return {?import("./geom/Polygon.js").default} A geometry of the position accuracy.
* @observable
* @api
*/
Geolocation.prototype.getAccuracyGeometry = function () {
return /** @type {?import("./geom/Polygon.js").default} */ (this.get(Property.ACCURACY_GEOMETRY) || null);
};
/**
* Get the altitude associated with the position.
* @return {number|undefined} The altitude of the position in meters above mean
* sea level.
* @observable
* @api
*/
Geolocation.prototype.getAltitude = function () {
return /** @type {number|undefined} */ (this.get(Property.ALTITUDE));
};
/**
* Get the altitude accuracy of the position.
* @return {number|undefined} The accuracy of the altitude measurement in
* meters.
* @observable
* @api
*/
Geolocation.prototype.getAltitudeAccuracy = function () {
return /** @type {number|undefined} */ (this.get(Property.ALTITUDE_ACCURACY));
};
/**
* Get the heading as radians clockwise from North.
* Note: depending on the browser, the heading is only defined if the `enableHighAccuracy`
* is set to `true` in the tracking options.
* @return {number|undefined} The heading of the device in radians from north.
* @observable
* @api
*/
Geolocation.prototype.getHeading = function () {
return /** @type {number|undefined} */ (this.get(Property.HEADING));
};
/**
* Get the position of the device.
* @return {import("./coordinate.js").Coordinate|undefined} The current position of the device reported
* in the current projection.
* @observable
* @api
*/
Geolocation.prototype.getPosition = function () {
return /** @type {import("./coordinate.js").Coordinate|undefined} */ (this.get(Property.POSITION));
};
/**
* Get the projection associated with the position.
* @return {import("./proj/Projection.js").default|undefined} The projection the position is
* reported in.
* @observable
* @api
*/
Geolocation.prototype.getProjection = function () {
return /** @type {import("./proj/Projection.js").default|undefined} */ (this.get(Property.PROJECTION));
};
/**
* Get the speed in meters per second.
* @return {number|undefined} The instantaneous speed of the device in meters
* per second.
* @observable
* @api
*/
Geolocation.prototype.getSpeed = function () {
return /** @type {number|undefined} */ (this.get(Property.SPEED));
};
/**
* Determine if the device location is being tracked.
* @return {boolean} The device location is being tracked.
* @observable
* @api
*/
Geolocation.prototype.getTracking = function () {
return /** @type {boolean} */ (this.get(Property.TRACKING));
};
/**
* Get the tracking options.
* See https://www.w3.org/TR/geolocation-API/#position-options.
* @return {PositionOptions|undefined} PositionOptions as defined by
* the [HTML5 Geolocation spec
* ](https://www.w3.org/TR/geolocation-API/#position_options_interface).
* @observable
* @api
*/
Geolocation.prototype.getTrackingOptions = function () {
return /** @type {PositionOptions|undefined} */ (this.get(Property.TRACKING_OPTIONS));
};
/**
* Set the projection to use for transforming the coordinates.
* @param {import("./proj.js").ProjectionLike} projection The projection the position is
* reported in.
* @observable
* @api
*/
Geolocation.prototype.setProjection = function (projection) {
this.set(Property.PROJECTION, getProjection(projection));
};
/**
* Enable or disable tracking.
* @param {boolean} tracking Enable tracking.
* @observable
* @api
*/
Geolocation.prototype.setTracking = function (tracking) {
this.set(Property.TRACKING, tracking);
};
/**
* Set the tracking options.
* See http://www.w3.org/TR/geolocation-API/#position-options.
* @param {PositionOptions} options PositionOptions as defined by the
* [HTML5 Geolocation spec
* ](http://www.w3.org/TR/geolocation-API/#position_options_interface).
* @observable
* @api
*/
Geolocation.prototype.setTrackingOptions = function (options) {
this.set(Property.TRACKING_OPTIONS, options);
};
return Geolocation;
}(BaseObject));
export default Geolocation;
//# sourceMappingURL=Geolocation.js.map

1
node_modules/ol/Geolocation.js.map generated vendored Normal file

File diff suppressed because one or more lines are too long

95
node_modules/ol/Image.d.ts generated vendored Normal file
View File

@@ -0,0 +1,95 @@
/**
* @param {HTMLCanvasElement|HTMLImageElement|HTMLVideoElement} image Image element.
* @param {function():any} loadHandler Load callback function.
* @param {function():any} errorHandler Error callback function.
* @return {function():void} Callback to stop listening.
*/
export function listenImage(image: HTMLCanvasElement | HTMLImageElement | HTMLVideoElement, loadHandler: () => any, errorHandler: () => any): () => void;
export default ImageWrapper;
/**
* A function that takes an {@link module :ol/Image~ImageWrapper} for the image and a
* `{string}` for the src as arguments. It is supposed to make it so the
* underlying image {@link module :ol/Image~ImageWrapper#getImage} is assigned the
* content specified by the src. If not specified, the default is
*
* function(image, src) {
* image.getImage().src = src;
* }
*
* Providing a custom `imageLoadFunction` can be useful to load images with
* post requests or - in general - through XHR requests, where the src of the
* image element would be set to a data URI when the content is loaded.
*/
export type LoadFunction = (arg0: ImageWrapper, arg1: string) => void;
/**
* A function that takes an {@link module:ol/Image~ImageWrapper} for the image and a
* `{string}` for the src as arguments. It is supposed to make it so the
* underlying image {@link module:ol/Image~ImageWrapper#getImage} is assigned the
* content specified by the src. If not specified, the default is
*
* function(image, src) {
* image.getImage().src = src;
* }
*
* Providing a custom `imageLoadFunction` can be useful to load images with
* post requests or - in general - through XHR requests, where the src of the
* image element would be set to a data URI when the content is loaded.
*
* @typedef {function(ImageWrapper, string): void} LoadFunction
* @api
*/
declare class ImageWrapper extends ImageBase {
/**
* @param {import("./extent.js").Extent} extent Extent.
* @param {number|undefined} resolution Resolution.
* @param {number} pixelRatio Pixel ratio.
* @param {string} src Image source URI.
* @param {?string} crossOrigin Cross origin.
* @param {LoadFunction} imageLoadFunction Image load function.
*/
constructor(extent: import("./extent.js").Extent, resolution: number | undefined, pixelRatio: number, src: string, crossOrigin: string | null, imageLoadFunction: LoadFunction);
/**
* @private
* @type {string}
*/
private src_;
/**
* @private
* @type {HTMLCanvasElement|HTMLImageElement|HTMLVideoElement}
*/
private image_;
/**
* @private
* @type {?function():void}
*/
private unlisten_;
/**
* @private
* @type {LoadFunction}
*/
private imageLoadFunction_;
/**
* Tracks loading or read errors.
*
* @private
*/
private handleImageError_;
/**
* Tracks successful image load.
*
* @private
*/
private handleImageLoad_;
/**
* @param {HTMLCanvasElement|HTMLImageElement|HTMLVideoElement} image Image.
*/
setImage(image: HTMLCanvasElement | HTMLImageElement | HTMLVideoElement): void;
/**
* Discards event handlers which listen for load completion or errors.
*
* @private
*/
private unlistenImage_;
}
import ImageBase from "./ImageBase.js";
//# sourceMappingURL=Image.d.ts.map

1
node_modules/ol/Image.d.ts.map generated vendored Normal file
View File

@@ -0,0 +1 @@
{"version":3,"file":"Image.d.ts","sourceRoot":"","sources":["src/Image.js"],"names":[],"mappings":"AA0JA;;;;;GAKG;AACH,mCALW,iBAAiB,GAAC,gBAAgB,GAAC,gBAAgB,qBACxC,GAAG,sBACH,GAAG,SACF,IAAI,CA2C1B;;;;;;;;;;;;;;;;kCAjLqB,YAAY,QAAE,MAAM,KAAG,IAAI;AAdjD;;;;;;;;;;;;;;;;GAgBG;AAEH;IACE;;;;;;;OAOG;IACH,oBAPW,OAAO,aAAa,EAAE,MAAM,cAC5B,MAAM,GAAC,SAAS,cAChB,MAAM,OACN,MAAM,eACL,MAAM,4BACP,YAAY,EA4CtB;IAhCC;;;OAGG;IACH,aAAe;IAEf;;;OAGG;IACH,eAAyB;IAKzB;;;OAGG;IACH,kBAAqB;IAQrB;;;OAGG;IACH,2BAA2C;IAW7C;;;;OAIG;IACH,0BAIC;IAED;;;;OAIG;IACH,yBAOC;IAqBD;;OAEG;IACH,gBAFW,iBAAiB,GAAC,gBAAgB,GAAC,gBAAgB,QAK7D;IAED;;;;OAIG;IACH,uBAKC;CACF"}

196
node_modules/ol/Image.js generated vendored Normal file
View File

@@ -0,0 +1,196 @@
var __extends = (this && this.__extends) || (function () {
var extendStatics = function (d, b) {
extendStatics = Object.setPrototypeOf ||
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };
return extendStatics(d, b);
};
return function (d, b) {
if (typeof b !== "function" && b !== null)
throw new TypeError("Class extends value " + String(b) + " is not a constructor or null");
extendStatics(d, b);
function __() { this.constructor = d; }
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
};
})();
/**
* @module ol/Image
*/
import EventType from './events/EventType.js';
import ImageBase from './ImageBase.js';
import ImageState from './ImageState.js';
import { IMAGE_DECODE } from './has.js';
import { getHeight } from './extent.js';
import { listenOnce, unlistenByKey } from './events.js';
/**
* A function that takes an {@link module:ol/Image~ImageWrapper} for the image and a
* `{string}` for the src as arguments. It is supposed to make it so the
* underlying image {@link module:ol/Image~ImageWrapper#getImage} is assigned the
* content specified by the src. If not specified, the default is
*
* function(image, src) {
* image.getImage().src = src;
* }
*
* Providing a custom `imageLoadFunction` can be useful to load images with
* post requests or - in general - through XHR requests, where the src of the
* image element would be set to a data URI when the content is loaded.
*
* @typedef {function(ImageWrapper, string): void} LoadFunction
* @api
*/
var ImageWrapper = /** @class */ (function (_super) {
__extends(ImageWrapper, _super);
/**
* @param {import("./extent.js").Extent} extent Extent.
* @param {number|undefined} resolution Resolution.
* @param {number} pixelRatio Pixel ratio.
* @param {string} src Image source URI.
* @param {?string} crossOrigin Cross origin.
* @param {LoadFunction} imageLoadFunction Image load function.
*/
function ImageWrapper(extent, resolution, pixelRatio, src, crossOrigin, imageLoadFunction) {
var _this = _super.call(this, extent, resolution, pixelRatio, ImageState.IDLE) || this;
/**
* @private
* @type {string}
*/
_this.src_ = src;
/**
* @private
* @type {HTMLCanvasElement|HTMLImageElement|HTMLVideoElement}
*/
_this.image_ = new Image();
if (crossOrigin !== null) {
_this.image_.crossOrigin = crossOrigin;
}
/**
* @private
* @type {?function():void}
*/
_this.unlisten_ = null;
/**
* @protected
* @type {import("./ImageState.js").default}
*/
_this.state = ImageState.IDLE;
/**
* @private
* @type {LoadFunction}
*/
_this.imageLoadFunction_ = imageLoadFunction;
return _this;
}
/**
* @return {HTMLCanvasElement|HTMLImageElement|HTMLVideoElement} Image.
* @api
*/
ImageWrapper.prototype.getImage = function () {
return this.image_;
};
/**
* Tracks loading or read errors.
*
* @private
*/
ImageWrapper.prototype.handleImageError_ = function () {
this.state = ImageState.ERROR;
this.unlistenImage_();
this.changed();
};
/**
* Tracks successful image load.
*
* @private
*/
ImageWrapper.prototype.handleImageLoad_ = function () {
if (this.resolution === undefined) {
this.resolution = getHeight(this.extent) / this.image_.height;
}
this.state = ImageState.LOADED;
this.unlistenImage_();
this.changed();
};
/**
* Load the image or retry if loading previously failed.
* Loading is taken care of by the tile queue, and calling this method is
* only needed for preloading or for reloading in case of an error.
* @api
*/
ImageWrapper.prototype.load = function () {
if (this.state == ImageState.IDLE || this.state == ImageState.ERROR) {
this.state = ImageState.LOADING;
this.changed();
this.imageLoadFunction_(this, this.src_);
this.unlisten_ = listenImage(this.image_, this.handleImageLoad_.bind(this), this.handleImageError_.bind(this));
}
};
/**
* @param {HTMLCanvasElement|HTMLImageElement|HTMLVideoElement} image Image.
*/
ImageWrapper.prototype.setImage = function (image) {
this.image_ = image;
this.resolution = getHeight(this.extent) / this.image_.height;
};
/**
* Discards event handlers which listen for load completion or errors.
*
* @private
*/
ImageWrapper.prototype.unlistenImage_ = function () {
if (this.unlisten_) {
this.unlisten_();
this.unlisten_ = null;
}
};
return ImageWrapper;
}(ImageBase));
/**
* @param {HTMLCanvasElement|HTMLImageElement|HTMLVideoElement} image Image element.
* @param {function():any} loadHandler Load callback function.
* @param {function():any} errorHandler Error callback function.
* @return {function():void} Callback to stop listening.
*/
export function listenImage(image, loadHandler, errorHandler) {
var img = /** @type {HTMLImageElement} */ (image);
var listening = true;
var decoding = false;
var loaded = false;
var listenerKeys = [
listenOnce(img, EventType.LOAD, function () {
loaded = true;
if (!decoding) {
loadHandler();
}
}),
];
if (img.src && IMAGE_DECODE) {
decoding = true;
img
.decode()
.then(function () {
if (listening) {
loadHandler();
}
})
.catch(function (error) {
if (listening) {
if (loaded) {
loadHandler();
}
else {
errorHandler();
}
}
});
}
else {
listenerKeys.push(listenOnce(img, EventType.ERROR, errorHandler));
}
return function unlisten() {
listening = false;
listenerKeys.forEach(unlistenByKey);
};
}
export default ImageWrapper;
//# sourceMappingURL=Image.js.map

1
node_modules/ol/Image.js.map generated vendored Normal file
View File

@@ -0,0 +1 @@
{"version":3,"file":"Image.js","sourceRoot":"","sources":["src/Image.js"],"names":[],"mappings":";;;;;;;;;;;;;;;AAAA;;GAEG;AACH,OAAO,SAAS,MAAM,uBAAuB,CAAC;AAC9C,OAAO,SAAS,MAAM,gBAAgB,CAAC;AACvC,OAAO,UAAU,MAAM,iBAAiB,CAAC;AACzC,OAAO,EAAC,YA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AAG,IAAI,CAAC;IACrB,IAAI,QAAQ,GAAG,KAAK,CAAC;IACrB,IAAI,MAAM,GAAG,KAAK,CAAC;IAEnB,IAAM,YAAY,GAAG;QACnB,UAAU,CAAC,GAAG,EAAE,SAAS,CAAC,IAAI,EAAE;YAC9B,MAAM,GAAG,IAAI,CAAC;YACd,IAAI,CAAC,QAAQ,EAAE;gBACb,WAAW,EAAE,CAAC;aACf;QACH,CAAC,CAAC;KACH,CAAC;IAEF,IAAI,GAAG,CAAC,GAAG,IAAI,YAAY,EAAE;QAC3B,QAAQ,GAAG,IAAI,CAAC;QAChB,GAAG;aACA,MAAM,EAAE;aACR,IAAI,CAAC;YACJ,IAAI,SAAS,EAAE;gBACb,WAAW,EAAE,CAAC;aACf;QACH,CAAC,CAAC;aACD,KAAK,CAAC,UAAU,KAAK;YACpB,IAAI,SAAS,EAAE;gBACb,IAAI,MAAM,EAAE;oBACV,WAAW,EAAE,CAAC;iBACf;qBAAM;oBACL,YAAY,EAAE,CAAC;iBAChB;aACF;QACH,CAAC,CAAC,CAAC;KACN;SAAM;QACL,YAAY,CAAC,IAAI,CAAC,UAAU,CAAC,GAAG,EAAE,SAAS,CAAC,KAAK,EAAE,YAAY,CAAC,CAAC,CAAC;KACnE;IAED,OAAO,SAAS,QAAQ;QACtB,SAAS,GAAG,KAAK,CAAC;QAClB,YAAY,CAAC,OAAO,CAAC,aAAa,CAAC,CAAC;IACtC,CAAC,CAAC;AACJ,CAAC;AAED,eAAe,YAAY,CAAC"}

65
node_modules/ol/ImageBase.d.ts generated vendored Normal file
View File

@@ -0,0 +1,65 @@
export default ImageBase;
/**
* @abstract
*/
declare class ImageBase extends EventTarget {
/**
* @param {import("./extent.js").Extent} extent Extent.
* @param {number|undefined} resolution Resolution.
* @param {number} pixelRatio Pixel ratio.
* @param {import("./ImageState.js").default} state State.
*/
constructor(extent: import("./extent.js").Extent, resolution: number | undefined, pixelRatio: number, state: any);
/**
* @protected
* @type {import("./extent.js").Extent}
*/
protected extent: import("./extent.js").Extent;
/**
* @private
* @type {number}
*/
private pixelRatio_;
/**
* @protected
* @type {number|undefined}
*/
protected resolution: number | undefined;
/**
* @protected
* @type {import("./ImageState.js").default}
*/
protected state: any;
/**
* @protected
*/
protected changed(): void;
/**
* @return {import("./extent.js").Extent} Extent.
*/
getExtent(): import("./extent.js").Extent;
/**
* @abstract
* @return {HTMLCanvasElement|HTMLImageElement|HTMLVideoElement} Image.
*/
getImage(): HTMLCanvasElement | HTMLImageElement | HTMLVideoElement;
/**
* @return {number} PixelRatio.
*/
getPixelRatio(): number;
/**
* @return {number} Resolution.
*/
getResolution(): number;
/**
* @return {import("./ImageState.js").default} State.
*/
getState(): any;
/**
* Load not yet loaded URI.
* @abstract
*/
load(): void;
}
import EventTarget from "./events/Target.js";
//# sourceMappingURL=ImageBase.d.ts.map

1
node_modules/ol/ImageBase.d.ts.map generated vendored Normal file
View File

@@ -0,0 +1 @@
{"version":3,"file":"ImageBase.d.ts","sourceRoot":"","sources":["src/ImageBase.js"],"names":[],"mappings":";AAOA;;GAEG;AACH;IACE;;;;;OAKG;IACH,oBALW,OAAO,aAAa,EAAE,MAAM,cAC5B,MAAM,GAAC,SAAS,cAChB,MAAM,cA6BhB;IAvBC;;;OAGG;IACH,kBAFU,OAAO,aAAa,EAAE,MAAM,CAElB;IAEpB;;;OAGG;IACH,oBAA6B;IAE7B;;;OAGG;IACH,sBAFU,MAAM,GAAC,SAAS,CAEE;IAE5B;;;OAGG;IACH,qBAAkB;IAGpB;;OAEG;IACH,0BAEC;IAED;;OAEG;IACH,aAFY,OAAO,aAAa,EAAE,MAAM,CAIvC;IAED;;;OAGG;IACH,YAFY,iBAAiB,GAAC,gBAAgB,GAAC,gBAAgB,CAI9D;IAED;;OAEG;IACH,iBAFY,MAAM,CAIjB;IAED;;OAEG;IACH,iBAFY,MAAM,CAIjB;IAED;;OAEG;IACH,gBAEC;IAED;;;OAGG;IACH,aAEC;CACF"}

104
node_modules/ol/ImageBase.js generated vendored Normal file
View File

@@ -0,0 +1,104 @@
var __extends = (this && this.__extends) || (function () {
var extendStatics = function (d, b) {
extendStatics = Object.setPrototypeOf ||
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };
return extendStatics(d, b);
};
return function (d, b) {
if (typeof b !== "function" && b !== null)
throw new TypeError("Class extends value " + String(b) + " is not a constructor or null");
extendStatics(d, b);
function __() { this.constructor = d; }
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
};
})();
/**
* @module ol/ImageBase
*/
import EventTarget from './events/Target.js';
import EventType from './events/EventType.js';
import { abstract } from './util.js';
/**
* @abstract
*/
var ImageBase = /** @class */ (function (_super) {
__extends(ImageBase, _super);
/**
* @param {import("./extent.js").Extent} extent Extent.
* @param {number|undefined} resolution Resolution.
* @param {number} pixelRatio Pixel ratio.
* @param {import("./ImageState.js").default} state State.
*/
function ImageBase(extent, resolution, pixelRatio, state) {
var _this = _super.call(this) || this;
/**
* @protected
* @type {import("./extent.js").Extent}
*/
_this.extent = extent;
/**
* @private
* @type {number}
*/
_this.pixelRatio_ = pixelRatio;
/**
* @protected
* @type {number|undefined}
*/
_this.resolution = resolution;
/**
* @protected
* @type {import("./ImageState.js").default}
*/
_this.state = state;
return _this;
}
/**
* @protected
*/
ImageBase.prototype.changed = function () {
this.dispatchEvent(EventType.CHANGE);
};
/**
* @return {import("./extent.js").Extent} Extent.
*/
ImageBase.prototype.getExtent = function () {
return this.extent;
};
/**
* @abstract
* @return {HTMLCanvasElement|HTMLImageElement|HTMLVideoElement} Image.
*/
ImageBase.prototype.getImage = function () {
return abstract();
};
/**
* @return {number} PixelRatio.
*/
ImageBase.prototype.getPixelRatio = function () {
return this.pixelRatio_;
};
/**
* @return {number} Resolution.
*/
ImageBase.prototype.getResolution = function () {
return /** @type {number} */ (this.resolution);
};
/**
* @return {import("./ImageState.js").default} State.
*/
ImageBase.prototype.getState = function () {
return this.state;
};
/**
* Load not yet loaded URI.
* @abstract
*/
ImageBase.prototype.load = function () {
abstract();
};
return ImageBase;
}(EventTarget));
export default ImageBase;
//# sourceMappingURL=ImageBase.js.map

1
node_modules/ol/ImageBase.js.map generated vendored Normal file
View File

@@ -0,0 +1 @@
{"version":3,"file":"ImageBase.js","sourceRoot":"","sources":["src/ImageBase.js"],"names":[],"mappings":";;;;;;;;;;;;;;;AAAA;;GAEG;AACH,OAAO,WAAW,MAAM,oBAAoB,CAAC;AAC7C,OAAO,SAAS,MAAM,uBAAuB,CAAC;AAC9C,OAAO,EAAC,QAAQ,EAAC,MAAM,WAAW,CAAC;AAEnC;;GAEG;AACH;IAAwB,6BAAW;IACjC;;;;;OAKG;IACH,mBAAY,MAAM,EAAE,UAAU,EAAE,UAAU,EAAE,KAAK;QAAjD,YACE,iBAAO,SAyBR;QAvBC;;;WAGG;QACH,KAAI,CAAC,MAAM,GAAG,MAAM,CAAC;QAErB;;;WAGG;QACH,KAAI,CAAC,WAAW,GAAG,UAAU,CAAC;QAE9B;;;WAGG;QACH,KAAI,CAAC,UAAU,GAAG,UAAU,CAAC;QAE7B;;;WAGG;QACH,KAAI,CAAC,KAAK,GAAG,KAAK,CAAC;;IACrB,CAAC;IAED;;OAEG;IACH,2BAAO,GAAP;QACE,IAAI,CAAC,aAAa,CAAC,SAAS,CAAC,MAAM,CAAC,CAAC;IACvC,CAAC;IAED;;OAEG;IACH,6BAAS,GAAT;QACE,OAAO,IAAI,CAAC,MAAM,CAAC;IACrB,CAAC;IAED;;;OAGG;IACH,4BAAQ,GAAR;QACE,OAAO,QAAQ,EAAE,CAAC;IACpB,CAAC;IAED;;OAEG;IACH,iCAAa,GAAb;QACE,OAAO,IAAI,CAAC,WAAW,CAAC;IAC1B,CAAC;IAED;;OAEG;IACH,iCAAa,GAAb;QACE,OAAO,qBAAqB,CAAC,CAAC,IAAI,CAAC,UAAU,CAAC,CAAC;IACjD,CAAC;IAED;;OAEG;IACH,4BAAQ,GAAR;QACE,OAAO,IAAI,CAAC,KAAK,CAAC;IACpB,CAAC;IAED;;;OAGG;IACH,wBAAI,GAAJ;QACE,QAAQ,EAAE,CAAC;IACb,CAAC;IACH,gBAAC;AAAD,CAAC,AArFD,CAAwB,WAAW,GAqFlC;AAED,eAAe,SAAS,CAAC"}

60
node_modules/ol/ImageCanvas.d.ts generated vendored Normal file
View File

@@ -0,0 +1,60 @@
export default ImageCanvas;
/**
* A function that is called to trigger asynchronous canvas drawing. It is
* called with a "done" callback that should be called when drawing is done.
* If any error occurs during drawing, the "done" callback should be called with
* that error.
*/
export type Loader = (arg0: (arg0: Error | undefined) => void) => void;
/**
* A function that is called to trigger asynchronous canvas drawing. It is
* called with a "done" callback that should be called when drawing is done.
* If any error occurs during drawing, the "done" callback should be called with
* that error.
*
* @typedef {function(function(Error=): void): void} Loader
*/
declare class ImageCanvas extends ImageBase {
/**
* @param {import("./extent.js").Extent} extent Extent.
* @param {number} resolution Resolution.
* @param {number} pixelRatio Pixel ratio.
* @param {HTMLCanvasElement} canvas Canvas.
* @param {Loader} [opt_loader] Optional loader function to
* support asynchronous canvas drawing.
*/
constructor(extent: import("./extent.js").Extent, resolution: number, pixelRatio: number, canvas: HTMLCanvasElement, opt_loader?: Loader | undefined);
/**
* Optional canvas loader function.
* @type {?Loader}
* @private
*/
private loader_;
/**
* @private
* @type {HTMLCanvasElement}
*/
private canvas_;
/**
* @private
* @type {?Error}
*/
private error_;
/**
* Get any error associated with asynchronous rendering.
* @return {?Error} Any error that occurred during rendering.
*/
getError(): Error | null;
/**
* Handle async drawing complete.
* @param {Error} [err] Any error during drawing.
* @private
*/
private handleLoad_;
/**
* @return {HTMLCanvasElement} Canvas element.
*/
getImage(): HTMLCanvasElement;
}
import ImageBase from "./ImageBase.js";
//# sourceMappingURL=ImageCanvas.d.ts.map

1
node_modules/ol/ImageCanvas.d.ts.map generated vendored Normal file
View File

@@ -0,0 +1 @@
{"version":3,"file":"ImageCanvas.d.ts","sourceRoot":"","sources":["src/ImageCanvas.js"],"names":[],"mappings":";;;;;;;mCAY+B,KAAK,iBAAI,IAAI,KAAG,IAAI;AANnD;;;;;;;GAOG;AAEH;IACE;;;;;;;OAOG;IACH,oBAPW,OAAO,aAAa,EAAE,MAAM,cAC5B,MAAM,cACN,MAAM,UACN,iBAAiB,mCA4B3B;IAlBC;;;;OAIG;IACH,gBAA2D;IAE3D;;;OAGG;IACH,gBAAqB;IAErB;;;OAGG;IACH,eAAkB;IAGpB;;;OAGG;IACH,YAFa,KAAK,QAIjB;IAED;;;;OAIG;IACH,oBAQC;IAaD;;OAEG;IACH,YAFY,iBAAiB,CAI5B;CACF"}

102
node_modules/ol/ImageCanvas.js generated vendored Normal file
View File

@@ -0,0 +1,102 @@
var __extends = (this && this.__extends) || (function () {
var extendStatics = function (d, b) {
extendStatics = Object.setPrototypeOf ||
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };
return extendStatics(d, b);
};
return function (d, b) {
if (typeof b !== "function" && b !== null)
throw new TypeError("Class extends value " + String(b) + " is not a constructor or null");
extendStatics(d, b);
function __() { this.constructor = d; }
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
};
})();
/**
* @module ol/ImageCanvas
*/
import ImageBase from './ImageBase.js';
import ImageState from './ImageState.js';
/**
* A function that is called to trigger asynchronous canvas drawing. It is
* called with a "done" callback that should be called when drawing is done.
* If any error occurs during drawing, the "done" callback should be called with
* that error.
*
* @typedef {function(function(Error=): void): void} Loader
*/
var ImageCanvas = /** @class */ (function (_super) {
__extends(ImageCanvas, _super);
/**
* @param {import("./extent.js").Extent} extent Extent.
* @param {number} resolution Resolution.
* @param {number} pixelRatio Pixel ratio.
* @param {HTMLCanvasElement} canvas Canvas.
* @param {Loader} [opt_loader] Optional loader function to
* support asynchronous canvas drawing.
*/
function ImageCanvas(extent, resolution, pixelRatio, canvas, opt_loader) {
var _this = this;
var state = opt_loader !== undefined ? ImageState.IDLE : ImageState.LOADED;
_this = _super.call(this, extent, resolution, pixelRatio, state) || this;
/**
* Optional canvas loader function.
* @type {?Loader}
* @private
*/
_this.loader_ = opt_loader !== undefined ? opt_loader : null;
/**
* @private
* @type {HTMLCanvasElement}
*/
_this.canvas_ = canvas;
/**
* @private
* @type {?Error}
*/
_this.error_ = null;
return _this;
}
/**
* Get any error associated with asynchronous rendering.
* @return {?Error} Any error that occurred during rendering.
*/
ImageCanvas.prototype.getError = function () {
return this.error_;
};
/**
* Handle async drawing complete.
* @param {Error} [err] Any error during drawing.
* @private
*/
ImageCanvas.prototype.handleLoad_ = function (err) {
if (err) {
this.error_ = err;
this.state = ImageState.ERROR;
}
else {
this.state = ImageState.LOADED;
}
this.changed();
};
/**
* Load not yet loaded URI.
*/
ImageCanvas.prototype.load = function () {
if (this.state == ImageState.IDLE) {
this.state = ImageState.LOADING;
this.changed();
this.loader_(this.handleLoad_.bind(this));
}
};
/**
* @return {HTMLCanvasElement} Canvas element.
*/
ImageCanvas.prototype.getImage = function () {
return this.canvas_;
};
return ImageCanvas;
}(ImageBase));
export default ImageCanvas;
//# sourceMappingURL=ImageCanvas.js.map

1
node_modules/ol/ImageCanvas.js.map generated vendored Normal file
View File

@@ -0,0 +1 @@
{"version":3,"file":"ImageCanvas.js","sourceRoot":"","sources":["src/ImageCanvas.js"],"names":[],"mappings":";;;;;;;;;;;;;;;AAAA;;GAEG;AACH,OAAO,SAAS,MAAM,gBAAgB,CAAC;AACvC,OAAO,UAAU,MAAM,iBAAiB,CAAC;AAEzC;;;;;;;GAOG;AAEH;IAA0B,+BAAS;IACjC;;;;;;;OAOG;IACH,qBAAY,MAAM,EAAE,UAAU,EAAE,UAAU,EAAE,MAAM,EAAE,UAAU;QAA9D,iBAwBC;QAvBC,IAAM,KAAK,GACT,UAAU,KAAK,SAAS,CAAC,CAAC,CAAC,UAAU,CAAC,IAAI,CAAC,CAAC,CAAC,UAAU,CAAC,MAAM,CAAC;gBAEjE,kBAAM,MAAM,EAAE,UAAU,EAAE,UAAU,EAAE,KAAK,CAAC;QAE5C;;;;WAIG;QACH,KAAI,CAAC,OAAO,GAAG,UAAU,KAAK,SAAS,CAAC,CAAC,CAAC,UAAU,CAAC,CAAC,CAAC,IAAI,CAAC;QAE5D;;;WAGG;QACH,KAAI,CAAC,OAAO,GAAG,MAAM,CAAC;QAEtB;;;WAGG;QACH,KAAI,CAAC,MAAM,GAAG,IAAI,CAAC;;IACrB,CAAC;IAED;;;OAGG;IACH,8BAAQ,GAAR;QACE,OAAO,IAAI,CAAC,MAAM,CAAC;IACrB,CAAC;IAED;;;;OAIG;IACH,iCAAW,GAAX,UAAY,GAAG;QACb,IAAI,GAAG,EAAE;YACP,IAAI,CAAC,MAAM,GAAG,GAAG,CAAC;YAClB,IAAI,CAAC,KAAK,GAAG,UAAU,CAAC,KAAK,CAAC;SAC/B;aAAM;YACL,IAAI,CAAC,KAAK,GAAG,UAAU,CAAC,MAAM,CAAC;SAChC;QACD,IAAI,CAAC,OAAO,EAAE,CAAC;IACjB,CAAC;IAED;;OAEG;IACH,0BAAI,GAAJ;QACE,IAAI,IAAI,CAAC,KAAK,IAAI,UAAU,CAAC,IAAI,EAAE;YACjC,IAAI,CAAC,KAAK,GAAG,UAAU,CAAC,OAAO,CAAC;YAChC,IAAI,CAAC,OAAO,EAAE,CAAC;YACf,IAAI,CAAC,OAAO,CAAC,IAAI,CAAC,WAAW,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC,CAAC;SAC3C;IACH,CAAC;IAED;;OAEG;IACH,8BAAQ,GAAR;QACE,OAAO,IAAI,CAAC,OAAO,CAAC;IACtB,CAAC;IACH,kBAAC;AAAD,CAAC,AA3ED,CAA0B,SAAS,GA2ElC;AAED,eAAe,WAAW,CAAC"}

9
node_modules/ol/ImageState.d.ts generated vendored Normal file
View File

@@ -0,0 +1,9 @@
declare namespace _default {
const IDLE: number;
const LOADING: number;
const LOADED: number;
const ERROR: number;
const EMPTY: number;
}
export default _default;
//# sourceMappingURL=ImageState.d.ts.map

1
node_modules/ol/ImageState.d.ts.map generated vendored Normal file
View File

@@ -0,0 +1 @@
{"version":3,"file":"ImageState.d.ts","sourceRoot":"","sources":["src/ImageState.js"],"names":[],"mappings":""}

14
node_modules/ol/ImageState.js generated vendored Normal file
View File

@@ -0,0 +1,14 @@
/**
* @module ol/ImageState
*/
/**
* @enum {number}
*/
export default {
IDLE: 0,
LOADING: 1,
LOADED: 2,
ERROR: 3,
EMPTY: 4,
};
//# sourceMappingURL=ImageState.js.map

1
node_modules/ol/ImageState.js.map generated vendored Normal file
View File

@@ -0,0 +1 @@
{"version":3,"file":"ImageState.js","sourceRoot":"","sources":["src/ImageState.js"],"names":[],"mappings":"AAAA;;GAEG;AAEH;;GAEG;AACH,eAAe;IACb,IAAI,EAAE,CAAC;IACP,OAAO,EAAE,CAAC;IACV,MAAM,EAAE,CAAC;IACT,KAAK,EAAE,CAAC;IACR,KAAK,EAAE,CAAC;CACT,CAAC"}

70
node_modules/ol/ImageTile.d.ts generated vendored Normal file
View File

@@ -0,0 +1,70 @@
export default ImageTile;
declare class ImageTile extends Tile {
/**
* @param {import("./tilecoord.js").TileCoord} tileCoord Tile coordinate.
* @param {import("./TileState.js").default} state State.
* @param {string} src Image source URI.
* @param {?string} crossOrigin Cross origin.
* @param {import("./Tile.js").LoadFunction} tileLoadFunction Tile load function.
* @param {import("./Tile.js").Options} [opt_options] Tile options.
*/
constructor(tileCoord: import("./tilecoord.js").TileCoord, state: any, src: string, crossOrigin: string | null, tileLoadFunction: import("./Tile.js").LoadFunction, opt_options?: import("./Tile.js").Options | undefined);
/**
* @private
* @type {?string}
*/
private crossOrigin_;
/**
* Image URI
*
* @private
* @type {string}
*/
private src_;
/**
* @private
* @type {HTMLImageElement|HTMLCanvasElement}
*/
private image_;
/**
* @private
* @type {?function():void}
*/
private unlisten_;
/**
* @private
* @type {import("./Tile.js").LoadFunction}
*/
private tileLoadFunction_;
/**
* Get the HTML image element for this tile (may be a Canvas, Image, or Video).
* @return {HTMLCanvasElement|HTMLImageElement|HTMLVideoElement} Image.
* @api
*/
getImage(): HTMLCanvasElement | HTMLImageElement | HTMLVideoElement;
/**
* Sets an HTML image element for this tile (may be a Canvas or preloaded Image).
* @param {HTMLCanvasElement|HTMLImageElement} element Element.
*/
setImage(element: HTMLCanvasElement | HTMLImageElement): void;
/**
* Tracks loading or read errors.
*
* @private
*/
private handleImageError_;
/**
* Tracks successful image load.
*
* @private
*/
private handleImageLoad_;
/**
* Discards event handlers which listen for load completion or errors.
*
* @private
*/
private unlistenImage_;
}
import Tile from "./Tile.js";
//# sourceMappingURL=ImageTile.d.ts.map

1
node_modules/ol/ImageTile.d.ts.map generated vendored Normal file
View File

@@ -0,0 +1 @@
{"version":3,"file":"ImageTile.d.ts","sourceRoot":"","sources":["src/ImageTile.js"],"names":[],"mappings":";AAQA;IACE;;;;;;;OAOG;IACH,uBAPW,OAAO,gBAAgB,EAAE,SAAS,mBAElC,MAAM,eACL,MAAM,2BACP,OAAO,WAAW,EAAE,YAAY,yDAiD1C;IApCC;;;OAGG;IACH,qBAA+B;IAE/B;;;;;OAKG;IACH,aAAe;IAIf;;;OAGG;IACH,eAAyB;IAKzB;;;OAGG;IACH,kBAAqB;IAErB;;;OAGG;IACH,0BAAyC;IAG3C;;;;OAIG;IACH,YAHY,iBAAiB,GAAC,gBAAgB,GAAC,gBAAgB,CAK9D;IAED;;;OAGG;IACH,kBAFW,iBAAiB,GAAC,gBAAgB,QAO5C;IAED;;;;OAIG;IACH,0BAKC;IAED;;;;OAIG;IACH,yBASC;IA0BD;;;;OAIG;IACH,uBAKC;CACF"}

156
node_modules/ol/ImageTile.js generated vendored Normal file
View File

@@ -0,0 +1,156 @@
var __extends = (this && this.__extends) || (function () {
var extendStatics = function (d, b) {
extendStatics = Object.setPrototypeOf ||
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };
return extendStatics(d, b);
};
return function (d, b) {
if (typeof b !== "function" && b !== null)
throw new TypeError("Class extends value " + String(b) + " is not a constructor or null");
extendStatics(d, b);
function __() { this.constructor = d; }
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
};
})();
/**
* @module ol/ImageTile
*/
import Tile from './Tile.js';
import TileState from './TileState.js';
import { createCanvasContext2D } from './dom.js';
import { listenImage } from './Image.js';
var ImageTile = /** @class */ (function (_super) {
__extends(ImageTile, _super);
/**
* @param {import("./tilecoord.js").TileCoord} tileCoord Tile coordinate.
* @param {import("./TileState.js").default} state State.
* @param {string} src Image source URI.
* @param {?string} crossOrigin Cross origin.
* @param {import("./Tile.js").LoadFunction} tileLoadFunction Tile load function.
* @param {import("./Tile.js").Options} [opt_options] Tile options.
*/
function ImageTile(tileCoord, state, src, crossOrigin, tileLoadFunction, opt_options) {
var _this = _super.call(this, tileCoord, state, opt_options) || this;
/**
* @private
* @type {?string}
*/
_this.crossOrigin_ = crossOrigin;
/**
* Image URI
*
* @private
* @type {string}
*/
_this.src_ = src;
_this.key = src;
/**
* @private
* @type {HTMLImageElement|HTMLCanvasElement}
*/
_this.image_ = new Image();
if (crossOrigin !== null) {
_this.image_.crossOrigin = crossOrigin;
}
/**
* @private
* @type {?function():void}
*/
_this.unlisten_ = null;
/**
* @private
* @type {import("./Tile.js").LoadFunction}
*/
_this.tileLoadFunction_ = tileLoadFunction;
return _this;
}
/**
* Get the HTML image element for this tile (may be a Canvas, Image, or Video).
* @return {HTMLCanvasElement|HTMLImageElement|HTMLVideoElement} Image.
* @api
*/
ImageTile.prototype.getImage = function () {
return this.image_;
};
/**
* Sets an HTML image element for this tile (may be a Canvas or preloaded Image).
* @param {HTMLCanvasElement|HTMLImageElement} element Element.
*/
ImageTile.prototype.setImage = function (element) {
this.image_ = element;
this.state = TileState.LOADED;
this.unlistenImage_();
this.changed();
};
/**
* Tracks loading or read errors.
*
* @private
*/
ImageTile.prototype.handleImageError_ = function () {
this.state = TileState.ERROR;
this.unlistenImage_();
this.image_ = getBlankImage();
this.changed();
};
/**
* Tracks successful image load.
*
* @private
*/
ImageTile.prototype.handleImageLoad_ = function () {
var image = /** @type {HTMLImageElement} */ (this.image_);
if (image.naturalWidth && image.naturalHeight) {
this.state = TileState.LOADED;
}
else {
this.state = TileState.EMPTY;
}
this.unlistenImage_();
this.changed();
};
/**
* Load not yet loaded URI.
* @api
*/
ImageTile.prototype.load = function () {
if (this.state == TileState.ERROR) {
this.state = TileState.IDLE;
this.image_ = new Image();
if (this.crossOrigin_ !== null) {
this.image_.crossOrigin = this.crossOrigin_;
}
}
if (this.state == TileState.IDLE) {
this.state = TileState.LOADING;
this.changed();
this.tileLoadFunction_(this, this.src_);
this.unlisten_ = listenImage(this.image_, this.handleImageLoad_.bind(this), this.handleImageError_.bind(this));
}
};
/**
* Discards event handlers which listen for load completion or errors.
*
* @private
*/
ImageTile.prototype.unlistenImage_ = function () {
if (this.unlisten_) {
this.unlisten_();
this.unlisten_ = null;
}
};
return ImageTile;
}(Tile));
/**
* Get a 1-pixel blank image.
* @return {HTMLCanvasElement} Blank image.
*/
function getBlankImage() {
var ctx = createCanvasContext2D(1, 1);
ctx.fillStyle = 'rgba(0,0,0,0)';
ctx.fillRect(0, 0, 1, 1);
return ctx.canvas;
}
export default ImageTile;
//# sourceMappingURL=ImageTile.js.map

1
node_modules/ol/ImageTile.js.map generated vendored Normal file
View File

@@ -0,0 +1 @@
{"version":3,"file":"ImageTile.js","sourceRoot":"","sources":["src/ImageTile.js"],"names":[],"mappings":";;;;;;;;;;;;;;;AAAA;;GAEG;AACH,OAAO,IAAI,MAAM,WAAW,CAAC;AAC7B,OAAO,SAAS,MAAM,gBAAgB,CAAC;AACvC,OAAO,EAAC,qBAAqB,EAAC,MAAM,UAAU,CAAC;AAC/C,OAAO,EAAC,WAAW,EAAC,MAAM,YAAY,CAAC;AAEvC;IAAwB,6BAAI;IA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ID,CAAwB,IAAI,GA4I3B;AAED;;;GAGG;AACH,SAAS,aAAa;IACpB,IAAM,GAAG,GAAG,qBAAqB,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC;IACxC,GAAG,CAAC,SAAS,GAAG,eAAe,CAAC;IAChC,GAAG,CAAC,QAAQ,CAAC,CAAC,EAAE,CAAC,EAAE,CAAC,EAAE,CAAC,CAAC,CAAC;IACzB,OAAO,GAAG,CAAC,MAAM,CAAC;AACpB,CAAC;AAED,eAAe,SAAS,CAAC"}

71
node_modules/ol/Kinetic.d.ts generated vendored Normal file
View File

@@ -0,0 +1,71 @@
export default Kinetic;
/**
* @module ol/Kinetic
*/
/**
* @classdesc
* Implementation of inertial deceleration for map movement.
*
* @api
*/
declare class Kinetic {
/**
* @param {number} decay Rate of decay (must be negative).
* @param {number} minVelocity Minimum velocity (pixels/millisecond).
* @param {number} delay Delay to consider to calculate the kinetic
* initial values (milliseconds).
*/
constructor(decay: number, minVelocity: number, delay: number);
/**
* @private
* @type {number}
*/
private decay_;
/**
* @private
* @type {number}
*/
private minVelocity_;
/**
* @private
* @type {number}
*/
private delay_;
/**
* @private
* @type {Array<number>}
*/
private points_;
/**
* @private
* @type {number}
*/
private angle_;
/**
* @private
* @type {number}
*/
private initialVelocity_;
/**
* FIXME empty description for jsdoc
*/
begin(): void;
/**
* @param {number} x X.
* @param {number} y Y.
*/
update(x: number, y: number): void;
/**
* @return {boolean} Whether we should do kinetic animation.
*/
end(): boolean;
/**
* @return {number} Total distance travelled (pixels).
*/
getDistance(): number;
/**
* @return {number} Angle of the kinetic panning animation (radians).
*/
getAngle(): number;
}
//# sourceMappingURL=Kinetic.d.ts.map

1
node_modules/ol/Kinetic.d.ts.map generated vendored Normal file
View File

@@ -0,0 +1 @@
{"version":3,"file":"Kinetic.d.ts","sourceRoot":"","sources":["src/Kinetic.js"],"names":[],"mappings":";AAAA;;GAEG;AAEH;;;;;GAKG;AACH;IACE;;;;;OAKG;IACH,mBALW,MAAM,eACN,MAAM,SACN,MAAM,EAuChB;IAnCC;;;OAGG;IACH,eAAmB;IAEnB;;;OAGG;IACH,qBAA+B;IAE/B;;;OAGG;IACH,eAAmB;IAEnB;;;OAGG;IACH,gBAAiB;IAEjB;;;OAGG;IACH,eAAe;IAEf;;;OAGG;IACH,yBAAyB;IAG3B;;OAEG;IACH,cAIC;IAED;;;OAGG;IACH,UAHW,MAAM,KACN,MAAM,QAIhB;IAED;;OAEG;IACH,OAFY,OAAO,CAmClB;IAED;;OAEG;IACH,eAFY,MAAM,CAIjB;IAED;;OAEG;IACH,YAFY,MAAM,CAIjB;CACF"}

113
node_modules/ol/Kinetic.js generated vendored Normal file
View File

@@ -0,0 +1,113 @@
/**
* @module ol/Kinetic
*/
/**
* @classdesc
* Implementation of inertial deceleration for map movement.
*
* @api
*/
var Kinetic = /** @class */ (function () {
/**
* @param {number} decay Rate of decay (must be negative).
* @param {number} minVelocity Minimum velocity (pixels/millisecond).
* @param {number} delay Delay to consider to calculate the kinetic
* initial values (milliseconds).
*/
function Kinetic(decay, minVelocity, delay) {
/**
* @private
* @type {number}
*/
this.decay_ = decay;
/**
* @private
* @type {number}
*/
this.minVelocity_ = minVelocity;
/**
* @private
* @type {number}
*/
this.delay_ = delay;
/**
* @private
* @type {Array<number>}
*/
this.points_ = [];
/**
* @private
* @type {number}
*/
this.angle_ = 0;
/**
* @private
* @type {number}
*/
this.initialVelocity_ = 0;
}
/**
* FIXME empty description for jsdoc
*/
Kinetic.prototype.begin = function () {
this.points_.length = 0;
this.angle_ = 0;
this.initialVelocity_ = 0;
};
/**
* @param {number} x X.
* @param {number} y Y.
*/
Kinetic.prototype.update = function (x, y) {
this.points_.push(x, y, Date.now());
};
/**
* @return {boolean} Whether we should do kinetic animation.
*/
Kinetic.prototype.end = function () {
if (this.points_.length < 6) {
// at least 2 points are required (i.e. there must be at least 6 elements
// in the array)
return false;
}
var delay = Date.now() - this.delay_;
var lastIndex = this.points_.length - 3;
if (this.points_[lastIndex + 2] < delay) {
// the last tracked point is too old, which means that the user stopped
// panning before releasing the map
return false;
}
// get the first point which still falls into the delay time
var firstIndex = lastIndex - 3;
while (firstIndex > 0 && this.points_[firstIndex + 2] > delay) {
firstIndex -= 3;
}
var duration = this.points_[lastIndex + 2] - this.points_[firstIndex + 2];
// we don't want a duration of 0 (divide by zero)
// we also make sure the user panned for a duration of at least one frame
// (1/60s) to compute sane displacement values
if (duration < 1000 / 60) {
return false;
}
var dx = this.points_[lastIndex] - this.points_[firstIndex];
var dy = this.points_[lastIndex + 1] - this.points_[firstIndex + 1];
this.angle_ = Math.atan2(dy, dx);
this.initialVelocity_ = Math.sqrt(dx * dx + dy * dy) / duration;
return this.initialVelocity_ > this.minVelocity_;
};
/**
* @return {number} Total distance travelled (pixels).
*/
Kinetic.prototype.getDistance = function () {
return (this.minVelocity_ - this.initialVelocity_) / this.decay_;
};
/**
* @return {number} Angle of the kinetic panning animation (radians).
*/
Kinetic.prototype.getAngle = function () {
return this.angle_;
};
return Kinetic;
}());
export default Kinetic;
//# sourceMappingURL=Kinetic.js.map

1
node_modules/ol/Kinetic.js.map generated vendored Normal file
View File

@@ -0,0 +1 @@
{"version":3,"file":"Kinetic.js","sourceRoot":"","sources":["src/Kinetic.js"],"names":[],"mappings":"AAAA;;GAEG;AAEH;;;;;GAKG;AACH;IACE;;;;;OAKG;IACH,iBAAY,KAAK,EAAE,WAAW,EAAE,KAAK;QACnC;;;WAGG;QACH,IAAI,CAAC,MAAM,GAAG,KAAK,CAAC;QAEpB;;;WAGG;QACH,IAAI,CAAC,YAAY,GAAG,WAAW,CAAC;QAEhC;;;WAGG;QACH,IAAI,CAAC,MAAM,GAAG,KAAK,CAAC;QAEpB;;;WAGG;QACH,IAAI,CAAC,OAAO,GAAG,EAAE,CAAC;QAElB;;;WAGG;QACH,IAAI,CAAC,MAAM,GAAG,CAAC,CAAC;QAEhB;;;WAGG;QACH,IAAI,CAAC,gBAAgB,GAAG,CAAC,CAAC;IAC5B,CAAC;IAED;;OAE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ACd;QAED,IAAM,EAAE,GAAG,IAAI,CAAC,OAAO,CAAC,SAAS,CAAC,GAAG,IAAI,CAAC,OAAO,CAAC,UAAU,CAAC,CAAC;QAC9D,IAAM,EAAE,GAAG,IAAI,CAAC,OAAO,CAAC,SAAS,GAAG,CAAC,CAAC,GAAG,IAAI,CAAC,OAAO,CAAC,UAAU,GAAG,CAAC,CAAC,CAAC;QACtE,IAAI,CAAC,MAAM,GAAG,IAAI,CAAC,KAAK,CAAC,EAAE,EAAE,EAAE,CAAC,CAAC;QACjC,IAAI,CAAC,gBAAgB,GAAG,IAAI,CAAC,IAAI,CAAC,EAAE,GAAG,EAAE,GAAG,EAAE,GAAG,EAAE,CAAC,GAAG,QAAQ,CAAC;QAChE,OAAO,IAAI,CAAC,gBAAgB,GAAG,IAAI,CAAC,YAAY,CAAC;IACnD,CAAC;IAED;;OAEG;IACH,6BAAW,GAAX;QACE,OAAO,CAAC,IAAI,CAAC,YAAY,GAAG,IAAI,CAAC,gBAAgB,CAAC,GAAG,IAAI,CAAC,MAAM,CAAC;IACnE,CAAC;IAED;;OAEG;IACH,0BAAQ,GAAR;QACE,OAAO,IAAI,CAAC,MAAM,CAAC;IACrB,CAAC;IACH,cAAC;AAAD,CAAC,AAjHD,IAiHC;AAED,eAAe,OAAO,CAAC"}

25
node_modules/ol/LICENSE.md generated vendored Normal file
View File

@@ -0,0 +1,25 @@
BSD 2-Clause License
Copyright 2005-present, OpenLayers Contributors
All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
1. Redistributions of source code must retain the above copyright notice, this
list of conditions and the following disclaimer.
2. Redistributions in binary form must reproduce the above copyright notice,
this list of conditions and the following disclaimer in the documentation
and/or other materials provided with the distribution.
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE
FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.

53
node_modules/ol/Map.d.ts generated vendored Normal file
View File

@@ -0,0 +1,53 @@
export default Map;
/**
* @classdesc
* The map is the core component of OpenLayers. For a map to render, a view,
* one or more layers, and a target container are needed:
*
* import Map from 'ol/Map';
* import View from 'ol/View';
* import TileLayer from 'ol/layer/Tile';
* import OSM from 'ol/source/OSM';
*
* var map = new Map({
* view: new View({
* center: [0, 0],
* zoom: 1
* }),
* layers: [
* new TileLayer({
* source: new OSM()
* })
* ],
* target: 'map'
* });
*
* The above snippet creates a map using a {@link module:ol/layer/Tile~TileLayer} to
* display {@link module:ol/source/OSM~OSM} OSM data and render it to a DOM
* element with the id `map`.
*
* The constructor places a viewport container (with CSS class name
* `ol-viewport`) in the target element (see `getViewport()`), and then two
* further elements within the viewport: one with CSS class name
* `ol-overlaycontainer-stopevent` for controls and some overlays, and one with
* CSS class name `ol-overlaycontainer` for other overlays (see the `stopEvent`
* option of {@link module:ol/Overlay~Overlay} for the difference). The map
* itself is placed in a further element within the viewport.
*
* Layers are stored as a {@link module:ol/Collection~Collection} in
* layerGroups. A top-level group is provided by the library. This is what is
* accessed by `getLayerGroup` and `setLayerGroup`. Layers entered in the
* options are added to this group, and `addLayer` and `removeLayer` change the
* layer collection in the group. `getLayers` is a convenience function for
* `getLayerGroup().getLayers()`. Note that {@link module:ol/layer/Group~LayerGroup}
* is a subclass of {@link module:ol/layer/Base~BaseLayer}, so layers entered in the
* options or added with `addLayer` can be groups, which can contain further
* groups, and so on.
*
* @api
*/
declare class Map extends PluggableMap {
createRenderer(): any;
}
import PluggableMap from "./PluggableMap.js";
//# sourceMappingURL=Map.d.ts.map

1
node_modules/ol/Map.d.ts.map generated vendored Normal file
View File

@@ -0,0 +1 @@
{"version":3,"file":"Map.d.ts","sourceRoot":"","sources":["src/Map.js"],"names":[],"mappings":";AASA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA8CG;AACH;IAkBE,sBAEC;CACF"}

94
node_modules/ol/Map.js generated vendored Normal file
View File

@@ -0,0 +1,94 @@
var __extends = (this && this.__extends) || (function () {
var extendStatics = function (d, b) {
extendStatics = Object.setPrototypeOf ||
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };
return extendStatics(d, b);
};
return function (d, b) {
if (typeof b !== "function" && b !== null)
throw new TypeError("Class extends value " + String(b) + " is not a constructor or null");
extendStatics(d, b);
function __() { this.constructor = d; }
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
};
})();
/**
* @module ol/Map
*/
import CompositeMapRenderer from './renderer/Composite.js';
import PluggableMap from './PluggableMap.js';
import { assign } from './obj.js';
import { defaults as defaultControls } from './control.js';
import { defaults as defaultInteractions } from './interaction.js';
/**
* @classdesc
* The map is the core component of OpenLayers. For a map to render, a view,
* one or more layers, and a target container are needed:
*
* import Map from 'ol/Map';
* import View from 'ol/View';
* import TileLayer from 'ol/layer/Tile';
* import OSM from 'ol/source/OSM';
*
* var map = new Map({
* view: new View({
* center: [0, 0],
* zoom: 1
* }),
* layers: [
* new TileLayer({
* source: new OSM()
* })
* ],
* target: 'map'
* });
*
* The above snippet creates a map using a {@link module:ol/layer/Tile~TileLayer} to
* display {@link module:ol/source/OSM~OSM} OSM data and render it to a DOM
* element with the id `map`.
*
* The constructor places a viewport container (with CSS class name
* `ol-viewport`) in the target element (see `getViewport()`), and then two
* further elements within the viewport: one with CSS class name
* `ol-overlaycontainer-stopevent` for controls and some overlays, and one with
* CSS class name `ol-overlaycontainer` for other overlays (see the `stopEvent`
* option of {@link module:ol/Overlay~Overlay} for the difference). The map
* itself is placed in a further element within the viewport.
*
* Layers are stored as a {@link module:ol/Collection~Collection} in
* layerGroups. A top-level group is provided by the library. This is what is
* accessed by `getLayerGroup` and `setLayerGroup`. Layers entered in the
* options are added to this group, and `addLayer` and `removeLayer` change the
* layer collection in the group. `getLayers` is a convenience function for
* `getLayerGroup().getLayers()`. Note that {@link module:ol/layer/Group~LayerGroup}
* is a subclass of {@link module:ol/layer/Base~BaseLayer}, so layers entered in the
* options or added with `addLayer` can be groups, which can contain further
* groups, and so on.
*
* @api
*/
var Map = /** @class */ (function (_super) {
__extends(Map, _super);
/**
* @param {import("./PluggableMap.js").MapOptions} options Map options.
*/
function Map(options) {
options = assign({}, options);
if (!options.controls) {
options.controls = defaultControls();
}
if (!options.interactions) {
options.interactions = defaultInteractions({
onFocusOnly: true,
});
}
return _super.call(this, options) || this;
}
Map.prototype.createRenderer = function () {
return new CompositeMapRenderer(this);
};
return Map;
}(PluggableMap));
export default Map;
//# sourceMappingURL=Map.js.map

1
node_modules/ol/Map.js.map generated vendored Normal file
View File

@@ -0,0 +1 @@
{"version":3,"file":"Map.js","sourceRoot":"","sources":["src/Map.js"],"names":[],"mappings":";;;;;;;;;;;;;;;AAAA;;GAEG;AACH,OAAO,oBAAoB,MAAM,yBAAyB,CAAC;AAC3D,OAAO,YAAY,MAAM,mBAAmB,CAAC;AAC7C,OAAO,EAAC,MAAM,EAAC,MAAM,UAAU,CAAC;AAChC,OAAO,EAAC,QAAQ,IAAI,eAAe,EAAC,MAAM,cAAc,CAAC;AACzD,OAAO,EAAC,QAAQ,IAAI,mBAAmB,EAAC,MAAM,kBAAkB,CAAC;AAEjE;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA8CG;AACH;IAAkB,uBAAY;IAC5B;;OAEG;IACH,aAAY,OAAO;QACjB,OAAO,GAAG,MAAM,CAAC,EAAE,EAAE,OAAO,CAAC,CAAC;QAC9B,IAAI,CAAC,OAAO,CAAC,QAAQ,EAAE;YACrB,OAAO,CAAC,QAAQ,GAAG,eAAe,EAAE,CAAC;SACtC;QACD,IAAI,CAAC,OAAO,CAAC,YAAY,EAAE;YACzB,OAAO,CAAC,YAAY,GAAG,mBAAmB,CAAC;gBACzC,WAAW,EAAE,IAAI;aAClB,CAAC,CAAC;SACJ;eAED,kBAAM,OAAO,CAAC;IAChB,CAAC;IAED,4BAAc,GAAd;QACE,OAAO,IAAI,oBAAoB,CAAC,IAAI,CAAC,CAAC;IACxC,CAAC;IACH,UAAC;AAAD,CAAC,AArBD,CAAkB,YAAY,GAqB7B;AAED,eAAe,GAAG,CAAC"}

64
node_modules/ol/MapBrowserEvent.d.ts generated vendored Normal file
View File

@@ -0,0 +1,64 @@
export default MapBrowserEvent;
/**
* @classdesc
* Events emitted as map browser events are instances of this type.
* See {@link module:ol/PluggableMap~PluggableMap} for which events trigger a map browser event.
* @template {UIEvent} EVENT
*/
declare class MapBrowserEvent<EVENT extends UIEvent> extends MapEvent {
/**
* @param {string} type Event type.
* @param {import("./PluggableMap.js").default} map Map.
* @param {EVENT} originalEvent Original event.
* @param {boolean} [opt_dragging] Is the map currently being dragged?
* @param {import("./PluggableMap.js").FrameState} [opt_frameState] Frame state.
* @param {Array<PointerEvent>} [opt_activePointers] Active pointers.
*/
constructor(type: string, map: import("./PluggableMap.js").default, originalEvent: EVENT, opt_dragging?: boolean | undefined, opt_frameState?: import("./PluggableMap.js").FrameState | undefined, opt_activePointers?: PointerEvent[] | undefined);
/**
* The original browser event.
* @const
* @type {EVENT}
* @api
*/
originalEvent: EVENT;
/**
* The map pixel relative to the viewport corresponding to the original browser event.
* @type {?import("./pixel.js").Pixel}
*/
pixel_: import("./pixel.js").Pixel | null;
/**
* The coordinate in the user projection corresponding to the original browser event.
* @type {?import("./coordinate.js").Coordinate}
*/
coordinate_: import("./coordinate.js").Coordinate | null;
/**
* Indicates if the map is currently being dragged. Only set for
* `POINTERDRAG` and `POINTERMOVE` events. Default is `false`.
*
* @type {boolean}
* @api
*/
dragging: boolean;
/**
* @type {Array<PointerEvent>|undefined}
*/
activePointers: Array<PointerEvent> | undefined;
set pixel(arg: import("./pixel.js").Pixel);
/**
* The map pixel relative to the viewport corresponding to the original event.
* @type {import("./pixel.js").Pixel}
* @api
*/
get pixel(): import("./pixel.js").Pixel;
set coordinate(arg: import("./coordinate.js").Coordinate);
/**
* The coordinate corresponding to the original browser event. This will be in the user
* projection if one is set. Otherwise it will be in the view projection.
* @type {import("./coordinate.js").Coordinate}
* @api
*/
get coordinate(): import("./coordinate.js").Coordinate;
}
import MapEvent from "./MapEvent.js";
//# sourceMappingURL=MapBrowserEvent.d.ts.map

1
node_modules/ol/MapBrowserEvent.d.ts.map generated vendored Normal file
View File

@@ -0,0 +1 @@
{"version":3,"file":"MapBrowserEvent.d.ts","sourceRoot":"","sources":["src/MapBrowserEvent.js"],"names":[],"mappings":";AAKA;;;;;GAKG;AACH;IACE;;;;;;;OAOG;IACH,kBAPW,MAAM,OACN,OAAO,mBAAmB,EAAE,OAAO,iBACnC,KAAK,4JAgDf;IAjCC;;;;;OAKG;IACH,eAHU,KAAK,CAGmB;IAElC;;;OAGG;IACH,QAFW,OAAO,YAAY,EAAE,KAAK,QAEnB;IAElB;;;OAGG;IACH,aAFW,OAAO,iBAAiB,EAAE,UAAU,QAExB;IAEvB;;;;;;OAMG;IACH,UAHU,OAAO,CAGgD;IAEjE;;OAEG;IACH,gBAFU,MAAM,YAAY,CAAC,GAAC,SAAS,CAEC;IAc1C,2CAEC;IAbD;;;;OAIG;IACH,wCAKC;IAiBD,0DAEC;IAdD;;;;;OAKG;IACH,uDAKC;CA4BF"}

131
node_modules/ol/MapBrowserEvent.js generated vendored Normal file
View File

@@ -0,0 +1,131 @@
var __extends = (this && this.__extends) || (function () {
var extendStatics = function (d, b) {
extendStatics = Object.setPrototypeOf ||
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };
return extendStatics(d, b);
};
return function (d, b) {
if (typeof b !== "function" && b !== null)
throw new TypeError("Class extends value " + String(b) + " is not a constructor or null");
extendStatics(d, b);
function __() { this.constructor = d; }
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
};
})();
/**
* @module ol/MapBrowserEvent
*/
import MapEvent from './MapEvent.js';
/**
* @classdesc
* Events emitted as map browser events are instances of this type.
* See {@link module:ol/PluggableMap~PluggableMap} for which events trigger a map browser event.
* @template {UIEvent} EVENT
*/
var MapBrowserEvent = /** @class */ (function (_super) {
__extends(MapBrowserEvent, _super);
/**
* @param {string} type Event type.
* @param {import("./PluggableMap.js").default} map Map.
* @param {EVENT} originalEvent Original event.
* @param {boolean} [opt_dragging] Is the map currently being dragged?
* @param {import("./PluggableMap.js").FrameState} [opt_frameState] Frame state.
* @param {Array<PointerEvent>} [opt_activePointers] Active pointers.
*/
function MapBrowserEvent(type, map, originalEvent, opt_dragging, opt_frameState, opt_activePointers) {
var _this = _super.call(this, type, map, opt_frameState) || this;
/**
* The original browser event.
* @const
* @type {EVENT}
* @api
*/
_this.originalEvent = originalEvent;
/**
* The map pixel relative to the viewport corresponding to the original browser event.
* @type {?import("./pixel.js").Pixel}
*/
_this.pixel_ = null;
/**
* The coordinate in the user projection corresponding to the original browser event.
* @type {?import("./coordinate.js").Coordinate}
*/
_this.coordinate_ = null;
/**
* Indicates if the map is currently being dragged. Only set for
* `POINTERDRAG` and `POINTERMOVE` events. Default is `false`.
*
* @type {boolean}
* @api
*/
_this.dragging = opt_dragging !== undefined ? opt_dragging : false;
/**
* @type {Array<PointerEvent>|undefined}
*/
_this.activePointers = opt_activePointers;
return _this;
}
Object.defineProperty(MapBrowserEvent.prototype, "pixel", {
/**
* The map pixel relative to the viewport corresponding to the original event.
* @type {import("./pixel.js").Pixel}
* @api
*/
get: function () {
if (!this.pixel_) {
this.pixel_ = this.map.getEventPixel(this.originalEvent);
}
return this.pixel_;
},
set: function (pixel) {
this.pixel_ = pixel;
},
enumerable: false,
configurable: true
});
Object.defineProperty(MapBrowserEvent.prototype, "coordinate", {
/**
* The coordinate corresponding to the original browser event. This will be in the user
* projection if one is set. Otherwise it will be in the view projection.
* @type {import("./coordinate.js").Coordinate}
* @api
*/
get: function () {
if (!this.coordinate_) {
this.coordinate_ = this.map.getCoordinateFromPixel(this.pixel);
}
return this.coordinate_;
},
set: function (coordinate) {
this.coordinate_ = coordinate;
},
enumerable: false,
configurable: true
});
/**
* Prevents the default browser action.
* See https://developer.mozilla.org/en-US/docs/Web/API/event.preventDefault.
* @api
*/
MapBrowserEvent.prototype.preventDefault = function () {
_super.prototype.preventDefault.call(this);
if ('preventDefault' in this.originalEvent) {
/** @type {UIEvent} */ (this.originalEvent).preventDefault();
}
};
/**
* Prevents further propagation of the current event.
* See https://developer.mozilla.org/en-US/docs/Web/API/event.stopPropagation.
* @api
*/
MapBrowserEvent.prototype.stopPropagation = function () {
_super.prototype.stopPropagation.call(this);
if ('stopPropagation' in this.originalEvent) {
/** @type {UIEvent} */ (this.originalEvent).stopPropagation();
}
};
return MapBrowserEvent;
}(MapEvent));
export default MapBrowserEvent;
//# sourceMappingURL=MapBrowserEvent.js.map

1
node_modules/ol/MapBrowserEvent.js.map generated vendored Normal file
View File

@@ -0,0 +1 @@
{"version":3,"file":"MapBrowserEvent.js","sourceRoot":"","sources":["src/MapBrowserEvent.js"],"names":[],"mappings":";;;;;;;;;;;;;;;AAAA;;GAEG;AACH,OAAO,QAAQ,MAAM,eAAe,CAAC;AAErC;;;;;GAK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C;QACvB,IAAI,gBAAgB,IAAI,IAAI,CAAC,aAAa,EAAE;YAC1C,sBAAsB,CAAC,CAAC,IAAI,CAAC,aAAa,CAAC,CAAC,cAAc,EAAE,CAAC;SAC9D;IACH,CAAC;IAED;;;;OAIG;IACH,yCAAe,GAAf;QACE,iBAAM,eAAe,WAAE,CAAC;QACxB,IAAI,iBAAiB,IAAI,IAAI,CAAC,aAAa,EAAE;YAC3C,sBAAsB,CAAC,CAAC,IAAI,CAAC,aAAa,CAAC,CAAC,eAAe,EAAE,CAAC;SAC/D;IACH,CAAC;IACH,sBAAC;AAAD,CAAC,AA5GD,CAA8B,QAAQ,GA4GrC;AAED,eAAe,eAAe,CAAC"}

140
node_modules/ol/MapBrowserEventHandler.d.ts generated vendored Normal file
View File

@@ -0,0 +1,140 @@
export default MapBrowserEventHandler;
declare class MapBrowserEventHandler extends Target {
/**
* @param {import("./PluggableMap.js").default} map The map with the viewport to listen to events on.
* @param {number} [moveTolerance] The minimal distance the pointer must travel to trigger a move.
*/
constructor(map: import("./PluggableMap.js").default, moveTolerance?: number | undefined);
/**
* This is the element that we will listen to the real events on.
* @type {import("./PluggableMap.js").default}
* @private
*/
private map_;
/**
* @type {any}
* @private
*/
private clickTimeoutId_;
/**
* Emulate dblclick and singleclick. Will be true when only one pointer is active.
* @type {boolean}
*/
emulateClicks_: boolean;
/**
* @type {boolean}
* @private
*/
private dragging_;
/**
* @type {!Array<import("./events.js").EventsKey>}
* @private
*/
private dragListenerKeys_;
/**
* @type {number}
* @private
*/
private moveTolerance_;
/**
* The most recent "down" type event (or null if none have occurred).
* Set on pointerdown.
* @type {PointerEvent|null}
* @private
*/
private down_;
/**
* @type {Array<PointerEvent>}
* @private
*/
private activePointers_;
/**
* @type {!Object<number, Event>}
* @private
*/
private trackedTouches_;
element_: HTMLElement;
/**
* @type {?import("./events.js").EventsKey}
* @private
*/
private pointerdownListenerKey_;
/**
* @type {PointerEvent}
* @private
*/
private originalPointerMoveEvent_;
/**
* @type {?import("./events.js").EventsKey}
* @private
*/
private relayedListenerKey_;
/**
* @private
*/
private boundHandleTouchMove_;
/**
* @param {PointerEvent} pointerEvent Pointer
* event.
* @private
*/
private emulateClick_;
/**
* Keeps track on how many pointers are currently active.
*
* @param {PointerEvent} pointerEvent Pointer
* event.
* @private
*/
private updateActivePointers_;
/**
* @param {PointerEvent} pointerEvent Pointer
* event.
* @private
*/
private handlePointerUp_;
/**
* @param {PointerEvent} pointerEvent Pointer
* event.
* @return {boolean} If the left mouse button was pressed.
* @private
*/
private isMouseActionButton_;
/**
* @param {PointerEvent} pointerEvent Pointer
* event.
* @private
*/
private handlePointerDown_;
/**
* @param {PointerEvent} pointerEvent Pointer
* event.
* @private
*/
private handlePointerMove_;
/**
* Wrap and relay a pointermove event.
* @param {PointerEvent} pointerEvent Pointer
* event.
* @private
*/
private relayMoveEvent_;
/**
* Flexible handling of a `touch-action: none` css equivalent: because calling
* `preventDefault()` on a `pointermove` event does not stop native page scrolling
* and zooming, we also listen for `touchmove` and call `preventDefault()` on it
* when an interaction (currently `DragPan` handles the event.
* @param {TouchEvent} event Event.
* @private
*/
private handleTouchMove_;
/**
* @param {PointerEvent} pointerEvent Pointer
* event.
* @return {boolean} Is moving.
* @private
*/
private isMoving_;
}
import Target from "./events/Target.js";
//# sourceMappingURL=MapBrowserEventHandler.d.ts.map

1
node_modules/ol/MapBrowserEventHandler.d.ts.map generated vendored Normal file
View File

@@ -0,0 +1 @@
{"version":3,"file":"MapBrowserEventHandler.d.ts","sourceRoot":"","sources":["src/MapBrowserEventHandler.js"],"names":[],"mappings":";AAcA;IACE;;;OAGG;IACH,iBAHW,OAAO,mBAAmB,EAAE,OAAO,sCAyG7C;IAnGC;;;;OAIG;IACH,aAAe;IAEf;;;OAGG;IACH,wBAAoB;IAEpB;;;OAGG;IACH,gBAFU,OAAO,CAEU;IAE3B;;;OAGG;IACH,kBAAsB;IAEtB;;;OAGG;IACH,0BAA2B;IAE3B;;;OAGG;IACH,uBAAqE;IAErE;;;;;OAKG;IACH,cAAiB;IAIjB;;;OAGG;IACH,wBAAyB;IAEzB;;;OAGG;IACH,wBAAyB;IAEzB,sBAAuB;IAEvB;;;OAGG;IACH,gCAKC;IAED;;;OAGG;IACH,kCAA8B;IAE9B;;;OAGG;IACH,4BAKC;IAED;;OAEG;IACH,8BAA6D;IAS/D;;;;OAIG;IACH,sBAiCC;IAED;;;;;;OAMG;IACH,8BA0BC;IAED;;;;OAIG;IACH,yBAiCC;IAED;;;;;OAKG;IACH,6BAEC;IAED;;;;OAIG;IACH,2BA6DC;IAED;;;;OAIG;IACH,2BAiBC;IAED;;;;;OAKG;IACH,wBAWC;IAED;;;;;;;OAOG;IACH,yBAUC;IAED;;;;;OAKG;IACH,kBAOC;CA0BF"}

316
node_modules/ol/MapBrowserEventHandler.js generated vendored Normal file
View File

@@ -0,0 +1,316 @@
/**
* @module ol/MapBrowserEventHandler
*/
var __extends = (this && this.__extends) || (function () {
var extendStatics = function (d, b) {
extendStatics = Object.setPrototypeOf ||
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };
return extendStatics(d, b);
};
return function (d, b) {
if (typeof b !== "function" && b !== null)
throw new TypeError("Class extends value " + String(b) + " is not a constructor or null");
extendStatics(d, b);
function __() { this.constructor = d; }
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
};
})();
import EventType from './events/EventType.js';
import MapBrowserEvent from './MapBrowserEvent.js';
import MapBrowserEventType from './MapBrowserEventType.js';
import PointerEventType from './pointer/EventType.js';
import Target from './events/Target.js';
import { PASSIVE_EVENT_LISTENERS } from './has.js';
import { VOID } from './functions.js';
import { getValues } from './obj.js';
import { listen, unlistenByKey } from './events.js';
var MapBrowserEventHandler = /** @class */ (function (_super) {
__extends(MapBrowserEventHandler, _super);
/**
* @param {import("./PluggableMap.js").default} map The map with the viewport to listen to events on.
* @param {number} [moveTolerance] The minimal distance the pointer must travel to trigger a move.
*/
function MapBrowserEventHandler(map, moveTolerance) {
var _this = _super.call(this, map) || this;
/**
* This is the element that we will listen to the real events on.
* @type {import("./PluggableMap.js").default}
* @private
*/
_this.map_ = map;
/**
* @type {any}
* @private
*/
_this.clickTimeoutId_;
/**
* Emulate dblclick and singleclick. Will be true when only one pointer is active.
* @type {boolean}
*/
_this.emulateClicks_ = false;
/**
* @type {boolean}
* @private
*/
_this.dragging_ = false;
/**
* @type {!Array<import("./events.js").EventsKey>}
* @private
*/
_this.dragListenerKeys_ = [];
/**
* @type {number}
* @private
*/
_this.moveTolerance_ = moveTolerance === undefined ? 1 : moveTolerance;
/**
* The most recent "down" type event (or null if none have occurred).
* Set on pointerdown.
* @type {PointerEvent|null}
* @private
*/
_this.down_ = null;
var element = _this.map_.getViewport();
/**
* @type {Array<PointerEvent>}
* @private
*/
_this.activePointers_ = [];
/**
* @type {!Object<number, Event>}
* @private
*/
_this.trackedTouches_ = {};
_this.element_ = element;
/**
* @type {?import("./events.js").EventsKey}
* @private
*/
_this.pointerdownListenerKey_ = listen(element, PointerEventType.POINTERDOWN, _this.handlePointerDown_, _this);
/**
* @type {PointerEvent}
* @private
*/
_this.originalPointerMoveEvent_;
/**
* @type {?import("./events.js").EventsKey}
* @private
*/
_this.relayedListenerKey_ = listen(element, PointerEventType.POINTERMOVE, _this.relayMoveEvent_, _this);
/**
* @private
*/
_this.boundHandleTouchMove_ = _this.handleTouchMove_.bind(_this);
_this.element_.addEventListener(EventType.TOUCHMOVE, _this.boundHandleTouchMove_, PASSIVE_EVENT_LISTENERS ? { passive: false } : false);
return _this;
}
/**
* @param {PointerEvent} pointerEvent Pointer
* event.
* @private
*/
MapBrowserEventHandler.prototype.emulateClick_ = function (pointerEvent) {
var newEvent = new MapBrowserEvent(MapBrowserEventType.CLICK, this.map_, pointerEvent);
this.dispatchEvent(newEvent);
if (this.clickTimeoutId_ !== undefined) {
// double-click
clearTimeout(this.clickTimeoutId_);
this.clickTimeoutId_ = undefined;
newEvent = new MapBrowserEvent(MapBrowserEventType.DBLCLICK, this.map_, pointerEvent);
this.dispatchEvent(newEvent);
}
else {
// click
this.clickTimeoutId_ = setTimeout(
/** @this {MapBrowserEventHandler} */
function () {
this.clickTimeoutId_ = undefined;
var newEvent = new MapBrowserEvent(MapBrowserEventType.SINGLECLICK, this.map_, pointerEvent);
this.dispatchEvent(newEvent);
}.bind(this), 250);
}
};
/**
* Keeps track on how many pointers are currently active.
*
* @param {PointerEvent} pointerEvent Pointer
* event.
* @private
*/
MapBrowserEventHandler.prototype.updateActivePointers_ = function (pointerEvent) {
var event = pointerEvent;
var id = event.pointerId;
if (event.type == MapBrowserEventType.POINTERUP ||
event.type == MapBrowserEventType.POINTERCANCEL) {
delete this.trackedTouches_[id];
for (var pointerId in this.trackedTouches_) {
if (this.trackedTouches_[pointerId].target !== event.target) {
// Some platforms assign a new pointerId when the target changes.
// If this happens, delete one tracked pointer. If there is more
// than one tracked pointer for the old target, it will be cleared
// by subsequent POINTERUP events from other pointers.
delete this.trackedTouches_[pointerId];
break;
}
}
}
else if (event.type == MapBrowserEventType.POINTERDOWN ||
event.type == MapBrowserEventType.POINTERMOVE) {
this.trackedTouches_[id] = event;
}
this.activePointers_ = getValues(this.trackedTouches_);
};
/**
* @param {PointerEvent} pointerEvent Pointer
* event.
* @private
*/
MapBrowserEventHandler.prototype.handlePointerUp_ = function (pointerEvent) {
this.updateActivePointers_(pointerEvent);
var newEvent = new MapBrowserEvent(MapBrowserEventType.POINTERUP, this.map_, pointerEvent, undefined, undefined, this.activePointers_);
this.dispatchEvent(newEvent);
// We emulate click events on left mouse button click, touch contact, and pen
// contact. isMouseActionButton returns true in these cases (evt.button is set
// to 0).
// See http://www.w3.org/TR/pointerevents/#button-states
// We only fire click, singleclick, and doubleclick if nobody has called
// event.preventDefault().
if (this.emulateClicks_ &&
!newEvent.defaultPrevented &&
!this.dragging_ &&
this.isMouseActionButton_(pointerEvent)) {
this.emulateClick_(this.down_);
}
if (this.activePointers_.length === 0) {
this.dragListenerKeys_.forEach(unlistenByKey);
this.dragListenerKeys_.length = 0;
this.dragging_ = false;
this.down_ = null;
}
};
/**
* @param {PointerEvent} pointerEvent Pointer
* event.
* @return {boolean} If the left mouse button was pressed.
* @private
*/
MapBrowserEventHandler.prototype.isMouseActionButton_ = function (pointerEvent) {
return pointerEvent.button === 0;
};
/**
* @param {PointerEvent} pointerEvent Pointer
* event.
* @private
*/
MapBrowserEventHandler.prototype.handlePointerDown_ = function (pointerEvent) {
this.emulateClicks_ = this.activePointers_.length === 0;
this.updateActivePointers_(pointerEvent);
var newEvent = new MapBrowserEvent(MapBrowserEventType.POINTERDOWN, this.map_, pointerEvent, undefined, undefined, this.activePointers_);
this.dispatchEvent(newEvent);
// Store a copy of the down event
this.down_ = /** @type {PointerEvent} */ ({});
for (var property in pointerEvent) {
var value = pointerEvent[property];
this.down_[property] = typeof value === 'function' ? VOID : value;
}
if (this.dragListenerKeys_.length === 0) {
var doc = this.map_.getOwnerDocument();
this.dragListenerKeys_.push(listen(doc, MapBrowserEventType.POINTERMOVE, this.handlePointerMove_, this), listen(doc, MapBrowserEventType.POINTERUP, this.handlePointerUp_, this),
/* Note that the listener for `pointercancel is set up on
* `pointerEventHandler_` and not `documentPointerEventHandler_` like
* the `pointerup` and `pointermove` listeners.
*
* The reason for this is the following: `TouchSource.vacuumTouches_()`
* issues `pointercancel` events, when there was no `touchend` for a
* `touchstart`. Now, let's say a first `touchstart` is registered on
* `pointerEventHandler_`. The `documentPointerEventHandler_` is set up.
* But `documentPointerEventHandler_` doesn't know about the first
* `touchstart`. If there is no `touchend` for the `touchstart`, we can
* only receive a `touchcancel` from `pointerEventHandler_`, because it is
* only registered there.
*/
listen(this.element_, MapBrowserEventType.POINTERCANCEL, this.handlePointerUp_, this));
if (this.element_.getRootNode && this.element_.getRootNode() !== doc) {
this.dragListenerKeys_.push(listen(this.element_.getRootNode(), MapBrowserEventType.POINTERUP, this.handlePointerUp_, this));
}
}
};
/**
* @param {PointerEvent} pointerEvent Pointer
* event.
* @private
*/
MapBrowserEventHandler.prototype.handlePointerMove_ = function (pointerEvent) {
// Between pointerdown and pointerup, pointermove events are triggered.
// To avoid a 'false' touchmove event to be dispatched, we test if the pointer
// moved a significant distance.
if (this.isMoving_(pointerEvent)) {
this.updateActivePointers_(pointerEvent);
this.dragging_ = true;
var newEvent = new MapBrowserEvent(MapBrowserEventType.POINTERDRAG, this.map_, pointerEvent, this.dragging_, undefined, this.activePointers_);
this.dispatchEvent(newEvent);
}
};
/**
* Wrap and relay a pointermove event.
* @param {PointerEvent} pointerEvent Pointer
* event.
* @private
*/
MapBrowserEventHandler.prototype.relayMoveEvent_ = function (pointerEvent) {
this.originalPointerMoveEvent_ = pointerEvent;
var dragging = !!(this.down_ && this.isMoving_(pointerEvent));
this.dispatchEvent(new MapBrowserEvent(MapBrowserEventType.POINTERMOVE, this.map_, pointerEvent, dragging));
};
/**
* Flexible handling of a `touch-action: none` css equivalent: because calling
* `preventDefault()` on a `pointermove` event does not stop native page scrolling
* and zooming, we also listen for `touchmove` and call `preventDefault()` on it
* when an interaction (currently `DragPan` handles the event.
* @param {TouchEvent} event Event.
* @private
*/
MapBrowserEventHandler.prototype.handleTouchMove_ = function (event) {
// Due to https://github.com/mpizenberg/elm-pep/issues/2, `this.originalPointerMoveEvent_`
// may not be initialized yet when we get here on a platform without native pointer events.
var originalEvent = this.originalPointerMoveEvent_;
if ((!originalEvent || originalEvent.defaultPrevented) &&
(typeof event.cancelable !== 'boolean' || event.cancelable === true)) {
event.preventDefault();
}
};
/**
* @param {PointerEvent} pointerEvent Pointer
* event.
* @return {boolean} Is moving.
* @private
*/
MapBrowserEventHandler.prototype.isMoving_ = function (pointerEvent) {
return (this.dragging_ ||
Math.abs(pointerEvent.clientX - this.down_.clientX) >
this.moveTolerance_ ||
Math.abs(pointerEvent.clientY - this.down_.clientY) > this.moveTolerance_);
};
/**
* Clean up.
*/
MapBrowserEventHandler.prototype.disposeInternal = function () {
if (this.relayedListenerKey_) {
unlistenByKey(this.relayedListenerKey_);
this.relayedListenerKey_ = null;
}
this.element_.removeEventListener(EventType.TOUCHMOVE, this.boundHandleTouchMove_);
if (this.pointerdownListenerKey_) {
unlistenByKey(this.pointerdownListenerKey_);
this.pointerdownListenerKey_ = null;
}
this.dragListenerKeys_.forEach(unlistenByKey);
this.dragListenerKeys_.length = 0;
this.element_ = null;
_super.prototype.disposeInternal.call(this);
};
return MapBrowserEventHandler;
}(Target));
export default MapBrowserEventHandler;
//# sourceMappingURL=MapBrowserEventHandler.js.map

1
node_modules/ol/MapBrowserEventHandler.js.map generated vendored Normal file

File diff suppressed because one or more lines are too long

20
node_modules/ol/MapBrowserEventType.d.ts generated vendored Normal file
View File

@@ -0,0 +1,20 @@
declare namespace _default {
const SINGLECLICK: string;
const CLICK: string;
const DBLCLICK: string;
const POINTERDRAG: string;
const POINTERMOVE: string;
const POINTERDOWN: string;
const POINTERUP: string;
const POINTEROVER: string;
const POINTEROUT: string;
const POINTERENTER: string;
const POINTERLEAVE: string;
const POINTERCANCEL: string;
}
export default _default;
/**
* *
*/
export type Types = 'singleclick' | 'click' | 'dblclick' | 'pointerdrag' | 'pointermove';
//# sourceMappingURL=MapBrowserEventType.d.ts.map

1
node_modules/ol/MapBrowserEventType.d.ts.map generated vendored Normal file
View File

@@ -0,0 +1 @@
{"version":3,"file":"MapBrowserEventType.d.ts","sourceRoot":"","sources":["src/MapBrowserEventType.js"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;oBAyDa,aAAa,GAAC,OAAO,GAAC,UAAU,GAAC,aAAa,GAAC,aAAa"}

53
node_modules/ol/MapBrowserEventType.js generated vendored Normal file
View File

@@ -0,0 +1,53 @@
/**
* @module ol/MapBrowserEventType
*/
import EventType from './events/EventType.js';
/**
* Constants for event names.
* @enum {string}
*/
export default {
/**
* A true single click with no dragging and no double click. Note that this
* event is delayed by 250 ms to ensure that it is not a double click.
* @event module:ol/MapBrowserEvent~MapBrowserEvent#singleclick
* @api
*/
SINGLECLICK: 'singleclick',
/**
* A click with no dragging. A double click will fire two of this.
* @event module:ol/MapBrowserEvent~MapBrowserEvent#click
* @api
*/
CLICK: EventType.CLICK,
/**
* A true double click, with no dragging.
* @event module:ol/MapBrowserEvent~MapBrowserEvent#dblclick
* @api
*/
DBLCLICK: EventType.DBLCLICK,
/**
* Triggered when a pointer is dragged.
* @event module:ol/MapBrowserEvent~MapBrowserEvent#pointerdrag
* @api
*/
POINTERDRAG: 'pointerdrag',
/**
* Triggered when a pointer is moved. Note that on touch devices this is
* triggered when the map is panned, so is not the same as mousemove.
* @event module:ol/MapBrowserEvent~MapBrowserEvent#pointermove
* @api
*/
POINTERMOVE: 'pointermove',
POINTERDOWN: 'pointerdown',
POINTERUP: 'pointerup',
POINTEROVER: 'pointerover',
POINTEROUT: 'pointerout',
POINTERENTER: 'pointerenter',
POINTERLEAVE: 'pointerleave',
POINTERCANCEL: 'pointercancel',
};
/***
* @typedef {'singleclick'|'click'|'dblclick'|'pointerdrag'|'pointermove'} Types
*/
//# sourceMappingURL=MapBrowserEventType.js.map

1
node_modules/ol/MapBrowserEventType.js.map generated vendored Normal file
View File

@@ -0,0 +1 @@
{"version":3,"file":"MapBrowserEventType.js","sourceRoot":"","sources":["src/MapBrowserEventType.js"],"names":[],"mappings":"AAAA;;GAEG;AACH,OAAO,SAAS,MAAM,uBAAuB,CAAC;AAE9C;;;GAGG;AACH,eAAe;IACb;;;;;OAKG;IACH,WAAW,EAAE,aAAa;IAE1B;;;;OAIG;IACH,KAAK,EAAE,SAAS,CAAC,KAAK;IAEtB;;;;OAIG;IACH,QAAQ,EAAE,SAAS,CAAC,QAAQ;IAE5B;;;;OAIG;IACH,WAAW,EAAE,aAAa;IAE1B;;;;;OAKG;IACH,WAAW,EAAE,aAAa;IAE1B,WAAW,EAAE,aAAa;IAC1B,SAAS,EAAE,WAAW;IACtB,WAAW,EAAE,aAAa;IAC1B,UAAU,EAAE,YAAY;IACxB,YAAY,EAAE,cAAc;IAC5B,YAAY,EAAE,cAAc;IAC5B,aAAa,EAAE,eAAe;CAC/B,CAAC;AAEF;;GAEG"}

28
node_modules/ol/MapEvent.d.ts generated vendored Normal file
View File

@@ -0,0 +1,28 @@
export default MapEvent;
/**
* @classdesc
* Events emitted as map events are instances of this type.
* See {@link module:ol/PluggableMap~PluggableMap} for which events trigger a map event.
*/
declare class MapEvent extends Event {
/**
* @param {string} type Event type.
* @param {import("./PluggableMap.js").default} map Map.
* @param {?import("./PluggableMap.js").FrameState} [opt_frameState] Frame state.
*/
constructor(type: string, map: import("./PluggableMap.js").default, opt_frameState?: import("./PluggableMap.js").FrameState | null | undefined);
/**
* The map where the event occurred.
* @type {import("./PluggableMap.js").default}
* @api
*/
map: import("./PluggableMap.js").default;
/**
* The frame state at the time of the event.
* @type {?import("./PluggableMap.js").FrameState}
* @api
*/
frameState: import("./PluggableMap.js").FrameState | null;
}
import Event from "./events/Event.js";
//# sourceMappingURL=MapEvent.d.ts.map

1
node_modules/ol/MapEvent.d.ts.map generated vendored Normal file
View File

@@ -0,0 +1 @@
{"version":3,"file":"MapEvent.d.ts","sourceRoot":"","sources":["src/MapEvent.js"],"names":[],"mappings":";AAKA;;;;GAIG;AACH;IACE;;;;OAIG;IACH,kBAJW,MAAM,OACN,OAAO,mBAAmB,EAAE,OAAO,8EAmB7C;IAbC;;;;OAIG;IACH,KAHU,OAAO,mBAAmB,EAAE,OAAO,CAG/B;IAEd;;;;OAIG;IACH,YAHW,OAAO,mBAAmB,EAAE,UAAU,QAGqB;CAEzE"}

51
node_modules/ol/MapEvent.js generated vendored Normal file
View File

@@ -0,0 +1,51 @@
var __extends = (this && this.__extends) || (function () {
var extendStatics = function (d, b) {
extendStatics = Object.setPrototypeOf ||
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };
return extendStatics(d, b);
};
return function (d, b) {
if (typeof b !== "function" && b !== null)
throw new TypeError("Class extends value " + String(b) + " is not a constructor or null");
extendStatics(d, b);
function __() { this.constructor = d; }
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
};
})();
/**
* @module ol/MapEvent
*/
import Event from './events/Event.js';
/**
* @classdesc
* Events emitted as map events are instances of this type.
* See {@link module:ol/PluggableMap~PluggableMap} for which events trigger a map event.
*/
var MapEvent = /** @class */ (function (_super) {
__extends(MapEvent, _super);
/**
* @param {string} type Event type.
* @param {import("./PluggableMap.js").default} map Map.
* @param {?import("./PluggableMap.js").FrameState} [opt_frameState] Frame state.
*/
function MapEvent(type, map, opt_frameState) {
var _this = _super.call(this, type) || this;
/**
* The map where the event occurred.
* @type {import("./PluggableMap.js").default}
* @api
*/
_this.map = map;
/**
* The frame state at the time of the event.
* @type {?import("./PluggableMap.js").FrameState}
* @api
*/
_this.frameState = opt_frameState !== undefined ? opt_frameState : null;
return _this;
}
return MapEvent;
}(Event));
export default MapEvent;
//# sourceMappingURL=MapEvent.js.map

1
node_modules/ol/MapEvent.js.map generated vendored Normal file
View File

@@ -0,0 +1 @@
{"version":3,"file":"MapEvent.js","sourceRoot":"","sources":["src/MapEvent.js"],"names":[],"mappings":";;;;;;;;;;;;;;;AAAA;;GAEG;AACH,OAAO,KAAK,MAAM,mBAAmB,CAAC;AAEtC;;;;GAIG;AACH;IAAuB,4BAAK;IAC1B;;;;OAIG;IACH,kBAAY,IAAI,EAAE,GAAG,EAAE,cAAc;QAArC,YACE,kBAAM,IAAI,CAAC,SAeZ;QAbC;;;;WAIG;QACH,KAAI,CAAC,GAAG,GAAG,GAAG,CAAC;QAEf;;;;WAIG;QACH,KAAI,CAAC,UAAU,GAAG,cAAc,KAAK,SAAS,CAAC,CAAC,CAAC,cAAc,CAAC,CAAC,CAAC,IAAI,CAAC;;IACzE,CAAC;IACH,eAAC;AAAD,CAAC,AAvBD,CAAuB,KAAK,GAuB3B;AAED,eAAe,QAAQ,CAAC"}

13
node_modules/ol/MapEventType.d.ts generated vendored Normal file
View File

@@ -0,0 +1,13 @@
declare namespace _default {
const POSTRENDER: string;
const MOVESTART: string;
const MOVEEND: string;
const LOADSTART: string;
const LOADEND: string;
}
export default _default;
/**
* *
*/
export type Types = 'postrender' | 'movestart' | 'moveend' | 'loadstart' | 'loadend';
//# sourceMappingURL=MapEventType.d.ts.map

1
node_modules/ol/MapEventType.d.ts.map generated vendored Normal file
View File

@@ -0,0 +1 @@
{"version":3,"file":"MapEventType.d.ts","sourceRoot":"","sources":["src/MapEventType.js"],"names":[],"mappings":";;;;;;;;;;;oBA6Ca,YAAY,GAAC,WAAW,GAAC,SAAS,GAAC,WAAW,GAAC,SAAS"}

42
node_modules/ol/MapEventType.js generated vendored Normal file
View File

@@ -0,0 +1,42 @@
/**
* @module ol/MapEventType
*/
/**
* @enum {string}
*/
export default {
/**
* Triggered after a map frame is rendered.
* @event module:ol/MapEvent~MapEvent#postrender
* @api
*/
POSTRENDER: 'postrender',
/**
* Triggered when the map starts moving.
* @event module:ol/MapEvent~MapEvent#movestart
* @api
*/
MOVESTART: 'movestart',
/**
* Triggered after the map is moved.
* @event module:ol/MapEvent~MapEvent#moveend
* @api
*/
MOVEEND: 'moveend',
/**
* Triggered when loading of additional map data (tiles, images, features) starts.
* @event module:ol/MapEvent~MapEvent#loadstart
* @api
*/
LOADSTART: 'loadstart',
/**
* Triggered when loading of additional map data has completed.
* @event module:ol/MapEvent~MapEvent#loadend
* @api
*/
LOADEND: 'loadend',
};
/***
* @typedef {'postrender'|'movestart'|'moveend'|'loadstart'|'loadend'} Types
*/
//# sourceMappingURL=MapEventType.js.map

1
node_modules/ol/MapEventType.js.map generated vendored Normal file
View File

@@ -0,0 +1 @@
{"version":3,"file":"MapEventType.js","sourceRoot":"","sources":["src/MapEventType.js"],"names":[],"mappings":"AAAA;;GAEG;AAEH;;GAEG;AACH,eAAe;IACb;;;;OAIG;IACH,UAAU,EAAE,YAAY;IAExB;;;;OAIG;IACH,SAAS,EAAE,WAAW;IAEtB;;;;OAIG;IACH,OAAO,EAAE,SAAS;IAElB;;;;OAIG;IACH,SAAS,EAAE,WAAW;IAEtB;;;;OAIG;IACH,OAAO,EAAE,SAAS;CACnB,CAAC;AAEF;;GAEG"}

8
node_modules/ol/MapProperty.d.ts generated vendored Normal file
View File

@@ -0,0 +1,8 @@
declare namespace _default {
const LAYERGROUP: string;
const SIZE: string;
const TARGET: string;
const VIEW: string;
}
export default _default;
//# sourceMappingURL=MapProperty.d.ts.map

1
node_modules/ol/MapProperty.d.ts.map generated vendored Normal file
View File

@@ -0,0 +1 @@
{"version":3,"file":"MapProperty.d.ts","sourceRoot":"","sources":["src/MapProperty.js"],"names":[],"mappings":""}

13
node_modules/ol/MapProperty.js generated vendored Normal file
View File

@@ -0,0 +1,13 @@
/**
* @module ol/MapProperty
*/
/**
* @enum {string}
*/
export default {
LAYERGROUP: 'layergroup',
SIZE: 'size',
TARGET: 'target',
VIEW: 'view',
};
//# sourceMappingURL=MapProperty.js.map

1
node_modules/ol/MapProperty.js.map generated vendored Normal file
View File

@@ -0,0 +1 @@
{"version":3,"file":"MapProperty.js","sourceRoot":"","sources":["src/MapProperty.js"],"names":[],"mappings":"AAAA;;GAEG;AAEH;;GAEG;AACH,eAAe;IACb,UAAU,EAAE,YAAY;IACxB,IAAI,EAAE,MAAM;IACZ,MAAM,EAAE,QAAQ;IAChB,IAAI,EAAE,MAAM;CACb,CAAC"}

178
node_modules/ol/Object.d.ts generated vendored Normal file
View File

@@ -0,0 +1,178 @@
/**
* @classdesc
* Events emitted by {@link module:ol/Object~BaseObject} instances are instances of this type.
*/
export class ObjectEvent extends Event {
/**
* @param {string} type The event type.
* @param {string} key The property name.
* @param {*} oldValue The old value for `key`.
*/
constructor(type: string, key: string, oldValue: any);
/**
* The name of the property whose value is changing.
* @type {string}
* @api
*/
key: string;
/**
* The old value. To get the new value use `e.target.get(e.key)` where
* `e` is the event object.
* @type {*}
* @api
*/
oldValue: any;
}
export default BaseObject;
/**
* *
*/
export type ObjectOnSignature<Return> = import("./Observable").OnSignature<import("./Observable").EventTypes, import("./events/Event.js").default, Return> & import("./Observable").OnSignature<import("./ObjectEventType").Types, ObjectEvent, Return> & import("./Observable").CombinedOnSignature<import("./Observable").EventTypes | import("./ObjectEventType").Types, Return>;
import Event from "./events/Event.js";
/***
* @template Return
* @typedef {import("./Observable").OnSignature<import("./Observable").EventTypes, import("./events/Event.js").default, Return> &
* import("./Observable").OnSignature<import("./ObjectEventType").Types, ObjectEvent, Return> &
* import("./Observable").CombinedOnSignature<import("./Observable").EventTypes|import("./ObjectEventType").Types, Return>} ObjectOnSignature
*/
/**
* @classdesc
* Abstract base class; normally only used for creating subclasses and not
* instantiated in apps.
* Most non-trivial classes inherit from this.
*
* This extends {@link module:ol/Observable~Observable} with observable
* properties, where each property is observable as well as the object as a
* whole.
*
* Classes that inherit from this have pre-defined properties, to which you can
* add your owns. The pre-defined properties are listed in this documentation as
* 'Observable Properties', and have their own accessors; for example,
* {@link module:ol/Map~Map} has a `target` property, accessed with
* `getTarget()` and changed with `setTarget()`. Not all properties are however
* settable. There are also general-purpose accessors `get()` and `set()`. For
* example, `get('target')` is equivalent to `getTarget()`.
*
* The `set` accessors trigger a change event, and you can monitor this by
* registering a listener. For example, {@link module:ol/View~View} has a
* `center` property, so `view.on('change:center', function(evt) {...});` would
* call the function whenever the value of the center property changes. Within
* the function, `evt.target` would be the view, so `evt.target.getCenter()`
* would return the new center.
*
* You can add your own observable properties with
* `object.set('prop', 'value')`, and retrieve that with `object.get('prop')`.
* You can listen for changes on that property value with
* `object.on('change:prop', listener)`. You can get a list of all
* properties with {@link module:ol/Object~BaseObject#getProperties}.
*
* Note that the observable properties are separate from standard JS properties.
* You can, for example, give your map object a title with
* `map.title='New title'` and with `map.set('title', 'Another title')`. The
* first will be a `hasOwnProperty`; the second will appear in
* `getProperties()`. Only the second is observable.
*
* Properties can be deleted by using the unset method. E.g.
* object.unset('foo').
*
* @fires ObjectEvent
* @api
*/
declare class BaseObject extends Observable {
/**
* @param {Object<string, *>} [opt_values] An object with key-value pairs.
*/
constructor(opt_values?: {
[x: string]: any;
} | undefined);
/***
* @type {ObjectOnSignature<import("./events").EventsKey>}
*/
on: ObjectOnSignature<import("./events").EventsKey>;
/***
* @type {ObjectOnSignature<import("./events").EventsKey>}
*/
once: ObjectOnSignature<import("./events").EventsKey>;
/***
* @type {ObjectOnSignature<void>}
*/
un: ObjectOnSignature<void>;
/**
* @private
* @type {Object<string, *>}
*/
private values_;
/**
* Gets a value.
* @param {string} key Key name.
* @return {*} Value.
* @api
*/
get(key: string): any;
/**
* Get a list of object property names.
* @return {Array<string>} List of property names.
* @api
*/
getKeys(): Array<string>;
/**
* Get an object of all property names and values.
* @return {Object<string, *>} Object.
* @api
*/
getProperties(): {
[x: string]: any;
};
/**
* @return {boolean} The object has properties.
*/
hasProperties(): boolean;
/**
* @param {string} key Key name.
* @param {*} oldValue Old value.
*/
notify(key: string, oldValue: any): void;
/**
* @param {string} key Key name.
* @param {import("./events.js").Listener} listener Listener.
*/
addChangeListener(key: string, listener: import("./events.js").Listener): void;
/**
* @param {string} key Key name.
* @param {import("./events.js").Listener} listener Listener.
*/
removeChangeListener(key: string, listener: import("./events.js").Listener): void;
/**
* Sets a value.
* @param {string} key Key name.
* @param {*} value Value.
* @param {boolean} [opt_silent] Update without triggering an event.
* @api
*/
set(key: string, value: any, opt_silent?: boolean | undefined): void;
/**
* Sets a collection of key-value pairs. Note that this changes any existing
* properties and adds new ones (it does not remove any existing properties).
* @param {Object<string, *>} values Values.
* @param {boolean} [opt_silent] Update without triggering an event.
* @api
*/
setProperties(values: {
[x: string]: any;
}, opt_silent?: boolean | undefined): void;
/**
* Apply any properties from another object without triggering events.
* @param {BaseObject} source The source object.
* @protected
*/
protected applyProperties(source: BaseObject): void;
/**
* Unsets a property.
* @param {string} key Key name.
* @param {boolean} [opt_silent] Unset without triggering an event.
* @api
*/
unset(key: string, opt_silent?: boolean | undefined): void;
}
import Observable from "./Observable.js";
//# sourceMappingURL=Object.d.ts.map

1
node_modules/ol/Object.d.ts.map generated vendored Normal file
View File

@@ -0,0 +1 @@
{"version":3,"file":"Object.d.ts","sourceRoot":"","sources":["src/Object.js"],"names":[],"mappings":"AASA;;;GAGG;AACH;IACE;;;;OAIG;IACH,kBAJW,MAAM,OACN,MAAM,iBAoBhB;IAdC;;;;OAIG;IACH,KAHU,MAAM,CAGF;IAEd;;;;;OAKG;IACH,cAAwB;CAE3B;;;;;wCAIY,OAAO,cAAc,EAAE,WAAW,CAAC,OAAO,cAAc,EAAE,UAAU,EAAE,OAAO,mBAAmB,EAAE,OAAO,EAAE,MAAM,CAAC,GAC9H,OAAY,cAAc,EAAE,WAAW,CAAC,OAAO,mBAAmB,EAAE,KAAK,EAAE,WAAW,EAAE,MAAM,CAAC,GAC/F,OAAY,cAAc,EAAE,mBAAmB,CAAC,OAAO,cAAc,EAAE,UAAU,GAAC,OAAO,mBAAmB,EAAE,KAAK,EAAE,MAAM,CAAC;;AAJ7H;;;;;GAKG;AAEH;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA0CG;AACH;IACE;;OAEG;IACH;;mBAiCC;IA9BC;;OAEG;IACH,IAFU,kBAAkB,OAAO,UAAU,EAAE,SAAS,CAAC,CAElD;IAEP;;OAEG;IACH,MAFU,kBAAkB,OAAO,UAAU,EAAE,SAAS,CAAC,CAEhD;IAET;;OAEG;IACH,IAFU,kBAAkB,IAAI,CAAC,CAE1B;IAQP;;;OAGG;IACH,gBAAmB;IAOrB;;;;;OAKG;IACH,SAJW,MAAM,OAUhB;IAED;;;;OAIG;IACH,WAHY,MAAM,MAAM,CAAC,CAKxB;IAED;;;;OAIG;IACH;YAHmB,MAAM;MAKxB;IAED;;OAEG;IACH,iBAFY,OAAO,CAIlB;IAED;;;OAGG;IACH,YAHW,MAAM,uBAahB;IAED;;;OAGG;IACH,uBAHW,MAAM,YACN,OAAO,aAAa,EAAE,QAAQ,QAIxC;IAED;;;OAGG;IACH,0BAHW,MAAM,YACN,OAAO,aAAa,EAAE,QAAQ,QAIxC;IAED;;;;;;OAMG;IACH,SALW,MAAM,sDAgBhB;IAED;;;;;;OAMG;IACH;YAJkB,MAAM;+CAQvB;IAED;;;;OAIG;IACH,kCAHW,UAAU,QAQpB;IAED;;;;;OAKG;IACH,WAJW,MAAM,0CAehB;CACF"}

266
node_modules/ol/Object.js generated vendored Normal file
View File

@@ -0,0 +1,266 @@
var __extends = (this && this.__extends) || (function () {
var extendStatics = function (d, b) {
extendStatics = Object.setPrototypeOf ||
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };
return extendStatics(d, b);
};
return function (d, b) {
if (typeof b !== "function" && b !== null)
throw new TypeError("Class extends value " + String(b) + " is not a constructor or null");
extendStatics(d, b);
function __() { this.constructor = d; }
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
};
})();
/**
* @module ol/Object
*/
import Event from './events/Event.js';
import ObjectEventType from './ObjectEventType.js';
import Observable from './Observable.js';
import { assign, isEmpty } from './obj.js';
import { getUid } from './util.js';
/**
* @classdesc
* Events emitted by {@link module:ol/Object~BaseObject} instances are instances of this type.
*/
var ObjectEvent = /** @class */ (function (_super) {
__extends(ObjectEvent, _super);
/**
* @param {string} type The event type.
* @param {string} key The property name.
* @param {*} oldValue The old value for `key`.
*/
function ObjectEvent(type, key, oldValue) {
var _this = _super.call(this, type) || this;
/**
* The name of the property whose value is changing.
* @type {string}
* @api
*/
_this.key = key;
/**
* The old value. To get the new value use `e.target.get(e.key)` where
* `e` is the event object.
* @type {*}
* @api
*/
_this.oldValue = oldValue;
return _this;
}
return ObjectEvent;
}(Event));
export { ObjectEvent };
/***
* @template Return
* @typedef {import("./Observable").OnSignature<import("./Observable").EventTypes, import("./events/Event.js").default, Return> &
* import("./Observable").OnSignature<import("./ObjectEventType").Types, ObjectEvent, Return> &
* import("./Observable").CombinedOnSignature<import("./Observable").EventTypes|import("./ObjectEventType").Types, Return>} ObjectOnSignature
*/
/**
* @classdesc
* Abstract base class; normally only used for creating subclasses and not
* instantiated in apps.
* Most non-trivial classes inherit from this.
*
* This extends {@link module:ol/Observable~Observable} with observable
* properties, where each property is observable as well as the object as a
* whole.
*
* Classes that inherit from this have pre-defined properties, to which you can
* add your owns. The pre-defined properties are listed in this documentation as
* 'Observable Properties', and have their own accessors; for example,
* {@link module:ol/Map~Map} has a `target` property, accessed with
* `getTarget()` and changed with `setTarget()`. Not all properties are however
* settable. There are also general-purpose accessors `get()` and `set()`. For
* example, `get('target')` is equivalent to `getTarget()`.
*
* The `set` accessors trigger a change event, and you can monitor this by
* registering a listener. For example, {@link module:ol/View~View} has a
* `center` property, so `view.on('change:center', function(evt) {...});` would
* call the function whenever the value of the center property changes. Within
* the function, `evt.target` would be the view, so `evt.target.getCenter()`
* would return the new center.
*
* You can add your own observable properties with
* `object.set('prop', 'value')`, and retrieve that with `object.get('prop')`.
* You can listen for changes on that property value with
* `object.on('change:prop', listener)`. You can get a list of all
* properties with {@link module:ol/Object~BaseObject#getProperties}.
*
* Note that the observable properties are separate from standard JS properties.
* You can, for example, give your map object a title with
* `map.title='New title'` and with `map.set('title', 'Another title')`. The
* first will be a `hasOwnProperty`; the second will appear in
* `getProperties()`. Only the second is observable.
*
* Properties can be deleted by using the unset method. E.g.
* object.unset('foo').
*
* @fires ObjectEvent
* @api
*/
var BaseObject = /** @class */ (function (_super) {
__extends(BaseObject, _super);
/**
* @param {Object<string, *>} [opt_values] An object with key-value pairs.
*/
function BaseObject(opt_values) {
var _this = _super.call(this) || this;
/***
* @type {ObjectOnSignature<import("./events").EventsKey>}
*/
_this.on;
/***
* @type {ObjectOnSignature<import("./events").EventsKey>}
*/
_this.once;
/***
* @type {ObjectOnSignature<void>}
*/
_this.un;
// Call {@link module:ol/util.getUid} to ensure that the order of objects' ids is
// the same as the order in which they were created. This also helps to
// ensure that object properties are always added in the same order, which
// helps many JavaScript engines generate faster code.
getUid(_this);
/**
* @private
* @type {Object<string, *>}
*/
_this.values_ = null;
if (opt_values !== undefined) {
_this.setProperties(opt_values);
}
return _this;
}
/**
* Gets a value.
* @param {string} key Key name.
* @return {*} Value.
* @api
*/
BaseObject.prototype.get = function (key) {
var value;
if (this.values_ && this.values_.hasOwnProperty(key)) {
value = this.values_[key];
}
return value;
};
/**
* Get a list of object property names.
* @return {Array<string>} List of property names.
* @api
*/
BaseObject.prototype.getKeys = function () {
return (this.values_ && Object.keys(this.values_)) || [];
};
/**
* Get an object of all property names and values.
* @return {Object<string, *>} Object.
* @api
*/
BaseObject.prototype.getProperties = function () {
return (this.values_ && assign({}, this.values_)) || {};
};
/**
* @return {boolean} The object has properties.
*/
BaseObject.prototype.hasProperties = function () {
return !!this.values_;
};
/**
* @param {string} key Key name.
* @param {*} oldValue Old value.
*/
BaseObject.prototype.notify = function (key, oldValue) {
var eventType;
eventType = "change:".concat(key);
if (this.hasListener(eventType)) {
this.dispatchEvent(new ObjectEvent(eventType, key, oldValue));
}
eventType = ObjectEventType.PROPERTYCHANGE;
if (this.hasListener(eventType)) {
this.dispatchEvent(new ObjectEvent(eventType, key, oldValue));
}
};
/**
* @param {string} key Key name.
* @param {import("./events.js").Listener} listener Listener.
*/
BaseObject.prototype.addChangeListener = function (key, listener) {
this.addEventListener("change:".concat(key), listener);
};
/**
* @param {string} key Key name.
* @param {import("./events.js").Listener} listener Listener.
*/
BaseObject.prototype.removeChangeListener = function (key, listener) {
this.removeEventListener("change:".concat(key), listener);
};
/**
* Sets a value.
* @param {string} key Key name.
* @param {*} value Value.
* @param {boolean} [opt_silent] Update without triggering an event.
* @api
*/
BaseObject.prototype.set = function (key, value, opt_silent) {
var values = this.values_ || (this.values_ = {});
if (opt_silent) {
values[key] = value;
}
else {
var oldValue = values[key];
values[key] = value;
if (oldValue !== value) {
this.notify(key, oldValue);
}
}
};
/**
* Sets a collection of key-value pairs. Note that this changes any existing
* properties and adds new ones (it does not remove any existing properties).
* @param {Object<string, *>} values Values.
* @param {boolean} [opt_silent] Update without triggering an event.
* @api
*/
BaseObject.prototype.setProperties = function (values, opt_silent) {
for (var key in values) {
this.set(key, values[key], opt_silent);
}
};
/**
* Apply any properties from another object without triggering events.
* @param {BaseObject} source The source object.
* @protected
*/
BaseObject.prototype.applyProperties = function (source) {
if (!source.values_) {
return;
}
assign(this.values_ || (this.values_ = {}), source.values_);
};
/**
* Unsets a property.
* @param {string} key Key name.
* @param {boolean} [opt_silent] Unset without triggering an event.
* @api
*/
BaseObject.prototype.unset = function (key, opt_silent) {
if (this.values_ && key in this.values_) {
var oldValue = this.values_[key];
delete this.values_[key];
if (isEmpty(this.values_)) {
this.values_ = null;
}
if (!opt_silent) {
this.notify(key, oldValue);
}
}
};
return BaseObject;
}(Observable));
export default BaseObject;
//# sourceMappingURL=Object.js.map

1
node_modules/ol/Object.js.map generated vendored Normal file
View File

@@ -0,0 +1 @@
{"version":3,"file":"Object.js","sourceRoot":"","sources":["src/Object.js"],"names":[],"mappings":";;;;;;;;;;;;;;;AAAA;;GAEG;AACH,OAAO,KAAK,MAAM,mBAAmB,CAAC;AACtC,OAAO,eAAe,MAAM,sBAAsB,CAAC;AACnD,OAAO,UAAU,MAAM,iBAAiB,CAAC;AACzC,OAAO,EAAC,MAAM,EAAE,OAAO,EAAC,MAAM,UAAU,CAAC;AACzC,OAAO,EAAC,MAAM,EAAC,MAAM,WAAW,CAAC;AAEjC;;;GAGG;AACH;IAAiC,+BAAK;IACpC;;;;OAIG;IACH,qBAAY,IAAI,EAAE,GAAG,EAAE,QAAQ;QAA/B,YACE,kBAAM,IAAI,CAAC,SAgBZ;QAdC;;;;WAIG;QACH,KAAI,CAAC,GAAG,GAAG,GAAG,CAAC;QAEf;;;;;WAKG;QACH,KAAI,CAAC,QAAQ,GAAG,QAAQ,CAAC;;IAC3B,CAAC;IACH,kBAAC;AAAD,CAAC,AAxBD,CAAiC,KAAK,GAwBrC;;AAED;;;;;G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ED;;;;;;OAMG;IACH,kCAAa,GAAb,UAAc,MAAM,EAAE,UAAU;QAC9B,KAAK,IAAM,GAAG,IAAI,MAAM,EAAE;YACxB,IAAI,CAAC,GAAG,CAAC,GAAG,EAAE,MAAM,CAAC,GAAG,CAAC,EAAE,UAAU,CAAC,CAAC;SACxC;IACH,CAAC;IAED;;;;OAIG;IACH,oCAAe,GAAf,UAAgB,MAAM;QACpB,IAAI,CAAC,MAAM,CAAC,OAAO,EAAE;YACnB,OAAO;SACR;QACD,MAAM,CAAC,IAAI,CAAC,OAAO,IAAI,CAAC,IAAI,CAAC,OAAO,GAAG,EAAE,CAAC,EAAE,MAAM,CAAC,OAAO,CAAC,CAAC;IAC9D,CAAC;IAED;;;;;OAKG;IACH,0BAAK,GAAL,UAAM,GAAG,EAAE,UAAU;QACnB,IAAI,IAAI,CAAC,OAAO,IAAI,GAAG,IAAI,IAAI,CAAC,OAAO,EAAE;YACvC,IAAM,QAAQ,GAAG,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,CAAC;YACnC,OAAO,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,CAAC;YACzB,IAAI,OAAO,CAAC,IAAI,CAAC,OAAO,CAAC,EAAE;gBACzB,IAAI,CAAC,OAAO,GAAG,IAAI,CAAC;aACrB;YACD,IAAI,CAAC,UAAU,EAAE;gBACf,IAAI,CAAC,MAAM,CAAC,GAAG,EAAE,QAAQ,CAAC,CAAC;aAC5B;SACF;IACH,CAAC;IACH,iBAAC;AAAD,CAAC,AA7KD,CAAyB,UAAU,GA6KlC;AAED,eAAe,UAAU,CAAC"}

6
node_modules/ol/ObjectEventType.d.ts generated vendored Normal file
View File

@@ -0,0 +1,6 @@
declare namespace _default {
const PROPERTYCHANGE: string;
}
export default _default;
export type Types = 'propertychange';
//# sourceMappingURL=ObjectEventType.d.ts.map

1
node_modules/ol/ObjectEventType.d.ts.map generated vendored Normal file
View File

@@ -0,0 +1 @@
{"version":3,"file":"ObjectEventType.d.ts","sourceRoot":"","sources":["src/ObjectEventType.js"],"names":[],"mappings":";;;;oBAiBa,gBAAgB"}

18
node_modules/ol/ObjectEventType.js generated vendored Normal file
View File

@@ -0,0 +1,18 @@
/**
* @module ol/ObjectEventType
*/
/**
* @enum {string}
*/
export default {
/**
* Triggered when a property is changed.
* @event module:ol/Object.ObjectEvent#propertychange
* @api
*/
PROPERTYCHANGE: 'propertychange',
};
/**
* @typedef {'propertychange'} Types
*/
//# sourceMappingURL=ObjectEventType.js.map

1
node_modules/ol/ObjectEventType.js.map generated vendored Normal file
View File

@@ -0,0 +1 @@
{"version":3,"file":"ObjectEventType.js","sourceRoot":"","sources":["src/ObjectEventType.js"],"names":[],"mappings":"AAAA;;GAEG;AAEH;;GAEG;AACH,eAAe;IACb;;;;OAIG;IACH,cAAc,EAAE,gBAAgB;CACjC,CAAC;AAEF;;GAEG"}

96
node_modules/ol/Observable.d.ts generated vendored Normal file
View File

@@ -0,0 +1,96 @@
/**
* Removes an event listener using the key returned by `on()` or `once()`.
* @param {import("./events.js").EventsKey|Array<import("./events.js").EventsKey>} key The key returned by `on()`
* or `once()` (or an array of keys).
* @api
*/
export function unByKey(key: import("./events.js").EventsKey | Array<import("./events.js").EventsKey>): void;
export default Observable;
/**
* *
*/
export type OnSignature<Type extends string, EventClass extends import("./events/Event.js").default | Event, Return> = (type: Type, listener: (event: EventClass) => unknown) => Return;
/**
* *
*/
export type CombinedOnSignature<Type extends string, Return> = (type: Type[], listener: (event: Event | import("./events/Event").default) => unknown) => Return extends void ? void : Return[];
export type EventTypes = 'change' | 'error';
/**
* *
*/
export type ObservableOnSignature<Return> = OnSignature<EventTypes, import("./events/Event.js").default, Return> & CombinedOnSignature<EventTypes, Return>;
/***
* @template {string} Type
* @template {Event|import("./events/Event.js").default} EventClass
* @template Return
* @typedef {(type: Type, listener: (event: EventClass) => ?) => Return} OnSignature
*/
/***
* @template {string} Type
* @template Return
* @typedef {(type: Type[], listener: (event: Event|import("./events/Event").default) => ?) => Return extends void ? void : Return[]} CombinedOnSignature
*/
/**
* @typedef {'change'|'error'} EventTypes
*/
/***
* @template Return
* @typedef {OnSignature<EventTypes, import("./events/Event.js").default, Return> & CombinedOnSignature<EventTypes, Return>} ObservableOnSignature
*/
/**
* @classdesc
* Abstract base class; normally only used for creating subclasses and not
* instantiated in apps.
* An event target providing convenient methods for listener registration
* and unregistration. A generic `change` event is always available through
* {@link module:ol/Observable~Observable#changed}.
*
* @fires import("./events/Event.js").default
* @api
*/
declare class Observable extends EventTarget {
constructor();
on: ObservableOnSignature<import("./events.js").EventsKey>;
once: ObservableOnSignature<import("./events.js").EventsKey>;
un: ObservableOnSignature<void>;
/**
* @private
* @type {number}
*/
private revision_;
/**
* Increases the revision counter and dispatches a 'change' event.
* @api
*/
changed(): void;
/**
* Get the version number for this object. Each time the object is modified,
* its version number will be incremented.
* @return {number} Revision.
* @api
*/
getRevision(): number;
/**
* @param {string|Array<string>} type Type.
* @param {function((Event|import("./events/Event").default)): ?} listener Listener.
* @return {import("./events.js").EventsKey|Array<import("./events.js").EventsKey>} Event key.
* @protected
*/
protected onInternal(type: string | Array<string>, listener: (arg0: (Event | import("./events/Event").default)) => unknown): import("./events.js").EventsKey | Array<import("./events.js").EventsKey>;
/**
* @param {string|Array<string>} type Type.
* @param {function((Event|import("./events/Event").default)): ?} listener Listener.
* @return {import("./events.js").EventsKey|Array<import("./events.js").EventsKey>} Event key.
* @protected
*/
protected onceInternal(type: string | Array<string>, listener: (arg0: (Event | import("./events/Event").default)) => unknown): import("./events.js").EventsKey | Array<import("./events.js").EventsKey>;
/**
* Unlisten for a certain type of event.
* @param {string|Array<string>} type Type.
* @param {function((Event|import("./events/Event").default)): ?} listener Listener.
* @protected
*/
protected unInternal(type: string | Array<string>, listener: (arg0: (Event | import("./events/Event").default)) => unknown): void;
}
import EventTarget from "./events/Target.js";
//# sourceMappingURL=Observable.d.ts.map

1
node_modules/ol/Observable.d.ts.map generated vendored Normal file
View File

@@ -0,0 +1 @@
{"version":3,"file":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modules/ol/Observable.js generated vendored Normal file
View File

@@ -0,0 +1,193 @@
var __extends = (this && this.__extends) || (function () {
var extendStatics = function (d, b) {
extendStatics = Object.setPrototypeOf ||
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };
return extendStatics(d, b);
};
return function (d, b) {
if (typeof b !== "function" && b !== null)
throw new TypeError("Class extends value " + String(b) + " is not a constructor or null");
extendStatics(d, b);
function __() { this.constructor = d; }
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
};
})();
/**
* @module ol/Observable
*/
import EventTarget from './events/Target.js';
import EventType from './events/EventType.js';
import { listen, listenOnce, unlistenByKey } from './events.js';
/***
* @template {string} Type
* @template {Event|import("./events/Event.js").default} EventClass
* @template Return
* @typedef {(type: Type, listener: (event: EventClass) => ?) => Return} OnSignature
*/
/***
* @template {string} Type
* @template Return
* @typedef {(type: Type[], listener: (event: Event|import("./events/Event").default) => ?) => Return extends void ? void : Return[]} CombinedOnSignature
*/
/**
* @typedef {'change'|'error'} EventTypes
*/
/***
* @template Return
* @typedef {OnSignature<EventTypes, import("./events/Event.js").default, Return> & CombinedOnSignature<EventTypes, Return>} ObservableOnSignature
*/
/**
* @classdesc
* Abstract base class; normally only used for creating subclasses and not
* instantiated in apps.
* An event target providing convenient methods for listener registration
* and unregistration. A generic `change` event is always available through
* {@link module:ol/Observable~Observable#changed}.
*
* @fires import("./events/Event.js").default
* @api
*/
var Observable = /** @class */ (function (_super) {
__extends(Observable, _super);
function Observable() {
var _this = _super.call(this) || this;
_this.on =
/** @type {ObservableOnSignature<import("./events").EventsKey>} */ (_this.onInternal);
_this.once =
/** @type {ObservableOnSignature<import("./events").EventsKey>} */ (_this.onceInternal);
_this.un = /** @type {ObservableOnSignature<void>} */ (_this.unInternal);
/**
* @private
* @type {number}
*/
_this.revision_ = 0;
return _this;
}
/**
* Increases the revision counter and dispatches a 'change' event.
* @api
*/
Observable.prototype.changed = function () {
++this.revision_;
this.dispatchEvent(EventType.CHANGE);
};
/**
* Get the version number for this object. Each time the object is modified,
* its version number will be incremented.
* @return {number} Revision.
* @api
*/
Observable.prototype.getRevision = function () {
return this.revision_;
};
/**
* @param {string|Array<string>} type Type.
* @param {function((Event|import("./events/Event").default)): ?} listener Listener.
* @return {import("./events.js").EventsKey|Array<import("./events.js").EventsKey>} Event key.
* @protected
*/
Observable.prototype.onInternal = function (type, listener) {
if (Array.isArray(type)) {
var len = type.length;
var keys = new Array(len);
for (var i = 0; i < len; ++i) {
keys[i] = listen(this, type[i], listener);
}
return keys;
}
else {
return listen(this, /** @type {string} */ (type), listener);
}
};
/**
* @param {string|Array<string>} type Type.
* @param {function((Event|import("./events/Event").default)): ?} listener Listener.
* @return {import("./events.js").EventsKey|Array<import("./events.js").EventsKey>} Event key.
* @protected
*/
Observable.prototype.onceInternal = function (type, listener) {
var key;
if (Array.isArray(type)) {
var len = type.length;
key = new Array(len);
for (var i = 0; i < len; ++i) {
key[i] = listenOnce(this, type[i], listener);
}
}
else {
key = listenOnce(this, /** @type {string} */ (type), listener);
}
/** @type {Object} */ (listener).ol_key = key;
return key;
};
/**
* Unlisten for a certain type of event.
* @param {string|Array<string>} type Type.
* @param {function((Event|import("./events/Event").default)): ?} listener Listener.
* @protected
*/
Observable.prototype.unInternal = function (type, listener) {
var key = /** @type {Object} */ (listener).ol_key;
if (key) {
unByKey(key);
}
else if (Array.isArray(type)) {
for (var i = 0, ii = type.length; i < ii; ++i) {
this.removeEventListener(type[i], listener);
}
}
else {
this.removeEventListener(type, listener);
}
};
return Observable;
}(EventTarget));
/**
* Listen for a certain type of event.
* @function
* @param {string|Array<string>} type The event type or array of event types.
* @param {function((Event|import("./events/Event").default)): ?} listener The listener function.
* @return {import("./events.js").EventsKey|Array<import("./events.js").EventsKey>} Unique key for the listener. If
* called with an array of event types as the first argument, the return
* will be an array of keys.
* @api
*/
Observable.prototype.on;
/**
* Listen once for a certain type of event.
* @function
* @param {string|Array<string>} type The event type or array of event types.
* @param {function((Event|import("./events/Event").default)): ?} listener The listener function.
* @return {import("./events.js").EventsKey|Array<import("./events.js").EventsKey>} Unique key for the listener. If
* called with an array of event types as the first argument, the return
* will be an array of keys.
* @api
*/
Observable.prototype.once;
/**
* Unlisten for a certain type of event.
* @function
* @param {string|Array<string>} type The event type or array of event types.
* @param {function((Event|import("./events/Event").default)): ?} listener The listener function.
* @api
*/
Observable.prototype.un;
/**
* Removes an event listener using the key returned by `on()` or `once()`.
* @param {import("./events.js").EventsKey|Array<import("./events.js").EventsKey>} key The key returned by `on()`
* or `once()` (or an array of keys).
* @api
*/
export function unByKey(key) {
if (Array.isArray(key)) {
for (var i = 0, ii = key.length; i < ii; ++i) {
unlistenByKey(key[i]);
}
}
else {
unlistenByKey(/** @type {import("./events.js").EventsKey} */ (key));
}
}
export default Observable;
//# sourceMappingURL=Observable.js.map

1
node_modules/ol/Observable.js.map generated vendored Normal file
View File

@@ -0,0 +1 @@
{"version":3,"file":"Observable.js","sourceRoot":"","sources":["src/Observable.js"],"names":[],"mappings":";;;;;;;;;;;;;;;AAAA;;GAEG;AACH,OAAO,WAAW,MAAM,oBAAoB,CAAC;AAC7C,OAAO,SAAS,MAAM,uBAAuB,CAAC;AAC9C,OAAO,EAAC,MAAM,EAAE,UAAU,EAAE,aAAa,EAAC,MAAM,aAAa,CAAC;AAE9D;;;;;GAKG;AAEH;;;;GAIG;AAEH;;GAEG;AAEH;;;GAGG;AAEH;;;;;;;;;;GAUG;AACH;IAAyB,8BAAW;IAClC;QAAA,YACE,iBAAO,SAmBR;QAjBC,KAAI,CAAC,EAAE;YACL,kEAAkE,CAAC,CACjE,KAAI,CAAC,UAAU,CAChB,CAAC;QAEJ,KAAI,CAAC,IAAI;YACP,kEAAkE,CAAC,CACjE,KAAI,CAAC,YAAY,CAClB,CAAC;QAEJ,KAAI,CAAC,EAAE,GAAG,0CAA0C,CAAC,CAAC,KAAI,CAAC,UA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CAAC,EAAE,EAAE,GAAG,GAAG,CAAC,MAAM,EAAE,CAAC,GAAG,EAAE,EAAE,EAAE,CAAC,EAAE;YAC5C,aAAa,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,CAAC;SACvB;KACF;SAAM;QACL,aAAa,CAAC,8CAA8C,CAAC,CAAC,GAAG,CAAC,CAAC,CAAC;KACrE;AACH,CAAC;AAED,eAAe,UAAU,CAAC"}

360
node_modules/ol/Overlay.d.ts generated vendored Normal file
View File

@@ -0,0 +1,360 @@
export default Overlay;
/**
* The overlay position: `'bottom-left'`, `'bottom-center'`, `'bottom-right'`,
* `'center-left'`, `'center-center'`, `'center-right'`, `'top-left'`,
* `'top-center'`, or `'top-right'`.
*/
export type Positioning = 'bottom-left' | 'bottom-center' | 'bottom-right' | 'center-left' | 'center-center' | 'center-right' | 'top-left' | 'top-center' | 'top-right';
export type Options = {
/**
* Set the overlay id. The overlay id can be used
* with the {@link module :ol/Map~Map#getOverlayById} method.
*/
id?: string | number | undefined;
/**
* The overlay element.
*/
element?: HTMLElement | undefined;
/**
* Offsets in pixels used when positioning
* the overlay. The first element in the
* array is the horizontal offset. A positive value shifts the overlay right.
* The second element in the array is the vertical offset. A positive value
* shifts the overlay down.
*/
offset?: number[] | undefined;
/**
* The overlay position
* in map projection.
*/
position?: import("./coordinate.js").Coordinate | undefined;
/**
* Defines how
* the overlay is actually positioned with respect to its `position` property.
* Possible values are `'bottom-left'`, `'bottom-center'`, `'bottom-right'`,
* `'center-left'`, `'center-center'`, `'center-right'`, `'top-left'`,
* `'top-center'`, and `'top-right'`.
*/
positioning?: Positioning | undefined;
/**
* Whether event propagation to the map
* viewport should be stopped. If `true` the overlay is placed in the same
* container as that of the controls (CSS class name
* `ol-overlaycontainer-stopevent`); if `false` it is placed in the container
* with CSS class name specified by the `className` property.
*/
stopEvent?: boolean | undefined;
/**
* Whether the overlay is inserted first
* in the overlay container, or appended. If the overlay is placed in the same
* container as that of the controls (see the `stopEvent` option) you will
* probably set `insertFirst` to `true` so the overlay is displayed below the
* controls.
*/
insertFirst?: boolean | undefined;
/**
* Pan the map when calling
* `setPosition`, so that the overlay is entirely visible in the current viewport?
* If `true` (deprecated), then `autoPanAnimation` and `autoPanMargin` will be
* used to determine the panning parameters; if an object is supplied then other
* parameters are ignored.
*/
autoPan?: boolean | PanIntoViewOptions | undefined;
/**
* The animation options used to pan
* the overlay into view. This animation is only used when `autoPan` is enabled.
* A `duration` and `easing` may be provided to customize the animation.
* Deprecated and ignored if `autoPan` is supplied as an object.
*/
autoPanAnimation?: PanOptions | undefined;
/**
* The margin (in pixels) between the
* overlay and the borders of the map when autopanning. Deprecated and ignored
* if `autoPan` is supplied as an object.
*/
autoPanMargin?: number | undefined;
/**
* The options to use for the
* autoPan. This is only used when `autoPan` is enabled and has preference over
* the individual `autoPanMargin` and `autoPanOptions`.
*/
autoPanOptions?: PanIntoViewOptions | undefined;
/**
* CSS class
* name.
*/
className?: string | undefined;
};
export type PanOptions = {
/**
* The duration of the animation in
* milliseconds.
*/
duration?: number | undefined;
/**
* The easing function to use. Can
* be one from {@link module :ol/easing} or a custom function.
* Default is {@link module :ol/easing.inAndOut}.
*/
easing?: ((arg0: number) => number) | undefined;
};
export type PanIntoViewOptions = {
/**
* The animation parameters for the pan
*/
animation?: PanOptions | undefined;
/**
* The margin (in pixels) between the
* overlay and the borders of the map when panning into view.
*/
margin?: number | undefined;
};
export type OverlayObjectEventTypes = import("./ObjectEventType").Types | 'change:element' | 'change:map' | 'change:offset' | 'change:position' | 'change:positioning';
/**
* *
*/
export type OverlayOnSignature<Return> = import("./Observable").OnSignature<import("./Observable").EventTypes, import("./events/Event.js").default, Return> & import("./Observable").OnSignature<OverlayObjectEventTypes, import("./Object").ObjectEvent, Return> & import("./Observable").CombinedOnSignature<import("./Observable").EventTypes | OverlayObjectEventTypes, Return>;
/**
* @typedef {import("./ObjectEventType").Types|'change:element'|'change:map'|'change:offset'|'change:position'|
* 'change:positioning'} OverlayObjectEventTypes
*/
/***
* @template Return
* @typedef {import("./Observable").OnSignature<import("./Observable").EventTypes, import("./events/Event.js").default, Return> &
* import("./Observable").OnSignature<OverlayObjectEventTypes, import("./Object").ObjectEvent, Return> &
* import("./Observable").CombinedOnSignature<import("./Observable").EventTypes|OverlayObjectEventTypes, Return>} OverlayOnSignature
*/
/**
* @classdesc
* An element to be displayed over the map and attached to a single map
* location. Like {@link module:ol/control/Control~Control}, Overlays are
* visible widgets. Unlike Controls, they are not in a fixed position on the
* screen, but are tied to a geographical coordinate, so panning the map will
* move an Overlay but not a Control.
*
* Example:
*
* import Overlay from 'ol/Overlay';
*
* var popup = new Overlay({
* element: document.getElementById('popup')
* });
* popup.setPosition(coordinate);
* map.addOverlay(popup);
*
* @api
*/
declare class Overlay extends BaseObject {
/**
* @param {Options} options Overlay options.
*/
constructor(options: Options);
/***
* @type {OverlayOnSignature<import("./events").EventsKey>}
*/
on: OverlayOnSignature<import("./events").EventsKey>;
/***
* @type {OverlayOnSignature<import("./events").EventsKey>}
*/
once: OverlayOnSignature<import("./events").EventsKey>;
/***
* @type {OverlayOnSignature<void>}
*/
un: OverlayOnSignature<void>;
/**
* @protected
* @type {Options}
*/
protected options: Options;
/**
* @protected
* @type {number|string|undefined}
*/
protected id: number | string | undefined;
/**
* @protected
* @type {boolean}
*/
protected insertFirst: boolean;
/**
* @protected
* @type {boolean}
*/
protected stopEvent: boolean;
/**
* @protected
* @type {HTMLElement}
*/
protected element: HTMLElement;
/**
* @protected
* @type {PanIntoViewOptions|false}
*/
protected autoPan: PanIntoViewOptions | false;
/**
* @protected
* @type {{transform_: string,
* visible: boolean}}
*/
protected rendered: {
transform_: string;
visible: boolean;
};
/**
* @protected
* @type {?import("./events.js").EventsKey}
*/
protected mapPostrenderListenerKey: import("./events.js").EventsKey | null;
/**
* Get the DOM element of this overlay.
* @return {HTMLElement|undefined} The Element containing the overlay.
* @observable
* @api
*/
getElement(): HTMLElement | undefined;
/**
* Get the overlay identifier which is set on constructor.
* @return {number|string|undefined} Id.
* @api
*/
getId(): number | string | undefined;
/**
* Get the map associated with this overlay.
* @return {import("./PluggableMap.js").default|null} The map that the
* overlay is part of.
* @observable
* @api
*/
getMap(): import("./PluggableMap.js").default | null;
/**
* Get the offset of this overlay.
* @return {Array<number>} The offset.
* @observable
* @api
*/
getOffset(): Array<number>;
/**
* Get the current position of this overlay.
* @return {import("./coordinate.js").Coordinate|undefined} The spatial point that the overlay is
* anchored at.
* @observable
* @api
*/
getPosition(): import("./coordinate.js").Coordinate | undefined;
/**
* Get the current positioning of this overlay.
* @return {Positioning} How the overlay is positioned
* relative to its point on the map.
* @observable
* @api
*/
getPositioning(): Positioning;
/**
* @protected
*/
protected handleElementChanged(): void;
/**
* @protected
*/
protected handleMapChanged(): void;
/**
* @protected
*/
protected render(): void;
/**
* @protected
*/
protected handleOffsetChanged(): void;
/**
* @protected
*/
protected handlePositionChanged(): void;
/**
* @protected
*/
protected handlePositioningChanged(): void;
/**
* Set the DOM element to be associated with this overlay.
* @param {HTMLElement|undefined} element The Element containing the overlay.
* @observable
* @api
*/
setElement(element: HTMLElement | undefined): void;
/**
* Set the map to be associated with this overlay.
* @param {import("./PluggableMap.js").default|null} map The map that the
* overlay is part of. Pass `null` to just remove the overlay from the current map.
* @observable
* @api
*/
setMap(map: import("./PluggableMap.js").default | null): void;
/**
* Set the offset for this overlay.
* @param {Array<number>} offset Offset.
* @observable
* @api
*/
setOffset(offset: Array<number>): void;
/**
* Set the position for this overlay. If the position is `undefined` the
* overlay is hidden.
* @param {import("./coordinate.js").Coordinate|undefined} position The spatial point that the overlay
* is anchored at.
* @observable
* @api
*/
setPosition(position: import("./coordinate.js").Coordinate | undefined): void;
/**
* Pan the map so that the overlay is entirely visible in the current viewport
* (if necessary) using the configured autoPan parameters
* @protected
*/
protected performAutoPan(): void;
/**
* Pan the map so that the overlay is entirely visible in the current viewport
* (if necessary).
* @param {PanIntoViewOptions} [opt_panIntoViewOptions] Options for the pan action
* @api
*/
panIntoView(opt_panIntoViewOptions?: PanIntoViewOptions | undefined): void;
/**
* Get the extent of an element relative to the document
* @param {HTMLElement} element The element.
* @param {import("./size.js").Size} size The size of the element.
* @return {import("./extent.js").Extent} The extent.
* @protected
*/
protected getRect(element: HTMLElement, size: import("./size.js").Size): import("./extent.js").Extent;
/**
* Set the positioning for this overlay.
* @param {Positioning} positioning how the overlay is
* positioned relative to its point on the map.
* @observable
* @api
*/
setPositioning(positioning: Positioning): void;
/**
* Modify the visibility of the element.
* @param {boolean} visible Element visibility.
* @protected
*/
protected setVisible(visible: boolean): void;
/**
* Update pixel position.
* @protected
*/
protected updatePixelPosition(): void;
/**
* @param {import("./pixel.js").Pixel} pixel The pixel location.
* @param {import("./size.js").Size|undefined} mapSize The map size.
* @protected
*/
protected updateRenderedPosition(pixel: import("./pixel.js").Pixel, mapSize: import("./size.js").Size | undefined): void;
/**
* returns the options this Overlay has been created with
* @return {Options} overlay options
*/
getOptions(): Options;
}
import BaseObject from "./Object.js";
//# sourceMappingURL=Overlay.d.ts.map

1
node_modules/ol/Overlay.d.ts.map generated vendored Normal file
View File

@@ -0,0 +1 @@
{"version":3,"file":"Overlay.d.ts","sourceRoot":"","sources":["src/Overlay.js"],"names":[],"mappings":";;;;;;0BAWa,aAAa,GAAG,eAAe,GAAG,cAAc,GAAG,aAAa,GAAG,eAAe,GAAG,cAAc,GAAG,UAAU,GAAG,YAAY,GAAG,WAAW;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;qBAwDnI,MAAM,KAAE,MAAM;;;;;;;;;;;;;sCAyBxB,OAAO,mBAAmB,EAAE,KAAK,GAAC,gBAAgB,GAAC,YAAY,GAAC,eAAe,GAAC,iBAAiB,GAC7G,oBAAwB;;;;yCAKZ,OAAO,cAAc,EAAE,WAAW,CAAC,OAAO,cAAc,EAAE,UAAU,EAAE,OAAO,mBAAmB,EAAE,OAAO,EAAE,MAA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,CAOtB;IAED;;OAEG;IACH,uCAMC;IAED;;OAEG;IACH,mCAyBC;IAED;;OAEG;IACH,yBAEC;IAED;;OAEG;IACH,sCAEC;IAED;;OAEG;IACH,wCAGC;IAED;;OAEG;IACH,2CAEC;IAED;;;;;OAKG;IACH,oBAJW,WAAW,GAAC,SAAS,QAM/B;IAED;;;;;;OAMG;IACH,YALW,OAAO,mBAAmB,EAAE,OAAO,GAAC,IAAI,QAOlD;IAED;;;;;OAKG;IACH,kBAJW,MAAM,MAAM,CAAC,QAMvB;IAED;;;;;;;OAOG;IACH,sBALW,OAAO,iBAAiB,EAAE,UAAU,GAAC,SAAS,QAOxD;IAED;;;;OAIG;IACH,iCAIC;IAED;;;;;OAKG;IACH,2EA2DC;IAED;;;;;;OAMG;IACH,2BALW,WAAW,QACX,OAAO,WAAW,EAAE,IAAI,GACvB,OAAO,aAAa,EAAE,MAAM,CAQvC;IAED;;;;;;OAMG;IACH,4BALW,WAAW,QAOrB;IAED;;;;OAIG;IACH,8BAHW,OAAO,QAQjB;IAED;;;OAGG;IACH,sCAWC;IAED;;;;OAIG;IACH,wCAJW,OAAO,YAAY,EAAE,KAAK,WAC1B,OAAO,WAAW,EAAE,IAAI,GAAC,SAAS,QAgD5C;IAED;;;OAGG;IACH,cAFY,OAAO,CAIlB;CACF"}

547
node_modules/ol/Overlay.js generated vendored Normal file
View File

@@ -0,0 +1,547 @@
var __extends = (this && this.__extends) || (function () {
var extendStatics = function (d, b) {
extendStatics = Object.setPrototypeOf ||
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };
return extendStatics(d, b);
};
return function (d, b) {
if (typeof b !== "function" && b !== null)
throw new TypeError("Class extends value " + String(b) + " is not a constructor or null");
extendStatics(d, b);
function __() { this.constructor = d; }
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
};
})();
/**
* @module ol/Overlay
*/
import BaseObject from './Object.js';
import MapEventType from './MapEventType.js';
import { CLASS_SELECTABLE } from './css.js';
import { containsExtent } from './extent.js';
import { listen, unlistenByKey } from './events.js';
import { outerHeight, outerWidth, removeChildren, removeNode } from './dom.js';
/**
* @typedef {'bottom-left' | 'bottom-center' | 'bottom-right' | 'center-left' | 'center-center' | 'center-right' | 'top-left' | 'top-center' | 'top-right'} Positioning
* The overlay position: `'bottom-left'`, `'bottom-center'`, `'bottom-right'`,
* `'center-left'`, `'center-center'`, `'center-right'`, `'top-left'`,
* `'top-center'`, or `'top-right'`.
*/
/**
* @typedef {Object} Options
* @property {number|string} [id] Set the overlay id. The overlay id can be used
* with the {@link module:ol/Map~Map#getOverlayById} method.
* @property {HTMLElement} [element] The overlay element.
* @property {Array<number>} [offset=[0, 0]] Offsets in pixels used when positioning
* the overlay. The first element in the
* array is the horizontal offset. A positive value shifts the overlay right.
* The second element in the array is the vertical offset. A positive value
* shifts the overlay down.
* @property {import("./coordinate.js").Coordinate} [position] The overlay position
* in map projection.
* @property {Positioning} [positioning='top-left'] Defines how
* the overlay is actually positioned with respect to its `position` property.
* Possible values are `'bottom-left'`, `'bottom-center'`, `'bottom-right'`,
* `'center-left'`, `'center-center'`, `'center-right'`, `'top-left'`,
* `'top-center'`, and `'top-right'`.
* @property {boolean} [stopEvent=true] Whether event propagation to the map
* viewport should be stopped. If `true` the overlay is placed in the same
* container as that of the controls (CSS class name
* `ol-overlaycontainer-stopevent`); if `false` it is placed in the container
* with CSS class name specified by the `className` property.
* @property {boolean} [insertFirst=true] Whether the overlay is inserted first
* in the overlay container, or appended. If the overlay is placed in the same
* container as that of the controls (see the `stopEvent` option) you will
* probably set `insertFirst` to `true` so the overlay is displayed below the
* controls.
* @property {PanIntoViewOptions|boolean} [autoPan=false] Pan the map when calling
* `setPosition`, so that the overlay is entirely visible in the current viewport?
* If `true` (deprecated), then `autoPanAnimation` and `autoPanMargin` will be
* used to determine the panning parameters; if an object is supplied then other
* parameters are ignored.
* @property {PanOptions} [autoPanAnimation] The animation options used to pan
* the overlay into view. This animation is only used when `autoPan` is enabled.
* A `duration` and `easing` may be provided to customize the animation.
* Deprecated and ignored if `autoPan` is supplied as an object.
* @property {number} [autoPanMargin=20] The margin (in pixels) between the
* overlay and the borders of the map when autopanning. Deprecated and ignored
* if `autoPan` is supplied as an object.
* @property {PanIntoViewOptions} [autoPanOptions] The options to use for the
* autoPan. This is only used when `autoPan` is enabled and has preference over
* the individual `autoPanMargin` and `autoPanOptions`.
* @property {string} [className='ol-overlay-container ol-selectable'] CSS class
* name.
*/
/**
* @typedef {Object} PanOptions
* @property {number} [duration=1000] The duration of the animation in
* milliseconds.
* @property {function(number):number} [easing] The easing function to use. Can
* be one from {@link module:ol/easing} or a custom function.
* Default is {@link module:ol/easing.inAndOut}.
*/
/**
* @typedef {Object} PanIntoViewOptions
* @property {PanOptions} [animation={}] The animation parameters for the pan
* @property {number} [margin=20] The margin (in pixels) between the
* overlay and the borders of the map when panning into view.
*/
/**
* @enum {string}
* @protected
*/
var Property = {
ELEMENT: 'element',
MAP: 'map',
OFFSET: 'offset',
POSITION: 'position',
POSITIONING: 'positioning',
};
/**
* @typedef {import("./ObjectEventType").Types|'change:element'|'change:map'|'change:offset'|'change:position'|
* 'change:positioning'} OverlayObjectEventTypes
*/
/***
* @template Return
* @typedef {import("./Observable").OnSignature<import("./Observable").EventTypes, import("./events/Event.js").default, Return> &
* import("./Observable").OnSignature<OverlayObjectEventTypes, import("./Object").ObjectEvent, Return> &
* import("./Observable").CombinedOnSignature<import("./Observable").EventTypes|OverlayObjectEventTypes, Return>} OverlayOnSignature
*/
/**
* @classdesc
* An element to be displayed over the map and attached to a single map
* location. Like {@link module:ol/control/Control~Control}, Overlays are
* visible widgets. Unlike Controls, they are not in a fixed position on the
* screen, but are tied to a geographical coordinate, so panning the map will
* move an Overlay but not a Control.
*
* Example:
*
* import Overlay from 'ol/Overlay';
*
* var popup = new Overlay({
* element: document.getElementById('popup')
* });
* popup.setPosition(coordinate);
* map.addOverlay(popup);
*
* @api
*/
var Overlay = /** @class */ (function (_super) {
__extends(Overlay, _super);
/**
* @param {Options} options Overlay options.
*/
function Overlay(options) {
var _this = _super.call(this) || this;
/***
* @type {OverlayOnSignature<import("./events").EventsKey>}
*/
_this.on;
/***
* @type {OverlayOnSignature<import("./events").EventsKey>}
*/
_this.once;
/***
* @type {OverlayOnSignature<void>}
*/
_this.un;
/**
* @protected
* @type {Options}
*/
_this.options = options;
/**
* @protected
* @type {number|string|undefined}
*/
_this.id = options.id;
/**
* @protected
* @type {boolean}
*/
_this.insertFirst =
options.insertFirst !== undefined ? options.insertFirst : true;
/**
* @protected
* @type {boolean}
*/
_this.stopEvent = options.stopEvent !== undefined ? options.stopEvent : true;
/**
* @protected
* @type {HTMLElement}
*/
_this.element = document.createElement('div');
_this.element.className =
options.className !== undefined
? options.className
: 'ol-overlay-container ' + CLASS_SELECTABLE;
_this.element.style.position = 'absolute';
_this.element.style.pointerEvents = 'auto';
var autoPan = options.autoPan;
if (autoPan && 'object' !== typeof autoPan) {
autoPan = {
animation: options.autoPanAnimation,
margin: options.autoPanMargin,
};
}
/**
* @protected
* @type {PanIntoViewOptions|false}
*/
_this.autoPan = /** @type {PanIntoViewOptions} */ (autoPan) || false;
/**
* @protected
* @type {{transform_: string,
* visible: boolean}}
*/
_this.rendered = {
transform_: '',
visible: true,
};
/**
* @protected
* @type {?import("./events.js").EventsKey}
*/
_this.mapPostrenderListenerKey = null;
_this.addChangeListener(Property.ELEMENT, _this.handleElementChanged);
_this.addChangeListener(Property.MAP, _this.handleMapChanged);
_this.addChangeListener(Property.OFFSET, _this.handleOffsetChanged);
_this.addChangeListener(Property.POSITION, _this.handlePositionChanged);
_this.addChangeListener(Property.POSITIONING, _this.handlePositioningChanged);
if (options.element !== undefined) {
_this.setElement(options.element);
}
_this.setOffset(options.offset !== undefined ? options.offset : [0, 0]);
_this.setPositioning(options.positioning || 'top-left');
if (options.position !== undefined) {
_this.setPosition(options.position);
}
return _this;
}
/**
* Get the DOM element of this overlay.
* @return {HTMLElement|undefined} The Element containing the overlay.
* @observable
* @api
*/
Overlay.prototype.getElement = function () {
return /** @type {HTMLElement|undefined} */ (this.get(Property.ELEMENT));
};
/**
* Get the overlay identifier which is set on constructor.
* @return {number|string|undefined} Id.
* @api
*/
Overlay.prototype.getId = function () {
return this.id;
};
/**
* Get the map associated with this overlay.
* @return {import("./PluggableMap.js").default|null} The map that the
* overlay is part of.
* @observable
* @api
*/
Overlay.prototype.getMap = function () {
return /** @type {import("./PluggableMap.js").default|null} */ (this.get(Property.MAP) || null);
};
/**
* Get the offset of this overlay.
* @return {Array<number>} The offset.
* @observable
* @api
*/
Overlay.prototype.getOffset = function () {
return /** @type {Array<number>} */ (this.get(Property.OFFSET));
};
/**
* Get the current position of this overlay.
* @return {import("./coordinate.js").Coordinate|undefined} The spatial point that the overlay is
* anchored at.
* @observable
* @api
*/
Overlay.prototype.getPosition = function () {
return /** @type {import("./coordinate.js").Coordinate|undefined} */ (this.get(Property.POSITION));
};
/**
* Get the current positioning of this overlay.
* @return {Positioning} How the overlay is positioned
* relative to its point on the map.
* @observable
* @api
*/
Overlay.prototype.getPositioning = function () {
return /** @type {Positioning} */ (this.get(Property.POSITIONING));
};
/**
* @protected
*/
Overlay.prototype.handleElementChanged = function () {
removeChildren(this.element);
var element = this.getElement();
if (element) {
this.element.appendChild(element);
}
};
/**
* @protected
*/
Overlay.prototype.handleMapChanged = function () {
if (this.mapPostrenderListenerKey) {
removeNode(this.element);
unlistenByKey(this.mapPostrenderListenerKey);
this.mapPostrenderListenerKey = null;
}
var map = this.getMap();
if (map) {
this.mapPostrenderListenerKey = listen(map, MapEventType.POSTRENDER, this.render, this);
this.updatePixelPosition();
var container = this.stopEvent
? map.getOverlayContainerStopEvent()
: map.getOverlayContainer();
if (this.insertFirst) {
container.insertBefore(this.element, container.childNodes[0] || null);
}
else {
container.appendChild(this.element);
}
this.performAutoPan();
}
};
/**
* @protected
*/
Overlay.prototype.render = function () {
this.updatePixelPosition();
};
/**
* @protected
*/
Overlay.prototype.handleOffsetChanged = function () {
this.updatePixelPosition();
};
/**
* @protected
*/
Overlay.prototype.handlePositionChanged = function () {
this.updatePixelPosition();
this.performAutoPan();
};
/**
* @protected
*/
Overlay.prototype.handlePositioningChanged = function () {
this.updatePixelPosition();
};
/**
* Set the DOM element to be associated with this overlay.
* @param {HTMLElement|undefined} element The Element containing the overlay.
* @observable
* @api
*/
Overlay.prototype.setElement = function (element) {
this.set(Property.ELEMENT, element);
};
/**
* Set the map to be associated with this overlay.
* @param {import("./PluggableMap.js").default|null} map The map that the
* overlay is part of. Pass `null` to just remove the overlay from the current map.
* @observable
* @api
*/
Overlay.prototype.setMap = function (map) {
this.set(Property.MAP, map);
};
/**
* Set the offset for this overlay.
* @param {Array<number>} offset Offset.
* @observable
* @api
*/
Overlay.prototype.setOffset = function (offset) {
this.set(Property.OFFSET, offset);
};
/**
* Set the position for this overlay. If the position is `undefined` the
* overlay is hidden.
* @param {import("./coordinate.js").Coordinate|undefined} position The spatial point that the overlay
* is anchored at.
* @observable
* @api
*/
Overlay.prototype.setPosition = function (position) {
this.set(Property.POSITION, position);
};
/**
* Pan the map so that the overlay is entirely visible in the current viewport
* (if necessary) using the configured autoPan parameters
* @protected
*/
Overlay.prototype.performAutoPan = function () {
if (this.autoPan) {
this.panIntoView(this.autoPan);
}
};
/**
* Pan the map so that the overlay is entirely visible in the current viewport
* (if necessary).
* @param {PanIntoViewOptions} [opt_panIntoViewOptions] Options for the pan action
* @api
*/
Overlay.prototype.panIntoView = function (opt_panIntoViewOptions) {
var map = this.getMap();
if (!map || !map.getTargetElement() || !this.get(Property.POSITION)) {
return;
}
var mapRect = this.getRect(map.getTargetElement(), map.getSize());
var element = this.getElement();
var overlayRect = this.getRect(element, [
outerWidth(element),
outerHeight(element),
]);
var panIntoViewOptions = opt_panIntoViewOptions || {};
var myMargin = panIntoViewOptions.margin === undefined ? 20 : panIntoViewOptions.margin;
if (!containsExtent(mapRect, overlayRect)) {
// the overlay is not completely inside the viewport, so pan the map
var offsetLeft = overlayRect[0] - mapRect[0];
var offsetRight = mapRect[2] - overlayRect[2];
var offsetTop = overlayRect[1] - mapRect[1];
var offsetBottom = mapRect[3] - overlayRect[3];
var delta = [0, 0];
if (offsetLeft < 0) {
// move map to the left
delta[0] = offsetLeft - myMargin;
}
else if (offsetRight < 0) {
// move map to the right
delta[0] = Math.abs(offsetRight) + myMargin;
}
if (offsetTop < 0) {
// move map up
delta[1] = offsetTop - myMargin;
}
else if (offsetBottom < 0) {
// move map down
delta[1] = Math.abs(offsetBottom) + myMargin;
}
if (delta[0] !== 0 || delta[1] !== 0) {
var center = /** @type {import("./coordinate.js").Coordinate} */ (map.getView().getCenterInternal());
var centerPx = map.getPixelFromCoordinateInternal(center);
if (!centerPx) {
return;
}
var newCenterPx = [centerPx[0] + delta[0], centerPx[1] + delta[1]];
var panOptions = panIntoViewOptions.animation || {};
map.getView().animateInternal({
center: map.getCoordinateFromPixelInternal(newCenterPx),
duration: panOptions.duration,
easing: panOptions.easing,
});
}
}
};
/**
* Get the extent of an element relative to the document
* @param {HTMLElement} element The element.
* @param {import("./size.js").Size} size The size of the element.
* @return {import("./extent.js").Extent} The extent.
* @protected
*/
Overlay.prototype.getRect = function (element, size) {
var box = element.getBoundingClientRect();
var offsetX = box.left + window.pageXOffset;
var offsetY = box.top + window.pageYOffset;
return [offsetX, offsetY, offsetX + size[0], offsetY + size[1]];
};
/**
* Set the positioning for this overlay.
* @param {Positioning} positioning how the overlay is
* positioned relative to its point on the map.
* @observable
* @api
*/
Overlay.prototype.setPositioning = function (positioning) {
this.set(Property.POSITIONING, positioning);
};
/**
* Modify the visibility of the element.
* @param {boolean} visible Element visibility.
* @protected
*/
Overlay.prototype.setVisible = function (visible) {
if (this.rendered.visible !== visible) {
this.element.style.display = visible ? '' : 'none';
this.rendered.visible = visible;
}
};
/**
* Update pixel position.
* @protected
*/
Overlay.prototype.updatePixelPosition = function () {
var map = this.getMap();
var position = this.getPosition();
if (!map || !map.isRendered() || !position) {
this.setVisible(false);
return;
}
var pixel = map.getPixelFromCoordinate(position);
var mapSize = map.getSize();
this.updateRenderedPosition(pixel, mapSize);
};
/**
* @param {import("./pixel.js").Pixel} pixel The pixel location.
* @param {import("./size.js").Size|undefined} mapSize The map size.
* @protected
*/
Overlay.prototype.updateRenderedPosition = function (pixel, mapSize) {
var style = this.element.style;
var offset = this.getOffset();
var positioning = this.getPositioning();
this.setVisible(true);
var x = Math.round(pixel[0] + offset[0]) + 'px';
var y = Math.round(pixel[1] + offset[1]) + 'px';
var posX = '0%';
var posY = '0%';
if (positioning == 'bottom-right' ||
positioning == 'center-right' ||
positioning == 'top-right') {
posX = '-100%';
}
else if (positioning == 'bottom-center' ||
positioning == 'center-center' ||
positioning == 'top-center') {
posX = '-50%';
}
if (positioning == 'bottom-left' ||
positioning == 'bottom-center' ||
positioning == 'bottom-right') {
posY = '-100%';
}
else if (positioning == 'center-left' ||
positioning == 'center-center' ||
positioning == 'center-right') {
posY = '-50%';
}
var transform = "translate(".concat(posX, ", ").concat(posY, ") translate(").concat(x, ", ").concat(y, ")");
if (this.rendered.transform_ != transform) {
this.rendered.transform_ = transform;
style.transform = transform;
// @ts-ignore IE9
style.msTransform = transform;
}
};
/**
* returns the options this Overlay has been created with
* @return {Options} overlay options
*/
Overlay.prototype.getOptions = function () {
return this.options;
};
return Overlay;
}(BaseObject));
export default Overlay;
//# sourceMappingURL=Overlay.js.map

1
node_modules/ol/Overlay.js.map generated vendored Normal file

File diff suppressed because one or more lines are too long

829
node_modules/ol/PluggableMap.d.ts generated vendored Normal file
View File

@@ -0,0 +1,829 @@
export default PluggableMap;
/**
* State of the current frame. Only `pixelRatio`, `time` and `viewState` should
* be used in applications.
*/
export type FrameState = {
/**
* The pixel ratio of the frame.
*/
pixelRatio: number;
/**
* The time when rendering of the frame was requested.
*/
time: number;
/**
* The state of the current view.
*/
viewState: import("./View.js").State;
/**
* Animate.
*/
animate: boolean;
/**
* CoordinateToPixelTransform.
*/
coordinateToPixelTransform: import("./transform.js").Transform;
/**
* DeclutterTree.
*/
declutterTree: any;
/**
* Extent.
*/
extent: null | import("./extent.js").Extent;
/**
* Next extent during an animation series.
*/
nextExtent?: import("./extent.js").Extent | undefined;
/**
* Index.
*/
index: number;
/**
* LayerStatesArray.
*/
layerStatesArray: Array<import("./layer/Layer.js").State>;
/**
* LayerIndex.
*/
layerIndex: number;
/**
* PixelToCoordinateTransform.
*/
pixelToCoordinateTransform: import("./transform.js").Transform;
/**
* PostRenderFunctions.
*/
postRenderFunctions: Array<PostRenderFunction>;
/**
* Size.
*/
size: import("./size.js").Size;
/**
* TileQueue.
*/
tileQueue: TileQueue;
/**
* UsedTiles.
*/
usedTiles: {
[x: string]: {
[x: string]: boolean;
};
};
/**
* ViewHints.
*/
viewHints: Array<number>;
/**
* WantedTiles.
*/
wantedTiles: {
[x: string]: {
[x: string]: boolean;
};
};
/**
* The id of the map.
*/
mapId: string;
/**
* Identifiers of previously rendered elements.
*/
renderTargets: {
[x: string]: boolean;
};
};
export type PostRenderFunction = (arg0: PluggableMap, arg1: FrameState | null) => any;
export type AtPixelOptions = {
/**
* Layer filter
* function. The filter function will receive one argument, the
* {@link module :ol/layer/Layer~Layer layer-candidate} and it should return a boolean value.
* Only layers which are visible and for which this function returns `true`
* will be tested for features. By default, all visible layers will be tested.
*/
layerFilter?: undefined | ((arg0: import("./layer/Layer.js").default<import("./source/Source").default>) => boolean);
/**
* Hit-detection tolerance in css pixels. Pixels
* inside the radius around the given position will be checked for features.
*/
hitTolerance?: number | undefined;
/**
* Check-Wrapped Will check for for wrapped geometries inside the range of
* +/- 1 world width. Works only if a projection is used that can be wrapped.
*/
checkWrapped?: boolean | undefined;
};
export type MapOptionsInternal = {
/**
* Controls.
*/
controls?: Collection<import("./control/Control.js").default> | undefined;
/**
* Interactions.
*/
interactions?: Collection<import("./interaction/Interaction.js").default> | undefined;
/**
* KeyboardEventTarget.
*/
keyboardEventTarget: HTMLElement | Document;
/**
* Overlays.
*/
overlays: Collection<import("./Overlay.js").default>;
/**
* Values.
*/
values: {
[x: string]: any;
};
};
export type MapObjectEventTypes = import("./ObjectEventType").Types | 'change:layergroup' | 'change:size' | 'change:target' | 'change:view';
/**
* *
*/
export type PluggableMapOnSignature<Return> = import("./Observable").OnSignature<import("./Observable").EventTypes, import("./events/Event.js").default, Return> & import("./Observable").OnSignature<MapObjectEventTypes, import("./Object").ObjectEvent, Return> & import("./Observable").OnSignature<import("./MapBrowserEventType").Types, MapBrowserEvent<any>, Return> & import("./Observable").OnSignature<import("./MapEventType").Types, import("./MapEvent").default, Return> & import("./Observable").OnSignature<import("./render/EventType").MapRenderEventTypes, import("./render/Event").default, Return> & import("./Observable").CombinedOnSignature<import("./Observable").EventTypes | MapObjectEventTypes | import("./MapBrowserEventType").Types | import("./MapEventType").Types | import("./render/EventType").MapRenderEventTypes, Return>;
/**
* Object literal with config options for the map.
*/
export type MapOptions = {
/**
* Controls initially added to the map. If not specified,
* {@link module :ol/control.defaults} is used.
*/
controls?: Collection<import("./control/Control.js").default> | import("./control/Control.js").default[] | undefined;
/**
* The ratio between
* physical pixels and device-independent pixels (dips) on the device.
*/
pixelRatio?: number | undefined;
/**
* Interactions that are initially added to the map. If not specified,
* {@link module :ol/interaction.defaults} is used.
*/
interactions?: Collection<import("./interaction/Interaction.js").default> | import("./interaction/Interaction.js").default[] | undefined;
/**
* The element to
* listen to keyboard events on. This determines when the `KeyboardPan` and
* `KeyboardZoom` interactions trigger. For example, if this option is set to
* `document` the keyboard interactions will always trigger. If this option is
* not specified, the element the library listens to keyboard events on is the
* map target (i.e. the user-provided div for the map). If this is not
* `document`, the target element needs to be focused for key events to be
* emitted, requiring that the target element has a `tabindex` attribute.
*/
keyboardEventTarget?: string | Document | HTMLElement | undefined;
/**
* Layers. If this is not defined, a map with no layers will be rendered. Note
* that layers are rendered in the order supplied, so if you want, for example,
* a vector layer to appear on top of a tile layer, it must come after the tile
* layer.
*/
layers?: import("./layer/Base.js").default[] | Collection<import("./layer/Base.js").default> | LayerGroup | undefined;
/**
* Maximum number tiles to load
* simultaneously.
*/
maxTilesLoading?: number | undefined;
/**
* The minimum distance in pixels the
* cursor must move to be detected as a map move event instead of a click.
* Increasing this value can make it easier to click on the map.
*/
moveTolerance?: number | undefined;
/**
* Overlays initially added to the map. By default, no overlays are added.
*/
overlays?: Collection<import("./Overlay.js").default> | import("./Overlay.js").default[] | undefined;
/**
* The container for the map, either the
* element itself or the `id` of the element. If not specified at construction
* time, {@link module :ol/Map~Map#setTarget} must be called for the map to be
* rendered. If passed by element, the container can be in a secondary document.
*/
target?: string | HTMLElement | undefined;
/**
* The map's view. No layer sources will be
* fetched unless this is specified at construction time or through
* {@link module :ol/Map~Map#setView}.
*/
view?: View | Promise<import("./View.js").ViewOptions> | undefined;
};
/**
* @fires import("./MapBrowserEvent.js").MapBrowserEvent
* @fires import("./MapEvent.js").MapEvent
* @fires import("./render/Event.js").default#precompose
* @fires import("./render/Event.js").default#postcompose
* @fires import("./render/Event.js").default#rendercomplete
* @api
*/
declare class PluggableMap extends BaseObject {
/**
* @param {MapOptions} options Map options.
*/
constructor(options: MapOptions);
/***
* @type {PluggableMapOnSignature<import("./events").EventsKey>}
*/
on: PluggableMapOnSignature<import("./events").EventsKey>;
/***
* @type {PluggableMapOnSignature<import("./events").EventsKey>}
*/
once: PluggableMapOnSignature<import("./events").EventsKey>;
/***
* @type {PluggableMapOnSignature<void>}
*/
un: PluggableMapOnSignature<void>;
/**
* @private
* @type {boolean|undefined}
*/
private renderComplete_;
/**
* @private
* @type {boolean}
*/
private loaded_;
/** @private */
private boundHandleBrowserEvent_;
/**
* @type {number}
* @private
*/
private maxTilesLoading_;
/**
* @private
* @type {number}
*/
private pixelRatio_;
/**
* @private
* @type {*}
*/
private postRenderTimeoutHandle_;
/**
* @private
* @type {number|undefined}
*/
private animationDelayKey_;
/**
* @private
*/
private animationDelay_;
/**
* @private
* @type {import("./transform.js").Transform}
*/
private coordinateToPixelTransform_;
/**
* @private
* @type {import("./transform.js").Transform}
*/
private pixelToCoordinateTransform_;
/**
* @private
* @type {number}
*/
private frameIndex_;
/**
* @private
* @type {?FrameState}
*/
private frameState_;
/**
* The extent at the previous 'moveend' event.
* @private
* @type {import("./extent.js").Extent}
*/
private previousExtent_;
/**
* @private
* @type {?import("./events.js").EventsKey}
*/
private viewPropertyListenerKey_;
/**
* @private
* @type {?import("./events.js").EventsKey}
*/
private viewChangeListenerKey_;
/**
* @private
* @type {?Array<import("./events.js").EventsKey>}
*/
private layerGroupPropertyListenerKeys_;
/**
* @private
* @type {!HTMLElement}
*/
private viewport_;
/**
* @private
* @type {!HTMLElement}
*/
private overlayContainer_;
/**
* @private
* @type {!HTMLElement}
*/
private overlayContainerStopEvent_;
/**
* @private
* @type {MapBrowserEventHandler}
*/
private mapBrowserEventHandler_;
/**
* @private
* @type {number}
*/
private moveTolerance_;
/**
* @private
* @type {HTMLElement|Document}
*/
private keyboardEventTarget_;
/**
* @private
* @type {?Array<import("./events.js").EventsKey>}
*/
private targetChangeHandlerKeys_;
/**
* @type {Collection<import("./control/Control.js").default>}
* @protected
*/
protected controls: Collection<import("./control/Control.js").default>;
/**
* @type {Collection<import("./interaction/Interaction.js").default>}
* @protected
*/
protected interactions: Collection<import("./interaction/Interaction.js").default>;
/**
* @type {Collection<import("./Overlay.js").default>}
* @private
*/
private overlays_;
/**
* A lookup of overlays by id.
* @private
* @type {Object<string, import("./Overlay.js").default>}
*/
private overlayIdIndex_;
/**
* @type {import("./renderer/Map.js").default|null}
* @private
*/
private renderer_;
/**
* @private
* @type {!Array<PostRenderFunction>}
*/
private postRenderFunctions_;
/**
* @private
* @type {TileQueue}
*/
private tileQueue_;
/**
* @abstract
* @return {import("./renderer/Map.js").default} The map renderer
*/
createRenderer(): import("./renderer/Map.js").default;
/**
* Add the given control to the map.
* @param {import("./control/Control.js").default} control Control.
* @api
*/
addControl(control: import("./control/Control.js").default): void;
/**
* Add the given interaction to the map. If you want to add an interaction
* at another point of the collection use `getInteractions()` and the methods
* available on {@link module:ol/Collection~Collection}. This can be used to
* stop the event propagation from the handleEvent function. The interactions
* get to handle the events in the reverse order of this collection.
* @param {import("./interaction/Interaction.js").default} interaction Interaction to add.
* @api
*/
addInteraction(interaction: import("./interaction/Interaction.js").default): void;
/**
* Adds the given layer to the top of this map. If you want to add a layer
* elsewhere in the stack, use `getLayers()` and the methods available on
* {@link module:ol/Collection~Collection}.
* @param {import("./layer/Base.js").default} layer Layer.
* @api
*/
addLayer(layer: import("./layer/Base.js").default): void;
/**
* @param {import("./layer/Group.js").GroupEvent} event The layer add event.
* @private
*/
private handleLayerAdd_;
/**
* Add the given overlay to the map.
* @param {import("./Overlay.js").default} overlay Overlay.
* @api
*/
addOverlay(overlay: import("./Overlay.js").default): void;
/**
* This deals with map's overlay collection changes.
* @param {import("./Overlay.js").default} overlay Overlay.
* @private
*/
private addOverlayInternal_;
/**
* Detect features that intersect a pixel on the viewport, and execute a
* callback with each intersecting feature. Layers included in the detection can
* be configured through the `layerFilter` option in `opt_options`.
* @param {import("./pixel.js").Pixel} pixel Pixel.
* @param {function(import("./Feature.js").FeatureLike, import("./layer/Layer.js").default<import("./source/Source").default>, import("./geom/SimpleGeometry.js").default): T} callback Feature callback. The callback will be
* called with two arguments. The first argument is one
* {@link module:ol/Feature~Feature feature} or
* {@link module:ol/render/Feature~RenderFeature render feature} at the pixel, the second is
* the {@link module:ol/layer/Layer~Layer layer} of the feature and will be null for
* unmanaged layers. To stop detection, callback functions can return a
* truthy value.
* @param {AtPixelOptions} [opt_options] Optional options.
* @return {T|undefined} Callback result, i.e. the return value of last
* callback execution, or the first truthy callback return value.
* @template T
* @api
*/
forEachFeatureAtPixel<T>(pixel: import("./pixel.js").Pixel, callback: (arg0: import("./Feature.js").FeatureLike, arg1: import("./layer/Layer.js").default<import("./source/Source").default>, arg2: import("./geom/SimpleGeometry.js").default) => T, opt_options?: AtPixelOptions | undefined): T | undefined;
/**
* Get all features that intersect a pixel on the viewport.
* @param {import("./pixel.js").Pixel} pixel Pixel.
* @param {AtPixelOptions} [opt_options] Optional options.
* @return {Array<import("./Feature.js").FeatureLike>} The detected features or
* an empty array if none were found.
* @api
*/
getFeaturesAtPixel(pixel: import("./pixel.js").Pixel, opt_options?: AtPixelOptions | undefined): Array<import("./Feature.js").FeatureLike>;
/**
* Get all layers from all layer groups.
* @return {Array<import("./layer/Layer.js").default>} Layers.
* @api
*/
getAllLayers(): Array<import("./layer/Layer.js").default>;
/**
* Please the `layer.getData()` method for {@link module:ol/layer/Tile~TileLayer#getData tile layers} or
* {@link module:ol/layer/Image~ImageLayer#getData image layers} instead of using this method.
*
* Detect layers that have a color value at a pixel on the viewport, and
* execute a callback with each matching layer. Layers included in the
* detection can be configured through `opt_layerFilter`.
*
* Note: In maps with more than one layer, this method will typically return pixel data
* representing the composed image of all layers visible at the given pixel because layers
* will generally share the same rendering context. To force layers to render separately, and
* to get pixel data representing only one layer at a time, you can assign each layer a unique
* `className` in its constructor.
*
* @param {import("./pixel.js").Pixel} pixel Pixel.
* @param {function(this: S, import("./layer/Layer.js").default, (Uint8ClampedArray|Uint8Array)): T} callback
* Layer callback. This callback will receive two arguments: first is the
* {@link module:ol/layer/Layer~Layer layer}, second argument is an array representing
* [R, G, B, A] pixel values (0 - 255) and will be `null` for layer types
* that do not currently support this argument. To stop detection, callback
* functions can return a truthy value.
* @param {AtPixelOptions} [opt_options] Configuration options.
* @return {T|undefined} Callback result, i.e. the return value of last
* callback execution, or the first truthy callback return value.
* @template S,T
* @api
* @deprecated
*/
forEachLayerAtPixel<S, T_1>(pixel: import("./pixel.js").Pixel, callback: (this: S, arg1: import("./layer/Layer.js").default, arg2: (Uint8ClampedArray | Uint8Array)) => T_1, opt_options?: AtPixelOptions | undefined): T_1 | undefined;
/**
* Detect if features intersect a pixel on the viewport. Layers included in the
* detection can be configured through `opt_layerFilter`.
* @param {import("./pixel.js").Pixel} pixel Pixel.
* @param {AtPixelOptions} [opt_options] Optional options.
* @return {boolean} Is there a feature at the given pixel?
* @api
*/
hasFeatureAtPixel(pixel: import("./pixel.js").Pixel, opt_options?: AtPixelOptions | undefined): boolean;
/**
* Returns the coordinate in user projection for a browser event.
* @param {MouseEvent} event Event.
* @return {import("./coordinate.js").Coordinate} Coordinate.
* @api
*/
getEventCoordinate(event: MouseEvent): import("./coordinate.js").Coordinate;
/**
* Returns the coordinate in view projection for a browser event.
* @param {MouseEvent} event Event.
* @return {import("./coordinate.js").Coordinate} Coordinate.
*/
getEventCoordinateInternal(event: MouseEvent): import("./coordinate.js").Coordinate;
/**
* Returns the map pixel position for a browser event relative to the viewport.
* @param {UIEvent} event Event.
* @return {import("./pixel.js").Pixel} Pixel.
* @api
*/
getEventPixel(event: UIEvent): import("./pixel.js").Pixel;
/**
* Get the target in which this map is rendered.
* Note that this returns what is entered as an option or in setTarget:
* if that was an element, it returns an element; if a string, it returns that.
* @return {HTMLElement|string|undefined} The Element or id of the Element that the
* map is rendered in.
* @observable
* @api
*/
getTarget(): HTMLElement | string | undefined;
/**
* Get the DOM element into which this map is rendered. In contrast to
* `getTarget` this method always return an `Element`, or `null` if the
* map has no target.
* @return {HTMLElement} The element that the map is rendered in.
* @api
*/
getTargetElement(): HTMLElement;
/**
* Get the coordinate for a given pixel. This returns a coordinate in the
* user projection.
* @param {import("./pixel.js").Pixel} pixel Pixel position in the map viewport.
* @return {import("./coordinate.js").Coordinate} The coordinate for the pixel position.
* @api
*/
getCoordinateFromPixel(pixel: import("./pixel.js").Pixel): import("./coordinate.js").Coordinate;
/**
* Get the coordinate for a given pixel. This returns a coordinate in the
* map view projection.
* @param {import("./pixel.js").Pixel} pixel Pixel position in the map viewport.
* @return {import("./coordinate.js").Coordinate} The coordinate for the pixel position.
*/
getCoordinateFromPixelInternal(pixel: import("./pixel.js").Pixel): import("./coordinate.js").Coordinate;
/**
* Get the map controls. Modifying this collection changes the controls
* associated with the map.
* @return {Collection<import("./control/Control.js").default>} Controls.
* @api
*/
getControls(): Collection<import("./control/Control.js").default>;
/**
* Get the map overlays. Modifying this collection changes the overlays
* associated with the map.
* @return {Collection<import("./Overlay.js").default>} Overlays.
* @api
*/
getOverlays(): Collection<import("./Overlay.js").default>;
/**
* Get an overlay by its identifier (the value returned by overlay.getId()).
* Note that the index treats string and numeric identifiers as the same. So
* `map.getOverlayById(2)` will return an overlay with id `'2'` or `2`.
* @param {string|number} id Overlay identifier.
* @return {import("./Overlay.js").default} Overlay.
* @api
*/
getOverlayById(id: string | number): import("./Overlay.js").default;
/**
* Get the map interactions. Modifying this collection changes the interactions
* associated with the map.
*
* Interactions are used for e.g. pan, zoom and rotate.
* @return {Collection<import("./interaction/Interaction.js").default>} Interactions.
* @api
*/
getInteractions(): Collection<import("./interaction/Interaction.js").default>;
/**
* Get the layergroup associated with this map.
* @return {LayerGroup} A layer group containing the layers in this map.
* @observable
* @api
*/
getLayerGroup(): LayerGroup;
/**
* Clear any existing layers and add layers to the map.
* @param {Array<import("./layer/Base.js").default>|Collection<import("./layer/Base.js").default>} layers The layers to be added to the map.
* @api
*/
setLayers(layers: Array<import("./layer/Base.js").default> | Collection<import("./layer/Base.js").default>): void;
/**
* Get the collection of layers associated with this map.
* @return {!Collection<import("./layer/Base.js").default>} Layers.
* @api
*/
getLayers(): Collection<import("./layer/Base.js").default>;
/**
* @return {boolean} Layers have sources that are still loading.
*/
getLoadingOrNotReady(): boolean;
/**
* Get the pixel for a coordinate. This takes a coordinate in the user
* projection and returns the corresponding pixel.
* @param {import("./coordinate.js").Coordinate} coordinate A map coordinate.
* @return {import("./pixel.js").Pixel} A pixel position in the map viewport.
* @api
*/
getPixelFromCoordinate(coordinate: import("./coordinate.js").Coordinate): import("./pixel.js").Pixel;
/**
* Get the pixel for a coordinate. This takes a coordinate in the map view
* projection and returns the corresponding pixel.
* @param {import("./coordinate.js").Coordinate} coordinate A map coordinate.
* @return {import("./pixel.js").Pixel} A pixel position in the map viewport.
*/
getPixelFromCoordinateInternal(coordinate: import("./coordinate.js").Coordinate): import("./pixel.js").Pixel;
/**
* Get the map renderer.
* @return {import("./renderer/Map.js").default|null} Renderer
*/
getRenderer(): import("./renderer/Map.js").default | null;
/**
* Get the size of this map.
* @return {import("./size.js").Size|undefined} The size in pixels of the map in the DOM.
* @observable
* @api
*/
getSize(): import("./size.js").Size | undefined;
/**
* Get the view associated with this map. A view manages properties such as
* center and resolution.
* @return {View} The view that controls this map.
* @observable
* @api
*/
getView(): View;
/**
* Get the element that serves as the map viewport.
* @return {HTMLElement} Viewport.
* @api
*/
getViewport(): HTMLElement;
/**
* Get the element that serves as the container for overlays. Elements added to
* this container will let mousedown and touchstart events through to the map,
* so clicks and gestures on an overlay will trigger {@link module:ol/MapBrowserEvent~MapBrowserEvent}
* events.
* @return {!HTMLElement} The map's overlay container.
*/
getOverlayContainer(): HTMLElement;
/**
* Get the element that serves as a container for overlays that don't allow
* event propagation. Elements added to this container won't let mousedown and
* touchstart events through to the map, so clicks and gestures on an overlay
* don't trigger any {@link module:ol/MapBrowserEvent~MapBrowserEvent}.
* @return {!HTMLElement} The map's overlay container that stops events.
*/
getOverlayContainerStopEvent(): HTMLElement;
/**
* @return {!Document} The document where the map is displayed.
*/
getOwnerDocument(): Document;
/**
* @param {import("./Tile.js").default} tile Tile.
* @param {string} tileSourceKey Tile source key.
* @param {import("./coordinate.js").Coordinate} tileCenter Tile center.
* @param {number} tileResolution Tile resolution.
* @return {number} Tile priority.
*/
getTilePriority(tile: import("./Tile.js").default, tileSourceKey: string, tileCenter: import("./coordinate.js").Coordinate, tileResolution: number): number;
/**
* @param {UIEvent} browserEvent Browser event.
* @param {string} [opt_type] Type.
*/
handleBrowserEvent(browserEvent: UIEvent, opt_type?: string | undefined): void;
/**
* @param {MapBrowserEvent} mapBrowserEvent The event to handle.
*/
handleMapBrowserEvent(mapBrowserEvent: MapBrowserEvent<any>): void;
/**
* @protected
*/
protected handlePostRender(): void;
/**
* @private
*/
private handleSizeChanged_;
/**
* @private
*/
private handleTargetChanged_;
/**
* @private
*/
private handleTileChange_;
/**
* @private
*/
private handleViewPropertyChanged_;
/**
* @private
*/
private handleViewChanged_;
/**
* @private
*/
private handleLayerGroupChanged_;
/**
* @return {boolean} Is rendered.
*/
isRendered(): boolean;
/**
* Requests an immediate render in a synchronous manner.
* @api
*/
renderSync(): void;
/**
* Redraws all text after new fonts have loaded
*/
redrawText(): void;
/**
* Request a map rendering (at the next animation frame).
* @api
*/
render(): void;
/**
* Remove the given control from the map.
* @param {import("./control/Control.js").default} control Control.
* @return {import("./control/Control.js").default|undefined} The removed control (or undefined
* if the control was not found).
* @api
*/
removeControl(control: import("./control/Control.js").default): import("./control/Control.js").default | undefined;
/**
* Remove the given interaction from the map.
* @param {import("./interaction/Interaction.js").default} interaction Interaction to remove.
* @return {import("./interaction/Interaction.js").default|undefined} The removed interaction (or
* undefined if the interaction was not found).
* @api
*/
removeInteraction(interaction: import("./interaction/Interaction.js").default): import("./interaction/Interaction.js").default | undefined;
/**
* Removes the given layer from the map.
* @param {import("./layer/Base.js").default} layer Layer.
* @return {import("./layer/Base.js").default|undefined} The removed layer (or undefined if the
* layer was not found).
* @api
*/
removeLayer(layer: import("./layer/Base.js").default): import("./layer/Base.js").default | undefined;
/**
* @param {import("./layer/Group.js").GroupEvent} event The layer remove event.
* @private
*/
private handleLayerRemove_;
/**
* Remove the given overlay from the map.
* @param {import("./Overlay.js").default} overlay Overlay.
* @return {import("./Overlay.js").default|undefined} The removed overlay (or undefined
* if the overlay was not found).
* @api
*/
removeOverlay(overlay: import("./Overlay.js").default): import("./Overlay.js").default | undefined;
/**
* @param {number} time Time.
* @private
*/
private renderFrame_;
/**
* Sets the layergroup of this map.
* @param {LayerGroup} layerGroup A layer group containing the layers in this map.
* @observable
* @api
*/
setLayerGroup(layerGroup: LayerGroup): void;
/**
* Set the size of this map.
* @param {import("./size.js").Size|undefined} size The size in pixels of the map in the DOM.
* @observable
* @api
*/
setSize(size: import("./size.js").Size | undefined): void;
/**
* Set the target element to render this map into.
* @param {HTMLElement|string} [target] The Element or id of the Element
* that the map is rendered in.
* @observable
* @api
*/
setTarget(target?: string | HTMLElement | undefined): void;
/**
* Set the view for this map.
* @param {View|Promise<import("./View.js").ViewOptions>} view The view that controls this map.
* It is also possible to pass a promise that resolves to options for constructing a view. This
* alternative allows view properties to be resolved by sources or other components that load
* view-related metadata.
* @observable
* @api
*/
setView(view: View | Promise<import("./View.js").ViewOptions>): void;
/**
* Force a recalculation of the map viewport size. This should be called when
* third-party code changes the size of the map viewport.
* @api
*/
updateSize(): void;
/**
* Recomputes the viewport size and save it on the view object (if any)
* @private
*/
private updateViewportSize_;
}
import TileQueue from "./TileQueue.js";
import Collection from "./Collection.js";
import MapBrowserEvent from "./MapBrowserEvent.js";
import LayerGroup from "./layer/Group.js";
import View from "./View.js";
import BaseObject from "./Object.js";
//# sourceMappingURL=PluggableMap.d.ts.map

1
node_modules/ol/PluggableMap.d.ts.map generated vendored Normal file

File diff suppressed because one or more lines are too long

1510
node_modules/ol/PluggableMap.js generated vendored Normal file

File diff suppressed because it is too large Load Diff

Some files were not shown because too many files have changed in this diff Show More