Updating files after merge
This commit is contained in:
@@ -1,8 +1,6 @@
|
||||
import React from 'react';
|
||||
import PropTypes from 'prop-types';
|
||||
import { NavLink, withRouter } from 'react-router-dom';
|
||||
import { FormattedMessage, injectIntl } from 'react-intl';
|
||||
import NotificationsCounterIcon from './notifications_counter_icon';
|
||||
import NotificationCounter from '../../../components/notification_counter';
|
||||
import { me } from '../../../initial_state';
|
||||
|
||||
const links = [
|
||||
@@ -12,7 +10,7 @@ const links = [
|
||||
</NavLink>,
|
||||
<NavLink key='pr2' className='footer-bar__link' to='/notifications' data-preview-title-id='column.notifications'>
|
||||
<i className='tabs-bar__link__icon notifications'/>
|
||||
<NotificationsCounterIcon />
|
||||
<NotificationCounter />
|
||||
<FormattedMessage id='tabs_bar.notifications' defaultMessage='Notifications' />
|
||||
</NavLink>,
|
||||
<NavLink key='pr3' className='footer-bar__link' to='/groups' data-preview-title-id='column.groups'>
|
||||
|
||||
@@ -1,6 +1,3 @@
|
||||
import React from 'react';
|
||||
import PropTypes from 'prop-types';
|
||||
import { connect } from 'react-redux';
|
||||
import { defineMessages, injectIntl, FormattedMessage } from 'react-intl';
|
||||
import ImmutablePureComponent from 'react-immutable-pure-component';
|
||||
import { me } from '../../../initial_state';
|
||||
|
||||
@@ -1,4 +1,3 @@
|
||||
import React from 'react';
|
||||
import { monthlyExpensesComplete } from '../../../initial_state';
|
||||
|
||||
export default class ProgressPanel extends React.PureComponent {
|
||||
|
||||
@@ -1,8 +1,7 @@
|
||||
import React from 'react';
|
||||
|
||||
import { injectIntl } from 'react-intl';
|
||||
import PropTypes from 'prop-types';
|
||||
import ImmutablePureComponent from 'react-immutable-pure-component';
|
||||
import ModalLoading from './modal_loading';
|
||||
import ModalLoading from '../../../components/modal_loading';
|
||||
import RelativeTimestamp from '../../../components/relative_timestamp';
|
||||
|
||||
export default @injectIntl
|
||||
|
||||
@@ -1,6 +1,5 @@
|
||||
import React from 'react';
|
||||
|
||||
import { defineMessages, injectIntl, FormattedMessage } from 'react-intl';
|
||||
import PropTypes from 'prop-types';
|
||||
import ImmutablePropTypes from 'react-immutable-proptypes';
|
||||
import ImmutablePureComponent from 'react-immutable-pure-component';
|
||||
import IconButton from 'gabsocial/components/icon_button';
|
||||
@@ -29,7 +28,6 @@ class StatusRevisionModal extends ImmutablePureComponent {
|
||||
<h3 className='status-revisions__header__title'><FormattedMessage id='status_revisions.heading' defaultMessage='Revision History' /></h3>
|
||||
<IconButton className='status-revisions__close' title={intl.formatMessage(messages.close)} icon='times' onClick={onClose} size={20} />
|
||||
</div>
|
||||
|
||||
<div className='status-revisions__content'>
|
||||
<StatusRevisionListContainer id={status.get('id')} />
|
||||
</div>
|
||||
|
||||
@@ -1,6 +1,4 @@
|
||||
import React from 'react';
|
||||
import ImmutablePureComponent from 'react-immutable-pure-component';
|
||||
import { connect } from 'react-redux';
|
||||
import { load } from '../../../actions/status_revision_list';
|
||||
import StatusRevisionList from '../components/status_revision_list';
|
||||
|
||||
|
||||
@@ -1,16 +1,9 @@
|
||||
'use strict';
|
||||
|
||||
import classNames from 'classnames';
|
||||
import React from 'react';
|
||||
import { HotKeys } from 'react-hotkeys';
|
||||
import { defineMessages, injectIntl } from 'react-intl';
|
||||
import { connect } from 'react-redux';
|
||||
import { Switch, Redirect, withRouter } from 'react-router-dom';
|
||||
import PropTypes from 'prop-types';
|
||||
import NotificationsContainer from './containers/notifications_container';
|
||||
import LoadingBarContainer from './containers/loading_bar_container';
|
||||
import ModalContainer from './containers/modal_container';
|
||||
import { isMobile } from '../../is_mobile';
|
||||
import { debounce } from 'lodash';
|
||||
import { uploadCompose, resetCompose } from '../../actions/compose';
|
||||
import { expandHomeTimeline } from '../../actions/timelines';
|
||||
@@ -21,20 +14,24 @@ import {
|
||||
import { fetchFilters } from '../../actions/filters';
|
||||
import { clearHeight } from '../../actions/height_cache';
|
||||
import { openModal } from '../../actions/modal';
|
||||
import { WrappedSwitch, WrappedRoute } from './util/react_router_helpers';
|
||||
import UploadArea from './components/upload_area';
|
||||
import TabsBar from './components/tabs_bar';
|
||||
import WrappedRoute from './util/wrapped_route';
|
||||
import { isMobile } from '../../utils/is_mobile';
|
||||
import NotificationsContainer from '../../containers/notifications_container';
|
||||
import LoadingBarContainer from '../../containers/loading_bar_container';
|
||||
import ModalContainer from '../../containers/modal_container';
|
||||
import UploadArea from '../../components/upload_area';
|
||||
import TabsBar from '../../components/tabs_bar';
|
||||
import FooterBar from './components/footer_bar';
|
||||
// import TrendsPanel from './components/trends_panel';
|
||||
import WhoToFollowPanel from './components/who_to_follow_panel';
|
||||
import LinkFooter from './components/link_footer';
|
||||
import ProfilePage from 'gabsocial/pages/profile_page';
|
||||
import GroupsPage from 'gabsocial/pages/groups_page';
|
||||
import GroupPage from 'gabsocial/pages/group_page';
|
||||
import SearchPage from 'gabsocial/pages/search_page';
|
||||
import HomePage from 'gabsocial/pages/home_page';
|
||||
import GroupSidebarPanel from '../groups/sidebar_panel';
|
||||
import { WhoToFollowPanel } from '../../components/panel';
|
||||
import LinkFooter from '../../components/link_footer';
|
||||
import SidebarMenu from '../../components/sidebar_menu';
|
||||
import ProfilePage from '../../pages/profile_page';
|
||||
// import GroupsPage from 'gabsocial/pages/groups_page';
|
||||
import GroupPage from '../../pages/group_page';
|
||||
import SearchPage from '../../pages/search_page';
|
||||
import HomePage from '../../pages/home_page';
|
||||
import GroupSidebarPanel from '../groups/sidebar_panel';
|
||||
|
||||
import {
|
||||
Status,
|
||||
@@ -69,14 +66,15 @@ import {
|
||||
GroupEdit,
|
||||
} from './util/async-components';
|
||||
import { me, meUsername } from '../../initial_state';
|
||||
import { previewState as previewMediaState } from './components/media_modal';
|
||||
import { previewState as previewVideoState } from './components/video_modal';
|
||||
|
||||
// Dummy import, to make sure that <Status /> ends up in the application bundle.
|
||||
// Without this it ends up in ~8 very commonly used bundles.
|
||||
import '../../components/status';
|
||||
import { fetchGroups } from '../../actions/groups';
|
||||
|
||||
import '../../../styles/application.scss';
|
||||
import './ui.scss';
|
||||
|
||||
const messages = defineMessages({
|
||||
beforeUnload: { id: 'ui.beforeunload', defaultMessage: 'Your draft will be lost if you leave Gab Social.' },
|
||||
publish: { id: 'compose_form.publish', defaultMessage: 'Gab' },
|
||||
@@ -189,10 +187,10 @@ class SwitchingColumnsArea extends React.PureComponent {
|
||||
<WrappedRoute path='/home' exact page={HomePage} component={HomeTimeline} content={children} />
|
||||
<WrappedRoute path='/timeline/all' exact page={HomePage} component={CommunityTimeline} content={children} />
|
||||
|
||||
<WrappedRoute path='/groups' exact page={GroupsPage} component={Groups} content={children} componentParams={{ activeTab: 'featured' }} />
|
||||
{/*<WrappedRoute path='/groups' exact page={GroupsPage} component={Groups} content={children} componentParams={{ activeTab: 'featured' }} />
|
||||
<WrappedRoute path='/groups/create' page={GroupsPage} component={Groups} content={children} componentParams={{ showCreateForm: true, activeTab: 'featured' }} />
|
||||
<WrappedRoute path='/groups/browse/member' page={GroupsPage} component={Groups} content={children} componentParams={{ activeTab: 'member' }} />
|
||||
<WrappedRoute path='/groups/browse/admin' page={GroupsPage} component={Groups} content={children} componentParams={{ activeTab: 'admin' }} />
|
||||
<WrappedRoute path='/groups/browse/admin' page={GroupsPage} component={Groups} content={children} componentParams={{ activeTab: 'admin' }} />*/}
|
||||
<WrappedRoute path='/groups/:id/members' page={GroupPage} component={GroupMembers} content={children} />
|
||||
<WrappedRoute path='/groups/:id/removed_accounts' page={GroupPage} component={GroupRemovedAccounts} content={children} />
|
||||
<WrappedRoute path='/groups/:id/edit' page={GroupPage} component={GroupEdit} content={children} />
|
||||
|
||||
@@ -27,11 +27,11 @@ export default class WrappedRoute extends Component {
|
||||
<Bundle fetchComponent={component} loading={this.renderLoading} error={this.renderError}>
|
||||
{Component =>
|
||||
(
|
||||
<Page params={match.params} {...componentParams}>
|
||||
<Component params={match.params} {...componentParams}>
|
||||
{content}
|
||||
</Component>
|
||||
</Page>
|
||||
<Page params={match.params} {...componentParams}>
|
||||
<Component params={match.params} {...componentParams}>
|
||||
{content}
|
||||
</Component>
|
||||
</Page>
|
||||
)
|
||||
}
|
||||
</Bundle>
|
||||
@@ -61,15 +61,15 @@ export default class WrappedRoute extends Component {
|
||||
return <BundleColumnError {...props} />;
|
||||
}
|
||||
|
||||
render () {
|
||||
render() {
|
||||
const { component: Component, content, publicRoute, ...rest } = this.props;
|
||||
|
||||
if (!publicRoute && !me) {
|
||||
const actualUrl = encodeURIComponent(this.props.computedMatch.url);
|
||||
return <Route path={this.props.path} component={() => {
|
||||
window.location.href = `/auth/sign_in?redirect_uri=${actualUrl}`;
|
||||
return null;
|
||||
}}/>
|
||||
window.location.href = `/auth/sign_in?redirect_uri=${actualUrl}`;
|
||||
return null;
|
||||
}} />
|
||||
}
|
||||
|
||||
return <Route {...rest} render={this.renderComponent} />;
|
||||
|
||||
Reference in New Issue
Block a user