mirror of
https://github.com/muerwre/vault-frontend.git
synced 2025-04-25 12:56:41 +07:00
receiving window messages
This commit is contained in:
parent
f7b8b56b53
commit
49bccb96c1
8 changed files with 68 additions and 37 deletions
|
@ -1,4 +1,4 @@
|
|||
import React, { FC } from 'react';
|
||||
import React, { FC, useEffect } from 'react';
|
||||
import { connect } from 'react-redux';
|
||||
import { hot } from 'react-hot-loader';
|
||||
import { ConnectedRouter } from 'connected-react-router';
|
||||
|
@ -25,31 +25,33 @@ const mapDispatchToProps = {};
|
|||
|
||||
type IProps = typeof mapDispatchToProps & ReturnType<typeof mapStateToProps> & {};
|
||||
|
||||
const Component: FC<IProps> = ({ modal: { is_shown } }) => (
|
||||
<ConnectedRouter history={history}>
|
||||
<div>
|
||||
<BlurWrapper is_blurred={is_shown}>
|
||||
<PageCover />
|
||||
<MainLayout>
|
||||
<Modal />
|
||||
<Sprites />
|
||||
const Component: FC<IProps> = ({ modal: { is_shown } }) => {
|
||||
return (
|
||||
<ConnectedRouter history={history}>
|
||||
<div>
|
||||
<BlurWrapper is_blurred={is_shown}>
|
||||
<PageCover />
|
||||
<MainLayout>
|
||||
<Modal />
|
||||
<Sprites />
|
||||
|
||||
<Switch>
|
||||
<Route exact path={URLS.BASE} component={FlowLayout} />
|
||||
<Route path={URLS.EXAMPLES.IMAGE} component={ImageExample} />
|
||||
<Route path={URLS.EXAMPLES.EDITOR} component={EditorExample} />
|
||||
<Route path="/examples/horizontal" component={HorizontalExample} />
|
||||
<Route path="/post:id" component={NodeLayout} />
|
||||
<Switch>
|
||||
<Route exact path={URLS.BASE} component={FlowLayout} />
|
||||
<Route path={URLS.EXAMPLES.IMAGE} component={ImageExample} />
|
||||
<Route path={URLS.EXAMPLES.EDITOR} component={EditorExample} />
|
||||
<Route path="/examples/horizontal" component={HorizontalExample} />
|
||||
<Route path="/post:id" component={NodeLayout} />
|
||||
|
||||
<Redirect to="/" />
|
||||
</Switch>
|
||||
</MainLayout>
|
||||
</BlurWrapper>
|
||||
<Redirect to="/" />
|
||||
</Switch>
|
||||
</MainLayout>
|
||||
</BlurWrapper>
|
||||
|
||||
<BottomContainer />
|
||||
</div>
|
||||
</ConnectedRouter>
|
||||
);
|
||||
<BottomContainer />
|
||||
</div>
|
||||
</ConnectedRouter>
|
||||
);
|
||||
};
|
||||
|
||||
export default connect(
|
||||
mapStateToProps,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue