@fctc/widget-logic 1.4.0 → 1.4.2
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/config.d.mts +6 -0
- package/dist/config.d.ts +6 -0
- package/dist/config.js +24 -0
- package/dist/config.mjs +2 -0
- package/dist/constants.d.mts +1 -0
- package/dist/constants.d.ts +1 -0
- package/dist/constants.js +24 -0
- package/dist/constants.mjs +2 -0
- package/dist/environment.d.mts +1 -0
- package/dist/environment.d.ts +1 -0
- package/dist/environment.js +24 -0
- package/dist/environment.mjs +2 -0
- package/dist/hooks.d.mts +969 -0
- package/dist/hooks.d.ts +969 -0
- package/dist/hooks.js +743 -0
- package/dist/hooks.mjs +717 -0
- package/dist/icons.d.mts +9 -0
- package/dist/icons.d.ts +9 -0
- package/dist/icons.js +139 -0
- package/dist/icons.mjs +110 -0
- package/dist/index.d.mts +15 -4
- package/dist/index.d.ts +15 -4
- package/dist/index.js +7227 -230
- package/dist/index.mjs +7312 -218
- package/dist/provider.d.mts +1 -0
- package/dist/provider.d.ts +1 -0
- package/dist/provider.js +24 -0
- package/dist/provider.mjs +2 -0
- package/dist/services.d.mts +1 -0
- package/dist/services.d.ts +1 -0
- package/dist/services.js +24 -0
- package/dist/services.mjs +2 -0
- package/dist/store.d.mts +1 -0
- package/dist/store.d.ts +1 -0
- package/dist/store.js +24 -0
- package/dist/store.mjs +2 -0
- package/dist/utils.d.mts +38 -0
- package/dist/utils.d.ts +38 -0
- package/dist/utils.js +282 -0
- package/dist/utils.mjs +242 -0
- package/dist/widget.d.mts +325 -0
- package/dist/widget.d.ts +325 -0
- package/dist/widget.js +7079 -0
- package/dist/widget.mjs +7111 -0
- package/package.json +64 -23
- package/dist/action.d.mts +0 -68
- package/dist/action.d.ts +0 -68
- package/dist/action.js +0 -152
- package/dist/action.mjs +0 -122
- package/dist/common.d.mts +0 -13
- package/dist/common.d.ts +0 -13
- package/dist/common.js +0 -60
- package/dist/common.mjs +0 -33
- package/dist/form.d.mts +0 -41
- package/dist/form.d.ts +0 -41
- package/dist/form.js +0 -116
- package/dist/form.mjs +0 -87
- package/dist/table.d.mts +0 -22
- package/dist/table.d.ts +0 -22
- package/dist/table.js +0 -118
- package/dist/table.mjs +0 -91
package/dist/icons.d.mts
ADDED
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
declare const EyeIcon: React.FC<React.SVGProps<SVGSVGElement>>;
|
|
2
|
+
|
|
3
|
+
declare const LoadingIcon: ({ width, height, ...props }: React.SVGProps<SVGSVGElement>) => JSX.Element;
|
|
4
|
+
|
|
5
|
+
declare const CloseIcon: ({ className }: {
|
|
6
|
+
className?: string;
|
|
7
|
+
}) => JSX.Element;
|
|
8
|
+
|
|
9
|
+
export { CloseIcon, EyeIcon, LoadingIcon };
|
package/dist/icons.d.ts
ADDED
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
declare const EyeIcon: React.FC<React.SVGProps<SVGSVGElement>>;
|
|
2
|
+
|
|
3
|
+
declare const LoadingIcon: ({ width, height, ...props }: React.SVGProps<SVGSVGElement>) => JSX.Element;
|
|
4
|
+
|
|
5
|
+
declare const CloseIcon: ({ className }: {
|
|
6
|
+
className?: string;
|
|
7
|
+
}) => JSX.Element;
|
|
8
|
+
|
|
9
|
+
export { CloseIcon, EyeIcon, LoadingIcon };
|
package/dist/icons.js
ADDED
|
@@ -0,0 +1,139 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __defProp = Object.defineProperty;
|
|
3
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
4
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
5
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
6
|
+
var __export = (target, all) => {
|
|
7
|
+
for (var name in all)
|
|
8
|
+
__defProp(target, name, { get: all[name], enumerable: true });
|
|
9
|
+
};
|
|
10
|
+
var __copyProps = (to, from, except, desc) => {
|
|
11
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
12
|
+
for (let key of __getOwnPropNames(from))
|
|
13
|
+
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
14
|
+
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
15
|
+
}
|
|
16
|
+
return to;
|
|
17
|
+
};
|
|
18
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
19
|
+
|
|
20
|
+
// src/icons.ts
|
|
21
|
+
var icons_exports = {};
|
|
22
|
+
__export(icons_exports, {
|
|
23
|
+
CloseIcon: () => CloseIcon,
|
|
24
|
+
EyeIcon: () => EyeIcon,
|
|
25
|
+
LoadingIcon: () => LoadingIcon
|
|
26
|
+
});
|
|
27
|
+
module.exports = __toCommonJS(icons_exports);
|
|
28
|
+
|
|
29
|
+
// src/icons/eye-icon.tsx
|
|
30
|
+
var import_jsx_runtime = require("react/jsx-runtime");
|
|
31
|
+
var EyeIcon = () => /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(
|
|
32
|
+
"svg",
|
|
33
|
+
{
|
|
34
|
+
width: "20",
|
|
35
|
+
height: "21",
|
|
36
|
+
viewBox: "0 0 20 21",
|
|
37
|
+
fill: "none",
|
|
38
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
39
|
+
children: [
|
|
40
|
+
/* @__PURE__ */ (0, import_jsx_runtime.jsx)(
|
|
41
|
+
"path",
|
|
42
|
+
{
|
|
43
|
+
d: "M2.72904 13.5776C2.02076 12.6574 1.66663 12.1974 1.66663 10.8312C1.66663 9.46507 2.02076 9.00499 2.72904 8.08483C4.14326 6.24752 6.51505 4.16455 9.99996 4.16455C13.4849 4.16455 15.8567 6.24752 17.2709 8.08483C17.9792 9.00499 18.3333 9.46507 18.3333 10.8312C18.3333 12.1974 17.9792 12.6574 17.2709 13.5776C15.8567 15.4149 13.4849 17.4979 9.99996 17.4979C6.51505 17.4979 4.14326 15.4149 2.72904 13.5776Z",
|
|
44
|
+
stroke: "#ABACAE",
|
|
45
|
+
strokeWidth: "1.5"
|
|
46
|
+
}
|
|
47
|
+
),
|
|
48
|
+
/* @__PURE__ */ (0, import_jsx_runtime.jsx)(
|
|
49
|
+
"path",
|
|
50
|
+
{
|
|
51
|
+
d: "M12.5 10.8311C12.5 12.2118 11.3807 13.3311 10 13.3311C8.61929 13.3311 7.5 12.2118 7.5 10.8311C7.5 9.45034 8.61929 8.33105 10 8.33105C11.3807 8.33105 12.5 9.45034 12.5 10.8311Z",
|
|
52
|
+
stroke: "#ABACAE",
|
|
53
|
+
strokeWidth: "1.5"
|
|
54
|
+
}
|
|
55
|
+
)
|
|
56
|
+
]
|
|
57
|
+
}
|
|
58
|
+
);
|
|
59
|
+
|
|
60
|
+
// src/icons/loading-icon.tsx
|
|
61
|
+
var import_jsx_runtime2 = require("react/jsx-runtime");
|
|
62
|
+
var LoadingIcon = ({
|
|
63
|
+
width = 15,
|
|
64
|
+
height = 15,
|
|
65
|
+
...props
|
|
66
|
+
}) => {
|
|
67
|
+
return /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(
|
|
68
|
+
"svg",
|
|
69
|
+
{
|
|
70
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
71
|
+
xmlnsXlink: "http://www.w3.org/1999/xlink",
|
|
72
|
+
viewBox: "0 0 100 100",
|
|
73
|
+
preserveAspectRatio: "xMidYMid",
|
|
74
|
+
width,
|
|
75
|
+
height,
|
|
76
|
+
style: {
|
|
77
|
+
shapeRendering: "auto",
|
|
78
|
+
display: "block",
|
|
79
|
+
background: "transparent"
|
|
80
|
+
},
|
|
81
|
+
...props,
|
|
82
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime2.jsxs)("g", { children: [
|
|
83
|
+
/* @__PURE__ */ (0, import_jsx_runtime2.jsx)(
|
|
84
|
+
"circle",
|
|
85
|
+
{
|
|
86
|
+
strokeDasharray: "141.37166941154067 49.12388980384689",
|
|
87
|
+
r: "30",
|
|
88
|
+
strokeWidth: "10",
|
|
89
|
+
stroke: "currentColor",
|
|
90
|
+
fill: "none",
|
|
91
|
+
cy: "50",
|
|
92
|
+
cx: "50",
|
|
93
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(
|
|
94
|
+
"animateTransform",
|
|
95
|
+
{
|
|
96
|
+
keyTimes: "0;1",
|
|
97
|
+
values: "0 50 50;360 50 50",
|
|
98
|
+
dur: "0.5050505050505051s",
|
|
99
|
+
repeatCount: "indefinite",
|
|
100
|
+
type: "rotate",
|
|
101
|
+
attributeName: "transform"
|
|
102
|
+
}
|
|
103
|
+
)
|
|
104
|
+
}
|
|
105
|
+
),
|
|
106
|
+
/* @__PURE__ */ (0, import_jsx_runtime2.jsx)("g", {})
|
|
107
|
+
] })
|
|
108
|
+
}
|
|
109
|
+
);
|
|
110
|
+
};
|
|
111
|
+
|
|
112
|
+
// src/icons/close-icon.tsx
|
|
113
|
+
var import_jsx_runtime3 = require("react/jsx-runtime");
|
|
114
|
+
var CloseIcon = ({ className = "" }) => {
|
|
115
|
+
return /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(
|
|
116
|
+
"svg",
|
|
117
|
+
{
|
|
118
|
+
width: "24",
|
|
119
|
+
height: "24",
|
|
120
|
+
viewBox: "0 0 24 24",
|
|
121
|
+
fill: "none",
|
|
122
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
123
|
+
className,
|
|
124
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(
|
|
125
|
+
"path",
|
|
126
|
+
{
|
|
127
|
+
d: "M12.0001 10.7275L16.4551 6.27246L17.7277 7.54506L13.2727 12.0001L17.7277 16.4551L16.4551 17.7277L12.0001 13.2727L7.54506 17.7277L6.27246 16.4551L10.7275 12.0001L6.27246 7.54506L7.54506 6.27246L12.0001 10.7275Z",
|
|
128
|
+
fill: "#A4A4A4"
|
|
129
|
+
}
|
|
130
|
+
)
|
|
131
|
+
}
|
|
132
|
+
);
|
|
133
|
+
};
|
|
134
|
+
// Annotate the CommonJS export names for ESM import in node:
|
|
135
|
+
0 && (module.exports = {
|
|
136
|
+
CloseIcon,
|
|
137
|
+
EyeIcon,
|
|
138
|
+
LoadingIcon
|
|
139
|
+
});
|
package/dist/icons.mjs
ADDED
|
@@ -0,0 +1,110 @@
|
|
|
1
|
+
// src/icons/eye-icon.tsx
|
|
2
|
+
import { jsx, jsxs } from "react/jsx-runtime";
|
|
3
|
+
var EyeIcon = () => /* @__PURE__ */ jsxs(
|
|
4
|
+
"svg",
|
|
5
|
+
{
|
|
6
|
+
width: "20",
|
|
7
|
+
height: "21",
|
|
8
|
+
viewBox: "0 0 20 21",
|
|
9
|
+
fill: "none",
|
|
10
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
11
|
+
children: [
|
|
12
|
+
/* @__PURE__ */ jsx(
|
|
13
|
+
"path",
|
|
14
|
+
{
|
|
15
|
+
d: "M2.72904 13.5776C2.02076 12.6574 1.66663 12.1974 1.66663 10.8312C1.66663 9.46507 2.02076 9.00499 2.72904 8.08483C4.14326 6.24752 6.51505 4.16455 9.99996 4.16455C13.4849 4.16455 15.8567 6.24752 17.2709 8.08483C17.9792 9.00499 18.3333 9.46507 18.3333 10.8312C18.3333 12.1974 17.9792 12.6574 17.2709 13.5776C15.8567 15.4149 13.4849 17.4979 9.99996 17.4979C6.51505 17.4979 4.14326 15.4149 2.72904 13.5776Z",
|
|
16
|
+
stroke: "#ABACAE",
|
|
17
|
+
strokeWidth: "1.5"
|
|
18
|
+
}
|
|
19
|
+
),
|
|
20
|
+
/* @__PURE__ */ jsx(
|
|
21
|
+
"path",
|
|
22
|
+
{
|
|
23
|
+
d: "M12.5 10.8311C12.5 12.2118 11.3807 13.3311 10 13.3311C8.61929 13.3311 7.5 12.2118 7.5 10.8311C7.5 9.45034 8.61929 8.33105 10 8.33105C11.3807 8.33105 12.5 9.45034 12.5 10.8311Z",
|
|
24
|
+
stroke: "#ABACAE",
|
|
25
|
+
strokeWidth: "1.5"
|
|
26
|
+
}
|
|
27
|
+
)
|
|
28
|
+
]
|
|
29
|
+
}
|
|
30
|
+
);
|
|
31
|
+
|
|
32
|
+
// src/icons/loading-icon.tsx
|
|
33
|
+
import { jsx as jsx2, jsxs as jsxs2 } from "react/jsx-runtime";
|
|
34
|
+
var LoadingIcon = ({
|
|
35
|
+
width = 15,
|
|
36
|
+
height = 15,
|
|
37
|
+
...props
|
|
38
|
+
}) => {
|
|
39
|
+
return /* @__PURE__ */ jsx2(
|
|
40
|
+
"svg",
|
|
41
|
+
{
|
|
42
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
43
|
+
xmlnsXlink: "http://www.w3.org/1999/xlink",
|
|
44
|
+
viewBox: "0 0 100 100",
|
|
45
|
+
preserveAspectRatio: "xMidYMid",
|
|
46
|
+
width,
|
|
47
|
+
height,
|
|
48
|
+
style: {
|
|
49
|
+
shapeRendering: "auto",
|
|
50
|
+
display: "block",
|
|
51
|
+
background: "transparent"
|
|
52
|
+
},
|
|
53
|
+
...props,
|
|
54
|
+
children: /* @__PURE__ */ jsxs2("g", { children: [
|
|
55
|
+
/* @__PURE__ */ jsx2(
|
|
56
|
+
"circle",
|
|
57
|
+
{
|
|
58
|
+
strokeDasharray: "141.37166941154067 49.12388980384689",
|
|
59
|
+
r: "30",
|
|
60
|
+
strokeWidth: "10",
|
|
61
|
+
stroke: "currentColor",
|
|
62
|
+
fill: "none",
|
|
63
|
+
cy: "50",
|
|
64
|
+
cx: "50",
|
|
65
|
+
children: /* @__PURE__ */ jsx2(
|
|
66
|
+
"animateTransform",
|
|
67
|
+
{
|
|
68
|
+
keyTimes: "0;1",
|
|
69
|
+
values: "0 50 50;360 50 50",
|
|
70
|
+
dur: "0.5050505050505051s",
|
|
71
|
+
repeatCount: "indefinite",
|
|
72
|
+
type: "rotate",
|
|
73
|
+
attributeName: "transform"
|
|
74
|
+
}
|
|
75
|
+
)
|
|
76
|
+
}
|
|
77
|
+
),
|
|
78
|
+
/* @__PURE__ */ jsx2("g", {})
|
|
79
|
+
] })
|
|
80
|
+
}
|
|
81
|
+
);
|
|
82
|
+
};
|
|
83
|
+
|
|
84
|
+
// src/icons/close-icon.tsx
|
|
85
|
+
import { jsx as jsx3 } from "react/jsx-runtime";
|
|
86
|
+
var CloseIcon = ({ className = "" }) => {
|
|
87
|
+
return /* @__PURE__ */ jsx3(
|
|
88
|
+
"svg",
|
|
89
|
+
{
|
|
90
|
+
width: "24",
|
|
91
|
+
height: "24",
|
|
92
|
+
viewBox: "0 0 24 24",
|
|
93
|
+
fill: "none",
|
|
94
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
95
|
+
className,
|
|
96
|
+
children: /* @__PURE__ */ jsx3(
|
|
97
|
+
"path",
|
|
98
|
+
{
|
|
99
|
+
d: "M12.0001 10.7275L16.4551 6.27246L17.7277 7.54506L13.2727 12.0001L17.7277 16.4551L16.4551 17.7277L12.0001 13.2727L7.54506 17.7277L6.27246 16.4551L10.7275 12.0001L6.27246 7.54506L7.54506 6.27246L12.0001 10.7275Z",
|
|
100
|
+
fill: "#A4A4A4"
|
|
101
|
+
}
|
|
102
|
+
)
|
|
103
|
+
}
|
|
104
|
+
);
|
|
105
|
+
};
|
|
106
|
+
export {
|
|
107
|
+
CloseIcon,
|
|
108
|
+
EyeIcon,
|
|
109
|
+
LoadingIcon
|
|
110
|
+
};
|
package/dist/index.d.mts
CHANGED
|
@@ -1,5 +1,16 @@
|
|
|
1
|
-
export {
|
|
2
|
-
export
|
|
3
|
-
export
|
|
4
|
-
export {
|
|
1
|
+
export { ActionResultType, AppProvider, ContextProfile, Record, ViewResponse, useAppProvider, useAuth, useAuthType, useCallAction, useCallActionType, useClickOutside, useConfig, useConfigType, useDebounce, useDetail, useListData, useListDataType, useMenu, useMenuType, useProfile, useUser, useUserType, useViewV2, useViewV2Type } from './hooks.mjs';
|
|
2
|
+
export * from '@fctc/interface-logic/hooks';
|
|
3
|
+
export * from '@fctc/interface-logic/configs';
|
|
4
|
+
export { CloseIcon, EyeIcon, LoadingIcon } from './icons.mjs';
|
|
5
|
+
export { ISelctionStateProps, ITableBodyProps, ITableHeadProps, ITableProps, binaryFieldController, colorFieldController, copyLinkButtonController, dateFieldController, downLoadBinaryController, downloadFileController, durationController, floatController, floatTimeFiledController, many2manyFieldController, many2manyTagsController, many2oneButtonController, many2oneFieldController, priorityFieldController, statusDropdownController, tableBodyController, tableController, tableGroupController, tableHeadController } from './widget.mjs';
|
|
6
|
+
export { API_APP_URL, API_PRESCHOOL_URL, STORAGES, combineContexts, convertFieldsToArray, countSum, getDateRange, languages, mergeButtons, setStorageItemAsync, useGetRowIds, useStorageState } from './utils.mjs';
|
|
7
|
+
export * from '@fctc/interface-logic/utils';
|
|
8
|
+
export * from '@fctc/interface-logic/store';
|
|
9
|
+
export * from '@fctc/interface-logic/constants';
|
|
10
|
+
export * from '@fctc/interface-logic/environment';
|
|
11
|
+
export * from '@fctc/interface-logic/provider';
|
|
12
|
+
export * from '@fctc/interface-logic/services';
|
|
13
|
+
import '@tanstack/react-query';
|
|
14
|
+
import '@tanstack/query-core';
|
|
5
15
|
import 'react';
|
|
16
|
+
import 'moment';
|
package/dist/index.d.ts
CHANGED
|
@@ -1,5 +1,16 @@
|
|
|
1
|
-
export {
|
|
2
|
-
export
|
|
3
|
-
export
|
|
4
|
-
export {
|
|
1
|
+
export { ActionResultType, AppProvider, ContextProfile, Record, ViewResponse, useAppProvider, useAuth, useAuthType, useCallAction, useCallActionType, useClickOutside, useConfig, useConfigType, useDebounce, useDetail, useListData, useListDataType, useMenu, useMenuType, useProfile, useUser, useUserType, useViewV2, useViewV2Type } from './hooks.js';
|
|
2
|
+
export * from '@fctc/interface-logic/hooks';
|
|
3
|
+
export * from '@fctc/interface-logic/configs';
|
|
4
|
+
export { CloseIcon, EyeIcon, LoadingIcon } from './icons.js';
|
|
5
|
+
export { ISelctionStateProps, ITableBodyProps, ITableHeadProps, ITableProps, binaryFieldController, colorFieldController, copyLinkButtonController, dateFieldController, downLoadBinaryController, downloadFileController, durationController, floatController, floatTimeFiledController, many2manyFieldController, many2manyTagsController, many2oneButtonController, many2oneFieldController, priorityFieldController, statusDropdownController, tableBodyController, tableController, tableGroupController, tableHeadController } from './widget.js';
|
|
6
|
+
export { API_APP_URL, API_PRESCHOOL_URL, STORAGES, combineContexts, convertFieldsToArray, countSum, getDateRange, languages, mergeButtons, setStorageItemAsync, useGetRowIds, useStorageState } from './utils.js';
|
|
7
|
+
export * from '@fctc/interface-logic/utils';
|
|
8
|
+
export * from '@fctc/interface-logic/store';
|
|
9
|
+
export * from '@fctc/interface-logic/constants';
|
|
10
|
+
export * from '@fctc/interface-logic/environment';
|
|
11
|
+
export * from '@fctc/interface-logic/provider';
|
|
12
|
+
export * from '@fctc/interface-logic/services';
|
|
13
|
+
import '@tanstack/react-query';
|
|
14
|
+
import '@tanstack/query-core';
|
|
5
15
|
import 'react';
|
|
16
|
+
import 'moment';
|