feat: migrate icons from custom SVGs and MUI to Lucide React

Replace custom SVG icons and @mui/icons-material with lucide-react for consistent,
lightweight icon management across the application.

## Changes
- Add lucide-react package and remove @mui/icons-material
- Create theme-aware Icon wrapper component with color resolution
- Create iconMap.js for legacy icon name mappings
- Migrate 64 components to use new Icon component
- Remove 74 unused SVG files from assets/icons/

## Benefits
- Consistent icon API across the application
- Smaller bundle size with tree-shakeable imports
- Theme-aware color support via MUI theme paths
- Simpler maintenance with single icon library
This commit is contained in:
gorkem-bwl committed 2026-01-15 23:37:50 -05:00
1 parent b5caabed20
commit ba0c89fc6c
140 files changed
+421 -746

No files matched your search

@@ -3,7 +3,7 @@ import PropTypes from "prop-types";
import FilterHeader from "@/Components/v1/FilterHeader/index.jsx";
import { useMemo } from "react";
import { Box, Button } from "@mui/material";
import ClearIcon from "@mui/icons-material/Clear";
import Icon from "@/Components/v1/Icon";
import { useTranslation } from "react-i18next";
/**
@@ -131,7 +131,7 @@ const Filter = ({
color={theme.palette.primary.contrastText}
onClick={handleReset}
variant="contained"
endIcon={<ClearIcon />}
endIcon={<Icon name="X" size={18} />}
sx={{
visibility: isFilterActive ? "visible" : "hidden",
}}
@@ -1,9 +1,8 @@
import PropTypes from "prop-types";
import { useTheme } from "@emotion/react";
import { Box, Stack, Typography } from "@mui/material";
import Arrow from "@/assets/icons/top-right-arrow.svg?react";
import Icon from "@/Components/v1/Icon";
import Background from "@/assets/Images/background-grid.svg?react";
import ClockSnooze from "@/assets/icons/clock-snooze.svg?react";
const StatusBox = ({ title, value, status }) => {
const theme = useTheme();
@@ -20,21 +19,21 @@ const StatusBox = ({ title, value, status }) => {
color = theme.palette.success.lowContrast;
icon = (
<Box sx={{ ...sharedStyles, top: theme.spacing(4) }}>
<Arrow />
<Icon name="ArrowUpRight" size={20} />
</Box>
);
} else if (status === "down") {
color = theme.palette.error.lowContrast;
icon = (
<Box sx={{ ...sharedStyles, transform: "rotate(180deg)", top: theme.spacing(2) }}>
<Arrow />
<Icon name="ArrowUpRight" size={20} />
</Box>
);
} else if (status === "paused") {
color = theme.palette.warning.lowContrast;
icon = (
<Box sx={{ ...sharedStyles, top: theme.spacing(6), right: theme.spacing(6) }}>
<ClockSnooze />
<Icon name="Clock" size={20} />
</Box>
);
}
@@ -1,8 +1,7 @@
// Components
import { Box, Stack } from "@mui/material";
import DataTable from "@/Components/v1/Table/index.jsx";
import ArrowDownwardRoundedIcon from "@mui/icons-material/ArrowDownwardRounded";
import ArrowUpwardRoundedIcon from "@mui/icons-material/ArrowUpwardRounded";
import Icon from "@/Components/v1/Icon";
import Host from "@/Components/v1/Host/index.jsx";
import { StatusLabel } from "@/Components/v1/Label/index.jsx";
import BarChart from "@/Components/v1/Charts/BarChart/index.jsx";
@@ -92,9 +91,9 @@ const UptimeDataTable = ({
}}
>
{sort?.order === "asc" ? (
<ArrowUpwardRoundedIcon />
<Icon name="ArrowUp" size={18} />
) : (
<ArrowDownwardRoundedIcon />
<Icon name="ArrowDown" size={18} />
)}
</Stack>
</Stack>
@@ -128,9 +127,9 @@ const UptimeDataTable = ({
}}
>
{sort?.order === "asc" ? (
<ArrowUpwardRoundedIcon fontSize="18px" />
<Icon name="ArrowUp" size={18} />
) : (
<ArrowDownwardRoundedIcon fontSize="18px" />
<Icon name="ArrowDown" size={18} />
)}
</Stack>
</Stack>