From bf7c62f457fc14624881f69c5baf9a62219383f7 Mon Sep 17 00:00:00 2001
From: tanjinzhou <415800467@qq.com>
Date: Thu, 7 Jan 2021 19:18:59 +0800
Subject: [PATCH] fix: date-picker ts type error
---
components/date-picker/createPicker.tsx | 2 +-
components/date-picker/index.ts | 8 ++++----
package.json | 7 +++----
3 files changed, 8 insertions(+), 9 deletions(-)
diff --git a/components/date-picker/createPicker.tsx b/components/date-picker/createPicker.tsx
index 6713bf601f..0a31752236 100644
--- a/components/date-picker/createPicker.tsx
+++ b/components/date-picker/createPicker.tsx
@@ -29,7 +29,7 @@ export default function createPicker
(
TheCalendar: DefineComponent
,
props: any,
name: string,
-): DefineComponent {
+): any {
return defineComponent({
name,
mixins: [BaseMixin],
diff --git a/components/date-picker/index.ts b/components/date-picker/index.ts
index a67372aa8f..8841fdc874 100755
--- a/components/date-picker/index.ts
+++ b/components/date-picker/index.ts
@@ -14,19 +14,19 @@ import {
} from './interface';
const WrappedRangePicker = (wrapPicker(
- RangePicker,
+ RangePicker as any,
RangePickerProps,
'date',
) as unknown) as DefineComponent;
const WrappedWeekPicker = (wrapPicker(
- WeekPicker,
+ WeekPicker as any,
WeekPickerProps,
'week',
) as unknown) as DefineComponent;
const DatePicker = (wrapPicker(
- createPicker(VcCalendar, DatePickerProps, 'ADatePicker'),
+ createPicker(VcCalendar as any, DatePickerProps, 'ADatePicker'),
DatePickerProps,
'date',
) as unknown) as DefineComponent & {
@@ -36,7 +36,7 @@ const DatePicker = (wrapPicker(
};
const MonthPicker = (wrapPicker(
- createPicker(MonthCalendar, MonthPickerProps, 'AMonthPicker'),
+ createPicker(MonthCalendar as any, MonthPickerProps, 'AMonthPicker'),
MonthPickerProps,
'month',
) as unknown) as DefineComponent;
diff --git a/package.json b/package.json
index b7eccba3dd..ed384bb17e 100644
--- a/package.json
+++ b/package.json
@@ -94,7 +94,7 @@
"@vue/cli-plugin-eslint": "^4.0.0",
"@vue/compiler-sfc": "^3.0.4",
"@vue/eslint-config-prettier": "^6.0.0",
- "@vue/eslint-config-typescript": "^5.1.0",
+ "@vue/eslint-config-typescript": "^7.0.0",
"@vue/test-utils": "^2.0.0-beta.2",
"acorn": "^7.0.0",
"autoprefixer": "^9.6.0",
@@ -152,6 +152,7 @@
"minimist": "^1.2.0",
"mkdirp": "^0.5.1",
"mockdate": "^2.0.2",
+ "node-emoji": "^1.10.0",
"nprogress": "^0.2.0",
"optimize-css-assets-webpack-plugin": "^5.0.1",
"postcss": "^7.0.6",
@@ -193,7 +194,6 @@
"vue-router": "^4.0.0",
"vue-server-renderer": "^2.6.11",
"vue-style-loader": "^4.1.2",
- "vue-virtual-scroller": "^1.0.0",
"vuex": "^4.0.0-beta.2",
"webpack": "^4.28.4",
"webpack-bundle-analyzer": "^3.8.0",
@@ -201,8 +201,7 @@
"webpack-dev-server": "^3.1.14",
"webpack-merge": "^4.1.1",
"webpackbar": "^4.0.0",
- "xhr-mock": "^2.5.1",
- "node-emoji": "^1.10.0"
+ "xhr-mock": "^2.5.1"
},
"dependencies": {
"@ant-design-vue/use": "^0.0.1-0",