Remove React, PureComponent global import, added those imports to files directly
• Remove: - React, PureComponent global import and added those imports to files directly
This commit is contained in:
@@ -1,3 +1,4 @@
|
||||
import React from 'react'
|
||||
import { defineMessages, injectIntl } from 'react-intl'
|
||||
import { closePopover } from '../../actions/popover'
|
||||
import { changeSetting, saveSettings } from '../../actions/settings'
|
||||
@@ -34,7 +35,7 @@ const mapDispatchToProps = (dispatch) => ({
|
||||
export default
|
||||
@injectIntl
|
||||
@connect(mapStateToProps, mapDispatchToProps)
|
||||
class CommentSortingOptionsPopover extends PureComponent {
|
||||
class CommentSortingOptionsPopover extends React.PureComponent {
|
||||
|
||||
static propTypes = {
|
||||
commentSorting: PropTypes.string.isRequired,
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
import React from 'react'
|
||||
import DatePicker from 'react-datepicker'
|
||||
import { FormattedMessage } from 'react-intl'
|
||||
import moment from 'moment-mini'
|
||||
@@ -36,7 +37,7 @@ const mapDispatchToProps = (dispatch) => ({
|
||||
|
||||
export default
|
||||
@connect(mapStateToProps, mapDispatchToProps)
|
||||
class DatePickerPopover extends PureComponent {
|
||||
class DatePickerPopover extends React.PureComponent {
|
||||
|
||||
static propTypes = {
|
||||
date: PropTypes.instanceOf(Date),
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
import React from 'react'
|
||||
import { defineMessages, injectIntl } from 'react-intl'
|
||||
import ImmutablePropTypes from 'react-immutable-proptypes'
|
||||
import ImmutablePureComponent from 'react-immutable-pure-component'
|
||||
|
||||
@@ -1,7 +1,8 @@
|
||||
import React from 'react'
|
||||
import PopoverLayout from './popover_layout'
|
||||
import ColumnIndicator from '../column_indicator'
|
||||
|
||||
export default class ErrorPopover extends PureComponent {
|
||||
export default class ErrorPopover extends React.PureComponent {
|
||||
|
||||
static defaultProps = {
|
||||
isXS: PropTypes.bool,
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
import React from 'react'
|
||||
import { closePopover } from '../../actions/popover'
|
||||
import { sortGroups } from '../../actions/groups'
|
||||
import {
|
||||
@@ -14,7 +15,7 @@ const mapDispatchToProps = (dispatch) => ({
|
||||
|
||||
export default
|
||||
@connect(null, mapDispatchToProps)
|
||||
class GroupListSortOptionsPopover extends PureComponent {
|
||||
class GroupListSortOptionsPopover extends React.PureComponent {
|
||||
|
||||
static defaultProps = {
|
||||
tab: PropTypes.string.isRequired,
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
import React from 'react'
|
||||
import { closePopover } from '../../actions/popover'
|
||||
import {
|
||||
updateRole,
|
||||
@@ -20,7 +21,7 @@ const mapDispatchToProps = (dispatch) => ({
|
||||
|
||||
export default
|
||||
@connect(null, mapDispatchToProps)
|
||||
class GroupMemberOptionsPopover extends PureComponent {
|
||||
class GroupMemberOptionsPopover extends React.PureComponent {
|
||||
|
||||
static defaultProps = {
|
||||
accountId: PropTypes.string.isRequired,
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
import React from 'react'
|
||||
import ImmutablePureComponent from 'react-immutable-pure-component'
|
||||
import ImmutablePropTypes from 'react-immutable-proptypes'
|
||||
import { defineMessages, injectIntl } from 'react-intl'
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
import React from 'react'
|
||||
import { defineMessages, injectIntl } from 'react-intl'
|
||||
import isObject from 'lodash.isobject'
|
||||
import { closePopover } from '../../actions/popover'
|
||||
@@ -37,7 +38,7 @@ const mapDispatchToProps = (dispatch) => ({
|
||||
export default
|
||||
@injectIntl
|
||||
@connect(mapStateToProps, mapDispatchToProps)
|
||||
class GroupTimelineSortOptionsPopover extends PureComponent {
|
||||
class GroupTimelineSortOptionsPopover extends React.PureComponent {
|
||||
|
||||
static propTypes = {
|
||||
sorting: PropTypes.string.isRequired,
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
import React from 'react'
|
||||
import { defineMessages, injectIntl } from 'react-intl'
|
||||
import { closePopover } from '../../actions/popover'
|
||||
import { setGroupTimelineTopSort } from '../../actions/groups'
|
||||
@@ -34,7 +35,7 @@ const mapDispatchToProps = (dispatch) => ({
|
||||
export default
|
||||
@injectIntl
|
||||
@connect(mapStateToProps, mapDispatchToProps)
|
||||
class GroupTimelineSortTopOptionsPopover extends PureComponent {
|
||||
class GroupTimelineSortTopOptionsPopover extends React.PureComponent {
|
||||
|
||||
static propTypes = {
|
||||
sortByTopValue: PropTypes.string.isRequired,
|
||||
|
||||
@@ -1,7 +1,8 @@
|
||||
import React from 'react'
|
||||
import PopoverLayout from './popover_layout'
|
||||
import ColumnIndicator from '../column_indicator'
|
||||
|
||||
export default class LoadingPopover extends PureComponent {
|
||||
export default class LoadingPopover extends React.PureComponent {
|
||||
|
||||
static defaultProps = {
|
||||
isXS: PropTypes.bool,
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
import React from 'react'
|
||||
import { defineMessages, injectIntl } from 'react-intl'
|
||||
import { closePopover } from '../../actions/popover'
|
||||
import { meUsername } from '../../initial_state'
|
||||
@@ -21,7 +22,7 @@ const mapDispatchToProps = (dispatch) => ({
|
||||
export default
|
||||
@injectIntl
|
||||
@connect(null, mapDispatchToProps)
|
||||
class NavSettingsPopover extends PureComponent {
|
||||
class NavSettingsPopover extends React.PureComponent {
|
||||
|
||||
static propTypes = {
|
||||
intl: PropTypes.object.isRequired,
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
import React from 'react'
|
||||
import detectPassiveEvents from 'detect-passive-events'
|
||||
import ImmutablePropTypes from 'react-immutable-proptypes'
|
||||
import ImmutablePureComponent from 'react-immutable-pure-component'
|
||||
|
||||
@@ -1,9 +1,10 @@
|
||||
import React from 'react'
|
||||
import Block from '../block'
|
||||
import Button from '../button'
|
||||
import Heading from '../heading'
|
||||
import Text from '../text'
|
||||
|
||||
export default class PopoverLayout extends PureComponent {
|
||||
export default class PopoverLayout extends React.PureComponent {
|
||||
|
||||
static propTypes = {
|
||||
children: PropTypes.node,
|
||||
|
||||
@@ -38,6 +38,7 @@ import {
|
||||
VideoStatsPopover,
|
||||
} from '../../features/ui/util/async_components'
|
||||
|
||||
import React from 'react'
|
||||
import { closePopover } from '../../actions/popover'
|
||||
import { getWindowDimension } from '../../utils/is_mobile'
|
||||
import Bundle from '../../features/ui/util/bundle'
|
||||
@@ -78,7 +79,7 @@ const mapDispatchToProps = (dispatch) => ({
|
||||
|
||||
export default
|
||||
@connect(mapStateToProps, mapDispatchToProps)
|
||||
class PopoverRoot extends PureComponent {
|
||||
class PopoverRoot extends React.PureComponent {
|
||||
|
||||
static propTypes = {
|
||||
type: PropTypes.string,
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
import React from 'react'
|
||||
import { defineMessages, injectIntl } from 'react-intl'
|
||||
import {
|
||||
followAccount,
|
||||
@@ -134,7 +135,7 @@ const mapDispatchToProps = (dispatch, { intl }) => ({
|
||||
export default
|
||||
@injectIntl
|
||||
@connect(mapStateToProps, mapDispatchToProps)
|
||||
class ProfileOptionsPopover extends PureComponent {
|
||||
class ProfileOptionsPopover extends React.PureComponent {
|
||||
|
||||
static defaultProps = {
|
||||
isXS: PropTypes.bool,
|
||||
|
||||
@@ -1,4 +1,6 @@
|
||||
export default class SearchPopover extends PureComponent {
|
||||
import React from 'react'
|
||||
|
||||
export default class SearchPopover extends React.PureComponent {
|
||||
render() {
|
||||
// : todo :
|
||||
// <div className='search-popout-container' style={{ ...style, position: 'absolute', zIndex: 1000 }}>
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
import React from 'react'
|
||||
import { defineMessages, injectIntl } from 'react-intl'
|
||||
import { MODAL_DISPLAY_OPTIONS } from '../../constants'
|
||||
import { openModal } from '../../actions/modal'
|
||||
@@ -24,7 +25,7 @@ const mapDispatchToProps = (dispatch) => ({
|
||||
export default
|
||||
@injectIntl
|
||||
@connect(null, mapDispatchToProps)
|
||||
class SidebarMorePopover extends PureComponent {
|
||||
class SidebarMorePopover extends React.PureComponent {
|
||||
|
||||
static propTypes = {
|
||||
intl: PropTypes.object.isRequired,
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
import React from 'react'
|
||||
import { defineMessages, injectIntl } from 'react-intl'
|
||||
import { closePopover } from '../../actions/popover'
|
||||
import { changeExpiresAt } from '../../actions/compose'
|
||||
@@ -34,7 +35,7 @@ const mapDispatchToProps = (dispatch) => ({
|
||||
export default
|
||||
@injectIntl
|
||||
@connect(mapStateToProps, mapDispatchToProps)
|
||||
class StatusExpirationOptionsPopover extends PureComponent {
|
||||
class StatusExpirationOptionsPopover extends React.PureComponent {
|
||||
|
||||
static defaultProps = {
|
||||
expiresAtValue: PropTypes.string.isRequired,
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
import React from 'react'
|
||||
import ImmutablePropTypes from 'react-immutable-proptypes'
|
||||
import ImmutablePureComponent from 'react-immutable-pure-component'
|
||||
import { FormattedMessage, defineMessages, injectIntl } from 'react-intl'
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
import React from 'react'
|
||||
import { injectIntl, defineMessages } from 'react-intl'
|
||||
import classNames from 'classnames/bind'
|
||||
import { changeComposeVisibility } from '../../actions/compose'
|
||||
@@ -34,7 +35,7 @@ const mapDispatchToProps = (dispatch) => ({
|
||||
export default
|
||||
@connect(mapStateToProps, mapDispatchToProps)
|
||||
@injectIntl
|
||||
class StatusVisibilityDropdown extends PureComponent {
|
||||
class StatusVisibilityDropdown extends React.PureComponent {
|
||||
|
||||
static propTypes = {
|
||||
intl: PropTypes.object.isRequired,
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
import React from 'react'
|
||||
import ImmutablePropTypes from 'react-immutable-proptypes'
|
||||
import ImmutablePureComponent from 'react-immutable-pure-component'
|
||||
import { NavLink } from 'react-router-dom'
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
import React from 'react'
|
||||
import ImmutablePropTypes from 'react-immutable-proptypes'
|
||||
import ImmutablePureComponent from 'react-immutable-pure-component'
|
||||
import { defineMessages, injectIntl } from 'react-intl'
|
||||
@@ -120,7 +121,7 @@ class VideoStatsPopover extends ImmutablePureComponent {
|
||||
|
||||
}
|
||||
|
||||
class VideoStatLine extends PureComponent {
|
||||
class VideoStatLine extends React.PureComponent {
|
||||
|
||||
static propTypes = {
|
||||
isXS: PropTypes.bool.isRequired,
|
||||
|
||||
Reference in New Issue
Block a user