Skip to content

Commit

Permalink
1.0.9
Browse files Browse the repository at this point in the history
  • Loading branch information
github-actions[bot] committed Mar 2, 2024
1 parent ea38da2 commit 5be390c
Show file tree
Hide file tree
Showing 6 changed files with 169 additions and 3 deletions.
82 changes: 82 additions & 0 deletions dist/cjs/index.d.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,82 @@
import mapboxgl from "mapbox-gl";
import { PMTiles, Protocol } from "pmtiles";
export declare const SOURCE_TYPE = "pmtile-source";
declare class TileBounds {
bounds: mapboxgl.LngLatBounds;
minzoom: number;
maxzoom: number;
constructor(bounds: mapboxgl.LngLatBoundsLike, minzoom: number, maxzoom: number);
validateBounds(bounds: mapboxgl.LngLatBoundsLike): mapboxgl.LngLatBoundsLike;
contains(tileID: TileID): boolean;
}
type Callback<T> = (error: Error | null | undefined, result: T | null | undefined) => void;
type MapboxMap = mapboxgl.Map & {
_refreshExpiredTiles: any;
_requestManager: any;
painter: any;
};
type PmTilesOptions = {
url: string;
};
type Tile = {
request: any;
aborted: any;
resourceTiming: any;
setExpiryData(data: any): unknown;
loadVectorData(data: any, painter: any): unknown;
reloadCallback: any;
tileID: any;
uid: any;
tileZoom: any;
isSymbolTile: any;
isExtraShadowCaster: any;
actor: any;
state: string;
};
type TileID = {
z: number;
x: number;
y: number;
canonical: TileID;
};
export declare const PmTilesSource: {
new (args_0: string, args_1: PmTilesOptions, args_2: any, args_3: any): {
id: string;
scheme: string;
minzoom: number;
maxzoom: number;
tileSize: number;
attribution: string | undefined;
tiles: string[];
map: MapboxMap;
roundZoom: boolean;
tileBounds: TileBounds | undefined;
minTileCacheSize: number | undefined;
maxTileCacheSize: number | undefined;
promoteId: string | undefined;
type: string;
fire: Function | undefined;
scope: string | undefined;
dispatcher: any;
reparseOverscaled: boolean;
setEventedParent: any;
_loaded: boolean;
_tileWorkers: {
[string: string]: any;
};
_dataType: string;
_implementation: PmTilesOptions;
_protocol: Protocol;
_instance: PMTiles;
_collectResourceTiming: boolean;
_tileJSONRequest: Promise<any> | undefined;
hasTile(tileID: TileID): boolean;
load(callback?: Callback<void>): void;
loaded(): boolean;
loadTile(tile: Tile, callback: Callback<void>): void;
};
SOURCE_TYPE: string;
getMetadata(url: string): Promise<any>;
};
export default PmTilesSource;
//# sourceMappingURL=index.d.ts.map
1 change: 1 addition & 0 deletions dist/cjs/index.d.ts.map

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

82 changes: 82 additions & 0 deletions dist/esm/index.d.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,82 @@
import mapboxgl from "mapbox-gl";
import { PMTiles, Protocol } from "pmtiles";
export declare const SOURCE_TYPE = "pmtile-source";
declare class TileBounds {
bounds: mapboxgl.LngLatBounds;
minzoom: number;
maxzoom: number;
constructor(bounds: mapboxgl.LngLatBoundsLike, minzoom: number, maxzoom: number);
validateBounds(bounds: mapboxgl.LngLatBoundsLike): mapboxgl.LngLatBoundsLike;
contains(tileID: TileID): boolean;
}
type Callback<T> = (error: Error | null | undefined, result: T | null | undefined) => void;
type MapboxMap = mapboxgl.Map & {
_refreshExpiredTiles: any;
_requestManager: any;
painter: any;
};
type PmTilesOptions = {
url: string;
};
type Tile = {
request: any;
aborted: any;
resourceTiming: any;
setExpiryData(data: any): unknown;
loadVectorData(data: any, painter: any): unknown;
reloadCallback: any;
tileID: any;
uid: any;
tileZoom: any;
isSymbolTile: any;
isExtraShadowCaster: any;
actor: any;
state: string;
};
type TileID = {
z: number;
x: number;
y: number;
canonical: TileID;
};
export declare const PmTilesSource: {
new (args_0: string, args_1: PmTilesOptions, args_2: any, args_3: any): {
id: string;
scheme: string;
minzoom: number;
maxzoom: number;
tileSize: number;
attribution: string | undefined;
tiles: string[];
map: MapboxMap;
roundZoom: boolean;
tileBounds: TileBounds | undefined;
minTileCacheSize: number | undefined;
maxTileCacheSize: number | undefined;
promoteId: string | undefined;
type: string;
fire: Function | undefined;
scope: string | undefined;
dispatcher: any;
reparseOverscaled: boolean;
setEventedParent: any;
_loaded: boolean;
_tileWorkers: {
[string: string]: any;
};
_dataType: string;
_implementation: PmTilesOptions;
_protocol: Protocol;
_instance: PMTiles;
_collectResourceTiming: boolean;
_tileJSONRequest: Promise<any> | undefined;
hasTile(tileID: TileID): boolean;
load(callback?: Callback<void>): void;
loaded(): boolean;
loadTile(tile: Tile, callback: Callback<void>): void;
};
SOURCE_TYPE: string;
getMetadata(url: string): Promise<any>;
};
export default PmTilesSource;
//# sourceMappingURL=index.d.ts.map
1 change: 1 addition & 0 deletions dist/esm/index.d.ts.map

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "mapbox-pmtiles",
"version": "1.0.8",
"version": "1.0.9",
"type": "module",
"description": "A custom source to add PmTiles support to mapbox gl js",
"scripts": {
Expand Down

0 comments on commit 5be390c

Please sign in to comment.