xph-crud 0.0.7 → 0.0.9
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/index.js +2275 -2101
- package/dist/index.umd.cjs +9 -9
- package/dist/types/common/src/componnets/dialog/hooks/index.d.ts +4 -0
- package/dist/types/common/src/componnets/dialog/hooks/useDialogActions.d.ts +2 -2
- package/dist/types/common/src/componnets/dialog/hooks/useDialogPosition.d.ts +3 -2
- package/dist/types/common/src/componnets/dialog/hooks/useDialogSize.d.ts +7 -11
- package/dist/types/common/src/componnets/dialog/hooks/useOnContainerSizeChange.d.ts +22 -0
- package/dist/types/common/src/componnets/dialog/hooks/useOnPropsSizeChange.d.ts +3 -3
- package/dist/types/common/src/componnets/dialog/hooks/useOnVisableChange.d.ts +21 -0
- package/dist/types/common/src/componnets/dialog/hooks/useResizeDialog.d.ts +5 -2
- package/dist/types/common/src/componnets/dialog/types/dialog.d.ts +1 -1
- package/dist/types/common/src/hooks/index.d.ts +2 -1
- package/dist/types/common/src/hooks/useAsyncState.d.ts +6 -0
- package/dist/types/common/src/utils/getValueByPath.d.ts +9 -0
- package/dist/types/common/src/utils/index.d.ts +1 -0
- package/dist/types/table/src/types/crudFormDialog.d.ts +1 -0
- package/package.json +63 -63
|
@@ -1,9 +1,12 @@
|
|
|
1
1
|
import { MouseEvent } from 'react';
|
|
2
2
|
|
|
3
|
-
declare const useResizeDialog: ({
|
|
4
|
-
visible: boolean;
|
|
3
|
+
declare const useResizeDialog: ({ container, dialogRef, minResizeRecord, setDialogSize, setDialogPosition, }: {
|
|
5
4
|
container: HTMLElement;
|
|
6
5
|
dialogRef: React.RefObject<HTMLDivElement>;
|
|
6
|
+
minResizeRecord: React.MutableRefObject<{
|
|
7
|
+
width: number;
|
|
8
|
+
height: number;
|
|
9
|
+
} | null>;
|
|
7
10
|
setDialogSize: (size: {
|
|
8
11
|
width: number | string;
|
|
9
12
|
height: number | string;
|
|
@@ -1,3 +1,4 @@
|
|
|
1
1
|
import { IExtendProps as IXphExtendProps, IExtendComponentProps as IXphExtendComponentProps, ExtendCompPropsProvider as XphExtendCompPropsProvider, useExtendCompProps as useXphExtendCompProps } from './useExtendCompProps';
|
|
2
|
+
import { useAsyncState } from './useAsyncState';
|
|
2
3
|
|
|
3
|
-
export { IXphExtendProps, IXphExtendComponentProps, XphExtendCompPropsProvider, useXphExtendCompProps, };
|
|
4
|
+
export { IXphExtendProps, IXphExtendComponentProps, XphExtendCompPropsProvider, useXphExtendCompProps, useAsyncState, };
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
export declare const getValueByPath: (obj: Record<string, any>, path: string) => any;
|
|
2
|
+
/**
|
|
3
|
+
* @description 通过属性为包含.的字符串的对象从值对象中获取值
|
|
4
|
+
* @param fields = { current: 'data.current', pageSize: 'data.pageSize' }
|
|
5
|
+
* @param values = { data: { current: 1, pageSize: 10 } }
|
|
6
|
+
* @returns = { current: 1, pageSize: 10 }
|
|
7
|
+
*
|
|
8
|
+
*/
|
|
9
|
+
export declare const getValuesByPathObj: (fields: Record<string, string>, values: Record<string, any>) => Record<string, any>;
|
package/package.json
CHANGED
|
@@ -1,63 +1,63 @@
|
|
|
1
|
-
{
|
|
2
|
-
"name": "xph-crud",
|
|
3
|
-
"version": "0.0.
|
|
4
|
-
"type": "module",
|
|
5
|
-
"main": "dist/index.js",
|
|
6
|
-
"types": "dist/types/index.d.ts",
|
|
7
|
-
"description": "This is a configurable component library based on React",
|
|
8
|
-
"keywords": [
|
|
9
|
-
"react",
|
|
10
|
-
"ant-design",
|
|
11
|
-
"configurable-component"
|
|
12
|
-
],
|
|
13
|
-
"
|
|
14
|
-
"
|
|
15
|
-
"
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
"
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
"
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
"
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
"
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
"
|
|
32
|
-
"
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
"
|
|
36
|
-
"
|
|
37
|
-
"
|
|
38
|
-
"
|
|
39
|
-
"
|
|
40
|
-
"
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
"
|
|
47
|
-
"
|
|
48
|
-
},
|
|
49
|
-
"
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
"
|
|
55
|
-
},
|
|
56
|
-
"
|
|
57
|
-
"
|
|
58
|
-
"
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
"
|
|
62
|
-
}
|
|
63
|
-
}
|
|
1
|
+
{
|
|
2
|
+
"name": "xph-crud",
|
|
3
|
+
"version": "0.0.9",
|
|
4
|
+
"type": "module",
|
|
5
|
+
"main": "dist/index.js",
|
|
6
|
+
"types": "dist/types/index.d.ts",
|
|
7
|
+
"description": "This is a configurable component library based on React",
|
|
8
|
+
"keywords": [
|
|
9
|
+
"react",
|
|
10
|
+
"ant-design",
|
|
11
|
+
"configurable-component"
|
|
12
|
+
],
|
|
13
|
+
"files": [
|
|
14
|
+
"dist",
|
|
15
|
+
"README.md"
|
|
16
|
+
],
|
|
17
|
+
"peerDependencies": {
|
|
18
|
+
"@ant-design/icons": "5.3.2",
|
|
19
|
+
"antd": "^5.14.2",
|
|
20
|
+
"react": "^18.2.0",
|
|
21
|
+
"react-dom": "^18.2.0"
|
|
22
|
+
},
|
|
23
|
+
"dependencies": {
|
|
24
|
+
"dayjs": "^1.11.10",
|
|
25
|
+
"lodash-es": "^4.17.21"
|
|
26
|
+
},
|
|
27
|
+
"devDependencies": {
|
|
28
|
+
"@types/lodash-es": "^4.17.12",
|
|
29
|
+
"@types/node": "^20.14.2",
|
|
30
|
+
"@types/react": "^18.2.66",
|
|
31
|
+
"@types/react-dom": "^18.2.22",
|
|
32
|
+
"@typescript-eslint/eslint-plugin": "^7.2.0",
|
|
33
|
+
"@typescript-eslint/parser": "^7.2.0",
|
|
34
|
+
"@vitejs/plugin-react": "^4.2.1",
|
|
35
|
+
"eslint": "^8.57.0",
|
|
36
|
+
"eslint-plugin-react-hooks": "^4.6.0",
|
|
37
|
+
"eslint-plugin-react-refresh": "^0.4.6",
|
|
38
|
+
"typescript": "^5.2.2",
|
|
39
|
+
"vite": "^5.2.0",
|
|
40
|
+
"vite-plugin-dts": "^3.9.1"
|
|
41
|
+
},
|
|
42
|
+
"license": "ISC",
|
|
43
|
+
"author": "XiaoPiHong",
|
|
44
|
+
"homepage": "https://github.com/XiaoPiHong/xph-crud",
|
|
45
|
+
"bugs": {
|
|
46
|
+
"url": "https://github.com/XiaoPiHong/xph-crud/issues",
|
|
47
|
+
"email": "260094892@qq.com"
|
|
48
|
+
},
|
|
49
|
+
"repository": {
|
|
50
|
+
"type": "git",
|
|
51
|
+
"url": "https://github.com/XiaoPiHong/xph-crud.git"
|
|
52
|
+
},
|
|
53
|
+
"engines": {
|
|
54
|
+
"node": ">=16"
|
|
55
|
+
},
|
|
56
|
+
"scripts": {
|
|
57
|
+
"examples": "vite",
|
|
58
|
+
"build": "tsc && vite build",
|
|
59
|
+
"docs": "cd docs && npm run start",
|
|
60
|
+
"build:docs": "cd docs && npm run build",
|
|
61
|
+
"lint": "eslint . --ext ts,tsx --report-unused-disable-directives --max-warnings 0"
|
|
62
|
+
}
|
|
63
|
+
}
|