ConfirmWrapper: Fixed Scrollbar wrapper usage if height property set
This commit is contained in:
parent
9d6a5fe708
commit
0577ebe6f8
@ -47,13 +47,16 @@ const BgBlock = styled.div`
|
|||||||
const ConfirmWrapper = (props) => {
|
const ConfirmWrapper = (props) => {
|
||||||
const { children, currentColorScheme, height } = props;
|
const { children, currentColorScheme, height } = props;
|
||||||
const bgPattern = getBgPattern(currentColorScheme?.id);
|
const bgPattern = getBgPattern(currentColorScheme?.id);
|
||||||
|
const content = (
|
||||||
|
<>
|
||||||
|
<BgBlock bgPattern={bgPattern} />
|
||||||
|
{children}
|
||||||
|
</>
|
||||||
|
);
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<StyledWrapper height={height}>
|
<StyledWrapper height={height}>
|
||||||
<Scrollbar>
|
{!!height ? content : <Scrollbar>{content}</Scrollbar>}
|
||||||
<BgBlock bgPattern={bgPattern} />
|
|
||||||
{children}
|
|
||||||
</Scrollbar>
|
|
||||||
</StyledWrapper>
|
</StyledWrapper>
|
||||||
);
|
);
|
||||||
};
|
};
|
||||||
|
Loading…
Reference in New Issue
Block a user