forked from MapComplete/MapComplete
chore: automated housekeeping...
This commit is contained in:
parent
a0218253ce
commit
9ee3343426
154 changed files with 5959 additions and 3840 deletions
|
@ -1,30 +1,34 @@
|
|||
<script lang="ts">
|
||||
import { Utils } from "../Utils"
|
||||
import { Store, UIEventSource } from "../Logic/UIEventSource"
|
||||
import Loading from "./Base/Loading.svelte"
|
||||
import { OsmConnection } from "../Logic/Osm/OsmConnection"
|
||||
|
||||
import { Utils } from "../Utils"
|
||||
import { Store, UIEventSource } from "../Logic/UIEventSource"
|
||||
import Loading from "./Base/Loading.svelte"
|
||||
import { OsmConnection } from "../Logic/Osm/OsmConnection"
|
||||
|
||||
const osmConnection = new OsmConnection({
|
||||
attemptLogin: true
|
||||
})
|
||||
let loggedInContributor: Store<string> = osmConnection.userDetails.map(ud => ud.name)
|
||||
export let source = "https://raw.githubusercontent.com/pietervdvn/MapComplete-data/main/picture-leaderboard.json"
|
||||
let data: Store<undefined | {
|
||||
const osmConnection = new OsmConnection({
|
||||
attemptLogin: true,
|
||||
})
|
||||
let loggedInContributor: Store<string> = osmConnection.userDetails.map((ud) => ud.name)
|
||||
export let source =
|
||||
"https://raw.githubusercontent.com/pietervdvn/MapComplete-data/main/picture-leaderboard.json"
|
||||
let data: Store<
|
||||
| undefined
|
||||
| {
|
||||
leaderboard: {
|
||||
rank: number,
|
||||
name: string,
|
||||
account: string,
|
||||
nrOfImages: number
|
||||
}[],
|
||||
median: number,
|
||||
totalAuthors: number,
|
||||
rank: number
|
||||
name: string
|
||||
account: string
|
||||
nrOfImages: number
|
||||
}[]
|
||||
median: number
|
||||
totalAuthors: number
|
||||
byLicense: {
|
||||
license: string, total: number, authors: string[]
|
||||
},
|
||||
license: string
|
||||
total: number
|
||||
authors: string[]
|
||||
}
|
||||
date: string
|
||||
}> = UIEventSource.FromPromise(Utils.downloadJsonCached(source))
|
||||
|
||||
}
|
||||
> = UIEventSource.FromPromise(Utils.downloadJsonCached(source))
|
||||
</script>
|
||||
|
||||
<h1>Contributed images with MapComplete: leaderboard</h1>
|
||||
|
@ -43,13 +47,14 @@
|
|||
</td>
|
||||
<td>
|
||||
{#if $loggedInContributor === contributor.name}
|
||||
<a class="thanks" href="{contributor.account}">{contributor.name}</a>
|
||||
<a class="thanks" href={contributor.account}>{contributor.name}</a>
|
||||
{:else}
|
||||
<a href="{contributor.account}">{contributor.name}</a>
|
||||
<a href={contributor.account}>{contributor.name}</a>
|
||||
{/if}
|
||||
</td>
|
||||
<td>
|
||||
<b>{contributor.nrOfImages}</b> total images
|
||||
<b>{contributor.nrOfImages}</b>
|
||||
total images
|
||||
</td>
|
||||
</tr>
|
||||
{/each}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue