Admin: async components
This commit is contained in:
parent
aa54e0bd0b
commit
1e77adda34
2 changed files with 19 additions and 4 deletions
|
@ -330,6 +330,14 @@ export function InstanceModerationPanel() {
|
||||||
return import(/* webpackChunkName: "features/remote_timeline" */'../components/profile_media_panel');
|
return import(/* webpackChunkName: "features/remote_timeline" */'../components/profile_media_panel');
|
||||||
}
|
}
|
||||||
|
|
||||||
|
export function LatestAccountsPanel() {
|
||||||
|
return import(/* webpackChunkName: "features/admin" */'../../admin/components/latest_accounts_panel');
|
||||||
|
}
|
||||||
|
|
||||||
|
export function AdminNav() {
|
||||||
|
return import(/* webpackChunkName: "features/admin" */'../../admin/components/admin_nav');
|
||||||
|
}
|
||||||
|
|
||||||
export function CryptoDonate() {
|
export function CryptoDonate() {
|
||||||
return import(/* webpackChunkName: "features/crypto_donate" */'../../crypto_donate');
|
return import(/* webpackChunkName: "features/crypto_donate" */'../../crypto_donate');
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,8 +1,11 @@
|
||||||
import React from 'react';
|
import React from 'react';
|
||||||
import ImmutablePureComponent from 'react-immutable-pure-component';
|
import ImmutablePureComponent from 'react-immutable-pure-component';
|
||||||
import LinkFooter from '../features/ui/components/link_footer';
|
import LinkFooter from '../features/ui/components/link_footer';
|
||||||
import AdminNav from 'soapbox/features/admin/components/admin_nav';
|
import BundleContainer from 'soapbox/features/ui/containers/bundle_container';
|
||||||
import LatestAccountsPanel from 'soapbox/features/admin/components/latest_accounts_panel';
|
import {
|
||||||
|
AdminNav,
|
||||||
|
LatestAccountsPanel,
|
||||||
|
} from 'soapbox/features/ui/util/async-components';
|
||||||
|
|
||||||
export default
|
export default
|
||||||
class AdminPage extends ImmutablePureComponent {
|
class AdminPage extends ImmutablePureComponent {
|
||||||
|
@ -17,7 +20,9 @@ class AdminPage extends ImmutablePureComponent {
|
||||||
|
|
||||||
<div className='columns-area__panels__pane columns-area__panels__pane--left'>
|
<div className='columns-area__panels__pane columns-area__panels__pane--left'>
|
||||||
<div className='columns-area__panels__pane__inner'>
|
<div className='columns-area__panels__pane__inner'>
|
||||||
<AdminNav />
|
<BundleContainer fetchComponent={AdminNav}>
|
||||||
|
{Component => <Component />}
|
||||||
|
</BundleContainer>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
@ -29,7 +34,9 @@ class AdminPage extends ImmutablePureComponent {
|
||||||
|
|
||||||
<div className='columns-area__panels__pane columns-area__panels__pane--right'>
|
<div className='columns-area__panels__pane columns-area__panels__pane--right'>
|
||||||
<div className='columns-area__panels__pane__inner'>
|
<div className='columns-area__panels__pane__inner'>
|
||||||
<LatestAccountsPanel limit={5} />
|
<BundleContainer fetchComponent={LatestAccountsPanel}>
|
||||||
|
{Component => <Component limit={5} />}
|
||||||
|
</BundleContainer>
|
||||||
<LinkFooter />
|
<LinkFooter />
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
Loading…
Reference in a new issue