Pleroma/priv/static/packs/flavours/glitch/async/notifications.js.map
Haelwenn (lanodan) Monnier 2a850abbeb
MastoFE: Bundle 2020-01-20
2020-02-29 06:41:13 +01:00

1 line
57 KiB
Plaintext

{"version":3,"sources":["webpack:///app/javascript/tank/sources/git/git.pleroma.social/pleroma/mastofe/app/javascript/flavours/glitch/features/notifications/components/follow.js","webpack:///app/javascript/tank/sources/git/git.pleroma.social/pleroma/mastofe/app/javascript/flavours/glitch/features/notifications/components/follow_request.js","webpack:///app/javascript/tank/sources/git/git.pleroma.social/pleroma/mastofe/app/javascript/flavours/glitch/features/notifications/containers/follow_request_container.js","webpack:///app/javascript/tank/sources/git/git.pleroma.social/pleroma/mastofe/app/javascript/flavours/glitch/features/notifications/components/notification.js","webpack:///app/javascript/tank/sources/git/git.pleroma.social/pleroma/mastofe/app/javascript/flavours/glitch/features/notifications/containers/notification_container.js","webpack:///app/javascript/tank/sources/git/git.pleroma.social/pleroma/mastofe/app/javascript/flavours/glitch/features/notifications/components/clear_column_button.js","webpack:///app/javascript/tank/sources/git/git.pleroma.social/pleroma/mastofe/app/javascript/flavours/glitch/features/notifications/components/column_settings.js","webpack:///app/javascript/tank/sources/git/git.pleroma.social/pleroma/mastofe/app/javascript/flavours/glitch/features/notifications/containers/column_settings_container.js","webpack:///app/javascript/tank/sources/git/git.pleroma.social/pleroma/mastofe/app/javascript/flavours/glitch/features/notifications/components/filter_bar.js","webpack:///app/javascript/tank/sources/git/git.pleroma.social/pleroma/mastofe/app/javascript/flavours/glitch/features/notifications/containers/filter_bar_container.js","webpack:///app/javascript/tank/sources/git/git.pleroma.social/pleroma/mastofe/app/javascript/flavours/glitch/features/notifications/index.js"],"names":["NotificationFollow","props","notification","onMoveUp","get","onMoveDown","handleOpenProfile","context","router","history","push","getIn","e","preventDefault","onMention","getHandlers","moveUp","this","handleMoveUp","moveDown","handleMoveDown","open","handleOpen","openProfile","mention","handleMention","reply","render","account","hidden","displayName","link","className","href","title","to","dangerouslySetInnerHTML","__html","handlers","tabIndex","fixedWidth","id","defaultMessage","values","name","withNote","ImmutablePureComponent","PropTypes","bool","string","isRequired","ImmutablePropTypes","map","messages","defineMessages","authorize","reject","FollowRequest","injectIntl","intl","onAuthorize","onReject","size","formatMessage","icon","onClick","func","object","connect","dispatch","authorizeFollowRequest","rejectFollowRequest","Notification","getScrollPosition","updateScrollBottom","containerId","contextType","cachedMediaWidth","cacheMediaWidth","onUnmount","withDismiss","prepend","muted","number","getNotification","makeGetNotification","state","accountId","notifCleaning","mentionCompose","ClearColumnButton","React","Component","ColumnSettings","path","checked","onChange","settings","pushSettings","onClear","filterShowStr","filterAdvancedStr","alertStr","showStr","soundStr","showPushSettings","pushStr","pushMeta","role","aria-labelledby","prefix","settingPath","label","meta","onPushChange","PureComponent","clearMessage","clearConfirm","changePushNotifications","slice","changeSetting","setFilter","openModal","message","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","numPending","notifCleaningActive","onEnterCleaningMode","yes","enterNotificationClearingMode","onMount","mountNotifications","unmountNotifications","maxId","expandNotifications","last","leading","loadPending","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","shouldUpdateScroll","multiColumn","pinned","emptyMessage","scrollableContent","filterBarContainer","disabled","handleLoadGap","scrollContainer","scrollKey","trackScroll","showLoading","onLoadMore","handleLoadOlder","onLoadPending","handleLoadPending","onScrollToTop","handleScrollToTop","onScroll","handleScroll","bindToDocument","ref","setColumnRef","extraClasses","active","onPin","handlePin","onMove","handleMove","handleHeaderClick"],"mappings":"6TAcqBA,E,8LASJ,WAAO,IAA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B5I,KAAKhB,MAAM4J,oBAChCC,oBAAqB7I,KAAKhB,MAAM6J,0BAZlC,EAcE,YAAC,GAAD,KAEDyC,EACAG,I,GA5LmB/G,IAAMwB,e,6BAqBV,CACpByF,aAAa,I","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';\nimport Icon from 'flavours/glitch/components/icon';\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 <Icon fixedWidth id='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","import React, { Fragment } from 'react';\nimport ImmutablePropTypes from 'react-immutable-proptypes';\nimport PropTypes from 'prop-types';\nimport Avatar from 'flavours/glitch/components/avatar';\nimport DisplayName from 'flavours/glitch/components/display_name';\nimport Permalink from 'flavours/glitch/components/permalink';\nimport IconButton from 'flavours/glitch/components/icon_button';\nimport { defineMessages, injectIntl, FormattedMessage } from 'react-intl';\nimport ImmutablePureComponent from 'react-immutable-pure-component';\nimport NotificationOverlayContainer from '../containers/overlay_container';\nimport { HotKeys } from 'react-hotkeys';\nimport Icon from 'flavours/glitch/components/icon';\n\nconst messages = defineMessages({\n authorize: { id: 'follow_request.authorize', defaultMessage: 'Authorize' },\n reject: { id: 'follow_request.reject', defaultMessage: 'Reject' },\n});\n\nexport default @injectIntl\nclass FollowRequest extends ImmutablePureComponent {\n\n static propTypes = {\n account: ImmutablePropTypes.map.isRequired,\n onAuthorize: PropTypes.func.isRequired,\n onReject: PropTypes.func.isRequired,\n intl: PropTypes.object.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 { intl, hidden, account, onAuthorize, onReject, notification } = this.props;\n\n if (!account) {\n return <div />;\n }\n\n if (hidden) {\n return (\n <Fragment>\n {account.get('display_name')}\n {account.get('username')}\n </Fragment>\n );\n }\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 return (\n <HotKeys handlers={this.getHandlers()}>\n <div className='notification notification-follow-request focusable' tabIndex='0'>\n <div className='notification__message'>\n <div className='notification__favourite-icon-wrapper'>\n <Icon id='user' fixedWidth />\n </div>\n\n <FormattedMessage\n id='notification.follow_request'\n defaultMessage='{name} has requested to follow you'\n values={{ name: link }}\n />\n </div>\n\n <div className='account'>\n <div className='account__wrapper'>\n <Permalink key={account.get('id')} className='account__display-name' title={account.get('acct')} href={account.get('url')} to={`/accounts/${account.get('id')}`}>\n <div className='account__avatar-wrapper'><Avatar account={account} size={36} /></div>\n <DisplayName account={account} />\n </Permalink>\n\n <div className='account__relationship'>\n <IconButton title={intl.formatMessage(messages.authorize)} icon='check' onClick={onAuthorize} />\n <IconButton title={intl.formatMessage(messages.reject)} icon='times' onClick={onReject} />\n </div>\n </div>\n </div>\n\n <NotificationOverlayContainer notification={notification} />\n </div>\n </HotKeys>\n );\n }\n\n}\n","import { connect } from 'react-redux';\nimport { makeGetAccount } from 'flavours/glitch/selectors';\nimport FollowRequest from '../components/follow_request';\nimport { authorizeFollowRequest, rejectFollowRequest } from 'flavours/glitch/actions/accounts';\n\nconst mapDispatchToProps = (dispatch, { account }) => ({\n onAuthorize () {\n dispatch(authorizeFollowRequest(account.get('id')));\n },\n\n onReject () {\n dispatch(rejectFollowRequest(account.get('id')));\n },\n});\n\nexport default connect(null, mapDispatchToProps)(FollowRequest);\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';\nimport NotificationFollowRequestContainer from '../containers/follow_request_container';\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 'follow_request':\n return (\n <NotificationFollowRequestContainer\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';\nimport Icon from 'flavours/glitch/components/icon';\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}><Icon id='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-follow-request'>\n <span id='notifications-follow-request' className='column-settings__section'><FormattedMessage id='notifications.column_settings.follow_request' defaultMessage='New follow requests:' /></span>\n\n <div className='column-settings__row'>\n <SettingToggle prefix='notifications_desktop' settings={settings} settingPath={['alerts', 'follow_request']} onChange={onChange} label={alertStr} />\n {showPushSettings && <SettingToggle prefix='notifications_push' settings={pushSettings} settingPath={['alerts', 'follow_request']} onChange={this.onPushChange} label={pushStr} />}\n <SettingToggle prefix='notifications' settings={settings} settingPath={['shows', 'follow_request']} onChange={onChange} label={showStr} />\n <SettingToggle prefix='notifications' settings={settings} settingPath={['sounds', 'follow_request']} 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';\nimport Icon from 'flavours/glitch/components/icon';\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 <Icon id='reply-all' fixedWidth />\n </button>\n <button\n className={selectedFilter === 'favourite' ? 'active' : ''}\n onClick={this.onClick('favourite')}\n title={intl.formatMessage(tooltips.favourites)}\n >\n <Icon id='star' fixedWidth />\n </button>\n <button\n className={selectedFilter === 'reblog' ? 'active' : ''}\n onClick={this.onClick('reblog')}\n title={intl.formatMessage(tooltips.boosts)}\n >\n <Icon id='retweet' fixedWidth />\n </button>\n <button\n className={selectedFilter === 'poll' ? 'active' : ''}\n onClick={this.onClick('poll')}\n title={intl.formatMessage(tooltips.polls)}\n >\n <Icon id='tasks' fixedWidth />\n </button>\n <button\n className={selectedFilter === 'follow' ? 'active' : ''}\n onClick={this.onClick('follow')}\n title={intl.formatMessage(tooltips.follows)}\n >\n <Icon id='user-plus' fixedWidth />\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 loadPending,\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 || state.getIn(['notifications', 'pendingItems']).size > 0,\n hasMore: state.getIn(['notifications', 'hasMore']),\n numPending: state.getIn(['notifications', 'pendingItems'], ImmutableList()).size,\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\nexport default @connect(mapStateToProps, mapDispatchToProps)\n@injectIntl\nclass 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 numPending: PropTypes.number,\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 handleLoadPending = () => {\n this.props.dispatch(loadPending());\n };\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, numPending, 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 numPending={numPending}\n emptyMessage={emptyMessage}\n onLoadMore={this.handleLoadOlder}\n onLoadPending={this.handleLoadPending}\n onScrollToTop={this.handleScrollToTop}\n onScroll={this.handleScroll}\n shouldUpdateScroll={shouldUpdateScroll}\n bindToDocument={!multiColumn}\n >\n {scrollableContent}\n </ScrollableList>\n );\n\n return (\n <Column\n bindToDocument={!multiColumn}\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":""}