-{"version":3,"sources":["webpack:///app/javascript/builds/pleroma/mastofe/app/javascript/mastodon/features/status/components/detailed_status.js","webpack:///app/javascript/builds/pleroma/mastofe/app/javascript/mastodon/features/status/components/action_bar.js","webpack:///app/javascript/builds/pleroma/mastofe/app/javascript/mastodon/features/status/index.js"],"names":["DetailedStatus","height","e","button","ctrlKey","metaKey","_this","context","router","preventDefault","history","push","props","status","getIn","stopPropagation","media","startTime","onOpenVideo","onToggleHidden","c","node","_measureHeight","href","target","nodeName","parentNode","window","open","heightJustChanged","_this2","this","measureHeight","scheduleIdleTask","setState","Math","ceil","scrollHeight","onHeightChange","componentDidUpdate","prevProps","prevState","state","render","get","outerStyle","boxSizing","compact","applicationLink","reblogLink","reblogIcon","favouriteLink","size","some","item","Object","_babel_runtime_helpers_esm_jsx__WEBPACK_IMPORTED_MODULE_0__","_components_attachment_list__WEBPACK_IMPORTED_MODULE_11__","video","_video__WEBPACK_IMPORTED_MODULE_16__","preview","src","alt","width","inline","handleOpenVideo","sensitive","_components_media_gallery__WEBPACK_IMPORTED_MODULE_10__","standalone","onOpenMedia","length","_card__WEBPACK_IMPORTED_MODULE_14__","card","className","rel","mastodon_components_icon__WEBPACK_IMPORTED_MODULE_19__","id","react_router_dom__WEBPACK_IMPORTED_MODULE_12__","to","react_intl__WEBPACK_IMPORTED_MODULE_13__","value","onClick","handleModalLink","style","react__WEBPACK_IMPORTED_MODULE_4___default","a","createElement","ref","setRef","classNames","handleAccountClick","_components_avatar__WEBPACK_IMPORTED_MODULE_7__","account","_components_display_name__WEBPACK_IMPORTED_MODULE_8__","localDomain","domain","_components_status_content__WEBPACK_IMPORTED_MODULE_9__","expanded","onExpandedToggle","handleExpandedToggle","Date","hour12","year","month","day","hour","minute","ImmutablePureComponent","PropTypes","object","ImmutablePropTypes","map","isRequired","func","bool","string","messages","defineMessages","delete","defaultMessage","redraft","direct","mention","reply","reblog","reblog_private","cancel_reblog_private","cannot_reblog","favourite","mute","muteConversation","unmuteConversation","block","report","share","pin","unpin","embed","admin_account","admin_status","ActionBar","injectIntl","onReply","onReblog","onFavourite","onDelete","onDirect","onMention","onMute","onMuteConversation","onBlock","onReport","onPin","navigator","text","url","onEmbed","_this$props","intl","publicStatus","includes","mutingConversation","menu","formatMessage","action","handleEmbed","me","handlePinClick","handleReblogClick","handleConversationMuteClick","handleDeleteClick","handleRedraftClick","name","handleMentionClick","handleDirectClick","handleMuteClick","handleBlockClick","handleReport","isStaff","replyIcon","shareButton","jsx","icon_button","title","icon","handleShare","reblog_disabled","handleReplyClick","disabled","active","animate","handleFavouriteClick","dropdown_menu_container","items","direction","React","PureComponent","deleteConfirm","deleteMessage","redraftConfirm","redraftMessage","blockConfirm","revealAll","hideAll","detailedStatus","replyConfirm","replyMessage","Status","connect","getStatus","makeGetStatus","params","statusId","ancestorsIds","Immutable","List","descendantsIds","withMutations","mutable","unshift","ids","shift","replies","reverse","forEach","askReplyConfirmation","trim","fullscreen","dispatch","unfavourite","openModal","message","confirm","onConfirm","replyCompose","unreblog","shiftKey","boostModal","handleModalReblog","withRedraft","_this$props2","deleteModal","deleteStatus","directCompose","mentionCompose","index","time","initMuteModal","unmuteStatus","muteStatus","revealStatus","hideStatus","_this$props3","statusIds","concat","toJS","_this$props4","index_es","values","blockAccount","initReport","handleMoveUp","handleMoveDown","handleToggleHidden","_this$props5","_selectChild","indexOf","_this$props6","isFullscreen","componentWillMount","fetchStatus","componentDidMount","attachFullscreenListener","onFullScreenChange","componentWillReceiveProps","nextProps","_scrolledIntoView","element","querySelectorAll","focus","renderChildren","list","status_container","onMoveUp","onMoveDown","contextType","_this$props7","requestAnimationFrame","scrollIntoView","componentWillUnmount","detachFullscreenListener","ancestors","descendants","_this$props8","shouldUpdateScroll","column","column_back_button","missing_indicator","handlers","moveUp","handleHotkeyMoveUp","moveDown","handleHotkeyMoveDown","handleHotkeyReply","handleHotkeyFavourite","boost","handleHotkeyBoost","handleHotkeyMention","openProfile","handleHotkeyOpenProfile","toggleHidden","handleHotkeyToggleHidden","label","column_header","showBackButton","extraButton","aria-label","handleToggleAll","aria-pressed","react_router_scroll_4_es","scrollKey","react_default","react_hotkeys_index_es","tabIndex","textForScreenReader","detailed_status","handleOpenMedia","action_bar_ActionBar","handlePin"],"mappings":"qUAiBqBA,qMAiBX,CACNC,OAAQ,oEAGW,SAACC,GACH,IAAbA,EAAEC,QAAkBD,EAAEE,SAAWF,EAAEG,UAAYC,EAAKC,QAAQC,SAC9DN,EAAEO,iBACFH,EAAKC,QAAQC,OAAOE,QAAQC,KAA5B,aAA8CL,EAAKM,MAAMC,OAAOC,MAAM,CAAC,UAAW,SAGpFZ,EAAEa,8EAGc,SAACC,EAAOC,GACxBX,EAAKM,MAAMM,YAAYF,EAAOC,oEAGT,WACrBX,EAAKM,MAAMO,eAAeb,EAAKM,MAAMC,2DAa9B,SAAAO,GACPd,EAAKe,KAAOD,EACZd,EAAKgB,6EAOW,SAAApB,GAGhB,IAAIqB,EAFJrB,EAAEO,iBAKAc,EADwB,MAAtBrB,EAAEsB,OAAOC,SACJvB,EAAEsB,OAAOE,WAAWH,KAEpBrB,EAAEsB,OAAOD,KAGlBI,OAAOC,KAAKL,EAAM,kBAAmB,yHA9BvCD,eAAA,SAAgBO,GAAmB,IAAAC,EAAAC,KAC7BA,KAAKnB,MAAMoB,eAAiBD,KAAKV,OACnCY,YAAiB,kBAAMH,EAAKT,MAAQS,EAAKI,SAAS,CAAEjC,OAAQkC,KAAKC,KAAKN,EAAKT,KAAKgB,cAAgB,MAE5FN,KAAKnB,MAAM0B,gBAAkBT,GAC/BE,KAAKnB,MAAM0B,qBAUjBC,mBAAA,SAAoBC,EAAWC,GAC7BV,KAAKT,eAAemB,EAAUxC,SAAW8B,KAAKW,MAAMzC,WAiBtD0C,OAAA,WACE,IAAM9B,EAASkB,KAAKnB,MAAMC,OAAO+B,IAAI,UAAYb,KAAKnB,MAAMC,OAAO+B,IAAI,UAAYb,KAAKnB,MAAMC,OACxFgC,EAAa,CAAEC,UAAW,cACxBC,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H,KAAK0I,4BACzBnB,QAASvH,KAAKiJ,iBACdzB,SAAUxH,KAAKkJ,aACfzB,MAAOzH,KAAKyS,UACZ5K,QAAS7H,KAAKsI,gBAKnB+H,SA/VQzL,kCAEG,CACpBnG,OAAQoG,IAAUC,mCAGD,CACjBsG,OAAQvG,IAAUC,OAAOG,WACzBoH,SAAUxH,IAAUK,KAAKD,WACzBnG,OAAQiG,IAAmBC,IAC3BsG,aAAcvG,IAAmB2K,KACjCjE,eAAgB1G,IAAmB2K,KACnC3H,KAAMlD,IAAUC,OAAOG,WACvBiH,qBAAsBrH,IAAUM,KAChCnB,OAAQa,IAAUO,OAAOH","file":"features/status.js","sourcesContent":["import React from 'react';\nimport PropTypes from 'prop-types';\nimport ImmutablePropTypes from 'react-immutable-proptypes';\nimport Avatar from '../../../components/avatar';\nimport DisplayName from '../../../components/display_name';\nimport StatusContent from '../../../components/status_content';\nimport MediaGallery from '../../../components/media_gallery';\nimport AttachmentList from '../../../components/attachment_list';\nimport { Link } from 'react-router-dom';\nimport { FormattedDate, FormattedNumber } from 'react-intl';\nimport Card from './card';\nimport ImmutablePureComponent from 'react-immutable-pure-component';\nimport Video from '../../video';\nimport scheduleIdleTask from '../../ui/util/schedule_idle_task';\nimport classNames from 'classnames';\nimport Icon from 'mastodon/components/icon';\n\nexport default class DetailedStatus extends ImmutablePureComponent {\n\n static contextTypes = {\n router: PropTypes.object,\n };\n\n static propTypes = {\n status: ImmutablePropTypes.map.isRequired,\n onOpenMedia: PropTypes.func.isRequired,\n onOpenVideo: PropTypes.func.isRequired,\n onToggleHidden: PropTypes.func.isRequired,\n measureHeight: PropTypes.bool,\n onHeightChange: PropTypes.func,\n domain: PropTypes.string.isRequired,\n compact: PropTypes.bool,\n };\n\n state = {\n height: null,\n };\n\n handleAccountClick = (e) => {\n if (e.button === 0 && !(e.ctrlKey || e.metaKey) && this.context.router) {\n e.preventDefault();\n this.context.router.history.push(`/accounts/${this.props.status.getIn(['account', 'id'])}`);\n }\n\n e.stopPropagation();\n }\n\n handleOpenVideo = (media, startTime) => {\n this.props.onOpenVideo(media, startTime);\n }\n\n handleExpandedToggle = () => {\n this.props.onToggleHidden(this.props.status);\n }\n\n _measureHeight (heightJustChanged) {\n if (this.props.measureHeight && this.node) {\n scheduleIdleTask(() => this.node && this.setState({ height: Math.ceil(this.node.scrollHeight) + 1 }));\n\n if (this.props.onHeightChange && heightJustChanged) {\n this.props.onHeightChange();\n }\n }\n }\n\n setRef = c => {\n this.node = c;\n this._measureHeight();\n }\n\n componentDidUpdate (prevProps, prevState) {\n this._measureHeight(prevState.height !== this.state.height);\n }\n\n handleModalLink = e => {\n e.preventDefault();\n\n let href;\n\n if (e.target.nodeName !== 'A') {\n href = e.target.parentNode.href;\n } else {\n href = e.target.href;\n }\n\n window.open(href, 'mastodon-intent', 'width=445,height=600,resizable=no,menubar=no,status=no,scrollbars=yes');\n }\n\n render () {\n const status = this.props.status.get('reblog') ? this.props.status.get('reblog') : this.props.status;\n const outerStyle = { boxSizing: 'border-box' };\n const { compact } = this.props;\n\n if (!status) {\n return null;\n }\n\n let media = '';\n let applicationLink = '';\n let reblogLink = '';\n let reblogIcon = 'retweet';\n let favouriteLink = '';\n\n if (this.props.measureHeight) {\n outerStyle.height = `${this.state.height}px`;\n }\n\n if (status.get('media_attachments').size > 0) {\n if (status.get('media_attachments').some(item => item.get('type') === 'unknown')) {\n media = <AttachmentList media={status.get('media_attachments')} />;\n } else if (status.getIn(['media_attachments', 0, 'type']) === 'video') {\n const video = status.getIn(['media_attachments', 0]);\n\n media = (\n <Video\n preview={video.get('preview_url')}\n src={video.get('url')}\n alt={video.get('description')}\n width={300}\n height={150}\n inline\n onOpenVideo={this.handleOpenVideo}\n sensitive={status.get('sensitive')}\n />\n );\n } else {\n media = (\n <MediaGallery\n standalone\n sensitive={status.get('sensitive')}\n media={status.get('media_attachments')}\n height={300}\n onOpenMedia={this.props.onOpenMedia}\n />\n );\n }\n } else if (status.get('spoiler_text').length === 0) {\n media = <Card onOpenMedia={this.props.onOpenMedia} card={status.get('card', null)} />;\n }\n\n if (status.get('application')) {\n applicationLink = <span> · <a className='detailed-status__application' href={status.getIn(['application', 'website'])} target='_blank' rel='noopener'>{status.getIn(['application', 'name'])}</a></span>;\n }\n\n if (status.get('visibility') === 'direct') {\n reblogIcon = 'envelope';\n } else if (status.get('visibility') === 'private') {\n reblogIcon = 'lock';\n }\n\n if (status.get('visibility') === 'private') {\n reblogLink = <Icon id={reblogIcon} />;\n } else if (this.context.router) {\n reblogLink = (\n <Link to={`/statuses/${status.get('id')}/reblogs`} className='detailed-status__link'>\n <Icon id={reblogIcon} />\n <span className='detailed-status__reblogs'>\n <FormattedNumber value={status.get('reblogs_count')} />\n </span>\n </Link>\n );\n } else {\n reblogLink = (\n <a href={`/interact/${status.get('id')}?type=reblog`} className='detailed-status__link' onClick={this.handleModalLink}>\n <Icon id={reblogIcon} />\n <span className='detailed-status__reblogs'>\n <FormattedNumber value={status.get('reblogs_count')} />\n </span>\n </a>\n );\n }\n\n if (this.context.router) {\n favouriteLink = (\n <Link to={`/statuses/${status.get('id')}/favourites`} className='detailed-status__link'>\n <Icon id='star' />\n <span className='detailed-status__favorites'>\n <FormattedNumber value={status.get('favourites_count')} />\n </span>\n </Link>\n );\n } else {\n favouriteLink = (\n <a href={`/interact/${status.get('id')}?type=favourite`} className='detailed-status__link' onClick={this.handleModalLink}>\n <Icon id='star' />\n <span className='detailed-status__favorites'>\n <FormattedNumber value={status.get('favourites_count')} />\n </span>\n </a>\n );\n }\n\n return (\n <div style={outerStyle}>\n <div ref={this.setRef} className={classNames('detailed-status', { compact })}>\n <a href={status.getIn(['account', 'url'])} onClick={this.handleAccountClick} className='detailed-status__display-name'>\n <div className='detailed-status__display-avatar'><Avatar account={status.get('account')} size={48} /></div>\n <DisplayName account={status.get('account')} localDomain={this.props.domain} />\n </a>\n\n <StatusContent status={status} expanded={!status.get('hidden')} onExpandedToggle={this.handleExpandedToggle} />\n\n {media}\n\n <div className='detailed-status__meta'>\n <a className='detailed-status__datetime' href={status.get('url')} target='_blank' rel='noopener'>\n <FormattedDate value={new Date(status.get('created_at'))} hour12={false} year='numeric' month='short' day='2-digit' hour='2-digit' minute='2-digit' />\n </a>{applicationLink} · {reblogLink} · {favouriteLink}\n </div>\n </div>\n </div>\n );\n }\n\n}\n","import React from 'react';\nimport PropTypes from 'prop-types';\nimport IconButton from '../../../components/icon_button';\nimport ImmutablePropTypes from 'react-immutable-proptypes';\nimport DropdownMenuContainer from '../../../containers/dropdown_menu_container';\nimport { defineMessages, injectIntl } from 'react-intl';\nimport { me, isStaff } from '../../../initial_state';\n\nconst messages = defineMessages({\n delete: { id: 'status.delete', defaultMessage: 'Delete' },\n redraft: { id: 'status.redraft', defaultMessage: 'Delete & re-draft' },\n direct: { id: 'status.direct', defaultMessage: 'Direct message @{name}' },\n mention: { id: 'status.mention', defaultMessage: 'Mention @{name}' },\n reply: { id: 'status.reply', defaultMessage: 'Reply' },\n reblog: { id: 'status.reblog', defaultMessage: 'Boost' },\n reblog_private: { id: 'status.reblog_private', defaultMessage: 'Boost to original audience' },\n cancel_reblog_private: { id: 'status.cancel_reblog_private', defaultMessage: 'Unboost' },\n cannot_reblog: { id: 'status.cannot_reblog', defaultMessage: 'This post cannot be boosted' },\n favourite: { id: 'status.favourite', defaultMessage: 'Favourite' },\n mute: { id: 'status.mute', defaultMessage: 'Mute @{name}' },\n muteConversation: { id: 'status.mute_conversation', defaultMessage: 'Mute conversation' },\n unmuteConversation: { id: 'status.unmute_conversation', defaultMessage: 'Unmute conversation' },\n block: { id: 'status.block', defaultMessage: 'Block @{name}' },\n report: { id: 'status.report', defaultMessage: 'Report @{name}' },\n share: { id: 'status.share', defaultMessage: 'Share' },\n pin: { id: 'status.pin', defaultMessage: 'Pin on profile' },\n unpin: { id: 'status.unpin', defaultMessage: 'Unpin from profile' },\n embed: { id: 'status.embed', defaultMessage: 'Embed' },\n admin_account: { id: 'status.admin_account', defaultMessage: 'Open moderation interface for @{name}' },\n admin_status: { id: 'status.admin_status', defaultMessage: 'Open this status in the moderation interface' },\n});\n\nexport default @injectIntl\nclass ActionBar extends React.PureComponent {\n\n static contextTypes = {\n router: PropTypes.object,\n };\n\n static propTypes = {\n status: ImmutablePropTypes.map.isRequired,\n onReply: PropTypes.func.isRequired,\n onReblog: PropTypes.func.isRequired,\n onFavourite: PropTypes.func.isRequired,\n onDelete: PropTypes.func.isRequired,\n onDirect: PropTypes.func.isRequired,\n onMention: PropTypes.func.isRequired,\n onMute: PropTypes.func,\n onMuteConversation: PropTypes.func,\n onBlock: PropTypes.func,\n onReport: PropTypes.func,\n onPin: PropTypes.func,\n onEmbed: PropTypes.func,\n intl: PropTypes.object.isRequired,\n };\n\n handleReplyClick = () => {\n this.props.onReply(this.props.status);\n }\n\n handleReblogClick = (e) => {\n this.props.onReblog(this.props.status, e);\n }\n\n handleFavouriteClick = () => {\n this.props.onFavourite(this.props.status);\n }\n\n handleDeleteClick = () => {\n this.props.onDelete(this.props.status, this.context.router.history);\n }\n\n handleRedraftClick = () => {\n this.props.onDelete(this.props.status, this.context.router.history, true);\n }\n\n handleDirectClick = () => {\n this.props.onDirect(this.props.status.get('account'), this.context.router.history);\n }\n\n handleMentionClick = () => {\n this.props.onMention(this.props.status.get('account'), this.context.router.history);\n }\n\n handleMuteClick = () => {\n this.props.onMute(this.props.status.get('account'));\n }\n\n handleConversationMuteClick = () => {\n this.props.onMuteConversation(this.props.status);\n }\n\n handleBlockClick = () => {\n this.props.onBlock(this.props.status.get('account'));\n }\n\n handleReport = () => {\n this.props.onReport(this.props.status);\n }\n\n handlePinClick = () => {\n this.props.onPin(this.props.status);\n }\n\n handleShare = () => {\n navigator.share({\n text: this.props.status.get('search_index'),\n url: this.props.status.get('url'),\n });\n }\n\n handleEmbed = () => {\n this.props.onEmbed(this.props.status);\n }\n\n render () {\n const { status, intl } = this.props;\n\n const publicStatus = ['public', 'unlisted'].includes(status.get('visibility'));\n const mutingConversation = status.get('muted');\n\n let menu = [];\n\n if (publicStatus) {\n menu.push({ text: intl.formatMessage(messages.embed), action: this.handleEmbed });\n menu.push(null);\n }\n\n if (me === status.getIn(['account', 'id'])) {\n if (publicStatus) {\n menu.push({ text: intl.formatMessage(status.get('pinned') ? messages.unpin : messages.pin), action: this.handlePinClick });\n } else {\n if (status.get('visibility') === 'private') {\n menu.push({ text: intl.formatMessage(status.get('reblogged') ? messages.cancel_reblog_private : messages.reblog_private), action: this.handleReblogClick });\n }\n }\n\n menu.push(null);\n menu.push({ text: intl.formatMessage(mutingConversation ? messages.unmuteConversation : messages.muteConversation), action: this.handleConversationMuteClick });\n menu.push(null);\n menu.push({ text: intl.formatMessage(messages.delete), action: this.handleDeleteClick });\n menu.push({ text: intl.formatMessage(messages.redraft), action: this.handleRedraftClick });\n } else {\n menu.push({ text: intl.formatMessage(messages.mention, { name: status.getIn(['account', 'username']) }), action: this.handleMentionClick });\n menu.push({ text: intl.formatMessage(messages.direct, { name: status.getIn(['account', 'username']) }), action: this.handleDirectClick });\n menu.push(null);\n menu.push({ text: intl.formatMessage(messages.mute, { name: status.getIn(['account', 'username']) }), action: this.handleMuteClick });\n menu.push({ text: intl.formatMessage(messages.block, { name: status.getIn(['account', 'username']) }), action: this.handleBlockClick });\n menu.push({ text: intl.formatMessage(messages.report, { name: status.getIn(['account', 'username']) }), action: this.handleReport });\n if (isStaff) {\n menu.push(null);\n menu.push({ text: intl.formatMessage(messages.admin_account, { name: status.getIn(['account', 'username']) }), href: `/admin/accounts/${status.getIn(['account', 'id'])}` });\n menu.push({ text: intl.formatMessage(messages.admin_status), href: `/admin/accounts/${status.getIn(['account', 'id'])}/statuses/${status.get('id')}` });\n }\n }\n\n const shareButton = ('share' in navigator) && status.get('visibility') === 'public' && (\n <div className='detailed-status__button'><IconButton title={intl.formatMessage(messages.share)} icon='share-alt' onClick={this.handleShare} /></div>\n );\n\n let replyIcon;\n if (status.get('in_reply_to_id', null) === null) {\n replyIcon = 'reply';\n } else {\n replyIcon = 'reply-all';\n }\n\n let reblogIcon = 'retweet';\n if (status.get('visibility') === 'direct') reblogIcon = 'envelope';\n else if (status.get('visibility') === 'private') reblogIcon = 'lock';\n\n let reblog_disabled = (status.get('visibility') === 'direct' || status.get('visibility') === 'private');\n\n return (\n <div className='detailed-status__action-bar'>\n <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} onClick={this.handleReplyClick} /></div>\n <div className='detailed-status__button'><IconButton disabled={reblog_disabled} active={status.get('reblogged')} title={reblog_disabled ? intl.formatMessage(messages.cannot_reblog) : intl.formatMessage(messages.reblog)} icon={reblogIcon} onClick={this.handleReblogClick} /></div>\n <div className='detailed-status__button'><IconButton className='star-icon' animate active={status.get('favourited')} title={intl.formatMessage(messages.favourite)} icon='star' onClick={this.handleFavouriteClick} /></div>\n {shareButton}\n\n <div className='detailed-status__action-bar-dropdown'>\n <DropdownMenuContainer size={18} icon='ellipsis-h' items={menu} direction='left' title='More' />\n </div>\n </div>\n );\n }\n\n}\n","import Immutable from 'immutable';\nimport React from 'react';\nimport { connect } from 'react-redux';\nimport PropTypes from 'prop-types';\nimport classNames from 'classnames';\nimport ImmutablePropTypes from 'react-immutable-proptypes';\nimport { fetchStatus } from '../../actions/statuses';\nimport MissingIndicator from '../../components/missing_indicator';\nimport DetailedStatus from './components/detailed_status';\nimport ActionBar from './components/action_bar';\nimport Column from '../ui/components/column';\nimport {\n favourite,\n unfavourite,\n reblog,\n unreblog,\n pin,\n unpin,\n} from '../../actions/interactions';\nimport {\n replyCompose,\n mentionCompose,\n directCompose,\n} from '../../actions/compose';\nimport { blockAccount } from '../../actions/accounts';\nimport {\n muteStatus,\n unmuteStatus,\n deleteStatus,\n hideStatus,\n revealStatus,\n} from '../../actions/statuses';\nimport { initMuteModal } from '../../actions/mutes';\nimport { initReport } from '../../actions/reports';\nimport { makeGetStatus } from '../../selectors';\nimport { ScrollContainer } from 'react-router-scroll-4';\nimport ColumnBackButton from '../../components/column_back_button';\nimport ColumnHeader from '../../components/column_header';\nimport StatusContainer from '../../containers/status_container';\nimport { openModal } from '../../actions/modal';\nimport { defineMessages, injectIntl, FormattedMessage } from 'react-intl';\nimport ImmutablePureComponent from 'react-immutable-pure-component';\nimport { HotKeys } from 'react-hotkeys';\nimport { boostModal, deleteModal } from '../../initial_state';\nimport { attachFullscreenListener, detachFullscreenListener, isFullscreen } from '../ui/util/fullscreen';\nimport { textForScreenReader } from '../../components/status';\nimport Icon from 'mastodon/components/icon';\n\nconst messages = defineMessages({\n deleteConfirm: { id: 'confirmations.delete.confirm', defaultMessage: 'Delete' },\n deleteMessage: { id: 'confirmations.delete.message', defaultMessage: 'Are you sure you want to delete this status?' },\n redraftConfirm: { id: 'confirmations.redraft.confirm', defaultMessage: 'Delete & redraft' },\n redraftMessage: { id: 'confirmations.redraft.message', defaultMessage: 'Are you sure you want to delete this status and re-draft it? Favourites and boosts will be lost, and replies to the original post will be orphaned.' },\n blockConfirm: { id: 'confirmations.block.confirm', defaultMessage: 'Block' },\n revealAll: { id: 'status.show_more_all', defaultMessage: 'Show more for all' },\n hideAll: { id: 'status.show_less_all', defaultMessage: 'Show less for all' },\n detailedStatus: { id: 'status.detailed_status', defaultMessage: 'Detailed conversation view' },\n replyConfirm: { id: 'confirmations.reply.confirm', defaultMessage: 'Reply' },\n replyMessage: { id: 'confirmations.reply.message', defaultMessage: 'Replying now will overwrite the message you are currently composing. Are you sure you want to proceed?' },\n});\n\nconst makeMapStateToProps = () => {\n const getStatus = makeGetStatus();\n\n const mapStateToProps = (state, props) => {\n const status = getStatus(state, { id: props.params.statusId });\n let ancestorsIds = Immutable.List();\n let descendantsIds = Immutable.List();\n\n if (status) {\n ancestorsIds = ancestorsIds.withMutations(mutable => {\n let id = status.get('in_reply_to_id');\n\n while (id) {\n mutable.unshift(id);\n id = state.getIn(['contexts', 'inReplyTos', id]);\n }\n });\n\n descendantsIds = descendantsIds.withMutations(mutable => {\n const ids = [status.get('id')];\n\n while (ids.length > 0) {\n let id = ids.shift();\n const replies = state.getIn(['contexts', 'replies', id]);\n\n if (status.get('id') !== id) {\n mutable.push(id);\n }\n\n if (replies) {\n replies.reverse().forEach(reply => {\n ids.unshift(reply);\n });\n }\n }\n });\n }\n\n return {\n status,\n ancestorsIds,\n descendantsIds,\n askReplyConfirmation: state.getIn(['compose', 'text']).trim().length !== 0,\n domain: state.getIn(['meta', 'domain']),\n };\n };\n\n return mapStateToProps;\n};\n\nexport default @injectIntl\n@connect(makeMapStateToProps)\nclass Status extends ImmutablePureComponent {\n\n static contextTypes = {\n router: PropTypes.object,\n };\n\n static propTypes = {\n params: PropTypes.object.isRequired,\n dispatch: PropTypes.func.isRequired,\n status: ImmutablePropTypes.map,\n ancestorsIds: ImmutablePropTypes.list,\n descendantsIds: ImmutablePropTypes.list,\n intl: PropTypes.object.isRequired,\n askReplyConfirmation: PropTypes.bool,\n domain: PropTypes.string.isRequired,\n };\n\n state = {\n fullscreen: false,\n };\n\n componentWillMount () {\n this.props.dispatch(fetchStatus(this.props.params.statusId));\n }\n\n componentDidMount () {\n attachFullscreenListener(this.onFullScreenChange);\n }\n\n componentWillReceiveProps (nextProps) {\n if (nextProps.params.statusId !== this.props.params.statusId && nextProps.params.statusId) {\n this._scrolledIntoView = false;\n this.props.dispatch(fetchStatus(nextProps.params.statusId));\n }\n }\n\n handleFavouriteClick = (status) => {\n if (status.get('favourited')) {\n this.props.dispatch(unfavourite(status));\n } else {\n this.props.dispatch(favourite(status));\n }\n }\n\n handlePin = (status) => {\n if (status.get('pinned')) {\n this.props.dispatch(unpin(status));\n } else {\n this.props.dispatch(pin(status));\n }\n }\n\n handleReplyClick = (status) => {\n let { askReplyConfirmation, dispatch, intl } = this.props;\n if (askReplyConfirmation) {\n dispatch(openModal('CONFIRM', {\n message: intl.formatMessage(messages.replyMessage),\n confirm: intl.formatMessage(messages.replyConfirm),\n onConfirm: () => dispatch(replyCompose(status, this.context.router.history)),\n }));\n } else {\n dispatch(replyCompose(status, this.context.router.history));\n }\n }\n\n handleModalReblog = (status) => {\n this.props.dispatch(reblog(status));\n }\n\n handleReblogClick = (status, e) => {\n if (status.get('reblogged')) {\n this.props.dispatch(unreblog(status));\n } else {\n if ((e && e.shiftKey) || !boostModal) {\n this.handleModalReblog(status);\n } else {\n this.props.dispatch(openModal('BOOST', { status, onReblog: this.handleModalReblog }));\n }\n }\n }\n\n handleDeleteClick = (status, history, withRedraft = false) => {\n const { dispatch, intl } = this.props;\n\n if (!deleteModal) {\n dispatch(deleteStatus(status.get('id'), history, withRedraft));\n } else {\n dispatch(openModal('CONFIRM', {\n message: intl.formatMessage(withRedraft ? messages.redraftMessage : messages.deleteMessage),\n confirm: intl.formatMessage(withRedraft ? messages.redraftConfirm : messages.deleteConfirm),\n onConfirm: () => dispatch(deleteStatus(status.get('id'), history, withRedraft)),\n }));\n }\n }\n\n handleDirectClick = (account, router) => {\n this.props.dispatch(directCompose(account, router));\n }\n\n handleMentionClick = (account, router) => {\n this.props.dispatch(mentionCompose(account, router));\n }\n\n handleOpenMedia = (media, index) => {\n this.props.dispatch(openModal('MEDIA', { media, index }));\n }\n\n handleOpenVideo = (media, time) => {\n this.props.dispatch(openModal('VIDEO', { media, time }));\n }\n\n handleMuteClick = (account) => {\n this.props.dispatch(initMuteModal(account));\n }\n\n handleConversationMuteClick = (status) => {\n if (status.get('muted')) {\n this.props.dispatch(unmuteStatus(status.get('id')));\n } else {\n this.props.dispatch(muteStatus(status.get('id')));\n }\n }\n\n handleToggleHidden = (status) => {\n if (status.get('hidden')) {\n this.props.dispatch(revealStatus(status.get('id')));\n } else {\n this.props.dispatch(hideStatus(status.get('id')));\n }\n }\n\n handleToggleAll = () => {\n const { status, ancestorsIds, descendantsIds } = this.props;\n const statusIds = [status.get('id')].concat(ancestorsIds.toJS(), descendantsIds.toJS());\n\n if (status.get('hidden')) {\n this.props.dispatch(revealStatus(statusIds));\n } else {\n this.props.dispatch(hideStatus(statusIds));\n }\n }\n\n handleBlockClick = (account) => {\n const { dispatch, intl } = this.props;\n\n dispatch(openModal('CONFIRM', {\n message: <FormattedMessage id='confirmations.block.message' defaultMessage='Are you sure you want to block {name}?' values={{ name: <strong>@{account.get('acct')}</strong> }} />,\n confirm: intl.formatMessage(messages.blockConfirm),\n onConfirm: () => dispatch(blockAccount(account.get('id'))),\n }));\n }\n\n handleReport = (status) => {\n this.props.dispatch(initReport(status.get('account'), status));\n }\n\n handleEmbed = (status) => {\n this.props.dispatch(openModal('EMBED', { url: status.get('url') }));\n }\n\n handleHotkeyMoveUp = () => {\n this.handleMoveUp(this.props.status.get('id'));\n }\n\n handleHotkeyMoveDown = () => {\n this.handleMoveDown(this.props.status.get('id'));\n }\n\n handleHotkeyReply = e => {\n e.preventDefault();\n this.handleReplyClick(this.props.status);\n }\n\n handleHotkeyFavourite = () => {\n this.handleFavouriteClick(this.props.status);\n }\n\n handleHotkeyBoost = () => {\n this.handleReblogClick(this.props.status);\n }\n\n handleHotkeyMention = e => {\n e.preventDefault();\n this.handleMentionClick(this.props.status.get('account'));\n }\n\n handleHotkeyOpenProfile = () => {\n this.context.router.history.push(`/accounts/${this.props.status.getIn(['account', 'id'])}`);\n }\n\n handleHotkeyToggleHidden = () => {\n this.handleToggleHidden(this.props.status);\n }\n\n handleMoveUp = id => {\n const { status, ancestorsIds, descendantsIds } = this.props;\n\n if (id === status.get('id')) {\n this._selectChild(ancestorsIds.size - 1);\n } else {\n let index = ancestorsIds.indexOf(id);\n\n if (index === -1) {\n index = descendantsIds.indexOf(id);\n this._selectChild(ancestorsIds.size + index);\n } else {\n this._selectChild(index - 1);\n }\n }\n }\n\n handleMoveDown = id => {\n const { status, ancestorsIds, descendantsIds } = this.props;\n\n if (id === status.get('id')) {\n this._selectChild(ancestorsIds.size + 1);\n } else {\n let index = ancestorsIds.indexOf(id);\n\n if (index === -1) {\n index = descendantsIds.indexOf(id);\n this._selectChild(ancestorsIds.size + index + 2);\n } else {\n this._selectChild(index + 1);\n }\n }\n }\n\n _selectChild (index) {\n const element = this.node.querySelectorAll('.focusable')[index];\n\n if (element) {\n element.focus();\n }\n }\n\n renderChildren (list) {\n return list.map(id => (\n <StatusContainer\n key={id}\n id={id}\n onMoveUp={this.handleMoveUp}\n onMoveDown={this.handleMoveDown}\n contextType='thread'\n />\n ));\n }\n\n setRef = c => {\n this.node = c;\n }\n\n componentDidUpdate () {\n if (this._scrolledIntoView) {\n return;\n }\n\n const { status, ancestorsIds } = this.props;\n\n if (status && ancestorsIds && ancestorsIds.size > 0) {\n const element = this.node.querySelectorAll('.focusable')[ancestorsIds.size - 1];\n\n window.requestAnimationFrame(() => {\n element.scrollIntoView(true);\n });\n this._scrolledIntoView = true;\n }\n }\n\n componentWillUnmount () {\n detachFullscreenListener(this.onFullScreenChange);\n }\n\n onFullScreenChange = () => {\n this.setState({ fullscreen: isFullscreen() });\n }\n\n render () {\n let ancestors, descendants;\n const { shouldUpdateScroll, status, ancestorsIds, descendantsIds, intl, domain } = this.props;\n const { fullscreen } = this.state;\n\n if (status === null) {\n return (\n <Column>\n <ColumnBackButton />\n <MissingIndicator />\n </Column>\n );\n }\n\n if (ancestorsIds && ancestorsIds.size > 0) {\n ancestors = <div>{this.renderChildren(ancestorsIds)}</div>;\n }\n\n if (descendantsIds && descendantsIds.size > 0) {\n descendants = <div>{this.renderChildren(descendantsIds)}</div>;\n }\n\n const handlers = {\n moveUp: this.handleHotkeyMoveUp,\n moveDown: this.handleHotkeyMoveDown,\n reply: this.handleHotkeyReply,\n favourite: this.handleHotkeyFavourite,\n boost: this.handleHotkeyBoost,\n mention: this.handleHotkeyMention,\n openProfile: this.handleHotkeyOpenProfile,\n toggleHidden: this.handleHotkeyToggleHidden,\n };\n\n return (\n <Column label={intl.formatMessage(messages.detailedStatus)}>\n <ColumnHeader\n showBackButton\n extraButton={(\n <button className='column-header__button' title={intl.formatMessage(status.get('hidden') ? messages.revealAll : messages.hideAll)} aria-label={intl.formatMessage(status.get('hidden') ? messages.revealAll : messages.hideAll)} onClick={this.handleToggleAll} aria-pressed={status.get('hidden') ? 'false' : 'true'}><Icon id={status.get('hidden') ? 'eye-slash' : 'eye'} /></button>\n )}\n />\n\n <ScrollContainer scrollKey='thread' shouldUpdateScroll={shouldUpdateScroll}>\n <div className={classNames('scrollable', { fullscreen })} ref={this.setRef}>\n {ancestors}\n\n <HotKeys handlers={handlers}>\n <div className={classNames('focusable', 'detailed-status__wrapper')} tabIndex='0' aria-label={textForScreenReader(intl, status, false, !status.get('hidden'))}>\n <DetailedStatus\n status={status}\n onOpenVideo={this.handleOpenVideo}\n onOpenMedia={this.handleOpenMedia}\n onToggleHidden={this.handleToggleHidden}\n domain={domain}\n />\n\n <ActionBar\n status={status}\n onReply={this.handleReplyClick}\n onFavourite={this.handleFavouriteClick}\n onReblog={this.handleReblogClick}\n onDelete={this.handleDeleteClick}\n onDirect={this.handleDirectClick}\n onMention={this.handleMentionClick}\n onMute={this.handleMuteClick}\n onMuteConversation={this.handleConversationMuteClick}\n onBlock={this.handleBlockClick}\n onReport={this.handleReport}\n onPin={this.handlePin}\n onEmbed={this.handleEmbed}\n />\n </div>\n </HotKeys>\n\n {descendants}\n </div>\n </ScrollContainer>\n </Column>\n );\n }\n\n}\n"],"sourceRoot":""}
\ No newline at end of file
+{"version":3,"sources":["webpack:///app/javascript/tank/sources/git/git.pleroma.social/pleroma/mastofe/app/javascript/mastodon/features/status/components/detailed_status.js","webpack:///app/javascript/tank/sources/git/git.pleroma.social/pleroma/mastofe/app/javascript/mastodon/features/status/components/action_bar.js","webpack:///app/javascript/tank/sources/git/git.pleroma.social/pleroma/mastofe/app/javascript/mastodon/features/status/index.js"],"names":["DetailedStatus","height","e","button","ctrlKey","metaKey","context","router","preventDefault","history","push","props","status","getIn","stopPropagation","media","startTime","onOpenVideo","onToggleHidden","c","node","_measureHeight","href","target","nodeName","parentNode","window","open","heightJustChanged","this","measureHeight","scheduleIdleTask","setState","Math","ceil","scrollHeight","onHeightChange","componentDidUpdate","prevProps","prevState","state","render","get","outerStyle","boxSizing","compact","applicationLink","reblogLink","reblogIcon","favouriteLink","size","attachment","src","alt","duration","preload","preview","blurhash","width","inline","handleOpenVideo","sensitive","visible","showMedia","onToggleVisibility","onToggleMediaVisibility","standalone","onOpenMedia","length","card","className","rel","id","to","value","onClick","handleModalLink","style","ref","setRef","classNames","handleAccountClick","account","localDomain","domain","expanded","onExpandedToggle","handleExpandedToggle","Date","hour12","year","month","day","hour","minute","ImmutablePureComponent","PropTypes","object","ImmutablePropTypes","map","func","isRequired","bool","string","messages","defineMessages","delete","redraft","direct","mention","reply","reblog","reblog_private","cancel_reblog_private","cannot_reblog","favourite","bookmark","mute","muteConversation","unmuteConversation","block","report","share","pin","unpin","embed","admin_account","admin_status","copy","blockDomain","unblockDomain","unmute","unblock","ActionBar","connect","relationship","injectIntl","onReply","onReblog","onFavourite","onBookmark","onDelete","onDirect","onMention","onMute","onUnmute","onBlock","onUnblock","onBlockDomain","split","onUnblockDomain","onMuteConversation","onReport","onPin","navigator","text","url","onEmbed","textarea","document","createElement","textContent","position","body","appendChild","select","execCommand","removeChild","intl","publicStatus","includes","mutingConversation","menu","formatMessage","action","handleCopy","handleEmbed","me","handlePinClick","handleReblogClick","handleConversationMuteClick","handleDeleteClick","handleRedraftClick","name","handleMentionClick","handleDirectClick","handleMuteClick","handleBlockClick","handleReport","handleUnblockDomain","handleBlockDomain","isStaff","replyIcon","shareButton","title","icon","handleShare","reblog_disabled","handleReplyClick","disabled","active","animate","handleFavouriteClick","handleBookmarkClick","items","direction","React","PureComponent","deleteConfirm","deleteMessage","redraftConfirm","redraftMessage","revealAll","hideAll","detailedStatus","replyConfirm","replyMessage","blockDomainConfirm","Status","getStatus","makeGetStatus","getAncestorsIds","createSelector","_","statusId","inReplyTos","ancestorsIds","Immutable","List","withMutations","mutable","unshift","getDescendantsIds","contextReplies","statuses","descendantsIds","ids","shift","replies","reverse","forEach","insertAt","findIndex","idx","splice","params","askReplyConfirmation","trim","fullscreen","defaultMediaVisibility","loadedStatusId","undefined","dispatch","unfavourite","openModal","message","confirm","onConfirm","replyCompose","unreblog","shiftKey","boostModal","handleModalReblog","unbookmark","withRedraft","deleteModal","deleteStatus","directCompose","mentionCompose","index","time","_properStatus","handleOpenMedia","initMuteModal","unmuteStatus","muteStatus","revealStatus","hideStatus","statusIds","concat","toJS","initBlockModal","initReport","unmuteAccount","unblockAccount","defaultMessage","values","handleMoveUp","handleMoveDown","handleToggleHidden","handleToggleMediaVisibility","_selectChild","indexOf","isFullscreen","componentWillMount","fetchStatus","componentDidMount","attachFullscreenListener","onFullScreenChange","componentWillReceiveProps","nextProps","_scrolledIntoView","align_top","container","element","querySelectorAll","scrollTop","offsetTop","scrollIntoView","clientHeight","offsetHeight","focus","renderChildren","list","onMoveUp","onMoveDown","contextType","requestAnimationFrame","componentWillUnmount","detachFullscreenListener","ancestors","descendants","shouldUpdateScroll","multiColumn","handlers","moveUp","handleHotkeyMoveUp","moveDown","handleHotkeyMoveDown","handleHotkeyReply","handleHotkeyFavourite","boost","handleHotkeyBoost","handleHotkeyMention","openProfile","handleHotkeyOpenProfile","toggleHidden","handleHotkeyToggleHidden","toggleSensitive","handleHotkeyToggleSensitive","openMedia","handleHotkeyOpenMedia","bindToDocument","label","showBackButton","extraButton","aria-label","handleToggleAll","aria-pressed","scrollKey","tabIndex","textForScreenReader","handleUnmuteClick","handleUnblockClick","handleBlockDomainClick","handleUnblockDomainClick","handlePin"],"mappings":"sUAiBqBA,E,sLAmBX,CACNC,OAAQ,O,iDAGW,SAACC,GACH,IAAbA,EAAEC,QAAkBD,EAAEE,SAAWF,EAAEG,UAAY,EAAKC,QAAQC,SAC9DL,EAAEM,iBACF,EAAKF,QAAQC,OAAOE,QAAQC,KAA5B,aAA8C,EAAKC,MAAMC,OAAOC,MAAM,CAAC,UAAW,SAGpFX,EAAEY,qB,8CAGc,SAACC,EAAOC,GACxB,EAAKL,MAAMM,YAAYF,EAAOC,M,mDAGT,WACrB,EAAKL,MAAMO,e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,mBACrB7M,OAAQA,EACRrB,UAAWlC,KAAKW,MAAMuB,UACtBE,wBAAyBpC,KAAKqQ,6BARhC,WACkBtR,EAAO8B,IAAI,OAU7B,YAAC,EAAD,CAEE9B,OAAQA,EACR6H,QAAS5G,KAAKyK,iBACd3D,YAAa9G,KAAK6K,qBAClBhE,SAAU7G,KAAKsJ,kBACfvC,WAAY/G,KAAK8K,oBACjB9D,SAAUhH,KAAKwJ,kBACfvC,SAAUjH,KAAK4J,kBACf1C,UAAWlH,KAAK2J,mBAChBxC,OAAQnH,KAAK6J,gBACbzC,SAAUpH,KAAKmU,kBACfzM,mBAAoB1H,KAAKuJ,4BACzBlC,QAASrH,KAAK8J,iBACdxC,UAAWtH,KAAKoU,mBAChB7M,cAAevH,KAAKqU,uBACpB5M,gBAAiBzH,KAAKsU,yBACtB3M,SAAU3H,KAAK+J,aACfnC,MAAO5H,KAAKuU,UACZvM,QAAShI,KAAKmJ,aAnBhB,cACqBpK,EAAO8B,IAAI,SAuBnCuR,M,GAzaQlO,K,6BAEG,CACpBxF,OAAQyF,IAAUC,S,0BAGD,CACjBoJ,OAAQrJ,IAAUC,OAAOI,WACzBuJ,SAAU5J,IAAUI,KAAKC,WACzBzF,OAAQsF,IAAmBC,IAC3B+H,aAAchI,IAAmBuN,KACjC9E,eAAgBzI,IAAmBuN,KACnCjJ,KAAMxE,IAAUC,OAAOI,WACvBiJ,qBAAsBtJ,IAAUM,KAChC6N,YAAanO,IAAUM,KACvBlB,OAAQY,IAAUO,OAAOF,a","file":"features/status.js","sourcesContent":["import React from 'react';\nimport PropTypes from 'prop-types';\nimport ImmutablePropTypes from 'react-immutable-proptypes';\nimport Avatar from '../../../components/avatar';\nimport DisplayName from '../../../components/display_name';\nimport StatusContent from '../../../components/status_content';\nimport MediaGallery from '../../../components/media_gallery';\nimport { Link } from 'react-router-dom';\nimport { FormattedDate, FormattedNumber } from 'react-intl';\nimport Card from './card';\nimport ImmutablePureComponent from 'react-immutable-pure-component';\nimport Video from '../../video';\nimport Audio from '../../audio';\nimport scheduleIdleTask from '../../ui/util/schedule_idle_task';\nimport classNames from 'classnames';\nimport Icon from 'mastodon/components/icon';\n\nexport default class DetailedStatus extends ImmutablePureComponent {\n\n static contextTypes = {\n router: PropTypes.object,\n };\n\n static propTypes = {\n status: ImmutablePropTypes.map,\n onOpenMedia: PropTypes.func.isRequired,\n onOpenVideo: PropTypes.func.isRequired,\n onToggleHidden: PropTypes.func.isRequired,\n measureHeight: PropTypes.bool,\n onHeightChange: PropTypes.func,\n domain: PropTypes.string.isRequired,\n compact: PropTypes.bool,\n showMedia: PropTypes.bool,\n onToggleMediaVisibility: PropTypes.func,\n };\n\n state = {\n height: null,\n };\n\n handleAccountClick = (e) => {\n if (e.button === 0 && !(e.ctrlKey || e.metaKey) && this.context.router) {\n e.preventDefault();\n this.context.router.history.push(`/accounts/${this.props.status.getIn(['account', 'id'])}`);\n }\n\n e.stopPropagation();\n }\n\n handleOpenVideo = (media, startTime) => {\n this.props.onOpenVideo(media, startTime);\n }\n\n handleExpandedToggle = () => {\n this.props.onToggleHidden(this.props.status);\n }\n\n _measureHeight (heightJustChanged) {\n if (this.props.measureHeight && this.node) {\n scheduleIdleTask(() => this.node && this.setState({ height: Math.ceil(this.node.scrollHeight) + 1 }));\n\n if (this.props.onHeightChange && heightJustChanged) {\n this.props.onHeightChange();\n }\n }\n }\n\n setRef = c => {\n this.node = c;\n this._measureHeight();\n }\n\n componentDidUpdate (prevProps, prevState) {\n this._measureHeight(prevState.height !== this.state.height);\n }\n\n handleModalLink = e => {\n e.preventDefault();\n\n let href;\n\n if (e.target.nodeName !== 'A') {\n href = e.target.parentNode.href;\n } else {\n href = e.target.href;\n }\n\n window.open(href, 'mastodon-intent', 'width=445,height=600,resizable=no,menubar=no,status=no,scrollbars=yes');\n }\n\n render () {\n const status = (this.props.status && this.props.status.get('reblog')) ? this.props.status.get('reblog') : this.props.status;\n const outerStyle = { boxSizing: 'border-box' };\n const { compact } = this.props;\n\n if (!status) {\n return null;\n }\n\n let media = '';\n let applicationLink = '';\n let reblogLink = '';\n let reblogIcon = 'retweet';\n let favouriteLink = '';\n\n if (this.props.measureHeight) {\n outerStyle.height = `${this.state.height}px`;\n }\n\n if (status.get('media_attachments').size > 0) {\n if (status.getIn(['media_attachments', 0, 'type']) === 'audio') {\n const attachment = status.getIn(['media_attachments', 0]);\n\n media = (\n <Audio\n src={attachment.get('url')}\n alt={attachment.get('description')}\n duration={attachment.getIn(['meta', 'original', 'duration'], 0)}\n height={110}\n preload\n />\n );\n } else if (status.getIn(['media_attachments', 0, 'type']) === 'video') {\n const attachment = status.getIn(['media_attachments', 0]);\n\n media = (\n <Video\n preview={attachment.get('preview_url')}\n blurhash={attachment.get('blurhash')}\n src={attachment.get('url')}\n alt={attachment.get('description')}\n width={300}\n height={150}\n inline\n onOpenVideo={this.handleOpenVideo}\n sensitive={status.get('sensitive')}\n visible={this.props.showMedia}\n onToggleVisibility={this.props.onToggleMediaVisibility}\n />\n );\n } else {\n media = (\n <MediaGallery\n standalone\n sensitive={status.get('sensitive')}\n media={status.get('media_attachments')}\n height={300}\n onOpenMedia={this.props.onOpenMedia}\n visible={this.props.showMedia}\n onToggleVisibility={this.props.onToggleMediaVisibility}\n />\n );\n }\n } else if (status.get('spoiler_text').length === 0) {\n media = <Card onOpenMedia={this.props.onOpenMedia} card={status.get('card', null)} />;\n }\n\n if (status.get('application')) {\n applicationLink = <span> · <a className='detailed-status__application' href={status.getIn(['application', 'website'])} target='_blank' rel='noopener noreferrer'>{status.getIn(['application', 'name'])}</a></span>;\n }\n\n if (status.get('visibility') === 'direct') {\n reblogIcon = 'envelope';\n } else if (status.get('visibility') === 'private') {\n reblogIcon = 'lock';\n }\n\n if (status.get('visibility') === 'private') {\n reblogLink = <Icon id={reblogIcon} />;\n } else if (this.context.router) {\n reblogLink = (\n <Link to={`/statuses/${status.get('id')}/reblogs`} className='detailed-status__link'>\n <Icon id={reblogIcon} />\n <span className='detailed-status__reblogs'>\n <FormattedNumber value={status.get('reblogs_count')} />\n </span>\n </Link>\n );\n } else {\n reblogLink = (\n <a href={`/interact/${status.get('id')}?type=reblog`} className='detailed-status__link' onClick={this.handleModalLink}>\n <Icon id={reblogIcon} />\n <span className='detailed-status__reblogs'>\n <FormattedNumber value={status.get('reblogs_count')} />\n </span>\n </a>\n );\n }\n\n if (this.context.router) {\n favouriteLink = (\n <Link to={`/statuses/${status.get('id')}/favourites`} className='detailed-status__link'>\n <Icon id='star' />\n <span className='detailed-status__favorites'>\n <FormattedNumber value={status.get('favourites_count')} />\n </span>\n </Link>\n );\n } else {\n favouriteLink = (\n <a href={`/interact/${status.get('id')}?type=favourite`} className='detailed-status__link' onClick={this.handleModalLink}>\n <Icon id='star' />\n <span className='detailed-status__favorites'>\n <FormattedNumber value={status.get('favourites_count')} />\n </span>\n </a>\n );\n }\n\n return (\n <div style={outerStyle}>\n <div ref={this.setRef} className={classNames('detailed-status', { compact })}>\n <a href={status.getIn(['account', 'url'])} onClick={this.handleAccountClick} className='detailed-status__display-name'>\n <div className='detailed-status__display-avatar'><Avatar account={status.get('account')} size={48} /></div>\n <DisplayName account={status.get('account')} localDomain={this.props.domain} />\n </a>\n\n <StatusContent status={status} expanded={!status.get('hidden')} onExpandedToggle={this.handleExpandedToggle} />\n\n {media}\n\n <div className='detailed-status__meta'>\n <a className='detailed-status__datetime' href={status.get('url')} target='_blank' rel='noopener noreferrer'>\n <FormattedDate value={new Date(status.get('created_at'))} hour12={false} year='numeric' month='short' day='2-digit' hour='2-digit' minute='2-digit' />\n </a>{applicationLink} · {reblogLink} · {favouriteLink}\n </div>\n </div>\n </div>\n );\n }\n\n}\n","import React from 'react';\nimport PropTypes from 'prop-types';\nimport { connect } from 'react-redux';\nimport IconButton from '../../../components/icon_button';\nimport ImmutablePropTypes from 'react-immutable-proptypes';\nimport DropdownMenuContainer from '../../../containers/dropdown_menu_container';\nimport { defineMessages, injectIntl } from 'react-intl';\nimport { me, isStaff } from '../../../initial_state';\n\nconst messages = defineMessages({\n delete: { id: 'status.delete', defaultMessage: 'Delete' },\n redraft: { id: 'status.redraft', defaultMessage: 'Delete & re-draft' },\n direct: { id: 'status.direct', defaultMessage: 'Direct message @{name}' },\n mention: { id: 'status.mention', defaultMessage: 'Mention @{name}' },\n reply: { id: 'status.reply', defaultMessage: 'Reply' },\n reblog: { id: 'status.reblog', defaultMessage: 'Boost' },\n reblog_private: { id: 'status.reblog_private', defaultMessage: 'Boost to original audience' },\n cancel_reblog_private: { id: 'status.cancel_reblog_private', defaultMessage: 'Unboost' },\n cannot_reblog: { id: 'status.cannot_reblog', defaultMessage: 'This post cannot be boosted' },\n favourite: { id: 'status.favourite', defaultMessage: 'Favourite' },\n bookmark: { id: 'status.bookmark', defaultMessage: 'Bookmark' },\n mute: { id: 'status.mute', defaultMessage: 'Mute @{name}' },\n muteConversation: { id: 'status.mute_conversation', defaultMessage: 'Mute conversation' },\n unmuteConversation: { id: 'status.unmute_conversation', defaultMessage: 'Unmute conversation' },\n block: { id: 'status.block', defaultMessage: 'Block @{name}' },\n report: { id: 'status.report', defaultMessage: 'Report @{name}' },\n share: { id: 'status.share', defaultMessage: 'Share' },\n pin: { id: 'status.pin', defaultMessage: 'Pin on profile' },\n unpin: { id: 'status.unpin', defaultMessage: 'Unpin from profile' },\n embed: { id: 'status.embed', defaultMessage: 'Embed' },\n admin_account: { id: 'status.admin_account', defaultMessage: 'Open moderation interface for @{name}' },\n admin_status: { id: 'status.admin_status', defaultMessage: 'Open this status in the moderation interface' },\n copy: { id: 'status.copy', defaultMessage: 'Copy link to status' },\n blockDomain: { id: 'account.block_domain', defaultMessage: 'Hide everything from {domain}' },\n unblockDomain: { id: 'account.unblock_domain', defaultMessage: 'Unhide {domain}' },\n unmute: { id: 'account.unmute', defaultMessage: 'Unmute @{name}' },\n unblock: { id: 'account.unblock', defaultMessage: 'Unblock @{name}' },\n});\n\nconst mapStateToProps = (state, { status }) => ({\n relationship: state.getIn(['relationships', status.getIn(['account', 'id'])]),\n});\n\nexport default @connect(mapStateToProps)\n@injectIntl\nclass ActionBar extends React.PureComponent {\n\n static contextTypes = {\n router: PropTypes.object,\n };\n\n static propTypes = {\n status: ImmutablePropTypes.map.isRequired,\n relationship: ImmutablePropTypes.map,\n onReply: PropTypes.func.isRequired,\n onReblog: PropTypes.func.isRequired,\n onFavourite: PropTypes.func.isRequired,\n onBookmark: PropTypes.func.isRequired,\n onDelete: PropTypes.func.isRequired,\n onDirect: PropTypes.func.isRequired,\n onMention: PropTypes.func.isRequired,\n onMute: PropTypes.func,\n onUnmute: PropTypes.func,\n onBlock: PropTypes.func,\n onUnblock: PropTypes.func,\n onBlockDomain: PropTypes.func,\n onUnblockDomain: PropTypes.func,\n onMuteConversation: PropTypes.func,\n onReport: PropTypes.func,\n onPin: PropTypes.func,\n onEmbed: PropTypes.func,\n intl: PropTypes.object.isRequired,\n };\n\n handleReplyClick = () => {\n this.props.onReply(this.props.status);\n }\n\n handleReblogClick = (e) => {\n this.props.onReblog(this.props.status, e);\n }\n\n handleFavouriteClick = () => {\n this.props.onFavourite(this.props.status);\n }\n\n handleBookmarkClick = (e) => {\n this.props.onBookmark(this.props.status, e);\n }\n\n handleDeleteClick = () => {\n this.props.onDelete(this.props.status, this.context.router.history);\n }\n\n handleRedraftClick = () => {\n this.props.onDelete(this.props.status, this.context.router.history, true);\n }\n\n handleDirectClick = () => {\n this.props.onDirect(this.props.status.get('account'), this.context.router.history);\n }\n\n handleMentionClick = () => {\n this.props.onMention(this.props.status.get('account'), this.context.router.history);\n }\n\n handleMuteClick = () => {\n const { status, relationship, onMute, onUnmute } = this.props;\n const account = status.get('account');\n\n if (relationship && relationship.get('muting')) {\n onUnmute(account);\n } else {\n onMute(account);\n }\n }\n\n handleBlockClick = () => {\n const { status, relationship, onBlock, onUnblock } = this.props;\n const account = status.get('account');\n\n if (relationship && relationship.get('blocking')) {\n onUnblock(account);\n } else {\n onBlock(status);\n }\n }\n\n handleBlockDomain = () => {\n const { status, onBlockDomain } = this.props;\n const account = status.get('account');\n\n onBlockDomain(account.get('acct').split('@')[1]);\n }\n\n handleUnblockDomain = () => {\n const { status, onUnblockDomain } = this.props;\n const account = status.get('account');\n\n onUnblockDomain(account.get('acct').split('@')[1]);\n }\n\n handleConversationMuteClick = () => {\n this.props.onMuteConversation(this.props.status);\n }\n\n handleReport = () => {\n this.props.onReport(this.props.status);\n }\n\n handlePinClick = () => {\n this.props.onPin(this.props.status);\n }\n\n handleShare = () => {\n navigator.share({\n text: this.props.status.get('search_index'),\n url: this.props.status.get('url'),\n });\n }\n\n handleEmbed = () => {\n this.props.onEmbed(this.props.status);\n }\n\n handleCopy = () => {\n const url = this.props.status.get('url');\n const textarea = document.createElement('textarea');\n\n textarea.textContent = url;\n textarea.style.position = 'fixed';\n\n document.body.appendChild(textarea);\n\n try {\n textarea.select();\n document.execCommand('copy');\n } catch (e) {\n\n } finally {\n document.body.removeChild(textarea);\n }\n }\n\n render () {\n const { status, relationship, intl } = this.props;\n\n const publicStatus = ['public', 'unlisted'].includes(status.get('visibility'));\n const mutingConversation = status.get('muted');\n const account = status.get('account');\n\n let menu = [];\n\n if (publicStatus) {\n menu.push({ text: intl.formatMessage(messages.copy), action: this.handleCopy });\n menu.push({ text: intl.formatMessage(messages.embed), action: this.handleEmbed });\n menu.push(null);\n }\n\n if (me === status.getIn(['account', 'id'])) {\n if (publicStatus) {\n menu.push({ text: intl.formatMessage(status.get('pinned') ? messages.unpin : messages.pin), action: this.handlePinClick });\n } else {\n if (status.get('visibility') === 'private') {\n menu.push({ text: intl.formatMessage(status.get('reblogged') ? messages.cancel_reblog_private : messages.reblog_private), action: this.handleReblogClick });\n }\n }\n\n menu.push(null);\n menu.push({ text: intl.formatMessage(mutingConversation ? messages.unmuteConversation : messages.muteConversation), action: this.handleConversationMuteClick });\n menu.push(null);\n menu.push({ text: intl.formatMessage(messages.delete), action: this.handleDeleteClick });\n menu.push({ text: intl.formatMessage(messages.redraft), action: this.handleRedraftClick });\n } else {\n menu.push({ text: intl.formatMessage(messages.mention, { name: status.getIn(['account', 'username']) }), action: this.handleMentionClick });\n menu.push({ text: intl.formatMessage(messages.direct, { name: status.getIn(['account', 'username']) }), action: this.handleDirectClick });\n menu.push(null);\n\n if (relationship && relationship.get('muting')) {\n menu.push({ text: intl.formatMessage(messages.unmute, { name: account.get('username') }), action: this.handleMuteClick });\n } else {\n menu.push({ text: intl.formatMessage(messages.mute, { name: account.get('username') }), action: this.handleMuteClick });\n }\n\n if (relationship && relationship.get('blocking')) {\n menu.push({ text: intl.formatMessage(messages.unblock, { name: account.get('username') }), action: this.handleBlockClick });\n } else {\n menu.push({ text: intl.formatMessage(messages.block, { name: account.get('username') }), action: this.handleBlockClick });\n }\n\n menu.push({ text: intl.formatMessage(messages.report, { name: status.getIn(['account', 'username']) }), action: this.handleReport });\n\n if (account.get('acct') !== account.get('username')) {\n const domain = account.get('acct').split('@')[1];\n\n menu.push(null);\n\n if (relationship && relationship.get('domain_blocking')) {\n menu.push({ text: intl.formatMessage(messages.unblockDomain, { domain }), action: this.handleUnblockDomain });\n } else {\n menu.push({ text: intl.formatMessage(messages.blockDomain, { domain }), action: this.handleBlockDomain });\n }\n }\n\n if (isStaff) {\n menu.push(null);\n menu.push({ text: intl.formatMessage(messages.admin_account, { name: status.getIn(['account', 'username']) }), href: `/admin/accounts/${status.getIn(['account', 'id'])}` });\n menu.push({ text: intl.formatMessage(messages.admin_status), href: `/admin/accounts/${status.getIn(['account', 'id'])}/statuses/${status.get('id')}` });\n }\n }\n\n const shareButton = ('share' in navigator) && status.get('visibility') === 'public' && (\n <div className='detailed-status__button'><IconButton title={intl.formatMessage(messages.share)} icon='share-alt' onClick={this.handleShare} /></div>\n );\n\n let replyIcon;\n if (status.get('in_reply_to_id', null) === null) {\n replyIcon = 'reply';\n } else {\n replyIcon = 'reply-all';\n }\n\n let reblogIcon = 'retweet';\n if (status.get('visibility') === 'direct') reblogIcon = 'envelope';\n else if (status.get('visibility') === 'private') reblogIcon = 'lock';\n\n let reblog_disabled = (status.get('visibility') === 'direct' || status.get('visibility') === 'private');\n\n return (\n <div className='detailed-status__action-bar'>\n <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} onClick={this.handleReplyClick} /></div>\n <div className='detailed-status__button'><IconButton disabled={reblog_disabled} active={status.get('reblogged')} title={reblog_disabled ? intl.formatMessage(messages.cannot_reblog) : intl.formatMessage(messages.reblog)} icon={reblogIcon} onClick={this.handleReblogClick} /></div>\n <div className='detailed-status__button'><IconButton className='star-icon' animate active={status.get('favourited')} title={intl.formatMessage(messages.favourite)} icon='star' onClick={this.handleFavouriteClick} /></div>\n {shareButton}\n <div className='detailed-status__button'><IconButton className='bookmark-icon' active={status.get('bookmarked')} title={intl.formatMessage(messages.bookmark)} icon='bookmark' onClick={this.handleBookmarkClick} /></div>\n\n <div className='detailed-status__action-bar-dropdown'>\n <DropdownMenuContainer size={18} icon='ellipsis-h' status={status} items={menu} direction='left' title='More' />\n </div>\n </div>\n );\n }\n\n}\n","import Immutable from 'immutable';\nimport React from 'react';\nimport { connect } from 'react-redux';\nimport PropTypes from 'prop-types';\nimport classNames from 'classnames';\nimport ImmutablePropTypes from 'react-immutable-proptypes';\nimport { createSelector } from 'reselect';\nimport { fetchStatus } from '../../actions/statuses';\nimport MissingIndicator from '../../components/missing_indicator';\nimport DetailedStatus from './components/detailed_status';\nimport ActionBar from './components/action_bar';\nimport Column from '../ui/components/column';\nimport {\n favourite,\n unfavourite,\n bookmark,\n unbookmark,\n reblog,\n unreblog,\n pin,\n unpin,\n} from '../../actions/interactions';\nimport {\n replyCompose,\n mentionCompose,\n directCompose,\n} from '../../actions/compose';\nimport {\n muteStatus,\n unmuteStatus,\n deleteStatus,\n hideStatus,\n revealStatus,\n} from '../../actions/statuses';\nimport {\n unblockAccount,\n unmuteAccount,\n} from '../../actions/accounts';\nimport {\n blockDomain,\n unblockDomain,\n} from '../../actions/domain_blocks';\nimport { initMuteModal } from '../../actions/mutes';\nimport { initBlockModal } from '../../actions/blocks';\nimport { initReport } from '../../actions/reports';\nimport { makeGetStatus } from '../../selectors';\nimport { ScrollContainer } from 'react-router-scroll-4';\nimport ColumnBackButton from '../../components/column_back_button';\nimport ColumnHeader from '../../components/column_header';\nimport StatusContainer from '../../containers/status_container';\nimport { openModal } from '../../actions/modal';\nimport { defineMessages, injectIntl, FormattedMessage } from 'react-intl';\nimport ImmutablePureComponent from 'react-immutable-pure-component';\nimport { HotKeys } from 'react-hotkeys';\nimport { boostModal, deleteModal } from '../../initial_state';\nimport { attachFullscreenListener, detachFullscreenListener, isFullscreen } from '../ui/util/fullscreen';\nimport { textForScreenReader, defaultMediaVisibility } from '../../components/status';\nimport Icon from 'mastodon/components/icon';\n\nconst messages = defineMessages({\n deleteConfirm: { id: 'confirmations.delete.confirm', defaultMessage: 'Delete' },\n deleteMessage: { id: 'confirmations.delete.message', defaultMessage: 'Are you sure you want to delete this status?' },\n redraftConfirm: { id: 'confirmations.redraft.confirm', defaultMessage: 'Delete & redraft' },\n redraftMessage: { id: 'confirmations.redraft.message', defaultMessage: 'Are you sure you want to delete this status and re-draft it? Favourites and boosts will be lost, and replies to the original post will be orphaned.' },\n revealAll: { id: 'status.show_more_all', defaultMessage: 'Show more for all' },\n hideAll: { id: 'status.show_less_all', defaultMessage: 'Show less for all' },\n detailedStatus: { id: 'status.detailed_status', defaultMessage: 'Detailed conversation view' },\n replyConfirm: { id: 'confirmations.reply.confirm', defaultMessage: 'Reply' },\n replyMessage: { id: 'confirmations.reply.message', defaultMessage: 'Replying now will overwrite the message you are currently composing. Are you sure you want to proceed?' },\n blockDomainConfirm: { id: 'confirmations.domain_block.confirm', defaultMessage: 'Hide entire domain' },\n});\n\nconst makeMapStateToProps = () => {\n const getStatus = makeGetStatus();\n\n const getAncestorsIds = createSelector([\n (_, { id }) => id,\n state => state.getIn(['contexts', 'inReplyTos']),\n ], (statusId, inReplyTos) => {\n let ancestorsIds = Immutable.List();\n ancestorsIds = ancestorsIds.withMutations(mutable => {\n let id = statusId;\n\n while (id) {\n mutable.unshift(id);\n id = inReplyTos.get(id);\n }\n });\n\n return ancestorsIds;\n });\n\n const getDescendantsIds = createSelector([\n (_, { id }) => id,\n state => state.getIn(['contexts', 'replies']),\n state => state.get('statuses'),\n ], (statusId, contextReplies, statuses) => {\n let descendantsIds = [];\n const ids = [statusId];\n\n while (ids.length > 0) {\n let id = ids.shift();\n const replies = contextReplies.get(id);\n\n if (statusId !== id) {\n descendantsIds.push(id);\n }\n\n if (replies) {\n replies.reverse().forEach(reply => {\n ids.unshift(reply);\n });\n }\n }\n\n let insertAt = descendantsIds.findIndex((id) => statuses.get(id).get('in_reply_to_account_id') !== statuses.get(id).get('account'));\n if (insertAt !== -1) {\n descendantsIds.forEach((id, idx) => {\n if (idx > insertAt && statuses.get(id).get('in_reply_to_account_id') === statuses.get(id).get('account')) {\n descendantsIds.splice(idx, 1);\n descendantsIds.splice(insertAt, 0, id);\n insertAt += 1;\n }\n });\n }\n\n return Immutable.List(descendantsIds);\n });\n\n const mapStateToProps = (state, props) => {\n const status = getStatus(state, { id: props.params.statusId });\n let ancestorsIds = Immutable.List();\n let descendantsIds = Immutable.List();\n\n if (status) {\n ancestorsIds = getAncestorsIds(state, { id: status.get('in_reply_to_id') });\n descendantsIds = getDescendantsIds(state, { id: status.get('id') });\n }\n\n return {\n status,\n ancestorsIds,\n descendantsIds,\n askReplyConfirmation: state.getIn(['compose', 'text']).trim().length !== 0,\n domain: state.getIn(['meta', 'domain']),\n };\n };\n\n return mapStateToProps;\n};\n\nexport default @injectIntl\n@connect(makeMapStateToProps)\nclass Status extends ImmutablePureComponent {\n\n static contextTypes = {\n router: PropTypes.object,\n };\n\n static propTypes = {\n params: PropTypes.object.isRequired,\n dispatch: PropTypes.func.isRequired,\n status: ImmutablePropTypes.map,\n ancestorsIds: ImmutablePropTypes.list,\n descendantsIds: ImmutablePropTypes.list,\n intl: PropTypes.object.isRequired,\n askReplyConfirmation: PropTypes.bool,\n multiColumn: PropTypes.bool,\n domain: PropTypes.string.isRequired,\n };\n\n state = {\n fullscreen: false,\n showMedia: defaultMediaVisibility(this.props.status),\n loadedStatusId: undefined,\n };\n\n componentWillMount () {\n this.props.dispatch(fetchStatus(this.props.params.statusId));\n }\n\n componentDidMount () {\n attachFullscreenListener(this.onFullScreenChange);\n }\n\n componentWillReceiveProps (nextProps) {\n if (nextProps.params.statusId !== this.props.params.statusId && nextProps.params.statusId) {\n this._scrolledIntoView = false;\n this.props.dispatch(fetchStatus(nextProps.params.statusId));\n }\n\n if (nextProps.status && nextProps.status.get('id') !== this.state.loadedStatusId) {\n this.setState({ showMedia: defaultMediaVisibility(nextProps.status), loadedStatusId: nextProps.status.get('id') });\n }\n }\n\n handleToggleMediaVisibility = () => {\n this.setState({ showMedia: !this.state.showMedia });\n }\n\n handleFavouriteClick = (status) => {\n if (status.get('favourited')) {\n this.props.dispatch(unfavourite(status));\n } else {\n this.props.dispatch(favourite(status));\n }\n }\n\n handlePin = (status) => {\n if (status.get('pinned')) {\n this.props.dispatch(unpin(status));\n } else {\n this.props.dispatch(pin(status));\n }\n }\n\n handleReplyClick = (status) => {\n let { askReplyConfirmation, dispatch, intl } = this.props;\n if (askReplyConfirmation) {\n dispatch(openModal('CONFIRM', {\n message: intl.formatMessage(messages.replyMessage),\n confirm: intl.formatMessage(messages.replyConfirm),\n onConfirm: () => dispatch(replyCompose(status, this.context.router.history)),\n }));\n } else {\n dispatch(replyCompose(status, this.context.router.history));\n }\n }\n\n handleModalReblog = (status) => {\n this.props.dispatch(reblog(status));\n }\n\n handleReblogClick = (status, e) => {\n if (status.get('reblogged')) {\n this.props.dispatch(unreblog(status));\n } else {\n if ((e && e.shiftKey) || !boostModal) {\n this.handleModalReblog(status);\n } else {\n this.props.dispatch(openModal('BOOST', { status, onReblog: this.handleModalReblog }));\n }\n }\n }\n\n handleBookmarkClick = (status) => {\n if (status.get('bookmarked')) {\n this.props.dispatch(unbookmark(status));\n } else {\n this.props.dispatch(bookmark(status));\n }\n }\n\n handleDeleteClick = (status, history, withRedraft = false) => {\n const { dispatch, intl } = this.props;\n\n if (!deleteModal) {\n dispatch(deleteStatus(status.get('id'), history, withRedraft));\n } else {\n dispatch(openModal('CONFIRM', {\n message: intl.formatMessage(withRedraft ? messages.redraftMessage : messages.deleteMessage),\n confirm: intl.formatMessage(withRedraft ? messages.redraftConfirm : messages.deleteConfirm),\n onConfirm: () => dispatch(deleteStatus(status.get('id'), history, withRedraft)),\n }));\n }\n }\n\n handleDirectClick = (account, router) => {\n this.props.dispatch(directCompose(account, router));\n }\n\n handleMentionClick = (account, router) => {\n this.props.dispatch(mentionCompose(account, router));\n }\n\n handleOpenMedia = (media, index) => {\n this.props.dispatch(openModal('MEDIA', { media, index }));\n }\n\n handleOpenVideo = (media, time) => {\n this.props.dispatch(openModal('VIDEO', { media, time }));\n }\n\n handleHotkeyOpenMedia = e => {\n const status = this._properStatus();\n\n e.preventDefault();\n\n if (status.get('media_attachments').size > 0) {\n if (status.getIn(['media_attachments', 0, 'type']) === 'audio') {\n // TODO: toggle play/paused?\n } else if (status.getIn(['media_attachments', 0, 'type']) === 'video') {\n this.handleOpenVideo(status.getIn(['media_attachments', 0]), 0);\n } else {\n this.handleOpenMedia(status.get('media_attachments'), 0);\n }\n }\n }\n\n handleMuteClick = (account) => {\n this.props.dispatch(initMuteModal(account));\n }\n\n handleConversationMuteClick = (status) => {\n if (status.get('muted')) {\n this.props.dispatch(unmuteStatus(status.get('id')));\n } else {\n this.props.dispatch(muteStatus(status.get('id')));\n }\n }\n\n handleToggleHidden = (status) => {\n if (status.get('hidden')) {\n this.props.dispatch(revealStatus(status.get('id')));\n } else {\n this.props.dispatch(hideStatus(status.get('id')));\n }\n }\n\n handleToggleAll = () => {\n const { status, ancestorsIds, descendantsIds } = this.props;\n const statusIds = [status.get('id')].concat(ancestorsIds.toJS(), descendantsIds.toJS());\n\n if (status.get('hidden')) {\n this.props.dispatch(revealStatus(statusIds));\n } else {\n this.props.dispatch(hideStatus(statusIds));\n }\n }\n\n handleBlockClick = (status) => {\n const { dispatch } = this.props;\n const account = status.get('account');\n dispatch(initBlockModal(account));\n }\n\n handleReport = (status) => {\n this.props.dispatch(initReport(status.get('account'), status));\n }\n\n handleEmbed = (status) => {\n this.props.dispatch(openModal('EMBED', { url: status.get('url') }));\n }\n\n handleUnmuteClick = account => {\n this.props.dispatch(unmuteAccount(account.get('id')));\n }\n\n handleUnblockClick = account => {\n this.props.dispatch(unblockAccount(account.get('id')));\n }\n\n handleBlockDomainClick = domain => {\n this.props.dispatch(openModal('CONFIRM', {\n message: <FormattedMessage id='confirmations.domain_block.message' defaultMessage='Are you really, really sure you want to block the entire {domain}? In most cases a few targeted blocks or mutes are sufficient and preferable. You will not see content from that domain in any public timelines or your notifications. Your followers from that domain will be removed.' values={{ domain: <strong>{domain}</strong> }} />,\n confirm: this.props.intl.formatMessage(messages.blockDomainConfirm),\n onConfirm: () => this.props.dispatch(blockDomain(domain)),\n }));\n }\n\n handleUnblockDomainClick = domain => {\n this.props.dispatch(unblockDomain(domain));\n }\n\n\n handleHotkeyMoveUp = () => {\n this.handleMoveUp(this.props.status.get('id'));\n }\n\n handleHotkeyMoveDown = () => {\n this.handleMoveDown(this.props.status.get('id'));\n }\n\n handleHotkeyReply = e => {\n e.preventDefault();\n this.handleReplyClick(this.props.status);\n }\n\n handleHotkeyFavourite = () => {\n this.handleFavouriteClick(this.props.status);\n }\n\n handleHotkeyBoost = () => {\n this.handleReblogClick(this.props.status);\n }\n\n handleHotkeyMention = e => {\n e.preventDefault();\n this.handleMentionClick(this.props.status.get('account'));\n }\n\n handleHotkeyOpenProfile = () => {\n this.context.router.history.push(`/accounts/${this.props.status.getIn(['account', 'id'])}`);\n }\n\n handleHotkeyToggleHidden = () => {\n this.handleToggleHidden(this.props.status);\n }\n\n handleHotkeyToggleSensitive = () => {\n this.handleToggleMediaVisibility();\n }\n\n handleMoveUp = id => {\n const { status, ancestorsIds, descendantsIds } = this.props;\n\n if (id === status.get('id')) {\n this._selectChild(ancestorsIds.size - 1, true);\n } else {\n let index = ancestorsIds.indexOf(id);\n\n if (index === -1) {\n index = descendantsIds.indexOf(id);\n this._selectChild(ancestorsIds.size + index, true);\n } else {\n this._selectChild(index - 1, true);\n }\n }\n }\n\n handleMoveDown = id => {\n const { status, ancestorsIds, descendantsIds } = this.props;\n\n if (id === status.get('id')) {\n this._selectChild(ancestorsIds.size + 1, false);\n } else {\n let index = ancestorsIds.indexOf(id);\n\n if (index === -1) {\n index = descendantsIds.indexOf(id);\n this._selectChild(ancestorsIds.size + index + 2, false);\n } else {\n this._selectChild(index + 1, false);\n }\n }\n }\n\n _selectChild (index, align_top) {\n const container = this.node;\n const element = container.querySelectorAll('.focusable')[index];\n\n if (element) {\n if (align_top && container.scrollTop > element.offsetTop) {\n element.scrollIntoView(true);\n } else if (!align_top && container.scrollTop + container.clientHeight < element.offsetTop + element.offsetHeight) {\n element.scrollIntoView(false);\n }\n element.focus();\n }\n }\n\n renderChildren (list) {\n return list.map(id => (\n <StatusContainer\n key={id}\n id={id}\n onMoveUp={this.handleMoveUp}\n onMoveDown={this.handleMoveDown}\n contextType='thread'\n />\n ));\n }\n\n setRef = c => {\n this.node = c;\n }\n\n componentDidUpdate () {\n if (this._scrolledIntoView) {\n return;\n }\n\n const { status, ancestorsIds } = this.props;\n\n if (status && ancestorsIds && ancestorsIds.size > 0) {\n const element = this.node.querySelectorAll('.focusable')[ancestorsIds.size - 1];\n\n window.requestAnimationFrame(() => {\n element.scrollIntoView(true);\n });\n this._scrolledIntoView = true;\n }\n }\n\n componentWillUnmount () {\n detachFullscreenListener(this.onFullScreenChange);\n }\n\n onFullScreenChange = () => {\n this.setState({ fullscreen: isFullscreen() });\n }\n\n render () {\n let ancestors, descendants;\n const { shouldUpdateScroll, status, ancestorsIds, descendantsIds, intl, domain, multiColumn } = this.props;\n const { fullscreen } = this.state;\n\n if (status === null) {\n return (\n <Column>\n <ColumnBackButton multiColumn={multiColumn} />\n <MissingIndicator />\n </Column>\n );\n }\n\n if (ancestorsIds && ancestorsIds.size > 0) {\n ancestors = <div>{this.renderChildren(ancestorsIds)}</div>;\n }\n\n if (descendantsIds && descendantsIds.size > 0) {\n descendants = <div>{this.renderChildren(descendantsIds)}</div>;\n }\n\n const handlers = {\n moveUp: this.handleHotkeyMoveUp,\n moveDown: this.handleHotkeyMoveDown,\n reply: this.handleHotkeyReply,\n favourite: this.handleHotkeyFavourite,\n boost: this.handleHotkeyBoost,\n mention: this.handleHotkeyMention,\n openProfile: this.handleHotkeyOpenProfile,\n toggleHidden: this.handleHotkeyToggleHidden,\n toggleSensitive: this.handleHotkeyToggleSensitive,\n openMedia: this.handleHotkeyOpenMedia,\n };\n\n return (\n <Column bindToDocument={!multiColumn} label={intl.formatMessage(messages.detailedStatus)}>\n <ColumnHeader\n showBackButton\n multiColumn={multiColumn}\n extraButton={(\n <button className='column-header__button' title={intl.formatMessage(status.get('hidden') ? messages.revealAll : messages.hideAll)} aria-label={intl.formatMessage(status.get('hidden') ? messages.revealAll : messages.hideAll)} onClick={this.handleToggleAll} aria-pressed={status.get('hidden') ? 'false' : 'true'}><Icon id={status.get('hidden') ? 'eye-slash' : 'eye'} /></button>\n )}\n />\n\n <ScrollContainer scrollKey='thread' shouldUpdateScroll={shouldUpdateScroll}>\n <div className={classNames('scrollable', { fullscreen })} ref={this.setRef}>\n {ancestors}\n\n <HotKeys handlers={handlers}>\n <div className={classNames('focusable', 'detailed-status__wrapper')} tabIndex='0' aria-label={textForScreenReader(intl, status, false)}>\n <DetailedStatus\n key={`details-${status.get('id')}`}\n status={status}\n onOpenVideo={this.handleOpenVideo}\n onOpenMedia={this.handleOpenMedia}\n onToggleHidden={this.handleToggleHidden}\n domain={domain}\n showMedia={this.state.showMedia}\n onToggleMediaVisibility={this.handleToggleMediaVisibility}\n />\n\n <ActionBar\n key={`action-bar-${status.get('id')}`}\n status={status}\n onReply={this.handleReplyClick}\n onFavourite={this.handleFavouriteClick}\n onReblog={this.handleReblogClick}\n onBookmark={this.handleBookmarkClick}\n onDelete={this.handleDeleteClick}\n onDirect={this.handleDirectClick}\n onMention={this.handleMentionClick}\n onMute={this.handleMuteClick}\n onUnmute={this.handleUnmuteClick}\n onMuteConversation={this.handleConversationMuteClick}\n onBlock={this.handleBlockClick}\n onUnblock={this.handleUnblockClick}\n onBlockDomain={this.handleBlockDomainClick}\n onUnblockDomain={this.handleUnblockDomainClick}\n onReport={this.handleReport}\n onPin={this.handlePin}\n onEmbed={this.handleEmbed}\n />\n </div>\n </HotKeys>\n\n {descendants}\n </div>\n </ScrollContainer>\n </Column>\n );\n }\n\n}\n"],"sourceRoot":""}
\ No newline at end of file