Skip to content

Commit 304d5b6

Browse files
fix(heo): prevent music player from overlapping footer (#4291)
* fix(heo): prevent music player from overlapping footer * fix(heo): use class for footer player spacing --------- Co-authored-by: tangly1024 <mail@tangly1024.com>
1 parent 08481aa commit 304d5b6

1 file changed

Lines changed: 8 additions & 2 deletions

File tree

themes/heo/components/Footer.js

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,8 @@ const Footer = () => {
1111
const BEI_AN = siteConfig('BEI_AN')
1212
const BEI_AN_LINK = siteConfig('BEI_AN_LINK')
1313
const BIO = siteConfig('BIO')
14+
const reserveMusicPlayerSpace =
15+
siteConfig('MUSIC_PLAYER') && siteConfig('MUSIC_PLAYER_VISIBLE')
1416
return (
1517
<footer className='relative flex-shrink-0 bg-[var(--heo-color-card)] dark:bg-[var(--heo-color-bg-dark)] justify-center text-center m-auto w-full leading-6 text-gray-600 dark:text-gray-100 text-sm'>
1618
{/* 颜色过度区 */}
@@ -29,14 +31,18 @@ const Footer = () => {
2931
{/* 底部页面信息 */}
3032
<div
3133
id='footer-bottom'
32-
className='w-full h-20 flex flex-col p-3 lg:flex-row justify-between px-6 items-center bg-[#f1f3f7] dark:bg-[#21232A] border-t dark:border-t-[#3D3D3F]'>
34+
className={`w-full min-h-20 flex flex-col p-3 lg:flex-row justify-between px-6 items-center bg-[#f1f3f7] dark:bg-[#21232A] border-t dark:border-t-[#3D3D3F] ${
35+
reserveMusicPlayerSpace ? 'pb-20' : ''
36+
}`}
37+
>
3338
<div id='footer-bottom-left' className='text-center lg:text-start'>
3439
<PoweredBy />
3540
<div className='flex gap-x-1'>
3641
<CopyRightDate />
3742
<a
3843
href={'/about'}
39-
className='underline font-semibold dark:text-gray-300 '>
44+
className='underline font-semibold dark:text-gray-300 '
45+
>
4046
{siteConfig('AUTHOR')}
4147
</a>
4248
{BIO && <span className='mx-1'> | {BIO}</span>}

0 commit comments

Comments
 (0)