* Enable import order

* Add new order groups and add consistent-type-imports

* Remove types group, move react to top and fix issues

* Add store and reducers to the redux group and move imports from types folder to the end

* Fix tsc

* Remove react rule

* Fix test

* Fix eslint disable
Этот коммит содержится в:
Daniel Espino García
2023-09-06 12:51:55 +02:00
коммит произвёл GitHub
родитель b2f36c7cdf
Коммит d13429aa92
2342 изменённых файлов: 12353 добавлений и 11153 удалений

Просмотреть файл

@@ -1,21 +1,17 @@
// Copyright (c) 2015-present Mattermost, Inc. All Rights Reserved.
// See LICENSE.txt for license information.
import type {ReactWrapper} from 'enzyme';
import {shallow} from 'enzyme';
import React from 'react';
import {ReactWrapper, shallow} from 'enzyme';
import {act} from 'react-dom/test-utils';
import {Provider} from 'react-redux';
import {act} from 'react-dom/test-utils';
import * as cloudActions from 'actions/cloud';
import {trackEvent} from 'actions/telemetry_actions.jsx';
import {mountWithIntl} from 'tests/helpers/intl-test-helper';
import mockStore from 'tests/test_store';
import {trackEvent} from 'actions/telemetry_actions.jsx';
import {TELEMETRY_CATEGORIES} from 'utils/constants';
import CloudStartTrialButton from './cloud_start_trial_btn';

Просмотреть файл

@@ -1,24 +1,25 @@
// Copyright (c) 2015-present Mattermost, Inc. All Rights Reserved.
// See LICENSE.txt for license information.
import React, {useEffect, useState, ReactNode} from 'react';
import React, {useEffect, useState} from 'react';
import type {ReactNode} from 'react';
import {useIntl} from 'react-intl';
import {useDispatch} from 'react-redux';
import {DispatchFunc} from 'mattermost-redux/types/actions';
import useGetSubscription from 'components/common/hooks/useGetSubscription';
import type {DispatchFunc} from 'mattermost-redux/types/actions';
import {requestCloudTrial, validateWorkspaceBusinessEmail, getCloudLimits} from 'actions/cloud';
import {trackEvent} from 'actions/telemetry_actions';
import {openModal, closeModal} from 'actions/views/modals';
import TrialBenefitsModal from 'components/trial_benefits_modal/trial_benefits_modal';
import useGetSubscription from 'components/common/hooks/useGetSubscription';
import ExternalLink from 'components/external_link';
import TrialBenefitsModal from 'components/trial_benefits_modal/trial_benefits_modal';
import {ModalIdentifiers, TELEMETRY_CATEGORIES, LicenseLinks} from 'utils/constants';
import RequestBusinessEmailModal from './request_business_email_modal';
import './cloud_start_trial_btn.scss';
export type CloudStartTrialBtnProps = {

Просмотреть файл

@@ -1,8 +1,8 @@
// Copyright (c) 2015-present Mattermost, Inc. All Rights Reserved.
// See LICENSE.txt for license information.
import React from 'react';
import {mount, shallow} from 'enzyme';
import React from 'react';
import {ItemStatus} from 'utils/constants';

Просмотреть файл

@@ -4,7 +4,8 @@
import React from 'react';
import {useIntl} from 'react-intl';
import Input, {CustomMessageInputType} from 'components/widgets/inputs/input/input';
import Input from 'components/widgets/inputs/input/input';
import type {CustomMessageInputType} from 'components/widgets/inputs/input/input';
interface InputBusinessEmailProps {
email: string;
handleEmailValues: (e: React.ChangeEvent<HTMLInputElement>) => void;

Просмотреть файл

@@ -1,17 +1,15 @@
// Copyright (c) 2015-present Mattermost, Inc. All Rights Reserved.
// See LICENSE.txt for license information.
import React from 'react';
import {Provider} from 'react-redux';
import {act} from 'react-dom/test-utils';
import {shallow} from 'enzyme';
import * as cloudActions from 'actions/cloud';
import React from 'react';
import {act} from 'react-dom/test-utils';
import {Provider} from 'react-redux';
import {GenericModal} from '@mattermost/components';
import * as cloudActions from 'actions/cloud';
import {mountWithIntl} from 'tests/helpers/intl-test-helper';
import mockStore from 'tests/test_store';

Просмотреть файл

@@ -1,27 +1,25 @@
// Copyright (c) 2015-present Mattermost, Inc. All Rights Reserved.
// See LICENSE.txt for license information.
import {debounce} from 'lodash';
import React, {useCallback, useEffect, useState} from 'react';
import {FormattedMessage, useIntl} from 'react-intl';
import {useDispatch} from 'react-redux';
import {FormattedMessage, useIntl} from 'react-intl';
import {GenericModal} from '@mattermost/components';
import {debounce} from 'lodash';
import {DispatchFunc} from 'mattermost-redux/types/actions';
import type {DispatchFunc} from 'mattermost-redux/types/actions';
import {isEmail} from 'mattermost-redux/utils/helpers';
import {validateBusinessEmail} from 'actions/cloud';
import {trackEvent} from 'actions/telemetry_actions';
import {closeModal} from 'actions/views/modals';
import {validateBusinessEmail} from 'actions/cloud';
import ExternalLink from 'components/external_link';
import type {CustomMessageInputType} from 'components/widgets/inputs/input/input';
import {ItemStatus, TELEMETRY_CATEGORIES, ModalIdentifiers, LicenseLinks, AboutLinks} from 'utils/constants';
import {GenericModal} from '@mattermost/components';
import {CustomMessageInputType} from 'components/widgets/inputs/input/input';
import ExternalLink from 'components/external_link';
import {isEmail} from 'mattermost-redux/utils/helpers';
import StartCloudTrialBtn from './cloud_start_trial_btn';
import InputBusinessEmail from './input_business_email';