mirror of
https://akkoma.dev/AkkomaGang/akkoma.git
synced 2024-12-24 10:07:24 +00:00
1 line
50 KiB
Plaintext
1 line
50 KiB
Plaintext
{"version":3,"sources":["webpack:///app/javascript/builds/pleroma/mastofe/app/javascript/flavours/glitch/features/notifications/components/follow.js","webpack:///app/javascript/builds/pleroma/mastofe/app/javascript/flavours/glitch/features/notifications/components/notification.js","webpack:///app/javascript/builds/pleroma/mastofe/app/javascript/flavours/glitch/features/notifications/containers/notification_container.js","webpack:///app/javascript/builds/pleroma/mastofe/app/javascript/flavours/glitch/features/notifications/components/clear_column_button.js","webpack:///app/javascript/builds/pleroma/mastofe/app/javascript/flavours/glitch/features/notifications/components/column_settings.js","webpack:///app/javascript/builds/pleroma/mastofe/app/javascript/flavours/glitch/features/notifications/containers/column_settings_container.js","webpack:///app/javascript/builds/pleroma/mastofe/app/javascript/flavours/glitch/features/notifications/components/filter_bar.js","webpack:///app/javascript/builds/pleroma/mastofe/app/javascript/flavours/glitch/features/notifications/containers/filter_bar_container.js","webpack:///app/javascript/builds/pleroma/mastofe/app/javascript/flavours/glitch/features/notifications/index.js"],"names":["NotificationFollow","_this$props","_this","props","notification","onMoveUp","get","_this$props2","onMoveDown","handleOpenProfile","context","router","history","push","getIn","e","preventDefault","_this$props3","onMention","getHandlers","moveUp","this","handleMoveUp","moveDown","handleMoveDown","open","handleOpen","openProfile","mention","handleMention","reply","render","_this$props4","account","hidden","displayName","link","Object","jsx","permalink","className","href","title","to","dangerouslySetInnerHTML","__html","react_hotkeys_index_es","handlers","tabIndex","index_es","id","defaultMessage","values","name","account_container","withNote","overlay_container","ImmutablePureComponent","PropTypes","bool","string","isRequired","ImmutablePropTypes","map","Notification","getScrollPosition","updateScrollBottom","follow_NotificationFollow","status_container","containerId","contextType","cachedMediaWidth","cacheMediaWidth","onUnmount","withDismiss","prepend","muted","func","number","connect","getNotification","makeGetNotification","state","accountId","notifCleaning","dispatch","mentionCompose","ClearColumnButton","onClick","React","Component","ColumnSettings","path","checked","onChange","concat","settings","pushSettings","onClear","filterShowStr","filterAdvancedStr","alertStr","showStr","soundStr","showPushSettings","pushStr","pushMeta","clear_column_button_ClearColumnButton","role","aria-labelledby","setting_toggle","prefix","settingPath","label","meta","onPushChange","PureComponent","messages","defineMessages","clearMessage","clearConfirm","injectIntl","_ref","intl","changePushNotifications","slice","changeSetting","setFilter","openModal","message","formatMessage","confirm","onConfirm","clearNotifications","tooltips","mentions","favourites","boosts","polls","follows","FilterBar","notificationType","selectFilter","selectedFilter","advancedMode","newActiveFilter","getNotifications","createSelector","ImmutableList","filter","item","keys","showFilterBar","allowedType","excludedTypes","notifications","filterNot","includes","Notifications","localSettings","isLoading","isUnread","hasMore","notifCleaningActive","onEnterCleaningMode","yes","enterNotificationClearingMode","onMount","mountNotifications","unmountNotifications","maxId","expandNotifications","debounce_default","last","leading","scrollTopNotifications","columnId","removeColumn","addColumn","dir","moveColumn","column","scrollTop","c","elementIndex","findIndex","_selectChild","index","align_top","container","node","element","querySelector","offsetTop","scrollIntoView","clientHeight","offsetHeight","focus","componentDidMount","componentWillUnmount","_this2","shouldUpdateScroll","multiColumn","pinned","emptyMessage","scrollableContent","filterBarContainer","filter_bar_container","size","load_gap","disabled","handleLoadGap","notification_container","scrollContainer","scrollable_list","scrollKey","trackScroll","showLoading","onLoadMore","handleLoadOlder","onScrollToTop","handleScrollToTop","onScroll","handleScroll","react_default","a","createElement","ref","setColumnRef","extraClasses","column_header","icon","active","onPin","handlePin","onMove","handleMove","handleHeaderClick","column_settings_container"],"mappings":"oTAaqBA,+LASJ,WAAM,IAAAC,EACgBC,EAAKC,MAAhCC,EADWH,EACXG,cACRC,EAFmBJ,EACGI,UACbD,EAAaE,IAAI,qDAGX,WAAM,IAAAC,EACgBL,EAAKC,MAAlCC,EADaG,EACbH,cACRI,EAFqBD,EACCC,YACXJ,EAAaE,IAAI,iDAGjB,WACXJ,EAAKO,qEAGa,WAAM,IAChBL,EAAiBF,EAAKC,MAAtBC,aACRF,EAAKQ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AAoBA,QAVtB,EAYGI,GAIL,OACEmB,EAAAC,EAAAC,cAAC7C,EAAA,EAAD,CACE8C,IAAK9M,KAAK+M,aACV/K,KAAK,gBACLgL,aAAchN,KAAKlB,MAAMgK,oBAAsB,iBAAmB,KAClElD,MAAOU,EAAKO,cAAcb,EAAS3E,QAEnCL,OAAAC,EAAA,EAAAD,CAACiM,EAAA,EAAD,CACEC,KAAK,OACLC,OAAQvE,EACRvH,MAAOiF,EAAKO,cAAcb,EAAS3E,OACnC+L,MAAOpN,KAAKqN,UACZC,OAAQtN,KAAKuN,WACbpJ,QAASnE,KAAKwN,kBACdlC,OAAQA,EACRD,YAAaA,EACb3C,cAAe1I,KAAKlB,MAAM4J,cAC1B3E,eAAa,EACb+E,oBAAqB9I,KAAKlB,MAAMgK,oBAChCC,oBAAqB/I,KAAKlB,MAAMiK,0BAZlC,EAcE/H,OAAAC,EAAA,EAAAD,CAACyM,EAAD,KAEDhC,EACAO,OAnLkC5H,IAAM2B,4CAoBzB,CACpBoG,aAAa","file":"flavours/glitch/async/notifications.js","sourcesContent":["// Package imports.\nimport React from 'react';\nimport ImmutablePropTypes from 'react-immutable-proptypes';\nimport PropTypes from 'prop-types';\nimport { FormattedMessage } from 'react-intl';\nimport ImmutablePureComponent from 'react-immutable-pure-component';\nimport { HotKeys } from 'react-hotkeys';\n\n// Our imports.\nimport Permalink from 'flavours/glitch/components/permalink';\nimport AccountContainer from 'flavours/glitch/containers/account_container';\nimport NotificationOverlayContainer from '../containers/overlay_container';\n\nexport default class NotificationFollow extends ImmutablePureComponent {\n\n static propTypes = {\n hidden: PropTypes.bool,\n id: PropTypes.string.isRequired,\n account: ImmutablePropTypes.map.isRequired,\n notification: ImmutablePropTypes.map.isRequired,\n };\n\n handleMoveUp = () => {\n const { notification, onMoveUp } = this.props;\n onMoveUp(notification.get('id'));\n }\n\n handleMoveDown = () => {\n const { notification, onMoveDown } = this.props;\n onMoveDown(notification.get('id'));\n }\n\n handleOpen = () => {\n this.handleOpenProfile();\n }\n\n handleOpenProfile = () => {\n const { notification } = this.props;\n this.context.router.history.push(`/accounts/${notification.getIn(['account', 'id'])}`);\n }\n\n handleMention = e => {\n e.preventDefault();\n\n const { notification, onMention } = this.props;\n onMention(notification.get('account'), this.context.router.history);\n }\n\n getHandlers () {\n return {\n moveUp: this.handleMoveUp,\n moveDown: this.handleMoveDown,\n open: this.handleOpen,\n openProfile: this.handleOpenProfile,\n mention: this.handleMention,\n reply: this.handleMention,\n };\n }\n\n render () {\n const { account, notification, hidden } = this.props;\n\n // Links to the display name.\n const displayName = account.get('display_name_html') || account.get('username');\n const link = (\n <bdi><Permalink\n className='notification__display-name'\n href={account.get('url')}\n title={account.get('acct')}\n to={`/accounts/${account.get('id')}`}\n dangerouslySetInnerHTML={{ __html: displayName }}\n /></bdi>\n );\n\n // Renders.\n return (\n <HotKeys handlers={this.getHandlers()}>\n <div className='notification notification-follow focusable' tabIndex='0'>\n <div className='notification__message'>\n <div className='notification__favourite-icon-wrapper'>\n <i className='fa fa-fw fa-user-plus' />\n </div>\n\n <FormattedMessage\n id='notification.follow'\n defaultMessage='{name} followed you'\n values={{ name: link }}\n />\n </div>\n\n <AccountContainer hidden={hidden} id={account.get('id')} withNote={false} />\n <NotificationOverlayContainer notification={notification} />\n </div>\n </HotKeys>\n );\n }\n\n}\n","// Package imports.\nimport React from 'react';\nimport PropTypes from 'prop-types';\nimport ImmutablePropTypes from 'react-immutable-proptypes';\nimport ImmutablePureComponent from 'react-immutable-pure-component';\n\n// Our imports,\nimport StatusContainer from 'flavours/glitch/containers/status_container';\nimport NotificationFollow from './follow';\n\nexport default class Notification extends ImmutablePureComponent {\n\n static propTypes = {\n notification: ImmutablePropTypes.map.isRequired,\n hidden: PropTypes.bool,\n onMoveUp: PropTypes.func.isRequired,\n onMoveDown: PropTypes.func.isRequired,\n onMention: PropTypes.func.isRequired,\n getScrollPosition: PropTypes.func,\n updateScrollBottom: PropTypes.func,\n cacheMediaWidth: PropTypes.func,\n cachedMediaWidth: PropTypes.number,\n onUnmount: PropTypes.func,\n };\n\n render () {\n const {\n hidden,\n notification,\n onMoveDown,\n onMoveUp,\n onMention,\n getScrollPosition,\n updateScrollBottom,\n } = this.props;\n\n switch(notification.get('type')) {\n case 'follow':\n return (\n <NotificationFollow\n hidden={hidden}\n id={notification.get('id')}\n account={notification.get('account')}\n notification={notification}\n onMoveDown={onMoveDown}\n onMoveUp={onMoveUp}\n onMention={onMention}\n />\n );\n case 'mention':\n return (\n <StatusContainer\n containerId={notification.get('id')}\n hidden={hidden}\n id={notification.get('status')}\n notification={notification}\n onMoveDown={onMoveDown}\n onMoveUp={onMoveUp}\n onMention={onMention}\n contextType='notifications'\n getScrollPosition={getScrollPosition}\n updateScrollBottom={updateScrollBottom}\n cachedMediaWidth={this.props.cachedMediaWidth}\n cacheMediaWidth={this.props.cacheMediaWidth}\n onUnmount={this.props.onUnmount}\n withDismiss\n />\n );\n case 'favourite':\n return (\n <StatusContainer\n containerId={notification.get('id')}\n hidden={hidden}\n id={notification.get('status')}\n account={notification.get('account')}\n prepend='favourite'\n muted\n notification={notification}\n onMoveDown={onMoveDown}\n onMoveUp={onMoveUp}\n onMention={onMention}\n getScrollPosition={getScrollPosition}\n updateScrollBottom={updateScrollBottom}\n cachedMediaWidth={this.props.cachedMediaWidth}\n cacheMediaWidth={this.props.cacheMediaWidth}\n onUnmount={this.props.onUnmount}\n withDismiss\n />\n );\n case 'reblog':\n return (\n <StatusContainer\n containerId={notification.get('id')}\n hidden={hidden}\n id={notification.get('status')}\n account={notification.get('account')}\n prepend='reblog'\n muted\n notification={notification}\n onMoveDown={onMoveDown}\n onMoveUp={onMoveUp}\n onMention={onMention}\n getScrollPosition={getScrollPosition}\n updateScrollBottom={updateScrollBottom}\n cachedMediaWidth={this.props.cachedMediaWidth}\n cacheMediaWidth={this.props.cacheMediaWidth}\n onUnmount={this.props.onUnmount}\n withDismiss\n />\n );\n case 'poll':\n return (\n <StatusContainer\n containerId={notification.get('id')}\n hidden={hidden}\n id={notification.get('status')}\n account={notification.get('account')}\n prepend='poll'\n muted\n notification={notification}\n onMoveDown={onMoveDown}\n onMoveUp={onMoveUp}\n onMention={onMention}\n getScrollPosition={getScrollPosition}\n updateScrollBottom={updateScrollBottom}\n cachedMediaWidth={this.props.cachedMediaWidth}\n cacheMediaWidth={this.props.cacheMediaWidth}\n onUnmount={this.props.onUnmount}\n withDismiss\n />\n );\n default:\n return null;\n }\n }\n\n}\n","// Package imports.\nimport { connect } from 'react-redux';\n\n// Our imports.\nimport { makeGetNotification } from 'flavours/glitch/selectors';\nimport Notification from '../components/notification';\nimport { mentionCompose } from 'flavours/glitch/actions/compose';\n\nconst makeMapStateToProps = () => {\n const getNotification = makeGetNotification();\n\n const mapStateToProps = (state, props) => ({\n notification: getNotification(state, props.notification, props.accountId),\n notifCleaning: state.getIn(['notifications', 'cleaningMode']),\n });\n\n return mapStateToProps;\n};\n\nconst mapDispatchToProps = dispatch => ({\n onMention: (account, router) => {\n dispatch(mentionCompose(account, router));\n },\n});\n\nexport default connect(makeMapStateToProps, mapDispatchToProps)(Notification);\n","import React from 'react';\nimport PropTypes from 'prop-types';\nimport { FormattedMessage } from 'react-intl';\n\nexport default class ClearColumnButton extends React.Component {\n\n static propTypes = {\n onClick: PropTypes.func.isRequired,\n };\n\n render () {\n return (\n <button className='text-btn column-header__setting-btn' tabIndex='0' onClick={this.props.onClick}><i className='fa fa-eraser' /> <FormattedMessage id='notifications.clear' defaultMessage='Clear notifications' /></button>\n );\n }\n\n}\n","import React from 'react';\nimport PropTypes from 'prop-types';\nimport ImmutablePropTypes from 'react-immutable-proptypes';\nimport { FormattedMessage } from 'react-intl';\nimport ClearColumnButton from './clear_column_button';\nimport SettingToggle from './setting_toggle';\n\nexport default class ColumnSettings extends React.PureComponent {\n\n static propTypes = {\n settings: ImmutablePropTypes.map.isRequired,\n pushSettings: ImmutablePropTypes.map.isRequired,\n onChange: PropTypes.func.isRequired,\n onClear: PropTypes.func.isRequired,\n };\n\n onPushChange = (path, checked) => {\n this.props.onChange(['push', ...path], checked);\n }\n\n render () {\n const { settings, pushSettings, onChange, onClear } = this.props;\n\n const filterShowStr = <FormattedMessage id='notifications.column_settings.filter_bar.show' defaultMessage='Show' />;\n const filterAdvancedStr = <FormattedMessage id='notifications.column_settings.filter_bar.advanced' defaultMessage='Display all categories' />;\n const alertStr = <FormattedMessage id='notifications.column_settings.alert' defaultMessage='Desktop notifications' />;\n const showStr = <FormattedMessage id='notifications.column_settings.show' defaultMessage='Show in column' />;\n const soundStr = <FormattedMessage id='notifications.column_settings.sound' defaultMessage='Play sound' />;\n\n const showPushSettings = pushSettings.get('browserSupport') && pushSettings.get('isSubscribed');\n const pushStr = showPushSettings && <FormattedMessage id='notifications.column_settings.push' defaultMessage='Push notifications' />;\n const pushMeta = showPushSettings && <FormattedMessage id='notifications.column_settings.push_meta' defaultMessage='This device' />;\n\n return (\n <div>\n <div className='column-settings__row'>\n <ClearColumnButton onClick={onClear} />\n </div>\n\n <div role='group' aria-labelledby='notifications-filter-bar'>\n <span id='notifications-filter-bar' className='column-settings__section'>\n <FormattedMessage id='notifications.column_settings.filter_bar.category' defaultMessage='Quick filter bar' />\n </span>\n <div className='column-settings__row'>\n <SettingToggle id='show-filter-bar' prefix='notifications' settings={settings} settingPath={['quickFilter', 'show']} onChange={onChange} label={filterShowStr} />\n <SettingToggle id='show-filter-bar' prefix='notifications' settings={settings} settingPath={['quickFilter', 'advanced']} onChange={onChange} label={filterAdvancedStr} />\n </div>\n </div>\n\n <div role='group' aria-labelledby='notifications-follow'>\n <span id='notifications-follow' className='column-settings__section'><FormattedMessage id='notifications.column_settings.follow' defaultMessage='New followers:' /></span>\n\n <div className='column-settings__row'>\n <SettingToggle prefix='notifications_desktop' settings={settings} settingPath={['alerts', 'follow']} onChange={onChange} label={alertStr} />\n {showPushSettings && <SettingToggle prefix='notifications_push' settings={pushSettings} settingPath={['alerts', 'follow']} meta={pushMeta} onChange={this.onPushChange} label={pushStr} />}\n <SettingToggle prefix='notifications' settings={settings} settingPath={['shows', 'follow']} onChange={onChange} label={showStr} />\n <SettingToggle prefix='notifications' settings={settings} settingPath={['sounds', 'follow']} onChange={onChange} label={soundStr} />\n </div>\n </div>\n\n <div role='group' aria-labelledby='notifications-favourite'>\n <span id='notifications-favourite' className='column-settings__section'><FormattedMessage id='notifications.column_settings.favourite' defaultMessage='Favourites:' /></span>\n\n <div className='column-settings__row'>\n <SettingToggle prefix='notifications_desktop' settings={settings} settingPath={['alerts', 'favourite']} onChange={onChange} label={alertStr} />\n {showPushSettings && <SettingToggle prefix='notifications_push' settings={pushSettings} settingPath={['alerts', 'favourite']} meta={pushMeta} onChange={this.onPushChange} label={pushStr} />}\n <SettingToggle prefix='notifications' settings={settings} settingPath={['shows', 'favourite']} onChange={onChange} label={showStr} />\n <SettingToggle prefix='notifications' settings={settings} settingPath={['sounds', 'favourite']} onChange={onChange} label={soundStr} />\n </div>\n </div>\n\n <div role='group' aria-labelledby='notifications-mention'>\n <span id='notifications-mention' className='column-settings__section'><FormattedMessage id='notifications.column_settings.mention' defaultMessage='Mentions:' /></span>\n\n <div className='column-settings__row'>\n <SettingToggle prefix='notifications_desktop' settings={settings} settingPath={['alerts', 'mention']} onChange={onChange} label={alertStr} />\n {showPushSettings && <SettingToggle prefix='notifications_push' settings={pushSettings} settingPath={['alerts', 'mention']} meta={pushMeta} onChange={this.onPushChange} label={pushStr} />}\n <SettingToggle prefix='notifications' settings={settings} settingPath={['shows', 'mention']} onChange={onChange} label={showStr} />\n <SettingToggle prefix='notifications' settings={settings} settingPath={['sounds', 'mention']} onChange={onChange} label={soundStr} />\n </div>\n </div>\n\n <div role='group' aria-labelledby='notifications-reblog'>\n <span id='notifications-reblog' className='column-settings__section'><FormattedMessage id='notifications.column_settings.reblog' defaultMessage='Boosts:' /></span>\n\n <div className='column-settings__row'>\n <SettingToggle prefix='notifications_desktop' settings={settings} settingPath={['alerts', 'reblog']} onChange={onChange} label={alertStr} />\n {showPushSettings && <SettingToggle prefix='notifications_push' settings={pushSettings} settingPath={['alerts', 'reblog']} meta={pushMeta} onChange={this.onPushChange} label={pushStr} />}\n <SettingToggle prefix='notifications' settings={settings} settingPath={['shows', 'reblog']} onChange={onChange} label={showStr} />\n <SettingToggle prefix='notifications' settings={settings} settingPath={['sounds', 'reblog']} onChange={onChange} label={soundStr} />\n </div>\n </div>\n\n <div role='group' aria-labelledby='notifications-poll'>\n <span id='notifications-poll' className='column-settings__section'><FormattedMessage id='notifications.column_settings.poll' defaultMessage='Poll results:' /></span>\n\n <div className='column-settings__row'>\n <SettingToggle prefix='notifications_desktop' settings={settings} settingPath={['alerts', 'poll']} onChange={onChange} label={alertStr} />\n {showPushSettings && <SettingToggle prefix='notifications_push' settings={pushSettings} settingPath={['alerts', 'poll']} meta={pushMeta} onChange={this.onPushChange} label={pushStr} />}\n <SettingToggle prefix='notifications' settings={settings} settingPath={['shows', 'poll']} onChange={onChange} label={showStr} />\n <SettingToggle prefix='notifications' settings={settings} settingPath={['sounds', 'poll']} onChange={onChange} label={soundStr} />\n </div>\n </div>\n </div>\n );\n }\n\n}\n","import { connect } from 'react-redux';\nimport { defineMessages, injectIntl } from 'react-intl';\nimport ColumnSettings from '../components/column_settings';\nimport { changeSetting } from 'flavours/glitch/actions/settings';\nimport { setFilter } from 'flavours/glitch/actions/notifications';\nimport { clearNotifications } from 'flavours/glitch/actions/notifications';\nimport { changeAlerts as changePushNotifications } from 'flavours/glitch/actions/push_notifications';\nimport { openModal } from 'flavours/glitch/actions/modal';\n\nconst messages = defineMessages({\n clearMessage: { id: 'notifications.clear_confirmation', defaultMessage: 'Are you sure you want to permanently clear all your notifications?' },\n clearConfirm: { id: 'notifications.clear', defaultMessage: 'Clear notifications' },\n});\n\nconst mapStateToProps = state => ({\n settings: state.getIn(['settings', 'notifications']),\n pushSettings: state.get('push_notifications'),\n});\n\nconst mapDispatchToProps = (dispatch, { intl }) => ({\n\n onChange (path, checked) {\n if (path[0] === 'push') {\n dispatch(changePushNotifications(path.slice(1), checked));\n } else if (path[0] === 'quickFilter') {\n dispatch(changeSetting(['notifications', ...path], checked));\n dispatch(setFilter('all'));\n } else {\n dispatch(changeSetting(['notifications', ...path], checked));\n }\n },\n\n onClear () {\n dispatch(openModal('CONFIRM', {\n message: intl.formatMessage(messages.clearMessage),\n confirm: intl.formatMessage(messages.clearConfirm),\n onConfirm: () => dispatch(clearNotifications()),\n }));\n },\n\n});\n\nexport default injectIntl(connect(mapStateToProps, mapDispatchToProps)(ColumnSettings));\n","import React from 'react';\nimport PropTypes from 'prop-types';\nimport { defineMessages, injectIntl, FormattedMessage } from 'react-intl';\n\nconst tooltips = defineMessages({\n mentions: { id: 'notifications.filter.mentions', defaultMessage: 'Mentions' },\n favourites: { id: 'notifications.filter.favourites', defaultMessage: 'Favourites' },\n boosts: { id: 'notifications.filter.boosts', defaultMessage: 'Boosts' },\n polls: { id: 'notifications.filter.polls', defaultMessage: 'Poll results' },\n follows: { id: 'notifications.filter.follows', defaultMessage: 'Follows' },\n});\n\nexport default @injectIntl\nclass FilterBar extends React.PureComponent {\n\n static propTypes = {\n selectFilter: PropTypes.func.isRequired,\n selectedFilter: PropTypes.string.isRequired,\n advancedMode: PropTypes.bool.isRequired,\n intl: PropTypes.object.isRequired,\n };\n\n onClick (notificationType) {\n return () => this.props.selectFilter(notificationType);\n }\n\n render () {\n const { selectedFilter, advancedMode, intl } = this.props;\n const renderedElement = !advancedMode ? (\n <div className='notification__filter-bar'>\n <button\n className={selectedFilter === 'all' ? 'active' : ''}\n onClick={this.onClick('all')}\n >\n <FormattedMessage\n id='notifications.filter.all'\n defaultMessage='All'\n />\n </button>\n <button\n className={selectedFilter === 'mention' ? 'active' : ''}\n onClick={this.onClick('mention')}\n >\n <FormattedMessage\n id='notifications.filter.mentions'\n defaultMessage='Mentions'\n />\n </button>\n </div>\n ) : (\n <div className='notification__filter-bar'>\n <button\n className={selectedFilter === 'all' ? 'active' : ''}\n onClick={this.onClick('all')}\n >\n <FormattedMessage\n id='notifications.filter.all'\n defaultMessage='All'\n />\n </button>\n <button\n className={selectedFilter === 'mention' ? 'active' : ''}\n onClick={this.onClick('mention')}\n title={intl.formatMessage(tooltips.mentions)}\n >\n <i className='fa fa-fw fa-at' />\n </button>\n <button\n className={selectedFilter === 'favourite' ? 'active' : ''}\n onClick={this.onClick('favourite')}\n title={intl.formatMessage(tooltips.favourites)}\n >\n <i className='fa fa-fw fa-star' />\n </button>\n <button\n className={selectedFilter === 'reblog' ? 'active' : ''}\n onClick={this.onClick('reblog')}\n title={intl.formatMessage(tooltips.boosts)}\n >\n <i className='fa fa-fw fa-retweet' />\n </button>\n <button\n className={selectedFilter === 'poll' ? 'active' : ''}\n onClick={this.onClick('poll')}\n title={intl.formatMessage(tooltips.polls)}\n >\n <i className='fa fa-fw fa-tasks' />\n </button>\n <button\n className={selectedFilter === 'follow' ? 'active' : ''}\n onClick={this.onClick('follow')}\n title={intl.formatMessage(tooltips.follows)}\n >\n <i className='fa fa-fw fa-user-plus' />\n </button>\n </div>\n );\n return renderedElement;\n }\n\n}\n","import { connect } from 'react-redux';\nimport FilterBar from '../components/filter_bar';\nimport { setFilter } from '../../../actions/notifications';\n\nconst makeMapStateToProps = state => ({\n selectedFilter: state.getIn(['settings', 'notifications', 'quickFilter', 'active']),\n advancedMode: state.getIn(['settings', 'notifications', 'quickFilter', 'advanced']),\n});\n\nconst mapDispatchToProps = (dispatch) => ({\n selectFilter (newActiveFilter) {\n dispatch(setFilter(newActiveFilter));\n },\n});\n\nexport default connect(makeMapStateToProps, mapDispatchToProps)(FilterBar);\n","import React from 'react';\nimport { connect } from 'react-redux';\nimport PropTypes from 'prop-types';\nimport ImmutablePropTypes from 'react-immutable-proptypes';\nimport Column from 'flavours/glitch/components/column';\nimport ColumnHeader from 'flavours/glitch/components/column_header';\nimport {\n enterNotificationClearingMode,\n expandNotifications,\n scrollTopNotifications,\n mountNotifications,\n unmountNotifications,\n} from 'flavours/glitch/actions/notifications';\nimport { addColumn, removeColumn, moveColumn } from 'flavours/glitch/actions/columns';\nimport NotificationContainer from './containers/notification_container';\nimport { defineMessages, injectIntl, FormattedMessage } from 'react-intl';\nimport ColumnSettingsContainer from './containers/column_settings_container';\nimport FilterBarContainer from './containers/filter_bar_container';\nimport { createSelector } from 'reselect';\nimport { List as ImmutableList } from 'immutable';\nimport { debounce } from 'lodash';\nimport ScrollableList from 'flavours/glitch/components/scrollable_list';\nimport LoadGap from 'flavours/glitch/components/load_gap';\n\nconst messages = defineMessages({\n title: { id: 'column.notifications', defaultMessage: 'Notifications' },\n});\n\nconst getNotifications = createSelector([\n state => state.getIn(['settings', 'notifications', 'quickFilter', 'show']),\n state => state.getIn(['settings', 'notifications', 'quickFilter', 'active']),\n state => ImmutableList(state.getIn(['settings', 'notifications', 'shows']).filter(item => !item).keys()),\n state => state.getIn(['notifications', 'items']),\n], (showFilterBar, allowedType, excludedTypes, notifications) => {\n if (!showFilterBar || allowedType === 'all') {\n // used if user changed the notification settings after loading the notifications from the server\n // otherwise a list of notifications will come pre-filtered from the backend\n // we need to turn it off for FilterBar in order not to block ourselves from seeing a specific category\n return notifications.filterNot(item => item !== null && excludedTypes.includes(item.get('type')));\n }\n return notifications.filter(item => item !== null && allowedType === item.get('type'));\n});\n\nconst mapStateToProps = state => ({\n showFilterBar: state.getIn(['settings', 'notifications', 'quickFilter', 'show']),\n notifications: getNotifications(state),\n localSettings: state.get('local_settings'),\n isLoading: state.getIn(['notifications', 'isLoading'], true),\n isUnread: state.getIn(['notifications', 'unread']) > 0,\n hasMore: state.getIn(['notifications', 'hasMore']),\n notifCleaningActive: state.getIn(['notifications', 'cleaningMode']),\n});\n\n/* glitch */\nconst mapDispatchToProps = dispatch => ({\n onEnterCleaningMode(yes) {\n dispatch(enterNotificationClearingMode(yes));\n },\n onMount() {\n dispatch(mountNotifications());\n },\n onUnmount() {\n dispatch(unmountNotifications());\n },\n dispatch,\n});\n\n@connect(mapStateToProps, mapDispatchToProps)\n@injectIntl\nexport default class Notifications extends React.PureComponent {\n\n static propTypes = {\n columnId: PropTypes.string,\n notifications: ImmutablePropTypes.list.isRequired,\n showFilterBar: PropTypes.bool.isRequired,\n dispatch: PropTypes.func.isRequired,\n shouldUpdateScroll: PropTypes.func,\n intl: PropTypes.object.isRequired,\n isLoading: PropTypes.bool,\n isUnread: PropTypes.bool,\n multiColumn: PropTypes.bool,\n hasMore: PropTypes.bool,\n localSettings: ImmutablePropTypes.map,\n notifCleaningActive: PropTypes.bool,\n onEnterCleaningMode: PropTypes.func,\n onMount: PropTypes.func,\n onUnmount: PropTypes.func,\n };\n\n static defaultProps = {\n trackScroll: true,\n };\n\n handleLoadGap = (maxId) => {\n this.props.dispatch(expandNotifications({ maxId }));\n };\n\n handleLoadOlder = debounce(() => {\n const last = this.props.notifications.last();\n this.props.dispatch(expandNotifications({ maxId: last && last.get('id') }));\n }, 300, { leading: true });\n\n handleScrollToTop = debounce(() => {\n this.props.dispatch(scrollTopNotifications(true));\n }, 100);\n\n handleScroll = debounce(() => {\n this.props.dispatch(scrollTopNotifications(false));\n }, 100);\n\n handlePin = () => {\n const { columnId, dispatch } = this.props;\n\n if (columnId) {\n dispatch(removeColumn(columnId));\n } else {\n dispatch(addColumn('NOTIFICATIONS', {}));\n }\n }\n\n handleMove = (dir) => {\n const { columnId, dispatch } = this.props;\n dispatch(moveColumn(columnId, dir));\n }\n\n handleHeaderClick = () => {\n this.column.scrollTop();\n }\n\n setColumnRef = c => {\n this.column = c;\n }\n\n handleMoveUp = id => {\n const elementIndex = this.props.notifications.findIndex(item => item !== null && item.get('id') === id) - 1;\n this._selectChild(elementIndex, true);\n }\n\n handleMoveDown = id => {\n const elementIndex = this.props.notifications.findIndex(item => item !== null && item.get('id') === id) + 1;\n this._selectChild(elementIndex, false);\n }\n\n _selectChild (index, align_top) {\n const container = this.column.node;\n const element = container.querySelector(`article:nth-of-type(${index + 1}) .focusable`);\n\n if (element) {\n if (align_top && container.scrollTop > element.offsetTop) {\n element.scrollIntoView(true);\n } else if (!align_top && container.scrollTop + container.clientHeight < element.offsetTop + element.offsetHeight) {\n element.scrollIntoView(false);\n }\n element.focus();\n }\n }\n\n componentDidMount () {\n const { onMount } = this.props;\n if (onMount) {\n onMount();\n }\n }\n\n componentWillUnmount () {\n const { onUnmount } = this.props;\n if (onUnmount) {\n onUnmount();\n }\n }\n\n render () {\n const { intl, notifications, shouldUpdateScroll, isLoading, isUnread, columnId, multiColumn, hasMore, showFilterBar } = this.props;\n const pinned = !!columnId;\n const emptyMessage = <FormattedMessage id='empty_column.notifications' defaultMessage=\"You don't have any notifications yet. Interact with others to start the conversation.\" />;\n\n let scrollableContent = null;\n\n const filterBarContainer = showFilterBar\n ? (<FilterBarContainer />)\n : null;\n\n if (isLoading && this.scrollableContent) {\n scrollableContent = this.scrollableContent;\n } else if (notifications.size > 0 || hasMore) {\n scrollableContent = notifications.map((item, index) => item === null ? (\n <LoadGap\n key={'gap:' + notifications.getIn([index + 1, 'id'])}\n disabled={isLoading}\n maxId={index > 0 ? notifications.getIn([index - 1, 'id']) : null}\n onClick={this.handleLoadGap}\n />\n ) : (\n <NotificationContainer\n key={item.get('id')}\n notification={item}\n accountId={item.get('account')}\n onMoveUp={this.handleMoveUp}\n onMoveDown={this.handleMoveDown}\n />\n ));\n } else {\n scrollableContent = null;\n }\n\n this.scrollableContent = scrollableContent;\n\n const scrollContainer = (\n <ScrollableList\n scrollKey={`notifications-${columnId}`}\n trackScroll={!pinned}\n isLoading={isLoading}\n showLoading={isLoading && notifications.size === 0}\n hasMore={hasMore}\n emptyMessage={emptyMessage}\n onLoadMore={this.handleLoadOlder}\n onScrollToTop={this.handleScrollToTop}\n onScroll={this.handleScroll}\n shouldUpdateScroll={shouldUpdateScroll}\n >\n {scrollableContent}\n </ScrollableList>\n );\n\n return (\n <Column\n ref={this.setColumnRef}\n name='notifications'\n extraClasses={this.props.notifCleaningActive ? 'notif-cleaning' : null}\n label={intl.formatMessage(messages.title)}\n >\n <ColumnHeader\n icon='bell'\n active={isUnread}\n title={intl.formatMessage(messages.title)}\n onPin={this.handlePin}\n onMove={this.handleMove}\n onClick={this.handleHeaderClick}\n pinned={pinned}\n multiColumn={multiColumn}\n localSettings={this.props.localSettings}\n notifCleaning\n notifCleaningActive={this.props.notifCleaningActive} // this is used to toggle the header text\n onEnterCleaningMode={this.props.onEnterCleaningMode}\n >\n <ColumnSettingsContainer />\n </ColumnHeader>\n {filterBarContainer}\n {scrollContainer}\n </Column>\n );\n }\n\n}\n"],"sourceRoot":""} |