Refactored out 'layout.ts'

This commit is contained in:
Pieter Vander Vennet 2020-11-11 16:23:49 +01:00
parent 36f5e896df
commit 73f32e0ecf
30 changed files with 465 additions and 400 deletions

View file

@ -1,9 +1,9 @@
import {OsmConnection, UserDetails} from "./OsmConnection";
import {UIEventSource} from "../UIEventSource";
import {ElementStorage} from "../ElementStorage";
import {Layout} from "../../Customizations/Layout";
import State from "../../State";
import Locale from "../../UI/i18n/Locale";
import LayoutConfig from "../../Customizations/JSON/LayoutConfig";
export class ChangesetHandler {
@ -26,7 +26,7 @@ export class ChangesetHandler {
public UploadChangeset(
layout: Layout,
layout: LayoutConfig,
allElements: ElementStorage,
generateChangeXML: (csid: string) => string,
continuation: () => void) {
@ -85,10 +85,10 @@ export class ChangesetHandler {
private OpenChangeset(
layout : Layout,
layout : LayoutConfig,
continuation: (changesetId: string) => void) {
const commentExtra = layout.changesetMessage !== undefined ? " - " + layout.changesetMessage : "";
const commentExtra = layout.changesetmessage !== undefined ? " - " + layout.changesetmessage : "";
let surveySource = "";
if (State.state.currentGPSLocation.data !== undefined) {

View file

@ -3,10 +3,10 @@ import osmAuth from "osm-auth";
import {UIEventSource} from "../UIEventSource";
import {OsmPreferences} from "./OsmPreferences";
import {ChangesetHandler} from "./ChangesetHandler";
import {Layout} from "../../Customizations/Layout";
import {ElementStorage} from "../ElementStorage";
import {Img} from "../../UI/Img";
import Svg from "../../Svg";
import LayoutConfig from "../../Customizations/JSON/LayoutConfig";
export class UserDetails {
@ -97,7 +97,7 @@ export class OsmConnection {
public UploadChangeset(
layout: Layout,
layout: LayoutConfig,
allElements: ElementStorage,
generateChangeXML: (csid: string) => string,
continuation: () => void = () => {}) {