fix: updating image file format to proper Vite style
This commit is contained in:
parent
b4143adc7c
commit
57d1d20467
2 changed files with 13 additions and 3 deletions
|
|
@ -3,13 +3,13 @@ export default {
|
||||||
{
|
{
|
||||||
"title": "What is Viossa?",
|
"title": "What is Viossa?",
|
||||||
"text": "Viossa is a community-created artificial pidgin language, created to simulate the formation of natural pidgin languages. Viossa is characterized by its lack of standardization, with each speaker developing a personal idiolect. Spelling and pronunciation can vary greatly, and serve as a form of personal self-expression. Viossa is learnt and taught entirely by immersion — translation is prohibited while learning.",
|
"text": "Viossa is a community-created artificial pidgin language, created to simulate the formation of natural pidgin languages. Viossa is characterized by its lack of standardization, with each speaker developing a personal idiolect. Spelling and pronunciation can vary greatly, and serve as a form of personal self-expression. Viossa is learnt and taught entirely by immersion — translation is prohibited while learning.",
|
||||||
"image": "/src/assets/flakka.png",
|
"image": "flakka.png",
|
||||||
"alt": "Flag of the Viossa Language"
|
"alt": "Flag of the Viossa Language"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"title": "History of Viossa",
|
"title": "History of Viossa",
|
||||||
"text": "Viossa began as a Skype group in 2014, created by members of the r/conlangs community on Reddit, as an experiment to simulate the formation of a pidgin language. Pidgins are simplified languages resulting from contact between populations with no shared common language. Unlike most pidgins, which usually have two to three contributor languages, Viossa comes from many diverse languages. This is because people from all around the world helped to contribute to Viossa's vocabulary.",
|
"text": "Viossa began as a Skype group in 2014, created by members of the r/conlangs community on Reddit, as an experiment to simulate the formation of a pidgin language. Pidgins are simplified languages resulting from contact between populations with no shared common language. Unlike most pidgins, which usually have two to three contributor languages, Viossa comes from many diverse languages. This is because people from all around the world helped to contribute to Viossa's vocabulary.",
|
||||||
"image": "/src/assets/flakka.png",
|
"image": "flakka.png",
|
||||||
"alt": "Flag of the Viossa Language"
|
"alt": "Flag of the Viossa Language"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
|
|
||||||
|
|
@ -7,7 +7,7 @@
|
||||||
|
|
||||||
<section class="section">
|
<section class="section">
|
||||||
<HomeSectionWrapper
|
<HomeSectionWrapper
|
||||||
v-for="(section, index) in sectionList"
|
v-for="(section, index) in sectionsWithImages"
|
||||||
:key="index"
|
:key="index"
|
||||||
:title="section.title"
|
:title="section.title"
|
||||||
:text="section.text"
|
:text="section.text"
|
||||||
|
|
@ -29,6 +29,16 @@ import { computed } from 'vue'
|
||||||
|
|
||||||
const { tm } = useI18n()
|
const { tm } = useI18n()
|
||||||
const sectionList = computed<MessageSchema['sections']>(() => tm('sections'))
|
const sectionList = computed<MessageSchema['sections']>(() => tm('sections'))
|
||||||
|
const sectionsWithImages = computed(() =>
|
||||||
|
sectionList.value.map(section => {
|
||||||
|
if (!section.image) return section
|
||||||
|
|
||||||
|
return {
|
||||||
|
...section,
|
||||||
|
image: new URL(`../assets/${section.image}`, import.meta.url).href
|
||||||
|
}
|
||||||
|
})
|
||||||
|
)
|
||||||
|
|
||||||
console.log(sectionList.value)
|
console.log(sectionList.value)
|
||||||
</script>
|
</script>
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue