Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
19 changes: 18 additions & 1 deletion .vitepress/data/locales/en.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,8 @@ export const en: LocaleMessages = {
'<iconify-icon class="i-mr" icon="mdi:download" style="color:#2ecc71"></iconify-icon>Download',
about:
'<iconify-icon class="i-mr" icon="mdi:information" style="color:#9b59b6"></iconify-icon>About',
history:
'<iconify-icon class="i-mr" icon="mdi:history" style="color:#e67e22"></iconify-icon>History',
},

// Theme config
Expand All @@ -33,7 +35,7 @@ export const en: LocaleMessages = {
community: 'Community',
feedback: 'Issues',
discussions: 'Discussions',
beian: '',
beian: '京ICP备2025138063号',
copyright: 'MIT License.',
},

Expand Down Expand Up @@ -66,6 +68,21 @@ export const en: LocaleMessages = {
alsoDownload: 'Or download directly from:',
},

history: {
title: 'Historical Releases',
subtitle: 'Fetch historical releases and download links from GitHub.',
selectLabel: 'Select a release',
loading: 'Loading releases…',
error: 'Failed to load releases.',
retry: 'Retry',
empty: 'No historical releases found.',
noAssets: 'No downloadable assets for this release.',
noChangelog: 'No release notes available for this release.',
viewOnGithub: 'View on GitHub',
x64Label: 'Download X64',
arm64Label: 'Download ARM64',
},

// About page
about: {
title: 'PCL Community',
Expand Down
28 changes: 27 additions & 1 deletion .vitepress/data/locales/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ export interface LocaleMessages {
home: string;
download: string;
about: string;
history: string;
};
theme: {
prevPage: string;
Expand Down Expand Up @@ -61,6 +62,20 @@ export interface LocaleMessages {
historicalBtn: string;
alsoDownload: string;
};
history: {
title: string;
subtitle: string;
selectLabel: string;
loading: string;
error: string;
retry: string;
empty: string;
noAssets: string;
noChangelog: string;
viewOnGithub: string;
x64Label: string;
arm64Label: string;
};
about: {
title: string;
subtitle: string;
Expand Down Expand Up @@ -92,11 +107,13 @@ export const navTranslations: Record<
'zh-CN': [
{ text: zh.nav.home, link: '/' },
{ text: zh.nav.download, link: '/download' },
{ text: zh.nav.history, link: '/history' },
{ text: zh.nav.about, link: '/about' },
],
en: [
{ text: en.nav.home, link: '/en/' },
{ text: en.nav.download, link: '/en/download' },
{ text: en.nav.history, link: '/en/history' },
{ text: en.nav.about, link: '/en/about' },
],
};
Expand Down Expand Up @@ -152,6 +169,7 @@ export const themeConfigTranslations: Record<Lang, object> = {
// Footer 数据
export const getFooterData = (lang: Lang): FooterData => {
const msgs = getMessages(lang);
const beianNumber = msgs.footer.beian || zh.footer.beian;

const footerData: Record<Lang, FooterData> = {
'zh-CN': {
Expand Down Expand Up @@ -196,7 +214,7 @@ export const getFooterData = (lang: Lang): FooterData => {
beian: {
showIcon: true,
icp: {
number: msgs.footer.beian,
number: beianNumber,
link: 'https://beian.miit.gov.cn/',
rel: 'nofollow',
},
Expand Down Expand Up @@ -247,6 +265,14 @@ export const getFooterData = (lang: Lang): FooterData => {
],
},
],
beian: {
showIcon: true,
icp: {
number: beianNumber,
link: 'https://beian.miit.gov.cn/',
rel: 'nofollow',
},
},
author: {
name: 'PCL Community',
link: 'https://github.com/PCL-Community',
Expand Down
17 changes: 17 additions & 0 deletions .vitepress/data/locales/zh.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,8 @@ export const zh: LocaleMessages = {
'<iconify-icon class="i-mr" icon="mdi:download" style="color:#2ecc71"></iconify-icon>下载',
about:
'<iconify-icon class="i-mr" icon="mdi:information" style="color:#9b59b6"></iconify-icon>关于',
history:
'<iconify-icon class="i-mr" icon="mdi:history" style="color:#e67e22"></iconify-icon>历史版本',
},

// 主题配置
Expand Down Expand Up @@ -67,6 +69,21 @@ export const zh: LocaleMessages = {
alsoDownload: '你也可以直接在下方的链接中下载',
},

history: {
title: '历史版本下载',
subtitle: '选择版本查看更新日志并下载对应安装包。',
selectLabel: '选择版本',
loading: '正在获取版本列表…',
error: '获取失败,请稍后再试。',
retry: '重试',
empty: '暂无可用的历史版本。',
noAssets: '该版本暂无可用下载资源。',
noChangelog: '该版本没有更新日志描述。',
viewOnGithub: '在 GitHub 查看详情',
x64Label: '下载 X64',
arm64Label: '下载 ARM64',
},

// 关于页面
about: {
title: 'PCL Community',
Expand Down
3 changes: 1 addition & 2 deletions .vitepress/theme/components/AboutPage.vue
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,6 @@ const _props = defineProps<{
.about-card-link:hover {
border-color: var(--vp-c-brand-1);
box-shadow: 0 4px 16px rgba(2, 102, 193, 0.12);
transform: translateX(4px);
}

.about-card-icon {
Expand Down Expand Up @@ -150,4 +149,4 @@ const _props = defineProps<{
width: 100%;
}
}
</style>
</style>
Loading
Loading