|
|
@ -1,29 +1,38 @@
|
|
|
|
/////// Make the website //////
|
|
|
|
/////// Make the website //////
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
function voices(voices) {
|
|
|
|
fetch("glossary.json").then(response => response.json()).then(data => glossary = data).then(()=>{
|
|
|
|
return `
|
|
|
|
|
|
|
|
${voices.map((voice) => `<p>${voice}</p>`).join("")}
|
|
|
|
function voices(voices) {
|
|
|
|
`
|
|
|
|
return `
|
|
|
|
}
|
|
|
|
${voices.map((voice) => `<p>${voice}</p>`).join("")}
|
|
|
|
|
|
|
|
`
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
function links(links) {
|
|
|
|
|
|
|
|
return `
|
|
|
|
|
|
|
|
${links.map((links) => `<p><a href="${links}">⤴︎</a></p>`).join("")}
|
|
|
|
|
|
|
|
`
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
function wordTemplate(word) {
|
|
|
|
|
|
|
|
return `
|
|
|
|
|
|
|
|
<div class="${word.properties.join(' ')}">
|
|
|
|
|
|
|
|
<h1 id="${word.title}"class="title">${word.title}</h1>
|
|
|
|
|
|
|
|
${voices(word.voices)}
|
|
|
|
|
|
|
|
${links(word.links)}
|
|
|
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
`
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
document.getElementById("words").innerHTML = `${glossary.map(wordTemplate).join("")}`
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
console.log(glossary)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
}); ///// END OF FETCH!!!!!!
|
|
|
|
|
|
|
|
|
|
|
|
function links(links) {
|
|
|
|
|
|
|
|
return `
|
|
|
|
|
|
|
|
${links.map((links) => `<p><a href="${links}">⤴︎</a></p>`).join("")}
|
|
|
|
|
|
|
|
`
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
function wordTemplate(word) {
|
|
|
|
|
|
|
|
return `
|
|
|
|
|
|
|
|
<div class="${word.properties.join(' ')}">
|
|
|
|
|
|
|
|
<h1 id="${word.title}"class="title">${word.title}</h1>
|
|
|
|
|
|
|
|
${voices(word.voices)}
|
|
|
|
|
|
|
|
${links(word.links)}
|
|
|
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
`
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
document.getElementById("words").innerHTML = `${glossary.map(wordTemplate).join("")}`
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|