fix: accessibility issues with footer links, optimize footer link handling logic

This commit is contained in:
radishzzz 2025-05-19 00:58:53 +01:00
parent a27cdcb7f9
commit 96fba2d473
8 changed files with 52 additions and 44 deletions

View file

@ -16,7 +16,15 @@ const links = socialLinks.map((link) => {
if (link.name === 'RSS') { if (link.name === 'RSS') {
return { return {
...link, ...link,
url: currentLang === defaultLocale ? link.url : `/${currentLang}${link.url}`, url: currentLang === defaultLocale
? link.url
: `/${currentLang}${link.url}`,
}
}
if (link.name === 'Email') {
return {
...link,
url: `mailto:${link.url}`,
} }
} }
return link return link

View file

@ -141,16 +141,16 @@ export const themeConfig: ThemeConfig = {
url: 'https://github.com/radishzzz/astro-theme-retypeset', url: 'https://github.com/radishzzz/astro-theme-retypeset',
}, },
{ {
name: 'X', name: 'Email',
url: 'https://x.com/radishzz_', url: 'email@radishzz.cc',
}, }
// { // {
// name: 'Email', // name: 'X',
// url: 'https://example@gmail.com', // url: 'https://x.com/radishzz_',
// } // },
], ],
// year of website start // year of website start
startYear: 2024, startYear: 2025,
}, },
// FOOTER SETTINGS >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> END // FOOTER SETTINGS >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> END

View file

@ -165,13 +165,13 @@ footer: {
url: 'https://github.com/radishzzz/astro-theme-retypeset', url: 'https://github.com/radishzzz/astro-theme-retypeset',
}, },
{ {
name: 'X', name: 'Email',
url: 'https://x.com/radishzz_', url: 'email@radishzz.cc',
}, }
// { // {
// name: 'Email', // name: 'X',
// url: 'https://example@gmail.com', // url: 'https://x.com/radishzz_',
// } // },
] ]
// year of website start // year of website start
startYear: 2024 startYear: 2024

View file

@ -165,13 +165,13 @@ footer: {
url: 'https://github.com/radishzzz/astro-theme-retypeset', url: 'https://github.com/radishzzz/astro-theme-retypeset',
}, },
{ {
name: 'X', name: 'Email',
url: 'https://x.com/radishzz_', url: 'email@radishzz.cc',
}, }
// { // {
// name: 'Email', // name: 'X',
// url: 'https://example@gmail.com', // url: 'https://x.com/radishzz_',
// } // },
] ]
// año de inicio del sitio web // año de inicio del sitio web
startYear: 2024 startYear: 2024

View file

@ -165,13 +165,13 @@ footer: {
url: 'https://github.com/radishzzz/astro-theme-retypeset', url: 'https://github.com/radishzzz/astro-theme-retypeset',
}, },
{ {
name: 'X', name: 'Email',
url: 'https://x.com/radishzz_', url: 'email@radishzz.cc',
}, }
// { // {
// name: 'Email', // name: 'X',
// url: 'https://example@gmail.com', // url: 'https://x.com/radishzz_',
// } // },
] ]
// サイト開始年 // サイト開始年
startYear: 2024 startYear: 2024

View file

@ -165,13 +165,13 @@ footer: {
url: 'https://github.com/radishzzz/astro-theme-retypeset', url: 'https://github.com/radishzzz/astro-theme-retypeset',
}, },
{ {
name: 'X', name: 'Email',
url: 'https://x.com/radishzz_', url: 'email@radishzz.cc',
}, }
// { // {
// name: 'Email', // name: 'X',
// url: 'https://example@gmail.com', // url: 'https://x.com/radishzz_',
// } // },
] ]
// год начала работы веб-сайта // год начала работы веб-сайта
startYear: 2024 startYear: 2024

View file

@ -165,13 +165,13 @@ footer: {
url: 'https://github.com/radishzzz/astro-theme-retypeset', url: 'https://github.com/radishzzz/astro-theme-retypeset',
}, },
{ {
name: 'X', name: 'Email',
url: 'https://x.com/radishzz_', url: 'email@radishzz.cc',
}, }
// { // {
// name: 'Email', // name: 'X',
// url: 'https://example@gmail.com', // url: 'https://x.com/radishzz_',
// } // },
] ]
// 建站年份 // 建站年份
startYear: 2024 startYear: 2024

View file

@ -165,13 +165,13 @@ footer: {
url: 'https://github.com/radishzzz/astro-theme-retypeset', url: 'https://github.com/radishzzz/astro-theme-retypeset',
}, },
{ {
name: 'X', name: 'Email',
url: 'https://x.com/radishzz_', url: 'email@radishzz.cc',
}, }
// { // {
// name: 'Email', // name: 'X',
// url: 'https://example@gmail.com', // url: 'https://x.com/radishzz_',
// } // },
] ]
// 建站年份 // 建站年份
startYear: 2024 startYear: 2024