pleroma/priv/static/packs/features/mutes.js.map
2019-01-31 10:35:44 +01:00

1 line
No EOL
4.3 KiB
Text

{"version":3,"sources":["webpack:///app/javascript/seagate/sources/git/hacktivis.me/git/mastofe/app/javascript/mastodon/features/mutes/index.js"],"names":["messages","defineMessages","heading","id","defaultMessage","Mutes","connect","state","accountIds","getIn","injectIntl","lodash_debounce__WEBPACK_IMPORTED_MODULE_4___default","_this","props","dispatch","expandMutes","leading","componentWillMount","this","fetchMutes","render","_this$props","intl","shouldUpdateScroll","Object","_babel_runtime_helpers_esm_jsx__WEBPACK_IMPORTED_MODULE_0__","_ui_components_column__WEBPACK_IMPORTED_MODULE_12__","_components_loading_indicator__WEBPACK_IMPORTED_MODULE_11__","emptyMessage","react_intl__WEBPACK_IMPORTED_MODULE_7__","icon","formatMessage","_components_column_back_button_slim__WEBPACK_IMPORTED_MODULE_13__","_components_scrollable_list__WEBPACK_IMPORTED_MODULE_16__","scrollKey","onLoadMore","handleLoadMore","map","_containers_account_container__WEBPACK_IMPORTED_MODULE_14__","ImmutablePureComponent","params","PropTypes","object","isRequired","func","ImmutablePropTypes","list"],"mappings":"oTAcMA,EAAWC,YAAe,CAC9BC,QAAO,CAAAC,GAAA,eAAAC,eAAA,iBASHC,EAFUC,kBAJQ,SAAAC,GAAK,MAAK,CAChCC,WAAYD,EAAME,MAAM,CAAC,aAAc,QAAS,eAIjDC,6NAekBC,IAAS,WACxBC,EAAKC,MAAMC,SAASC,gBACnB,IAAK,CAAEC,SAAS,mDANnBC,mBAAA,WACEC,KAAKL,MAAMC,SAASK,kBAOtBC,OAAA,WAAU,IAAAC,EACyCH,KAAKL,MAA9CS,EADAD,EACAC,KAAMC,EADNF,EACME,mBAAoBf,EAD1Ba,EAC0Bb,WAElC,IAAKA,EACH,OACEgB,OAAAC,EAAA,EAAAD,CAACE,EAAA,EAAD,UACEF,OAAAC,EAAA,EAAAD,CAACG,EAAA,EAAD,KAKN,IAAMC,EAAeJ,OAAAC,EAAA,EAAAD,CAACK,EAAA,EAAD,CAAkB1B,GAAG,qBAAqBC,eAAe,qCAE9E,OACEoB,OAAAC,EAAA,EAAAD,CAACE,EAAA,EAAD,CAAQI,KAAK,aAAa5B,QAASoB,EAAKS,cAAc/B,EAASE,eAA/D,EACEsB,OAAAC,EAAA,EAAAD,CAACQ,EAAA,EAAD,IACAR,OAAAC,EAAA,EAAAD,CAACS,EAAA,EAAD,CACEC,UAAU,QACVC,WAAYjB,KAAKkB,eACjBb,mBAAoBA,EACpBK,aAAcA,QAJhB,EAMGpB,EAAW6B,IAAI,SAAAlC,GAAE,OAChBqB,OAAAC,EAAA,EAAAD,CAACc,EAAA,EAAD,CAA2BnC,GAAIA,GAARA,WAzCfoC,+BAEC,CACjBC,OAAQC,IAAUC,OAAOC,WACzB7B,SAAU2B,IAAUG,KAAKD,WACzBpB,mBAAoBkB,IAAUG,KAC9BpC,WAAYqC,IAAmBC,KAC/BxB,KAAMmB,IAAUC,OAAOC","file":"features/mutes.js","sourcesContent":["import React from 'react';\nimport { connect } from 'react-redux';\nimport { defineMessages, injectIntl, FormattedMessage } from 'react-intl';\nimport ImmutablePureComponent from 'react-immutable-pure-component';\nimport PropTypes from 'prop-types';\nimport ImmutablePropTypes from 'react-immutable-proptypes';\nimport { debounce } from 'lodash';\nimport LoadingIndicator from '../../components/loading_indicator';\nimport Column from '../ui/components/column';\nimport ColumnBackButtonSlim from '../../components/column_back_button_slim';\nimport AccountContainer from '../../containers/account_container';\nimport { fetchMutes, expandMutes } from '../../actions/mutes';\nimport ScrollableList from '../../components/scrollable_list';\n\nconst messages = defineMessages({\n heading: { id: 'column.mutes', defaultMessage: 'Muted users' },\n});\n\nconst mapStateToProps = state => ({\n accountIds: state.getIn(['user_lists', 'mutes', 'items']),\n});\n\nexport default @connect(mapStateToProps)\n@injectIntl\nclass Mutes extends ImmutablePureComponent {\n\n static propTypes = {\n params: PropTypes.object.isRequired,\n dispatch: PropTypes.func.isRequired,\n shouldUpdateScroll: PropTypes.func,\n accountIds: ImmutablePropTypes.list,\n intl: PropTypes.object.isRequired,\n };\n\n componentWillMount () {\n this.props.dispatch(fetchMutes());\n }\n\n handleLoadMore = debounce(() => {\n this.props.dispatch(expandMutes());\n }, 300, { leading: true });\n\n render () {\n const { intl, shouldUpdateScroll, accountIds } = this.props;\n\n if (!accountIds) {\n return (\n <Column>\n <LoadingIndicator />\n </Column>\n );\n }\n\n const emptyMessage = <FormattedMessage id='empty_column.mutes' defaultMessage=\"You haven't muted any users yet.\" />;\n\n return (\n <Column icon='volume-off' heading={intl.formatMessage(messages.heading)}>\n <ColumnBackButtonSlim />\n <ScrollableList\n scrollKey='mutes'\n onLoadMore={this.handleLoadMore}\n shouldUpdateScroll={shouldUpdateScroll}\n emptyMessage={emptyMessage}\n >\n {accountIds.map(id =>\n <AccountContainer key={id} id={id} />\n )}\n </ScrollableList>\n </Column>\n );\n }\n\n}\n"],"sourceRoot":""}