@pnkx-lib/ui 1.5.3 → 1.5.5
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/chunks/{Checkbox-Djkz94gB.js → Checkbox-CJ_M7IzZ.js} +2 -2
- package/es/chunks/{Checkbox-Djkz94gB.js.map → Checkbox-CJ_M7IzZ.js.map} +1 -1
- package/es/chunks/{Divider-RlbRBxOQ.js → Image-CFyQxi2B.js} +382 -134
- package/es/chunks/Image-CFyQxi2B.js.map +1 -0
- package/es/chunks/{Switch-DKjEDP4L.js → Switch-eMq9KkOy.js} +11 -11
- package/es/chunks/{Switch-DKjEDP4L.js.map → Switch-eMq9KkOy.js.map} +1 -1
- package/es/fields/index.js +2 -2
- package/es/index.js +3 -3
- package/es/ui/index.js +2 -2
- package/package.json +1 -1
- package/es/chunks/Divider-RlbRBxOQ.js.map +0 -1
@@ -1,10 +1,10 @@
|
|
1
|
-
import { j as jsxRuntimeExports, b as Icon, _ as _extends, c as _typeof, u as useForm, P as PnkxField, I as Input, d as
|
2
|
-
import { Button as Button$1, Cascader, Space as Space$1, Card, Skeleton as Skeleton$1, Popconfirm, Typography, Table as Table$1, Modal as Modal$1, Tooltip as Tooltip$1, Tabs as Tabs$1, Popover as Popover$1, Badge as Badge$1, Col as Col$1, Row as Row$1, Dropdown as Dropdown$1, Breadcrumb as Breadcrumb$1, Flex as Flex$1, Splitter as Splitter$1, Menu as Menu$1, Pagination as Pagination$1, Steps as Steps$1, Tag as Tag$1, Divider as Divider$2 } from 'antd';
|
1
|
+
import { j as jsxRuntimeExports, b as Icon, _ as _extends, c as _typeof, u as useForm, P as PnkxField, I as Input, d as classNames, e as _arrayLikeToArray, f as _unsupportedIterableToArray, w as warningOnce, h as _createClass, i as _classCallCheck, k as _defineProperty, l as _slicedToArray, m as warning$1, n as canUseDom, o as _objectSpread2, p as updateCSS, r as removeCSS, q as _arrayWithHoles, s as _nonIterableRest, t as resetWarned$1, F as FastColor, v as generate, x as presetPrimaryColors, y as presetPalettes, z as _inherits, A as _createSuper, B as _assertThisInitialized, C as _objectWithoutProperties, G as IconContext } from './Switch-eMq9KkOy.js';
|
2
|
+
import { Button as Button$1, Cascader, Space as Space$1, Card, Skeleton as Skeleton$1, Popconfirm as Popconfirm$1, Typography, Table as Table$1, Modal as Modal$1, Tooltip as Tooltip$1, Tabs as Tabs$1, Popover as Popover$1, Badge as Badge$1, Col as Col$1, Row as Row$1, Dropdown as Dropdown$1, Breadcrumb as Breadcrumb$1, Flex as Flex$1, Splitter as Splitter$1, Menu as Menu$1, Pagination as Pagination$1, Steps as Steps$1, Tag as Tag$1, Divider as Divider$2, Alert as Alert$1, Spin as Spin$1, Drawer as Drawer$1, QRCode as QRCode$1, Result as Result$1, Rate as Rate$1, Segmented as Segmented$1, Statistic as Statistic$1, Timeline as Timeline$1, Tour as Tour$1, Tree as Tree$1, Watermark as Watermark$1, Anchor as Anchor$1, Affix, AutoComplete as AutoComplete$1, Input as Input$1, Collapse, ColorPicker, Empty as Empty$2, Image as Image$1 } from 'antd';
|
3
3
|
import * as React from 'react';
|
4
4
|
import React__default, { version as version$1, isValidElement, useState, useEffect, useContext, createContext, useRef, useLayoutEffect as useLayoutEffect$1, useMemo as useMemo$1 } from 'react';
|
5
|
-
import ReactDOM__default from 'react-dom';
|
6
5
|
import { useNavigate, useLocation } from 'react-router-dom';
|
7
6
|
import { u as useToast } from './cloneDeep-BLYi2V0G.js';
|
7
|
+
import ReactDOM__default from 'react-dom';
|
8
8
|
|
9
9
|
const Button = (props) => {
|
10
10
|
return /* @__PURE__ */ jsxRuntimeExports.jsx(Button$1, { ...props });
|
@@ -2299,7 +2299,7 @@ const Table = ({
|
|
2299
2299
|
const editable2 = isEditing(record);
|
2300
2300
|
return editable2 ? /* @__PURE__ */ jsxRuntimeExports.jsxs("span", { children: [
|
2301
2301
|
/* @__PURE__ */ jsxRuntimeExports.jsx(
|
2302
|
-
Popconfirm,
|
2302
|
+
Popconfirm$1,
|
2303
2303
|
{
|
2304
2304
|
title: "Bạn có chắc chắn muốn huỷ chỉnh sửa?",
|
2305
2305
|
onConfirm: cancel,
|
@@ -2318,7 +2318,7 @@ const Table = ({
|
|
2318
2318
|
color: "blue"
|
2319
2319
|
}
|
2320
2320
|
),
|
2321
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx(Popconfirm, { title: "Bạn có muốn xoá ?", onConfirm: () => {
|
2321
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx(Popconfirm$1, { title: "Bạn có muốn xoá ?", onConfirm: () => {
|
2322
2322
|
}, children: /* @__PURE__ */ jsxRuntimeExports.jsx(
|
2323
2323
|
Button,
|
2324
2324
|
{
|
@@ -2407,12 +2407,7 @@ const Table = ({
|
|
2407
2407
|
return renderTableContent();
|
2408
2408
|
};
|
2409
2409
|
|
2410
|
-
const Modal = ({
|
2411
|
-
children,
|
2412
|
-
onOk,
|
2413
|
-
onSubmit,
|
2414
|
-
...rest
|
2415
|
-
}) => {
|
2410
|
+
const Modal = ({ children, onOk, onSubmit, ...rest }) => {
|
2416
2411
|
return /* @__PURE__ */ jsxRuntimeExports.jsx(Modal$1, { onOk: onSubmit ? onSubmit : onOk, ...rest, children: /* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "max-h-[20rem] overflow-y-auto", children: onSubmit ? /* @__PURE__ */ jsxRuntimeExports.jsx("form", { onSubmit, children }) : children }) });
|
2417
2412
|
};
|
2418
2413
|
|
@@ -2548,13 +2543,13 @@ const SearchFiltersForm = ({
|
|
2548
2543
|
|
2549
2544
|
const Container = ({
|
2550
2545
|
children,
|
2551
|
-
className
|
2546
|
+
className,
|
2552
2547
|
size
|
2553
2548
|
}) => {
|
2554
2549
|
return /* @__PURE__ */ jsxRuntimeExports.jsx(
|
2555
2550
|
"div",
|
2556
2551
|
{
|
2557
|
-
className:
|
2552
|
+
className: classNames(size, "mx-auto px-4 sm:px-6 lg:px-8", className),
|
2558
2553
|
children
|
2559
2554
|
}
|
2560
2555
|
);
|
@@ -4359,7 +4354,7 @@ var parseStyle = function parseStyle(interpolation) {
|
|
4359
4354
|
function uniqueHash(path, styleStr) {
|
4360
4355
|
return murmur2("".concat(path.join('%')).concat(styleStr));
|
4361
4356
|
}
|
4362
|
-
function Empty() {
|
4357
|
+
function Empty$1() {
|
4363
4358
|
return null;
|
4364
4359
|
}
|
4365
4360
|
var STYLE_PREFIX = 'style';
|
@@ -4509,7 +4504,7 @@ function useStyleRegister(info, styleFn) {
|
|
4509
4504
|
return function (node) {
|
4510
4505
|
var styleNode;
|
4511
4506
|
if (!ssrInline || isMergedClientSide || !defaultCache) {
|
4512
|
-
styleNode = /*#__PURE__*/React.createElement(Empty, null);
|
4507
|
+
styleNode = /*#__PURE__*/React.createElement(Empty$1, null);
|
4513
4508
|
} else {
|
4514
4509
|
var _ref6;
|
4515
4510
|
styleNode = /*#__PURE__*/React.createElement("style", _extends({}, (_ref6 = {}, _defineProperty(_ref6, ATTR_TOKEN, cachedTokenKey), _defineProperty(_ref6, ATTR_MARK, cachedStyleId), _ref6), {
|
@@ -7350,7 +7345,7 @@ function genCSSMotion(config) {
|
|
7350
7345
|
}
|
7351
7346
|
var motionCls = getTransitionName(motionName, "".concat(status, "-").concat(statusSuffix));
|
7352
7347
|
motionChildren = children(_objectSpread2(_objectSpread2({}, mergedProps), {}, {
|
7353
|
-
className:
|
7348
|
+
className: classNames(getTransitionName(motionName, status), _defineProperty(_defineProperty({}, motionCls, motionCls && statusSuffix), motionName, typeof motionName === 'string')),
|
7354
7349
|
style: statusStyle
|
7355
7350
|
}), setNodeRef);
|
7356
7351
|
}
|
@@ -8292,7 +8287,7 @@ const generateId = (() => {
|
|
8292
8287
|
const Sider = /*#__PURE__*/React.forwardRef((props, ref) => {
|
8293
8288
|
const {
|
8294
8289
|
prefixCls: customizePrefixCls,
|
8295
|
-
className
|
8290
|
+
className,
|
8296
8291
|
trigger,
|
8297
8292
|
children,
|
8298
8293
|
defaultCollapsed = false,
|
@@ -8370,7 +8365,7 @@ const Sider = /*#__PURE__*/React.forwardRef((props, ref) => {
|
|
8370
8365
|
// special trigger when collapsedWidth == 0
|
8371
8366
|
const zeroWidthTrigger = parseFloat(String(collapsedWidth || 0)) === 0 ? (/*#__PURE__*/React.createElement("span", {
|
8372
8367
|
onClick: toggle,
|
8373
|
-
className:
|
8368
|
+
className: classNames(`${prefixCls}-zero-width-trigger`, `${prefixCls}-zero-width-trigger-${reverseArrow ? 'right' : 'left'}`),
|
8374
8369
|
style: zeroWidthTriggerStyle
|
8375
8370
|
}, trigger || /*#__PURE__*/React.createElement(RefIcon$6, null))) : null;
|
8376
8371
|
const reverseIcon = direction === 'rtl' === !reverseArrow;
|
@@ -8393,12 +8388,12 @@ const Sider = /*#__PURE__*/React.forwardRef((props, ref) => {
|
|
8393
8388
|
minWidth: siderWidth,
|
8394
8389
|
width: siderWidth
|
8395
8390
|
});
|
8396
|
-
const siderCls =
|
8391
|
+
const siderCls = classNames(prefixCls, `${prefixCls}-${theme}`, {
|
8397
8392
|
[`${prefixCls}-collapsed`]: !!collapsed,
|
8398
8393
|
[`${prefixCls}-has-trigger`]: collapsible && trigger !== null && !zeroWidthTrigger,
|
8399
8394
|
[`${prefixCls}-below`]: !!below,
|
8400
8395
|
[`${prefixCls}-zero-width`]: parseFloat(siderWidth) === 0
|
8401
|
-
}, className
|
8396
|
+
}, className, hashId, cssVarCls);
|
8402
8397
|
const contextValue = React.useMemo(() => ({
|
8403
8398
|
siderCollapsed: collapsed
|
8404
8399
|
}), [collapsed]);
|
@@ -8458,7 +8453,7 @@ const Basic = /*#__PURE__*/React.forwardRef((props, ref) => {
|
|
8458
8453
|
const {
|
8459
8454
|
prefixCls: customizePrefixCls,
|
8460
8455
|
suffixCls,
|
8461
|
-
className
|
8456
|
+
className,
|
8462
8457
|
tagName: TagName
|
8463
8458
|
} = props,
|
8464
8459
|
others = __rest(props, ["prefixCls", "suffixCls", "className", "tagName"]);
|
@@ -8469,7 +8464,7 @@ const Basic = /*#__PURE__*/React.forwardRef((props, ref) => {
|
|
8469
8464
|
const [wrapSSR, hashId, cssVarCls] = useStyle$1(prefixCls);
|
8470
8465
|
const prefixWithSuffixCls = suffixCls ? `${prefixCls}-${suffixCls}` : prefixCls;
|
8471
8466
|
return wrapSSR(/*#__PURE__*/React.createElement(TagName, Object.assign({
|
8472
|
-
className:
|
8467
|
+
className: classNames(customizePrefixCls || prefixWithSuffixCls, className, hashId, cssVarCls),
|
8473
8468
|
ref: ref
|
8474
8469
|
}, others)));
|
8475
8470
|
});
|
@@ -8480,7 +8475,7 @@ const BasicLayout = /*#__PURE__*/React.forwardRef((props, ref) => {
|
|
8480
8475
|
const [siders, setSiders] = React.useState([]);
|
8481
8476
|
const {
|
8482
8477
|
prefixCls: customizePrefixCls,
|
8483
|
-
className
|
8478
|
+
className,
|
8484
8479
|
rootClassName,
|
8485
8480
|
children,
|
8486
8481
|
hasSider,
|
@@ -8497,10 +8492,10 @@ const BasicLayout = /*#__PURE__*/React.forwardRef((props, ref) => {
|
|
8497
8492
|
const prefixCls = getPrefixCls('layout', customizePrefixCls);
|
8498
8493
|
const mergedHasSider = useHasSider(siders, children, hasSider);
|
8499
8494
|
const [wrapCSSVar, hashId, cssVarCls] = useStyle$1(prefixCls);
|
8500
|
-
const classString =
|
8495
|
+
const classString = classNames(prefixCls, {
|
8501
8496
|
[`${prefixCls}-has-sider`]: mergedHasSider,
|
8502
8497
|
[`${prefixCls}-rtl`]: direction === 'rtl'
|
8503
|
-
}, contextClassName, className
|
8498
|
+
}, contextClassName, className, rootClassName, hashId, cssVarCls);
|
8504
8499
|
const contextValue = React.useMemo(() => ({
|
8505
8500
|
siderHook: {
|
8506
8501
|
addSider: id => {
|
@@ -11716,11 +11711,8 @@ const getDefaultConfig = () => {
|
|
11716
11711
|
};
|
11717
11712
|
const twMerge = /*#__PURE__*/createTailwindMerge(getDefaultConfig);
|
11718
11713
|
|
11719
|
-
function classNames(...classes) {
|
11720
|
-
return classes.filter(Boolean).join(" ");
|
11721
|
-
}
|
11722
11714
|
const userInfo = {
|
11723
|
-
avatar: "https://
|
11715
|
+
avatar: "https://img.freepik.com/premium-vector/character-avatar-isolated_729149-194801.jpg?semt=ais_hybrid&w=740",
|
11724
11716
|
name: "username",
|
11725
11717
|
email: "gmail@gmail.com"
|
11726
11718
|
};
|
@@ -11731,17 +11723,17 @@ const languageInfo = {
|
|
11731
11723
|
const bottomMenu = [
|
11732
11724
|
{
|
11733
11725
|
key: "user",
|
11734
|
-
icon: /* @__PURE__ */ jsxRuntimeExports.jsx(
|
11735
|
-
|
11736
|
-
|
11737
|
-
"
|
11738
|
-
|
11739
|
-
|
11740
|
-
|
11741
|
-
|
11742
|
-
|
11743
|
-
),
|
11744
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx("
|
11726
|
+
icon: /* @__PURE__ */ jsxRuntimeExports.jsx(
|
11727
|
+
"img",
|
11728
|
+
{
|
11729
|
+
className: "h-8 w-8 rounded-md object-cover",
|
11730
|
+
src: userInfo.avatar,
|
11731
|
+
alt: ""
|
11732
|
+
}
|
11733
|
+
),
|
11734
|
+
label: /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "h-[32px]", children: [
|
11735
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "text-sm font-semibold text-white group-hover:text-black", children: userInfo.name }),
|
11736
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "text-xs text-gray-300", children: userInfo.email })
|
11745
11737
|
] }),
|
11746
11738
|
show: true
|
11747
11739
|
},
|
@@ -11822,64 +11814,110 @@ const Sidebar = ({ children, menu }) => {
|
|
11822
11814
|
collapse ? "w-60" : "w-16"
|
11823
11815
|
),
|
11824
11816
|
children: [
|
11825
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx(
|
11826
|
-
"
|
11817
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx(
|
11818
|
+
"div",
|
11827
11819
|
{
|
11828
|
-
className:
|
11829
|
-
|
11830
|
-
|
11831
|
-
|
11832
|
-
|
11833
|
-
/* @__PURE__ */ jsxRuntimeExports.jsxs("nav", { className: "flex flex-1 flex-col px-2", children: [
|
11834
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx("ul", { role: "list", className: "-mx-2 space-y-1 relative", children: menu.map((item) => /* @__PURE__ */ jsxRuntimeExports.jsxs("li", { className: "relative pl-2 cursor-pointer", children: [
|
11835
|
-
(activeMainMenu === item.href || item.href === pathUrl) && !collapse && /* @__PURE__ */ jsxRuntimeExports.jsxs(jsxRuntimeExports.Fragment, { children: [
|
11836
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx("span", { className: "absolute top-[-40px] right-0 w-10 h-10 rounded-full shadow-[24px_24px_0_white]" }),
|
11837
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx("span", { className: "absolute bottom-[-40px] right-0 w-10 h-10 rounded-full shadow-[24px_-24px_0_white]" })
|
11838
|
-
] }),
|
11839
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx(
|
11840
|
-
"div",
|
11820
|
+
className: twMerge(
|
11821
|
+
"flex h-16 shrink-0 items-center justify-center bg-[#FFFFFF]"
|
11822
|
+
),
|
11823
|
+
children: /* @__PURE__ */ jsxRuntimeExports.jsx(
|
11824
|
+
"img",
|
11841
11825
|
{
|
11842
|
-
className:
|
11843
|
-
|
11844
|
-
|
11826
|
+
className: twMerge("h-8 w-auto"),
|
11827
|
+
src: collapse ? "https://i.ibb.co/XrQYLt6C/logo.png" : "https://i.ibb.co/7tPnGMqx/Type-Collapse-menu.png",
|
11828
|
+
alt: "logo"
|
11829
|
+
}
|
11830
|
+
)
|
11831
|
+
}
|
11832
|
+
),
|
11833
|
+
/* @__PURE__ */ jsxRuntimeExports.jsxs("nav", { className: twMerge("flex flex-1 flex-col px-2"), children: [
|
11834
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx("ul", { role: "list", className: twMerge("-mx-2 space-y-1 relative"), children: menu.map((item) => /* @__PURE__ */ jsxRuntimeExports.jsxs(
|
11835
|
+
"li",
|
11836
|
+
{
|
11837
|
+
className: twMerge("relative pl-2 cursor-pointer"),
|
11838
|
+
children: [
|
11839
|
+
(activeMainMenu === item.href || item.href === pathUrl) && !collapse && /* @__PURE__ */ jsxRuntimeExports.jsxs(jsxRuntimeExports.Fragment, { children: [
|
11840
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx(
|
11841
|
+
"span",
|
11842
|
+
{
|
11843
|
+
className: twMerge(
|
11844
|
+
"absolute top-[-40px] right-0 w-10 h-10 rounded-full shadow-[24px_24px_0_white]"
|
11845
|
+
)
|
11846
|
+
}
|
11847
|
+
),
|
11848
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx(
|
11849
|
+
"span",
|
11850
|
+
{
|
11851
|
+
className: twMerge(
|
11852
|
+
"absolute bottom-[-40px] right-0 w-10 h-10 rounded-full shadow-[24px_-24px_0_white]"
|
11853
|
+
)
|
11854
|
+
}
|
11855
|
+
)
|
11856
|
+
] }),
|
11857
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx(
|
11858
|
+
"div",
|
11845
11859
|
{
|
11846
|
-
|
11847
|
-
|
11848
|
-
|
11849
|
-
setOpenSubCollapse(true);
|
11850
|
-
},
|
11851
|
-
className: classNames(
|
11852
|
-
item.href === activeMainMenu || item.href === pathUrl ? "bg-white text-black hover:text-black" : "text-white hover:bg-[#FFFFFF] hover:text-black",
|
11853
|
-
`py-2 rounded-md mt-2 text-sm whitespace-nowrap leading-6 font-semibold relative z-10 ${collapse ? "pl-4 mr-2" : "rounded-bl-full rounded-tl-full justify-center "} flex items-center gap-2`
|
11860
|
+
className: twMerge(
|
11861
|
+
"relative group rounded-bl-full rounded-tl-full hover:text-black",
|
11862
|
+
!collapse && "hover:bg-[#FFFFFF]"
|
11854
11863
|
),
|
11855
|
-
children:
|
11856
|
-
|
11857
|
-
|
11858
|
-
|
11859
|
-
|
11864
|
+
children: /* @__PURE__ */ jsxRuntimeExports.jsxs(
|
11865
|
+
"a",
|
11866
|
+
{
|
11867
|
+
onClick: () => {
|
11868
|
+
handleActiveMain(item.href);
|
11869
|
+
setCollapse(false);
|
11870
|
+
setOpenSubCollapse(true);
|
11871
|
+
},
|
11872
|
+
className: twMerge(
|
11873
|
+
item.href === activeMainMenu || item.href === pathUrl ? "bg-white text-black hover:text-black" : "text-white hover:bg-[#FFFFFF] hover:text-black",
|
11874
|
+
"py-2 rounded-md mt-2 text-sm whitespace-nowrap leading-6 font-semibold relative z-10",
|
11875
|
+
collapse ? "pl-4 mr-2" : "rounded-bl-full rounded-tl-full justify-center ",
|
11876
|
+
"flex items-center gap-2"
|
11877
|
+
),
|
11878
|
+
children: [
|
11879
|
+
item.icon,
|
11880
|
+
collapse && item.name,
|
11881
|
+
collapse && /* @__PURE__ */ jsxRuntimeExports.jsx(
|
11882
|
+
ForwardRef$2,
|
11883
|
+
{
|
11884
|
+
className: twMerge("w-4 h-4 ml-auto")
|
11885
|
+
}
|
11886
|
+
)
|
11887
|
+
]
|
11888
|
+
}
|
11889
|
+
)
|
11860
11890
|
}
|
11861
11891
|
)
|
11862
|
-
|
11863
|
-
|
11864
|
-
|
11865
|
-
|
11892
|
+
]
|
11893
|
+
},
|
11894
|
+
item.name
|
11895
|
+
)) }),
|
11896
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: twMerge("mt-auto pb-4"), children: /* @__PURE__ */ jsxRuntimeExports.jsx("ul", { children: bottomMenu.map(
|
11866
11897
|
(bm) => bm.show && /* @__PURE__ */ jsxRuntimeExports.jsx(
|
11867
11898
|
"li",
|
11868
11899
|
{
|
11869
|
-
className:
|
11900
|
+
className: twMerge(
|
11870
11901
|
"-mx-2 list-none flex items-center gap-4 rounded-md whitespace-nowrap group cursor-pointer",
|
11871
|
-
bm.extraClass || ""
|
11872
|
-
bm.key === "user" ? "mt-auto" : ""
|
11902
|
+
bm.extraClass || ""
|
11873
11903
|
),
|
11874
11904
|
onClick: () => toast(),
|
11875
|
-
children: /* @__PURE__ */ jsxRuntimeExports.jsxs(
|
11876
|
-
|
11877
|
-
|
11878
|
-
|
11905
|
+
children: /* @__PURE__ */ jsxRuntimeExports.jsxs(
|
11906
|
+
"div",
|
11907
|
+
{
|
11908
|
+
className: twMerge(
|
11909
|
+
"hover:bg-[#FFFFFF] flex items-center w-full ml-2 mr-2 whitespace-nowrap gap-2 p-2 rounded-md"
|
11910
|
+
),
|
11911
|
+
children: [
|
11912
|
+
bm.icon,
|
11913
|
+
collapse && bm.label
|
11914
|
+
]
|
11915
|
+
}
|
11916
|
+
)
|
11879
11917
|
},
|
11880
11918
|
bm.key
|
11881
11919
|
)
|
11882
|
-
)
|
11920
|
+
) }) })
|
11883
11921
|
] })
|
11884
11922
|
]
|
11885
11923
|
}
|
@@ -11888,56 +11926,74 @@ const Sidebar = ({ children, menu }) => {
|
|
11888
11926
|
"button",
|
11889
11927
|
{
|
11890
11928
|
onClick: () => setOpenSubCollapse(false),
|
11891
|
-
className:
|
11892
|
-
|
11893
|
-
|
11894
|
-
children: /* @__PURE__ */ jsxRuntimeExports.jsx(ForwardRef$3, { className: "w-4 h-4" })
|
11929
|
+
className: twMerge(
|
11930
|
+
"absolute top-1/19 transform -translate-y-1/2 cursor-pointer bg-white z-10 text-[#3078BD] rounded-full w-10 h-10 flex items-center justify-center shadow transition-all duration-300 left-44 sm:left-40 md:left-48 lg:left-66"
|
11931
|
+
),
|
11932
|
+
children: /* @__PURE__ */ jsxRuntimeExports.jsx(ForwardRef$3, { className: twMerge("w-4 h-4") })
|
11933
|
+
}
|
11934
|
+
),
|
11935
|
+
openSubCollapse && /* @__PURE__ */ jsxRuntimeExports.jsxs(
|
11936
|
+
"div",
|
11937
|
+
{
|
11938
|
+
className: twMerge(
|
11939
|
+
"flex mt-3 flex-col w-40 border-gray-200 bg-white h-screen transition-all duration-300"
|
11940
|
+
),
|
11941
|
+
children: [
|
11942
|
+
!collapse && /* @__PURE__ */ jsxRuntimeExports.jsx("div", { children: /* @__PURE__ */ jsxRuntimeExports.jsx("img", { src: "https://i.ibb.co/0yCpN5wS/Frame-1111113861.png" }) }),
|
11943
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx(
|
11944
|
+
"nav",
|
11945
|
+
{
|
11946
|
+
className: twMerge(
|
11947
|
+
"flex flex-1 transition-all duration-300 flex-col",
|
11948
|
+
collapse ? "mt-0" : "mt-6"
|
11949
|
+
),
|
11950
|
+
children: activeMenu && /* @__PURE__ */ jsxRuntimeExports.jsx(
|
11951
|
+
"ul",
|
11952
|
+
{
|
11953
|
+
role: "list",
|
11954
|
+
className: twMerge("-mx-2 space-y-1 cursor-pointer mt-4"),
|
11955
|
+
children: /* @__PURE__ */ jsxRuntimeExports.jsxs("li", { children: [
|
11956
|
+
/* @__PURE__ */ jsxRuntimeExports.jsxs(
|
11957
|
+
"a",
|
11958
|
+
{
|
11959
|
+
onClick: () => {
|
11960
|
+
handleOpenSubmenu(activeMenu.name);
|
11961
|
+
router(activeMenu.href);
|
11962
|
+
},
|
11963
|
+
className: twMerge(
|
11964
|
+
activeMenu.href === pathUrl ? "bg-[#EEEEF0] text-black" : "text-gray-700 hover:bg-[#EEEEF0]",
|
11965
|
+
"group flex gap-x-3 rounded-md p-2 text-sm leading-6 transition-all duration-300 font-semibold items-center"
|
11966
|
+
),
|
11967
|
+
children: [
|
11968
|
+
activeMenu.icon,
|
11969
|
+
activeMenu.name,
|
11970
|
+
openSubmenu === activeMenu.name ? /* @__PURE__ */ jsxRuntimeExports.jsx(ForwardRef$1, { className: twMerge("w-4 h-4 ml-auto") }) : /* @__PURE__ */ jsxRuntimeExports.jsx(ForwardRef$4, { className: twMerge("w-4 h-4 ml-auto") })
|
11971
|
+
]
|
11972
|
+
}
|
11973
|
+
),
|
11974
|
+
openSubmenu === activeMenu.name && activeMenu.children && /* @__PURE__ */ jsxRuntimeExports.jsx("ul", { className: twMerge("pl-2 transition-all duration-300"), children: activeMenu.children.map((sub) => /* @__PURE__ */ jsxRuntimeExports.jsxs(
|
11975
|
+
"li",
|
11976
|
+
{
|
11977
|
+
onClick: () => router(sub.href),
|
11978
|
+
className: twMerge(
|
11979
|
+
sub.href === pathUrl ? "bg-[#EEEEF0] text-black" : "",
|
11980
|
+
"text-xs hover:bg-[#EEEEF0] transition-all duration-300 mt-2 rounded-md py-2 flex items-center gap-2 p-2"
|
11981
|
+
),
|
11982
|
+
children: [
|
11983
|
+
sub.icon,
|
11984
|
+
sub.name
|
11985
|
+
]
|
11986
|
+
},
|
11987
|
+
sub.name
|
11988
|
+
)) })
|
11989
|
+
] }, activeMenu.name)
|
11990
|
+
}
|
11991
|
+
)
|
11992
|
+
}
|
11993
|
+
)
|
11994
|
+
]
|
11895
11995
|
}
|
11896
11996
|
),
|
11897
|
-
openSubCollapse && /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "flex mt-3 flex-col w-40 border-gray-200 bg-white h-screen transition-all duration-300", children: [
|
11898
|
-
!collapse && /* @__PURE__ */ jsxRuntimeExports.jsx("div", { children: /* @__PURE__ */ jsxRuntimeExports.jsx("img", { src: "https://i.ibb.co/0yCpN5wS/Frame-1111113861.png" }) }),
|
11899
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx(
|
11900
|
-
"nav",
|
11901
|
-
{
|
11902
|
-
className: `flex flex-1 transition-all duration-300 flex-col ${collapse ? "mt-0" : "mt-6"}`,
|
11903
|
-
children: activeMenu && /* @__PURE__ */ jsxRuntimeExports.jsx("ul", { role: "list", className: "-mx-2 space-y-1 cursor-pointer mt-4", children: /* @__PURE__ */ jsxRuntimeExports.jsxs("li", { children: [
|
11904
|
-
/* @__PURE__ */ jsxRuntimeExports.jsxs(
|
11905
|
-
"a",
|
11906
|
-
{
|
11907
|
-
onClick: () => {
|
11908
|
-
handleOpenSubmenu(activeMenu.name);
|
11909
|
-
router(activeMenu.href);
|
11910
|
-
},
|
11911
|
-
className: classNames(
|
11912
|
-
activeMenu.href === pathUrl ? "bg-[#EEEEF0] text-black" : "text-gray-700 hover:bg-[#EEEEF0]",
|
11913
|
-
"group flex gap-x-3 rounded-md p-2 text-sm leading-6 transition-all duration-300 font-semibold items-center"
|
11914
|
-
),
|
11915
|
-
children: [
|
11916
|
-
activeMenu.icon,
|
11917
|
-
activeMenu.name,
|
11918
|
-
openSubmenu === activeMenu.name ? /* @__PURE__ */ jsxRuntimeExports.jsx(ForwardRef$1, { className: "w-4 h-4 ml-auto" }) : /* @__PURE__ */ jsxRuntimeExports.jsx(ForwardRef$4, { className: "w-4 h-4 ml-auto" })
|
11919
|
-
]
|
11920
|
-
}
|
11921
|
-
),
|
11922
|
-
openSubmenu === activeMenu.name && activeMenu.children && /* @__PURE__ */ jsxRuntimeExports.jsx("ul", { className: "pl-2 transition-all duration-300", children: activeMenu.children.map((sub) => /* @__PURE__ */ jsxRuntimeExports.jsxs(
|
11923
|
-
"li",
|
11924
|
-
{
|
11925
|
-
onClick: () => router(sub.href),
|
11926
|
-
className: classNames(
|
11927
|
-
sub.href === pathUrl ? "bg-[#EEEEF0] text-black" : "",
|
11928
|
-
"text-xs hover:bg-[#EEEEF0] transition-all duration-300 mt-2 rounded-md py-2 flex items-center gap-2 p-2"
|
11929
|
-
),
|
11930
|
-
children: [
|
11931
|
-
sub.icon,
|
11932
|
-
sub.name
|
11933
|
-
]
|
11934
|
-
},
|
11935
|
-
sub.name
|
11936
|
-
)) })
|
11937
|
-
] }, activeMenu.name) })
|
11938
|
-
}
|
11939
|
-
)
|
11940
|
-
] }),
|
11941
11997
|
children
|
11942
11998
|
] });
|
11943
11999
|
};
|
@@ -11957,7 +12013,7 @@ const Heading = (props) => {
|
|
11957
12013
|
/* @__PURE__ */ jsxRuntimeExports.jsxs(
|
11958
12014
|
"div",
|
11959
12015
|
{
|
11960
|
-
className:
|
12016
|
+
className: classNames(
|
11961
12017
|
"flex justify-between items-end ",
|
11962
12018
|
classNameWrapHeading
|
11963
12019
|
),
|
@@ -11983,5 +12039,197 @@ const Divider = ({ children, ...rest }) => {
|
|
11983
12039
|
return /* @__PURE__ */ jsxRuntimeExports.jsx(Divider$2, { ...rest, children });
|
11984
12040
|
};
|
11985
12041
|
|
11986
|
-
|
11987
|
-
|
12042
|
+
const Alert = (props) => {
|
12043
|
+
return /* @__PURE__ */ jsxRuntimeExports.jsx(Alert$1, { ...props });
|
12044
|
+
};
|
12045
|
+
|
12046
|
+
const Spin = ({ children, ...rest }) => {
|
12047
|
+
return /* @__PURE__ */ jsxRuntimeExports.jsx(Spin$1, { ...rest, children });
|
12048
|
+
};
|
12049
|
+
|
12050
|
+
const Drawer = ({ onSubmit, children, ...rest }) => {
|
12051
|
+
return /* @__PURE__ */ jsxRuntimeExports.jsx(Drawer$1, { ...rest, children: onSubmit ? /* @__PURE__ */ jsxRuntimeExports.jsx(
|
12052
|
+
"form",
|
12053
|
+
{
|
12054
|
+
id: "pnkx-form",
|
12055
|
+
onSubmit: (e) => {
|
12056
|
+
e.preventDefault();
|
12057
|
+
onSubmit?.(e);
|
12058
|
+
},
|
12059
|
+
method: "POST",
|
12060
|
+
children
|
12061
|
+
}
|
12062
|
+
) : children });
|
12063
|
+
};
|
12064
|
+
|
12065
|
+
const Popconfirm = ({ children, ...rest }) => {
|
12066
|
+
return /* @__PURE__ */ jsxRuntimeExports.jsx(Popconfirm$1, { ...rest, children });
|
12067
|
+
};
|
12068
|
+
|
12069
|
+
const QRCode = (props) => {
|
12070
|
+
return /* @__PURE__ */ jsxRuntimeExports.jsx(QRCode$1, { ...props });
|
12071
|
+
};
|
12072
|
+
|
12073
|
+
const Result = ({ children, ...rest }) => {
|
12074
|
+
return /* @__PURE__ */ jsxRuntimeExports.jsx(Result$1, { ...rest, children });
|
12075
|
+
};
|
12076
|
+
|
12077
|
+
const Rate = (props) => {
|
12078
|
+
return /* @__PURE__ */ jsxRuntimeExports.jsx(Rate$1, { ...props });
|
12079
|
+
};
|
12080
|
+
|
12081
|
+
const Segmented = (props) => {
|
12082
|
+
return /* @__PURE__ */ jsxRuntimeExports.jsx(Segmented$1, { ...props });
|
12083
|
+
};
|
12084
|
+
|
12085
|
+
const Statistic = (props) => {
|
12086
|
+
return /* @__PURE__ */ jsxRuntimeExports.jsx(Statistic$1, { ...props });
|
12087
|
+
};
|
12088
|
+
|
12089
|
+
const Timeline = (props) => {
|
12090
|
+
return /* @__PURE__ */ jsxRuntimeExports.jsx(Timeline$1, { ...props });
|
12091
|
+
};
|
12092
|
+
|
12093
|
+
const Tour = (props) => {
|
12094
|
+
return /* @__PURE__ */ jsxRuntimeExports.jsx(Tour$1, { ...props });
|
12095
|
+
};
|
12096
|
+
|
12097
|
+
const Tree = (props) => {
|
12098
|
+
return /* @__PURE__ */ jsxRuntimeExports.jsx(Tree$1, { ...props });
|
12099
|
+
};
|
12100
|
+
|
12101
|
+
const Watermark = ({ ...rest }) => {
|
12102
|
+
const { Paragraph } = Typography;
|
12103
|
+
return /* @__PURE__ */ jsxRuntimeExports.jsx(Flex$1, { gap: "middle", children: /* @__PURE__ */ jsxRuntimeExports.jsxs(Watermark$1, { ...rest, children: [
|
12104
|
+
/* @__PURE__ */ jsxRuntimeExports.jsxs(Typography, { children: [
|
12105
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx(Paragraph, { children: "The light-speed iteration of the digital world makes products more complex. However, human consciousness and attention resources are limited. Facing this design contradiction, the pursuit of natural interaction will be the consistent direction of Ant Design." }),
|
12106
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx(Paragraph, { children: "Natural user cognition: According to cognitive psychology, about 80% of external information is obtained through visual channels. The most important visual elements in the interface design, including layout, colors, illustrations, icons, etc., should fully absorb the laws of nature, thereby reducing the user's cognitive cost and bringing authentic and smooth feelings. In some scenarios, opportunely adding other sensory channels such as hearing, touch can create a richer and more natural product experience." }),
|
12107
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx(Paragraph, { children: "Natural user behavior: In the interaction with the system, the designer should fully understand the relationship between users, system roles, and task objectives, and also contextually organize system functions and services. At the same time, a series of methods such as behavior analysis, artificial intelligence and sensors could be applied to assist users to make effective decisions and reduce extra operations of users, to save users' mental and physical resources and make human-computer interaction more natural." })
|
12108
|
+
] }),
|
12109
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx(
|
12110
|
+
"img",
|
12111
|
+
{
|
12112
|
+
style: {
|
12113
|
+
zIndex: 10,
|
12114
|
+
width: "100%",
|
12115
|
+
maxWidth: 800,
|
12116
|
+
position: "relative"
|
12117
|
+
},
|
12118
|
+
src: "https://gw.alipayobjects.com/mdn/rms_08e378/afts/img/A*zx7LTI_ECSAAAAAAAAAAAABkARQnAQ",
|
12119
|
+
alt: "img"
|
12120
|
+
}
|
12121
|
+
)
|
12122
|
+
] }) });
|
12123
|
+
};
|
12124
|
+
|
12125
|
+
const AnchorContext = /*#__PURE__*/React.createContext(undefined);
|
12126
|
+
|
12127
|
+
const AnchorLink = props => {
|
12128
|
+
const {
|
12129
|
+
href,
|
12130
|
+
title,
|
12131
|
+
prefixCls: customizePrefixCls,
|
12132
|
+
children,
|
12133
|
+
className,
|
12134
|
+
target,
|
12135
|
+
replace
|
12136
|
+
} = props;
|
12137
|
+
const context = React.useContext(AnchorContext);
|
12138
|
+
const {
|
12139
|
+
registerLink,
|
12140
|
+
unregisterLink,
|
12141
|
+
scrollTo,
|
12142
|
+
onClick,
|
12143
|
+
activeLink,
|
12144
|
+
direction
|
12145
|
+
} = context || {};
|
12146
|
+
React.useEffect(() => {
|
12147
|
+
registerLink === null || registerLink === void 0 ? void 0 : registerLink(href);
|
12148
|
+
return () => {
|
12149
|
+
unregisterLink === null || unregisterLink === void 0 ? void 0 : unregisterLink(href);
|
12150
|
+
};
|
12151
|
+
}, [href]);
|
12152
|
+
const handleClick = e => {
|
12153
|
+
onClick === null || onClick === void 0 ? void 0 : onClick(e, {
|
12154
|
+
title,
|
12155
|
+
href
|
12156
|
+
});
|
12157
|
+
scrollTo === null || scrollTo === void 0 ? void 0 : scrollTo(href);
|
12158
|
+
// Support clicking on an anchor does not record history.
|
12159
|
+
if (e.defaultPrevented) {
|
12160
|
+
return;
|
12161
|
+
}
|
12162
|
+
const isExternalLink = href.startsWith('http://') || href.startsWith('https://');
|
12163
|
+
// Support external link
|
12164
|
+
if (isExternalLink) {
|
12165
|
+
if (replace) {
|
12166
|
+
e.preventDefault();
|
12167
|
+
window.location.replace(href);
|
12168
|
+
}
|
12169
|
+
return;
|
12170
|
+
}
|
12171
|
+
// Handling internal anchor link
|
12172
|
+
e.preventDefault();
|
12173
|
+
const historyMethod = replace ? 'replaceState' : 'pushState';
|
12174
|
+
window.history[historyMethod](null, '', href);
|
12175
|
+
};
|
12176
|
+
// =================== Warning =====================
|
12177
|
+
if (process.env.NODE_ENV !== 'production') {
|
12178
|
+
const warning = devUseWarning('Anchor.Link');
|
12179
|
+
process.env.NODE_ENV !== "production" ? warning(!children || direction !== 'horizontal', 'usage', '`Anchor.Link children` is not supported when `Anchor` direction is horizontal') : void 0;
|
12180
|
+
}
|
12181
|
+
const {
|
12182
|
+
getPrefixCls
|
12183
|
+
} = React.useContext(ConfigContext);
|
12184
|
+
const prefixCls = getPrefixCls('anchor', customizePrefixCls);
|
12185
|
+
const active = activeLink === href;
|
12186
|
+
const wrapperClassName = classNames(`${prefixCls}-link`, className, {
|
12187
|
+
[`${prefixCls}-link-active`]: active
|
12188
|
+
});
|
12189
|
+
const titleClassName = classNames(`${prefixCls}-link-title`, {
|
12190
|
+
[`${prefixCls}-link-title-active`]: active
|
12191
|
+
});
|
12192
|
+
return /*#__PURE__*/React.createElement("div", {
|
12193
|
+
className: wrapperClassName
|
12194
|
+
}, /*#__PURE__*/React.createElement("a", {
|
12195
|
+
className: titleClassName,
|
12196
|
+
href: href,
|
12197
|
+
title: typeof title === 'string' ? title : '',
|
12198
|
+
target: target,
|
12199
|
+
onClick: handleClick
|
12200
|
+
}, title), direction !== 'horizontal' ? children : null);
|
12201
|
+
};
|
12202
|
+
|
12203
|
+
const AnchorComponent = (props) => {
|
12204
|
+
const { containerClassName, spaceClassName, ...restProps } = props;
|
12205
|
+
return /* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: containerClassName, children: /* @__PURE__ */ jsxRuntimeExports.jsx(Anchor$1, { className: spaceClassName, ...restProps }) });
|
12206
|
+
};
|
12207
|
+
AnchorComponent.Link = AnchorLink;
|
12208
|
+
const Anchor = AnchorComponent;
|
12209
|
+
|
12210
|
+
const Appfix = ({ children, ...rest }) => {
|
12211
|
+
return /* @__PURE__ */ jsxRuntimeExports.jsx(Affix, { ...rest, children });
|
12212
|
+
};
|
12213
|
+
|
12214
|
+
const AutoComplete = (props) => {
|
12215
|
+
return /* @__PURE__ */ jsxRuntimeExports.jsx(AutoComplete$1, { ...props, children: /* @__PURE__ */ jsxRuntimeExports.jsx(Input$1, {}) });
|
12216
|
+
};
|
12217
|
+
|
12218
|
+
const PnkxCollapse = (props) => {
|
12219
|
+
return /* @__PURE__ */ jsxRuntimeExports.jsx(Collapse, { ...props });
|
12220
|
+
};
|
12221
|
+
|
12222
|
+
const PnkxColorPicker = (props) => {
|
12223
|
+
return /* @__PURE__ */ jsxRuntimeExports.jsx(ColorPicker, { ...props });
|
12224
|
+
};
|
12225
|
+
|
12226
|
+
const Empty = (props) => {
|
12227
|
+
return /* @__PURE__ */ jsxRuntimeExports.jsx(Empty$2, { ...props });
|
12228
|
+
};
|
12229
|
+
|
12230
|
+
const Image = (props) => {
|
12231
|
+
return /* @__PURE__ */ jsxRuntimeExports.jsx(Image$1, { ...props });
|
12232
|
+
};
|
12233
|
+
|
12234
|
+
export { Alert as A, Button as B, CascaderField as C, Dropdown as D, Anchor as E, Flex as F, Appfix as G, Heading as H, AutoComplete as I, PnkxCollapse as J, PnkxColorPicker as K, Layout as L, Modal as M, Empty as N, Image as O, Popover as P, QRCode as Q, Row as R, Skeleton as S, Table as T, Watermark as W, Tooltip as a, Tabs as b, SearchFiltersForm as c, Container as d, Badge as e, Col as f, Breadcrumb as g, Space as h, Splitter as i, Menu as j, Pagination as k, Steps as l, Sidebar as m, Tag as n, Divider as o, Spin as p, Drawer as q, Popconfirm as r, Result as s, typeColorMap as t, Rate as u, Segmented as v, Statistic as w, Timeline as x, Tour as y, Tree as z };
|
12235
|
+
//# sourceMappingURL=Image-CFyQxi2B.js.map
|