feat(components): 新增表格属性配置

This commit is contained in:
xlsea
2025-06-05 21:09:01 +08:00
parent 9cdbf81467
commit f81a65a359
12 changed files with 160 additions and 4 deletions

23
src/typings/app.d.ts vendored
View File

@ -109,6 +109,20 @@ declare namespace App {
/** Watermark text */
text: string;
};
table: {
/** Whether to show the table border */
bordered: boolean;
/** Whether to show the table bottom border */
bottomBordered: boolean;
/** Whether to show the table single column */
singleColumn: boolean;
/** Whether to show the table single line */
singleLine: boolean;
/** Whether to show the table size */
size: UnionKey.ThemeTableSize;
/** Whether to show the table striped */
striped: boolean;
};
/** define some theme settings tokens, will transform to css variables */
tokens: {
light: ThemeSettingToken;
@ -426,6 +440,15 @@ declare namespace App {
visible: string;
text: string;
};
tablePropsTitle: string;
table: {
size: { title: string } & Record<UnionKey.ThemeTableSize, string>;
bordered: string;
bottomBordered: string;
singleColumn: string;
singleLine: string;
striped: string;
};
themeDrawerTitle: string;
pageFunTitle: string;
resetCacheStrategy: { title: string } & Record<UnionKey.ResetCacheStrategy, string>;

View File

@ -14,6 +14,7 @@ declare module 'vue' {
ButtonIcon: typeof import('./../components/custom/button-icon.vue')['default']
CountTo: typeof import('./../components/custom/count-to.vue')['default']
DarkModeContainer: typeof import('./../components/common/dark-mode-container.vue')['default']
DataTable: typeof import('./../components/common/data-table.vue')['default']
DeptTree: typeof import('./../components/custom/dept-tree.vue')['default']
DeptTreeSelect: typeof import('./../components/custom/dept-tree-select.vue')['default']
DictRadio: typeof import('./../components/custom/dict-radio.vue')['default']

View File

@ -51,6 +51,15 @@ declare namespace UnionKey {
*/
type ThemeTabMode = import('@sa/materials').PageTabMode;
/**
* The table size
*
* - small: small size
* - medium: medium size
* - large: large size
*/
type ThemeTableSize = 'small' | 'medium' | 'large';
/** Unocss animate key */
type UnoCssAnimateKey =
| 'pulse'