分享按钮调整

This commit is contained in:
tangly1024.com
2023-04-26 16:19:51 +08:00
parent d44edb2d85
commit 262dca3251
2 changed files with 7 additions and 7 deletions

View File

@@ -12,7 +12,7 @@ const ShareBar = ({ post }) => {
const shareUrl = BLOG.LINK + router.asPath
return <div className='py-1 flex'>
return <div className='py-1 flex overflow-x-auto'>
<ShareButtons shareUrl={shareUrl} title={post.title} image={post.pageCover} body={
post.title +
' | ' +

View File

@@ -333,16 +333,16 @@ const ShareButtons = ({ shareUrl, title, body, image }) => {
)
}
if (singleService === 'qq') {
return <button key={singleService} className='cursor-pointer w-8 h-8 bg-blue-600 text-white rounded-full mx-1'>
return <button key={singleService} className='cursor-pointer bg-blue-600 text-white rounded-full mx-1'>
<div target='_blank' rel='noreferrer' href={`http://connect.qq.com/widget/shareqq/index.html?url=${shareUrl}&sharesource=qzone&title=${title}&desc=${body}`} >
<i className='fab fa-qq' />
<i className='fab fa-qq w-8' />
</div>
</button>
}
if (singleService === 'wechat') {
return <button onMouseEnter={openPopover} onMouseLeave={closePopover} aria-label={singleService} key={singleService} className='relative cursor-pointer w-8 h-8 bg-green-600 text-white rounded-full mx-1'>
return <button onMouseEnter={openPopover} onMouseLeave={closePopover} aria-label={singleService} key={singleService} className='relative cursor-pointer bg-green-600 text-white rounded-full mx-1'>
<div id='wechat-button'>
<i className='fab fa-weixin' />
<i className='fab fa-weixin w-8' />
</div>
<div id='pop' className={(qrCodeShow ? 'opacity-100 ' : ' invisible opacity-0') + ' z-40 absolute bottom-10 -left-10 bg-white shadow-xl transition-all duration-200 text-center'}>
<div className='p-2 mt-1'>
@@ -355,9 +355,9 @@ const ShareButtons = ({ shareUrl, title, body, image }) => {
</button>
}
if (singleService === 'link') {
return <button aria-label={singleService} key={singleService} className='cursor-pointer w-8 h-8 bg-yellow-500 text-white rounded-full mx-1'>
return <button aria-label={singleService} key={singleService} className='cursor-pointer bg-yellow-500 text-white rounded-full mx-1'>
<div alt={locale.COMMON.URL_COPIED} onClick={copyUrl} >
<i className='fas fa-link' />
<i className='fas fa-link w-8' />
</div>
</button>
}