From e9449a7294f1b98f6e73910abcda04359ca4271a Mon Sep 17 00:00:00 2001 From: fikyair Date: Sun, 5 Sep 2021 18:14:43 +0800 Subject: [PATCH] feat: icon more icons --- package.json | 7 +- src/components/InputDatePicker/calendar.tsx | 2 +- src/components/InputDatePicker/dateView.tsx | 4 +- .../InputDatePicker/inputDatePicker.tsx | 3 +- .../InputDatePicker/monthYearView.tsx | 2 +- src/components/icons/icon.stories.tsx | 103 + src/components/icons/icon.tsx | 2 - src/components/icons/shared/res.js | 6021 +++++++++++++++++ src/components/icons/style.scss | 11 +- 9 files changed, 6143 insertions(+), 12 deletions(-) create mode 100644 src/components/icons/icon.stories.tsx create mode 100644 src/components/icons/shared/res.js diff --git a/package.json b/package.json index 0c200f91..d99bfe72 100644 --- a/package.json +++ b/package.json @@ -36,9 +36,9 @@ ], "dependencies": { "@babel/core": "7.12.3", - "@fortawesome/fontawesome-svg-core": "^1.2.30", - "@fortawesome/free-solid-svg-icons": "^5.14.0", - "@fortawesome/react-fontawesome": "0.1.14", + "@fortawesome/fontawesome-svg-core": "^1.2.36", + "@fortawesome/free-solid-svg-icons": "^5.15.4", + "@fortawesome/react-fontawesome": "0.1.15", "@pmmmwh/react-refresh-webpack-plugin": "0.4.3", "@svgr/webpack": "5.5.0", "@typescript-eslint/eslint-plugin": "^4.5.0", @@ -53,6 +53,7 @@ "camelcase": "^6.1.0", "case-sensitive-paths-webpack-plugin": "2.3.0", "classnames": "^2.2.6", + "copy-to-clipboard": "^3.3.1", "css-loader": "4.3.0", "dayjs": "^1.9.8", "dotenv": "8.2.0", diff --git a/src/components/InputDatePicker/calendar.tsx b/src/components/InputDatePicker/calendar.tsx index f804046b..73b8d5c8 100644 --- a/src/components/InputDatePicker/calendar.tsx +++ b/src/components/InputDatePicker/calendar.tsx @@ -15,7 +15,7 @@ export interface CalendarProps { function Calendar(props: CalendarProps) { const { selectedDate, onSelectDate } = props; - const [isDateView, setDateView] = useState(false); + const [isDateView, setDateView] = useState(true); const calendarRef = useRef(null); const today = new Date(); diff --git a/src/components/InputDatePicker/dateView.tsx b/src/components/InputDatePicker/dateView.tsx index 0c31fdcd..ce861546 100644 --- a/src/components/InputDatePicker/dateView.tsx +++ b/src/components/InputDatePicker/dateView.tsx @@ -52,7 +52,7 @@ function DateView(props: DateViewProps & CalendarProps) { /> } header={{ - leftElement: , + leftElement: , middleElement: ( ), - rightElement: , + rightElement: , }} footerElement={