Skip to content

Commit 5d66828

Browse files
committed
[Dashboard] Remove react-icons (1)
1 parent 9768993 commit 5d66828

File tree

11 files changed

+43
-55
lines changed

11 files changed

+43
-55
lines changed

apps/dashboard/src/components/contract-components/contract-table-v2/index.tsx

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
import { WalletAddress } from "@/components/blocks/wallet-address";
22
import {
33
Flex,
4-
Icon,
54
Image,
65
Spinner,
76
Table,
@@ -17,10 +16,9 @@ import { ChakraNextImage } from "components/Image";
1716
import { replaceDeployerAddress } from "components/explore/publisher";
1817
import { useTrack } from "hooks/analytics/useTrack";
1918
import { replaceIpfsUrl } from "lib/sdk";
19+
import { MoveRightIcon, ShieldCheckIcon } from "lucide-react";
2020
import { useRouter } from "next/router";
2121
import { useMemo } from "react";
22-
import { BsShieldFillCheck } from "react-icons/bs";
23-
import { FiArrowRight } from "react-icons/fi";
2422
import { type Column, type Row, useTable } from "react-table";
2523
import {
2624
Card,
@@ -139,7 +137,7 @@ export const PublishedContractTable: ComponentWithChildren<
139137
aria-label="Audited contract"
140138
colorScheme="green"
141139
variant="ghost"
142-
icon={<Icon as={BsShieldFillCheck} boxSize={4} />}
140+
icon={<ShieldCheckIcon className="size-4" />}
143141
onClick={(e) => {
144142
e.stopPropagation();
145143
trackEvent({
@@ -255,7 +253,7 @@ const ContractTableRow: React.FC<ContractTableRowProps> = ({ row }) => {
255253
</Td>
256254
))}
257255
<Td borderBottomColor="borderColor" borderBottomWidth="inherit">
258-
<Icon color="var(--rowIconColor)" as={FiArrowRight} />
256+
<MoveRightIcon className="size-4" />
259257
</Td>
260258
</Tr>
261259
</>

apps/dashboard/src/components/contract-components/published-contract/index.tsx

Lines changed: 12 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -1,23 +1,20 @@
11
"use client";
22

33
import { useThirdwebClient } from "@/constants/thirdweb.client";
4-
import {
5-
Divider,
6-
Flex,
7-
GridItem,
8-
Icon,
9-
List,
10-
ListItem,
11-
} from "@chakra-ui/react";
4+
import { Divider, Flex, GridItem, List, ListItem } from "@chakra-ui/react";
125
import { useQuery } from "@tanstack/react-query";
136
import { ContractFunctionsOverview } from "components/contract-functions/contract-functions";
147
import { format } from "date-fns/format";
158
import { correctAndUniqueLicenses } from "lib/licenses";
169
import { replaceIpfsUrl } from "lib/sdk";
17-
import { ShieldCheckIcon } from "lucide-react";
10+
import {
11+
BookOpenTextIcon,
12+
CalendarDaysIcon,
13+
PencilIcon,
14+
ServerIcon,
15+
ShieldCheckIcon,
16+
} from "lucide-react";
1817
import { useMemo } from "react";
19-
import { BiPencil } from "react-icons/bi";
20-
import { VscBook, VscCalendar, VscServer } from "react-icons/vsc";
2118
import type { ThirdwebClient } from "thirdweb";
2219
import { useActiveAccount } from "thirdweb/react";
2320
import { download } from "thirdweb/storage";
@@ -112,7 +109,7 @@ export const PublishedContract: React.FC<PublishedContractProps> = ({
112109
ml="auto"
113110
size="sm"
114111
variant="outline"
115-
leftIcon={<Icon as={BiPencil} />}
112+
leftIcon={<PencilIcon className="size-3" />}
116113
href={`/contracts/publish/${encodeURIComponent(
117114
publishedContract.publishMetadataUri.replace("ipfs://", ""),
118115
)}`}
@@ -166,7 +163,7 @@ export const PublishedContract: React.FC<PublishedContractProps> = ({
166163
{publishedContract.publishTimestamp && (
167164
<ListItem>
168165
<Flex gap={2} alignItems="flex-start">
169-
<Icon color="paragraph" as={VscCalendar} boxSize={5} />
166+
<CalendarDaysIcon className="size-5 text-muted-foreground" />
170167
<Flex direction="column" gap={1}>
171168
<Heading as="h5" size="label.sm">
172169
Publish Date
@@ -208,7 +205,7 @@ export const PublishedContract: React.FC<PublishedContractProps> = ({
208205
)}
209206
<ListItem>
210207
<Flex gap={2} alignItems="flex-start">
211-
<Icon color="paragraph" as={VscBook} boxSize={5} />
208+
<BookOpenTextIcon className="size-5 text-muted-foreground" />
212209
<Flex direction="column" gap={1}>
213210
<Heading as="h5" size="label.sm">
214211
License
@@ -226,7 +223,7 @@ export const PublishedContract: React.FC<PublishedContractProps> = ({
226223
hasFactoryAddresses) ? (
227224
<ListItem>
228225
<Flex gap={2} alignItems="flex-start">
229-
<Icon color="paragraph" as={VscServer} boxSize={5} />
226+
<ServerIcon className="size-5 text-muted-foreground" />
230227
<Flex direction="column" gap={1}>
231228
<Heading as="h5" size="label.sm">
232229
{publishedContract?.isDeployableViaFactory

apps/dashboard/src/components/engine/configuration/add-webhook-button.tsx

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,6 @@ import {
55
import {
66
Flex,
77
FormControl,
8-
Icon,
98
Input,
109
Modal,
1110
ModalBody,
@@ -19,8 +18,8 @@ import {
1918
} from "@chakra-ui/react";
2019
import { useTrack } from "hooks/analytics/useTrack";
2120
import { useTxNotifications } from "hooks/useTxNotifications";
21+
import { CirclePlusIcon } from "lucide-react";
2222
import { useForm } from "react-hook-form";
23-
import { AiOutlinePlusCircle } from "react-icons/ai";
2423
import { Button, FormLabel } from "tw-components";
2524
import { beautifyString } from "./webhooks-table";
2625

@@ -57,7 +56,7 @@ export const AddWebhookButton: React.FC<AddWebhookButtonProps> = ({
5756
onClick={onOpen}
5857
variant="ghost"
5958
size="sm"
60-
leftIcon={<Icon as={AiOutlinePlusCircle} boxSize={6} />}
59+
leftIcon={<CirclePlusIcon className="size-6" />}
6160
colorScheme="primary"
6261
w="fit-content"
6362
>

apps/dashboard/src/components/engine/contract-subscription/add-contract-subscription-button.tsx

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,6 @@ import {
1212
Collapse,
1313
Flex,
1414
FormControl,
15-
Icon,
1615
Input,
1716
Modal,
1817
ModalBody,
@@ -30,9 +29,9 @@ import {
3029
import { useTrack } from "hooks/analytics/useTrack";
3130
import { useTxNotifications } from "hooks/useTxNotifications";
3231
import { useV5DashboardChain } from "lib/v5-adapter";
32+
import { CirclePlusIcon } from "lucide-react";
3333
import { type Dispatch, type SetStateAction, useMemo, useState } from "react";
3434
import { type UseFormReturn, useForm } from "react-hook-form";
35-
import { AiOutlinePlusCircle } from "react-icons/ai";
3635
import { getContract, isAddress } from "thirdweb";
3736
import {
3837
Button,
@@ -59,7 +58,7 @@ export const AddContractSubscriptionButton: React.FC<
5958
onClick={disclosure.onOpen}
6059
variant="ghost"
6160
size="sm"
62-
leftIcon={<Icon as={AiOutlinePlusCircle} boxSize={6} />}
61+
leftIcon={<CirclePlusIcon className="size-6" />}
6362
colorScheme="primary"
6463
w="fit-content"
6564
>

apps/dashboard/src/components/engine/permissions/add-access-token-button.tsx

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
import { useEngineCreateAccessToken } from "@3rdweb-sdk/react/hooks/useEngine";
22
import {
33
Flex,
4-
Icon,
54
Modal,
65
ModalBody,
76
ModalContent,
@@ -12,8 +11,8 @@ import {
1211
} from "@chakra-ui/react";
1312
import { useTrack } from "hooks/analytics/useTrack";
1413
import { useTxNotifications } from "hooks/useTxNotifications";
14+
import { CirclePlusIcon } from "lucide-react";
1515
import { useState } from "react";
16-
import { AiOutlinePlusCircle } from "react-icons/ai";
1716
import { Button, Checkbox, CodeBlock, Text } from "tw-components";
1817

1918
interface AddAccessTokenButtonProps {
@@ -64,7 +63,7 @@ export const AddAccessTokenButton: React.FC<AddAccessTokenButtonProps> = ({
6463
}}
6564
variant="ghost"
6665
size="sm"
67-
leftIcon={<Icon as={AiOutlinePlusCircle} boxSize={6} />}
66+
leftIcon={<CirclePlusIcon className="size-6" />}
6867
colorScheme="primary"
6968
w="fit-content"
7069
>

apps/dashboard/src/components/engine/permissions/add-admin-button.tsx

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,6 @@ import {
55
import {
66
Flex,
77
FormControl,
8-
Icon,
98
Input,
109
Modal,
1110
ModalBody,
@@ -18,8 +17,8 @@ import {
1817
} from "@chakra-ui/react";
1918
import { useTrack } from "hooks/analytics/useTrack";
2019
import { useTxNotifications } from "hooks/useTxNotifications";
20+
import { CirclePlusIcon } from "lucide-react";
2121
import { useForm } from "react-hook-form";
22-
import { AiOutlinePlusCircle } from "react-icons/ai";
2322
import { isAddress } from "thirdweb";
2423
import { Button, FormLabel } from "tw-components";
2524

@@ -50,7 +49,7 @@ export const AddAdminButton: React.FC<AddAdminButtonProps> = ({
5049
onClick={onOpen}
5150
variant="ghost"
5251
size="sm"
53-
leftIcon={<Icon as={AiOutlinePlusCircle} boxSize={6} />}
52+
leftIcon={<CirclePlusIcon className="size-6" />}
5453
colorScheme="primary"
5554
w="fit-content"
5655
>

apps/dashboard/src/components/engine/permissions/add-keypair-button.tsx

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,6 @@ import {
66
Alert,
77
Flex,
88
FormControl,
9-
Icon,
109
Input,
1110
Modal,
1211
ModalBody,
@@ -20,8 +19,8 @@ import {
2019
} from "@chakra-ui/react";
2120
import { useTrack } from "hooks/analytics/useTrack";
2221
import { useTxNotifications } from "hooks/useTxNotifications";
22+
import { CirclePlusIcon } from "lucide-react";
2323
import { useState } from "react";
24-
import { AiOutlinePlusCircle } from "react-icons/ai";
2524
import { Button, CodeBlock, FormLabel, Text } from "tw-components";
2625

2726
const KEYPAIR_ALGORITHM_DETAILS: Record<
@@ -108,7 +107,7 @@ export const AddKeypairButton: React.FC<AddKeypairButtonProps> = ({
108107
onClick={onOpen}
109108
variant="ghost"
110109
size="sm"
111-
leftIcon={<Icon as={AiOutlinePlusCircle} boxSize={6} />}
110+
leftIcon={<CirclePlusIcon className="size-6" />}
112111
colorScheme="primary"
113112
w="fit-content"
114113
>

apps/dashboard/src/components/engine/relayer/add-relayer-button.tsx

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,6 @@ import {
77
import {
88
Flex,
99
FormControl,
10-
Icon,
1110
Input,
1211
Modal,
1312
ModalBody,
@@ -24,8 +23,8 @@ import {
2423
import { useTrack } from "hooks/analytics/useTrack";
2524
import { useAllChainsData } from "hooks/chains/allChains";
2625
import { useTxNotifications } from "hooks/useTxNotifications";
26+
import { CirclePlusIcon } from "lucide-react";
2727
import { useForm } from "react-hook-form";
28-
import { AiOutlinePlusCircle } from "react-icons/ai";
2928
import { isAddress, shortenAddress } from "thirdweb/utils";
3029
import { Button, FormHelperText, FormLabel } from "tw-components";
3130

@@ -44,7 +43,7 @@ export const AddRelayerButton: React.FC<AddRelayerButtonProps> = ({
4443
onClick={disclosure.onOpen}
4544
variant="ghost"
4645
size="sm"
47-
leftIcon={<Icon as={AiOutlinePlusCircle} boxSize={6} />}
46+
leftIcon={<CirclePlusIcon className="size-6" />}
4847
colorScheme="primary"
4948
w="fit-content"
5049
>

apps/dashboard/src/components/wallets/ConnectWalletPlayground/FormItem.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
import { Flex, FormControl, Tooltip } from "@chakra-ui/react";
2-
import { AiOutlineInfoCircle } from "react-icons/ai";
2+
import { CirclePlusIcon } from "lucide-react";
33
import { FormLabel } from "tw-components";
44

55
export const FormItem: React.FC<{
@@ -26,7 +26,7 @@ export const FormItem: React.FC<{
2626
label={<div>{props.description}</div>}
2727
>
2828
<div>
29-
<AiOutlineInfoCircle className="text-muted-foreground" />
29+
<CirclePlusIcon className="size-5 text-muted-foreground" />
3030
</div>
3131
</Tooltip>
3232
)}

apps/dashboard/src/components/wallets/ConnectWalletPlayground/ModalSizeButton.tsx

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
1-
import { Icon, IconButton, Tooltip } from "@chakra-ui/react";
1+
import { ToolTipLabel } from "@/components/ui/tooltip";
2+
import { IconButton } from "@chakra-ui/react";
23
import { useTrack } from "hooks/analytics/useTrack";
3-
import { FaRectangleList } from "react-icons/fa6";
4-
import { RiFileListFill } from "react-icons/ri";
4+
import { ListIcon, Rows3Icon } from "lucide-react";
55

66
export function ModalSizeButton(props: {
77
modalSize: "compact" | "wide";
@@ -12,7 +12,7 @@ export function ModalSizeButton(props: {
1212
}) {
1313
const trackEvent = useTrack();
1414
return (
15-
<Tooltip label={props.modalSize === "wide" ? "Wide" : "Compact"}>
15+
<ToolTipLabel label={props.modalSize === "wide" ? "Wide" : "Compact"}>
1616
<IconButton
1717
w={10}
1818
h={10}
@@ -26,11 +26,11 @@ export function ModalSizeButton(props: {
2626
color={props.isSelected ? "blue.500" : "heading"}
2727
borderColor={props.isSelected ? "blue.500" : "gray.800"}
2828
icon={
29-
<Icon
30-
as={props.modalSize === "wide" ? FaRectangleList : RiFileListFill}
31-
width={5}
32-
height={5}
33-
/>
29+
props.modalSize === "wide" ? (
30+
<ListIcon className="size-5" />
31+
) : (
32+
<Rows3Icon className="size-5" />
33+
)
3434
}
3535
onClick={() => {
3636
props.onClick();
@@ -43,6 +43,6 @@ export function ModalSizeButton(props: {
4343
});
4444
}}
4545
/>
46-
</Tooltip>
46+
</ToolTipLabel>
4747
);
4848
}

0 commit comments

Comments
 (0)