This commit is contained in:
a-ill 2023-07-21 18:07:22 +03:00
parent 909416fbe3
commit 117e924f66
4 changed files with 34 additions and 6 deletions

View File

@ -23,6 +23,12 @@ export let communes = [
status: "forming",
members: 1,
contact: ["https://discord.gg/Qk8KUk787z","DiscordInviteLink"]
},
{
location: [["Switzerland"],[46.97045202584917, 8.05130091516525]],
status: "forming",
members: 1,
contact: ["https://discord.gg/Qk8KUk787z","DiscordInviteLink"]
}
]
@ -39,6 +45,16 @@ for (let c of communes) {
export let communesMarkersLayer = L.layerGroup()
export function translate(content, x) {
let out = content[x]
if (out==undefined) {
return x
}
else {
return out
}
}
export function addMarkersCommunes(map,content,locale) {
for (let g of communes) {
let coordinates
@ -55,7 +71,7 @@ export function addMarkersCommunes(map,content,locale) {
locationString = location.map(x => x).join(", ")
}
else {
locationString = location.map(x => content[x]).join(", ")
locationString = location.map(x => translate(content, x)).join(", ")
}
text += fieldText + locationString + "<br>"

View File

@ -113,8 +113,6 @@ export function translate(content, x) {
}
}
function addMarkersToLayer(g,layer,content,locale) {
let coordinates
let text = "<b>"+content["Group"]+"</b><br>"

View File

@ -23,6 +23,12 @@ export let communes = [
status: "forming",
members: 1,
contact: ["https://discord.gg/Qk8KUk787z","DiscordInviteLink"]
},
{
location: [["Switzerland"],[46.97045202584917, 8.05130091516525]],
status: "forming",
members: 1,
contact: ["https://discord.gg/Qk8KUk787z","DiscordInviteLink"]
}
]
@ -39,6 +45,16 @@ for (let c of communes) {
export let communesMarkersLayer = L.layerGroup()
export function translate(content, x) {
let out = content[x]
if (out==undefined) {
return x
}
else {
return out
}
}
export function addMarkersCommunes(map,content,locale) {
for (let g of communes) {
let coordinates
@ -55,7 +71,7 @@ export function addMarkersCommunes(map,content,locale) {
locationString = location.map(x => x).join(", ")
}
else {
locationString = location.map(x => content[x]).join(", ")
locationString = location.map(x => translate(content, x)).join(", ")
}
text += fieldText + locationString + "<br>"

View File

@ -113,8 +113,6 @@ export function translate(content, x) {
}
}
function addMarkersToLayer(g,layer,content,locale) {
let coordinates
let text = "<b>"+content["Group"]+"</b><br>"