0
0
Fork 0

Feature conversations muting (#3017)

* Add <ostatus:conversation /> tag to Atom input/output

Only uses ref attribute (not href) because href would be
the alternate link that's always included also.

Creates new conversation for every non-reply status. Carries
over conversation for every reply. Keeps remote URIs verbatim,
generates local URIs on the fly like the rest of them.

* Conversation muting - prevents notifications that reference a conversation
(including replies, favourites, reblogs) from being created. API endpoints
/api/v1/statuses/:id/mute and /api/v1/statuses/:id/unmute

Currently no way to tell when a status/conversation is muted, so the web UI
only has a "disable notifications" button, doesn't work as a toggle

* Display "Dismiss notifications" on all statuses in notifications column, not just own

* Add "muted" as a boolean attribute on statuses JSON

For now always false on contained reblogs, since it's only relevant for
statuses returned from the notifications endpoint, which are not nested

Remove "Disable notifications" from detailed status view, since it's
only relevant in the notifications column

* Up max class length

* Remove pending test for conversation mute

* Add tests, clean up

* Rename to "mute conversation" and "unmute conversation"

* Raise validation error when trying to mute/unmute status without conversation
This commit is contained in:
Eugen Rochko 2017-05-15 03:04:13 +02:00 committed by GitHub
parent a588358f41
commit d0dd9eb5b5
52 changed files with 422 additions and 27 deletions

View file

@ -15,6 +15,14 @@ export const CONTEXT_FETCH_REQUEST = 'CONTEXT_FETCH_REQUEST';
export const CONTEXT_FETCH_SUCCESS = 'CONTEXT_FETCH_SUCCESS';
export const CONTEXT_FETCH_FAIL = 'CONTEXT_FETCH_FAIL';
export const STATUS_MUTE_REQUEST = 'STATUS_MUTE_REQUEST';
export const STATUS_MUTE_SUCCESS = 'STATUS_MUTE_SUCCESS';
export const STATUS_MUTE_FAIL = 'STATUS_MUTE_FAIL';
export const STATUS_UNMUTE_REQUEST = 'STATUS_UNMUTE_REQUEST';
export const STATUS_UNMUTE_SUCCESS = 'STATUS_UNMUTE_SUCCESS';
export const STATUS_UNMUTE_FAIL = 'STATUS_UNMUTE_FAIL';
export function fetchStatusRequest(id, skipLoading) {
return {
type: STATUS_FETCH_REQUEST,
@ -139,3 +147,71 @@ export function fetchContextFail(id, error) {
skipAlert: true
};
};
export function muteStatus(id) {
return (dispatch, getState) => {
dispatch(muteStatusRequest(id));
api(getState).post(`/api/v1/statuses/${id}/mute`).then(response => {
dispatch(muteStatusSuccess(id));
}).catch(error => {
dispatch(muteStatusFail(id, error));
});
};
};
export function muteStatusRequest(id) {
return {
type: STATUS_MUTE_REQUEST,
id
};
};
export function muteStatusSuccess(id) {
return {
type: STATUS_MUTE_SUCCESS,
id
};
};
export function muteStatusFail(id, error) {
return {
type: STATUS_MUTE_FAIL,
id,
error
};
};
export function unmuteStatus(id) {
return (dispatch, getState) => {
dispatch(unmuteStatusRequest(id));
api(getState).post(`/api/v1/statuses/${id}/unmute`).then(response => {
dispatch(unmuteStatusSuccess(id));
}).catch(error => {
dispatch(unmuteStatusFail(id, error));
});
};
};
export function unmuteStatusRequest(id) {
return {
type: STATUS_UNMUTE_REQUEST,
id
};
};
export function unmuteStatusSuccess(id) {
return {
type: STATUS_UNMUTE_SUCCESS,
id
};
};
export function unmuteStatusFail(id, error) {
return {
type: STATUS_UNMUTE_FAIL,
id,
error
};
};

View file

@ -16,7 +16,9 @@ const messages = defineMessages({
cannot_reblog: { id: 'status.cannot_reblog', defaultMessage: 'This post cannot be boosted' },
favourite: { id: 'status.favourite', defaultMessage: 'Favourite' },
open: { id: 'status.open', defaultMessage: 'Expand this status' },
report: { id: 'status.report', defaultMessage: 'Report @{name}' }
report: { id: 'status.report', defaultMessage: 'Report @{name}' },
muteConversation: { id: 'status.mute_conversation', defaultMessage: 'Mute conversation' },
unmuteConversation: { id: 'status.unmute_conversation', defaultMessage: 'Unmute conversation' },
});
class StatusActionBar extends React.PureComponent {
@ -35,7 +37,9 @@ class StatusActionBar extends React.PureComponent {
onMute: PropTypes.func,
onBlock: PropTypes.func,
onReport: PropTypes.func,
onMuteConversation: PropTypes.func,
me: PropTypes.number.isRequired,
withDismiss: PropTypes.bool,
intl: PropTypes.object.isRequired
};
@ -76,9 +80,14 @@ class StatusActionBar extends React.PureComponent {
this.context.router.push('/report');
}
handleConversationMuteClick = () => {
this.props.onMuteConversation(this.props.status);
}
render () {
const { status, me, intl } = this.props;
const { status, me, intl, withDismiss } = this.props;
const reblogDisabled = status.get('visibility') === 'private' || status.get('visibility') === 'direct';
const mutingConversation = status.get('muted');
let menu = [];
let reblogIcon = 'retweet';
@ -88,6 +97,11 @@ class StatusActionBar extends React.PureComponent {
menu.push({ text: intl.formatMessage(messages.open), action: this.handleOpen });
menu.push(null);
if (withDismiss) {
menu.push({ text: intl.formatMessage(mutingConversation ? messages.unmuteConversation : messages.muteConversation), action: this.handleConversationMuteClick });
menu.push(null);
}
if (status.getIn(['account', 'id']) === me) {
menu.push({ text: intl.formatMessage(messages.delete), action: this.handleDeleteClick });
} else {

View file

@ -16,7 +16,7 @@ import {
blockAccount,
muteAccount
} from '../actions/accounts';
import { deleteStatus } from '../actions/statuses';
import { muteStatus, unmuteStatus, deleteStatus } from '../actions/statuses';
import { initReport } from '../actions/reports';
import { openModal } from '../actions/modal';
import { createSelector } from 'reselect'
@ -113,6 +113,14 @@ const mapDispatchToProps = (dispatch, { intl }) => ({
}));
},
onMuteConversation (status) {
if (status.get('muted')) {
dispatch(unmuteStatus(status.get('id')));
} else {
dispatch(muteStatus(status.get('id')));
}
},
});
export default injectIntl(connect(makeMapStateToProps, mapDispatchToProps)(Status));

View file

@ -32,7 +32,7 @@ class Notification extends ImmutablePureComponent {
}
renderMention (notification) {
return <StatusContainer id={notification.get('status')} />;
return <StatusContainer id={notification.get('status')} withDismiss />;
}
renderFavourite (notification, link) {
@ -45,7 +45,7 @@ class Notification extends ImmutablePureComponent {
<FormattedMessage id='notification.favourite' defaultMessage='{name} favourited your status' values={{ name: link }} />
</div>
<StatusContainer id={notification.get('status')} account={notification.get('account')} muted={true} />
<StatusContainer id={notification.get('status')} account={notification.get('account')} muted={true} withDismiss />
</div>
);
}
@ -60,7 +60,7 @@ class Notification extends ImmutablePureComponent {
<FormattedMessage id='notification.reblog' defaultMessage='{name} boosted your status' values={{ name: link }} />
</div>
<StatusContainer id={notification.get('status')} account={notification.get('account')} muted={true} />
<StatusContainer id={notification.get('status')} account={notification.get('account')} muted={true} withDismiss />
</div>
);
}

View file

@ -12,7 +12,7 @@ const messages = defineMessages({
reblog: { id: 'status.reblog', defaultMessage: 'Boost' },
cannot_reblog: { id: 'status.cannot_reblog', defaultMessage: 'This post cannot be boosted' },
favourite: { id: 'status.favourite', defaultMessage: 'Favourite' },
report: { id: 'status.report', defaultMessage: 'Report @{name}' }
report: { id: 'status.report', defaultMessage: 'Report @{name}' },
});
class ActionBar extends React.PureComponent {

View file

@ -171,8 +171,24 @@ class Status extends ImmutablePureComponent {
<div className='scrollable detailed-status__wrapper'>
{ancestors}
<DetailedStatus status={status} autoPlayGif={autoPlayGif} me={me} onOpenVideo={this.handleOpenVideo} onOpenMedia={this.handleOpenMedia} />
<ActionBar status={status} me={me} onReply={this.handleReplyClick} onFavourite={this.handleFavouriteClick} onReblog={this.handleReblogClick} onDelete={this.handleDeleteClick} onMention={this.handleMentionClick} onReport={this.handleReport} />
<DetailedStatus
status={status}
autoPlayGif={autoPlayGif}
me={me}
onOpenVideo={this.handleOpenVideo}
onOpenMedia={this.handleOpenMedia}
/>
<ActionBar
status={status}
me={me}
onReply={this.handleReplyClick}
onFavourite={this.handleFavouriteClick}
onReblog={this.handleReblogClick}
onDelete={this.handleDeleteClick}
onMention={this.handleMentionClick}
onReport={this.handleReport}
/>
{descendants}
</div>

View file

@ -142,6 +142,7 @@
"status.load_more": "حمّل المزيد",
"status.media_hidden": "الصورة مستترة",
"status.mention": "أذكُر @{name}",
"status.mute_conversation": "Mute conversation",
"status.open": "وسع هذه المشاركة",
"status.reblog": "رَقِّي",
"status.reblogged_by": "{name} رقى",
@ -152,6 +153,7 @@
"status.sensitive_warning": "محتوى حساس",
"status.show_less": "إعرض أقلّ",
"status.show_more": "أظهر المزيد",
"status.unmute_conversation": "Unmute conversation",
"tabs_bar.compose": "تحرير",
"tabs_bar.federated_timeline": "الموحَّد",
"tabs_bar.home": "الرئيسية",

View file

@ -142,6 +142,7 @@
"status.load_more": "Load more",
"status.media_hidden": "Media hidden",
"status.mention": "Споменаване",
"status.mute_conversation": "Mute conversation",
"status.open": "Expand this status",
"status.reblog": "Споделяне",
"status.reblogged_by": "{name} сподели",
@ -152,6 +153,7 @@
"status.sensitive_warning": "Деликатно съдържание",
"status.show_less": "Show less",
"status.show_more": "Show more",
"status.unmute_conversation": "Unmute conversation",
"tabs_bar.compose": "Съставяне",
"tabs_bar.federated_timeline": "Federated",
"tabs_bar.home": "Начало",

View file

@ -142,6 +142,7 @@
"status.load_more": "Weitere laden",
"status.media_hidden": "Medien versteckt",
"status.mention": "Erwähnen",
"status.mute_conversation": "Mute conversation",
"status.open": "Öffnen",
"status.reblog": "Teilen",
"status.reblogged_by": "{name} teilte",
@ -152,6 +153,7 @@
"status.sensitive_warning": "Heikle Inhalte",
"status.show_less": "Weniger anzeigen",
"status.show_more": "Mehr anzeigen",
"status.unmute_conversation": "Unmute conversation",
"tabs_bar.compose": "Schreiben",
"tabs_bar.federated_timeline": "Föderation",
"tabs_bar.home": "Home",

View file

@ -144,6 +144,14 @@
{
"defaultMessage": "Report @{name}",
"id": "status.report"
},
{
"defaultMessage": "Mute conversation",
"id": "status.mute_conversation"
},
{
"defaultMessage": "Unmute conversation",
"id": "status.unmute_conversation"
}
],
"path": "app/javascript/mastodon/components/status_action_bar.json"
@ -184,10 +192,6 @@
"defaultMessage": "Expand video",
"id": "video_player.expand"
},
{
"defaultMessage": "Video could not be played",
"id": "video_player.video_error"
},
{
"defaultMessage": "Sensitive content",
"id": "status.sensitive_warning"
@ -199,6 +203,10 @@
{
"defaultMessage": "Media hidden",
"id": "status.media_hidden"
},
{
"defaultMessage": "Video could not be played",
"id": "video_player.video_error"
}
],
"path": "app/javascript/mastodon/components/video_player.json"

View file

@ -142,6 +142,7 @@
"status.load_more": "Load more",
"status.media_hidden": "Media hidden",
"status.mention": "Mention @{name}",
"status.mute_conversation": "Mute conversation",
"status.open": "Expand this status",
"status.reblog": "Boost",
"status.reblogged_by": "{name} boosted",
@ -152,6 +153,7 @@
"status.sensitive_warning": "Sensitive content",
"status.show_less": "Show less",
"status.show_more": "Show more",
"status.unmute_conversation": "Unmute conversation",
"tabs_bar.compose": "Compose",
"tabs_bar.federated_timeline": "Federated",
"tabs_bar.home": "Home",

View file

@ -142,6 +142,7 @@
"status.load_more": "Load more",
"status.media_hidden": "Media hidden",
"status.mention": "Mencii @{name}",
"status.mute_conversation": "Mute conversation",
"status.open": "Expand this status",
"status.reblog": "Diskonigi",
"status.reblogged_by": "{name} diskonigita",
@ -152,6 +153,7 @@
"status.sensitive_warning": "Tikla enhavo",
"status.show_less": "Show less",
"status.show_more": "Show more",
"status.unmute_conversation": "Unmute conversation",
"tabs_bar.compose": "Ekskribi",
"tabs_bar.federated_timeline": "Federated",
"tabs_bar.home": "Hejmo",

View file

@ -142,6 +142,7 @@
"status.load_more": "Load more",
"status.media_hidden": "Media hidden",
"status.mention": "Mencionar",
"status.mute_conversation": "Mute conversation",
"status.open": "Expandir estado",
"status.reblog": "Retoot",
"status.reblogged_by": "Retooteado por {name}",
@ -152,6 +153,7 @@
"status.sensitive_warning": "Contenido sensible",
"status.show_less": "Mostrar menos",
"status.show_more": "Mostrar más",
"status.unmute_conversation": "Unmute conversation",
"tabs_bar.compose": "Redactar",
"tabs_bar.federated_timeline": "Federated",
"tabs_bar.home": "Inicio",

View file

@ -142,6 +142,7 @@
"status.load_more": "بیشتر نشان بده",
"status.media_hidden": "تصویر پنهان شده",
"status.mention": "نام‌بردن از @{name}",
"status.mute_conversation": "Mute conversation",
"status.open": "این نوشته را باز کن",
"status.reblog": "بازبوقیدن",
"status.reblogged_by": "{name} بازبوقید",
@ -152,6 +153,7 @@
"status.sensitive_warning": "محتوای حساس",
"status.show_less": "نهفتن",
"status.show_more": "نمایش",
"status.unmute_conversation": "Unmute conversation",
"tabs_bar.compose": "بنویسید",
"tabs_bar.federated_timeline": "همگانی",
"tabs_bar.home": "خانه",

View file

@ -142,6 +142,7 @@
"status.load_more": "Load more",
"status.media_hidden": "Media hidden",
"status.mention": "Mainitse @{name}",
"status.mute_conversation": "Mute conversation",
"status.open": "Expand this status",
"status.reblog": "Buustaa",
"status.reblogged_by": "{name} buustasi",
@ -152,6 +153,7 @@
"status.sensitive_warning": "Arkaluontoista sisältöä",
"status.show_less": "Show less",
"status.show_more": "Show more",
"status.unmute_conversation": "Unmute conversation",
"tabs_bar.compose": "Luo",
"tabs_bar.federated_timeline": "Federated",
"tabs_bar.home": "Koti",

View file

@ -142,6 +142,7 @@
"status.load_more": "Charger plus",
"status.media_hidden": "Média caché",
"status.mention": "Mentionner",
"status.mute_conversation": "Mute conversation",
"status.open": "Déplier ce statut",
"status.reblog": "Partager",
"status.reblogged_by": "{name} a partagé :",
@ -152,6 +153,7 @@
"status.sensitive_warning": "Contenu délicat",
"status.show_less": "Replier",
"status.show_more": "Déplier",
"status.unmute_conversation": "Unmute conversation",
"tabs_bar.compose": "Composer",
"tabs_bar.federated_timeline": "Fil public global",
"tabs_bar.home": "Accueil",

View file

@ -142,6 +142,7 @@
"status.load_more": "עוד",
"status.media_hidden": "מדיה מוסתרת",
"status.mention": "פניה אל @{name}",
"status.mute_conversation": "Mute conversation",
"status.open": "הרחבת הודעה",
"status.reblog": "הדהוד",
"status.reblogged_by": "הודהד על ידי {name}",
@ -152,6 +153,7 @@
"status.sensitive_warning": "תוכן רגיש",
"status.show_less": "הראה פחות",
"status.show_more": "הראה יותר",
"status.unmute_conversation": "Unmute conversation",
"tabs_bar.compose": "חיבור",
"tabs_bar.federated_timeline": "ציר זמן בין-קהילתי",
"tabs_bar.home": "בבית",

View file

@ -142,6 +142,7 @@
"status.load_more": "Učitaj više",
"status.media_hidden": "Sakriven media sadržaj",
"status.mention": "Spomeni @{name}",
"status.mute_conversation": "Mute conversation",
"status.open": "Proširi ovaj status",
"status.reblog": "Podigni",
"status.reblogged_by": "{name} je podigao",
@ -152,6 +153,7 @@
"status.sensitive_warning": "Osjetljiv sadržaj",
"status.show_less": "Pokaži manje",
"status.show_more": "Pokaži više",
"status.unmute_conversation": "Unmute conversation",
"tabs_bar.compose": "Sastavi",
"tabs_bar.federated_timeline": "Federalni",
"tabs_bar.home": "Dom",

View file

@ -142,6 +142,7 @@
"status.load_more": "Load more",
"status.media_hidden": "Media hidden",
"status.mention": "Említés",
"status.mute_conversation": "Mute conversation",
"status.open": "Expand this status",
"status.reblog": "Reblog",
"status.reblogged_by": "{name} reblogolta",
@ -152,6 +153,7 @@
"status.sensitive_warning": "Érzékeny tartalom",
"status.show_less": "Show less",
"status.show_more": "Show more",
"status.unmute_conversation": "Unmute conversation",
"tabs_bar.compose": "Összeállítás",
"tabs_bar.federated_timeline": "Federated",
"tabs_bar.home": "Kezdőlap",

View file

@ -142,6 +142,7 @@
"status.load_more": "Tampilkan semua",
"status.media_hidden": "Media disembunyikan",
"status.mention": "Balasan @{name}",
"status.mute_conversation": "Mute conversation",
"status.open": "Tampilkan status ini",
"status.reblog": "Boost",
"status.reblogged_by": "di-boost {name}",
@ -152,6 +153,7 @@
"status.sensitive_warning": "Konten sensitif",
"status.show_less": "Tampilkan lebih sedikit",
"status.show_more": "Tampilkan semua",
"status.unmute_conversation": "Unmute conversation",
"tabs_bar.compose": "Tulis",
"tabs_bar.federated_timeline": "Gabungan",
"tabs_bar.home": "Beranda",

View file

@ -142,6 +142,7 @@
"status.load_more": "Kargar pluse",
"status.media_hidden": "Kontenajo celita",
"status.mention": "Mencionar @{name}",
"status.mute_conversation": "Mute conversation",
"status.open": "Detaligar ca mesajo",
"status.reblog": "Repetar",
"status.reblogged_by": "{name} repetita",
@ -152,6 +153,7 @@
"status.sensitive_warning": "Trubliva kontenajo",
"status.show_less": "Montrar mine",
"status.show_more": "Montrar plue",
"status.unmute_conversation": "Unmute conversation",
"tabs_bar.compose": "Kompozar",
"tabs_bar.federated_timeline": "Federata",
"tabs_bar.home": "Hemo",

View file

@ -142,6 +142,7 @@
"status.load_more": "Mostra di più",
"status.media_hidden": "Allegato nascosto",
"status.mention": "Nomina @{name}",
"status.mute_conversation": "Mute conversation",
"status.open": "Espandi questo post",
"status.reblog": "Condividi",
"status.reblogged_by": "{name} ha condiviso",
@ -152,6 +153,7 @@
"status.sensitive_warning": "Materiale sensibile",
"status.show_less": "Mostra meno",
"status.show_more": "Mostra di più",
"status.unmute_conversation": "Unmute conversation",
"tabs_bar.compose": "Scrivi",
"tabs_bar.federated_timeline": "Federazione",
"tabs_bar.home": "Home",

View file

@ -142,6 +142,7 @@
"status.load_more": "もっと見る",
"status.media_hidden": "非表示のメデイア",
"status.mention": "返信",
"status.mute_conversation": "Mute conversation",
"status.open": "詳細を表示",
"status.reblog": "ブースト",
"status.reblogged_by": "{name} さんにブーストされました",
@ -152,6 +153,7 @@
"status.sensitive_warning": "閲覧注意",
"status.show_less": "隠す",
"status.show_more": "もっと見る",
"status.unmute_conversation": "Unmute conversation",
"tabs_bar.compose": "投稿",
"tabs_bar.federated_timeline": "連合",
"tabs_bar.home": "ホーム",

View file

@ -140,6 +140,7 @@
"status.load_more": "Meer laden",
"status.media_hidden": "Media verborgen",
"status.mention": "Vermeld @{name}",
"status.mute_conversation": "Mute conversation",
"status.open": "Toot volledig tonen",
"status.reblog": "Boost",
"status.reblogged_by": "{name} boostte",
@ -150,6 +151,7 @@
"status.sensitive_warning": "Gevoelige inhoud",
"status.show_less": "Minder tonen",
"status.show_more": "Meer tonen",
"status.unmute_conversation": "Unmute conversation",
"tabs_bar.compose": "Schrijven",
"tabs_bar.federated_timeline": "Globaal",
"tabs_bar.home": "Jouw tijdlijn",

View file

@ -142,6 +142,7 @@
"status.load_more": "Last mer",
"status.media_hidden": "Media skjult",
"status.mention": "Nevn @{name}",
"status.mute_conversation": "Mute conversation",
"status.open": "Utvid denne statusen",
"status.reblog": "Fremhev",
"status.reblogged_by": "Fremhevd av {name}",
@ -152,6 +153,7 @@
"status.sensitive_warning": "Følsomt innhold",
"status.show_less": "Vis mindre",
"status.show_more": "Vis mer",
"status.unmute_conversation": "Unmute conversation",
"tabs_bar.compose": "Komponer",
"tabs_bar.federated_timeline": "Felles",
"tabs_bar.home": "Hjem",

View file

@ -142,6 +142,7 @@
"status.load_more": "Cargar mai",
"status.media_hidden": "Mèdia rescondut",
"status.mention": "Mencionar",
"status.mute_conversation": "Mute conversation",
"status.open": "Desplegar aqueste estatut",
"status.reblog": "Partejar",
"status.reblogged_by": "{name} a partejat :",
@ -152,6 +153,7 @@
"status.sensitive_warning": "Contengut embarrassant",
"status.show_less": "Tornar plegar",
"status.show_more": "Desplegar",
"status.unmute_conversation": "Unmute conversation",
"tabs_bar.compose": "Compausar",
"tabs_bar.federated_timeline": "Fil public global",
"tabs_bar.home": "Acuèlh",

View file

@ -142,6 +142,7 @@
"status.load_more": "Załaduj więcej",
"status.media_hidden": "Zawartość multimedialna ukryta",
"status.mention": "Wspomnij o @{name}",
"status.mute_conversation": "Mute conversation",
"status.open": "Rozszerz ten status",
"status.reblog": "Podbij",
"status.reblogged_by": "{name} podbił",
@ -152,6 +153,7 @@
"status.sensitive_warning": "Wrażliwa zawartość",
"status.show_less": "Pokaż mniej",
"status.show_more": "Pokaż więcej",
"status.unmute_conversation": "Unmute conversation",
"tabs_bar.compose": "Napisz",
"tabs_bar.federated_timeline": "Globalne",
"tabs_bar.home": "Strona główna",

View file

@ -142,6 +142,7 @@
"status.load_more": "Carregar mais",
"status.media_hidden": "Media escondida",
"status.mention": "Mencionar @{name}",
"status.mute_conversation": "Mute conversation",
"status.open": "Expandir",
"status.reblog": "Partilhar",
"status.reblogged_by": "{name} partilhou",
@ -152,6 +153,7 @@
"status.sensitive_warning": "Conteúdo sensível",
"status.show_less": "Mostrar menos",
"status.show_more": "Mostrar mais",
"status.unmute_conversation": "Unmute conversation",
"tabs_bar.compose": "Criar",
"tabs_bar.federated_timeline": "Global",
"tabs_bar.home": "Home",

View file

@ -142,6 +142,7 @@
"status.load_more": "Carregar mais",
"status.media_hidden": "Media escondida",
"status.mention": "Mencionar @{name}",
"status.mute_conversation": "Mute conversation",
"status.open": "Expandir",
"status.reblog": "Partilhar",
"status.reblogged_by": "{name} partilhou",
@ -152,6 +153,7 @@
"status.sensitive_warning": "Conteúdo sensível",
"status.show_less": "Mostrar menos",
"status.show_more": "Mostrar mais",
"status.unmute_conversation": "Unmute conversation",
"tabs_bar.compose": "Criar",
"tabs_bar.federated_timeline": "Global",
"tabs_bar.home": "Home",

View file

@ -142,6 +142,7 @@
"status.load_more": "Показать еще",
"status.media_hidden": "Медиаконтент скрыт",
"status.mention": "Упомянуть @{name}",
"status.mute_conversation": "Mute conversation",
"status.open": "Развернуть статус",
"status.reblog": "Продвинуть",
"status.reblogged_by": "{name} продвинул(а)",
@ -152,6 +153,7 @@
"status.sensitive_warning": "Чувствительный контент",
"status.show_less": "Свернуть",
"status.show_more": "Развернуть",
"status.unmute_conversation": "Unmute conversation",
"tabs_bar.compose": "Написать",
"tabs_bar.federated_timeline": "Глобальная",
"tabs_bar.home": "Главная",

View file

@ -142,6 +142,7 @@
"status.load_more": "Daha fazla",
"status.media_hidden": "Gizli görsel",
"status.mention": "Bahset @{name}",
"status.mute_conversation": "Mute conversation",
"status.open": "Bu gönderiyi genişlet",
"status.reblog": "Boost'la",
"status.reblogged_by": "{name} boost etti",
@ -152,6 +153,7 @@
"status.sensitive_warning": "Hassas içerik",
"status.show_less": "Daha azı",
"status.show_more": "Daha fazlası",
"status.unmute_conversation": "Unmute conversation",
"tabs_bar.compose": "Oluştur",
"tabs_bar.federated_timeline": "Federe",
"tabs_bar.home": "Ana sayfa",

View file

@ -142,6 +142,7 @@
"status.load_more": "Завантажити більше",
"status.media_hidden": "Медіаконтент приховано",
"status.mention": "Згадати",
"status.mute_conversation": "Mute conversation",
"status.open": "Розгорнути допис",
"status.reblog": "Передмухнути",
"status.reblogged_by": "{name} передмухнув(-ла)",
@ -152,6 +153,7 @@
"status.sensitive_warning": "Непристойний зміст",
"status.show_less": "Згорнути",
"status.show_more": "Розгорнути",
"status.unmute_conversation": "Unmute conversation",
"tabs_bar.compose": "Написати",
"tabs_bar.federated_timeline": "Глобальна",
"tabs_bar.home": "Головна",

View file

@ -142,6 +142,7 @@
"status.load_more": "加载更多",
"status.media_hidden": "隐藏媒体内容",
"status.mention": "提及 @{name}",
"status.mute_conversation": "Mute conversation",
"status.open": "展开嘟文",
"status.reblog": "转嘟",
"status.reblogged_by": "{name} 转嘟",
@ -152,6 +153,7 @@
"status.sensitive_warning": "敏感内容",
"status.show_less": "减少显示",
"status.show_more": "显示更多",
"status.unmute_conversation": "Unmute conversation",
"tabs_bar.compose": "撰写",
"tabs_bar.federated_timeline": "跨站",
"tabs_bar.home": "主页",

View file

@ -142,6 +142,7 @@
"status.load_more": "載入更多",
"status.media_hidden": "隱藏媒體內容",
"status.mention": "提及 @{name}",
"status.mute_conversation": "Mute conversation",
"status.open": "展開文章",
"status.reblog": "轉推",
"status.reblogged_by": "{name} 轉推",
@ -152,6 +153,7 @@
"status.sensitive_warning": "敏感內容",
"status.show_less": "減少顯示",
"status.show_more": "顯示更多",
"status.unmute_conversation": "Unmute conversation",
"tabs_bar.compose": "撰寫",
"tabs_bar.federated_timeline": "跨站",
"tabs_bar.home": "主頁",

View file

@ -10,7 +10,9 @@ import {
} from '../actions/interactions';
import {
STATUS_FETCH_SUCCESS,
CONTEXT_FETCH_SUCCESS
CONTEXT_FETCH_SUCCESS,
STATUS_MUTE_SUCCESS,
STATUS_UNMUTE_SUCCESS
} from '../actions/statuses';
import {
TIMELINE_REFRESH_SUCCESS,
@ -103,6 +105,10 @@ export default function statuses(state = initialState, action) {
return state.setIn([action.status.get('id'), 'reblogged'], true);
case REBLOG_FAIL:
return state.setIn([action.status.get('id'), 'reblogged'], false);
case STATUS_MUTE_SUCCESS:
return state.setIn([action.id, 'muted'], true);
case STATUS_UNMUTE_SUCCESS:
return state.setIn([action.id, 'muted'], false);
case TIMELINE_REFRESH_SUCCESS:
case TIMELINE_EXPAND_SUCCESS:
case ACCOUNT_TIMELINE_FETCH_SUCCESS: