Skip to content

Commit

Permalink
feat: docs-ci-cd
Browse files Browse the repository at this point in the history
  • Loading branch information
Majid committed Mar 10, 2024
1 parent a35aef4 commit ca13edb
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 17 deletions.
8 changes: 2 additions & 6 deletions docs-src/package-lock.json

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

1 change: 1 addition & 0 deletions docs-src/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@
"react": "^18.0.0",
"react-dom": "^18.0.0",
"typedoc": "^0.25.12",
"typedoc-plugin-markdown": "^3.17.1",
"typescript": "^5.4.2"
},
"devDependencies": {
Expand Down
12 changes: 1 addition & 11 deletions src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -163,7 +163,6 @@ export class PmTilesSource extends VectorTileSourceImpl {
_implementation;
_protocol: Protocol;
_instance: PMTiles;
_collectResourceTiming: boolean = false;
_tileJSONRequest: Promise<any> | undefined;
loadTile!: (tile: Tile, callback: Callback<void>) => void;
tileType!: TileType;
Expand Down Expand Up @@ -319,8 +318,6 @@ export class PmTilesSource extends VectorTileSourceImpl {
if (this.map?._refreshExpiredTiles && data) tile.setExpiryData(data);
tile.loadVectorData(data, this.map?.painter);

// cacheEntryPossiblyAdded(this.dispatcher);

callback(null);

if (tile.reloadCallback) {
Expand Down Expand Up @@ -352,17 +349,13 @@ export class PmTilesSource extends VectorTileSourceImpl {
// brightness: this.map.style ? (this.map.style.getBrightness() || 0.0) : 0.0,
extraShadowCaster: tile.isExtraShadowCaster,
};
// params.request.collectResourceTiming = this._collectResourceTiming;

const afterLoad = (error: any, data: any, cacheControl: any, expires: any) => {
if (error || !data) {
done.call(this, error);
return
}
// if (data.length == 0) {
// done.call(this, new Error("zero size data"));
// return
// }

params.data = {
cacheControl: cacheControl,
expires: expires,
Expand All @@ -385,15 +378,12 @@ export class PmTilesSource extends VectorTileSourceImpl {

tile.request = this._protocol.tile({ ...request }, afterLoad);
// always load tiles on the main thread and pass the result instead of requesting a worker to do so

} else if (tile.state === "loading") {
// schedule tile reloading after it has been loaded
tile.reloadCallback = callback;
} else {
debugger
tile.request = this._protocol.tile({ ...tile, url }, afterLoad);
}
console.log(url)
}

loadRasterTileData(tile: Tile, data: any): void {
Expand Down

0 comments on commit ca13edb

Please sign in to comment.