@tmagic/table 1.5.4 → 1.5.6
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/tmagic-table.js +235 -140
- package/dist/tmagic-table.umd.cjs +2494 -145
- package/package.json +4 -13
- package/types/index.d.ts +89 -1
- /package/dist/{style.css → tmagic-table.css} +0 -0
package/package.json
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
{
|
|
2
|
-
"version": "1.5.
|
|
2
|
+
"version": "1.5.6",
|
|
3
3
|
"name": "@tmagic/table",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"sideEffects": [
|
|
@@ -39,26 +39,17 @@
|
|
|
39
39
|
"lodash-es": "^4.17.21"
|
|
40
40
|
},
|
|
41
41
|
"devDependencies": {
|
|
42
|
-
"@types/lodash-es": "^4.17.4"
|
|
43
|
-
"@types/node": "^18.19.0",
|
|
44
|
-
"@vitejs/plugin-vue": "^5.2.1",
|
|
45
|
-
"@vue/compiler-sfc": "^3.5.12",
|
|
46
|
-
"rimraf": "^3.0.2",
|
|
47
|
-
"sass": "^1.83.0",
|
|
48
|
-
"vite": "^6.0.3"
|
|
42
|
+
"@types/lodash-es": "^4.17.4"
|
|
49
43
|
},
|
|
50
44
|
"peerDependencies": {
|
|
51
45
|
"vue": ">=3.5.0",
|
|
52
46
|
"typescript": "*",
|
|
53
|
-
"@tmagic/
|
|
54
|
-
"@tmagic/
|
|
47
|
+
"@tmagic/design": "1.5.6",
|
|
48
|
+
"@tmagic/form": "1.5.6"
|
|
55
49
|
},
|
|
56
50
|
"peerDependenciesMeta": {
|
|
57
51
|
"typescript": {
|
|
58
52
|
"optional": true
|
|
59
53
|
}
|
|
60
|
-
},
|
|
61
|
-
"scripts": {
|
|
62
|
-
"build": "vite build"
|
|
63
54
|
}
|
|
64
55
|
}
|
package/types/index.d.ts
CHANGED
|
@@ -1,5 +1,7 @@
|
|
|
1
1
|
import * as vue from 'vue';
|
|
2
2
|
import { App } from 'vue';
|
|
3
|
+
import * as _vue_reactivity from '@vue/reactivity';
|
|
4
|
+
import * as _tmagic_design from '@tmagic/design';
|
|
3
5
|
import { FormConfig, FormValue } from '@tmagic/form';
|
|
4
6
|
|
|
5
7
|
interface ColumnActionConfig {
|
|
@@ -106,7 +108,93 @@ declare const _default$1: vue.DefineComponent<__VLS_Props, {
|
|
|
106
108
|
defaultExpandAll: boolean;
|
|
107
109
|
columns: ColumnConfig[];
|
|
108
110
|
showHeader: boolean;
|
|
109
|
-
}, {}, {}, {}, string, vue.ComponentProvideOptions, false, {
|
|
111
|
+
}, {}, {}, {}, string, vue.ComponentProvideOptions, false, {
|
|
112
|
+
tMagicTable: ({
|
|
113
|
+
$: vue.ComponentInternalInstance;
|
|
114
|
+
$data: {};
|
|
115
|
+
$props: {
|
|
116
|
+
readonly data?: any[] | undefined;
|
|
117
|
+
readonly border?: boolean | undefined;
|
|
118
|
+
readonly maxHeight?: number | string | undefined;
|
|
119
|
+
readonly defaultExpandAll?: boolean | undefined;
|
|
120
|
+
readonly onSelect?: ((...args: any[]) => any) | undefined;
|
|
121
|
+
readonly "onSort-change"?: ((...args: any[]) => any) | undefined;
|
|
122
|
+
readonly "onExpand-change"?: ((...args: any[]) => any) | undefined;
|
|
123
|
+
readonly "onCell-click"?: ((...args: any[]) => any) | undefined;
|
|
124
|
+
} & vue.VNodeProps & vue.AllowedComponentProps & vue.ComponentCustomProps;
|
|
125
|
+
$attrs: {
|
|
126
|
+
[x: string]: unknown;
|
|
127
|
+
};
|
|
128
|
+
$refs: {
|
|
129
|
+
[x: string]: unknown;
|
|
130
|
+
} & {
|
|
131
|
+
table: unknown;
|
|
132
|
+
};
|
|
133
|
+
$slots: Readonly<{
|
|
134
|
+
[name: string]: vue.Slot<any> | undefined;
|
|
135
|
+
}>;
|
|
136
|
+
$root: vue.ComponentPublicInstance | null;
|
|
137
|
+
$parent: vue.ComponentPublicInstance | null;
|
|
138
|
+
$host: Element | null;
|
|
139
|
+
$emit: ((event: "select", ...args: any[]) => void) & ((event: "sort-change", ...args: any[]) => void) & ((event: "expand-change", ...args: any[]) => void) & ((event: "cell-click", ...args: any[]) => void);
|
|
140
|
+
$el: any;
|
|
141
|
+
$options: vue.ComponentOptionsBase<Readonly<_tmagic_design.TableProps> & Readonly<{
|
|
142
|
+
onSelect?: ((...args: any[]) => any) | undefined;
|
|
143
|
+
"onSort-change"?: ((...args: any[]) => any) | undefined;
|
|
144
|
+
"onExpand-change"?: ((...args: any[]) => any) | undefined;
|
|
145
|
+
"onCell-click"?: ((...args: any[]) => any) | undefined;
|
|
146
|
+
}>, {
|
|
147
|
+
instance: vue.Ref<any, any>;
|
|
148
|
+
$el: HTMLDivElement | undefined;
|
|
149
|
+
clearSelection(...args: any[]): any;
|
|
150
|
+
toggleRowSelection(...args: any[]): any;
|
|
151
|
+
toggleRowExpansion(...args: any[]): any;
|
|
152
|
+
}, {}, {}, {}, vue.ComponentOptionsMixin, vue.ComponentOptionsMixin, {
|
|
153
|
+
select: (...args: any[]) => void;
|
|
154
|
+
"sort-change": (...args: any[]) => void;
|
|
155
|
+
"expand-change": (...args: any[]) => void;
|
|
156
|
+
"cell-click": (...args: any[]) => void;
|
|
157
|
+
}, string, {
|
|
158
|
+
data: any[];
|
|
159
|
+
}, {}, string, {}, vue.GlobalComponents, vue.GlobalDirectives, string, vue.ComponentProvideOptions> & {
|
|
160
|
+
beforeCreate?: (() => void) | (() => void)[];
|
|
161
|
+
created?: (() => void) | (() => void)[];
|
|
162
|
+
beforeMount?: (() => void) | (() => void)[];
|
|
163
|
+
mounted?: (() => void) | (() => void)[];
|
|
164
|
+
beforeUpdate?: (() => void) | (() => void)[];
|
|
165
|
+
updated?: (() => void) | (() => void)[];
|
|
166
|
+
activated?: (() => void) | (() => void)[];
|
|
167
|
+
deactivated?: (() => void) | (() => void)[];
|
|
168
|
+
beforeDestroy?: (() => void) | (() => void)[];
|
|
169
|
+
beforeUnmount?: (() => void) | (() => void)[];
|
|
170
|
+
destroyed?: (() => void) | (() => void)[];
|
|
171
|
+
unmounted?: (() => void) | (() => void)[];
|
|
172
|
+
renderTracked?: ((e: vue.DebuggerEvent) => void) | ((e: vue.DebuggerEvent) => void)[];
|
|
173
|
+
renderTriggered?: ((e: vue.DebuggerEvent) => void) | ((e: vue.DebuggerEvent) => void)[];
|
|
174
|
+
errorCaptured?: ((err: unknown, instance: vue.ComponentPublicInstance | null, info: string) => boolean | void) | ((err: unknown, instance: vue.ComponentPublicInstance | null, info: string) => boolean | void)[];
|
|
175
|
+
};
|
|
176
|
+
$forceUpdate: () => void;
|
|
177
|
+
$nextTick: typeof vue.nextTick;
|
|
178
|
+
$watch<T extends string | ((...args: any) => any)>(source: T, cb: T extends (...args: any) => infer R ? (...args: [R, R, _vue_reactivity.OnCleanup]) => any : (...args: [any, any, _vue_reactivity.OnCleanup]) => any, options?: vue.WatchOptions): vue.WatchStopHandle;
|
|
179
|
+
} & Readonly<{
|
|
180
|
+
data: any[];
|
|
181
|
+
}> & Omit<Readonly<_tmagic_design.TableProps> & Readonly<{
|
|
182
|
+
onSelect?: ((...args: any[]) => any) | undefined;
|
|
183
|
+
"onSort-change"?: ((...args: any[]) => any) | undefined;
|
|
184
|
+
"onExpand-change"?: ((...args: any[]) => any) | undefined;
|
|
185
|
+
"onCell-click"?: ((...args: any[]) => any) | undefined;
|
|
186
|
+
}>, "instance" | "data" | "$el" | "clearSelection" | "toggleRowSelection" | "toggleRowExpansion"> & vue.ShallowUnwrapRef<{
|
|
187
|
+
instance: vue.Ref<any, any>;
|
|
188
|
+
$el: HTMLDivElement | undefined;
|
|
189
|
+
clearSelection(...args: any[]): any;
|
|
190
|
+
toggleRowSelection(...args: any[]): any;
|
|
191
|
+
toggleRowExpansion(...args: any[]): any;
|
|
192
|
+
}> & {} & vue.ComponentCustomProperties & {} & {
|
|
193
|
+
$slots: {
|
|
194
|
+
default?(_: {}): any;
|
|
195
|
+
};
|
|
196
|
+
}) | null;
|
|
197
|
+
}, any>;
|
|
110
198
|
|
|
111
199
|
declare const formatter: (item: ColumnConfig, row: any) => any;
|
|
112
200
|
declare const createColumns: (columns: ColumnConfig[]) => ColumnConfig<any>[];
|
|
File without changes
|