@pnkx-lib/ui 1.9.180 → 1.9.181
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/es/fields/CascaderField.js +5 -5
- package/es/fields/Checkbox.js +5 -5
- package/es/fields/DatePicker.js +5 -5
- package/es/fields/DateRangePicker.js +5 -5
- package/es/fields/Input.js +10 -10
- package/es/fields/PnkxField.js +3 -3
- package/es/fields/Radio.js +5 -5
- package/es/fields/Select.js +5 -5
- package/es/fields/SliderRanger.js +5 -5
- package/es/fields/SliderSingle.js +5 -5
- package/es/fields/Switch.js +5 -5
- package/es/fields/Textarea.js +5 -5
- package/es/fields/TinyMCE.js +5 -5
- package/es/fields/Upload.js +9 -9
- package/es/ui/Alert.js +2 -2
- package/es/ui/Anchor.js +2 -2
- package/es/ui/Appfix.js +2 -2
- package/es/ui/AutoComplete.js +2 -2
- package/es/ui/Badge.js +2 -2
- package/es/ui/BottomPagination.js +10 -10
- package/es/ui/Breadcrumb.js +2 -2
- package/es/ui/BreadcrumbHeading.js +5 -5
- package/es/ui/Button.js +2 -2
- package/es/ui/Card.js +2 -2
- package/es/ui/Cascader.js +2 -2
- package/es/ui/CategoryStatus.js +5 -5
- package/es/ui/Col.js +2 -2
- package/es/ui/Collapse.js +2 -2
- package/es/ui/ColorPicker.js +2 -2
- package/es/ui/ConfigProvider.js +2 -2
- package/es/ui/ConfirmModal.js +22 -22
- package/es/ui/Container.js +2 -2
- package/es/ui/Divider.js +2 -2
- package/es/ui/Drawer.js +2 -2
- package/es/ui/Dropdown.js +2 -2
- package/es/ui/Empty.js +2 -2
- package/es/ui/ErrorBoundary.js +9 -9
- package/es/ui/ErrorMessage.js +2 -2
- package/es/ui/Flex.js +2 -2
- package/es/ui/Footer.js +2 -2
- package/es/ui/Heading.js +7 -7
- package/es/ui/Image.js +2 -2
- package/es/ui/Label.js +4 -4
- package/es/ui/Layout.js +2 -2
- package/es/ui/Menu.js +4 -4
- package/es/ui/Modal.js +2 -2
- package/es/ui/PageNotFound.js +81 -81
- package/es/ui/Pagination.js +2 -2
- package/es/ui/Popconfirm.js +2 -2
- package/es/ui/Popover.js +2 -2
- package/es/ui/QRCode.js +2 -2
- package/es/ui/Rate.js +2 -2
- package/es/ui/Result.js +2 -2
- package/es/ui/Row.js +2 -2
- package/es/ui/SearchFilterForm.js +8 -8
- package/es/ui/Segmented.js +2 -2
- package/es/ui/Sidebar.js +31 -31
- package/es/ui/Skeleton.js +8 -8
- package/es/ui/Space.js +2 -2
- package/es/ui/Spin.js +2 -2
- package/es/ui/Splitter.js +2 -2
- package/es/ui/Statistic.js +2 -2
- package/es/ui/Steps.js +2 -2
- package/es/ui/Tabs.js +2 -2
- package/es/ui/Tag.js +2 -2
- package/es/ui/Timeline.js +2 -2
- package/es/ui/Tooltip.js +2 -2
- package/es/ui/Tour.js +2 -2
- package/es/ui/Tree.js +2 -2
- package/es/ui/Typography.js +4 -4
- package/es/ui/UploadImage.js +9 -9
- package/es/ui/Watermark.js +7 -7
- package/es/ui/index.js +97 -97
- package/package.json +1 -1
- package/es/chunks/jsx-runtime-DFKOoQSG.js +0 -430
package/es/ui/Cascader.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { jsx } from 'react/jsx-runtime';
|
|
2
2
|
import { Cascader } from 'antd';
|
|
3
3
|
|
|
4
4
|
const CascaderField = (props) => {
|
|
@@ -8,7 +8,7 @@ const CascaderField = (props) => {
|
|
|
8
8
|
options = [],
|
|
9
9
|
...restProps
|
|
10
10
|
} = props;
|
|
11
|
-
return /* @__PURE__ */
|
|
11
|
+
return /* @__PURE__ */ jsx("div", { className: customStyleContainer, children: /* @__PURE__ */ jsx(
|
|
12
12
|
Cascader,
|
|
13
13
|
{
|
|
14
14
|
options,
|
package/es/ui/CategoryStatus.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { jsx, jsxs } from 'react/jsx-runtime';
|
|
2
2
|
import { t as twMerge } from '../chunks/bundle-mjs-BME7zF0Z.js';
|
|
3
3
|
|
|
4
4
|
var CATEGORY_LIST_ENUM = /* @__PURE__ */ ((CATEGORY_LIST_ENUM2) => {
|
|
@@ -38,13 +38,13 @@ const CategoryStatus = ({ status }) => {
|
|
|
38
38
|
color,
|
|
39
39
|
statusName
|
|
40
40
|
}) => {
|
|
41
|
-
return /* @__PURE__ */
|
|
42
|
-
/* @__PURE__ */
|
|
43
|
-
/* @__PURE__ */
|
|
41
|
+
return /* @__PURE__ */ jsx("div", { children: /* @__PURE__ */ jsxs("div", { className: "flex items-center gap-2", children: [
|
|
42
|
+
/* @__PURE__ */ jsx("div", { className: twMerge("w-3 h-3 rounded-sm", color || "") }),
|
|
43
|
+
/* @__PURE__ */ jsx("span", { className: "text-sm font-normal", children: statusName || "" })
|
|
44
44
|
] }) });
|
|
45
45
|
};
|
|
46
46
|
//! Render
|
|
47
|
-
return /* @__PURE__ */
|
|
47
|
+
return /* @__PURE__ */ jsx(ItemStatus, { color: bagde?.color, statusName: bagde?.text });
|
|
48
48
|
};
|
|
49
49
|
|
|
50
50
|
export { CATEGORY_LIST_ENUM, CategoryStatus, badgeStatusCategoryConfig };
|
package/es/ui/Col.js
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { jsx } from 'react/jsx-runtime';
|
|
2
2
|
import { Col as Col$1 } from 'antd';
|
|
3
3
|
|
|
4
4
|
const Col = (props) => {
|
|
5
5
|
const { colClassName, ...restProps } = props;
|
|
6
|
-
return /* @__PURE__ */
|
|
6
|
+
return /* @__PURE__ */ jsx(Col$1, { className: colClassName, ...restProps });
|
|
7
7
|
};
|
|
8
8
|
|
|
9
9
|
export { Col };
|
package/es/ui/Collapse.js
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { jsx } from 'react/jsx-runtime';
|
|
2
2
|
import { Collapse as Collapse$1 } from 'antd';
|
|
3
3
|
|
|
4
4
|
const Collapse = (props) => {
|
|
5
|
-
return /* @__PURE__ */
|
|
5
|
+
return /* @__PURE__ */ jsx(Collapse$1, { ...props });
|
|
6
6
|
};
|
|
7
7
|
|
|
8
8
|
export { Collapse };
|
package/es/ui/ColorPicker.js
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { jsx } from 'react/jsx-runtime';
|
|
2
2
|
import { ColorPicker as ColorPicker$1 } from 'antd';
|
|
3
3
|
|
|
4
4
|
const ColorPicker = (props) => {
|
|
5
|
-
return /* @__PURE__ */
|
|
5
|
+
return /* @__PURE__ */ jsx(ColorPicker$1, { ...props });
|
|
6
6
|
};
|
|
7
7
|
|
|
8
8
|
export { ColorPicker };
|
package/es/ui/ConfigProvider.js
CHANGED
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { jsx } from 'react/jsx-runtime';
|
|
2
2
|
import { ConfigProvider as ConfigProvider$1 } from 'antd';
|
|
3
3
|
|
|
4
4
|
const ConfigProvider = ({
|
|
5
5
|
children,
|
|
6
6
|
...rest
|
|
7
7
|
}) => {
|
|
8
|
-
return /* @__PURE__ */
|
|
8
|
+
return /* @__PURE__ */ jsx(ConfigProvider$1, { ...rest, children });
|
|
9
9
|
};
|
|
10
10
|
|
|
11
11
|
export { ConfigProvider };
|
package/es/ui/ConfirmModal.js
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { jsx, jsxs } from 'react/jsx-runtime';
|
|
2
2
|
import { Button } from './Button.js';
|
|
3
3
|
import { Modal } from './Modal.js';
|
|
4
4
|
|
|
5
|
-
const ErrorConfirmIcon = (props) => /* @__PURE__ */
|
|
5
|
+
const ErrorConfirmIcon = (props) => /* @__PURE__ */ jsx(
|
|
6
6
|
"svg",
|
|
7
7
|
{
|
|
8
8
|
xmlns: "http://www.w3.org/2000/svg",
|
|
@@ -10,7 +10,7 @@ const ErrorConfirmIcon = (props) => /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
|
10
10
|
height: 24,
|
|
11
11
|
fill: "none",
|
|
12
12
|
...props,
|
|
13
|
-
children: /* @__PURE__ */
|
|
13
|
+
children: /* @__PURE__ */ jsx(
|
|
14
14
|
"path",
|
|
15
15
|
{
|
|
16
16
|
fill: props?.fill || "#FF4D4F",
|
|
@@ -20,7 +20,7 @@ const ErrorConfirmIcon = (props) => /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
|
20
20
|
}
|
|
21
21
|
);
|
|
22
22
|
|
|
23
|
-
const InfoConfirmIcon = (props) => /* @__PURE__ */
|
|
23
|
+
const InfoConfirmIcon = (props) => /* @__PURE__ */ jsx(
|
|
24
24
|
"svg",
|
|
25
25
|
{
|
|
26
26
|
xmlns: "http://www.w3.org/2000/svg",
|
|
@@ -28,7 +28,7 @@ const InfoConfirmIcon = (props) => /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
|
28
28
|
height: 24,
|
|
29
29
|
fill: "none",
|
|
30
30
|
...props,
|
|
31
|
-
children: /* @__PURE__ */
|
|
31
|
+
children: /* @__PURE__ */ jsx(
|
|
32
32
|
"path",
|
|
33
33
|
{
|
|
34
34
|
fill: props?.fill || "#1677FF",
|
|
@@ -39,7 +39,7 @@ const InfoConfirmIcon = (props) => /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
|
39
39
|
}
|
|
40
40
|
);
|
|
41
41
|
|
|
42
|
-
const SuccessIcon = (props) => /* @__PURE__ */
|
|
42
|
+
const SuccessIcon = (props) => /* @__PURE__ */ jsx(
|
|
43
43
|
"svg",
|
|
44
44
|
{
|
|
45
45
|
xmlns: "http://www.w3.org/2000/svg",
|
|
@@ -47,7 +47,7 @@ const SuccessIcon = (props) => /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
|
47
47
|
height: 24,
|
|
48
48
|
fill: "none",
|
|
49
49
|
...props,
|
|
50
|
-
children: /* @__PURE__ */
|
|
50
|
+
children: /* @__PURE__ */ jsx(
|
|
51
51
|
"path",
|
|
52
52
|
{
|
|
53
53
|
fill: props?.fill || "#52C41A",
|
|
@@ -58,7 +58,7 @@ const SuccessIcon = (props) => /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
|
58
58
|
}
|
|
59
59
|
);
|
|
60
60
|
|
|
61
|
-
const WarningConfrimIcon = (props) => /* @__PURE__ */
|
|
61
|
+
const WarningConfrimIcon = (props) => /* @__PURE__ */ jsx(
|
|
62
62
|
"svg",
|
|
63
63
|
{
|
|
64
64
|
xmlns: "http://www.w3.org/2000/svg",
|
|
@@ -66,7 +66,7 @@ const WarningConfrimIcon = (props) => /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
|
66
66
|
height: 24,
|
|
67
67
|
fill: "none",
|
|
68
68
|
...props,
|
|
69
|
-
children: /* @__PURE__ */
|
|
69
|
+
children: /* @__PURE__ */ jsx(
|
|
70
70
|
"path",
|
|
71
71
|
{
|
|
72
72
|
fill: props?.fill || "#FAAD14",
|
|
@@ -90,28 +90,28 @@ const ConfirmModal = ({
|
|
|
90
90
|
const IconType = () => {
|
|
91
91
|
switch (typeIcon) {
|
|
92
92
|
case "success":
|
|
93
|
-
return /* @__PURE__ */
|
|
93
|
+
return /* @__PURE__ */ jsx(SuccessIcon, {});
|
|
94
94
|
case "error":
|
|
95
|
-
return /* @__PURE__ */
|
|
95
|
+
return /* @__PURE__ */ jsx(ErrorConfirmIcon, {});
|
|
96
96
|
case "info":
|
|
97
|
-
return /* @__PURE__ */
|
|
97
|
+
return /* @__PURE__ */ jsx(InfoConfirmIcon, {});
|
|
98
98
|
case "warning":
|
|
99
|
-
return /* @__PURE__ */
|
|
99
|
+
return /* @__PURE__ */ jsx(WarningConfrimIcon, {});
|
|
100
100
|
}
|
|
101
101
|
};
|
|
102
102
|
//! Function
|
|
103
103
|
//! Render
|
|
104
|
-
return /* @__PURE__ */
|
|
105
|
-
/* @__PURE__ */
|
|
106
|
-
/* @__PURE__ */
|
|
107
|
-
/* @__PURE__ */
|
|
108
|
-
/* @__PURE__ */
|
|
109
|
-
/* @__PURE__ */
|
|
104
|
+
return /* @__PURE__ */ jsx(Modal, { ...restProps, footer: null, closeIcon: null, width: 400, children: /* @__PURE__ */ jsxs("div", { children: [
|
|
105
|
+
/* @__PURE__ */ jsxs("div", { className: "flex gap-3", children: [
|
|
106
|
+
/* @__PURE__ */ jsx("div", { className: "max-w-fit", children: /* @__PURE__ */ jsx(IconType, {}) }),
|
|
107
|
+
/* @__PURE__ */ jsxs("div", { children: [
|
|
108
|
+
/* @__PURE__ */ jsx("h2", { className: "text-base font-semibold", children: title }),
|
|
109
|
+
/* @__PURE__ */ jsx("p", { className: "text-sm", children: content })
|
|
110
110
|
] })
|
|
111
111
|
] }),
|
|
112
|
-
/* @__PURE__ */
|
|
113
|
-
/* @__PURE__ */
|
|
114
|
-
/* @__PURE__ */
|
|
112
|
+
/* @__PURE__ */ jsxs("div", { className: "flex gap-2 w-full justify-end items-end pt-3", children: [
|
|
113
|
+
/* @__PURE__ */ jsx(Button, { shape: "round", onClick: handleCancel, children: titleCancelBtn }),
|
|
114
|
+
/* @__PURE__ */ jsx(Button, { shape: "round", type: "primary", onClick: handleSubmit, children: titleSubmitBtn })
|
|
115
115
|
] })
|
|
116
116
|
] }) });
|
|
117
117
|
};
|
package/es/ui/Container.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { jsx } from 'react/jsx-runtime';
|
|
2
2
|
import { t as twMerge } from '../chunks/bundle-mjs-BME7zF0Z.js';
|
|
3
3
|
|
|
4
4
|
const Container = ({
|
|
@@ -6,7 +6,7 @@ const Container = ({
|
|
|
6
6
|
className,
|
|
7
7
|
size
|
|
8
8
|
}) => {
|
|
9
|
-
return /* @__PURE__ */
|
|
9
|
+
return /* @__PURE__ */ jsx("div", { className: twMerge(size, "mx-auto px-4 sm:px-6 lg:px-8", className), children });
|
|
10
10
|
};
|
|
11
11
|
|
|
12
12
|
export { Container };
|
package/es/ui/Divider.js
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { jsx } from 'react/jsx-runtime';
|
|
2
2
|
import { Divider as Divider$1 } from 'antd';
|
|
3
3
|
|
|
4
4
|
const Divider = ({ children, ...rest }) => {
|
|
5
|
-
return /* @__PURE__ */
|
|
5
|
+
return /* @__PURE__ */ jsx(Divider$1, { ...rest, children });
|
|
6
6
|
};
|
|
7
7
|
|
|
8
8
|
export { Divider };
|
package/es/ui/Drawer.js
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { jsx } from 'react/jsx-runtime';
|
|
2
2
|
import { Drawer as Drawer$1 } from 'antd';
|
|
3
3
|
|
|
4
4
|
const Drawer = ({ onSubmit, children, ...rest }) => {
|
|
5
|
-
return /* @__PURE__ */
|
|
5
|
+
return /* @__PURE__ */ jsx(Drawer$1, { ...rest, children: onSubmit ? /* @__PURE__ */ jsx(
|
|
6
6
|
"form",
|
|
7
7
|
{
|
|
8
8
|
id: "pnkx-form",
|
package/es/ui/Dropdown.js
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { jsx } from 'react/jsx-runtime';
|
|
2
2
|
import { Dropdown as Dropdown$1 } from 'antd';
|
|
3
3
|
|
|
4
4
|
const Dropdown = (props) => {
|
|
5
5
|
const { containerClassName, dropdownClassName, ...restProps } = props;
|
|
6
|
-
return /* @__PURE__ */
|
|
6
|
+
return /* @__PURE__ */ jsx("div", { className: containerClassName, children: /* @__PURE__ */ jsx(Dropdown$1, { className: dropdownClassName, ...restProps }) });
|
|
7
7
|
};
|
|
8
8
|
|
|
9
9
|
export { Dropdown };
|
package/es/ui/Empty.js
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { jsx } from 'react/jsx-runtime';
|
|
2
2
|
import { Empty as Empty$1 } from 'antd';
|
|
3
3
|
|
|
4
4
|
const Empty = (props) => {
|
|
5
|
-
return /* @__PURE__ */
|
|
5
|
+
return /* @__PURE__ */ jsx(Empty$1, { ...props });
|
|
6
6
|
};
|
|
7
7
|
|
|
8
8
|
export { Empty };
|
package/es/ui/ErrorBoundary.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { jsxs, jsx } from 'react/jsx-runtime';
|
|
2
2
|
import { Component } from 'react';
|
|
3
3
|
|
|
4
4
|
class ErrorBoundaryClass extends Component {
|
|
@@ -27,14 +27,14 @@ class ErrorBoundaryClass extends Component {
|
|
|
27
27
|
render() {
|
|
28
28
|
const { hasError, error, errorInfo } = this.state;
|
|
29
29
|
if (hasError) {
|
|
30
|
-
return /* @__PURE__ */
|
|
31
|
-
/* @__PURE__ */
|
|
32
|
-
/* @__PURE__ */
|
|
33
|
-
/* @__PURE__ */
|
|
34
|
-
process.env.NODE_ENV === "development" && error && /* @__PURE__ */
|
|
35
|
-
/* @__PURE__ */
|
|
36
|
-
/* @__PURE__ */
|
|
37
|
-
/* @__PURE__ */
|
|
30
|
+
return /* @__PURE__ */ jsxs("div", { style: styles.container, children: [
|
|
31
|
+
/* @__PURE__ */ jsx("h2", { style: styles.title, children: "🚨 An unexpected error has occurred." }),
|
|
32
|
+
/* @__PURE__ */ jsx("p", { style: styles.description, children: "Please refresh the page or contact support if the problem persists." }),
|
|
33
|
+
/* @__PURE__ */ jsx("button", { style: styles.button, onClick: this.handleReload, children: "Reload Page" }),
|
|
34
|
+
process.env.NODE_ENV === "development" && error && /* @__PURE__ */ jsxs("details", { style: styles.details, children: [
|
|
35
|
+
/* @__PURE__ */ jsx("summary", { children: "View Error Details" }),
|
|
36
|
+
/* @__PURE__ */ jsx("pre", { children: error.toString() }),
|
|
37
|
+
/* @__PURE__ */ jsx("pre", { children: errorInfo?.componentStack })
|
|
38
38
|
] })
|
|
39
39
|
] });
|
|
40
40
|
}
|
package/es/ui/ErrorMessage.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { jsx } from 'react/jsx-runtime';
|
|
2
2
|
import React__default from 'react';
|
|
3
3
|
|
|
4
4
|
const ErrorMessage = React__default.memo(
|
|
@@ -7,7 +7,7 @@ const ErrorMessage = React__default.memo(
|
|
|
7
7
|
return null;
|
|
8
8
|
}
|
|
9
9
|
if (!errorMessage) return null;
|
|
10
|
-
return /* @__PURE__ */
|
|
10
|
+
return /* @__PURE__ */ jsx("div", { className: "ml-2 text-red-600", children: errorMessage });
|
|
11
11
|
}
|
|
12
12
|
);
|
|
13
13
|
|
package/es/ui/Flex.js
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { jsx } from 'react/jsx-runtime';
|
|
2
2
|
import { Flex as Flex$1 } from 'antd';
|
|
3
3
|
|
|
4
4
|
const Flex = (props) => {
|
|
5
5
|
const { containerClassName, flexClassName, ...restProps } = props;
|
|
6
|
-
return /* @__PURE__ */
|
|
6
|
+
return /* @__PURE__ */ jsx("div", { className: containerClassName, children: /* @__PURE__ */ jsx(Flex$1, { className: flexClassName, ...restProps }) });
|
|
7
7
|
};
|
|
8
8
|
|
|
9
9
|
export { Flex };
|
package/es/ui/Footer.js
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { jsxs } from 'react/jsx-runtime';
|
|
2
2
|
import { Layout } from 'antd';
|
|
3
3
|
|
|
4
4
|
const { Footer: AntdFooter } = Layout;
|
|
5
5
|
const Footer = () => {
|
|
6
|
-
return /* @__PURE__ */
|
|
6
|
+
return /* @__PURE__ */ jsxs(AntdFooter, { style: { textAlign: "center" }, children: [
|
|
7
7
|
"Footer ©",
|
|
8
8
|
(/* @__PURE__ */ new Date()).getFullYear(),
|
|
9
9
|
" Created by Điệp lại lập trình"
|
package/es/ui/Heading.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { jsx, jsxs, Fragment } from 'react/jsx-runtime';
|
|
2
2
|
import { c as className } from '../chunks/index-mzHK7Za8.js';
|
|
3
3
|
import { Breadcrumb } from './Breadcrumb.js';
|
|
4
4
|
import { useLocation, Link } from 'react-router';
|
|
@@ -9,14 +9,14 @@ const Heading = (props) => {
|
|
|
9
9
|
const location = useLocation();
|
|
10
10
|
const pathUrl = location.pathname;
|
|
11
11
|
const breadcrumbsItem = [
|
|
12
|
-
{ title: /* @__PURE__ */
|
|
12
|
+
{ title: /* @__PURE__ */ jsx(Link, { to: "/", children: "Trang chủ" }) }
|
|
13
13
|
];
|
|
14
14
|
function findBreadcrumbs(items, currentPath, trail = []) {
|
|
15
15
|
for (const item of items) {
|
|
16
16
|
if (!item || !item.path) continue;
|
|
17
17
|
if (currentPath === item.path) {
|
|
18
18
|
if (!Object.prototype.hasOwnProperty.call(item, "isShowLabel") || item.isShowLabel) {
|
|
19
|
-
return [...trail, { title: /* @__PURE__ */
|
|
19
|
+
return [...trail, { title: /* @__PURE__ */ jsx(Link, { to: item.path, children: item.name }) }];
|
|
20
20
|
}
|
|
21
21
|
return trail;
|
|
22
22
|
}
|
|
@@ -24,7 +24,7 @@ const Heading = (props) => {
|
|
|
24
24
|
const newTrail = [...trail];
|
|
25
25
|
if (!Object.prototype.hasOwnProperty.call(item, "isShowLabel") || item.isShowLabel) {
|
|
26
26
|
newTrail.push({
|
|
27
|
-
title: /* @__PURE__ */
|
|
27
|
+
title: /* @__PURE__ */ jsx(Link, { to: item.path, children: item.name })
|
|
28
28
|
});
|
|
29
29
|
}
|
|
30
30
|
if (item.children && item.children.length > 0) {
|
|
@@ -46,8 +46,8 @@ const Heading = (props) => {
|
|
|
46
46
|
console.log("breadcrumbsItem table", breadcrumbsItem);
|
|
47
47
|
//! Function
|
|
48
48
|
//! Render
|
|
49
|
-
return /* @__PURE__ */
|
|
50
|
-
/* @__PURE__ */
|
|
49
|
+
return /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
50
|
+
/* @__PURE__ */ jsxs(
|
|
51
51
|
"div",
|
|
52
52
|
{
|
|
53
53
|
className: className(
|
|
@@ -55,7 +55,7 @@ const Heading = (props) => {
|
|
|
55
55
|
classNameWrapHeading
|
|
56
56
|
),
|
|
57
57
|
children: [
|
|
58
|
-
!noBreadcum && /* @__PURE__ */
|
|
58
|
+
!noBreadcum && /* @__PURE__ */ jsx(Breadcrumb, { items: breadcrumbsItem }),
|
|
59
59
|
rightContent
|
|
60
60
|
]
|
|
61
61
|
}
|
package/es/ui/Image.js
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { jsx } from 'react/jsx-runtime';
|
|
2
2
|
import { Image as Image$1 } from 'antd';
|
|
3
3
|
|
|
4
4
|
const Image = (props) => {
|
|
5
|
-
return /* @__PURE__ */
|
|
5
|
+
return /* @__PURE__ */ jsx(Image$1, { ...props });
|
|
6
6
|
};
|
|
7
7
|
|
|
8
8
|
export { Image };
|
package/es/ui/Label.js
CHANGED
|
@@ -1,13 +1,13 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { jsxs, jsx } from 'react/jsx-runtime';
|
|
2
2
|
import { Typography } from './Typography.js';
|
|
3
3
|
|
|
4
4
|
const Label = ({ label, required }) => {
|
|
5
5
|
//! State
|
|
6
6
|
//! Function
|
|
7
7
|
//! Render
|
|
8
|
-
return /* @__PURE__ */
|
|
9
|
-
/* @__PURE__ */
|
|
10
|
-
required && /* @__PURE__ */
|
|
8
|
+
return /* @__PURE__ */ jsxs("div", { className: "flex gap-1 mb-2 items-baseline", children: [
|
|
9
|
+
/* @__PURE__ */ jsx(Typography.Text, { children: label }),
|
|
10
|
+
required && /* @__PURE__ */ jsx("span", { className: "text-red-600 h-0", children: "*" })
|
|
11
11
|
] });
|
|
12
12
|
};
|
|
13
13
|
|
package/es/ui/Layout.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { jsx } from 'react/jsx-runtime';
|
|
2
2
|
import { S as SiderContext, a as Sider, C as Content, F as Footer, H as Header, L as Layout$1 } from '../chunks/layout-B04d5Lfr.js';
|
|
3
3
|
|
|
4
4
|
const LayoutComponent = ({
|
|
@@ -6,7 +6,7 @@ const LayoutComponent = ({
|
|
|
6
6
|
className,
|
|
7
7
|
...rest
|
|
8
8
|
}) => {
|
|
9
|
-
return /* @__PURE__ */
|
|
9
|
+
return /* @__PURE__ */ jsx(
|
|
10
10
|
Layout$1,
|
|
11
11
|
{
|
|
12
12
|
className: [layoutClassName, className].filter(Boolean).join(" "),
|
package/es/ui/Menu.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { jsx } from 'react/jsx-runtime';
|
|
2
2
|
import { Menu as Menu$1 } from 'antd';
|
|
3
3
|
|
|
4
4
|
const MenuComponent = ({
|
|
@@ -6,11 +6,11 @@ const MenuComponent = ({
|
|
|
6
6
|
menuClassName,
|
|
7
7
|
...rest
|
|
8
8
|
}) => {
|
|
9
|
-
return /* @__PURE__ */
|
|
9
|
+
return /* @__PURE__ */ jsx("div", { className: containerClassName, children: /* @__PURE__ */ jsx(Menu$1, { className: menuClassName, ...rest }) });
|
|
10
10
|
};
|
|
11
|
-
const MenuItem = (props) => /* @__PURE__ */
|
|
11
|
+
const MenuItem = (props) => /* @__PURE__ */ jsx(Menu$1.Item, { ...props });
|
|
12
12
|
MenuItem.displayName = "Menu.Item";
|
|
13
|
-
const SubMenu = (props) => /* @__PURE__ */
|
|
13
|
+
const SubMenu = (props) => /* @__PURE__ */ jsx(Menu$1.SubMenu, { ...props });
|
|
14
14
|
SubMenu.displayName = "Menu.SubMenu";
|
|
15
15
|
const Divider = Menu$1.Divider;
|
|
16
16
|
const ItemGroup = Menu$1.ItemGroup;
|
package/es/ui/Modal.js
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { jsx } from 'react/jsx-runtime';
|
|
2
2
|
import { Modal as Modal$1 } from 'antd';
|
|
3
3
|
|
|
4
4
|
const Modal = ({ children, ...rest }) => {
|
|
5
|
-
return /* @__PURE__ */
|
|
5
|
+
return /* @__PURE__ */ jsx(Modal$1, { ...rest, children });
|
|
6
6
|
};
|
|
7
7
|
|
|
8
8
|
export { Modal };
|