Fixed key prop error

This commit is contained in:
Daniel Cojocea committed 2024-08-19 15:04:04 -04:00
1 parent 1c31b13438
commit b27712a629
1 file changed
+2 -2
+2 -2
View File
@@ -185,6 +185,7 @@ function Sidebar() {
{menu.map((item) => {menu.map((item) =>
item.path ? ( item.path ? (
<Tooltip <Tooltip
key={item.path}
placement="right" placement="right"
title={collapsed ? item.name : ""} title={collapsed ? item.name : ""}
slotProps={{ slotProps={{
@@ -204,7 +205,6 @@ function Sidebar() {
className={ className={
location.pathname.includes(item.path) ? "selected-path" : "" location.pathname.includes(item.path) ? "selected-path" : ""
} }
key={item.path}
onClick={() => navigate(`/${item.path}`)} onClick={() => navigate(`/${item.path}`)}
sx={{ sx={{
gap: theme.gap.medium, gap: theme.gap.medium,
@@ -381,6 +381,7 @@ function Sidebar() {
> >
{other.map((item) => ( {other.map((item) => (
<Tooltip <Tooltip
key={item.path}
placement="right" placement="right"
title={collapsed ? item.name : ""} title={collapsed ? item.name : ""}
slotProps={{ slotProps={{
@@ -400,7 +401,6 @@ function Sidebar() {
className={ className={
location.pathname.includes(item.path) ? "selected-path" : "" location.pathname.includes(item.path) ? "selected-path" : ""
} }
key={item.path}
onClick={() => onClick={() =>
item.path === "support" item.path === "support"
? window.open( ? window.open(