forked from MapComplete/MapComplete
Refactoring: port wikipedia panel to Svelte
This commit is contained in:
parent
24f7610d0a
commit
d8e14927c8
32 changed files with 362 additions and 847 deletions
|
@ -1,15 +1,11 @@
|
|||
import { Utils } from "../Utils"
|
||||
import Toggle from "./Input/Toggle"
|
||||
import LeftControls from "./BigComponents/LeftControls"
|
||||
import RightControls from "./BigComponents/RightControls"
|
||||
import CenterMessageBox from "./CenterMessageBox"
|
||||
import ScrollableFullScreen from "./Base/ScrollableFullScreen"
|
||||
import Translations from "./i18n/Translations"
|
||||
import { DefaultGuiState } from "./DefaultGuiState"
|
||||
import Combine from "./Base/Combine"
|
||||
import ExtraLinkButton from "./BigComponents/ExtraLinkButton"
|
||||
import GeoLocationHandler from "../Logic/Actors/GeoLocationHandler"
|
||||
import CopyrightPanel from "./BigComponents/CopyrightPanel"
|
||||
|
||||
/**
|
||||
* The default MapComplete GUI initializer
|
||||
|
@ -25,17 +21,6 @@ export default class DefaultGUI {
|
|||
}
|
||||
|
||||
public setup() {
|
||||
this.SetupUIElements()
|
||||
|
||||
if (
|
||||
this.state.layoutToUse.customCss !== undefined &&
|
||||
window.location.pathname.indexOf("index") >= 0
|
||||
) {
|
||||
Utils.LoadCustomCss(this.state.layoutToUse.customCss)
|
||||
}
|
||||
}
|
||||
|
||||
private SetupUIElements() {
|
||||
const extraLink = Toggle.If(
|
||||
state.featureSwitchExtraLinkEnabled,
|
||||
() => new ExtraLinkButton(state, state.layoutToUse.extraLink)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue