@pnkx-lib/ui 1.9.255 → 1.9.256
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/ui/index.js
CHANGED
|
@@ -4904,37 +4904,38 @@ const DropListActions = ({
|
|
|
4904
4904
|
};
|
|
4905
4905
|
const renderContentPopover = () => {
|
|
4906
4906
|
return /* @__PURE__ */ jsx("div", { className: "flex flex-col", children: !isEmpty(listIcon) && listIcon?.map(
|
|
4907
|
-
(item, index) => (
|
|
4908
|
-
|
|
4909
|
-
|
|
4910
|
-
|
|
4911
|
-
|
|
4912
|
-
|
|
4913
|
-
|
|
4914
|
-
|
|
4915
|
-
|
|
4916
|
-
|
|
4917
|
-
|
|
4918
|
-
|
|
4919
|
-
|
|
4920
|
-
|
|
4921
|
-
|
|
4922
|
-
|
|
4923
|
-
|
|
4924
|
-
|
|
4925
|
-
|
|
4926
|
-
|
|
4927
|
-
|
|
4928
|
-
|
|
4929
|
-
|
|
4930
|
-
|
|
4931
|
-
/* @__PURE__ */ jsx("span", { children: item.name || "" })
|
|
4932
|
-
]
|
|
4907
|
+
(item, index) => item?.showTitle && /* @__PURE__ */ jsxs(
|
|
4908
|
+
"button",
|
|
4909
|
+
{
|
|
4910
|
+
className: twMerge(
|
|
4911
|
+
"flex gap-4 px-3 py-2 rounded-sm transition duration-200 hover:rounded-sm",
|
|
4912
|
+
IsShow(item?.arrShow) ? "hover:bg-[#F5F6F7] cursor-pointer" : "text-[#B2B7C2] cursor-not-allowed"
|
|
4913
|
+
),
|
|
4914
|
+
disabled: IsShow(item?.arrShow) ? false : true,
|
|
4915
|
+
onClick: () => {
|
|
4916
|
+
toggle();
|
|
4917
|
+
setNotifyContent({
|
|
4918
|
+
title: item?.title || "",
|
|
4919
|
+
content: item?.content || "",
|
|
4920
|
+
typeIcon: item?.typeIcon,
|
|
4921
|
+
handleCancel: () => {
|
|
4922
|
+
toggle();
|
|
4923
|
+
},
|
|
4924
|
+
handleSubmit: () => {
|
|
4925
|
+
if (item?.action) {
|
|
4926
|
+
item?.action();
|
|
4927
|
+
}
|
|
4928
|
+
toggle();
|
|
4929
|
+
}
|
|
4930
|
+
});
|
|
4933
4931
|
},
|
|
4934
|
-
|
|
4935
|
-
|
|
4932
|
+
children: [
|
|
4933
|
+
IsShow(item?.arrShow) ? item.iconDropList : item.iconDisable,
|
|
4934
|
+
/* @__PURE__ */ jsx("span", { children: item.name || "" })
|
|
4935
|
+
]
|
|
4936
|
+
},
|
|
4937
|
+
index
|
|
4936
4938
|
)
|
|
4937
|
-
// )
|
|
4938
4939
|
) });
|
|
4939
4940
|
};
|
|
4940
4941
|
//! Render
|
|
@@ -4967,7 +4968,7 @@ const BulkActions = ({
|
|
|
4967
4968
|
title: "Xác nhận khôi phục",
|
|
4968
4969
|
content: "Bạn có chắc chắn muốn khôi phục không?",
|
|
4969
4970
|
arrShow: [CATEGORY_LIST_ENUM?.DELETE, CATEGORY_LIST_ENUM?.REJECT],
|
|
4970
|
-
|
|
4971
|
+
showTitle: true
|
|
4971
4972
|
},
|
|
4972
4973
|
{
|
|
4973
4974
|
icon: /* @__PURE__ */ jsx(SendApprovalIcon, { stroke: "white" }),
|
|
@@ -4979,7 +4980,7 @@ const BulkActions = ({
|
|
|
4979
4980
|
title: "Xác nhận gửi duyệt",
|
|
4980
4981
|
content: "Bạn có chắc chắn muốn gửi duyệt không?",
|
|
4981
4982
|
arrShow: [CATEGORY_LIST_ENUM?.DRAFT],
|
|
4982
|
-
|
|
4983
|
+
showTitle: true
|
|
4983
4984
|
},
|
|
4984
4985
|
{
|
|
4985
4986
|
icon: /* @__PURE__ */ jsx(CancelSendApprovalIcon, { stroke: "white" }),
|
|
@@ -4991,7 +4992,7 @@ const BulkActions = ({
|
|
|
4991
4992
|
title: "Xác nhận hủy gửi duyệt",
|
|
4992
4993
|
content: "Bạn có chắc chắn muốn hủy gửi duyệt không?",
|
|
4993
4994
|
arrShow: [CATEGORY_LIST_ENUM?.WATING_APPROVAL],
|
|
4994
|
-
|
|
4995
|
+
showTitle: true
|
|
4995
4996
|
},
|
|
4996
4997
|
{
|
|
4997
4998
|
icon: /* @__PURE__ */ jsx(RefuseApprovalIcon, { stroke: "white" }),
|
|
@@ -5002,7 +5003,8 @@ const BulkActions = ({
|
|
|
5002
5003
|
typeIcon: "error",
|
|
5003
5004
|
title: "Xác nhận từ chối duyệt",
|
|
5004
5005
|
content: "Bạn có chắc chắn muốn từ chối duyệt không? Hành động này không thể hoàn tác.",
|
|
5005
|
-
arrShow: [CATEGORY_LIST_ENUM?.WATING_APPROVAL]
|
|
5006
|
+
arrShow: [CATEGORY_LIST_ENUM?.WATING_APPROVAL],
|
|
5007
|
+
showTitle: true
|
|
5006
5008
|
},
|
|
5007
5009
|
{
|
|
5008
5010
|
icon: /* @__PURE__ */ jsx(ApprovalIcon, { stroke: "white" }),
|
|
@@ -5014,7 +5016,7 @@ const BulkActions = ({
|
|
|
5014
5016
|
title: "Xác nhận duyệt",
|
|
5015
5017
|
content: "Bạn có chắc chắn muốn duyệt không?",
|
|
5016
5018
|
arrShow: [CATEGORY_LIST_ENUM?.WATING_APPROVAL],
|
|
5017
|
-
|
|
5019
|
+
showTitle: true
|
|
5018
5020
|
},
|
|
5019
5021
|
{
|
|
5020
5022
|
icon: /* @__PURE__ */ jsx(CancelApprovalIcon, { stroke: "white" }),
|
|
@@ -5026,7 +5028,7 @@ const BulkActions = ({
|
|
|
5026
5028
|
title: "Xác nhận hủy duyệt",
|
|
5027
5029
|
content: "Bạn có chắc chắn muốn hủy duyệt không?",
|
|
5028
5030
|
arrShow: [CATEGORY_LIST_ENUM?.ACTIVE],
|
|
5029
|
-
|
|
5031
|
+
showTitle: true
|
|
5030
5032
|
},
|
|
5031
5033
|
{
|
|
5032
5034
|
icon: /* @__PURE__ */ jsx(DeleteIcon, { fill: "white" }),
|
|
@@ -5042,7 +5044,7 @@ const BulkActions = ({
|
|
|
5042
5044
|
CATEGORY_LIST_ENUM?.ACTIVE,
|
|
5043
5045
|
CATEGORY_LIST_ENUM?.INACTIVE
|
|
5044
5046
|
],
|
|
5045
|
-
|
|
5047
|
+
showTitle: false
|
|
5046
5048
|
},
|
|
5047
5049
|
{
|
|
5048
5050
|
icon: /* @__PURE__ */ jsx(ActivateIcon, { stroke: "white" }),
|
|
@@ -5054,7 +5056,7 @@ const BulkActions = ({
|
|
|
5054
5056
|
title: "Xác nhận kích hoạt",
|
|
5055
5057
|
content: "Bạn có chắc chắn muốn kích hoạt không?",
|
|
5056
5058
|
arrShow: [CATEGORY_LIST_ENUM?.INACTIVE],
|
|
5057
|
-
|
|
5059
|
+
showTitle: true
|
|
5058
5060
|
},
|
|
5059
5061
|
{
|
|
5060
5062
|
icon: /* @__PURE__ */ jsx(InActiveIcon, { stroke: "white" }),
|
|
@@ -5066,7 +5068,7 @@ const BulkActions = ({
|
|
|
5066
5068
|
title: "Xác nhận vô hiệu hóa",
|
|
5067
5069
|
content: "Bạn có chắc chắn muốn vô hiệu hóa không?",
|
|
5068
5070
|
arrShow: [CATEGORY_LIST_ENUM?.ACTIVE],
|
|
5069
|
-
|
|
5071
|
+
showTitle: true
|
|
5070
5072
|
}
|
|
5071
5073
|
];
|
|
5072
5074
|
const { open, shouldRender, toggle } = useToggle();
|
package/package.json
CHANGED
|
@@ -17,7 +17,7 @@ export type TListIcon = {
|
|
|
17
17
|
content?: string;
|
|
18
18
|
typeIcon?: ConfirmModalProps["typeIcon"];
|
|
19
19
|
name?: string;
|
|
20
|
-
|
|
20
|
+
showTitle?: boolean;
|
|
21
21
|
};
|
|
22
22
|
export declare const BulkActions: ({ quantity, handleDelete, handleSubmitForApproval, handleCancelSubmission, handleApprove, handleCancelApproval, handleReject, handleDeactivate, handleActivate, handleRestore, status, typeBulkaction, }: IBulkActionsProps) => import("react/jsx-runtime").JSX.Element;
|
|
23
23
|
export {};
|