(window.webpackJsonp=window.webpackJsonp||[]).push([[92],{1127:function(e,t,n){"use strict";n.r(t),n.d(t,"default",(function(){return f}));var c=n(0),a=(n(1),n(3)),o=n.n(a),s=n(16),i=n.n(s),d=n(12),r=n(18),u=n(4),l=n(19),b=n(143),j=n(1433);var p=Object(u.g)(Object(d.connect)((()=>{const e=Object(b.e)();return(t,n)=>{let{accountId:c,added:a}=n;return{account:e(t,c),added:void 0===a?t.getIn(["pinnedAccountsEditor","accounts","items"]).includes(c):a}}}),((e,t)=>{let{accountId:n}=t;return{onRemove:()=>e(Object(l.nb)(n)),onAdd:()=>e(Object(l.gb)(n))}}))(j.a)),O=n(1434);var v,m,I=Object(u.g)(Object(d.connect)((e=>({value:e.getIn(["pinnedAccountsEditor","suggestions","value"])})),(e=>({onSubmit:t=>e(Object(l.bb)(t)),onClear:()=>e(Object(l.S)()),onChange:t=>e(Object(l.R)(t))})))(O.a)),g=n(227),_=n(26),R=n.n(_);let f=Object(d.connect)((e=>({accountIds:e.getIn(["pinnedAccountsEditor","accounts","items"]),searchAccountIds:e.getIn(["pinnedAccountsEditor","suggestions","items"])})),(e=>({onInitialize:()=>e(Object(l.ab)()),onClear:()=>e(Object(l.S)()),onReset:()=>e(Object(l.ib)())})))(v=Object(u.g)(((m=class extends r.a{componentDidMount(){const{onInitialize:e}=this.props;e()}componentWillUnmount(){const{onReset:e}=this.props;e()}render(){const{accountIds:e,searchAccountIds:t,onClear:n}=this.props,a=t.size>0;return Object(c.a)("div",{className:"modal-root__modal list-editor"},void 0,Object(c.a)("h4",{},void 0,Object(c.a)(u.b,{id:"endorsed_accounts_editor.endorsed_accounts",defaultMessage:"Featured accounts"})),Object(c.a)(I,{}),Object(c.a)("div",{className:"drawer__pager"},void 0,Object(c.a)("div",{className:"drawer__inner list-editor__accounts"},void 0,e.map((e=>Object(c.a)(p,{accountId:e,added:!0},e)))),a&&Object(c.a)("div",{role:"button",tabIndex:"-1",className:"drawer__backdrop",onClick:n}),Object(c.a)(g.a,{defaultStyle:{x:-100},style:{x:R()(a?0:-100,{stiffness:210,damping:20})}},void 0,(e=>{let{x:n}=e;return Object(c.a)("div",{className:"drawer__inner backdrop",style:{transform:0===n?null:"translateX("+n+"%)",visibility:-100===n?"hidden":"visible"}},void 0,t.map((e=>Object(c.a)(p,{accountId:e},e))))}))))}}).propTypes={onClose:o.a.func.isRequired,intl:o.a.object.isRequired,onInitialize:o.a.func.isRequired,onClear:o.a.func.isRequired,onReset:o.a.func.isRequired,title:o.a.string.isRequired,accountIds:i.a.list.isRequired,searchAccountIds:i.a.list.isRequired},v=m))||v)||v}}]);
//# sourceMappingURL=pinned_accounts_editor-0e0b31d4b305a6ac0a1a.chunk.js.map