jpf 5.0.42 → 5.0.44
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/controls/leaflet/OpenStreetMapTileLayer/OpenStreetMapTileLayer.d.ts +1 -0
- package/dist/controls/leaflet/OpenStreetMapTileLayer/OpenStreetMapTileLayer.js +2 -1
- package/dist/controls/leaflet/OpenStreetMapTileLayer/OpenStreetMapTileLayer.js.map +1 -1
- package/dist/framework/event.d.ts +3 -1
- package/dist/framework/event.js +3 -0
- package/dist/framework/event.js.map +1 -1
- package/package.json +1 -1
- package/src/controls/leaflet/OpenStreetMapTileLayer/OpenStreetMapTileLayer.ts +3 -1
- package/src/framework/event.ts +6 -1
|
@@ -5,7 +5,8 @@ export class OpenStreetMapTileLayer extends TileLayer {
|
|
|
5
5
|
options = {};
|
|
6
6
|
}
|
|
7
7
|
options.attribution = "© <a href=\"https://www.openstreetmap.org/copyright\">OpenStreetMap</a> contributors";
|
|
8
|
-
|
|
8
|
+
const urlTemplate = options.urlTemplate || "https://{s}.tile.openstreetmap.org/{z}/{x}/{y}.png";
|
|
9
|
+
super(urlTemplate, options);
|
|
9
10
|
}
|
|
10
11
|
}
|
|
11
12
|
export function createOpenStreetMapTileLayer(options) {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"OpenStreetMapTileLayer.js","sourceRoot":"","sources":["../../../../src/controls/leaflet/OpenStreetMapTileLayer/OpenStreetMapTileLayer.ts"],"names":[],"mappings":"AAAA,OAAO,EAAoB,SAAS,EAAE,MAAM,SAAS,CAAC;
|
|
1
|
+
{"version":3,"file":"OpenStreetMapTileLayer.js","sourceRoot":"","sources":["../../../../src/controls/leaflet/OpenStreetMapTileLayer/OpenStreetMapTileLayer.ts"],"names":[],"mappings":"AAAA,OAAO,EAAoB,SAAS,EAAE,MAAM,SAAS,CAAC;AAOtD,MAAM,OAAO,sBAAuB,SAAQ,SAAS;IACjD,YAAY,OAAwC;QAChD,IAAI,CAAC,OAAO,EAAE,CAAC;YACX,OAAO,GAAG,EAAE,CAAC;QACjB,CAAC;QACD,OAAO,CAAC,WAAW,GAAG,2FAA2F,CAAC;QAClH,MAAM,WAAW,GAAG,OAAO,CAAC,WAAW,IAAI,oDAAoD,CAAC;QAChG,KAAK,CAAC,WAAW,EAAE,OAAO,CAAC,CAAC;IAChC,CAAC;CACJ;AAED,MAAM,UAAU,4BAA4B,CAAC,OAAwC;IACjF,OAAO,IAAI,sBAAsB,CAAC,OAAO,CAAC,CAAC;AAC/C,CAAC"}
|
|
@@ -1,9 +1,10 @@
|
|
|
1
|
-
export type EventType = typeof Event | typeof UIEvent | typeof KeyboardEvent | typeof PointerEvent | typeof TouchEvent | typeof MouseEvent;
|
|
1
|
+
export type EventType = typeof Event | typeof UIEvent | typeof KeyboardEvent | typeof PointerEvent | typeof TouchEvent | typeof MouseEvent | typeof FocusEvent;
|
|
2
2
|
export type UiEventType = "load" | "unload" | "abort" | "error" | "select";
|
|
3
3
|
export type KeyboardEventType = "keydown" | "keyup" | "keypress";
|
|
4
4
|
export type PointerEventType = "click" | "pointerdown" | "pointerup" | "pointermove";
|
|
5
5
|
export type TouchEventType = "touchstart" | "touchend" | "touchmove" | "touchcancel";
|
|
6
6
|
export type MouseEventType = "contextmenu" | "dblclick" | "mousedown" | "mouseenter" | "mouseleave" | "mousemove" | "mouseout" | "mouseover" | "mouseup";
|
|
7
|
+
export type FocusEventType = "blur" | "focusout" | "focus" | "focusin";
|
|
7
8
|
export interface IEventListener extends AddEventListenerOptions, KeyboardEventInit {
|
|
8
9
|
type: EventType;
|
|
9
10
|
name: string;
|
|
@@ -16,6 +17,7 @@ export declare function createPointerEvent(name: PointerEventType, handler: (eve
|
|
|
16
17
|
export declare function createClickEvent(handler: (event: PointerEvent) => void): IEventListener;
|
|
17
18
|
export declare function createTouchEvent(name: TouchEventType, handler: (event: TouchEvent) => void): IEventListener;
|
|
18
19
|
export declare function createMouseEvent(name: MouseEventType, handler: (event: MouseEvent) => void): IEventListener;
|
|
20
|
+
export declare function createFocusEvent(name: FocusEventType, handler: (event: FocusEvent) => void): IEventListener;
|
|
19
21
|
interface ISwipeEventOptions {
|
|
20
22
|
leftHandler?: (event: TouchEvent) => void;
|
|
21
23
|
rightHandler?: (event: TouchEvent) => void;
|
package/dist/framework/event.js
CHANGED
|
@@ -26,6 +26,9 @@ export function createTouchEvent(name, handler) {
|
|
|
26
26
|
export function createMouseEvent(name, handler) {
|
|
27
27
|
return createEventListener(MouseEvent, name, handler);
|
|
28
28
|
}
|
|
29
|
+
export function createFocusEvent(name, handler) {
|
|
30
|
+
return createEventListener(FocusEvent, name, handler);
|
|
31
|
+
}
|
|
29
32
|
export function createSwipeEvent(options) {
|
|
30
33
|
let startX = 0;
|
|
31
34
|
let startY = 0;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"event.js","sourceRoot":"","sources":["../../src/framework/event.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"event.js","sourceRoot":"","sources":["../../src/framework/event.ts"],"names":[],"mappings":"AAmBA,SAAS,mBAAmB,CAAS,IAAe,EAAE,IAAY,EAAE,OAAgC;IAChG,OAAO;QACH,IAAI,EAAE,IAAI;QACV,IAAI,EAAE,IAAI;QACV,OAAO,EAAE,OAAO;KACnB,CAAC;AACN,CAAC;AAGD,MAAM,UAAU,WAAW,CAAS,IAAe,EAAE,IAAY,EAAE,OAAgC;IAC/F,OAAO,mBAAmB,CAAC,IAAI,EAAE,IAAI,EAAE,OAAO,CAAC,CAAC;AACpD,CAAC;AAGD,MAAM,UAAU,aAAa,CAAC,IAAiB,EAAE,OAAiC;IAC9E,OAAO,mBAAmB,CAAC,OAAO,EAAE,IAAI,EAAE,OAAO,CAAC,CAAC;AACvD,CAAC;AAGD,MAAM,UAAU,mBAAmB,CAAC,IAAuB,EAAE,OAAuC;IAChG,OAAO,mBAAmB,CAAC,aAAa,EAAE,IAAI,EAAE,OAAO,CAAC,CAAC;AAC7D,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CAAC,cAAc,CAAC,CAAC,CAAC,CAAC;YACtC,IAAI,GAAG,KAAK,CAAC,OAAO,CAAC;YACrB,IAAI,GAAG,KAAK,CAAC,OAAO,CAAC;YACrB,IAAI,MAAM,GAAG,IAAI,GAAG,QAAQ,EAAE,CAAC;gBAC3B,IAAI,OAAO,CAAC,WAAW,EAAE,CAAC;oBACtB,OAAO,CAAC,WAAW,CAAC,KAAK,CAAC,CAAC;gBAC/B,CAAC;YACL,CAAC;iBAAM,IAAI,IAAI,GAAG,MAAM,GAAG,QAAQ,EAAE,CAAC;gBAClC,IAAI,OAAO,CAAC,YAAY,EAAE,CAAC;oBACvB,OAAO,CAAC,YAAY,CAAC,KAAK,CAAC,CAAC;gBAChC,CAAC;YACL,CAAC;iBAAM,IAAI,MAAM,GAAG,IAAI,GAAG,QAAQ,EAAE,CAAC;gBAClC,IAAI,OAAO,CAAC,SAAS,EAAE,CAAC;oBACpB,OAAO,CAAC,SAAS,CAAC,KAAK,CAAC,CAAC;gBAC7B,CAAC;YACL,CAAC;iBAAM,IAAI,IAAI,GAAG,MAAM,GAAG,QAAQ,EAAE,CAAC;gBAClC,IAAI,OAAO,CAAC,WAAW,EAAE,CAAC;oBACtB,OAAO,CAAC,WAAW,CAAC,KAAK,CAAC,CAAC;gBAC/B,CAAC;YACL,CAAC;QACL,CAAC,CACJ;KACJ,CAAA;AACL,CAAC"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { TileLayerOptions, TileLayer } from "leaflet";
|
|
2
2
|
|
|
3
3
|
export interface IOpenStreetMapTileLayerOptions extends TileLayerOptions {
|
|
4
|
+
urlTemplate?: string
|
|
4
5
|
attribution?: string
|
|
5
6
|
}
|
|
6
7
|
|
|
@@ -10,7 +11,8 @@ export class OpenStreetMapTileLayer extends TileLayer {
|
|
|
10
11
|
options = {};
|
|
11
12
|
}
|
|
12
13
|
options.attribution = "© <a href=\"https://www.openstreetmap.org/copyright\">OpenStreetMap</a> contributors";
|
|
13
|
-
|
|
14
|
+
const urlTemplate = options.urlTemplate || "https://{s}.tile.openstreetmap.org/{z}/{x}/{y}.png";
|
|
15
|
+
super(urlTemplate, options);
|
|
14
16
|
}
|
|
15
17
|
}
|
|
16
18
|
|
package/src/framework/event.ts
CHANGED
|
@@ -1,12 +1,13 @@
|
|
|
1
1
|
import { key } from "../utilities";
|
|
2
2
|
|
|
3
|
-
export type EventType = typeof Event | typeof UIEvent | typeof KeyboardEvent | typeof PointerEvent | typeof TouchEvent | typeof MouseEvent;
|
|
3
|
+
export type EventType = typeof Event | typeof UIEvent | typeof KeyboardEvent | typeof PointerEvent | typeof TouchEvent | typeof MouseEvent | typeof FocusEvent;
|
|
4
4
|
|
|
5
5
|
export type UiEventType = "load" | "unload" | "abort" | "error" | "select";
|
|
6
6
|
export type KeyboardEventType = "keydown" | "keyup" | "keypress";
|
|
7
7
|
export type PointerEventType = "click" | "pointerdown" | "pointerup" | "pointermove";
|
|
8
8
|
export type TouchEventType = "touchstart" | "touchend" | "touchmove" | "touchcancel";
|
|
9
9
|
export type MouseEventType = "contextmenu" | "dblclick" | "mousedown" | "mouseenter" | "mouseleave" | "mousemove" | "mouseout" | "mouseover" | "mouseup";
|
|
10
|
+
export type FocusEventType = "blur" | "focusout" | "focus" | "focusin";
|
|
10
11
|
|
|
11
12
|
|
|
12
13
|
|
|
@@ -57,6 +58,10 @@ export function createMouseEvent(name: MouseEventType, handler: (event: MouseEve
|
|
|
57
58
|
return createEventListener(MouseEvent, name, handler);
|
|
58
59
|
}
|
|
59
60
|
|
|
61
|
+
export function createFocusEvent(name: FocusEventType, handler: (event: FocusEvent) => void): IEventListener {
|
|
62
|
+
return createEventListener(FocusEvent, name, handler);
|
|
63
|
+
}
|
|
64
|
+
|
|
60
65
|
|
|
61
66
|
interface ISwipeEventOptions {
|
|
62
67
|
leftHandler?: (event: TouchEvent) => void;
|