Use OSM-settings to keep track of the chosen license; change tree marker to circle (fix #24)

This commit is contained in:
Pieter Vander Vennet 2020-07-01 17:38:48 +02:00
parent b2704d0ab8
commit b1775d8184
15 changed files with 83 additions and 57 deletions

View file

@ -3,6 +3,7 @@ import {UserDetails} from "../Logic/OsmConnection";
import {UIEventSource} from "./UIEventSource";
import {Basemap} from "../Logic/Basemap";
import L from "leaflet";
import {FixedUiElement} from "./Base/FixedUiElement";
/**
* Handles and updates the user badge
@ -10,6 +11,7 @@ import L from "leaflet";
export class UserBadge extends UIElement {
private _userDetails: UIEventSource<UserDetails>;
private _pendingChanges: UIElement;
private _logout: UIElement;
private _basemap: Basemap;
@ -20,6 +22,9 @@ export class UserBadge extends UIElement {
this._userDetails = userDetails;
this._pendingChanges = pendingChanges;
this._basemap = basemap;
this._logout = new FixedUiElement("<img src='assets/logout.svg' alt='logout'>")
.onClick(() => {userDetails.data.osmConnection.LogOut();});
userDetails.addCallback(function () {
const profilePic = document.getElementById("profile-pic");