forked from MapComplete/MapComplete
		
	Fix typings
This commit is contained in:
		
							parent
							
								
									728f526b61
								
							
						
					
					
						commit
						28fc81c96f
					
				
					 4 changed files with 12 additions and 9 deletions
				
			
		| 
						 | 
				
			
			@ -26,6 +26,7 @@ import BaseLayer from "../../Models/BaseLayer"
 | 
			
		|||
import Loading from "../Base/Loading"
 | 
			
		||||
import Hash from "../../Logic/Web/Hash"
 | 
			
		||||
import { GlobalFilter } from "../../Logic/State/MapState"
 | 
			
		||||
import {WayId} from "../../Models/OsmFeature";
 | 
			
		||||
 | 
			
		||||
/*
 | 
			
		||||
 * The SimpleAddUI is a single panel, which can have multiple states:
 | 
			
		||||
| 
						 | 
				
			
			@ -123,13 +124,13 @@ export default class SimpleAddUI extends Toggle {
 | 
			
		|||
                function confirm(
 | 
			
		||||
                    tags: any[],
 | 
			
		||||
                    location: { lat: number; lon: number },
 | 
			
		||||
                    snapOntoWayId?: string
 | 
			
		||||
                    snapOntoWayId?: WayId
 | 
			
		||||
                ) {
 | 
			
		||||
                    if (snapOntoWayId === undefined) {
 | 
			
		||||
                        createNewPoint(tags, location, undefined)
 | 
			
		||||
                    } else {
 | 
			
		||||
                        OsmObject.DownloadObject(snapOntoWayId).addCallbackAndRunD((way) => {
 | 
			
		||||
                            createNewPoint(tags, location, <OsmWay>way)
 | 
			
		||||
                            createNewPoint(tags, location, way)
 | 
			
		||||
                            return true
 | 
			
		||||
                        })
 | 
			
		||||
                    }
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue