mirror of
https://github.com/Unleash/unleash.git
synced 2025-06-23 01:16:27 +02:00
linter fixes (#2561)
This commit is contained in:
parent
d20dff60a7
commit
d1c565735a
@ -1,5 +1,5 @@
|
|||||||
import { Alert, Box, Typography } from '@mui/material';
|
import { Alert, Typography } from '@mui/material';
|
||||||
import { useNavigate, Link } from 'react-router-dom';
|
import { Link } from 'react-router-dom';
|
||||||
import { useThemeStyles } from 'themes/themeStyles';
|
import { useThemeStyles } from 'themes/themeStyles';
|
||||||
import { Dialogue } from 'component/common/Dialogue/Dialogue';
|
import { Dialogue } from 'component/common/Dialogue/Dialogue';
|
||||||
import { UserToken } from './UserToken/UserToken';
|
import { UserToken } from './UserToken/UserToken';
|
||||||
|
@ -15,7 +15,7 @@ import { PageContent } from '../../../common/PageContent/PageContent';
|
|||||||
import { PageHeader } from '../../../common/PageHeader/PageHeader';
|
import { PageHeader } from '../../../common/PageHeader/PageHeader';
|
||||||
|
|
||||||
export const InstanceStats: VFC = () => {
|
export const InstanceStats: VFC = () => {
|
||||||
const { stats, loading } = useInstanceStats();
|
const { stats } = useInstanceStats();
|
||||||
|
|
||||||
let versionTitle;
|
let versionTitle;
|
||||||
let version;
|
let version;
|
||||||
|
@ -1,4 +1,3 @@
|
|||||||
import { useEffect } from 'react';
|
|
||||||
import FormTemplate from 'component/common/FormTemplate/FormTemplate';
|
import FormTemplate from 'component/common/FormTemplate/FormTemplate';
|
||||||
import { UpdateButton } from 'component/common/UpdateButton/UpdateButton';
|
import { UpdateButton } from 'component/common/UpdateButton/UpdateButton';
|
||||||
import { ADMIN } from 'component/providers/AccessProvider/permissions';
|
import { ADMIN } from 'component/providers/AccessProvider/permissions';
|
||||||
|
@ -7,7 +7,6 @@ import { Box, Button, TextField, Typography } from '@mui/material';
|
|||||||
import Input from 'component/common/Input/Input';
|
import Input from 'component/common/Input/Input';
|
||||||
import { PermissionAccordion } from './PermissionAccordion/PermissionAccordion';
|
import { PermissionAccordion } from './PermissionAccordion/PermissionAccordion';
|
||||||
import { ConditionallyRender } from 'component/common/ConditionallyRender/ConditionallyRender';
|
import { ConditionallyRender } from 'component/common/ConditionallyRender/ConditionallyRender';
|
||||||
import EnvironmentIcon from 'component/common/EnvironmentIcon/EnvironmentIcon';
|
|
||||||
import {
|
import {
|
||||||
IPermission,
|
IPermission,
|
||||||
IProjectEnvironmentPermissions,
|
IProjectEnvironmentPermissions,
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
import { useEffect, VFC } from 'react';
|
import { VFC } from 'react';
|
||||||
import { useNavigate } from 'react-router-dom';
|
import { useNavigate } from 'react-router-dom';
|
||||||
import { Box, Button, Typography } from '@mui/material';
|
import { Box, Button, Typography } from '@mui/material';
|
||||||
import useLoading from 'hooks/useLoading';
|
import useLoading from 'hooks/useLoading';
|
||||||
|
@ -1,12 +1,5 @@
|
|||||||
import React, { FC, VFC } from 'react';
|
import React, { FC, VFC } from 'react';
|
||||||
import {
|
import { Alert, Box, Popover, styled, Typography } from '@mui/material';
|
||||||
Alert,
|
|
||||||
Box,
|
|
||||||
Popover,
|
|
||||||
styled,
|
|
||||||
Tooltip,
|
|
||||||
Typography,
|
|
||||||
} from '@mui/material';
|
|
||||||
import { ChangeRequestFeatureToggleChange } from '../ChangeRequestOverview/ChangeRequestFeatureToggleChange/ChangeRequestFeatureToggleChange';
|
import { ChangeRequestFeatureToggleChange } from '../ChangeRequestOverview/ChangeRequestFeatureToggleChange/ChangeRequestFeatureToggleChange';
|
||||||
import { objectId } from 'utils/objectId';
|
import { objectId } from 'utils/objectId';
|
||||||
import { ToggleStatusChange } from '../ChangeRequestOverview/ChangeRequestFeatureToggleChange/ToggleStatusChange';
|
import { ToggleStatusChange } from '../ChangeRequestOverview/ChangeRequestFeatureToggleChange/ToggleStatusChange';
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
import { VFC } from 'react';
|
import { VFC } from 'react';
|
||||||
import { styled, Typography } from '@mui/material';
|
import { styled, Typography } from '@mui/material';
|
||||||
import { formatStrategyName } from 'utils/strategyNames';
|
import { formatStrategyName } from 'utils/strategyNames';
|
||||||
import { IFeatureStrategy, IFeatureStrategyPayload } from 'interfaces/strategy';
|
import { IFeatureStrategyPayload } from 'interfaces/strategy';
|
||||||
|
|
||||||
interface ICopyStrategiesMessageProps {
|
interface ICopyStrategiesMessageProps {
|
||||||
payload?: IFeatureStrategyPayload[];
|
payload?: IFeatureStrategyPayload[];
|
||||||
|
@ -1,7 +1,6 @@
|
|||||||
import { FC } from 'react';
|
import { FC } from 'react';
|
||||||
import { Link } from 'react-router-dom';
|
import { Link } from 'react-router-dom';
|
||||||
import { Alert, Box, Card, Typography } from '@mui/material';
|
import { Alert, Box, Card, Typography } from '@mui/material';
|
||||||
import ToggleOnIcon from '@mui/icons-material/ToggleOn';
|
|
||||||
import { ConditionallyRender } from 'component/common/ConditionallyRender/ConditionallyRender';
|
import { ConditionallyRender } from 'component/common/ConditionallyRender/ConditionallyRender';
|
||||||
|
|
||||||
interface IChangeRequestToggleChange {
|
interface IChangeRequestToggleChange {
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
import { Alert, Button, styled, TextField, Typography } from '@mui/material';
|
import { Alert, Button, styled } from '@mui/material';
|
||||||
import { FC, useContext, useState } from 'react';
|
import { FC, useContext, useState } from 'react';
|
||||||
import { Box } from '@mui/material';
|
import { Box } from '@mui/material';
|
||||||
import { useChangeRequest } from 'hooks/api/getters/useChangeRequest/useChangeRequest';
|
import { useChangeRequest } from 'hooks/api/getters/useChangeRequest/useChangeRequest';
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
import { Box, Paper, styled, Typography } from '@mui/material';
|
import { Box, styled, Typography } from '@mui/material';
|
||||||
import React, { FC } from 'react';
|
import React, { FC } from 'react';
|
||||||
import { StyledAvatar } from '../ChangeRequestHeader/ChangeRequestHeader.styles';
|
import { StyledAvatar } from '../ChangeRequestHeader/ChangeRequestHeader.styles';
|
||||||
import { CheckCircle } from '@mui/icons-material';
|
import { CheckCircle } from '@mui/icons-material';
|
||||||
|
@ -12,7 +12,6 @@ import {
|
|||||||
MenuItem,
|
MenuItem,
|
||||||
MenuList,
|
MenuList,
|
||||||
ClickAwayListener,
|
ClickAwayListener,
|
||||||
Alert,
|
|
||||||
} from '@mui/material';
|
} from '@mui/material';
|
||||||
|
|
||||||
import ArrowDropDownIcon from '@mui/icons-material/ArrowDropDown';
|
import ArrowDropDownIcon from '@mui/icons-material/ArrowDropDown';
|
||||||
|
@ -1,7 +1,6 @@
|
|||||||
import { FC, useState, VFC } from 'react';
|
import { FC, useState, VFC } from 'react';
|
||||||
import { Box, Button, styled, Typography } from '@mui/material';
|
import { Box, Button, styled, Typography } from '@mui/material';
|
||||||
import { useStyles as useAppStyles } from 'component/App.styles';
|
import { useStyles as useAppStyles } from 'component/App.styles';
|
||||||
import WarningAmberIcon from '@mui/icons-material/WarningAmber';
|
|
||||||
import { ConditionallyRender } from 'component/common/ConditionallyRender/ConditionallyRender';
|
import { ConditionallyRender } from 'component/common/ConditionallyRender/ConditionallyRender';
|
||||||
import { ChangeRequestSidebar } from '../ChangeRequestSidebar/ChangeRequestSidebar';
|
import { ChangeRequestSidebar } from '../ChangeRequestSidebar/ChangeRequestSidebar';
|
||||||
import { usePendingChangeRequests } from 'hooks/api/getters/usePendingChangeRequests/usePendingChangeRequests';
|
import { usePendingChangeRequests } from 'hooks/api/getters/usePendingChangeRequests/usePendingChangeRequests';
|
||||||
|
@ -7,9 +7,7 @@ describe('PrettifyLargeNumber', () => {
|
|||||||
it('should render number with separator for value less than threshold', async () => {
|
it('should render number with separator for value less than threshold', async () => {
|
||||||
render(<PrettifyLargeNumber value={999999} threshold={1000000} />);
|
render(<PrettifyLargeNumber value={999999} threshold={1000000} />);
|
||||||
|
|
||||||
const prettifiedText = await screen.getByTestId(
|
const prettifiedText = screen.getByTestId(LARGE_NUMBER_PRETTIFIED);
|
||||||
LARGE_NUMBER_PRETTIFIED
|
|
||||||
);
|
|
||||||
|
|
||||||
expect(prettifiedText.textContent).toHaveLength('999,999'.length);
|
expect(prettifiedText.textContent).toHaveLength('999,999'.length);
|
||||||
});
|
});
|
||||||
@ -17,9 +15,7 @@ describe('PrettifyLargeNumber', () => {
|
|||||||
it('should render prettified number for value equal to the threshold', async () => {
|
it('should render prettified number for value equal to the threshold', async () => {
|
||||||
render(<PrettifyLargeNumber value={1000000} threshold={1000000} />);
|
render(<PrettifyLargeNumber value={1000000} threshold={1000000} />);
|
||||||
|
|
||||||
const prettifiedText = await screen.getByTestId(
|
const prettifiedText = screen.getByTestId(LARGE_NUMBER_PRETTIFIED);
|
||||||
LARGE_NUMBER_PRETTIFIED
|
|
||||||
);
|
|
||||||
|
|
||||||
expect(prettifiedText.textContent).toBe('1M');
|
expect(prettifiedText.textContent).toBe('1M');
|
||||||
});
|
});
|
||||||
@ -27,9 +23,7 @@ describe('PrettifyLargeNumber', () => {
|
|||||||
it('should render prettified number for value greater than threshold', async () => {
|
it('should render prettified number for value greater than threshold', async () => {
|
||||||
render(<PrettifyLargeNumber value={12345678} threshold={1000000} />);
|
render(<PrettifyLargeNumber value={12345678} threshold={1000000} />);
|
||||||
|
|
||||||
const prettifiedText = await screen.getByTestId(
|
const prettifiedText = screen.getByTestId(LARGE_NUMBER_PRETTIFIED);
|
||||||
LARGE_NUMBER_PRETTIFIED
|
|
||||||
);
|
|
||||||
|
|
||||||
expect(prettifiedText.textContent).toBe('12.35M');
|
expect(prettifiedText.textContent).toBe('12.35M');
|
||||||
});
|
});
|
||||||
@ -37,9 +31,7 @@ describe('PrettifyLargeNumber', () => {
|
|||||||
it('should render prettified number with tooltip having raw value for value greater than threshold', async () => {
|
it('should render prettified number with tooltip having raw value for value greater than threshold', async () => {
|
||||||
render(<PrettifyLargeNumber value={12345678} threshold={1000000} />);
|
render(<PrettifyLargeNumber value={12345678} threshold={1000000} />);
|
||||||
|
|
||||||
const prettifiedText = await screen.getByTestId(
|
const prettifiedText = screen.getByTestId(LARGE_NUMBER_PRETTIFIED);
|
||||||
LARGE_NUMBER_PRETTIFIED
|
|
||||||
);
|
|
||||||
|
|
||||||
expect(prettifiedText.getAttribute('aria-label')).toHaveLength(
|
expect(prettifiedText.getAttribute('aria-label')).toHaveLength(
|
||||||
'12,345,678'.length
|
'12,345,678'.length
|
||||||
@ -55,9 +47,7 @@ describe('PrettifyLargeNumber', () => {
|
|||||||
/>
|
/>
|
||||||
);
|
);
|
||||||
|
|
||||||
const prettifiedText = await screen.getByTestId(
|
const prettifiedText = screen.getByTestId(LARGE_NUMBER_PRETTIFIED);
|
||||||
LARGE_NUMBER_PRETTIFIED
|
|
||||||
);
|
|
||||||
|
|
||||||
expect(prettifiedText.textContent).toBe('12.3457M');
|
expect(prettifiedText.textContent).toBe('12.3457M');
|
||||||
});
|
});
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
import { ReactNode, FC } from 'react';
|
import { FC } from 'react';
|
||||||
import { Modal, Backdrop, styled } from '@mui/material';
|
import { Modal, Backdrop, styled } from '@mui/material';
|
||||||
import Fade from '@mui/material/Fade';
|
import Fade from '@mui/material/Fade';
|
||||||
import { SIDEBAR_MODAL_ID } from 'utils/testIds';
|
import { SIDEBAR_MODAL_ID } from 'utils/testIds';
|
||||||
|
@ -18,7 +18,6 @@ import {
|
|||||||
} from '../FeatureStrategyEdit/FeatureStrategyEdit';
|
} from '../FeatureStrategyEdit/FeatureStrategyEdit';
|
||||||
import { CREATE_FEATURE_STRATEGY } from 'component/providers/AccessProvider/permissions';
|
import { CREATE_FEATURE_STRATEGY } from 'component/providers/AccessProvider/permissions';
|
||||||
import { ISegment } from 'interfaces/segment';
|
import { ISegment } from 'interfaces/segment';
|
||||||
import { useSegmentsApi } from 'hooks/api/actions/useSegmentsApi/useSegmentsApi';
|
|
||||||
import { formatStrategyName } from 'utils/strategyNames';
|
import { formatStrategyName } from 'utils/strategyNames';
|
||||||
import { useFormErrors } from 'hooks/useFormErrors';
|
import { useFormErrors } from 'hooks/useFormErrors';
|
||||||
import { createFeatureStrategy } from 'utils/createFeatureStrategy';
|
import { createFeatureStrategy } from 'utils/createFeatureStrategy';
|
||||||
@ -43,7 +42,6 @@ export const FeatureStrategyCreate = () => {
|
|||||||
|
|
||||||
const { addStrategyToFeature, loading } = useFeatureStrategyApi();
|
const { addStrategyToFeature, loading } = useFeatureStrategyApi();
|
||||||
const { addChangeRequest } = useChangeRequestApi();
|
const { addChangeRequest } = useChangeRequestApi();
|
||||||
const { setStrategySegments } = useSegmentsApi();
|
|
||||||
const { setToastData, setToastApiError } = useToast();
|
const { setToastData, setToastApiError } = useToast();
|
||||||
const { uiConfig } = useUiConfig();
|
const { uiConfig } = useUiConfig();
|
||||||
const { unleashUrl } = uiConfig;
|
const { unleashUrl } = uiConfig;
|
||||||
@ -85,7 +83,7 @@ export const FeatureStrategyCreate = () => {
|
|||||||
}, [featureId, strategyDefinition]);
|
}, [featureId, strategyDefinition]);
|
||||||
|
|
||||||
const onAddStrategy = async (payload: IFeatureStrategyPayload) => {
|
const onAddStrategy = async (payload: IFeatureStrategyPayload) => {
|
||||||
const created = await addStrategyToFeature(
|
await addStrategyToFeature(
|
||||||
projectId,
|
projectId,
|
||||||
featureId,
|
featureId,
|
||||||
environmentId,
|
environmentId,
|
||||||
|
@ -15,7 +15,6 @@ import {
|
|||||||
} from 'interfaces/strategy';
|
} from 'interfaces/strategy';
|
||||||
import { UPDATE_FEATURE_STRATEGY } from 'component/providers/AccessProvider/permissions';
|
import { UPDATE_FEATURE_STRATEGY } from 'component/providers/AccessProvider/permissions';
|
||||||
import { ISegment } from 'interfaces/segment';
|
import { ISegment } from 'interfaces/segment';
|
||||||
import { useSegmentsApi } from 'hooks/api/actions/useSegmentsApi/useSegmentsApi';
|
|
||||||
import { useSegments } from 'hooks/api/getters/useSegments/useSegments';
|
import { useSegments } from 'hooks/api/getters/useSegments/useSegments';
|
||||||
import { formatStrategyName } from 'utils/strategyNames';
|
import { formatStrategyName } from 'utils/strategyNames';
|
||||||
import { useFormErrors } from 'hooks/useFormErrors';
|
import { useFormErrors } from 'hooks/useFormErrors';
|
||||||
@ -38,7 +37,6 @@ export const FeatureStrategyEdit = () => {
|
|||||||
const [strategy, setStrategy] = useState<Partial<IFeatureStrategy>>({});
|
const [strategy, setStrategy] = useState<Partial<IFeatureStrategy>>({});
|
||||||
const [segments, setSegments] = useState<ISegment[]>([]);
|
const [segments, setSegments] = useState<ISegment[]>([]);
|
||||||
const { updateStrategyOnFeature, loading } = useFeatureStrategyApi();
|
const { updateStrategyOnFeature, loading } = useFeatureStrategyApi();
|
||||||
const { setStrategySegments } = useSegmentsApi();
|
|
||||||
const { strategyDefinition } = useStrategy(strategy.name);
|
const { strategyDefinition } = useStrategy(strategy.name);
|
||||||
const { setToastData, setToastApiError } = useToast();
|
const { setToastData, setToastApiError } = useToast();
|
||||||
const errors = useFormErrors();
|
const errors = useFormErrors();
|
||||||
|
@ -8,7 +8,7 @@ import {
|
|||||||
Tooltip,
|
Tooltip,
|
||||||
} from '@mui/material';
|
} from '@mui/material';
|
||||||
import { AddToPhotos as CopyIcon, Lock } from '@mui/icons-material';
|
import { AddToPhotos as CopyIcon, Lock } from '@mui/icons-material';
|
||||||
import { IFeatureStrategy, IFeatureStrategyPayload } from 'interfaces/strategy';
|
import { IFeatureStrategyPayload } from 'interfaces/strategy';
|
||||||
import { useRequiredPathParam } from 'hooks/useRequiredPathParam';
|
import { useRequiredPathParam } from 'hooks/useRequiredPathParam';
|
||||||
import { IFeatureEnvironment } from 'interfaces/featureToggle';
|
import { IFeatureEnvironment } from 'interfaces/featureToggle';
|
||||||
import AccessContext from 'contexts/AccessContext';
|
import AccessContext from 'contexts/AccessContext';
|
||||||
|
@ -21,6 +21,7 @@ export const useStrategyChangeFromRequest = (
|
|||||||
) {
|
) {
|
||||||
return change.payload.id === strategyId;
|
return change.payload.id === strategyId;
|
||||||
}
|
}
|
||||||
|
return false;
|
||||||
});
|
});
|
||||||
|
|
||||||
return change;
|
return change;
|
||||||
|
@ -32,7 +32,6 @@ import { useRequiredPathParam } from 'hooks/useRequiredPathParam';
|
|||||||
import { FeatureArchiveDialog } from '../../common/FeatureArchiveDialog/FeatureArchiveDialog';
|
import { FeatureArchiveDialog } from '../../common/FeatureArchiveDialog/FeatureArchiveDialog';
|
||||||
import { DraftBanner } from 'component/changeRequest/DraftBanner/DraftBanner';
|
import { DraftBanner } from 'component/changeRequest/DraftBanner/DraftBanner';
|
||||||
import { MainLayout } from 'component/layout/MainLayout/MainLayout';
|
import { MainLayout } from 'component/layout/MainLayout/MainLayout';
|
||||||
import useUiConfig from 'hooks/api/getters/useUiConfig/useUiConfig';
|
|
||||||
import { useChangeRequestsEnabled } from 'hooks/useChangeRequestsEnabled';
|
import { useChangeRequestsEnabled } from 'hooks/useChangeRequestsEnabled';
|
||||||
|
|
||||||
export const FeatureView = () => {
|
export const FeatureView = () => {
|
||||||
|
@ -1,8 +1,7 @@
|
|||||||
import { VFC } from 'react';
|
import { VFC } from 'react';
|
||||||
import { useNavigate } from 'react-router-dom';
|
import { useNavigate } from 'react-router-dom';
|
||||||
import { Box, Typography } from '@mui/material';
|
import { Box } from '@mui/material';
|
||||||
import { Dialogue } from 'component/common/Dialogue/Dialogue';
|
import { Dialogue } from 'component/common/Dialogue/Dialogue';
|
||||||
import { GO_BACK } from 'constants/navigate';
|
|
||||||
import { ConditionallyRender } from 'component/common/ConditionallyRender/ConditionallyRender';
|
import { ConditionallyRender } from 'component/common/ConditionallyRender/ConditionallyRender';
|
||||||
|
|
||||||
interface IErrorProps {
|
interface IErrorProps {
|
||||||
|
@ -1,7 +1,6 @@
|
|||||||
import { useNavigate } from 'react-router';
|
import { useNavigate } from 'react-router';
|
||||||
import useProject from 'hooks/api/getters/useProject/useProject';
|
import useProject from 'hooks/api/getters/useProject/useProject';
|
||||||
import useLoading from 'hooks/useLoading';
|
import useLoading from 'hooks/useLoading';
|
||||||
import ApiError from 'component/common/ApiError/ApiError';
|
|
||||||
import { ConditionallyRender } from 'component/common/ConditionallyRender/ConditionallyRender';
|
import { ConditionallyRender } from 'component/common/ConditionallyRender/ConditionallyRender';
|
||||||
import { useStyles } from './Project.styles';
|
import { useStyles } from './Project.styles';
|
||||||
import { styled, Tab, Tabs } from '@mui/material';
|
import { styled, Tab, Tabs } from '@mui/material';
|
||||||
@ -53,7 +52,7 @@ const StyledText = styled(StyledTitle)(({ theme }) => ({
|
|||||||
const Project = () => {
|
const Project = () => {
|
||||||
const projectId = useRequiredPathParam('projectId');
|
const projectId = useRequiredPathParam('projectId');
|
||||||
const params = useQueryParams();
|
const params = useQueryParams();
|
||||||
const { project, error, loading, refetch } = useProject(projectId);
|
const { project, loading } = useProject(projectId);
|
||||||
const ref = useLoading(loading);
|
const ref = useLoading(loading);
|
||||||
const { setToastData } = useToast();
|
const { setToastData } = useToast();
|
||||||
const { classes: styles } = useStyles();
|
const { classes: styles } = useStyles();
|
||||||
@ -117,7 +116,7 @@ const Project = () => {
|
|||||||
const changeRequestTab = {
|
const changeRequestTab = {
|
||||||
title: 'Change requests',
|
title: 'Change requests',
|
||||||
path: `${basePath}/change-requests`,
|
path: `${basePath}/change-requests`,
|
||||||
name: 'change-request' + '',
|
name: 'change-request',
|
||||||
};
|
};
|
||||||
|
|
||||||
if (isChangeRequestFlagEnabled) {
|
if (isChangeRequestFlagEnabled) {
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
import { useCallback, useEffect, useMemo, useState, VFC } from 'react';
|
import { useEffect, useMemo, useState, VFC } from 'react';
|
||||||
import { SortingRule, useFlexLayout, useSortBy, useTable } from 'react-table';
|
import { SortingRule, useFlexLayout, useSortBy, useTable } from 'react-table';
|
||||||
import { VirtualizedTable, TablePlaceholder } from 'component/common/Table';
|
import { VirtualizedTable, TablePlaceholder } from 'component/common/Table';
|
||||||
import { styled, useMediaQuery, useTheme } from '@mui/material';
|
import { styled, useMediaQuery, useTheme } from '@mui/material';
|
||||||
|
@ -1,14 +1,6 @@
|
|||||||
import { Button } from '@mui/material';
|
import { Button } from '@mui/material';
|
||||||
import classnames from 'classnames';
|
import classnames from 'classnames';
|
||||||
import React, {
|
import React, { SyntheticEvent, useCallback, useEffect, useState } from 'react';
|
||||||
Dispatch,
|
|
||||||
SetStateAction,
|
|
||||||
SyntheticEvent,
|
|
||||||
useCallback,
|
|
||||||
useEffect,
|
|
||||||
useState,
|
|
||||||
} from 'react';
|
|
||||||
import { useNavigate } from 'react-router';
|
|
||||||
import { useThemeStyles } from 'themes/themeStyles';
|
import { useThemeStyles } from 'themes/themeStyles';
|
||||||
import { ConditionallyRender } from 'component/common/ConditionallyRender/ConditionallyRender';
|
import { ConditionallyRender } from 'component/common/ConditionallyRender/ConditionallyRender';
|
||||||
import PasswordChecker from './PasswordChecker/PasswordChecker';
|
import PasswordChecker from './PasswordChecker/PasswordChecker';
|
||||||
|
@ -2,7 +2,6 @@ import { useState, useEffect } from 'react';
|
|||||||
import { SWRConfiguration } from 'swr';
|
import { SWRConfiguration } from 'swr';
|
||||||
import { dequal } from 'dequal';
|
import { dequal } from 'dequal';
|
||||||
import { StaleDataNotification } from 'component/common/StaleDataNotification/StaleDataNotification';
|
import { StaleDataNotification } from 'component/common/StaleDataNotification/StaleDataNotification';
|
||||||
import { IFeatureToggle } from 'interfaces/featureToggle';
|
|
||||||
|
|
||||||
interface IFormatUnleashGetterOutput<Type> {
|
interface IFormatUnleashGetterOutput<Type> {
|
||||||
data: Type;
|
data: Type;
|
||||||
|
@ -1,5 +1,3 @@
|
|||||||
import { formatRelative } from 'date-fns';
|
|
||||||
|
|
||||||
export const formatDateYMDHMS = (
|
export const formatDateYMDHMS = (
|
||||||
date: number | string | Date,
|
date: number | string | Date,
|
||||||
locale: string
|
locale: string
|
||||||
|
Loading…
Reference in New Issue
Block a user