|
@ -174,7 +174,21 @@ const Sidebar = ({ |
|
|
> |
|
|
> |
|
|
{t('Now Playing')} |
|
|
{t('Now Playing')} |
|
|
</SidebarNavItem> |
|
|
</SidebarNavItem> |
|
|
|
|
|
<SidebarNavItem |
|
|
|
|
|
tabIndex={0} |
|
|
|
|
|
eventKey="playlists" |
|
|
|
|
|
icon={<Icon icon="list-ul" />} |
|
|
|
|
|
onSelect={handleSidebarSelect} |
|
|
|
|
|
disabled={disableSidebar} |
|
|
|
|
|
onKeyDown={(e: any) => { |
|
|
|
|
|
if (e.key === ' ' || e.key === 'Enter') { |
|
|
|
|
|
history.push('/playlist'); |
|
|
|
|
|
} |
|
|
|
|
|
}} |
|
|
|
|
|
$show={config.lookAndFeel.sidebar.selected.includes('playlists')} |
|
|
|
|
|
> |
|
|
|
|
|
{t('Playlists')} |
|
|
|
|
|
</SidebarNavItem> |
|
|
<SidebarNavItem |
|
|
<SidebarNavItem |
|
|
tabIndex={0} |
|
|
tabIndex={0} |
|
|
eventKey="starred" |
|
|
eventKey="starred" |
|
@ -300,33 +314,16 @@ const Sidebar = ({ |
|
|
> |
|
|
> |
|
|
{expand ? t('Collapse') : t('Expand')} |
|
|
{expand ? t('Collapse') : t('Expand')} |
|
|
</SidebarNavItem> |
|
|
</SidebarNavItem> |
|
|
{!expand && ( |
|
|
|
|
|
<SidebarNavItem |
|
|
|
|
|
tabIndex={0} |
|
|
|
|
|
eventKey="playlists" |
|
|
|
|
|
icon={<Icon icon="list-ul" />} |
|
|
|
|
|
onSelect={handleSidebarSelect} |
|
|
|
|
|
disabled={disableSidebar} |
|
|
|
|
|
onKeyDown={(e: any) => { |
|
|
|
|
|
if (e.key === ' ' || e.key === 'Enter') { |
|
|
|
|
|
history.push('/playlist'); |
|
|
|
|
|
} |
|
|
|
|
|
}} |
|
|
|
|
|
$show={config.lookAndFeel.sidebar.selected.includes('playlists')} |
|
|
|
|
|
> |
|
|
|
|
|
{t('Playlists')} |
|
|
|
|
|
</SidebarNavItem> |
|
|
|
|
|
)} |
|
|
|
|
|
</div> |
|
|
</div> |
|
|
</Nav> |
|
|
</Nav> |
|
|
{expand && |
|
|
{expand && |
|
|
!disableSidebar && |
|
|
!disableSidebar && |
|
|
config.lookAndFeel.sidebar.selected.includes('playlists') && ( |
|
|
config.lookAndFeel.sidebar.selected.includes('playlistList') && ( |
|
|
<div |
|
|
<div |
|
|
style={{ |
|
|
style={{ |
|
|
height: `${ |
|
|
height: `${ |
|
|
sidebarBodyHeight - mainNavHeight < 170 |
|
|
sidebarBodyHeight - mainNavHeight < 100 |
|
|
? 170 |
|
|
? 100 |
|
|
: sidebarBodyHeight - mainNavHeight |
|
|
: sidebarBodyHeight - mainNavHeight |
|
|
}px`,
|
|
|
}px`,
|
|
|
overflow: 'hidden', |
|
|
overflow: 'hidden', |
|
@ -334,9 +331,7 @@ const Sidebar = ({ |
|
|
}} |
|
|
}} |
|
|
> |
|
|
> |
|
|
<> |
|
|
<> |
|
|
<PlaylistDivider onClick={() => history.push('/playlist')}> |
|
|
<PlaylistDivider /> |
|
|
{t('Playlists')} |
|
|
|
|
|
</PlaylistDivider> |
|
|
|
|
|
<SidebarPlaylists width={width} /> |
|
|
<SidebarPlaylists width={width} /> |
|
|
</> |
|
|
</> |
|
|
</div> |
|
|
</div> |
|
|