Status Action Bar (#39702)
This commit is contained in:
12 files changed
+748
-124
No files matched your search
@@ -170,7 +170,7 @@ export const Footer: React.FC<{
|
||||
counter={status.get('replies_count') as number}
|
||||
/>
|
||||
|
||||
<BoostButton counters status={status} />
|
||||
<BoostButton counters statusId={statusId} />
|
||||
|
||||
<IconButton
|
||||
className='status__action-bar-button star-icon'
|
||||
|
||||
@@ -21,7 +21,8 @@ import { IconButton } from '../../../components/icon_button';
|
||||
import { Dropdown } from 'mastodon/components/dropdown_menu';
|
||||
import { me, quickBoosting } from '../../../initial_state';
|
||||
import { BoostButton } from '@/mastodon/components/status/boost_button';
|
||||
import { quoteItemState, selectStatusState } from '@/mastodon/components/status/boost_button_utils';
|
||||
import { quoteItemState } from '@/mastodon/components/status/boost_button_utils';
|
||||
import { selectStatusConditions } from '@/mastodon/selectors/statuses';
|
||||
|
||||
const messages = defineMessages({
|
||||
delete: { id: 'status.delete', defaultMessage: 'Delete' },
|
||||
@@ -62,7 +63,7 @@ const mapStateToProps = (state, { status }) => {
|
||||
return ({
|
||||
relationship: state.getIn(['relationships', status.getIn(['account', 'id'])]),
|
||||
quotedAccountId: quotedStatusId ? state.getIn(['statuses', quotedStatusId, 'account']) : null,
|
||||
statusQuoteState: selectStatusState(state, status),
|
||||
statusQuoteState: selectStatusConditions(state, status.get('id')),
|
||||
});
|
||||
};
|
||||
|
||||
@@ -330,7 +331,7 @@ class ActionBar extends PureComponent {
|
||||
<div className='detailed-status__action-bar'>
|
||||
<div className='detailed-status__button'><IconButton title={intl.formatMessage(messages.reply)} icon={status.get('in_reply_to_account_id') === status.getIn(['account', 'id']) ? 'reply' : replyIcon} iconComponent={status.get('in_reply_to_account_id') === status.getIn(['account', 'id']) ? ReplyIcon : replyIconComponent} onClick={this.handleReplyClick} /></div>
|
||||
<div className='detailed-status__button'>
|
||||
<BoostButton status={status} />
|
||||
<BoostButton statusId={status.get('id')} />
|
||||
</div>
|
||||
<div className='detailed-status__button'><IconButton className='star-icon' animate active={status.get('favourited')} title={favouriteTitle} icon='star' iconComponent={status.get('favourited') ? StarIcon : StarBorderIcon} onClick={this.handleFavouriteClick} /></div>
|
||||
<div className='detailed-status__button'><IconButton className='bookmark-icon' disabled={!signedIn} active={status.get('bookmarked')} title={bookmarkTitle} icon='bookmark' iconComponent={status.get('bookmarked') ? BookmarkIcon : BookmarkBorderIcon} onClick={this.handleBookmarkClick} /></div>
|
||||
|
||||
Reference in new issue
Block a user