Add bigger zoom-in and zoom-out button, move attribution to button on small screens

This commit is contained in:
Pieter Vander Vennet 2021-02-21 03:38:12 +01:00
parent 2572e99b95
commit 604d7863fe
13 changed files with 142 additions and 66 deletions

20
UI/MapControlButton.ts Normal file
View file

@ -0,0 +1,20 @@
import {UIElement} from "./UIElement";
/**
* A button floating above the map, in a uniform style
*/
export default class MapControlButton extends UIElement {
private _contents: UIElement;
constructor(contents: UIElement) {
super();
this._contents = contents;
this.SetClass("relative block rounded-full w-10 h-10 p-1 pointer-events-auto z-above-map subtle-background")
this.SetStyle("box-shadow: 0 0 10px var(--shadow-color);");
}
InnerRender(): string {
return this._contents.Render();
}
}