mirror of
https://akkoma.dev/AkkomaGang/akkoma.git
synced 2024-12-27 19:09:12 +00:00
2 lines
36 KiB
JavaScript
2 lines
36 KiB
JavaScript
webpackJsonp([6],{155:function(e,t,n){"use strict";n.d(t,"a",function(){return g});var o=n(2),i=n.n(o),a=n(1),s=n.n(a),r=n(3),c=n.n(r),l=n(4),u=n.n(l),d=n(0),p=n.n(d),f=n(10),h=n.n(f),g=function(e){function t(){var n,o,i;s()(this,t);for(var a=arguments.length,r=Array(a),l=0;l<a;l++)r[l]=arguments[l];return n=o=c()(this,e.call.apply(e,[this].concat(r))),o.handleClick=function(){o.props.onClick()},i=n,c()(o,i)}return u()(t,e),t.prototype.render=function(){var e=this.props,t=e.icon,n=e.type,o=e.active,a=e.columnHeaderId,s="";return t&&(s=i()("i",{className:"fa fa-fw fa-"+t+" column-header__icon"})),i()("h1",{className:h()("column-header",{active:o}),id:a||null},void 0,i()("button",{onClick:this.handleClick},void 0,s,n))},t}(p.a.PureComponent)},274:function(e,t,n){"use strict";n.d(t,"a",function(){return v});var o=n(2),i=n.n(o),a=n(1),s=n.n(a),r=n(3),c=n.n(r),l=n(4),u=n.n(l),d=n(32),p=n.n(d),f=n(0),h=n.n(f),g=n(155),m=n(91),b=n(43),v=function(e){function t(){var n,o,i;s()(this,t);for(var a=arguments.length,r=Array(a),l=0;l<a;l++)r[l]=arguments[l];return n=o=c()(this,e.call.apply(e,[this].concat(r))),o.handleHeaderClick=function(){var e=o.node.querySelector(".scrollable");e&&(o._interruptScrollAnimation=Object(m.b)(e))},o.handleScroll=p()(function(){void 0!==o._interruptScrollAnimation&&o._interruptScrollAnimation()},200),o.setRef=function(e){o.node=e},i=n,c()(o,i)}return u()(t,e),t.prototype.scrollTop=function(){var e=this.node.querySelector(".scrollable");e&&(this._interruptScrollAnimation=Object(m.b)(e))},t.prototype.render=function(){var e=this.props,t=e.heading,n=e.icon,o=e.children,a=e.active,s=e.hideHeadingOnMobile,r=t&&(!s||s&&!Object(b.b)(window.innerWidth)),c=r&&t.replace(/ /g,"-"),l=r&&i()(g.a,{icon:n,active:a,type:t,onClick:this.handleHeaderClick,columnHeaderId:c});return h.a.createElement("div",{ref:this.setRef,role:"region","aria-labelledby":c,className:"column",onScroll:this.handleScroll},l,o)},t}(h.a.PureComponent)},275:function(e,t,n){"use strict";n.d(t,"a",function(){return m});var o,i,a=n(2),s=n.n(a),r=n(1),c=n.n(r),l=n(3),u=n.n(l),d=n(4),p=n.n(d),f=n(0),h=n.n(f),g=n(7),m=(i=o=function(e){function t(){return c()(this,t),u()(this,e.apply(this,arguments))}return p()(t,e),t.prototype.render=function(){var e=this.props,t=e.disabled,n=e.visible;return s()("button",{className:"load-more",disabled:t||!n,style:{visibility:n?"visible":"hidden"},onClick:this.props.onClick},void 0,s()(g.b,{id:"status.load_more",defaultMessage:"Load more"}))},t}(h.a.PureComponent),o.defaultProps={visible:!0},i)},276:function(e,t,n){"use strict";n.d(t,"a",function(){return v});var o,i,a=n(2),s=n.n(a),r=n(1),c=n.n(r),l=n(3),u=n.n(l),d=n(4),p=n.n(d),f=n(0),h=n.n(f),g=n(7),m=n(5),b=n.n(m),v=(i=o=function(e){function t(){var n,o,i;c()(this,t);for(var a=arguments.length,s=Array(a),r=0;r<a;r++)s[r]=arguments[r];return n=o=u()(this,e.call.apply(e,[this].concat(s))),o.handleClick=function(){window.history&&1===window.history.length?o.context.router.history.push("/"):o.context.router.history.goBack()},i=n,u()(o,i)}return p()(t,e),t.prototype.render=function(){return s()("button",{onClick:this.handleClick,className:"column-back-button"},void 0,s()("i",{className:"fa fa-fw fa-chevron-left column-back-button__icon"}),s()(g.b,{id:"column_back_button.label",defaultMessage:"Back"}))},t}(h.a.PureComponent),o.contextTypes={router:b.a.object},i)},277:function(e,t,n){"use strict";var o=n(2),i=n.n(o),a=n(0),s=(n.n(a),n(9)),r=n(158),c=n(67),l=n(17),u=n(68),d=n(22),p=n(69),f=n(90),h=n(157),g=n(26),m=n(7),b=n(13),v=n(33),M=Object(m.f)({deleteConfirm:{id:"confirmations.delete.confirm",defaultMessage:"Delete"},deleteMessage:{id:"confirmations.delete.message",defaultMessage:"Are you sure you want to delete this status?"},redraftConfirm:{id:"confirmations.redraft.confirm",defaultMessage:"Delete & redraft"},redraftMessage:{id:"confirmations.redraft.message",defaultMessage:"Are you sure you want to delete this status and re-draft it? You will lose all replies, boosts and favourites to it."},blockConfirm:{id:"confirmations.block.confirm",defaultMessage:"Block"}}),_=function(){var e=Object(c.e)();return function(t,n){return{status:e(t,n.id)}}},y=function(e,t){var n=t.intl;return{onReply:function(t,n){e(Object(l.T)(t,n))},onModalReblog:function(t){e(Object(u.o)(t))},onReblog:function(t,n){t.get("reblogged")?e(Object(u.r)(t)):n.shiftKey||!b.b?this.onModalReblog(t):e(Object(g.d)("BOOST",{status:t,onReblog:this.onModalReblog}))},onFavourite:function(t){e(t.get("favourited")?Object(u.p)(t):Object(u.k)(t))},onPin:function(t){e(t.get("pinned")?Object(u.q)(t):Object(u.n)(t))},onEmbed:function(t){e(Object(g.d)("EMBED",{url:t.get("url"),onError:function(t){return e(Object(v.e)(t))}}))},onDelete:function(t){var o=arguments.length>1&&void 0!==arguments[1]&&arguments[1];e(b.d?Object(g.d)("CONFIRM",{message:n.formatMessage(o?M.redraftMessage:M.deleteMessage),confirm:n.formatMessage(o?M.redraftConfirm:M.deleteConfirm),onConfirm:function(){return e(Object(p.g)(t.get("id"),o))}}):Object(p.g)(t.get("id"),o))},onDirect:function(t,n){e(Object(l.N)(t,n))},onMention:function(t,n){e(Object(l.R)(t,n))},onOpenMedia:function(t,n){e(Object(g.d)("MEDIA",{media:t,index:n}))},onOpenVideo:function(t,n){e(Object(g.d)("VIDEO",{media:t,time:n}))},onBlock:function(t){e(Object(g.d)("CONFIRM",{message:i()(m.b,{id:"confirmations.block.message",defaultMessage:"Are you sure you want to block {name}?",values:{name:i()("strong",{},void 0,"@",t.get("acct"))}}),confirm:n.formatMessage(M.blockConfirm),onConfirm:function(){return e(Object(d.q)(t.get("id")))}}))},onReport:function(t){e(Object(h.k)(t.get("account"),t))},onMute:function(t){e(Object(f.g)(t))},onMuteConversation:function(t){e(t.get("muted")?Object(p.l)(t.get("id")):Object(p.j)(t.get("id")))},onToggleHidden:function(t){e(t.get("hidden")?Object(p.k)(t.get("id")):Object(p.i)(t.get("id")))}}};t.a=Object(m.g)(Object(s.connect)(_,y)(r.a))},278:function(e,t,n){"use strict";n.d(t,"a",function(){return C});var o,i,a=n(2),s=n.n(a),r=n(1),c=n.n(r),l=n(3),u=n.n(l),d=n(4),p=n.n(d),f=n(93),h=n.n(f),g=n(0),m=n.n(g),b=n(156),v=n(5),M=n.n(v),_=n(279),y=n(275),k=n(284),O=n(8),w=(n.n(O),n(10)),I=n.n(w),j=n(159),C=(i=o=function(e){function t(){var n,o,i;c()(this,t);for(var a=arguments.length,s=Array(a),r=0;r<a;r++)s[r]=arguments[r];return n=o=u()(this,e.call.apply(e,[this].concat(s))),o.state={fullscreen:null},o.intersectionObserverWrapper=new k.a,o.handleScroll=h()(function(){if(o.node){var e=o.node,t=e.scrollTop;400>e.scrollHeight-t-e.clientHeight&&o.props.onLoadMore&&!o.props.isLoading&&o.props.onLoadMore(),t<100&&o.props.onScrollToTop?o.props.onScrollToTop():o.props.onScroll&&o.props.onScroll()}},150,{trailing:!0}),o.onFullScreenChange=function(){o.setState({fullscreen:Object(j.d)()})},o.setRef=function(e){o.node=e},o.handleLoadMore=function(e){e.preventDefault(),o.props.onLoadMore()},i=n,u()(o,i)}return p()(t,e),t.prototype.componentDidMount=function(){this.attachScrollListener(),this.attachIntersectionObserver(),Object(j.a)(this.onFullScreenChange),this.handleScroll()},t.prototype.getSnapshotBeforeUpdate=function(e){return m.a.Children.count(e.children)>0&&m.a.Children.count(e.children)<m.a.Children.count(this.props.children)&&this.getFirstChildKey(e)!==this.getFirstChildKey(this.props)&&this.node.scrollTop>0?this.node.scrollHeight-this.node.scrollTop:null},t.prototype.componentDidUpdate=function(e,t,n){if(null!==n){var o=this.node.scrollHeight-n;this.node.scrollTop!==o&&(this.node.scrollTop=o)}},t.prototype.componentWillUnmount=function(){this.detachScrollListener(),this.detachIntersectionObserver(),Object(j.b)(this.onFullScreenChange)},t.prototype.attachIntersectionObserver=function(){this.intersectionObserverWrapper.connect({root:this.node,rootMargin:"300% 0px"})},t.prototype.detachIntersectionObserver=function(){this.intersectionObserverWrapper.disconnect()},t.prototype.attachScrollListener=function(){this.node.addEventListener("scroll",this.handleScroll)},t.prototype.detachScrollListener=function(){this.node.removeEventListener("scroll",this.handleScroll)},t.prototype.getFirstChildKey=function(e){var t=e.children,n=t;return t instanceof O.List?n=t.get(0):Array.isArray(t)&&(n=t[0]),n&&n.key},t.prototype.render=function(){var e=this,t=this.props,n=t.children,o=t.scrollKey,i=t.trackScroll,a=t.shouldUpdateScroll,r=t.isLoading,c=t.hasMore,l=t.prepend,u=t.alwaysPrepend,d=t.emptyMessage,p=t.onLoadMore,f=this.state.fullscreen,h=m.a.Children.count(n),g=c&&h>0&&p?s()(y.a,{visible:!r,onClick:this.handleLoadMore}):null,v=null;return v=r||h>0||!d?m.a.createElement("div",{className:I()("scrollable",{fullscreen:f}),ref:this.setRef},s()("div",{role:"feed",className:"item-list"},void 0,l,m.a.Children.map(this.props.children,function(t,n){return s()(_.a,{id:t.key,index:n,listLength:h,intersectionObserverWrapper:e.intersectionObserverWrapper,saveHeightKey:i?e.context.router.route.location.key+":"+o:null},t.key,t)}),g)):s()("div",{style:{flex:"1 1 auto",display:"flex",flexDirection:"column"}},void 0,u&&l,m.a.createElement("div",{className:"empty-column-indicator",ref:this.setRef},d)),i?s()(b.a,{scrollKey:o,shouldUpdateScroll:a},void 0,v):v},t}(g.PureComponent),o.contextTypes={router:M.a.object},o.defaultProps={trackScroll:!0},i)},279:function(e,t,n){"use strict";var o=n(9),i=n(280),a=n(94),s=function(e,t){return{cachedHeight:e.getIn(["height_cache",t.saveHeightKey,t.id])}},r=function(e){return{onHeightChange:function(t,n,o){e(Object(a.d)(t,n,o))}}};t.a=Object(o.connect)(s,r)(i.a)},280:function(e,t,n){"use strict";n.d(t,"a",function(){return m});var o=n(1),i=n.n(o),a=n(3),s=n.n(a),r=n(4),c=n.n(r),l=n(0),u=n.n(l),d=n(281),p=n(283),f=n(8),h=(n.n(f),["id","index","listLength"]),g=["id","index","listLength","cachedHeight"],m=function(e){function t(){var n,o,a;i()(this,t);for(var r=arguments.length,c=Array(r),l=0;l<r;l++)c[l]=arguments[l];return n=o=s()(this,e.call.apply(e,[this].concat(c))),o.state={isHidden:!1},o.handleIntersection=function(e){o.entry=e,Object(d.a)(o.calculateHeight),o.setState(o.updateStateAfterIntersection)},o.updateStateAfterIntersection=function(e){return e.isIntersecting&&!o.entry.isIntersecting&&Object(d.a)(o.hideIfNotIntersecting),{isIntersecting:o.entry.isIntersecting,isHidden:!1}},o.calculateHeight=function(){var e=o.props,t=e.onHeightChange,n=e.saveHeightKey,i=e.id;o.height=Object(p.a)(o.entry).height,t&&n&&t(n,i,o.height)},o.hideIfNotIntersecting=function(){o.componentMounted&&o.setState(function(e){return{isHidden:!e.isIntersecting}})},o.handleRef=function(e){o.node=e},a=n,s()(o,a)}return c()(t,e),t.prototype.shouldComponentUpdate=function(e,t){var n=this,o=!this.state.isIntersecting&&(this.state.isHidden||this.props.cachedHeight);return!!o!=!(t.isIntersecting||!t.isHidden&&!e.cachedHeight)||!(o?g:h).every(function(t){return Object(f.is)(e[t],n.props[t])})},t.prototype.componentDidMount=function(){var e=this.props,t=e.intersectionObserverWrapper,n=e.id;t.observe(n,this.node,this.handleIntersection),this.componentMounted=!0},t.prototype.componentWillUnmount=function(){var e=this.props,t=e.intersectionObserverWrapper,n=e.id;t.unobserve(n,this.node),this.componentMounted=!1},t.prototype.render=function(){var e=this.props,t=e.children,n=e.id,o=e.index,i=e.listLength,a=e.cachedHeight,s=this.state,r=s.isIntersecting,c=s.isHidden;return r||!c&&!a?u.a.createElement("article",{ref:this.handleRef,"aria-posinset":o,"aria-setsize":i,"data-id":n,tabIndex:"0"},t&&u.a.cloneElement(t,{hidden:!1})):u.a.createElement("article",{ref:this.handleRef,"aria-posinset":o,"aria-setsize":i,style:{height:(this.height||a)+"px",opacity:0,overflow:"hidden"},"data-id":n,tabIndex:"0"},t&&u.a.cloneElement(t,{hidden:!0}))},t}(u.a.Component)},281:function(e,t,n){"use strict";function o(e){for(;r.length&&e.timeRemaining()>0;)r.shift()();r.length?requestIdleCallback(o):c=!1}function i(e){r.push(e),c||(c=!0,requestIdleCallback(o))}var a=n(282),s=n.n(a),r=new s.a,c=!1;t.a=i},282:function(e,t,n){"use strict";function o(){this.length=0}o.prototype.push=function(e){var t={item:e};this.last?this.last=this.last.next=t:this.last=this.first=t,this.length++},o.prototype.shift=function(){var e=this.first;if(e)return this.first=e.next,--this.length||(this.last=void 0),e.item},o.prototype.slice=function(e,t){e=void 0===e?0:e,t=void 0===t?1/0:t;for(var n=[],o=0,i=this.first;i&&!(--t<0);i=i.next)++o>e&&n.push(i.item);return n},e.exports=o},283:function(e,t,n){"use strict";function o(e){if("boolean"!=typeof i){var t=e.target.getBoundingClientRect(),n=e.boundingClientRect;i=t.height!==n.height||t.top!==n.top||t.width!==n.width||t.bottom!==n.bottom||t.left!==n.left||t.right!==n.right}return i?e.target.getBoundingClientRect():e.boundingClientRect}var i=void 0;t.a=o},284:function(e,t,n){"use strict";var o=n(1),i=n.n(o),a=function(){function e(){i()(this,e),this.callbacks={},this.observerBacklog=[],this.observer=null}return e.prototype.connect=function(e){var t=this,n=function(e){e.forEach(function(e){var n=e.target.getAttribute("data-id");t.callbacks[n]&&t.callbacks[n](e)})};this.observer=new IntersectionObserver(n,e),this.observerBacklog.forEach(function(e){var n=e[0],o=e[1],i=e[2];t.observe(n,o,i)}),this.observerBacklog=null},e.prototype.observe=function(e,t,n){this.observer?(this.callbacks[e]=n,this.observer.observe(t)):this.observerBacklog.push([e,t,n])},e.prototype.unobserve=function(e,t){this.observer&&(delete this.callbacks[e],this.observer.unobserve(t))},e.prototype.disconnect=function(){this.observer&&(this.callbacks={},this.observer.disconnect(),this.observer=null)},e}();t.a=a},285:function(e,t,n){"use strict";n.d(t,"a",function(){return m});var o,i=n(2),a=n.n(i),s=n(1),r=n.n(s),c=n(3),l=n.n(c),u=n(4),d=n.n(u),p=n(0),f=n.n(p),h=n(7),g=Object(h.f)({load_more:{id:"status.load_more",defaultMessage:"Load more"}}),m=Object(h.g)(o=function(e){function t(){var n,o,i;r()(this,t);for(var a=arguments.length,s=Array(a),c=0;c<a;c++)s[c]=arguments[c];return n=o=l()(this,e.call.apply(e,[this].concat(s))),o.handleClick=function(){o.props.onClick(o.props.maxId)},i=n,l()(o,i)}return d()(t,e),t.prototype.render=function(){var e=this.props,t=e.disabled,n=e.intl;return a()("button",{className:"load-more load-gap",disabled:t,onClick:this.handleClick,"aria-label":n.formatMessage(g.load_more)},void 0,a()("i",{className:"fa fa-ellipsis-h"}))},t}(f.a.PureComponent))||o},286:function(e,t,n){"use strict";n.d(t,"a",function(){return x});var o,i,a=n(34),s=n.n(a),r=n(2),c=n.n(r),l=n(55),u=n.n(l),d=n(1),p=n.n(d),f=n(3),h=n.n(f),g=n(4),m=n.n(g),b=n(32),v=n.n(b),M=n(0),_=n.n(M),y=n(14),k=n.n(y),O=n(5),w=n.n(O),I=n(277),j=n(12),C=n.n(j),R=n(285),S=n(278),N=n(7),x=(i=o=function(e){function t(){var n,o,i;p()(this,t);for(var a=arguments.length,s=Array(a),r=0;r<a;r++)s[r]=arguments[r];return n=o=h()(this,e.call.apply(e,[this].concat(s))),o.getFeaturedStatusCount=function(){return o.props.featuredStatusIds?o.props.featuredStatusIds.size:0},o.getCurrentStatusIndex=function(e,t){return t?o.props.featuredStatusIds.indexOf(e):o.props.statusIds.indexOf(e)+o.getFeaturedStatusCount()},o.handleMoveUp=function(e,t){var n=o.getCurrentStatusIndex(e,t)-1;o._selectChild(n)},o.handleMoveDown=function(e,t){var n=o.getCurrentStatusIndex(e,t)+1;o._selectChild(n)},o.handleLoadOlder=v()(function(){o.props.onLoadMore(o.props.statusIds.last())},300,{leading:!0}),o.setRef=function(e){o.node=e},i=n,h()(o,i)}return m()(t,e),t.prototype._selectChild=function(e){var t=this.node.node.querySelector("article:nth-of-type("+(e+1)+") .focusable");t&&t.focus()},t.prototype.render=function(){var e=this,t=this.props,n=t.statusIds,o=t.featuredStatusIds,i=t.onLoadMore,a=u()(t,["statusIds","featuredStatusIds","onLoadMore"]),r=a.isLoading;if(a.isPartial)return c()("div",{className:"regeneration-indicator"},void 0,c()("div",{},void 0,c()("div",{className:"regeneration-indicator__figure"}),c()("div",{className:"regeneration-indicator__label"},void 0,c()(N.b,{id:"regeneration_indicator.label",tagName:"strong",defaultMessage:"Loading…"}),c()(N.b,{id:"regeneration_indicator.sublabel",defaultMessage:"Your home feed is being prepared!"}))));var l=r||n.size>0?n.map(function(t,o){return null===t?c()(R.a,{disabled:r,maxId:o>0?n.get(o-1):null,onClick:i},"gap:"+n.get(o+1)):c()(I.a,{id:t,onMoveUp:e.handleMoveUp,onMoveDown:e.handleMoveDown},t)}):null;return l&&o&&(l=o.map(function(t){return c()(I.a,{id:t,featured:!0,onMoveUp:e.handleMoveUp,onMoveDown:e.handleMoveDown},"f-"+t)}).concat(l)),_.a.createElement(S.a,s()({},a,{onLoadMore:i&&this.handleLoadOlder,ref:this.setRef}),l)},t}(C.a),o.propTypes={scrollKey:w.a.string.isRequired,statusIds:k.a.list.isRequired,featuredStatusIds:k.a.list,onLoadMore:w.a.func,onScrollToTop:w.a.func,onScroll:w.a.func,trackScroll:w.a.bool,shouldUpdateScroll:w.a.func,isLoading:w.a.bool,isPartial:w.a.bool,hasMore:w.a.bool,prepend:w.a.node,emptyMessage:w.a.node,alwaysPrepend:w.a.bool},o.defaultProps={trackScroll:!0},i)},822:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),n.d(t,"default",function(){return D});var o,i,a,s,r=n(2),c=n.n(r),l=n(1),u=n.n(l),d=n(3),p=n.n(d),f=n(4),h=n.n(f),g=n(0),m=(n.n(g),n(9)),b=n(14),v=n.n(b),M=n(5),_=n.n(M),y=n(22),k=n(19),O=n(286),w=n(289),I=n(274),j=n(878),C=n(276),R=n(8),S=(n.n(R),n(12)),N=n.n(S),x=function(e,t){var n=t.params.accountId,o=t.withReplies,i=void 0!==o&&o,a=i?n+":with_replies":n;return{statusIds:e.getIn(["timelines","account:"+a,"items"],Object(R.List)()),featuredStatusIds:i?Object(R.List)():e.getIn(["timelines","account:"+n+":pinned","items"],Object(R.List)()),isLoading:e.getIn(["timelines","account:"+a,"isLoading"]),hasMore:e.getIn(["timelines","account:"+a,"hasMore"])}},D=(o=Object(m.connect)(x))((s=a=function(e){function t(){var n,o,i;u()(this,t);for(var a=arguments.length,s=Array(a),r=0;r<a;r++)s[r]=arguments[r];return n=o=p()(this,e.call.apply(e,[this].concat(s))),o.handleLoadMore=function(e){o.props.dispatch(Object(k.l)(o.props.params.accountId,{maxId:e,withReplies:o.props.withReplies}))},i=n,p()(o,i)}return h()(t,e),t.prototype.componentWillMount=function(){var e=this.props,t=e.params.accountId,n=e.withReplies;this.props.dispatch(Object(y.u)(t)),n||this.props.dispatch(Object(k.j)(t)),this.props.dispatch(Object(k.l)(t,{withReplies:n}))},t.prototype.componentWillReceiveProps=function(e){(e.params.accountId!==this.props.params.accountId&&e.params.accountId||e.withReplies!==this.props.withReplies)&&(this.props.dispatch(Object(y.u)(e.params.accountId)),e.withReplies||this.props.dispatch(Object(k.j)(e.params.accountId)),this.props.dispatch(Object(k.l)(e.params.accountId,{withReplies:e.params.withReplies})))},t.prototype.render=function(){var e=this.props,t=e.statusIds,n=e.featuredStatusIds,o=e.isLoading,i=e.hasMore;return!t&&o?c()(I.a,{},void 0,c()(w.a,{})):c()(I.a,{},void 0,c()(C.a,{}),c()(O.a,{prepend:c()(j.a,{accountId:this.props.params.accountId}),scrollKey:"account_timeline",statusIds:t,featuredStatusIds:n,isLoading:o,hasMore:i,onLoadMore:this.handleLoadMore}))},t}(N.a),a.propTypes={params:_.a.object.isRequired,dispatch:_.a.func.isRequired,statusIds:v.a.list,featuredStatusIds:v.a.list,isLoading:_.a.bool,hasMore:_.a.bool,withReplies:_.a.bool},i=s))||i},866:function(e,t,n){"use strict";var o=n(2),i=n.n(o),a=n(0),s=(n.n(a),n(7)),r=function(){return i()("div",{className:"regeneration-indicator missing-indicator"},void 0,i()("div",{},void 0,i()("div",{className:"regeneration-indicator__figure"}),i()("div",{className:"regeneration-indicator__label"},void 0,i()(s.b,{id:"missing_indicator.label",tagName:"strong",defaultMessage:"Not found"}),i()(s.b,{id:"missing_indicator.sublabel",defaultMessage:"This resource could not be found"}))))};t.a=r},871:function(e,t,n){"use strict";n.d(t,"a",function(){return r});var o=n(2),i=n.n(o),a=n(0),s=(n.n(a),n(7)),r=function(e){return e<1e3?i()(s.c,{value:e}):i()(a.Fragment,{},void 0,i()(s.c,{value:e/1e3,maximumFractionDigits:1}),"K")}},878:function(e,t,n){"use strict";var o=n(2),i=n.n(o),a=n(0),s=(n.n(a),n(9)),r=n(67),c=n(879),l=n(22),u=n(17),d=n(90),p=n(157),f=n(26),h=n(160),g=n(7),m=n(13),b=Object(g.f)({unfollowConfirm:{id:"confirmations.unfollow.confirm",defaultMessage:"Unfollow"},blockConfirm:{id:"confirmations.block.confirm",defaultMessage:"Block"},blockDomainConfirm:{id:"confirmations.domain_block.confirm",defaultMessage:"Hide entire domain"}}),v=function(){var e=Object(r.c)();return function(t,n){var o=n.accountId;return{account:e(t,o)}}},M=function(e,t){var n=t.intl;return{onFollow:function(t){e(t.getIn(["relationship","following"])||t.getIn(["relationship","requested"])?m.l?Object(f.d)("CONFIRM",{message:i()(g.b,{id:"confirmations.unfollow.message",defaultMessage:"Are you sure you want to unfollow {name}?",values:{name:i()("strong",{},void 0,"@",t.get("acct"))}}),confirm:n.formatMessage(b.unfollowConfirm),onConfirm:function(){return e(Object(l.D)(t.get("id")))}}):Object(l.D)(t.get("id")):Object(l.z)(t.get("id")))},onBlock:function(t){e(t.getIn(["relationship","blocking"])?Object(l.C)(t.get("id")):Object(f.d)("CONFIRM",{message:i()(g.b,{id:"confirmations.block.message",defaultMessage:"Are you sure you want to block {name}?",values:{name:i()("strong",{},void 0,"@",t.get("acct"))}}),confirm:n.formatMessage(b.blockConfirm),onConfirm:function(){return e(Object(l.q)(t.get("id")))}}))},onMention:function(t,n){e(Object(u.R)(t,n))},onDirect:function(t,n){e(Object(u.N)(t,n))},onReblogToggle:function(t){e(t.getIn(["relationship","showing_reblogs"])?Object(l.z)(t.get("id"),!1):Object(l.z)(t.get("id"),!0))},onReport:function(t){e(Object(p.k)(t))},onMute:function(t){e(t.getIn(["relationship","muting"])?Object(l.E)(t.get("id")):Object(d.g)(t))},onBlockDomain:function(t){e(Object(f.d)("CONFIRM",{message:i()(g.b,{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:i()("strong",{},void 0,t)}}),confirm:n.formatMessage(b.blockDomainConfirm),onConfirm:function(){return e(Object(h.e)(t))}}))},onUnblockDomain:function(t){e(Object(h.h)(t))}}};t.a=Object(g.g)(Object(s.connect)(v,M)(c.a))},879:function(e,t,n){"use strict";n.d(t,"a",function(){return j});var o,i,a=n(2),s=n.n(a),r=n(1),c=n.n(r),l=n(3),u=n.n(l),d=n(4),p=n.n(d),f=n(0),h=(n.n(f),n(14)),g=n.n(h),m=n(5),b=n.n(m),v=n(880),M=n(881),_=n(866),y=n(12),k=n.n(y),O=n(882),w=n(7),I=n(44),j=(i=o=function(e){function t(){var n,o,i;c()(this,t);for(var a=arguments.length,s=Array(a),r=0;r<a;r++)s[r]=arguments[r];return n=o=u()(this,e.call.apply(e,[this].concat(s))),o.handleFollow=function(){o.props.onFollow(o.props.account)},o.handleBlock=function(){o.props.onBlock(o.props.account)},o.handleMention=function(){o.props.onMention(o.props.account,o.context.router.history)},o.handleDirect=function(){o.props.onDirect(o.props.account,o.context.router.history)},o.handleReport=function(){o.props.onReport(o.props.account)},o.handleReblogToggle=function(){o.props.onReblogToggle(o.props.account)},o.handleMute=function(){o.props.onMute(o.props.account)},o.handleBlockDomain=function(){var e=o.props.account.get("acct").split("@")[1];e&&o.props.onBlockDomain(e)},o.handleUnblockDomain=function(){var e=o.props.account.get("acct").split("@")[1];e&&o.props.onUnblockDomain(e)},i=n,u()(o,i)}return p()(t,e),t.prototype.render=function(){var e=this.props,t=e.account,n=e.hideTabs;return null===t?s()(_.a,{}):s()("div",{className:"account-timeline__header"},void 0,t.get("moved")&&s()(O.a,{from:t,to:t.get("moved")}),s()(v.a,{account:t,onFollow:this.handleFollow,onBlock:this.handleBlock}),s()(M.a,{account:t,onBlock:this.handleBlock,onMention:this.handleMention,onDirect:this.handleDirect,onReblogToggle:this.handleReblogToggle,onReport:this.handleReport,onMute:this.handleMute,onBlockDomain:this.handleBlockDomain,onUnblockDomain:this.handleUnblockDomain}),!n&&s()("div",{className:"account__section-headline"},void 0,s()(I.c,{exact:!0,to:"/accounts/"+t.get("id")},void 0,s()(w.b,{id:"account.posts",defaultMessage:"Toots"})),s()(I.c,{exact:!0,to:"/accounts/"+t.get("id")+"/with_replies"},void 0,s()(w.b,{id:"account.posts_with_replies",defaultMessage:"Toots and replies"})),s()(I.c,{exact:!0,to:"/accounts/"+t.get("id")+"/media"},void 0,s()(w.b,{id:"account.media",defaultMessage:"Media"}))))},t}(k.a),o.propTypes={account:g.a.map,onFollow:b.a.func.isRequired,onBlock:b.a.func.isRequired,onMention:b.a.func.isRequired,onDirect:b.a.func.isRequired,onReblogToggle:b.a.func.isRequired,onReport:b.a.func.isRequired,onMute:b.a.func.isRequired,onBlockDomain:b.a.func.isRequired,onUnblockDomain:b.a.func.isRequired,hideTabs:b.a.bool},o.contextTypes={router:b.a.object},i)},880:function(e,t,n){"use strict";n.d(t,"a",function(){return x});var o,i,a,s,r,c=n(2),l=n.n(c),u=n(1),d=n.n(u),p=n(3),f=n.n(p),h=n(4),g=n.n(h),m=n(0),b=(n.n(m),n(14)),v=n.n(b),M=n(5),_=n.n(M),y=n(7),k=n(23),O=n(27),w=(n.n(O),n(12)),I=n.n(w),j=n(13),C=n(10),R=n.n(C),S=Object(y.f)({unfollow:{id:"account.unfollow",defaultMessage:"Unfollow"},follow:{id:"account.follow",defaultMessage:"Follow"},requested:{id:"account.requested",defaultMessage:"Awaiting approval. Click to cancel follow request"},unblock:{id:"account.unblock",defaultMessage:"Unblock @{name}"},edit_profile:{id:"account.edit_profile",defaultMessage:"Edit profile"}}),N=(i=o=function(e){function t(){var n,o,i;d()(this,t);for(var a=arguments.length,s=Array(a),r=0;r<a;r++)s[r]=arguments[r];return n=o=f()(this,e.call.apply(e,[this].concat(s))),o.state={isHovered:!1},o.handleMouseOver=function(){o.state.isHovered||o.setState({isHovered:!0})},o.handleMouseOut=function(){o.state.isHovered&&o.setState({isHovered:!1})},i=n,f()(o,i)}return g()(t,e),t.prototype.render=function(){var e=this.props.account,t=this.state.isHovered;return l()("a",{href:e.get("url"),className:"account__header__avatar",role:"presentation",target:"_blank",rel:"noopener",style:{backgroundImage:"url("+(j.a||t?e.get("avatar"):e.get("avatar_static"))+")"},onMouseOver:this.handleMouseOver,onMouseOut:this.handleMouseOut,onFocus:this.handleMouseOver,onBlur:this.handleMouseOut},void 0,l()("span",{style:{display:"none"}},void 0,e.get("acct")))},t}(I.a),o.propTypes={account:v.a.map.isRequired},i),x=Object(y.g)((r=s=function(e){function t(){var n,o,i;d()(this,t);for(var a=arguments.length,s=Array(a),r=0;r<a;r++)s[r]=arguments[r];return n=o=f()(this,e.call.apply(e,[this].concat(s))),o.openEditProfile=function(){window.open("/user-settings","_blank")},i=n,f()(o,i)}return g()(t,e),t.prototype.render=function(){var e=this.props,t=e.account,n=e.intl;if(!t)return null;var o="",i="",a="",s="";j.i!==t.get("id")&&t.getIn(["relationship","followed_by"])?o=l()("span",{className:"account--follows-info"},void 0,l()(y.b,{id:"account.follows_you",defaultMessage:"Follows you"})):j.i!==t.get("id")&&t.getIn(["relationship","blocking"])&&(o=l()("span",{className:"account--follows-info"},void 0,l()(y.b,{id:"account.blocked",defaultMessage:"Blocked"}))),j.i!==t.get("id")&&t.getIn(["relationship","muting"])?i=l()("span",{className:"account--muting-info"},void 0,l()(y.b,{id:"account.muted",defaultMessage:"Muted"})):j.i!==t.get("id")&&t.getIn(["relationship","domain_blocking"])&&(i=l()("span",{className:"account--muting-info"},void 0,l()(y.b,{id:"account.domain_blocked",defaultMessage:"Domain hidden"}))),j.i!==t.get("id")?t.getIn(["relationship","requested"])?a=l()("div",{className:"account--action-button"},void 0,l()(k.a,{size:26,active:!0,icon:"hourglass",title:n.formatMessage(S.requested),onClick:this.props.onFollow})):t.getIn(["relationship","blocking"])?t.getIn(["relationship","blocking"])&&(a=l()("div",{className:"account--action-button"},void 0,l()(k.a,{size:26,icon:"unlock-alt",title:n.formatMessage(S.unblock,{name:t.get("username")}),onClick:this.props.onBlock}))):a=l()("div",{className:"account--action-button"},void 0,l()(k.a,{size:26,icon:t.getIn(["relationship","following"])?"user-times":"user-plus",active:t.getIn(["relationship","following"]),title:n.formatMessage(t.getIn(["relationship","following"])?S.unfollow:S.follow),onClick:this.props.onFollow})):a=l()("div",{className:"account--action-button"},void 0,l()(k.a,{size:26,icon:"pencil",title:n.formatMessage(S.edit_profile),onClick:this.openEditProfile})),t.get("moved")&&!t.getIn(["relationship","following"])&&(a=""),t.get("locked")&&(s=l()("i",{className:"fa fa-lock"}));var r={__html:t.get("note_emojified")},c={__html:t.get("display_name_html")},u=t.get("fields"),d=t.get("bot")?l()("div",{className:"roles"},void 0,l()("div",{className:"account-role bot"},void 0,l()(y.b,{id:"account.badges.bot",defaultMessage:"Bot"}))):null;return l()("div",{className:R()("account__header",{inactive:!!t.get("moved")}),style:{backgroundImage:"url("+t.get("header")+")"}},void 0,l()("div",{},void 0,l()(N,{account:t}),l()("span",{className:"account__header__display-name",dangerouslySetInnerHTML:c}),l()("span",{className:"account__header__username"},void 0,"@",t.get("acct")," ",s),d,l()("div",{className:"account__header__content",dangerouslySetInnerHTML:r}),u.size>0&&l()("div",{className:"account__header__fields"},void 0,u.map(function(e,t){return l()("dl",{},t,l()("dt",{dangerouslySetInnerHTML:{__html:e.get("name_emojified")},title:e.get("name")}),l()("dd",{dangerouslySetInnerHTML:{__html:e.get("value_emojified")},title:e.get("value_plain")}))})),o,i,a))},t}(I.a),s.propTypes={account:v.a.map,onFollow:_.a.func.isRequired,onBlock:_.a.func.isRequired,intl:_.a.object.isRequired},a=r))||a},881:function(e,t,n){"use strict";n.d(t,"a",function(){return _});var o,i=n(2),a=n.n(i),s=n(1),r=n.n(s),c=n(3),l=n.n(c),u=n(4),d=n.n(u),p=n(0),f=n.n(p),h=n(291),g=n(44),m=n(7),b=n(13),v=n(871),M=Object(m.f)({mention:{id:"account.mention",defaultMessage:"Mention @{name}"},direct:{id:"account.direct",defaultMessage:"Direct message @{name}"},edit_profile:{id:"account.edit_profile",defaultMessage:"Edit profile"},unblock:{id:"account.unblock",defaultMessage:"Unblock @{name}"},unfollow:{id:"account.unfollow",defaultMessage:"Unfollow"},unmute:{id:"account.unmute",defaultMessage:"Unmute @{name}"},block:{id:"account.block",defaultMessage:"Block @{name}"},mute:{id:"account.mute",defaultMessage:"Mute @{name}"},follow:{id:"account.follow",defaultMessage:"Follow"},report:{id:"account.report",defaultMessage:"Report @{name}"},share:{id:"account.share",defaultMessage:"Share @{name}'s profile"},media:{id:"account.media",defaultMessage:"Media"},blockDomain:{id:"account.block_domain",defaultMessage:"Hide everything from {domain}"},unblockDomain:{id:"account.unblock_domain",defaultMessage:"Unhide {domain}"},hideReblogs:{id:"account.hide_reblogs",defaultMessage:"Hide boosts from @{name}"},showReblogs:{id:"account.show_reblogs",defaultMessage:"Show boosts from @{name}"},pins:{id:"navigation_bar.pins",defaultMessage:"Pinned toots"},preferences:{id:"navigation_bar.preferences",defaultMessage:"Preferences"},follow_requests:{id:"navigation_bar.follow_requests",defaultMessage:"Follow requests"},favourites:{id:"navigation_bar.favourites",defaultMessage:"Favourites"},lists:{id:"navigation_bar.lists",defaultMessage:"Lists"},blocks:{id:"navigation_bar.blocks",defaultMessage:"Blocked users"},domain_blocks:{id:"navigation_bar.domain_blocks",defaultMessage:"Hidden domains"},mutes:{id:"navigation_bar.mutes",defaultMessage:"Muted users"}}),_=Object(m.g)(o=function(e){function t(){var n,o,i;r()(this,t);for(var a=arguments.length,s=Array(a),c=0;c<a;c++)s[c]=arguments[c];return n=o=l()(this,e.call.apply(e,[this].concat(s))),o.handleShare=function(){navigator.share({url:o.props.account.get("url")})},i=n,l()(o,i)}return d()(t,e),t.prototype.render=function(){var e=this.props,t=e.account,n=e.intl,o=[],i="";if(t.get("id")!==b.i&&(o.push({text:n.formatMessage(M.mention,{name:t.get("username")}),action:this.props.onMention}),o.push({text:n.formatMessage(M.direct,{name:t.get("username")}),action:this.props.onDirect}),o.push(null)),"share"in navigator&&(o.push({text:n.formatMessage(M.share,{name:t.get("username")}),action:this.handleShare}),o.push(null)),t.get("id")===b.i?(o.push({text:n.formatMessage(M.preferences),href:"/user-settings"}),o.push({text:n.formatMessage(M.pins),to:"/pinned"}),o.push(null),o.push({text:n.formatMessage(M.follow_requests),to:"/follow_requests"}),o.push({text:n.formatMessage(M.favourites),to:"/favourites"}),o.push({text:n.formatMessage(M.lists),to:"/lists"}),o.push(null),o.push({text:n.formatMessage(M.mutes),to:"/mutes"}),o.push({text:n.formatMessage(M.blocks),to:"/blocks"}),o.push({text:n.formatMessage(M.domain_blocks),to:"/domain_blocks"})):(t.getIn(["relationship","following"])&&(t.getIn(["relationship","showing_reblogs"])?o.push({text:n.formatMessage(M.hideReblogs,{name:t.get("username")}),action:this.props.onReblogToggle}):o.push({text:n.formatMessage(M.showReblogs,{name:t.get("username")}),action:this.props.onReblogToggle})),t.getIn(["relationship","muting"])?o.push({text:n.formatMessage(M.unmute,{name:t.get("username")}),action:this.props.onMute}):o.push({text:n.formatMessage(M.mute,{name:t.get("username")}),action:this.props.onMute}),t.getIn(["relationship","blocking"])?o.push({text:n.formatMessage(M.unblock,{name:t.get("username")}),action:this.props.onBlock}):o.push({text:n.formatMessage(M.block,{name:t.get("username")}),action:this.props.onBlock}),o.push({text:n.formatMessage(M.report,{name:t.get("username")}),action:this.props.onReport})),t.get("acct")!==t.get("username")){var s=t.get("acct").split("@")[1];i=a()("div",{className:"account__disclaimer"},void 0,a()(m.b,{id:"account.disclaimer_full",defaultMessage:"Information below may reflect the user's profile incompletely."})," ",a()("a",{target:"_blank",rel:"noopener",href:t.get("url")},void 0,a()(m.b,{id:"account.view_full_profile",defaultMessage:"View full profile"}))),o.push(null),t.getIn(["relationship","domain_blocking"])?o.push({text:n.formatMessage(M.unblockDomain,{domain:s}),action:this.props.onUnblockDomain}):o.push({text:n.formatMessage(M.blockDomain,{domain:s}),action:this.props.onBlockDomain})}return a()("div",{},void 0,i,a()("div",{className:"account__action-bar"},void 0,a()("div",{className:"account__action-bar-links"},void 0,a()(g.b,{className:"account__action-bar__tab",to:"/accounts/"+t.get("id")},void 0,a()("span",{},void 0,a()(m.b,{id:"account.posts",defaultMessage:"Toots"})),a()("strong",{},void 0,Object(v.a)(t.get("statuses_count")))),a()(g.b,{className:"account__action-bar__tab",to:"/accounts/"+t.get("id")+"/following"},void 0,a()("span",{},void 0,a()(m.b,{id:"account.follows",defaultMessage:"Follows"})),a()("strong",{},void 0,Object(v.a)(t.get("following_count")))),a()(g.b,{className:"account__action-bar__tab",to:"/accounts/"+t.get("id")+"/followers"},void 0,a()("span",{},void 0,a()(m.b,{id:"account.followers",defaultMessage:"Followers"})),a()("strong",{},void 0,Object(v.a)(t.get("followers_count"))))),a()("div",{className:"account__action-bar-dropdown"},void 0,a()(h.a,{items:o,icon:"ellipsis-v",size:24,direction:"right"}))))},t}(f.a.PureComponent))||o},882:function(e,t,n){"use strict";n.d(t,"a",function(){return O});var o,i,a=n(2),s=n.n(a),r=n(1),c=n.n(r),l=n(3),u=n.n(l),d=n(4),p=n.n(d),f=n(0),h=(n.n(f),n(5)),g=n.n(h),m=n(14),b=n.n(m),v=n(7),M=n(12),_=n.n(M),y=n(292),k=n(53),O=(i=o=function(e){function t(){var n,o,i;c()(this,t);for(var a=arguments.length,s=Array(a),r=0;r<a;r++)s[r]=arguments[r];return n=o=u()(this,e.call.apply(e,[this].concat(s))),o.handleAccountClick=function(e){0===e.button&&(e.preventDefault(),o.context.router.history.push("/accounts/"+o.props.to.get("id"))),e.stopPropagation()},i=n,u()(o,i)}return p()(t,e),t.prototype.render=function(){var e=this.props,t=e.from,n=e.to,o={__html:t.get("display_name_html")};return s()("div",{className:"account__moved-note"},void 0,s()("div",{className:"account__moved-note__message"},void 0,s()("div",{className:"account__moved-note__icon-wrapper"},void 0,s()("i",{className:"fa fa-fw fa-suitcase account__moved-note__icon"})),s()(v.b,{id:"account.moved_to",defaultMessage:"{name} has moved to:",values:{name:s()("bdi",{},void 0,s()("strong",{dangerouslySetInnerHTML:o}))}})),s()("a",{href:n.get("url"),onClick:this.handleAccountClick,className:"detailed-status__display-name"},void 0,s()("div",{className:"detailed-status__display-avatar"},void 0,s()(y.a,{account:n,friend:t})),s()(k.a,{account:n})))},t}(_.a),o.contextTypes={router:g.a.object},o.propTypes={from:b.a.map.isRequired,to:b.a.map.isRequired},i)}});
|
|
//# sourceMappingURL=account_timeline.js.map
|