56 lines
1.6 KiB
Vue
56 lines
1.6 KiB
Vue
<script setup lang="ts">
|
|
import { newsContentBundle } from '~/data/news-content'
|
|
|
|
const content = useLocalized(newsContentBundle)
|
|
const { mediaItems } = useMediaCenter()
|
|
const { locale } = useSiteLocale()
|
|
|
|
const isZh = computed(() => locale.value === 'zh')
|
|
|
|
usePageSeo({
|
|
title: () =>
|
|
formatPageTitle(
|
|
isZh.value
|
|
? '媒体中心 | 中国医疗旅游导航'
|
|
: 'Media Center | Navigating Medical Tourism in China',
|
|
isZh.value ? 'zh' : 'en'
|
|
),
|
|
description: () =>
|
|
isZh.value
|
|
? '优医媒体中心——跨境医疗文章与视频,为国际患者提供来华就医参考。'
|
|
: 'UMedGlobal Media Center — articles and videos on cross-border healthcare for international patients.',
|
|
ogImage: '/images/cases-hero.png'
|
|
})
|
|
</script>
|
|
|
|
<template>
|
|
<div class="news-page">
|
|
<section v-if="mediaItems.length" class="section media-section">
|
|
<div class="container">
|
|
<template v-for="(item, i) in mediaItems" :key="item.mediaType + '-' + item.title + i">
|
|
<NewsCard
|
|
v-if="item.mediaType === 'article'"
|
|
:item="item"
|
|
:reverse="i % 2 === 1"
|
|
:read-original-label="content.readOriginalLabel"
|
|
/>
|
|
<VideoCard
|
|
v-else
|
|
:item="item"
|
|
:reverse="i % 2 === 1"
|
|
:watch-youtube-label="content.watchYoutubeLabel"
|
|
:watch-tiktok-label="content.watchTiktokLabel"
|
|
/>
|
|
</template>
|
|
</div>
|
|
</section>
|
|
</div>
|
|
</template>
|
|
|
|
<style scoped>
|
|
.media-section {
|
|
padding-top: 40px;
|
|
padding-bottom: 64px;
|
|
}
|
|
</style>
|