fix: Document history should scroll separate to page content

closes #1225
This commit is contained in:
Tom Moor
2020-04-05 13:07:16 -07:00
parent 597c09d2bc
commit 9712b8d205

View File

@ -100,6 +100,7 @@ class DocumentHistory extends React.Component<Props> {
const showLoading = !this.isLoaded && this.isFetching;
return (
<Sidebar>
<Wrapper column>
{showLoading ? (
<Loading>
@ -124,6 +125,7 @@ class DocumentHistory extends React.Component<Props> {
<Waypoint key={this.offset} onEnter={this.loadMoreResults} />
)}
</Wrapper>
</Sidebar>
);
}
}
@ -133,6 +135,16 @@ const Loading = styled.div`
`;
const Wrapper = styled(Flex)`
position: fixed;
top: 0;
right: 0;
z-index: 1;
min-width: ${props => props.theme.sidebarWidth};
overflow: scroll;
overscroll-behavior: none;
`;
const Sidebar = styled(Flex)`
background: ${props => props.theme.background};
min-width: ${props => props.theme.sidebarWidth};
border-left: 1px solid ${props => props.theme.divider};