Skip to content

Commit

Permalink
this didnt work as good as i wanted. oh well
Browse files Browse the repository at this point in the history
  • Loading branch information
BillyGalbreath committed Jun 2, 2024
1 parent 7c2dbf2 commit 4270510
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 8 deletions.
6 changes: 3 additions & 3 deletions web/src/layer/LiveTileLayer.ts
Original file line number Diff line number Diff line change
Expand Up @@ -59,12 +59,12 @@ export class LiveTileLayer extends L.TileLayer {

_tileOnLoad(done: L.DoneCallback, tile: HTMLElement): void {
super._tileOnLoad(done, tile);
tile.setAttribute('loaded', 'true');
//tile.setAttribute('loaded', 'true');
}

_tileOnError(done: L.DoneCallback, tile: HTMLElement, e: Error): void {
super._tileOnError(done, tile, e);
tile.setAttribute('loaded', 'false');
//tile.setAttribute('loaded', 'false');
}

// @method createTile(coords: Object, done?: Function): HTMLElement
Expand All @@ -73,7 +73,7 @@ export class LiveTileLayer extends L.TileLayer {
// callback is called when the tile has been loaded.
createTile(coords: L.Coords, done: L.DoneCallback): HTMLImageElement {
const tile: HTMLImageElement = L.DomUtil.create('img');
tile.setAttribute('loaded', 'false');
//tile.setAttribute('loaded', 'false');

L.DomEvent.on(tile, 'load', L.Util.bind(this._tileOnLoad, this, done, tile));
L.DomEvent.on(tile, 'error', L.Util.bind(this._tileOnError, this, done, tile));
Expand Down
5 changes: 0 additions & 5 deletions web/src/scss/livemap.scss
Original file line number Diff line number Diff line change
Expand Up @@ -6,15 +6,10 @@
cursor: grabbing;
}

img.leaflet-tile[loaded='false'] {
opacity: 0;
}

img.leaflet-tile {
image-rendering: pixelated;
image-rendering: -moz-crisp-edges;
border: 0 !important;
opacity: 1;

/* See: https://github.com/GoogleChrome/lighthouse/issues/15497#issuecomment-2047385179 */
mix-blend-mode: color-dodge !important;
Expand Down

0 comments on commit 4270510

Please sign in to comment.