From e64a19a05a79dcd8e5c8f3910832a1a9dde610ff Mon Sep 17 00:00:00 2001 From: tangjinzhou <415800467@qq.com> Date: Thu, 26 Jan 2023 10:13:10 +0800 Subject: [PATCH] refactor: backtop --- components/_util/type.ts | 4 + components/back-top/demo/custom.vue | 11 +- components/back-top/index.tsx | 31 +++--- components/back-top/style/index.less | 49 --------- components/back-top/style/index.ts | 118 ++++++++++++++++++++++ components/back-top/style/index.tsx | 2 - components/back-top/style/responsive.less | 21 ---- components/style.ts | 2 +- components/theme/interface/components.ts | 26 ++--- 9 files changed, 159 insertions(+), 105 deletions(-) delete mode 100644 components/back-top/style/index.less create mode 100644 components/back-top/style/index.ts delete mode 100644 components/back-top/style/index.tsx delete mode 100644 components/back-top/style/responsive.less diff --git a/components/_util/type.ts b/components/_util/type.ts index ed35b21a2..b2e14f33a 100644 --- a/components/_util/type.ts +++ b/components/_util/type.ts @@ -42,3 +42,7 @@ export const withInstall = (comp: T) => { }; export type MaybeRef = T | Ref; + +export function eventType() { + return { type: [Function, Array] as PropType }; +} diff --git a/components/back-top/demo/custom.vue b/components/back-top/demo/custom.vue index da70dad3e..ae36a70aa 100644 --- a/components/back-top/demo/custom.vue +++ b/components/back-top/demo/custom.vue @@ -17,7 +17,7 @@ You can customize the style of the button, just note the size limit: no more tha +