web: components: render scrollbars outside content
This commit is contained in:
parent
1b3e977d0e
commit
1de160c7cc
@ -4,6 +4,7 @@ import styled from "styled-components";
|
||||
const StyledSectionHeader = styled.div`
|
||||
border-bottom: 1px solid #eceef1;
|
||||
height: 56px;
|
||||
margin-right: 16px;
|
||||
`;
|
||||
|
||||
const SectionHeader = React.memo(props => {
|
||||
|
@ -2,7 +2,7 @@ import React from "react";
|
||||
import styled from "styled-components";
|
||||
|
||||
const StyledSection = styled.section`
|
||||
padding: 0 16px;
|
||||
padding: 0 0 0 16px;
|
||||
flex-grow: 1;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
|
@ -36,8 +36,12 @@ const Scrollbar = React.forwardRef((props, ref) => {
|
||||
<div {...props} style={{ ...style, ...thumbH }} />
|
||||
);
|
||||
|
||||
const renderView = ({ style, ...props }) => (
|
||||
<div {...props} style={{paddingRight: '16px', ...style}} />
|
||||
);
|
||||
|
||||
return (
|
||||
<Scrollbars renderThumbVertical={renderNavThumbVertical} renderThumbHorizontal={renderNavThumbHorizontal} {...props} ref={ref} />
|
||||
<Scrollbars renderView={renderView} renderThumbVertical={renderNavThumbVertical} renderThumbHorizontal={renderNavThumbHorizontal} {...props} ref={ref} />
|
||||
);
|
||||
});
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user