fix view for unauthed users
This commit is contained in:
parent
ef9b34c51f
commit
7990a379fc
3 changed files with 18 additions and 15 deletions
|
@ -65,6 +65,7 @@ function AppRouter(props: Props) {
|
|||
const {
|
||||
currentScroll,
|
||||
location: { pathname },
|
||||
isAuthenticated,
|
||||
} = props;
|
||||
|
||||
useEffect(() => {
|
||||
|
@ -78,7 +79,11 @@ function AppRouter(props: Props) {
|
|||
<Route path={`/$/${PAGES.AUTH}`} exact component={SignInPage} />
|
||||
<Route path={`/$/${PAGES.TAGS}`} exact component={TagsPage} />
|
||||
<Route path={`/$/${PAGES.TAGS_FOLLOWING}`} exact component={TagsFollowingPage} />
|
||||
<Route path={`/$/${PAGES.CHANNELS_FOLLOWING}`} exact component={ChannelsFollowingPage} />
|
||||
<Route
|
||||
path={`/$/${PAGES.CHANNELS_FOLLOWING}`}
|
||||
exact
|
||||
component={isAuthenticated ? ChannelsFollowingPage : DiscoverPage}
|
||||
/>
|
||||
<Route path={`/$/${PAGES.CHANNELS_FOLLOWING_MANAGE}`} exact component={ChannelsFollowingManagePage} />
|
||||
<Route path={`/$/${PAGES.HELP}`} exact component={HelpPage} />
|
||||
<Route path={`/$/${PAGES.AUTH_VERIFY}`} exact component={SignInVerifyPage} />
|
||||
|
|
|
@ -32,7 +32,7 @@ function ChannelsFollowing(props: Props) {
|
|||
<Page>
|
||||
{showTab ? (
|
||||
<ClaimList
|
||||
headerLabel={__('Find Channels To Follow')}
|
||||
header={__('Find Channels to Follow')}
|
||||
headerAltControls={
|
||||
<Button
|
||||
button="link"
|
||||
|
|
|
@ -39,19 +39,17 @@ function FollowingPage(props: Props) {
|
|||
return (
|
||||
<Page>
|
||||
<TagsSelect showClose={false} title={__('Follow New Tags')} />
|
||||
<div className="card">
|
||||
<ClaimList
|
||||
header={viewingSuggestedSubs ? __('Discover New Channels') : __('Channels You Follow')}
|
||||
headerAltControls={
|
||||
<Button
|
||||
button="link"
|
||||
label={viewingSuggestedSubs ? hasSubscriptions && __('View Your Channels') : __('Find New Channels')}
|
||||
onClick={() => onClick()}
|
||||
/>
|
||||
}
|
||||
uris={viewingSuggestedSubs ? suggestedSubscriptions.map(sub => `lbry://${sub.uri}`) : channelUris}
|
||||
/>
|
||||
</div>
|
||||
<ClaimList
|
||||
header={viewingSuggestedSubs ? __('Discover New Channels') : __('Channels You Follow')}
|
||||
headerAltControls={
|
||||
<Button
|
||||
button="link"
|
||||
label={viewingSuggestedSubs ? hasSubscriptions && __('View Your Channels') : __('Find New Channels')}
|
||||
onClick={() => onClick()}
|
||||
/>
|
||||
}
|
||||
uris={viewingSuggestedSubs ? suggestedSubscriptions.map(sub => `lbry://${sub.uri}`) : channelUris}
|
||||
/>
|
||||
</Page>
|
||||
);
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue