{"version":3,"sources":["webpack:///app/javascript/opt/mastodon/app/javascript/flavours/glitch/features/explore/components/story.jsx","webpack:///app/javascript/opt/mastodon/app/javascript/flavours/glitch/features/explore/links.jsx","webpack:///app/javascript/opt/mastodon/app/javascript/flavours/glitch/features/explore/statuses.jsx","webpack:///app/javascript/opt/mastodon/app/javascript/flavours/glitch/features/explore/components/card.jsx","webpack:///app/javascript/opt/mastodon/app/javascript/flavours/glitch/features/explore/suggestions.jsx","webpack:///app/javascript/opt/mastodon/app/javascript/flavours/glitch/features/explore/tags.jsx","webpack:///app/javascript/opt/mastodon/app/javascript/flavours/glitch/features/explore/index.tsx"],"names":["sharesCountRenderer","displayNumber","pluralReady","_jsx","FormattedMessage","id","defaultMessage","values","count","counter","Story","_ref","url","title","lang","publisher","publishedAt","author","authorAccount","sharedTimes","thumbnail","thumbnailDescription","blurhash","expanded","thumbnailLoaded","setThumbnailLoaded","useState","handleImageLoad","useCallback","className","classNames","Skeleton","width","_jsxs","_Fragment","children","RelativeTimestamp","timestamp","href","target","rel","name","AuthorLink","accountId","Link","to","encodeURIComponent","ShortNumber","value","renderer","Blurhash","hash","src","onLoad","alt","Links","PureComponent","componentDidMount","dispatch","links","history","this","props","action","size","fetchTrendingLinks","render","isLoading","banner","DismissableBanner","isEmpty","LoadingIndicator","map","link","i","get","getIn","connect","state","withRouter","Statuses","constructor","arguments","_defineProperty","_debounce","expandTrendingStatuses","leading","statusIds","fetchTrendingStatuses","hasMore","multiColumn","emptyMessage","StatusList","trackScroll","prepend","alwaysPrepend","timelineId","scrollKey","onLoadMore","handleLoadMore","bindToDocument","withCounters","getStatusList","messages","defineMessages","dismiss","Card","source","intl","useIntl","account","useSelector","useDispatch","handleDismiss","dismissSuggestion","label","domain","Avatar","DisplayName","IconButton","iconComponent","CloseIcon","onClick","formatMessage","FollowButton","Suggestions","suggestions","length","fetchSuggestions","suggestion","account_id","sources","items","Tags","hashtags","fetchTrendingHashtags","hashtag","Hashtag","isLoadingHashtags","Explore","signedIn","useIdentity","columnRef","useRef","handleHeaderClick","_columnRef$current","current","scrollTop","Column","ref","ColumnHeader","icon","ExploreIcon","Search","singleColumn","NavLink","exact","tagName","Switch","Route","path","component","Helmet","content"],"mappings":"uVAiBA,MAAMA,EAAsBA,CAACC,EAAeC,IAC1CC,YAACC,IAAgB,CACfC,GAAE,sBACFC,eAAe,gEACfC,OAAQ,CACNC,MAAON,EACPO,QAASN,YAAA,mBAASF,MAKXS,EAAQC,IAad,IAbe,IACpBC,EAAG,MACHC,EAAK,KACLC,EAAI,UACJC,EAAS,YACTC,EAAW,OACXC,EAAM,cACNC,EAAa,YACbC,EAAW,UACXC,EAAS,qBACTC,EAAoB,SACpBC,EAAQ,SACRC,GACDZ,EACC,MAAOa,EAAiBC,GAAsBC,oBAAS,GAEjDC,EAAkBC,uBAAY,KAClCH,GAAmB,EAAK,GACvB,CAACA,IAEJ,OACEtB,YAAA,OAAK0B,UAAWC,IAAW,QAAS,CAAEP,mBAAY,EAChDpB,YAAA,OAAK0B,UAAU,uBAAgB,EAC7B1B,YAAA,OAAK0B,UAAU,kCAA2B,EACvCd,EAAYZ,YAAA,QAAMW,KAAMA,QAAK,EAAEC,GAAoBZ,YAAC4B,IAAQ,CAACC,MAAO,KAAQhB,GAAeiB,eAAAC,WAAA,CAAAC,SAAA,CAAE,MAAGhC,YAACiC,IAAiB,CAACC,UAAWrB,QAGjIb,YAAA,KAAG0B,UAAU,wBAAwBf,KAAMA,EAAMwB,KAAM1B,EAAK2B,OAAO,QAAQC,IAAI,iBAAU,EACtF3B,GAAgBV,YAAC4B,IAAQ,KAG5B5B,YAAA,OAAK0B,UAAU,+BAAwB,EACpCZ,EAASd,YAACC,IAAgB,CAACC,GAAE,sBAAuBwB,UAAU,iCAAiCvB,eAAe,YAAYC,OAAQ,CAAEkC,KAAMvB,EAAgBf,YAACuC,IAAU,CAACC,UAAWzB,IAAoBf,YAAA,mBAASc,MAAyBd,YAAA,WAChN,iBAAhBgB,EAA2BhB,YAACy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ACwJ,IAAO,CAACC,OAAK,EAAC/G,GAAG,iBAAU,EAC1B1C,YAACC,IAAgB,CACfyJ,QAAQ,MACRxJ,GAAE,4BACFC,eAAe,WAInBH,YAACwJ,IAAO,CAACC,OAAK,EAAC/G,GAAG,sBAAe,EAC/B1C,YAACC,IAAgB,CACfyJ,QAAQ,MACRxJ,GAAE,wBACFC,eAAe,cAIlBsI,GACCzI,YAACwJ,IAAO,CAACC,OAAK,EAAC/G,GAAG,6BAAsB,EACtC1C,YAACC,IAAgB,CACfyJ,QAAQ,MACRxJ,GAAE,4BACFC,eAAe,YAKrBH,YAACwJ,IAAO,CAACC,OAAK,EAAC/G,GAAG,uBAAgB,EAChC1C,YAACC,IAAgB,CACfyJ,QAAQ,MACRxJ,GAAE,yBACFC,eAAe,WAKrBH,YAAC2J,IAAM,UACL3J,YAAC4J,IAAK,CAACC,KAAK,gBAAgBC,UAAW5B,IACvClI,YAAC4J,IAAK,CAACC,KAAK,iBAAiBC,UAAW1G,IACxCpD,YAAC4J,IAAK,CAACC,KAAK,uBAAuBC,UAAWpC,IAC9C1H,YAAC4J,IAAK,CAACH,OAAK,EAACI,KAAM,CAAC,WAAY,wBAAkB,EAChD7J,YAAC6E,EAAQ,CAACU,YAAaA,MAI3BvF,YAAC+J,IAAM,UACL/J,YAAA,kBAAQyG,EAAKe,cAAcpB,EAAS1F,QACpCV,YAAA,QAAMsC,KAAK,SAAS0H,QAAQ,WAEvB,C","file":"js/flavours/glitch/async/explore-1dc459ab70bd7aed46bb.chunk.js","sourcesContent":["import PropTypes from 'prop-types';\nimport { useState, useCallback } from 'react';\n\nimport { FormattedMessage } from 'react-intl';\n\nimport classNames from 'classnames';\nimport { Link } from 'react-router-dom';\n\n\n\nimport { Blurhash } from 'flavours/glitch/components/blurhash';\nimport { RelativeTimestamp } from 'flavours/glitch/components/relative_timestamp';\nimport { ShortNumber } from 'flavours/glitch/components/short_number';\nimport { Skeleton } from 'flavours/glitch/components/skeleton';\n\nimport { AuthorLink } from './author_link';\n\nconst sharesCountRenderer = (displayNumber, pluralReady) => (\n  <FormattedMessage\n    id='link_preview.shares'\n    defaultMessage='{count, plural, one {{counter} post} other {{counter} posts}}'\n    values={{\n      count: pluralReady,\n      counter: <strong>{displayNumber}</strong>,\n    }}\n  />\n);\n\nexport const Story = ({\n  url,\n  title,\n  lang,\n  publisher,\n  publishedAt,\n  author,\n  authorAccount,\n  sharedTimes,\n  thumbnail,\n  thumbnailDescription,\n  blurhash,\n  expanded\n}) => {\n  const [thumbnailLoaded, setThumbnailLoaded] = useState(false);\n\n  const handleImageLoad = useCallback(() => {\n    setThumbnailLoaded(true);\n  }, [setThumbnailLoaded]);\n\n  return (\n    <div className={classNames('story', { expanded })}>\n      <div className='story__details'>\n        <div className='story__details__publisher'>\n          {publisher ? <span lang={lang}>{publisher}</span> : <Skeleton width={50} />}{publishedAt && <> · <RelativeTimestamp timestamp={publishedAt} /></>}\n        </div>\n\n        <a className='story__details__title' lang={lang} href={url} target='blank' rel='noopener'>\n          {title ? title : <Skeleton />}\n        </a>\n\n        <div className='story__details__shared'>\n          {author ? <FormattedMessage id='link_preview.author' className='story__details__shared__author' defaultMessage='By {name}' values={{ name: authorAccount ? <AuthorLink accountId={authorAccount} /> : <strong>{author}</strong> }} /> : <span />}\n          {typeof sharedTimes === 'number' ? <Link className='story__details__shared__pill' to={`/links/${encodeURIComponent(url)}`}><ShortNumber value={sharedTimes} renderer={sharesCountRenderer} /></Link> : <Skeleton width='10ch' />}\n        </div>\n      </div>\n\n      <a className='story__thumbnail' href={url} target='blank' rel='noopener'>\n        {thumbnail ? (\n          <>\n            <div className={classNames('story__thumbnail__preview', { 'story__thumbnail__preview--hidden': thumbnailLoaded })}><Blurhash hash={blurhash} /></div>\n            <img src={thumbnail} onLoad={handleImageLoad} alt={thumbnailDescription} title={thumbnailDescription} lang={lang} />\n          </>\n        ) : <Skeleton />}\n      </a>\n    </div>\n  );\n};\n\nStory.propTypes = {\n  url: PropTypes.string,\n  title: PropTypes.string,\n  lang: PropTypes.string,\n  publisher: PropTypes.string,\n  publishedAt: PropTypes.string,\n  author: PropTypes.string,\n  authorAccount: PropTypes.string,\n  sharedTimes: PropTypes.number,\n  thumbnail: PropTypes.string,\n  thumbnailDescription: PropTypes.string,\n  blurhash: PropTypes.string,\n  expanded: PropTypes.bool,\n};\n","import PropTypes from 'prop-types';\nimport { PureComponent } from 'react';\n\nimport { FormattedMessage } from 'react-intl';\n\nimport { withRouter } from 'react-router-dom';\n\nimport ImmutablePropTypes from 'react-immutable-proptypes';\nimport { connect } from 'react-redux';\n\nimport { fetchTrendingLinks } from 'flavours/glitch/actions/trends';\nimport { DismissableBanner } from 'flavours/glitch/components/dismissable_banner';\nimport { LoadingIndicator } from 'flavours/glitch/components/loading_indicator';\nimport { WithRouterPropTypes } from 'flavours/glitch/utils/react_router';\n\nimport { Story } from './components/story';\n\nconst mapStateToProps = state => ({\n  links: state.getIn(['trends', 'links', 'items']),\n  isLoading: state.getIn(['trends', 'links', 'isLoading']),\n});\n\nclass Links extends PureComponent {\n\n  static propTypes = {\n    links: ImmutablePropTypes.list,\n    isLoading: PropTypes.bool,\n    dispatch: PropTypes.func.isRequired,\n    ...WithRouterPropTypes,\n  };\n\n  componentDidMount () {\n    const { dispatch, links, history } = this.props;\n\n    // If we're navigating back to the screen, do not trigger a reload\n    if (history.action === 'POP' && links.size > 0) {\n      return;\n    }\n\n    dispatch(fetchTrendingLinks());\n  }\n\n  render () {\n    const { isLoading, links } = this.props;\n\n    const banner = (\n      <DismissableBanner id='explore/links'>\n        <FormattedMessage id='dismissable_banner.explore_links' defaultMessage='These news stories are being shared the most on the fediverse today. Newer news stories posted by more different people are ranked higher.' />\n      </DismissableBanner>\n    );\n\n    if (!isLoading && links.isEmpty()) {\n      return (\n        <div className='explore__links scrollable scrollable--flex'>\n          {banner}\n\n          <div className='empty-column-indicator'>\n            <FormattedMessage id='empty_column.explore_statuses' defaultMessage='Nothing is trending right now. Check back later!' />\n          </div>\n        </div>\n      );\n    }\n\n    return (\n      <div className='explore__links scrollable' data-nosnippet>\n        {banner}\n\n        {isLoading ? (<LoadingIndicator />) : links.map((link, i) => (\n          <Story\n            key={link.get('id')}\n            expanded={i === 0}\n            lang={link.get('language')}\n            url={link.get('url')}\n            title={link.get('title')}\n            publisher={link.get('provider_name')}\n            publishedAt={link.get('published_at')}\n            author={link.get('author_name')}\n            authorAccount={link.getIn(['authors', 0, 'account', 'id'])}\n            sharedTimes={link.getIn(['history', 0, 'accounts']) * 1 + link.getIn(['history', 1, 'accounts']) * 1}\n            thumbnail={link.get('image')}\n            thumbnailDescription={link.get('image_description')}\n            blurhash={link.get('blurhash')}\n          />\n        ))}\n      </div>\n    );\n  }\n\n}\n\nexport default connect(mapStateToProps)(withRouter(Links));\n","import PropTypes from 'prop-types';\nimport { PureComponent } from 'react';\n\nimport { FormattedMessage } from 'react-intl';\n\nimport { withRouter } from 'react-router-dom';\n\nimport ImmutablePropTypes from 'react-immutable-proptypes';\nimport { connect } from 'react-redux';\n\nimport { debounce } from 'lodash';\n\n\nimport { fetchTrendingStatuses, expandTrendingStatuses } from 'flavours/glitch/actions/trends';\nimport { DismissableBanner } from 'flavours/glitch/components/dismissable_banner';\nimport StatusList from 'flavours/glitch/components/status_list';\nimport { getStatusList } from 'flavours/glitch/selectors';\nimport { WithRouterPropTypes } from 'flavours/glitch/utils/react_router';\n\nconst mapStateToProps = state => ({\n  statusIds: getStatusList(state, 'trending'),\n  isLoading: state.getIn(['status_lists', 'trending', 'isLoading'], true),\n  hasMore: !!state.getIn(['status_lists', 'trending', 'next']),\n});\n\nclass Statuses extends PureComponent {\n\n  static propTypes = {\n    statusIds: ImmutablePropTypes.list,\n    isLoading: PropTypes.bool,\n    hasMore: PropTypes.bool,\n    multiColumn: PropTypes.bool,\n    dispatch: PropTypes.func.isRequired,\n    ...WithRouterPropTypes,\n  };\n\n  componentDidMount () {\n    const { dispatch, statusIds, history } = this.props;\n\n    // If we're navigating back to the screen, do not trigger a reload\n    if (history.action === 'POP' && statusIds.size > 0) {\n      return;\n    }\n\n    dispatch(fetchTrendingStatuses());\n  }\n\n  handleLoadMore = debounce(() => {\n    const { dispatch } = this.props;\n    dispatch(expandTrendingStatuses());\n  }, 300, { leading: true });\n\n  render () {\n    const { isLoading, hasMore, statusIds, multiColumn } = this.props;\n\n    const emptyMessage = <FormattedMessage id='empty_column.explore_statuses' defaultMessage='Nothing is trending right now. Check back later!' />;\n\n    return (\n      <StatusList\n        trackScroll\n        prepend={<DismissableBanner id='explore/statuses'><FormattedMessage id='dismissable_banner.explore_statuses' defaultMessage='These posts from across the fediverse are gaining traction today. Newer posts with more boosts and favorites are ranked higher.' /></DismissableBanner>}\n        alwaysPrepend\n        timelineId='explore'\n        statusIds={statusIds}\n        scrollKey='explore-statuses'\n        hasMore={hasMore}\n        isLoading={isLoading}\n        onLoadMore={this.handleLoadMore}\n        emptyMessage={emptyMessage}\n        bindToDocument={!multiColumn}\n        withCounters\n      />\n    );\n  }\n\n}\n\nexport default connect(mapStateToProps)(withRouter(Statuses));\n","import PropTypes from 'prop-types';\nimport { useCallback } from 'react';\n\nimport { FormattedMessage, useIntl, defineMessages } from 'react-intl';\n\nimport { Link } from 'react-router-dom';\n\nimport { useDispatch, useSelector } from 'react-redux';\n\nimport CloseIcon from '@/material-icons/400-24px/close.svg?react';\nimport { dismissSuggestion } from 'flavours/glitch/actions/suggestions';\nimport { Avatar } from 'flavours/glitch/components/avatar';\nimport { DisplayName } from 'flavours/glitch/components/display_name';\nimport { FollowButton } from 'flavours/glitch/components/follow_button';\nimport { IconButton } from 'flavours/glitch/components/icon_button';\nimport { domain } from 'flavours/glitch/initial_state';\n\nconst messages = defineMessages({\n  dismiss: { id: 'follow_suggestions.dismiss', defaultMessage: \"Don't show again\" },\n});\n\nexport const Card = ({ id, source }) => {\n  const intl = useIntl();\n  const account = useSelector(state => state.getIn(['accounts', id]));\n  const dispatch = useDispatch();\n\n  const handleDismiss = useCallback(() => {\n    dispatch(dismissSuggestion(id));\n  }, [id, dispatch]);\n\n  let label;\n\n  switch (source) {\n  case 'friends_of_friends':\n    label = <FormattedMessage id='follow_suggestions.friends_of_friends_longer' defaultMessage='Popular among people you follow' />;\n    break;\n  case 'similar_to_recently_followed':\n    label = <FormattedMessage id='follow_suggestions.similar_to_recently_followed_longer' defaultMessage='Similar to profiles you recently followed' />;\n    break;\n  case 'featured':\n    label = <FormattedMessage id='follow_suggestions.featured_longer' defaultMessage='Hand-picked by the {domain} team' values={{ domain }} />;\n    break;\n  case 'most_followed':\n    label = <FormattedMessage id='follow_suggestions.popular_suggestion_longer' defaultMessage='Popular on {domain}' values={{ domain }} />;\n    break;\n  case 'most_interactions':\n    label = <FormattedMessage id='follow_suggestions.popular_suggestion_longer' defaultMessage='Popular on {domain}' values={{ domain }} />;\n    break;\n  }\n\n  return (\n    <div className='explore__suggestions__card'>\n      <div className='explore__suggestions__card__source'>\n        {label}\n      </div>\n\n      <div className='explore__suggestions__card__body'>\n        <Link to={`/@${account.get('acct')}`} data-hover-card-account={account.id}><Avatar account={account} size={48} /></Link>\n\n        <div className='explore__suggestions__card__body__main'>\n          <div className='explore__suggestions__card__body__main__name-button'>\n            <Link className='explore__suggestions__card__body__main__name-button__name' to={`/@${account.get('acct')}`} data-hover-card-account={account.id}><DisplayName account={account} /></Link>\n            <IconButton iconComponent={CloseIcon} onClick={handleDismiss} title={intl.formatMessage(messages.dismiss)} />\n            <FollowButton accountId={account.get('id')} />\n          </div>\n        </div>\n      </div>\n    </div>\n  );\n};\n\nCard.propTypes = {\n  id: PropTypes.string.isRequired,\n  source: PropTypes.oneOf(['friends_of_friends', 'similar_to_recently_followed', 'featured', 'most_followed', 'most_interactions']),\n};\n","import PropTypes from 'prop-types';\nimport { PureComponent } from 'react';\n\nimport { FormattedMessage } from 'react-intl';\n\nimport { withRouter } from 'react-router-dom';\n\nimport { connect } from 'react-redux';\n\nimport { fetchSuggestions } from 'flavours/glitch/actions/suggestions';\nimport { LoadingIndicator } from 'flavours/glitch/components/loading_indicator';\nimport { WithRouterPropTypes } from 'flavours/glitch/utils/react_router';\n\nimport { Card } from './components/card';\n\nconst mapStateToProps = state => ({\n  suggestions: state.suggestions.items,\n  isLoading: state.suggestions.isLoading,\n});\n\nclass Suggestions extends PureComponent {\n\n  static propTypes = {\n    isLoading: PropTypes.bool,\n    suggestions: PropTypes.array,\n    dispatch: PropTypes.func.isRequired,\n    ...WithRouterPropTypes,\n  };\n\n  componentDidMount () {\n    const { dispatch, suggestions, history } = this.props;\n\n    // If we're navigating back to the screen, do not trigger a reload\n    if (history.action === 'POP' && suggestions.length > 0) {\n      return;\n    }\n\n    dispatch(fetchSuggestions());\n  }\n\n  render () {\n    const { isLoading, suggestions } = this.props;\n\n    if (!isLoading && suggestions.length === 0) {\n      return (\n        <div className='explore__suggestions scrollable scrollable--flex'>\n          <div className='empty-column-indicator'>\n            <FormattedMessage id='empty_column.explore_statuses' defaultMessage='Nothing is trending right now. Check back later!' />\n          </div>\n        </div>\n      );\n    }\n\n    return (\n      <div className='explore__suggestions scrollable' data-nosnippet>\n        {isLoading ? <LoadingIndicator /> : suggestions.map(suggestion => (\n          <Card\n            key={suggestion.account_id}\n            id={suggestion.account_id}\n            source={suggestion.sources[0]}\n          />\n        ))}\n      </div>\n    );\n  }\n\n}\n\nexport default connect(mapStateToProps)(withRouter(Suggestions));\n","import PropTypes from 'prop-types';\nimport { PureComponent } from 'react';\n\nimport { FormattedMessage } from 'react-intl';\n\nimport { withRouter } from 'react-router-dom';\n\nimport ImmutablePropTypes from 'react-immutable-proptypes';\nimport { connect } from 'react-redux';\n\nimport { fetchTrendingHashtags } from 'flavours/glitch/actions/trends';\nimport { DismissableBanner } from 'flavours/glitch/components/dismissable_banner';\nimport { ImmutableHashtag as Hashtag } from 'flavours/glitch/components/hashtag';\nimport { LoadingIndicator } from 'flavours/glitch/components/loading_indicator';\nimport { WithRouterPropTypes } from 'flavours/glitch/utils/react_router';\n\nconst mapStateToProps = state => ({\n  hashtags: state.getIn(['trends', 'tags', 'items']),\n  isLoadingHashtags: state.getIn(['trends', 'tags', 'isLoading']),\n});\n\nclass Tags extends PureComponent {\n\n  static propTypes = {\n    hashtags: ImmutablePropTypes.list,\n    isLoading: PropTypes.bool,\n    dispatch: PropTypes.func.isRequired,\n    ...WithRouterPropTypes,\n  };\n\n  componentDidMount () {\n    const { dispatch, history, hashtags } = this.props;\n\n    // If we're navigating back to the screen, do not trigger a reload\n    if (history.action === 'POP' && hashtags.size > 0) {\n      return;\n    }\n\n    dispatch(fetchTrendingHashtags());\n  }\n\n  render () {\n    const { isLoading, hashtags } = this.props;\n\n    const banner = (\n      <DismissableBanner id='explore/tags'>\n        <FormattedMessage id='dismissable_banner.explore_tags' defaultMessage='These hashtags are gaining traction on the fediverse today. Hashtags that are used by more different people are ranked higher.' />\n      </DismissableBanner>\n    );\n\n    if (!isLoading && hashtags.isEmpty()) {\n      return (\n        <div className='explore__links scrollable scrollable--flex'>\n          {banner}\n\n          <div className='empty-column-indicator'>\n            <FormattedMessage id='empty_column.explore_statuses' defaultMessage='Nothing is trending right now. Check back later!' />\n          </div>\n        </div>\n      );\n    }\n\n    return (\n      <div className='scrollable explore__links' data-nosnippet>\n        {banner}\n\n        {isLoading ? (<LoadingIndicator />) : hashtags.map(hashtag => (\n          <Hashtag key={hashtag.get('name')} hashtag={hashtag} />\n        ))}\n      </div>\n    );\n  }\n\n}\n\nexport default connect(mapStateToProps)(withRouter(Tags));\n","import { useCallback, useRef } from 'react';\n\nimport { defineMessages, useIntl, FormattedMessage } from 'react-intl';\n\nimport { Helmet } from 'react-helmet';\nimport { NavLink, Switch, Route } from 'react-router-dom';\n\nimport ExploreIcon from '@/material-icons/400-24px/explore.svg?react';\nimport { Column } from 'flavours/glitch/components/column';\nimport type { ColumnRef } from 'flavours/glitch/components/column';\nimport { ColumnHeader } from 'flavours/glitch/components/column_header';\nimport { Search } from 'flavours/glitch/features/compose/components/search';\nimport { useIdentity } from 'flavours/glitch/identity_context';\n\nimport Links from './links';\nimport Statuses from './statuses';\nimport Suggestions from './suggestions';\nimport Tags from './tags';\n\nconst messages = defineMessages({\n  title: { id: 'explore.title', defaultMessage: 'Explore' },\n});\n\nconst Explore: React.FC<{ multiColumn: boolean }> = ({ multiColumn }) => {\n  const { signedIn } = useIdentity();\n  const intl = useIntl();\n  const columnRef = useRef<ColumnRef>(null);\n\n  const handleHeaderClick = useCallback(() => {\n    columnRef.current?.scrollTop();\n  }, []);\n\n  return (\n    <Column\n      bindToDocument={!multiColumn}\n      ref={columnRef}\n      label={intl.formatMessage(messages.title)}\n    >\n      <ColumnHeader\n        icon={'explore'}\n        iconComponent={ExploreIcon}\n        title={intl.formatMessage(messages.title)}\n        onClick={handleHeaderClick}\n        multiColumn={multiColumn}\n      />\n\n      <div className='explore__search-header'>\n        <Search singleColumn />\n      </div>\n\n      <div className='account__section-headline'>\n        <NavLink exact to='/explore'>\n          <FormattedMessage\n            tagName='div'\n            id='explore.trending_statuses'\n            defaultMessage='Posts'\n          />\n        </NavLink>\n\n        <NavLink exact to='/explore/tags'>\n          <FormattedMessage\n            tagName='div'\n            id='explore.trending_tags'\n            defaultMessage='Hashtags'\n          />\n        </NavLink>\n\n        {signedIn && (\n          <NavLink exact to='/explore/suggestions'>\n            <FormattedMessage\n              tagName='div'\n              id='explore.suggested_follows'\n              defaultMessage='People'\n            />\n          </NavLink>\n        )}\n\n        <NavLink exact to='/explore/links'>\n          <FormattedMessage\n            tagName='div'\n            id='explore.trending_links'\n            defaultMessage='News'\n          />\n        </NavLink>\n      </div>\n\n      <Switch>\n        <Route path='/explore/tags' component={Tags} />\n        <Route path='/explore/links' component={Links} />\n        <Route path='/explore/suggestions' component={Suggestions} />\n        <Route exact path={['/explore', '/explore/posts']}>\n          <Statuses multiColumn={multiColumn} />\n        </Route>\n      </Switch>\n\n      <Helmet>\n        <title>{intl.formatMessage(messages.title)}</title>\n        <meta name='robots' content='all' />\n      </Helmet>\n    </Column>\n  );\n};\n\n// eslint-disable-next-line import/no-default-export\nexport default Explore;\n"],"sourceRoot":""}