forked from MapComplete/MapComplete
		
	Chore: housekeeping: lint
This commit is contained in:
		
							parent
							
								
									2cbd709d71
								
							
						
					
					
						commit
						663b194247
					
				
					 334 changed files with 4675 additions and 1730 deletions
				
			
		|  | @ -1,30 +1,28 @@ | |||
| <script lang="ts"> | ||||
|   import { UIEventSource } from "../../Logic/UIEventSource"; | ||||
|   import { OsmConnection } from "../../Logic/Osm/OsmConnection"; | ||||
|   import Marker from "../Map/Marker.svelte"; | ||||
|   import NextButton from "../Base/NextButton.svelte"; | ||||
|   import { AllKnownLayouts } from "../../Customizations/AllKnownLayouts"; | ||||
|   import { AllSharedLayers } from "../../Customizations/AllSharedLayers"; | ||||
|   import { createEventDispatcher } from "svelte"; | ||||
|   import { UIEventSource } from "../../Logic/UIEventSource" | ||||
|   import { OsmConnection } from "../../Logic/Osm/OsmConnection" | ||||
|   import Marker from "../Map/Marker.svelte" | ||||
|   import NextButton from "../Base/NextButton.svelte" | ||||
|   import { AllKnownLayouts } from "../../Customizations/AllKnownLayouts" | ||||
|   import { AllSharedLayers } from "../../Customizations/AllSharedLayers" | ||||
|   import { createEventDispatcher } from "svelte" | ||||
| 
 | ||||
|   export let info: { id: string; owner: number }; | ||||
|   export let category: "layers" | "themes"; | ||||
|   export let osmConnection: OsmConnection; | ||||
|   const dispatch = createEventDispatcher<{ layerSelected: string }>(); | ||||
|   export let info: { id: string; owner: number } | ||||
|   export let category: "layers" | "themes" | ||||
|   export let osmConnection: OsmConnection | ||||
|   const dispatch = createEventDispatcher<{ layerSelected: string }>() | ||||
| 
 | ||||
|   let displayName = UIEventSource.FromPromise( | ||||
|     osmConnection.getInformationAboutUser(info.owner) | ||||
|   ).mapD((response) => response.display_name); | ||||
|   let selfId = osmConnection.userDetails.mapD((ud) => ud.uid); | ||||
| 
 | ||||
|   ).mapD((response) => response.display_name) | ||||
|   let selfId = osmConnection.userDetails.mapD((ud) => ud.uid) | ||||
| 
 | ||||
|   function fetchIconDescription(layerId): any { | ||||
|     if (category === "themes") { | ||||
|       return AllKnownLayouts.allKnownLayouts.get(layerId).icon; | ||||
|       return AllKnownLayouts.allKnownLayouts.get(layerId).icon | ||||
|     } | ||||
|     return AllSharedLayers.getSharedLayersConfigs().get(layerId)?._layerIcon; | ||||
|     return AllSharedLayers.getSharedLayersConfigs().get(layerId)?._layerIcon | ||||
|   } | ||||
| 
 | ||||
| </script> | ||||
| 
 | ||||
| <NextButton clss="small" on:click={() => dispatch("layerSelected", info)}> | ||||
|  | @ -39,7 +37,7 @@ | |||
|         - {info.owner} | ||||
|       {/if} | ||||
|       ) | ||||
|     {:else } | ||||
|     {:else} | ||||
|       ({info.owner}) | ||||
|     {/if} | ||||
|   {/if} | ||||
|  |  | |||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue