bi-sdk-react 0.0.55 → 0.0.56
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/es/js/bi-sdk.es.js +24 -24
- package/dist/types/components/example.d.ts +8 -4
- package/dist/types/components/hooks/datasource.d.ts +2 -1
- package/dist/types/components/plugins/@antd/item-props/TableProps.d.ts +9 -0
- package/dist/types/components/plugins/@antd/items/TableRender.d.ts +9 -1
- package/dist/umd/js/bi-sdk.umd.min.js +12 -12
- package/package.json +1 -1
- package/src/components/example.ts +9 -10
- package/src/components/hooks/datasource.ts +5 -4
- package/src/components/plugins/@antd/index.ts +5 -7
- package/src/components/plugins/@antd/item-props/TableProps.tsx +86 -0
- package/src/components/plugins/@antd/items/TableRender.tsx +95 -21
|
@@ -203,16 +203,20 @@ export declare const schema: {
|
|
|
203
203
|
children: {
|
|
204
204
|
type: string;
|
|
205
205
|
name: string;
|
|
206
|
+
datasource: {
|
|
207
|
+
source: string;
|
|
208
|
+
custom: string;
|
|
209
|
+
};
|
|
206
210
|
props: {
|
|
207
211
|
title: string;
|
|
208
212
|
size: string;
|
|
209
213
|
bordered: boolean;
|
|
210
214
|
showHeader: boolean;
|
|
215
|
+
showSizeChanger: boolean;
|
|
216
|
+
showQuickJumper: boolean;
|
|
217
|
+
hideOnSinglePage: boolean;
|
|
218
|
+
showTotal: boolean;
|
|
211
219
|
pageSize: number;
|
|
212
|
-
dataSource: {
|
|
213
|
-
name: string;
|
|
214
|
-
count: number;
|
|
215
|
-
}[];
|
|
216
220
|
columns: {
|
|
217
221
|
title: string;
|
|
218
222
|
dataIndex: string;
|
|
@@ -3,6 +3,7 @@ export type Signal = string | number;
|
|
|
3
3
|
type Props = {
|
|
4
4
|
item: SchemaItemType;
|
|
5
5
|
signal?: Signal;
|
|
6
|
+
query?: Record<string, any>;
|
|
6
7
|
};
|
|
7
|
-
export declare const useDatasource: ({ item, signal }: Props) => any;
|
|
8
|
+
export declare const useDatasource: ({ item, signal, query }: Props) => any;
|
|
8
9
|
export {};
|
|
@@ -11,5 +11,14 @@ export type TableColumnModel = {
|
|
|
11
11
|
export type TableModel = {
|
|
12
12
|
pageSize?: number;
|
|
13
13
|
columns: TableColumnModel[];
|
|
14
|
+
dataKey?: string;
|
|
15
|
+
showSizeChanger?: boolean;
|
|
16
|
+
showQuickJumper?: boolean;
|
|
17
|
+
hideOnSinglePage?: boolean;
|
|
18
|
+
showTotal?: boolean;
|
|
19
|
+
headerCellClassNames?: string[];
|
|
20
|
+
bodyCellClassNames?: string[];
|
|
21
|
+
paginationRootClassNames?: string[];
|
|
22
|
+
paginationItemClassNames?: string[];
|
|
14
23
|
} & Pick<AntTableProps, "bordered" | "showHeader" | "size">;
|
|
15
24
|
export declare const TableProps: React.FC<PropEditorProps<TableModel>>;
|
|
@@ -2,12 +2,20 @@ import { type TableProps } from "antd";
|
|
|
2
2
|
import React from "react";
|
|
3
3
|
import { HtmlBaseProps } from "../../../typing";
|
|
4
4
|
export type TableRenderProps = {
|
|
5
|
-
dataSource?: any[];
|
|
6
5
|
columns?: any[];
|
|
6
|
+
dataKey?: string;
|
|
7
7
|
pageSize?: number;
|
|
8
8
|
bordered?: boolean;
|
|
9
9
|
size?: TableProps["size"];
|
|
10
10
|
showHeader?: boolean;
|
|
11
11
|
item: any;
|
|
12
|
+
showSizeChanger?: boolean;
|
|
13
|
+
showQuickJumper?: boolean;
|
|
14
|
+
hideOnSinglePage?: boolean;
|
|
15
|
+
showTotal?: boolean;
|
|
16
|
+
headerCellClassNames?: string[];
|
|
17
|
+
bodyCellClassNames?: string[];
|
|
18
|
+
paginationRootClassNames?: string[];
|
|
19
|
+
paginationItemClassNames?: string[];
|
|
12
20
|
} & HtmlBaseProps;
|
|
13
21
|
export declare const TableRender: React.FC<TableRenderProps>;
|