fix bold icon link
This commit is contained in:
@@ -4,13 +4,13 @@ import {
|
|||||||
Element,
|
Element,
|
||||||
Gallery,
|
Gallery,
|
||||||
Grid8,
|
Grid8,
|
||||||
Link,
|
|
||||||
MouseSquare,
|
MouseSquare,
|
||||||
Shapes,
|
Shapes,
|
||||||
Sticker,
|
Sticker,
|
||||||
Text,
|
Text,
|
||||||
VideoSquare,
|
VideoSquare,
|
||||||
Minus,
|
Minus,
|
||||||
|
Link2,
|
||||||
} from "iconsax-react";
|
} from "iconsax-react";
|
||||||
import type { ToolType } from "../../store/editorStore";
|
import type { ToolType } from "../../store/editorStore";
|
||||||
|
|
||||||
@@ -20,7 +20,7 @@ const tools: Array<{ icon: (color: string, variant?: "Bold" | "Outline" | "Broke
|
|||||||
{ icon: (color, variant) => <Text size={20} color={color} variant={variant} />, tool: "text", label: "متن" },
|
{ icon: (color, variant) => <Text size={20} color={color} variant={variant} />, tool: "text", label: "متن" },
|
||||||
{ icon: (color, variant) => <Grid8 size={20} color={color} variant={variant} />, tool: "grid", label: "گرید" },
|
{ icon: (color, variant) => <Grid8 size={20} color={color} variant={variant} />, tool: "grid", label: "گرید" },
|
||||||
{ icon: (color, variant) => <Gallery size={20} color={color} variant={variant} />, tool: "image", label: "تصویر" },
|
{ icon: (color, variant) => <Gallery size={20} color={color} variant={variant} />, tool: "image", label: "تصویر" },
|
||||||
{ icon: (color, variant) => <Link size={20} color={color} variant={variant} />, tool: "link", label: "لینک" },
|
{ icon: (color, variant) => <Link2 size={20} color={color} variant={variant} />, tool: "link", label: "لینک" },
|
||||||
{ icon: (color, variant) => <DocumentUpload size={20} color={color} variant={variant} />, tool: "document", label: "سند" },
|
{ icon: (color, variant) => <DocumentUpload size={20} color={color} variant={variant} />, tool: "document", label: "سند" },
|
||||||
{ icon: (color, variant) => <Element size={20} color={color} variant={variant} />, tool: "arrow", label: "پیکان" },
|
{ icon: (color, variant) => <Element size={20} color={color} variant={variant} />, tool: "arrow", label: "پیکان" },
|
||||||
{ icon: (color, variant) => <Minus size={20} color={color} variant={variant} />, tool: "line", label: "خط" },
|
{ icon: (color, variant) => <Minus size={20} color={color} variant={variant} />, tool: "line", label: "خط" },
|
||||||
@@ -39,7 +39,7 @@ const ToolsBar = ({ tool, onToolClick }: ToolsBarProps) => {
|
|||||||
{tools.map((item, index) => {
|
{tools.map((item, index) => {
|
||||||
const isActive = tool === item.tool;
|
const isActive = tool === item.tool;
|
||||||
const iconColor = "black";
|
const iconColor = "black";
|
||||||
const iconVariant = isActive ? "Bold" : undefined;
|
const iconVariant: "Bold" | "Outline" | "Broken" | "Bulk" | "Linear" | "TwoTone" | undefined = isActive ? "Bold" : "Outline";
|
||||||
return (
|
return (
|
||||||
<button
|
<button
|
||||||
key={index}
|
key={index}
|
||||||
|
|||||||
Reference in New Issue
Block a user