refactor: update code to use centralized Ant Design imports
- Replaced direct import of '@ant-design/icons' with centralized import from '@/shared/antd-imports'
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
import { QuestionCircleOutlined } from '@ant-design/icons';
|
||||
import { QuestionCircleOutlined } from '@/shared/antd-imports';
|
||||
import { Button, Tooltip } from '@/shared/antd-imports';
|
||||
import React from 'react';
|
||||
import { useTranslation } from 'react-i18next';
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
import { UsergroupAddOutlined } from '@ant-design/icons';
|
||||
import { UsergroupAddOutlined } from '@/shared/antd-imports';
|
||||
import { Button, Tooltip } from '@/shared/antd-imports';
|
||||
import React from 'react';
|
||||
import { useTranslation } from 'react-i18next';
|
||||
|
||||
@@ -5,7 +5,7 @@ import {
|
||||
ProjectOutlined,
|
||||
QuestionCircleOutlined,
|
||||
ReadOutlined,
|
||||
} from '@ant-design/icons';
|
||||
} from '@/shared/antd-imports';
|
||||
import { Button, Card, Dropdown, Flex, MenuProps, Space, Typography } from '@/shared/antd-imports';
|
||||
import React from 'react';
|
||||
import { useTranslation } from 'react-i18next';
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
// Ant Design Icons
|
||||
import { BankOutlined, CaretDownFilled, CheckCircleFilled } from '@ant-design/icons';
|
||||
import { BankOutlined, CaretDownFilled, CheckCircleFilled } from '@/shared/antd-imports';
|
||||
|
||||
// Ant Design Components
|
||||
import { Card, Divider, Dropdown, Flex, Tooltip, Typography } from '@/shared/antd-imports';
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
import { ClockCircleOutlined, StopOutlined } from '@ant-design/icons';
|
||||
import { ClockCircleOutlined, StopOutlined } from '@/shared/antd-imports';
|
||||
import { Badge, Button, Dropdown, List, Tooltip, Typography, Space, Divider, theme } from '@/shared/antd-imports';
|
||||
import React, { useEffect, useState, useCallback } from 'react';
|
||||
import { useTranslation } from 'react-i18next';
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
import { UserOutlined } from '@ant-design/icons';
|
||||
import { UserOutlined } from '@/shared/antd-imports';
|
||||
import { Button, Card, Dropdown, Flex, MenuProps, Tooltip, Typography } from '@/shared/antd-imports';
|
||||
|
||||
import { Link } from 'react-router-dom';
|
||||
|
||||
@@ -7,7 +7,7 @@ import {
|
||||
TagsOutlined,
|
||||
UserAddOutlined,
|
||||
UsergroupAddOutlined,
|
||||
} from '@ant-design/icons';
|
||||
} from '@/shared/antd-imports';
|
||||
import { Button, Flex, Tooltip, Typography } from '@/shared/antd-imports';
|
||||
import { colors } from '../../../styles/colors';
|
||||
|
||||
|
||||
@@ -1,10 +1,9 @@
|
||||
import { SettingOutlined } from '@ant-design/icons';
|
||||
import { SettingOutlined } from '@/shared/antd-imports';
|
||||
import { Button, Tooltip } from '@/shared/antd-imports';
|
||||
import React from 'react';
|
||||
import { useAppDispatch } from '../../../../hooks/useAppDispatch';
|
||||
import { useAppDispatch } from '@/hooks/useAppDispatch';
|
||||
import { toggleDrawer } from './phases.slice';
|
||||
import { useAppSelector } from '../../../../hooks/useAppSelector';
|
||||
import { colors } from '../../../../styles/colors';
|
||||
import { useAppSelector } from '@/hooks/useAppSelector';
|
||||
import { colors } from '@/styles/colors';
|
||||
import { useTranslation } from 'react-i18next';
|
||||
|
||||
const ConfigPhaseButton = () => {
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
import { Button, Drawer, Flex, Input, Skeleton, Spin, Typography } from '@/shared/antd-imports';
|
||||
import { Button, Drawer, Flex, Input, Spin, Typography } from '@/shared/antd-imports';
|
||||
import { useState } from 'react';
|
||||
import { useAppSelector } from '../../../../hooks/useAppSelector';
|
||||
import { useAppDispatch } from '../../../../hooks/useAppDispatch';
|
||||
@@ -11,7 +11,7 @@ import {
|
||||
updateProjectPhaseLabel,
|
||||
} from './phases.slice';
|
||||
import { Divider } from 'antd/lib';
|
||||
import { PlusOutlined } from '@ant-design/icons';
|
||||
import { PlusOutlined } from '@/shared/antd-imports';
|
||||
import { useParams } from 'react-router-dom';
|
||||
import { useTranslation } from 'react-i18next';
|
||||
import PhaseOptionItem from './PhaseOptionItem';
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
import { Button, ColorPicker, ConfigProvider, Flex, Input } from '@/shared/antd-imports';
|
||||
import { CloseCircleOutlined, HolderOutlined } from '@ant-design/icons';
|
||||
import { CloseCircleOutlined, HolderOutlined } from '@/shared/antd-imports';
|
||||
import { nanoid } from '@reduxjs/toolkit';
|
||||
import { useAppDispatch } from '@/hooks/useAppDispatch';
|
||||
import {
|
||||
|
||||
@@ -18,7 +18,7 @@ import {
|
||||
projectColors,
|
||||
statusData,
|
||||
} from '../../../lib/project/project-constants';
|
||||
import { PlusCircleOutlined, PlusOutlined, QuestionCircleOutlined } from '@ant-design/icons';
|
||||
import { PlusCircleOutlined, PlusOutlined, QuestionCircleOutlined } from '@/shared/antd-imports';
|
||||
import { colors } from '../../../styles/colors';
|
||||
import { useAppSelector } from '@/hooks/useAppSelector';
|
||||
import { useAppDispatch } from '@/hooks/useAppDispatch';
|
||||
|
||||
@@ -2,7 +2,7 @@ import { Drawer, Typography, Flex, Button, Space, Dropdown } from '@/shared/antd
|
||||
import { useAppSelector } from '@/hooks/useAppSelector';
|
||||
import { useAppDispatch } from '@/hooks/useAppDispatch';
|
||||
import { toggleMembersReportsDrawer } from '../membersReportsSlice';
|
||||
import { DownOutlined } from '@ant-design/icons';
|
||||
import { DownOutlined } from '@/shared/antd-imports';
|
||||
import MembersReportsDrawerTabs from './members-reports-drawer-tabs';
|
||||
import { useTranslation } from 'react-i18next';
|
||||
import MembersOverviewTasksStatsDrawer from './overviewTab/members-overview-tasks-stats-drawer/members-overview-tasks-stats-drawer';
|
||||
|
||||
@@ -3,7 +3,7 @@ import CustomTableTitle from '@components/CustomTableTitle';
|
||||
import { colors } from '@/styles/colors';
|
||||
import dayjs from 'dayjs';
|
||||
import { useAppDispatch } from '@/hooks/useAppDispatch';
|
||||
import { DoubleRightOutlined } from '@ant-design/icons';
|
||||
import { DoubleRightOutlined } from '@/shared/antd-imports';
|
||||
import { useTranslation } from 'react-i18next';
|
||||
import { setShowTaskDrawer } from '@/features/task-drawer/task-drawer.slice';
|
||||
|
||||
|
||||
@@ -2,7 +2,7 @@ import {
|
||||
ClockCircleOutlined,
|
||||
ExclamationCircleOutlined,
|
||||
FileExcelOutlined,
|
||||
} from '@ant-design/icons';
|
||||
} from '@/shared/antd-imports';
|
||||
import { Button, Card, Flex } from '@/shared/antd-imports';
|
||||
import React, { ReactNode } from 'react';
|
||||
import { useTranslation } from 'react-i18next';
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
import { Badge, Flex, Table, TableColumnsType, Tag, Typography } from '@/shared/antd-imports';
|
||||
import React from 'react';
|
||||
import dayjs from 'dayjs';
|
||||
import { DoubleRightOutlined } from '@ant-design/icons';
|
||||
import { DoubleRightOutlined } from '@/shared/antd-imports';
|
||||
import { useAppDispatch } from '@/hooks/useAppDispatch';
|
||||
import { setSelectedTaskId, setShowTaskDrawer } from '@/features/task-drawer/task-drawer.slice';
|
||||
import CustomTableTitle from '@/components/CustomTableTitle';
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
import { CaretDownFilled } from '@ant-design/icons';
|
||||
import { CaretDownFilled } from '@/shared/antd-imports';
|
||||
import { Button, Card, Checkbox, Dropdown, List, Space } from '@/shared/antd-imports';
|
||||
import React, { useState } from 'react';
|
||||
import { useTranslation } from 'react-i18next';
|
||||
|
||||
@@ -3,7 +3,7 @@ import React, { useState } from 'react';
|
||||
import { useAppSelector } from '../../../../hooks/useAppSelector';
|
||||
import { useAppDispatch } from '../../../../hooks/useAppDispatch';
|
||||
import { setSelectedProject, toggleProjectReportsDrawer } from '../project-reports-slice';
|
||||
import { BankOutlined, DownOutlined } from '@ant-design/icons';
|
||||
import { BankOutlined, DownOutlined } from '@/shared/antd-imports';
|
||||
import ProjectReportsDrawerTabs from './ProjectReportsDrawerTabs';
|
||||
import { colors } from '../../../../styles/colors';
|
||||
import { useTranslation } from 'react-i18next';
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
import { Drawer, Typography, Flex, Button } from '@/shared/antd-imports';
|
||||
import React, { useMemo, useState } from 'react';
|
||||
import { FileOutlined } from '@ant-design/icons';
|
||||
import { FileOutlined } from '@/shared/antd-imports';
|
||||
import { useTranslation } from 'react-i18next';
|
||||
|
||||
import { useAppDispatch } from '@/hooks/useAppDispatch';
|
||||
|
||||
@@ -3,7 +3,7 @@ import React from 'react';
|
||||
import { createPortal } from 'react-dom';
|
||||
import { Badge, Flex, Table, TableColumnsType, Tag, Typography } from '@/shared/antd-imports';
|
||||
import dayjs from 'dayjs';
|
||||
import { DoubleRightOutlined } from '@ant-design/icons';
|
||||
import { DoubleRightOutlined } from '@/shared/antd-imports';
|
||||
|
||||
import { useAppDispatch } from '@/hooks/useAppDispatch';
|
||||
import { setShowTaskDrawer } from '@/features/task-drawer/task-drawer.slice';
|
||||
|
||||
@@ -3,7 +3,7 @@ import {
|
||||
ClockCircleOutlined,
|
||||
ExclamationCircleOutlined,
|
||||
FileExcelOutlined,
|
||||
} from '@ant-design/icons';
|
||||
} from '@/shared/antd-imports';
|
||||
import { Card, Flex, Typography } from '@/shared/antd-imports';
|
||||
import React, { ReactNode } from 'react';
|
||||
import { colors } from '../../../../../styles/colors';
|
||||
|
||||
@@ -9,7 +9,7 @@ import {
|
||||
fetchTask,
|
||||
setSelectedTaskId,
|
||||
} from '@/features/task-drawer/task-drawer.slice';
|
||||
import { DoubleRightOutlined } from '@ant-design/icons';
|
||||
import { DoubleRightOutlined } from '@/shared/antd-imports';
|
||||
import { useTranslation } from 'react-i18next';
|
||||
import { fetchPriorities } from '@/features/taskAttributes/taskPrioritySlice';
|
||||
import { fetchPhasesByProjectId } from '@/features/projects/singleProject/phase/phases.slice';
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
import { IGroupBy } from '@/features/board/board-slice';
|
||||
import { CaretDownFilled } from '@ant-design/icons';
|
||||
import { CaretDownFilled } from '@/shared/antd-imports';
|
||||
import { Flex, Select } from '@/shared/antd-imports';
|
||||
import React from 'react';
|
||||
import { useTranslation } from 'react-i18next';
|
||||
|
||||
@@ -3,7 +3,7 @@ import React, { useState, useEffect } from 'react';
|
||||
import { useAppSelector } from '@/hooks/useAppSelector';
|
||||
import { useAppDispatch } from '@/hooks/useAppDispatch';
|
||||
import { toggleTimeLogDrawer } from './timeLogSlice';
|
||||
import { DownloadOutlined } from '@ant-design/icons';
|
||||
import { DownloadOutlined } from '@/shared/antd-imports';
|
||||
import jsonData from './ProjectTimeLog.json';
|
||||
import { AvatarNamesMap, durations } from '../../../shared/constants';
|
||||
import './ProjectTimeLogDrawer.css';
|
||||
|
||||
Reference in New Issue
Block a user