Skip to content

Commit

Permalink
formatting
Browse files Browse the repository at this point in the history
  • Loading branch information
bdon committed Mar 11, 2024
1 parent 56d7354 commit 63628e2
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 2 deletions.
2 changes: 1 addition & 1 deletion src/frontends/leaflet.ts
Original file line number Diff line number Diff line change
Expand Up @@ -275,7 +275,7 @@ const leafletLayer = (options: LeafletLayerOptions = {}): unknown => {
public queryTileFeaturesDebug(
lng: number,
lat: number,
brushSize: number = 16
brushSize = 16,
): Map<string, PickedFeature[]> {
const featuresBySourceName = new Map<string, PickedFeature[]>();
for (const [sourceName, view] of this.views) {
Expand Down
7 changes: 6 additions & 1 deletion src/view.ts
Original file line number Diff line number Diff line change
Expand Up @@ -215,7 +215,12 @@ export class View {
};
}

public queryFeatures(lng: number, lat: number, displayZoom: number, brushSize: number) {
public queryFeatures(
lng: number,
lat: number,
displayZoom: number,
brushSize: number,
) {
const roundedZoom = Math.round(displayZoom);
const dataZoom = Math.min(roundedZoom - this.levelDiff, this.maxDataLevel);
const brushSizeAtZoom = brushSize / (1 << (roundedZoom - dataZoom));
Expand Down

0 comments on commit 63628e2

Please sign in to comment.