diff --git a/app/javascript/mastodon/features/account_timeline/index.js b/app/javascript/mastodon/features/account_timeline/index.js
index fa4239d6f5..821c852b6f 100644
--- a/app/javascript/mastodon/features/account_timeline/index.js
+++ b/app/javascript/mastodon/features/account_timeline/index.js
@@ -50,7 +50,6 @@ class AccountTimeline extends ImmutablePureComponent {
static propTypes = {
params: PropTypes.object.isRequired,
dispatch: PropTypes.func.isRequired,
- shouldUpdateScroll: PropTypes.func,
statusIds: ImmutablePropTypes.list,
featuredStatusIds: ImmutablePropTypes.list,
isLoading: PropTypes.bool,
@@ -115,7 +114,7 @@ class AccountTimeline extends ImmutablePureComponent {
}
render () {
- const { shouldUpdateScroll, statusIds, featuredStatusIds, isLoading, hasMore, blockedBy, suspended, isAccount, multiColumn, remote, remoteUrl } = this.props;
+ const { statusIds, featuredStatusIds, isLoading, hasMore, blockedBy, suspended, isAccount, multiColumn, remote, remoteUrl } = this.props;
if (!isAccount) {
return (
@@ -162,7 +161,6 @@ class AccountTimeline extends ImmutablePureComponent {
isLoading={isLoading}
hasMore={hasMore}
onLoadMore={this.handleLoadMore}
- shouldUpdateScroll={shouldUpdateScroll}
emptyMessage={emptyMessage}
bindToDocument={!multiColumn}
timelineId='account'
diff --git a/app/javascript/mastodon/features/blocks/index.js b/app/javascript/mastodon/features/blocks/index.js
index 107deb8417..7ec1774344 100644
--- a/app/javascript/mastodon/features/blocks/index.js
+++ b/app/javascript/mastodon/features/blocks/index.js
@@ -29,7 +29,6 @@ class Blocks extends ImmutablePureComponent {
static propTypes = {
params: PropTypes.object.isRequired,
dispatch: PropTypes.func.isRequired,
- shouldUpdateScroll: PropTypes.func,
accountIds: ImmutablePropTypes.list,
hasMore: PropTypes.bool,
isLoading: PropTypes.bool,
@@ -46,7 +45,7 @@ class Blocks extends ImmutablePureComponent {
}, 300, { leading: true });
render () {
- const { intl, accountIds, shouldUpdateScroll, hasMore, multiColumn, isLoading } = this.props;
+ const { intl, accountIds, hasMore, multiColumn, isLoading } = this.props;
if (!accountIds) {
return (
@@ -66,7 +65,6 @@ class Blocks extends ImmutablePureComponent {
onLoadMore={this.handleLoadMore}
hasMore={hasMore}
isLoading={isLoading}
- shouldUpdateScroll={shouldUpdateScroll}
emptyMessage={emptyMessage}
bindToDocument={!multiColumn}
>
diff --git a/app/javascript/mastodon/features/bookmarked_statuses/index.js b/app/javascript/mastodon/features/bookmarked_statuses/index.js
index c37cb91767..cf067d9543 100644
--- a/app/javascript/mastodon/features/bookmarked_statuses/index.js
+++ b/app/javascript/mastodon/features/bookmarked_statuses/index.js
@@ -27,7 +27,6 @@ class Bookmarks extends ImmutablePureComponent {
static propTypes = {
dispatch: PropTypes.func.isRequired,
- shouldUpdateScroll: PropTypes.func,
statusIds: ImmutablePropTypes.list.isRequired,
intl: PropTypes.object.isRequired,
columnId: PropTypes.string,
@@ -68,7 +67,7 @@ class Bookmarks extends ImmutablePureComponent {
}, 300, { leading: true })
render () {
- const { intl, shouldUpdateScroll, statusIds, columnId, multiColumn, hasMore, isLoading } = this.props;
+ const { intl, statusIds, columnId, multiColumn, hasMore, isLoading } = this.props;
const pinned = !!columnId;
const emptyMessage =
;
@@ -93,7 +92,6 @@ class Bookmarks extends ImmutablePureComponent {
hasMore={hasMore}
isLoading={isLoading}
onLoadMore={this.handleLoadMore}
- shouldUpdateScroll={shouldUpdateScroll}
emptyMessage={emptyMessage}
bindToDocument={!multiColumn}
/>
diff --git a/app/javascript/mastodon/features/community_timeline/index.js b/app/javascript/mastodon/features/community_timeline/index.js
index b3cd39685c..30f7760486 100644
--- a/app/javascript/mastodon/features/community_timeline/index.js
+++ b/app/javascript/mastodon/features/community_timeline/index.js
@@ -41,7 +41,6 @@ class CommunityTimeline extends React.PureComponent {
static propTypes = {
dispatch: PropTypes.func.isRequired,
- shouldUpdateScroll: PropTypes.func,
columnId: PropTypes.string,
intl: PropTypes.object.isRequired,
hasUnread: PropTypes.bool,
@@ -103,7 +102,7 @@ class CommunityTimeline extends React.PureComponent {
}
render () {
- const { intl, shouldUpdateScroll, hasUnread, columnId, multiColumn, onlyMedia } = this.props;
+ const { intl, hasUnread, columnId, multiColumn, onlyMedia } = this.props;
const pinned = !!columnId;
return (
@@ -127,7 +126,6 @@ class CommunityTimeline extends React.PureComponent {
timelineId={`community${onlyMedia ? ':media' : ''}`}
onLoadMore={this.handleLoadMore}
emptyMessage={
}
- shouldUpdateScroll={shouldUpdateScroll}
bindToDocument={!multiColumn}
/>
diff --git a/app/javascript/mastodon/features/direct_timeline/components/conversations_list.js b/app/javascript/mastodon/features/direct_timeline/components/conversations_list.js
index 4ee8e52122..fd1df72568 100644
--- a/app/javascript/mastodon/features/direct_timeline/components/conversations_list.js
+++ b/app/javascript/mastodon/features/direct_timeline/components/conversations_list.js
@@ -14,7 +14,6 @@ export default class ConversationsList extends ImmutablePureComponent {
hasMore: PropTypes.bool,
isLoading: PropTypes.bool,
onLoadMore: PropTypes.func,
- shouldUpdateScroll: PropTypes.func,
};
getCurrentIndex = id => this.props.conversations.findIndex(x => x.get('id') === id)
diff --git a/app/javascript/mastodon/features/direct_timeline/index.js b/app/javascript/mastodon/features/direct_timeline/index.js
index 5ce7957600..68523666c3 100644
--- a/app/javascript/mastodon/features/direct_timeline/index.js
+++ b/app/javascript/mastodon/features/direct_timeline/index.js
@@ -19,7 +19,6 @@ class DirectTimeline extends React.PureComponent {
static propTypes = {
dispatch: PropTypes.func.isRequired,
- shouldUpdateScroll: PropTypes.func,
columnId: PropTypes.string,
intl: PropTypes.object.isRequired,
hasUnread: PropTypes.bool,
@@ -71,7 +70,7 @@ class DirectTimeline extends React.PureComponent {
}
render () {
- const { intl, hasUnread, columnId, multiColumn, shouldUpdateScroll } = this.props;
+ const { intl, hasUnread, columnId, multiColumn } = this.props;
const pinned = !!columnId;
return (
@@ -93,7 +92,6 @@ class DirectTimeline extends React.PureComponent {
timelineId='direct'
onLoadMore={this.handleLoadMore}
emptyMessage={
}
- shouldUpdateScroll={shouldUpdateScroll}
/>
);
diff --git a/app/javascript/mastodon/features/directory/index.js b/app/javascript/mastodon/features/directory/index.js
index 2f91e759b5..88f20d3304 100644
--- a/app/javascript/mastodon/features/directory/index.js
+++ b/app/javascript/mastodon/features/directory/index.js
@@ -12,7 +12,7 @@ import AccountCard from './components/account_card';
import RadioButton from 'mastodon/components/radio_button';
import classNames from 'classnames';
import LoadMore from 'mastodon/components/load_more';
-import { ScrollContainer } from 'react-router-scroll-4';
+import ScrollContainer from 'mastodon/containers/scroll_container';
const messages = defineMessages({
title: { id: 'column.directory', defaultMessage: 'Browse profiles' },
@@ -40,7 +40,6 @@ class Directory extends React.PureComponent {
isLoading: PropTypes.bool,
accountIds: ImmutablePropTypes.list.isRequired,
dispatch: PropTypes.func.isRequired,
- shouldUpdateScroll: PropTypes.func,
columnId: PropTypes.string,
intl: PropTypes.object.isRequired,
multiColumn: PropTypes.bool,
@@ -125,7 +124,7 @@ class Directory extends React.PureComponent {
}
render () {
- const { isLoading, accountIds, intl, columnId, multiColumn, domain, shouldUpdateScroll } = this.props;
+ const { isLoading, accountIds, intl, columnId, multiColumn, domain } = this.props;
const { order, local } = this.getParams(this.props, this.state);
const pinned = !!columnId;
@@ -163,7 +162,7 @@ class Directory extends React.PureComponent {
multiColumn={multiColumn}
/>
- {multiColumn && !pinned ?
{scrollableArea} : scrollableArea}
+ {multiColumn && !pinned ?
{scrollableArea} : scrollableArea}
);
}
diff --git a/app/javascript/mastodon/features/domain_blocks/index.js b/app/javascript/mastodon/features/domain_blocks/index.js
index a6d9889124..edb80aef41 100644
--- a/app/javascript/mastodon/features/domain_blocks/index.js
+++ b/app/javascript/mastodon/features/domain_blocks/index.js
@@ -29,7 +29,6 @@ class Blocks extends ImmutablePureComponent {
static propTypes = {
params: PropTypes.object.isRequired,
dispatch: PropTypes.func.isRequired,
- shouldUpdateScroll: PropTypes.func,
hasMore: PropTypes.bool,
domains: ImmutablePropTypes.orderedSet,
intl: PropTypes.object.isRequired,
@@ -45,7 +44,7 @@ class Blocks extends ImmutablePureComponent {
}, 300, { leading: true });
render () {
- const { intl, domains, shouldUpdateScroll, hasMore, multiColumn } = this.props;
+ const { intl, domains, hasMore, multiColumn } = this.props;
if (!domains) {
return (
@@ -64,7 +63,6 @@ class Blocks extends ImmutablePureComponent {
scrollKey='domain_blocks'
onLoadMore={this.handleLoadMore}
hasMore={hasMore}
- shouldUpdateScroll={shouldUpdateScroll}
emptyMessage={emptyMessage}
bindToDocument={!multiColumn}
>
diff --git a/app/javascript/mastodon/features/favourited_statuses/index.js b/app/javascript/mastodon/features/favourited_statuses/index.js
index db8a3f815f..9606a144c6 100644
--- a/app/javascript/mastodon/features/favourited_statuses/index.js
+++ b/app/javascript/mastodon/features/favourited_statuses/index.js
@@ -27,7 +27,6 @@ class Favourites extends ImmutablePureComponent {
static propTypes = {
dispatch: PropTypes.func.isRequired,
- shouldUpdateScroll: PropTypes.func,
statusIds: ImmutablePropTypes.list.isRequired,
intl: PropTypes.object.isRequired,
columnId: PropTypes.string,
@@ -68,7 +67,7 @@ class Favourites extends ImmutablePureComponent {
}, 300, { leading: true })
render () {
- const { intl, shouldUpdateScroll, statusIds, columnId, multiColumn, hasMore, isLoading } = this.props;
+ const { intl, statusIds, columnId, multiColumn, hasMore, isLoading } = this.props;
const pinned = !!columnId;
const emptyMessage =
;
@@ -93,7 +92,6 @@ class Favourites extends ImmutablePureComponent {
hasMore={hasMore}
isLoading={isLoading}
onLoadMore={this.handleLoadMore}
- shouldUpdateScroll={shouldUpdateScroll}
emptyMessage={emptyMessage}
bindToDocument={!multiColumn}
/>
diff --git a/app/javascript/mastodon/features/favourites/index.js b/app/javascript/mastodon/features/favourites/index.js
index 75cb00c0ea..ac94ae18a2 100644
--- a/app/javascript/mastodon/features/favourites/index.js
+++ b/app/javascript/mastodon/features/favourites/index.js
@@ -27,7 +27,6 @@ class Favourites extends ImmutablePureComponent {
static propTypes = {
params: PropTypes.object.isRequired,
dispatch: PropTypes.func.isRequired,
- shouldUpdateScroll: PropTypes.func,
accountIds: ImmutablePropTypes.list,
multiColumn: PropTypes.bool,
intl: PropTypes.object.isRequired,
@@ -50,7 +49,7 @@ class Favourites extends ImmutablePureComponent {
}
render () {
- const { intl, shouldUpdateScroll, accountIds, multiColumn } = this.props;
+ const { intl, accountIds, multiColumn } = this.props;
if (!accountIds) {
return (
@@ -74,7 +73,6 @@ class Favourites extends ImmutablePureComponent {
diff --git a/app/javascript/mastodon/features/follow_requests/index.js b/app/javascript/mastodon/features/follow_requests/index.js
index 18df9d25cd..1f9b635bb7 100644
--- a/app/javascript/mastodon/features/follow_requests/index.js
+++ b/app/javascript/mastodon/features/follow_requests/index.js
@@ -32,7 +32,6 @@ class FollowRequests extends ImmutablePureComponent {
static propTypes = {
params: PropTypes.object.isRequired,
dispatch: PropTypes.func.isRequired,
- shouldUpdateScroll: PropTypes.func,
hasMore: PropTypes.bool,
isLoading: PropTypes.bool,
accountIds: ImmutablePropTypes.list,
@@ -51,7 +50,7 @@ class FollowRequests extends ImmutablePureComponent {
}, 300, { leading: true });
render () {
- const { intl, shouldUpdateScroll, accountIds, hasMore, multiColumn, locked, domain, isLoading } = this.props;
+ const { intl, accountIds, hasMore, multiColumn, locked, domain, isLoading } = this.props;
if (!accountIds) {
return (
@@ -80,7 +79,6 @@ class FollowRequests extends ImmutablePureComponent {
onLoadMore={this.handleLoadMore}
hasMore={hasMore}
isLoading={isLoading}
- shouldUpdateScroll={shouldUpdateScroll}
emptyMessage={emptyMessage}
bindToDocument={!multiColumn}
prepend={unlockedPrependMessage}
diff --git a/app/javascript/mastodon/features/followers/index.js b/app/javascript/mastodon/features/followers/index.js
index ae00d13d3b..ee747f0da6 100644
--- a/app/javascript/mastodon/features/followers/index.js
+++ b/app/javascript/mastodon/features/followers/index.js
@@ -43,7 +43,6 @@ class Followers extends ImmutablePureComponent {
static propTypes = {
params: PropTypes.object.isRequired,
dispatch: PropTypes.func.isRequired,
- shouldUpdateScroll: PropTypes.func,
accountIds: ImmutablePropTypes.list,
hasMore: PropTypes.bool,
isLoading: PropTypes.bool,
@@ -73,7 +72,7 @@ class Followers extends ImmutablePureComponent {
}, 300, { leading: true });
render () {
- const { shouldUpdateScroll, accountIds, hasMore, blockedBy, isAccount, multiColumn, isLoading, remote, remoteUrl } = this.props;
+ const { accountIds, hasMore, blockedBy, isAccount, multiColumn, isLoading, remote, remoteUrl } = this.props;
if (!isAccount) {
return (
@@ -112,7 +111,6 @@ class Followers extends ImmutablePureComponent {
hasMore={hasMore}
isLoading={isLoading}
onLoadMore={this.handleLoadMore}
- shouldUpdateScroll={shouldUpdateScroll}
prepend={}
alwaysPrepend
append={remoteMessage}
diff --git a/app/javascript/mastodon/features/following/index.js b/app/javascript/mastodon/features/following/index.js
index 666ec7a7f6..804df803ed 100644
--- a/app/javascript/mastodon/features/following/index.js
+++ b/app/javascript/mastodon/features/following/index.js
@@ -43,7 +43,6 @@ class Following extends ImmutablePureComponent {
static propTypes = {
params: PropTypes.object.isRequired,
dispatch: PropTypes.func.isRequired,
- shouldUpdateScroll: PropTypes.func,
accountIds: ImmutablePropTypes.list,
hasMore: PropTypes.bool,
isLoading: PropTypes.bool,
@@ -73,7 +72,7 @@ class Following extends ImmutablePureComponent {
}, 300, { leading: true });
render () {
- const { shouldUpdateScroll, accountIds, hasMore, blockedBy, isAccount, multiColumn, isLoading, remote, remoteUrl } = this.props;
+ const { accountIds, hasMore, blockedBy, isAccount, multiColumn, isLoading, remote, remoteUrl } = this.props;
if (!isAccount) {
return (
@@ -112,7 +111,6 @@ class Following extends ImmutablePureComponent {
hasMore={hasMore}
isLoading={isLoading}
onLoadMore={this.handleLoadMore}
- shouldUpdateScroll={shouldUpdateScroll}
prepend={}
alwaysPrepend
append={remoteMessage}
diff --git a/app/javascript/mastodon/features/hashtag_timeline/index.js b/app/javascript/mastodon/features/hashtag_timeline/index.js
index 5ccd9f8ea2..6a808eb306 100644
--- a/app/javascript/mastodon/features/hashtag_timeline/index.js
+++ b/app/javascript/mastodon/features/hashtag_timeline/index.js
@@ -24,7 +24,6 @@ class HashtagTimeline extends React.PureComponent {
params: PropTypes.object.isRequired,
columnId: PropTypes.string,
dispatch: PropTypes.func.isRequired,
- shouldUpdateScroll: PropTypes.func,
hasUnread: PropTypes.bool,
multiColumn: PropTypes.bool,
};
@@ -130,7 +129,7 @@ class HashtagTimeline extends React.PureComponent {
}
render () {
- const { shouldUpdateScroll, hasUnread, columnId, multiColumn } = this.props;
+ const { hasUnread, columnId, multiColumn } = this.props;
const { id, local } = this.props.params;
const pinned = !!columnId;
@@ -156,7 +155,6 @@ class HashtagTimeline extends React.PureComponent {
timelineId={`hashtag:${id}${local ? ':local' : ''}`}
onLoadMore={this.handleLoadMore}
emptyMessage={}
- shouldUpdateScroll={shouldUpdateScroll}
bindToDocument={!multiColumn}
/>
diff --git a/app/javascript/mastodon/features/home_timeline/index.js b/app/javascript/mastodon/features/home_timeline/index.js
index b85c69af70..dc440f2fe0 100644
--- a/app/javascript/mastodon/features/home_timeline/index.js
+++ b/app/javascript/mastodon/features/home_timeline/index.js
@@ -34,7 +34,6 @@ class HomeTimeline extends React.PureComponent {
static propTypes = {
dispatch: PropTypes.func.isRequired,
- shouldUpdateScroll: PropTypes.func,
intl: PropTypes.object.isRequired,
hasUnread: PropTypes.bool,
isPartial: PropTypes.bool,
@@ -112,7 +111,7 @@ class HomeTimeline extends React.PureComponent {
}
render () {
- const { intl, shouldUpdateScroll, hasUnread, columnId, multiColumn, hasAnnouncements, unreadAnnouncements, showAnnouncements } = this.props;
+ const { intl, hasUnread, columnId, multiColumn, hasAnnouncements, unreadAnnouncements, showAnnouncements } = this.props;
const pinned = !!columnId;
let announcementsButton = null;
@@ -154,7 +153,6 @@ class HomeTimeline extends React.PureComponent {
onLoadMore={this.handleLoadMore}
timelineId='home'
emptyMessage={ }} />}
- shouldUpdateScroll={shouldUpdateScroll}
bindToDocument={!multiColumn}
/>
diff --git a/app/javascript/mastodon/features/list_timeline/index.js b/app/javascript/mastodon/features/list_timeline/index.js
index 8eb6456302..8010274f88 100644
--- a/app/javascript/mastodon/features/list_timeline/index.js
+++ b/app/javascript/mastodon/features/list_timeline/index.js
@@ -41,7 +41,6 @@ class ListTimeline extends React.PureComponent {
static propTypes = {
params: PropTypes.object.isRequired,
dispatch: PropTypes.func.isRequired,
- shouldUpdateScroll: PropTypes.func,
columnId: PropTypes.string,
hasUnread: PropTypes.bool,
multiColumn: PropTypes.bool,
@@ -142,7 +141,7 @@ class ListTimeline extends React.PureComponent {
}
render () {
- const { shouldUpdateScroll, hasUnread, columnId, multiColumn, list, intl } = this.props;
+ const { hasUnread, columnId, multiColumn, list, intl } = this.props;
const { id } = this.props.params;
const pinned = !!columnId;
const title = list ? list.get('title') : id;
@@ -207,7 +206,6 @@ class ListTimeline extends React.PureComponent {
timelineId={`list:${id}`}
onLoadMore={this.handleLoadMore}
emptyMessage={}
- shouldUpdateScroll={shouldUpdateScroll}
bindToDocument={!multiColumn}
/>
diff --git a/app/javascript/mastodon/features/lists/index.js b/app/javascript/mastodon/features/lists/index.js
index ca1fa1f5ef..29c3118098 100644
--- a/app/javascript/mastodon/features/lists/index.js
+++ b/app/javascript/mastodon/features/lists/index.js
@@ -48,7 +48,7 @@ class Lists extends ImmutablePureComponent {
}
render () {
- const { intl, shouldUpdateScroll, lists, multiColumn } = this.props;
+ const { intl, lists, multiColumn } = this.props;
if (!lists) {
return (
@@ -68,7 +68,6 @@ class Lists extends ImmutablePureComponent {
}
bindToDocument={!multiColumn}
diff --git a/app/javascript/mastodon/features/mutes/index.js b/app/javascript/mastodon/features/mutes/index.js
index 17ff5c762a..c1d50d1940 100644
--- a/app/javascript/mastodon/features/mutes/index.js
+++ b/app/javascript/mastodon/features/mutes/index.js
@@ -29,7 +29,6 @@ class Mutes extends ImmutablePureComponent {
static propTypes = {
params: PropTypes.object.isRequired,
dispatch: PropTypes.func.isRequired,
- shouldUpdateScroll: PropTypes.func,
hasMore: PropTypes.bool,
isLoading: PropTypes.bool,
accountIds: ImmutablePropTypes.list,
@@ -46,7 +45,7 @@ class Mutes extends ImmutablePureComponent {
}, 300, { leading: true });
render () {
- const { intl, shouldUpdateScroll, hasMore, accountIds, multiColumn, isLoading } = this.props;
+ const { intl, hasMore, accountIds, multiColumn, isLoading } = this.props;
if (!accountIds) {
return (
@@ -66,7 +65,6 @@ class Mutes extends ImmutablePureComponent {
onLoadMore={this.handleLoadMore}
hasMore={hasMore}
isLoading={isLoading}
- shouldUpdateScroll={shouldUpdateScroll}
emptyMessage={emptyMessage}
bindToDocument={!multiColumn}
>
diff --git a/app/javascript/mastodon/features/notifications/index.js b/app/javascript/mastodon/features/notifications/index.js
index 1a621eca9a..a6a277d7ed 100644
--- a/app/javascript/mastodon/features/notifications/index.js
+++ b/app/javascript/mastodon/features/notifications/index.js
@@ -74,7 +74,6 @@ class Notifications extends React.PureComponent {
notifications: ImmutablePropTypes.list.isRequired,
showFilterBar: PropTypes.bool.isRequired,
dispatch: PropTypes.func.isRequired,
- shouldUpdateScroll: PropTypes.func,
intl: PropTypes.object.isRequired,
isLoading: PropTypes.bool,
isUnread: PropTypes.bool,
@@ -176,7 +175,7 @@ class Notifications extends React.PureComponent {
};
render () {
- const { intl, notifications, shouldUpdateScroll, isLoading, isUnread, columnId, multiColumn, hasMore, numPending, showFilterBar, lastReadId, canMarkAsRead, needsNotificationPermission } = this.props;
+ const { intl, notifications, isLoading, isUnread, columnId, multiColumn, hasMore, numPending, showFilterBar, lastReadId, canMarkAsRead, needsNotificationPermission } = this.props;
const pinned = !!columnId;
const emptyMessage = ;
@@ -227,7 +226,6 @@ class Notifications extends React.PureComponent {
onLoadPending={this.handleLoadPending}
onScrollToTop={this.handleScrollToTop}
onScroll={this.handleScroll}
- shouldUpdateScroll={shouldUpdateScroll}
bindToDocument={!multiColumn}
>
{scrollableContent}
diff --git a/app/javascript/mastodon/features/pinned_statuses/index.js b/app/javascript/mastodon/features/pinned_statuses/index.js
index ad5c9cafc3..f32bd6d234 100644
--- a/app/javascript/mastodon/features/pinned_statuses/index.js
+++ b/app/javascript/mastodon/features/pinned_statuses/index.js
@@ -24,7 +24,6 @@ class PinnedStatuses extends ImmutablePureComponent {
static propTypes = {
dispatch: PropTypes.func.isRequired,
- shouldUpdateScroll: PropTypes.func,
statusIds: ImmutablePropTypes.list.isRequired,
intl: PropTypes.object.isRequired,
hasMore: PropTypes.bool.isRequired,
@@ -44,7 +43,7 @@ class PinnedStatuses extends ImmutablePureComponent {
}
render () {
- const { intl, shouldUpdateScroll, statusIds, hasMore, multiColumn } = this.props;
+ const { intl, statusIds, hasMore, multiColumn } = this.props;
return (
@@ -53,7 +52,6 @@ class PinnedStatuses extends ImmutablePureComponent {
statusIds={statusIds}
scrollKey='pinned_statuses'
hasMore={hasMore}
- shouldUpdateScroll={shouldUpdateScroll}
bindToDocument={!multiColumn}
/>
diff --git a/app/javascript/mastodon/features/public_timeline/index.js b/app/javascript/mastodon/features/public_timeline/index.js
index 988b1b070b..b1d5518af5 100644
--- a/app/javascript/mastodon/features/public_timeline/index.js
+++ b/app/javascript/mastodon/features/public_timeline/index.js
@@ -43,7 +43,6 @@ class PublicTimeline extends React.PureComponent {
static propTypes = {
dispatch: PropTypes.func.isRequired,
- shouldUpdateScroll: PropTypes.func,
intl: PropTypes.object.isRequired,
columnId: PropTypes.string,
multiColumn: PropTypes.bool,
@@ -106,7 +105,7 @@ class PublicTimeline extends React.PureComponent {
}
render () {
- const { intl, shouldUpdateScroll, columnId, hasUnread, multiColumn, onlyMedia, onlyRemote } = this.props;
+ const { intl, columnId, hasUnread, multiColumn, onlyMedia, onlyRemote } = this.props;
const pinned = !!columnId;
return (
@@ -130,7 +129,6 @@ class PublicTimeline extends React.PureComponent {
trackScroll={!pinned}
scrollKey={`public_timeline-${columnId}`}
emptyMessage={}
- shouldUpdateScroll={shouldUpdateScroll}
bindToDocument={!multiColumn}
/>
diff --git a/app/javascript/mastodon/features/reblogs/index.js b/app/javascript/mastodon/features/reblogs/index.js
index 4becb5fb7e..0fbd094154 100644
--- a/app/javascript/mastodon/features/reblogs/index.js
+++ b/app/javascript/mastodon/features/reblogs/index.js
@@ -27,7 +27,6 @@ class Reblogs extends ImmutablePureComponent {
static propTypes = {
params: PropTypes.object.isRequired,
dispatch: PropTypes.func.isRequired,
- shouldUpdateScroll: PropTypes.func,
accountIds: ImmutablePropTypes.list,
multiColumn: PropTypes.bool,
intl: PropTypes.object.isRequired,
@@ -50,7 +49,7 @@ class Reblogs extends ImmutablePureComponent {
}
render () {
- const { intl, shouldUpdateScroll, accountIds, multiColumn } = this.props;
+ const { intl, accountIds, multiColumn } = this.props;
if (!accountIds) {
return (
@@ -74,7 +73,6 @@ class Reblogs extends ImmutablePureComponent {
diff --git a/app/javascript/mastodon/features/status/index.js b/app/javascript/mastodon/features/status/index.js
index df8362a1bc..69cd245fbc 100644
--- a/app/javascript/mastodon/features/status/index.js
+++ b/app/javascript/mastodon/features/status/index.js
@@ -45,7 +45,7 @@ import { initBlockModal } from '../../actions/blocks';
import { initBoostModal } from '../../actions/boosts';
import { initReport } from '../../actions/reports';
import { makeGetStatus, makeGetPictureInPicture } from '../../selectors';
-import { ScrollContainer } from 'react-router-scroll-4';
+import ScrollContainer from 'mastodon/containers/scroll_container';
import ColumnBackButton from '../../components/column_back_button';
import ColumnHeader from '../../components/column_header';
import StatusContainer from '../../containers/status_container';
@@ -498,7 +498,7 @@ class Status extends ImmutablePureComponent {
render () {
let ancestors, descendants;
- const { shouldUpdateScroll, status, ancestorsIds, descendantsIds, intl, domain, multiColumn, pictureInPicture } = this.props;
+ const { status, ancestorsIds, descendantsIds, intl, domain, multiColumn, pictureInPicture } = this.props;
const { fullscreen } = this.state;
if (status === null) {
@@ -541,7 +541,7 @@ class Status extends ImmutablePureComponent {
)}
/>
-
+
{ancestors}
diff --git a/app/javascript/mastodon/features/ui/components/audio_modal.js b/app/javascript/mastodon/features/ui/components/audio_modal.js
index 0676bd9cf1..c46fefce89 100644
--- a/app/javascript/mastodon/features/ui/components/audio_modal.js
+++ b/app/javascript/mastodon/features/ui/components/audio_modal.js
@@ -4,7 +4,6 @@ import PropTypes from 'prop-types';
import Audio from 'mastodon/features/audio';
import { connect } from 'react-redux';
import ImmutablePureComponent from 'react-immutable-pure-component';
-import { previewState } from './video_modal';
import Footer from 'mastodon/features/picture_in_picture/components/footer';
const mapStateToProps = (state, { statusId }) => ({
@@ -25,32 +24,6 @@ class AudioModal extends ImmutablePureComponent {
onChangeBackgroundColor: PropTypes.func.isRequired,
};
- static contextTypes = {
- router: PropTypes.object,
- };
-
- componentDidMount () {
- if (this.context.router) {
- const history = this.context.router.history;
-
- history.push(history.location.pathname, previewState);
-
- this.unlistenHistory = history.listen(() => {
- this.props.onClose();
- });
- }
- }
-
- componentWillUnmount () {
- if (this.context.router) {
- this.unlistenHistory();
-
- if (this.context.router.history.location.state === previewState) {
- this.context.router.history.goBack();
- }
- }
- }
-
render () {
const { media, accountStaticAvatar, statusId, onClose } = this.props;
const options = this.props.options || {};
diff --git a/app/javascript/mastodon/features/ui/components/media_modal.js b/app/javascript/mastodon/features/ui/components/media_modal.js
index 08da103304..061776e24e 100644
--- a/app/javascript/mastodon/features/ui/components/media_modal.js
+++ b/app/javascript/mastodon/features/ui/components/media_modal.js
@@ -20,8 +20,6 @@ const messages = defineMessages({
next: { id: 'lightbox.next', defaultMessage: 'Next' },
});
-export const previewState = 'previewMediaModal';
-
export default @injectIntl
class MediaModal extends ImmutablePureComponent {
@@ -37,10 +35,6 @@ class MediaModal extends ImmutablePureComponent {
volume: PropTypes.number,
};
- static contextTypes = {
- router: PropTypes.object,
- };
-
state = {
index: null,
navigationHidden: false,
@@ -98,16 +92,6 @@ class MediaModal extends ImmutablePureComponent {
componentDidMount () {
window.addEventListener('keydown', this.handleKeyDown, false);
- if (this.context.router) {
- const history = this.context.router.history;
-
- history.push(history.location.pathname, previewState);
-
- this.unlistenHistory = history.listen(() => {
- this.props.onClose();
- });
- }
-
this._sendBackgroundColor();
}
@@ -131,14 +115,6 @@ class MediaModal extends ImmutablePureComponent {
componentWillUnmount () {
window.removeEventListener('keydown', this.handleKeyDown);
- if (this.context.router) {
- this.unlistenHistory();
-
- if (this.context.router.history.location.state === previewState) {
- this.context.router.history.goBack();
- }
- }
-
this.props.onChangeBackgroundColor(null);
}
diff --git a/app/javascript/mastodon/features/ui/components/video_modal.js b/app/javascript/mastodon/features/ui/components/video_modal.js
index 2f13a175a1..7e8e1329d7 100644
--- a/app/javascript/mastodon/features/ui/components/video_modal.js
+++ b/app/javascript/mastodon/features/ui/components/video_modal.js
@@ -6,8 +6,6 @@ import ImmutablePureComponent from 'react-immutable-pure-component';
import Footer from 'mastodon/features/picture_in_picture/components/footer';
import { getAverageFromBlurhash } from 'mastodon/blurhash';
-export const previewState = 'previewVideoModal';
-
export default class VideoModal extends ImmutablePureComponent {
static propTypes = {
@@ -22,19 +20,9 @@ export default class VideoModal extends ImmutablePureComponent {
onChangeBackgroundColor: PropTypes.func.isRequired,
};
- static contextTypes = {
- router: PropTypes.object,
- };
-
componentDidMount () {
- const { router } = this.context;
const { media, onChangeBackgroundColor, onClose } = this.props;
- if (router) {
- router.history.push(router.history.location.pathname, previewState);
- this.unlistenHistory = router.history.listen(() => onClose());
- }
-
const backgroundColor = getAverageFromBlurhash(media.get('blurhash'));
if (backgroundColor) {
@@ -42,18 +30,6 @@ export default class VideoModal extends ImmutablePureComponent {
}
}
- componentWillUnmount () {
- const { router } = this.context;
-
- if (router) {
- this.unlistenHistory();
-
- if (router.history.location.state === previewState) {
- router.history.goBack();
- }
- }
- }
-
render () {
const { media, statusId, onClose } = this.props;
const options = this.props.options || {};
diff --git a/app/javascript/mastodon/features/ui/containers/modal_container.js b/app/javascript/mastodon/features/ui/containers/modal_container.js
index 2d27180f7e..ad1e8a2eea 100644
--- a/app/javascript/mastodon/features/ui/containers/modal_container.js
+++ b/app/javascript/mastodon/features/ui/containers/modal_container.js
@@ -3,8 +3,8 @@ import { closeModal } from '../../../actions/modal';
import ModalRoot from '../components/modal_root';
const mapStateToProps = state => ({
- type: state.get('modal').modalType,
- props: state.get('modal').modalProps,
+ type: state.getIn(['modal', 0, 'modalType'], null),
+ props: state.getIn(['modal', 0, 'modalProps'], {}),
});
const mapDispatchToProps = dispatch => ({
diff --git a/app/javascript/mastodon/features/ui/index.js b/app/javascript/mastodon/features/ui/index.js
index c1c6ac7397..756a692934 100644
--- a/app/javascript/mastodon/features/ui/index.js
+++ b/app/javascript/mastodon/features/ui/index.js
@@ -54,8 +54,6 @@ import {
FollowRecommendations,
} from './util/async-components';
import { me } from '../../initial_state';
-import { previewState as previewMediaState } from './components/media_modal';
-import { previewState as previewVideoState } from './components/video_modal';
import { closeOnboarding, INTRODUCTION_VERSION } from 'mastodon/actions/onboarding';
// Dummy import, to make sure that
ends up in the application bundle.
@@ -138,10 +136,6 @@ class SwitchingColumnsArea extends React.PureComponent {
}
}
- shouldUpdateScroll (_, { location }) {
- return location.state !== previewMediaState && location.state !== previewVideoState;
- }
-
setRef = c => {
if (c) {
this.node = c.getWrappedInstance();
@@ -158,38 +152,38 @@ class SwitchingColumnsArea extends React.PureComponent {
{redirect}
-
-
-
-
-
-
+
+
+
+
+
+
-
-
+
+
-
+
-
+
-
-
-
+
+
+
-
-
-
-
-
+
+
+
+
+
-
-
-
-
-
+
+
+
+
+
diff --git a/app/javascript/mastodon/reducers/modal.js b/app/javascript/mastodon/reducers/modal.js
index cb53887c74..ea81b43323 100644
--- a/app/javascript/mastodon/reducers/modal.js
+++ b/app/javascript/mastodon/reducers/modal.js
@@ -1,19 +1,15 @@
import { MODAL_OPEN, MODAL_CLOSE } from '../actions/modal';
import { TIMELINE_DELETE } from '../actions/timelines';
+import { Stack as ImmutableStack, Map as ImmutableMap } from 'immutable';
-const initialState = {
- modalType: null,
- modalProps: {},
-};
-
-export default function modal(state = initialState, action) {
+export default function modal(state = ImmutableStack(), action) {
switch(action.type) {
case MODAL_OPEN:
- return { modalType: action.modalType, modalProps: action.modalProps };
+ return state.unshift(ImmutableMap({ modalType: action.modalType, modalProps: action.modalProps }));
case MODAL_CLOSE:
- return (action.modalType === undefined || action.modalType === state.modalType) ? initialState : state;
+ return (action.modalType === undefined || action.modalType === state.getIn([0, 'modalType'])) ? state.shift() : state;
case TIMELINE_DELETE:
- return (state.modalProps.statusId === action.id) ? initialState : state;
+ return state.filterNot((modal) => modal.get('modalProps').statusId === action.id);
default:
return state;
}
diff --git a/config/deploy.rb b/config/deploy.rb
index f844cc8714..f642e6e59d 100644
--- a/config/deploy.rb
+++ b/config/deploy.rb
@@ -2,7 +2,7 @@
lock '3.16.0'
-set :repo_url, ENV.fetch('REPO', 'https://github.com/tootsuite/mastodon.git')
+set :repo_url, ENV.fetch('REPO', 'https://github.com/mastodon/mastodon.git')
set :branch, ENV.fetch('BRANCH', 'master')
set :application, 'mastodon'
diff --git a/db/migrate/20200508212852_reset_unique_jobs_locks.rb b/db/migrate/20200508212852_reset_unique_jobs_locks.rb
index 304e493223..d717ffc547 100644
--- a/db/migrate/20200508212852_reset_unique_jobs_locks.rb
+++ b/db/migrate/20200508212852_reset_unique_jobs_locks.rb
@@ -3,7 +3,7 @@ class ResetUniqueJobsLocks < ActiveRecord::Migration[5.2]
def up
# We do this to clean up unique job digests that were not properly
- # disposed of prior to https://github.com/tootsuite/mastodon/pull/13361
+ # disposed of prior to https://github.com/mastodon/mastodon/pull/13361
until SidekiqUniqueJobs::Digests.new.delete_by_pattern('*').nil?; end
end
diff --git a/lib/tasks/repo.rake b/lib/tasks/repo.rake
index 86c358a94e..d004c5751b 100644
--- a/lib/tasks/repo.rake
+++ b/lib/tasks/repo.rake
@@ -1,6 +1,6 @@
# frozen_string_literal: true
-REPOSITORY_NAME = 'tootsuite/mastodon'
+REPOSITORY_NAME = 'mastodon/mastodon'
namespace :repo do
desc 'Generate the AUTHORS.md file'
@@ -34,7 +34,7 @@ namespace :repo do
file << <<~FOOTER
- This document is provided for informational purposes only. Since it is only updated once per release, the version you are looking at may be currently out of date. To see the full list of contributors, consider looking at the [git history](https://github.com/tootsuite/mastodon/graphs/contributors) instead.
+ This document is provided for informational purposes only. Since it is only updated once per release, the version you are looking at may be currently out of date. To see the full list of contributors, consider looking at the [git history](https://github.com/mastodon/mastodon/graphs/contributors) instead.
FOOTER
end
diff --git a/package.json b/package.json
index 1c14ad610a..932911d6ce 100644
--- a/package.json
+++ b/package.json
@@ -1,5 +1,5 @@
{
- "name": "@tootsuite/mastodon",
+ "name": "@mastodon/mastodon",
"license": "AGPL-3.0-or-later",
"engines": {
"node": ">=12"
@@ -18,7 +18,7 @@
},
"repository": {
"type": "git",
- "url": "https://github.com/tootsuite/mastodon.git"
+ "url": "https://github.com/mastodon/mastodon.git"
},
"browserslist": [
"last 2 versions",
diff --git a/scalingo.json b/scalingo.json
index 324356df0c..51d9b5b9f5 100644
--- a/scalingo.json
+++ b/scalingo.json
@@ -1,8 +1,8 @@
{
"name": "Mastodon",
"description": "A GNU Social-compatible microblogging server",
- "repository": "https://github.com/tootsuite/mastodon",
- "logo": "https://github.com/tootsuite.png",
+ "repository": "https://github.com/mastodon/mastodon",
+ "logo": "https://github.com/mastodon.png",
"env": {
"LOCAL_DOMAIN": {
"description": "The domain that your Mastodon instance will run on (this can be appname.scalingo.io or a custom domain)",
diff --git a/spec/fixtures/xml/mastodon.atom b/spec/fixtures/xml/mastodon.atom
deleted file mode 100644
index 92921a9380..0000000000
--- a/spec/fixtures/xml/mastodon.atom
+++ /dev/null
@@ -1,261 +0,0 @@
-
-
- http://kickass.zone/users/localhost.atom
- ::1
- 2016-10-10T13:29:56Z
- http://kickass.zone/system/accounts/avatars/000/000/001/medium/eris.png
-
- http://activitystrea.ms/schema/1.0/person
- http://kickass.zone/users/localhost
- localhost
- localhost@kickass.zone
-
-
-
-
- localhost
- ::1
-
-
-
-
-
-
- tag:kickass.zone,2016-10-10:objectId=7:objectType=Follow
- 2016-10-10T13:29:56Z
- 2016-10-10T13:29:56Z
- localhost started following kat@mastodon.social
- localhost started following kat@mastodon.social
- http://activitystrea.ms/schema/1.0/follow
-
-
- http://activitystrea.ms/schema/1.0/activity
-
- http://activitystrea.ms/schema/1.0/person
- https://mastodon.social/users/kat
- kat
- kat@mastodon.social
- #trans #queer
-
-
-
-
- kat
- Kat
- #trans #queer
-
-
-
- tag:kickass.zone,2016-10-10:objectId=3:objectType=Favourite
- 2016-10-10T13:29:26Z
- 2016-10-10T13:29:26Z
- localhost favourited a status by kat@mastodon.social
- localhost favourited a status by kat@mastodon.social
- http://activitystrea.ms/schema/1.0/favorite
-
-
- http://activitystrea.ms/schema/1.0/activity
-
-
- http://activitystrea.ms/schema/1.0/comment
- tag:mastodon.social,2016-10-10:objectId=22833:objectType=Status
- @localhost oooh more mastodons ❤
-
- <p><a href="http://kickass.zone/users/localhost">@localhost</a> oooh more mastodons ❤</p>
- http://activitystrea.ms/schema/1.0/post
- 2016-10-10T13:23:35Z
- 2016-10-10T13:23:35Z
-
- http://activitystrea.ms/schema/1.0/person
- https://mastodon.social/users/kat
- kat
- kat@mastodon.social
- #trans #queer
-
-
-
-
- kat
- Kat
- #trans #queer
-
-
-
-
-
- tag:kickass.zone,2016-10-10:objectId=2:objectType=Favourite
- 2016-10-10T13:13:15Z
- 2016-10-10T13:13:15Z
- localhost favourited a status by Gargron@mastodon.social
- localhost favourited a status by Gargron@mastodon.social
- http://activitystrea.ms/schema/1.0/favorite
-
-
- http://activitystrea.ms/schema/1.0/activity
-
-
- http://activitystrea.ms/schema/1.0/note
- tag:mastodon.social,2016-10-10:objectId=22825:objectType=Status
- Deployed some fixes
-
- <p>Deployed some fixes</p>
- http://activitystrea.ms/schema/1.0/post
- 2016-10-10T13:10:37Z
- 2016-10-10T13:10:37Z
-
- http://activitystrea.ms/schema/1.0/person
- https://mastodon.social/users/Gargron
- Gargron
- Gargron@mastodon.social
- Developer of Mastodon, a GNU social alternative: https://github.com/tootsuite/mastodon
-
-
-
-
- Gargron
- Eugen
- Developer of Mastodon, a GNU social alternative: https://github.com/tootsuite/mastodon
-
-
-
-
- tag:kickass.zone,2016-10-10:objectId=17:objectType=Status
- 2016-10-10T00:41:31Z
- 2016-10-10T00:41:31Z
- Social media needs MOAR cats! http://kickass.zone/media/3
- <p>Social media needs MOAR cats! <a rel="nofollow noopener noreferrer" href="http://kickass.zone/media/3">http://kickass.zone/media/3</a></p>
- http://activitystrea.ms/schema/1.0/post
-
-
- http://activitystrea.ms/schema/1.0/note
-
-
-
- tag:kickass.zone,2016-10-10:objectId=14:objectType=Status
- 2016-10-10T00:38:39Z
- 2016-10-10T00:38:39Z
- http://kickass.zone/media/2
- <p><a rel="nofollow noopener noreferrer" href="http://kickass.zone/media/2">http://kickass.zone/media/2</a></p>
- http://activitystrea.ms/schema/1.0/post
-
-
- http://activitystrea.ms/schema/1.0/note
-
-
-
- tag:kickass.zone,2016-10-10:objectId=12:objectType=Status
- 2016-10-10T00:37:49Z
- 2016-10-10T00:37:49Z
-
- http://activitystrea.ms/schema/1.0/delete
-
-
- http://activitystrea.ms/schema/1.0/activity
-
-
- tag:kickass.zone,2016-10-10:objectId=4:objectType=Follow
- 2016-10-10T00:23:07Z
- 2016-10-10T00:23:07Z
- localhost started following bignimbus@mastodon.social
- localhost started following bignimbus@mastodon.social
- http://activitystrea.ms/schema/1.0/follow
-
-
- http://activitystrea.ms/schema/1.0/activity
-
- http://activitystrea.ms/schema/1.0/person
- https://mastodon.social/users/bignimbus
- bignimbus
- bignimbus@mastodon.social
- jdauriemma.com
-
-
-
-
- bignimbus
- Jeff Auriemma
- jdauriemma.com
-
-
-
- tag:kickass.zone,2016-10-10:objectId=2:objectType=Follow
- 2016-10-10T00:14:18Z
- 2016-10-10T00:14:18Z
- localhost started following Gargron@mastodon.social
- localhost started following Gargron@mastodon.social
- http://activitystrea.ms/schema/1.0/follow
-
-
- http://activitystrea.ms/schema/1.0/activity
-
- http://activitystrea.ms/schema/1.0/person
- https://mastodon.social/users/Gargron
- Gargron
- Gargron@mastodon.social
- Developer of Mastodon, a GNU social alternative: https://github.com/tootsuite/mastodon
-
-
-
-
- Gargron
- Eugen
- Developer of Mastodon, a GNU social alternative: https://github.com/tootsuite/mastodon
-
-
-
- tag:kickass.zone,2016-10-10:objectId=1:objectType=Follow
- 2016-10-10T00:09:09Z
- 2016-10-10T00:09:09Z
- localhost started following abc@mastodon.social
- localhost started following abc@mastodon.social
- http://activitystrea.ms/schema/1.0/follow
-
-
- http://activitystrea.ms/schema/1.0/activity
-
- http://activitystrea.ms/schema/1.0/person
- https://mastodon.social/users/abc
- abc
- abc@mastodon.social
-
-
-
-
- abc
- abc
-
-
-
- tag:kickass.zone,2016-10-10:objectId=3:objectType=Status
- 2016-10-10T00:02:47Z
- 2016-10-10T00:02:47Z
-
- http://activitystrea.ms/schema/1.0/delete
-
-
- http://activitystrea.ms/schema/1.0/activity
-
-
- tag:kickass.zone,2016-10-10:objectId=2:objectType=Status
- 2016-10-10T00:02:18Z
- 2016-10-10T00:02:18Z
- Yes, that was the obligatory first post. :)
- <p>Yes, that was the obligatory first post. :)</p>
- http://activitystrea.ms/schema/1.0/post
-
-
- http://activitystrea.ms/schema/1.0/comment
-
-
-
- tag:kickass.zone,2016-10-10:objectId=1:objectType=Status
- 2016-10-10T00:01:56Z
- 2016-10-10T00:01:56Z
- Hello, world!
- <p>Hello, world!</p>
- http://activitystrea.ms/schema/1.0/post
-
-
- http://activitystrea.ms/schema/1.0/note
-
-
diff --git a/spec/views/about/show.html.haml_spec.rb b/spec/views/about/show.html.haml_spec.rb
index 26b1319779..d608bbf5d3 100644
--- a/spec/views/about/show.html.haml_spec.rb
+++ b/spec/views/about/show.html.haml_spec.rb
@@ -19,7 +19,7 @@ describe 'about/show.html.haml', without_verify_partial_doubles: true do
site_short_description: 'something',
site_description: 'something',
version_number: '1.0',
- source_url: 'https://github.com/tootsuite/mastodon',
+ source_url: 'https://github.com/mastodon/mastodon',
open_registrations: false,
thumbnail: nil,
hero: nil,