From 15fbc51651587f86573ca18231796eb0e5712550 Mon Sep 17 00:00:00 2001 From: UncleBill Date: Wed, 17 May 2023 13:14:11 +0800 Subject: [PATCH] fix: mf-4181 add padding bottom for RSS3 feed detail dialog (#9618) --- .../components/DetailsDialog/index.tsx | 64 ++++++++++--------- 1 file changed, 34 insertions(+), 30 deletions(-) diff --git a/packages/plugins/RSS3/src/SNSAdaptor/components/DetailsDialog/index.tsx b/packages/plugins/RSS3/src/SNSAdaptor/components/DetailsDialog/index.tsx index 368b2726fc7..586ba02bbcd 100644 --- a/packages/plugins/RSS3/src/SNSAdaptor/components/DetailsDialog/index.tsx +++ b/packages/plugins/RSS3/src/SNSAdaptor/components/DetailsDialog/index.tsx @@ -18,17 +18,19 @@ const useStyles = makeStyles()((theme) => ({ content: { display: 'flex', flexDirection: 'column', - paddingRight: 15, + paddingBottom: theme.spacing(3), + }, + details: { + overflow: 'auto', + display: 'flex', + flexDirection: 'column', '::-webkit-scrollbar': { - backgroundColor: 'transparent', - width: 5, - }, - '::-webkit-scrollbar-thumb': { - borderRadius: '5px', - width: 5, - border: '5px solid transparent', - backgroundColor: theme.palette.maskColor.secondaryLine, + display: 'none', }, + '::-webkit-scrollbar-thumb': {}, + }, + card: { + flexGrow: 1, }, links: { display: 'flex', @@ -76,27 +78,29 @@ export function FeedDetailsDialog({ type, feed, onClose, actionIndex, onSubmit, onSubmit?.() }}> - - {links?.length ? ( -
- {links.map((link, index) => { - let host = '' - try { - const url = new URL(link) - if (!['http:', 'https:'].includes(url.protocol)) return null - host = url.host - } catch {} - const Icon = hostIconMap[host] ?? Icons.SettingsLanguage - const name = hostNameMap[host] ?? host - return ( - - - {name} - - ) - })} -
- ) : null} +
+ + {links?.length ? ( +
+ {links.map((link, index) => { + let host = '' + try { + const url = new URL(link) + if (!['http:', 'https:'].includes(url.protocol)) return null + host = url.host + } catch {} + const Icon = hostIconMap[host] ?? Icons.SettingsLanguage + const name = hostNameMap[host] ?? host + return ( + + + {name} + + ) + })} +
+ ) : null} +
)