@pisell/materials 1.0.616 → 1.0.617
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/build/lowcode/assets-daily.json +11 -11
- package/build/lowcode/assets-dev.json +2 -2
- package/build/lowcode/assets-prod.json +11 -11
- package/build/lowcode/index.js +1 -1
- package/build/lowcode/meta.js +1 -1
- package/build/lowcode/preview.js +12 -20
- package/build/lowcode/render/default/view.js +14 -28
- package/build/lowcode/view.js +18 -32
- package/es/components/Pagination/index.d.ts +1 -1
- package/es/components/dataSourceComponents/dataSourceTable/hooks/useFormat.js +2 -1
- package/es/components/dataSourceComponents/dataSourceTable/hooks/useTableProps.d.ts +3 -3
- package/es/components/dataSourceComponents/fields/index.d.ts +1 -1
- package/lib/components/Pagination/index.d.ts +1 -1
- package/lib/components/dataSourceComponents/dataSourceTable/hooks/useFormat.js +2 -1
- package/lib/components/dataSourceComponents/dataSourceTable/hooks/useTableProps.d.ts +3 -3
- package/lib/components/dataSourceComponents/fields/index.d.ts +1 -1
- package/package.json +3 -3
|
@@ -5,7 +5,7 @@ export declare const paginationConfig: {
|
|
|
5
5
|
className: string;
|
|
6
6
|
defaultCurrent: number;
|
|
7
7
|
showTotal: (total: number, range: [number, number]) => string;
|
|
8
|
-
itemRender: (page: number, type: "
|
|
8
|
+
itemRender: (page: number, type: "next" | "page" | "prev" | "jump-prev" | "jump-next", element: React.ReactNode) => React.ReactNode;
|
|
9
9
|
responsive: boolean;
|
|
10
10
|
size: string;
|
|
11
11
|
};
|
|
@@ -131,10 +131,11 @@ var useFormat = function useFormat(_ref4) {
|
|
|
131
131
|
};
|
|
132
132
|
}
|
|
133
133
|
if (dataSourceKey === 'mypisell-api' && 'list' in res && 'skip' in res) {
|
|
134
|
+
var skip = typeof res.skip === 'number' ? res.skip : 1;
|
|
134
135
|
return {
|
|
135
136
|
data: res.list,
|
|
136
137
|
count: res.count,
|
|
137
|
-
page:
|
|
138
|
+
page: skip - 1 || 1,
|
|
138
139
|
pageSize: res.size
|
|
139
140
|
};
|
|
140
141
|
}
|
|
@@ -17,7 +17,7 @@ interface UseTablePropsProps {
|
|
|
17
17
|
* @returns
|
|
18
18
|
*/
|
|
19
19
|
declare const useTableProps: (props: UseTablePropsProps) => {
|
|
20
|
-
title: number | boolean | React.
|
|
20
|
+
title: number | boolean | Iterable<React.ReactNode> | React.JSX.Element | (() => React.ReactNode) | null | undefined;
|
|
21
21
|
pagination: {
|
|
22
22
|
total: number;
|
|
23
23
|
current: number;
|
|
@@ -26,7 +26,7 @@ declare const useTableProps: (props: UseTablePropsProps) => {
|
|
|
26
26
|
showSizeChanger: boolean;
|
|
27
27
|
};
|
|
28
28
|
columns: import("./useColumns").Column[];
|
|
29
|
-
subTitle: number | boolean | React.
|
|
29
|
+
subTitle: number | boolean | Iterable<React.ReactNode> | React.JSX.Element | (() => React.ReactNode) | null | undefined;
|
|
30
30
|
buttons: any[] | null;
|
|
31
31
|
filter: React.JSX.Element | null;
|
|
32
32
|
onRow: (record: any) => any;
|
|
@@ -47,7 +47,7 @@ declare const useTableProps: (props: UseTablePropsProps) => {
|
|
|
47
47
|
width: number;
|
|
48
48
|
align: "center" | "left" | "right";
|
|
49
49
|
fixed: false | "left" | "right";
|
|
50
|
-
type: "
|
|
50
|
+
type: "button" | "link";
|
|
51
51
|
items: OperationItem[];
|
|
52
52
|
} | undefined;
|
|
53
53
|
operationContent?: {
|
|
@@ -59,7 +59,7 @@ declare const formFieldMap: {
|
|
|
59
59
|
FormItemTranslation: import("react").FC<import("./Translation/type").TranslationProps & import("../dataSourceForm/utils").WithModeProps & import("../dataSourceForm/utils").WithFormItemProps>;
|
|
60
60
|
FormItemIconSelect: import("react").FC<import("./IconSelect/type").IconSelectProps & import("../dataSourceForm/utils").WithModeProps & import("../dataSourceForm/utils").WithFormItemProps>;
|
|
61
61
|
};
|
|
62
|
-
declare const getFieldComponent: (fieldComponent: string) => import("react").FC<
|
|
62
|
+
declare const getFieldComponent: (fieldComponent: string) => import("react").FC<import("./Checkbox/type").CheckboxGroupProps & import("../dataSourceForm/utils").WithModeProps> | import("react").FC<any> | (import("react").FC<{}> & {
|
|
63
63
|
Group: import("react").FC<import("./Checkbox/type").CheckboxGroupProps & import("../dataSourceForm/utils").WithModeProps>;
|
|
64
64
|
} & {
|
|
65
65
|
Group: import("react").FC<import("./Checkbox/type").CheckboxGroupProps & import("../dataSourceForm/utils").WithModeProps>;
|
|
@@ -5,7 +5,7 @@ export declare const paginationConfig: {
|
|
|
5
5
|
className: string;
|
|
6
6
|
defaultCurrent: number;
|
|
7
7
|
showTotal: (total: number, range: [number, number]) => string;
|
|
8
|
-
itemRender: (page: number, type: "
|
|
8
|
+
itemRender: (page: number, type: "next" | "page" | "prev" | "jump-prev" | "jump-next", element: React.ReactNode) => React.ReactNode;
|
|
9
9
|
responsive: boolean;
|
|
10
10
|
size: string;
|
|
11
11
|
};
|
|
@@ -131,10 +131,11 @@ var useFormat = ({ dataSourceKey, fields }) => {
|
|
|
131
131
|
};
|
|
132
132
|
}
|
|
133
133
|
if (dataSourceKey === "mypisell-api" && "list" in res && "skip" in res) {
|
|
134
|
+
const skip = typeof res.skip === "number" ? res.skip : 1;
|
|
134
135
|
return {
|
|
135
136
|
data: res.list,
|
|
136
137
|
count: res.count,
|
|
137
|
-
page:
|
|
138
|
+
page: skip - 1 || 1,
|
|
138
139
|
pageSize: res.size
|
|
139
140
|
};
|
|
140
141
|
}
|
|
@@ -17,7 +17,7 @@ interface UseTablePropsProps {
|
|
|
17
17
|
* @returns
|
|
18
18
|
*/
|
|
19
19
|
declare const useTableProps: (props: UseTablePropsProps) => {
|
|
20
|
-
title: number | boolean | React.
|
|
20
|
+
title: number | boolean | Iterable<React.ReactNode> | React.JSX.Element | (() => React.ReactNode) | null | undefined;
|
|
21
21
|
pagination: {
|
|
22
22
|
total: number;
|
|
23
23
|
current: number;
|
|
@@ -26,7 +26,7 @@ declare const useTableProps: (props: UseTablePropsProps) => {
|
|
|
26
26
|
showSizeChanger: boolean;
|
|
27
27
|
};
|
|
28
28
|
columns: import("./useColumns").Column[];
|
|
29
|
-
subTitle: number | boolean | React.
|
|
29
|
+
subTitle: number | boolean | Iterable<React.ReactNode> | React.JSX.Element | (() => React.ReactNode) | null | undefined;
|
|
30
30
|
buttons: any[] | null;
|
|
31
31
|
filter: React.JSX.Element | null;
|
|
32
32
|
onRow: (record: any) => any;
|
|
@@ -47,7 +47,7 @@ declare const useTableProps: (props: UseTablePropsProps) => {
|
|
|
47
47
|
width: number;
|
|
48
48
|
align: "center" | "left" | "right";
|
|
49
49
|
fixed: false | "left" | "right";
|
|
50
|
-
type: "
|
|
50
|
+
type: "button" | "link";
|
|
51
51
|
items: OperationItem[];
|
|
52
52
|
} | undefined;
|
|
53
53
|
operationContent?: {
|
|
@@ -59,7 +59,7 @@ declare const formFieldMap: {
|
|
|
59
59
|
FormItemTranslation: import("react").FC<import("./Translation/type").TranslationProps & import("../dataSourceForm/utils").WithModeProps & import("../dataSourceForm/utils").WithFormItemProps>;
|
|
60
60
|
FormItemIconSelect: import("react").FC<import("./IconSelect/type").IconSelectProps & import("../dataSourceForm/utils").WithModeProps & import("../dataSourceForm/utils").WithFormItemProps>;
|
|
61
61
|
};
|
|
62
|
-
declare const getFieldComponent: (fieldComponent: string) => import("react").FC<
|
|
62
|
+
declare const getFieldComponent: (fieldComponent: string) => import("react").FC<import("./Checkbox/type").CheckboxGroupProps & import("../dataSourceForm/utils").WithModeProps> | import("react").FC<any> | (import("react").FC<{}> & {
|
|
63
63
|
Group: import("react").FC<import("./Checkbox/type").CheckboxGroupProps & import("../dataSourceForm/utils").WithModeProps>;
|
|
64
64
|
} & {
|
|
65
65
|
Group: import("react").FC<import("./Checkbox/type").CheckboxGroupProps & import("../dataSourceForm/utils").WithModeProps>;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@pisell/materials",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.617",
|
|
4
4
|
"main": "./lib/index.js",
|
|
5
5
|
"module": "./es/index.js",
|
|
6
6
|
"types": "./lib/index.d.ts",
|
|
@@ -69,9 +69,9 @@
|
|
|
69
69
|
"libphonenumber-js": "^1.11.17",
|
|
70
70
|
"swiper": "^8.4.7",
|
|
71
71
|
"react-barcode": "^1.5.3",
|
|
72
|
-
"@pisell/
|
|
72
|
+
"@pisell/date-picker": "1.0.115",
|
|
73
73
|
"@pisell/utils": "1.0.43",
|
|
74
|
-
"@pisell/
|
|
74
|
+
"@pisell/icon": "0.0.10"
|
|
75
75
|
},
|
|
76
76
|
"peerDependencies": {
|
|
77
77
|
"react": "^18.0.0",
|