From e410d88b78d05235d69ccb4fb8b7b33cbc313926 Mon Sep 17 00:00:00 2001 From: "Collin M. Barrett" Date: Mon, 9 Mar 2020 21:08:55 -0500 Subject: [PATCH] run ant's codemod tool --- web/src/App.tsx | 19 +++++++++++++------ web/src/components/LinkButton.tsx | 3 ++- web/src/components/ListInfoButton.tsx | 5 +++-- web/src/components/SubscribeButtons.tsx | 3 ++- .../components/maintainers/Maintainers.tsx | 10 ++++++---- web/src/hooks/useSearchColumnFilter.tsx | 10 ++++------ 6 files changed, 30 insertions(+), 20 deletions(-) diff --git a/web/src/App.tsx b/web/src/App.tsx index 586e45475..6d36cc739 100644 --- a/web/src/App.tsx +++ b/web/src/App.tsx @@ -1,4 +1,11 @@ -import { Icon, Layout, Menu, Tag } from "antd"; +import { + ApiOutlined, + DollarOutlined, + GithubOutlined, + TeamOutlined, + TwitterOutlined +} from "@ant-design/icons"; +import { Layout, Menu, Tag } from "antd"; import React from "react"; import { BrowserRouter as Router, @@ -93,7 +100,7 @@ const Twitter = () => ( target="_blank" rel="noopener noreferrer" > - Twitter + Twitter ); @@ -106,7 +113,7 @@ const Community = () => ( target="_blank" rel="noopener noreferrer" > - Community + Community ); @@ -119,7 +126,7 @@ const GitHub = () => ( target="_blank" rel="noopener noreferrer" > - GitHub + GitHub ); @@ -132,7 +139,7 @@ const Api = () => ( target="_blank" rel="noopener noreferrer" > - API + API ); @@ -145,7 +152,7 @@ const Donate = () => ( target="_blank" rel="noopener noreferrer" > - Donate + Donate ); diff --git a/web/src/components/LinkButton.tsx b/web/src/components/LinkButton.tsx index 1ad53baea..20d51c17e 100644 --- a/web/src/components/LinkButton.tsx +++ b/web/src/components/LinkButton.tsx @@ -1,3 +1,4 @@ +import { Icon as LegacyIcon } from "@ant-design/compatible"; import { Button } from "antd"; import { ButtonType } from "antd/lib/button"; import React from "react"; @@ -18,7 +19,7 @@ export const LinkButton = (props: Props) => type={props.type || "default"} block style={{ borderLeftColor: "rgb(217, 217, 217)" }} //HACK: override buggy style in antd - icon={props.icon} + icon={} target="_blank" rel="noopener noreferrer" > diff --git a/web/src/components/ListInfoButton.tsx b/web/src/components/ListInfoButton.tsx index 02cee68dd..37013b331 100644 --- a/web/src/components/ListInfoButton.tsx +++ b/web/src/components/ListInfoButton.tsx @@ -1,4 +1,5 @@ -import { Button, Icon } from "antd"; +import { InfoCircleOutlined } from "@ant-design/icons"; +import { Button } from "antd"; import React from "react"; import { RouteComponentProps } from "react-router-dom"; import slugify from "slugify"; @@ -21,7 +22,7 @@ export const ListInfoButton = (props: RouteComponentProps & Props) => { : props.history.push(listPath) } > - + ); }; diff --git a/web/src/components/SubscribeButtons.tsx b/web/src/components/SubscribeButtons.tsx index 4db0a71a9..8737f4828 100644 --- a/web/src/components/SubscribeButtons.tsx +++ b/web/src/components/SubscribeButtons.tsx @@ -1,3 +1,4 @@ +import { ImportOutlined } from "@ant-design/icons"; import { Button } from "antd"; import { ButtonType } from "antd/lib/button"; import React from "react"; @@ -52,7 +53,7 @@ const SubscribeButton = (props: SubscribeButtonProps) => {