(window.webpackJsonp=window.webpackJsonp||[]).push([[88],{1111:function(e,t,o){"use strict";o.r(t),o.d(t,"default",(function(){return g}));var a,i=o(0),n=o(1),s=o.n(n),u=o(12),c=o(4),l=o(960),d=o.n(l),r=o(87),m=o(51),b=o(19),f=o(141);const h=Object(c.f)({minutes:{id:"intervals.full.minutes",defaultMessage:"{number, plural, one {# minute} other {# minutes}}"},hours:{id:"intervals.full.hours",defaultMessage:"{number, plural, one {# hour} other {# hours}}"},days:{id:"intervals.full.days",defaultMessage:"{number, plural, one {# day} other {# days}}"},indefinite:{id:"mute_modal.indefinite",defaultMessage:"Indefinite"}});let g=Object(u.connect)((e=>({account:e.getIn(["mutes","new","account"]),notifications:e.getIn(["mutes","new","notifications"]),muteDuration:e.getIn(["mutes","new","duration"])})),(e=>({onConfirm(t,o,a){e(Object(b.fb)(t.get("id"),o,a))},onClose(){e(Object(m.c)())},onToggleNotifications(){e(Object(f.n)())},onChangeMuteDuration(t){e(Object(f.j)(t.target.value))}})))(a=Object(c.g)(a=class extends s.a.PureComponent{constructor(){super(...arguments),this.handleClick=()=>{this.props.onClose(),this.props.onConfirm(this.props.account,this.props.notifications,this.props.muteDuration)},this.handleCancel=()=>{this.props.onClose()},this.setRef=e=>{this.button=e},this.toggleNotifications=()=>{this.props.onToggleNotifications()},this.changeMuteDuration=e=>{this.props.onChangeMuteDuration(e)}}componentDidMount(){this.button.focus()}render(){const{account:e,notifications:t,muteDuration:o,intl:a}=this.props;return Object(i.a)("div",{className:"modal-root__modal mute-modal"},void 0,Object(i.a)("div",{className:"mute-modal__container"},void 0,Object(i.a)("p",{},void 0,Object(i.a)(c.b,{id:"confirmations.mute.message",defaultMessage:"Are you sure you want to mute {name}?",values:{name:Object(i.a)("strong",{},void 0,"@",e.get("acct"))}})),Object(i.a)("p",{className:"mute-modal__explanation"},void 0,Object(i.a)(c.b,{id:"confirmations.mute.explanation",defaultMessage:"This will hide posts from them and posts mentioning them, but it will still allow them to see your posts and follow you."})),Object(i.a)("div",{className:"setting-toggle"},void 0,Object(i.a)(d.a,{id:"mute-modal__hide-notifications-checkbox",checked:t,onChange:this.toggleNotifications}),Object(i.a)("label",{className:"setting-toggle__label",htmlFor:"mute-modal__hide-notifications-checkbox"},void 0,Object(i.a)(c.b,{id:"mute_modal.hide_notifications",defaultMessage:"Hide notifications from this user?"}))),Object(i.a)("div",{},void 0,Object(i.a)("span",{},void 0,Object(i.a)(c.b,{id:"mute_modal.duration",defaultMessage:"Duration"}),": "),Object(i.a)("select",{value:o,onChange:this.changeMuteDuration},void 0,Object(i.a)("option",{value:0},void 0,a.formatMessage(h.indefinite)),Object(i.a)("option",{value:300},void 0,a.formatMessage(h.minutes,{number:5})),Object(i.a)("option",{value:1800},void 0,a.formatMessage(h.minutes,{number:30})),Object(i.a)("option",{value:3600},void 0,a.formatMessage(h.hours,{number:1})),Object(i.a)("option",{value:21600},void 0,a.formatMessage(h.hours,{number:6})),Object(i.a)("option",{value:86400},void 0,a.formatMessage(h.days,{number:1})),Object(i.a)("option",{value:259200},void 0,a.formatMessage(h.days,{number:3})),Object(i.a)("option",{value:604800},void 0,a.formatMessage(h.days,{number:7}))))),Object(i.a)("div",{className:"mute-modal__action-bar"},void 0,Object(i.a)(r.a,{onClick:this.handleCancel,className:"mute-modal__cancel-button"},void 0,Object(i.a)(c.b,{id:"confirmation_modal.cancel",defaultMessage:"Cancel"})),s.a.createElement(r.a,{onClick:this.handleClick,ref:this.setRef},Object(i.a)(c.b,{id:"confirmations.mute.confirm",defaultMessage:"Mute"}))))}})||a)||a}}]);
//# sourceMappingURL=mute_modal-2c0d8d59266473901b3b.chunk.js.map