Restore stickyness of …
This commit is contained in:
parent
b37241229c
commit
c3d7f0785c
@ -41,7 +41,6 @@ class CollectionLink extends React.Component<Props> {
|
||||
history={history}
|
||||
collectionId={collection.id}
|
||||
activeClassName="activeDropZone"
|
||||
menuOpen={this.menuOpen}
|
||||
>
|
||||
<SidebarLink
|
||||
key={collection.id}
|
||||
@ -50,6 +49,7 @@ class CollectionLink extends React.Component<Props> {
|
||||
iconColor={collection.color}
|
||||
expand={expanded}
|
||||
hideExpandToggle
|
||||
menuOpen={this.menuOpen}
|
||||
expandedContent={
|
||||
<CollectionChildren column>
|
||||
{collection.documents.map(document => (
|
||||
|
@ -53,6 +53,7 @@ type Props = {
|
||||
expand?: boolean,
|
||||
expandedContent?: React.Node,
|
||||
menu?: React.Node,
|
||||
menuOpen?: boolean,
|
||||
hideExpandToggle?: boolean,
|
||||
iconColor?: string,
|
||||
active?: boolean,
|
||||
@ -92,13 +93,14 @@ class SidebarLink extends React.Component<Props> {
|
||||
expand,
|
||||
active,
|
||||
menu,
|
||||
menuOpen,
|
||||
hideExpandToggle,
|
||||
} = this.props;
|
||||
const Component = to ? StyledNavLink : StyledDiv;
|
||||
const showExpandIcon = expandedContent && !hideExpandToggle;
|
||||
|
||||
return (
|
||||
<Wrapper column>
|
||||
<Wrapper menuOpen={menuOpen} column>
|
||||
<Component
|
||||
iconVisible={showExpandIcon}
|
||||
activeStyle={activeStyle}
|
||||
@ -124,7 +126,7 @@ class SidebarLink extends React.Component<Props> {
|
||||
const Action = styled.span`
|
||||
position: absolute;
|
||||
right: 0;
|
||||
top: 0;
|
||||
top: 2px;
|
||||
color: ${color.slate};
|
||||
svg {
|
||||
opacity: 0.75;
|
||||
|
Reference in New Issue
Block a user