forked from MapComplete/MapComplete
		
	Merge develop
This commit is contained in:
		
						commit
						29ff09024f
					
				
					 287 changed files with 14955 additions and 4036 deletions
				
			
		| 
						 | 
				
			
			@ -17,6 +17,7 @@
 | 
			
		|||
  export let state: SpecialVisualizationState
 | 
			
		||||
 | 
			
		||||
  export let tags: Store<OsmTags>
 | 
			
		||||
  export let targetKey: string = undefined
 | 
			
		||||
  /**
 | 
			
		||||
   * Image to show in the button
 | 
			
		||||
   * NOT the image to upload!
 | 
			
		||||
| 
						 | 
				
			
			@ -35,7 +36,7 @@
 | 
			
		|||
      const file = files.item(i)
 | 
			
		||||
      console.log("Got file", file.name)
 | 
			
		||||
      try {
 | 
			
		||||
        state.imageUploadManager?.uploadImageAndApply(file, tags)
 | 
			
		||||
        state?.imageUploadManager.uploadImageAndApply(file, tags, targetKey)
 | 
			
		||||
      } catch (e) {
 | 
			
		||||
        alert(e)
 | 
			
		||||
      }
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
| 
						 | 
				
			
			@ -1,24 +1,24 @@
 | 
			
		|||
<script lang="ts">
 | 
			
		||||
    /**
 | 
			
		||||
     * Shows information about how much images are uploaded for the given feature
 | 
			
		||||
     *
 | 
			
		||||
     * Either pass in a store with tags or a featureId.
 | 
			
		||||
     */
 | 
			
		||||
  /**
 | 
			
		||||
   * Shows information about how much images are uploaded for the given feature
 | 
			
		||||
   *
 | 
			
		||||
   * Either pass in a store with tags or a featureId.
 | 
			
		||||
   */
 | 
			
		||||
 | 
			
		||||
    import type { SpecialVisualizationState } from "../SpecialVisualization"
 | 
			
		||||
    import { Store } from "../../Logic/UIEventSource"
 | 
			
		||||
    import type { OsmTags } from "../../Models/OsmFeature"
 | 
			
		||||
    import Translations from "../i18n/Translations"
 | 
			
		||||
    import Tr from "../Base/Tr.svelte"
 | 
			
		||||
    import Loading from "../Base/Loading.svelte"
 | 
			
		||||
  import type { SpecialVisualizationState } from "../SpecialVisualization"
 | 
			
		||||
  import { Store } from "../../Logic/UIEventSource"
 | 
			
		||||
  import type { OsmTags } from "../../Models/OsmFeature"
 | 
			
		||||
  import Translations from "../i18n/Translations"
 | 
			
		||||
  import Tr from "../Base/Tr.svelte"
 | 
			
		||||
  import Loading from "../Base/Loading.svelte"
 | 
			
		||||
 | 
			
		||||
    export let state: SpecialVisualizationState
 | 
			
		||||
    export let tags: Store<OsmTags>
 | 
			
		||||
    export let featureId = tags.data.id
 | 
			
		||||
    export let showThankYou: boolean = true
 | 
			
		||||
    const { uploadStarted, uploadFinished, retried, failed } =
 | 
			
		||||
        state.imageUploadManager.getCountsFor(featureId)
 | 
			
		||||
    const t = Translations.t.image
 | 
			
		||||
  export let state: SpecialVisualizationState
 | 
			
		||||
  export let tags: Store<OsmTags>
 | 
			
		||||
  export let featureId = tags.data.id
 | 
			
		||||
  export let showThankYou: boolean = true
 | 
			
		||||
  const { uploadStarted, uploadFinished, retried, failed } =
 | 
			
		||||
    state.imageUploadManager.getCountsFor(featureId)
 | 
			
		||||
  const t = Translations.t.image
 | 
			
		||||
</script>
 | 
			
		||||
 | 
			
		||||
{#if $uploadStarted === 1}
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue