From 87da2c270c1c4421114ad97077000e856daa8d3b Mon Sep 17 00:00:00 2001 From: Tyh2001 <1469442737@qq.com> Date: Sat, 16 Dec 2023 20:19:41 +0800 Subject: [PATCH] =?UTF-8?q?perf:=20=E4=BC=98=E5=8C=96=E8=A1=A8=E6=A0=BC?= =?UTF-8?q?=E7=BB=84=E4=BB=B6?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .eslintignore | 1 + CHANGELOG.md | 1 + .../fighting-design/table/components/index.ts | 3 - .../table/components/table-colgroup/index.vue | 19 --- .../components/table-colgroup/interface.ts | 1 - .../table/components/table-colgroup/props.ts | 11 -- .../fighting-design/table/src/interface.ts | 2 - .../fighting-design/table/src/table copy.vue | 153 ++++++++++++++++++ packages/fighting-design/table/src/table.vue | 41 +++-- packages/fighting-eslint-config/index.js | 2 +- packages/fighting-theme/src/table.scss | 18 +-- 11 files changed, 194 insertions(+), 58 deletions(-) delete mode 100644 packages/fighting-design/table/components/index.ts delete mode 100644 packages/fighting-design/table/components/table-colgroup/index.vue delete mode 100644 packages/fighting-design/table/components/table-colgroup/interface.ts delete mode 100644 packages/fighting-design/table/components/table-colgroup/props.ts create mode 100644 packages/fighting-design/table/src/table copy.vue diff --git a/.eslintignore b/.eslintignore index 72c6dda4be..1329b3865c 100644 --- a/.eslintignore +++ b/.eslintignore @@ -10,3 +10,4 @@ fighting-add-component scripts/** fighting-eslint-config fighting-icon +start diff --git a/CHANGELOG.md b/CHANGELOG.md index 2695e25842..591455162c 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -3,6 +3,7 @@ 中文 | [英文](https://github.com/FightingDesign/fighting-design/blob/master/CHANGELOG.en-US.md) - 修复 `f-table` 组件对于英文字母的文字不换行样式的问题 +- 修复 `f-table` 组件返回类型 ## 0.65.0 (2023-12-12) diff --git a/packages/fighting-design/table/components/index.ts b/packages/fighting-design/table/components/index.ts deleted file mode 100644 index 463bccd832..0000000000 --- a/packages/fighting-design/table/components/index.ts +++ /dev/null @@ -1,3 +0,0 @@ -export { default as TableColgroupVue } from './table-colgroup/index.vue' - -export * from './table-colgroup/interface' diff --git a/packages/fighting-design/table/components/table-colgroup/index.vue b/packages/fighting-design/table/components/table-colgroup/index.vue deleted file mode 100644 index 77c174b2b9..0000000000 --- a/packages/fighting-design/table/components/table-colgroup/index.vue +++ /dev/null @@ -1,19 +0,0 @@ - - - diff --git a/packages/fighting-design/table/components/table-colgroup/interface.ts b/packages/fighting-design/table/components/table-colgroup/interface.ts deleted file mode 100644 index cfaa189b8f..0000000000 --- a/packages/fighting-design/table/components/table-colgroup/interface.ts +++ /dev/null @@ -1 +0,0 @@ -export type { TableColgroupProps } from './props' diff --git a/packages/fighting-design/table/components/table-colgroup/props.ts b/packages/fighting-design/table/components/table-colgroup/props.ts deleted file mode 100644 index 5bc0189bb4..0000000000 --- a/packages/fighting-design/table/components/table-colgroup/props.ts +++ /dev/null @@ -1,11 +0,0 @@ -import { setArrayProp } from '../../../_utils' -import type { ExtractPropTypes } from 'vue' -import type { TableColumns } from '../../index' - -export const Props = { - /** 标题配置 */ - columns: setArrayProp() -} - -/** table-colgroup 组件 props 类型 */ -export type TableColgroupProps = ExtractPropTypes diff --git a/packages/fighting-design/table/src/interface.ts b/packages/fighting-design/table/src/interface.ts index 0b58d00fd1..a5000cefbc 100644 --- a/packages/fighting-design/table/src/interface.ts +++ b/packages/fighting-design/table/src/interface.ts @@ -6,7 +6,6 @@ export type { TableProps } from './props' export type TableAlign = 'left' | 'center' | 'right' /** 表格数据类型 */ -// eslint-disable-next-line @typescript-eslint/no-explicit-any export type TableData = Record[] /** @@ -15,7 +14,6 @@ export type TableData = Record[] type Children = string | number | boolean | VNode | null | Children[] /** 自定义模板函数渲染返回值类型 */ -// eslint-disable-next-line @typescript-eslint/no-explicit-any export type RenderReturn = VNode> /** diff --git a/packages/fighting-design/table/src/table copy.vue b/packages/fighting-design/table/src/table copy.vue new file mode 100644 index 0000000000..2c18fbc049 --- /dev/null +++ b/packages/fighting-design/table/src/table copy.vue @@ -0,0 +1,153 @@ + + + diff --git a/packages/fighting-design/table/src/table.vue b/packages/fighting-design/table/src/table.vue index 801773ee76..6db3dcff3f 100644 --- a/packages/fighting-design/table/src/table.vue +++ b/packages/fighting-design/table/src/table.vue @@ -1,10 +1,9 @@