style: overflow layer padding
This commit is contained in:
@@ -1,7 +1,6 @@
|
||||
import { useIntl } from '@umijs/max';
|
||||
import React from 'react';
|
||||
import styled from 'styled-components';
|
||||
import OverlayScroller from '../overlay-scroller';
|
||||
|
||||
const UL = styled.ul`
|
||||
list-style: none;
|
||||
@@ -31,25 +30,23 @@ const TooltipList: React.FC<TooltipListProps> = (props) => {
|
||||
const intl = useIntl();
|
||||
const { list } = props;
|
||||
return (
|
||||
<OverlayScroller style={{ padding: 0 }}>
|
||||
<UL>
|
||||
{list.map((item, index: number) => {
|
||||
return (
|
||||
<li key={index}>
|
||||
<span className="title">
|
||||
{item.title?.locale
|
||||
? intl.formatMessage({ id: item.title?.text || '' })
|
||||
: item.title}
|
||||
:
|
||||
</span>
|
||||
<span className="content">
|
||||
{intl.formatMessage({ id: item.tips })}
|
||||
</span>
|
||||
</li>
|
||||
);
|
||||
})}
|
||||
</UL>
|
||||
</OverlayScroller>
|
||||
<UL>
|
||||
{list.map((item, index: number) => {
|
||||
return (
|
||||
<li key={index}>
|
||||
<span className="title">
|
||||
{item.title?.locale
|
||||
? intl.formatMessage({ id: item.title?.text || '' })
|
||||
: item.title}
|
||||
:
|
||||
</span>
|
||||
<span className="content">
|
||||
{intl.formatMessage({ id: item.tips })}
|
||||
</span>
|
||||
</li>
|
||||
);
|
||||
})}
|
||||
</UL>
|
||||
);
|
||||
};
|
||||
|
||||
|
||||
Reference in New Issue
Block a user