{"version":3,"sources":["webpack:///./app/javascript/mastodon/features/about/index.js"],"names":["messages","defineMessages","title","rules","blocks","silenced","silencedExplanation","suspended","suspendedExplanation","severityMessages","silence","explanation","suspend","Section","React","PureComponent","state","collapsed","this","props","open","handleClick","onOpen","setState","render","children","className","classNames","active","role","tabIndex","onClick","id","fixedWidth","About","connect","server","getIn","extendedDescription","domainBlocks","injectIntl","handleDomainBlocksOpen","dispatch","fetchDomainBlocks","componentDidMount","fetchServer","fetchExtendedDescription","multiColumn","intl","isLoading","get","bindToDocument","label","formatMessage","blurhash","src","srcSet","map","value","key","replace","join","width","defaultMessage","values","mastodon","href","target","size","length","dangerouslySetInnerHTML","__html","isEmpty","rule","block","name","content"],"mappings":"2QAeA,MAAMA,EAAWC,YAAe,CAC9BC,MAAM,CAAD,0CACLC,MAAM,CAAD,gDACLC,OAAO,CAAD,sDACNC,SAAS,CAAD,kEACRC,oBAAoB,CAAD,gMACnBC,UAAU,CAAD,qEACTC,qBAAqB,CAAD,oNAGhBC,EAAmB,CACvBC,QAAS,CACPR,MAAOF,EAASK,SAChBM,YAAaX,EAASM,qBAGxBM,QAAS,CACPV,MAAOF,EAASO,UAChBI,YAAaX,EAASQ,uBAU1B,MAAMK,UAAgBC,IAAMC,cAAe,cAAD,yBASxCC,MAAQ,CACNC,WAAYC,KAAKC,MAAMC,MACvB,KAEFC,YAAc,KACZ,MAAM,OAAEC,GAAWJ,KAAKC,OAClB,UAAEF,GAAcC,KAAKF,MAE3BE,KAAKK,SAAS,CAAEN,WAAYA,IAAa,IAAMK,GAAUA,OAG3DE,SACE,MAAM,MAAEtB,EAAK,SAAEuB,GAAaP,KAAKC,OAC3B,UAAEF,GAAcC,KAAKF,MAE3B,OACE,mBAAKU,UAAWC,IAAW,iBAAkB,CAAEC,QAASX,UAAa,EACnE,mBAAKS,UAAU,wBAAwBG,KAAK,SAASC,SAAS,IAAIC,QAASb,KAAKG,kBAAY,EAC1F,YAAC,IAAI,CAACW,GAAIf,EAAY,gB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EAASI,QAASkB,OAAQJ,KAAKuB,6BAAuB,EACtFF,EAAaW,IAAI,aAChB,oCACE,YAAC,IAAQ,CAACY,MAAM,SAChB,qBACA,YAAC,IAAQ,CAACA,MAAM,SAEfvB,EAAaW,IAAI,eACpB,oCACE,0BAAG,YAAC,IAAgB,CAAClB,GAAG,+BAA+B+B,eAAe,gMAEtE,mBAAKrC,UAAU,6BAAsB,EAClCa,EAAaW,IAAI,SAASO,KAAIiB,GAC7B,mBAAKhD,UAAU,gCAAoCgD,EAAMxB,IAAI,UAC3D,mBAAKxB,UAAU,6CAAsC,EACnD,2BAAI,oBAAMxB,MAAQ,YAAWwE,EAAMxB,IAAI,kBAAY,EAAEwB,EAAMxB,IAAI,YAC/D,oBAAMxB,UAAU,qCAAqCxB,MAAO8C,EAAKK,cAAc5C,EAAiBiE,EAAMxB,IAAI,aAAavC,mBAAa,EAAEqC,EAAKK,cAAc5C,EAAiBiE,EAAMxB,IAAI,aAAahD,SAGnM,2BAAKwE,EAAMxB,IAAI,YAAc,IAAImB,OAAS,EAAIK,EAAMxB,IAAI,WAAa,YAAC,IAAgB,CAAClB,GAAG,0CAA0C+B,eAAe,+BAM3J,0BAAG,YAAC,IAAgB,CAAC/B,GAAG,sBAAsB+B,eAAe,mEAIjE,YAAC,IAAU,IAEX,mBAAKrC,UAAU,sBAAe,EAC5B,0BAAG,YAAC,IAAgB,CAACM,GAAG,mBAAmB+B,eAAe,kFAI9D,YAAC,IAAM,UACL,8BAAQf,EAAKK,cAAcrD,EAASE,QACpC,oBAAMyE,KAAK,SAASC,QAAQ,cAMrC","file":"js/features/about-b5f8a25ad6e5c29c4623.chunk.js","sourcesContent":["import React from 'react';\nimport ImmutablePropTypes from 'react-immutable-proptypes';\nimport { defineMessages, injectIntl, FormattedMessage } from 'react-intl';\nimport { connect } from 'react-redux';\nimport PropTypes from 'prop-types';\nimport Column from 'mastodon/components/column';\nimport LinkFooter from 'mastodon/features/ui/components/link_footer';\nimport { Helmet } from 'react-helmet';\nimport { fetchServer, fetchExtendedDescription, fetchDomainBlocks } from 'mastodon/actions/server';\nimport Account from 'mastodon/containers/account_container';\nimport Skeleton from 'mastodon/components/skeleton';\nimport Icon from 'mastodon/components/icon';\nimport classNames from 'classnames';\nimport Image from 'mastodon/components/image';\n\nconst messages = defineMessages({\n title: { id: 'column.about', defaultMessage: 'About' },\n rules: { id: 'about.rules', defaultMessage: 'Server rules' },\n blocks: { id: 'about.blocks', defaultMessage: 'Moderated servers' },\n silenced: { id: 'about.domain_blocks.silenced.title', defaultMessage: 'Limited' },\n silencedExplanation: { id: 'about.domain_blocks.silenced.explanation', defaultMessage: 'You will generally not see profiles and content from this server, unless you explicitly look it up or opt into it by following.' },\n suspended: { id: 'about.domain_blocks.suspended.title', defaultMessage: 'Suspended' },\n suspendedExplanation: { id: 'about.domain_blocks.suspended.explanation', defaultMessage: 'No data from this server will be processed, stored or exchanged, making any interaction or communication with users from this server impossible.' },\n});\n\nconst severityMessages = {\n silence: {\n title: messages.silenced,\n explanation: messages.silencedExplanation,\n },\n\n suspend: {\n title: messages.suspended,\n explanation: messages.suspendedExplanation,\n },\n};\n\nconst mapStateToProps = state => ({\n server: state.getIn(['server', 'server']),\n extendedDescription: state.getIn(['server', 'extendedDescription']),\n domainBlocks: state.getIn(['server', 'domainBlocks']),\n});\n\nclass Section extends React.PureComponent {\n\n static propTypes = {\n title: PropTypes.string,\n children: PropTypes.node,\n open: PropTypes.bool,\n onOpen: PropTypes.func,\n };\n\n state = {\n collapsed: !this.props.open,\n };\n\n handleClick = () => {\n const { onOpen } = this.props;\n const { collapsed } = this.state;\n\n this.setState({ collapsed: !collapsed }, () => onOpen && onOpen());\n };\n\n render () {\n const { title, children } = this.props;\n const { collapsed } = this.state;\n\n return (\n
\n
\n {title}\n
\n\n {!collapsed && (\n
{children}
\n )}\n
\n );\n }\n\n}\n\nexport default @connect(mapStateToProps)\n@injectIntl\nclass About extends React.PureComponent {\n\n static propTypes = {\n server: ImmutablePropTypes.map,\n extendedDescription: ImmutablePropTypes.map,\n domainBlocks: ImmutablePropTypes.contains({\n isLoading: PropTypes.bool,\n isAvailable: PropTypes.bool,\n items: ImmutablePropTypes.list,\n }),\n dispatch: PropTypes.func.isRequired,\n intl: PropTypes.object.isRequired,\n multiColumn: PropTypes.bool,\n };\n\n componentDidMount () {\n const { dispatch } = this.props;\n dispatch(fetchServer());\n dispatch(fetchExtendedDescription());\n }\n\n handleDomainBlocksOpen = () => {\n const { dispatch } = this.props;\n dispatch(fetchDomainBlocks());\n };\n\n render () {\n const { multiColumn, intl, server, extendedDescription, domainBlocks } = this.props;\n const isLoading = server.get('isLoading');\n\n return (\n \n
\n
\n `${value} ${key.replace('@', '')}`).join(', ')} className='about__header__hero' />\n

{isLoading ? : server.get('domain')}

\n

Mastodon }} />

\n
\n\n
\n
\n

\n\n \n
\n\n
\n\n
\n

\n\n {isLoading ? : {server.getIn(['contact', 'email'])}}\n
\n
\n\n
\n {extendedDescription.get('isLoading') ? (\n <>\n \n
\n \n
\n \n
\n \n \n ) : (extendedDescription.get('content')?.length > 0 ? (\n \n ) : (\n

\n ))}\n
\n\n
\n {!isLoading && (server.get('rules').isEmpty() ? (\n

\n ) : (\n
    \n {server.get('rules').map(rule => (\n
  1. \n {rule.get('text')}\n
  2. \n ))}\n
\n ))}\n
\n\n
\n {domainBlocks.get('isLoading') ? (\n <>\n \n
\n \n \n ) : (domainBlocks.get('isAvailable') ? (\n <>\n

\n\n
\n {domainBlocks.get('items').map(block => (\n
\n
\n
{block.get('domain')}
\n {intl.formatMessage(severityMessages[block.get('severity')].title)}\n
\n\n

{(block.get('comment') || '').length > 0 ? block.get('comment') : }

\n
\n ))}\n
\n \n ) : (\n

\n ))}\n
\n\n \n\n
\n

\n
\n
\n\n \n {intl.formatMessage(messages.title)}\n \n \n
\n );\n }\n\n}\n"],"sourceRoot":""}