@fctc/sme-widget-ui 1.9.2 → 1.9.4

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 CHANGED
@@ -10132,8 +10132,8 @@ var en_default = {
10132
10132
  download_file: "Download this file",
10133
10133
  upload_success: "Upload file success",
10134
10134
  upload_failure: "Upload file failure",
10135
- file_accept_single: "Only JPEG, PNG, PDF, MP4, XLS, XLXS, ZIP formats are allowed, and each file should be up to 10MB.",
10136
- file_accept_total: "Only JPEG, PNG, PDF, MP4, XLS, XLXS, ZIP formats are allowed, and total should be up to 50MB.",
10135
+ file_accept_single: "Only JPEG, PNG, PDF, MP4, XLS, XLXS, ZIP, JSON formats are allowed, and each file should be up to 10MB.",
10136
+ file_accept_total: "Only JPEG, PNG, PDF, MP4, XLS, XLXS, ZIP, JSON formats are allowed, and total should be up to 50MB.",
10137
10137
  must_required: "is required",
10138
10138
  invalid_number: "Invalid number",
10139
10139
  active: "Active",
@@ -13227,6 +13227,7 @@ var M = import_react16.default.forwardRef(({ id: t3, anchorId: l2, anchorSelect:
13227
13227
  });
13228
13228
 
13229
13229
  // src/widgets/advanced/table/table-head.tsx
13230
+ var import_react_dom2 = require("react-dom");
13230
13231
  var import_jsx_runtime47 = require("react/jsx-runtime");
13231
13232
  var TableHead = (props) => {
13232
13233
  const {
@@ -13268,27 +13269,31 @@ var TableHead = (props) => {
13268
13269
  return /* @__PURE__ */ (0, import_jsx_runtime47.jsx)(
13269
13270
  "th",
13270
13271
  {
13272
+ "data-rtc-resizable": col?.name,
13271
13273
  className: `column whitespace-nowrap text-left p-3 text-sm font-semibold capitalize text-[#060606]`,
13272
13274
  children: /* @__PURE__ */ (0, import_jsx_runtime47.jsxs)("div", { className: "cursor-pointer flex items-center gap-[4px] w-full min-w-max group relative", children: [
13273
13275
  col.title,
13274
13276
  col?.field?.help && /* @__PURE__ */ (0, import_jsx_runtime47.jsxs)(import_jsx_runtime47.Fragment, { children: [
13275
- /* @__PURE__ */ (0, import_jsx_runtime47.jsx)(
13276
- M,
13277
- {
13278
- style: {
13279
- padding: "6px 12px",
13280
- fontSize: "12px",
13281
- borderRadius: "4px",
13282
- maxWidth: "200%",
13283
- whiteSpace: "wrap",
13284
- fontWeight: 400,
13285
- textTransform: "none"
13286
- },
13287
- id: `field-help-${col?.field?.name}`,
13288
- content: col?.field?.help,
13289
- place: "top",
13290
- className: "z-30"
13291
- }
13277
+ (0, import_react_dom2.createPortal)(
13278
+ /* @__PURE__ */ (0, import_jsx_runtime47.jsx)(
13279
+ M,
13280
+ {
13281
+ style: {
13282
+ padding: "6px 12px",
13283
+ fontSize: "12px",
13284
+ borderRadius: "4px",
13285
+ maxWidth: "200px",
13286
+ whiteSpace: "wrap",
13287
+ fontWeight: 400,
13288
+ textTransform: "none",
13289
+ zIndex: "9999"
13290
+ },
13291
+ id: `field-help-${col?.field?.name}`,
13292
+ content: col?.field?.help,
13293
+ place: "top"
13294
+ }
13295
+ ),
13296
+ document.body
13292
13297
  ),
13293
13298
  /* @__PURE__ */ (0, import_jsx_runtime47.jsx)(
13294
13299
  "span",
@@ -16415,7 +16420,7 @@ var ModalConfirm = ({
16415
16420
 
16416
16421
  // src/widgets/common/modal-detail.tsx
16417
16422
  var import_react24 = require("react");
16418
- var import_react_dom2 = require("react-dom");
16423
+ var import_react_dom3 = require("react-dom");
16419
16424
  var import_jsx_runtime65 = require("react/jsx-runtime");
16420
16425
  var ModalDetail = ({
16421
16426
  idToolTip,
@@ -16438,7 +16443,7 @@ var ModalDetail = ({
16438
16443
  sessionStorage.setItem("actionData", JSON.stringify(actionData));
16439
16444
  window.location.href = `/form/menu?model=${model}&id=${idForm}`;
16440
16445
  };
16441
- return (0, import_react_dom2.createPortal)(
16446
+ return (0, import_react_dom3.createPortal)(
16442
16447
  /* @__PURE__ */ (0, import_jsx_runtime65.jsx)(import_jsx_runtime65.Fragment, { children: showModalDetail && /* @__PURE__ */ (0, import_jsx_runtime65.jsxs)("div", { className: "fixed bottom-0 left-0 right-0 top-0 z-[100]", children: [
16443
16448
  /* @__PURE__ */ (0, import_jsx_runtime65.jsx)("div", { className: "absolute inset-0 bg-[rgba(27,27,27,0.48)]" }),
16444
16449
  /* @__PURE__ */ (0, import_jsx_runtime65.jsx)("div", { className: "absolute inset-0 overflow-auto flex flex-col justify-center items-center px-5", children: /* @__PURE__ */ (0, import_jsx_runtime65.jsxs)("div", { className: "relative z-[1] max-w-full p-4 flex flex-col gap-4 w-[1000px] transform rounded-3xl bg-[#FFF] h-[90%]", children: [
@@ -16979,7 +16984,8 @@ var ButtonSelectFiles = ({
16979
16984
  "application/zip",
16980
16985
  "application/x-zip-compressed",
16981
16986
  "application/vnd.ms-excel",
16982
- "application/vnd.openxmlformats-officedocument.spreadsheetml.sheet"
16987
+ "application/vnd.openxmlformats-officedocument.spreadsheetml.sheet",
16988
+ "application/json"
16983
16989
  ];
16984
16990
  const MAX_FILE_SIZE = 10 * 1024 * 1024;
16985
16991
  const MAX_TOTAL_SIZE = 50 * 1024 * 1024;
@@ -17080,7 +17086,7 @@ var ButtonSelectFiles = ({
17080
17086
  style: { display: "none" },
17081
17087
  onChange: handleOnChange,
17082
17088
  multiple: true,
17083
- accept: ".jpeg,.jpg,.png,.pdf,.mp4,.zip,application/vnd.openxmlformats-officedocument.spreadsheetml.sheet, application/vnd.ms-excel"
17089
+ accept: ".jpeg,.jpg,.png,.pdf,.json,.mp4,.zip,application/vnd.openxmlformats-officedocument.spreadsheetml.sheet, application/vnd.ms-excel"
17084
17090
  }
17085
17091
  )
17086
17092
  ] });
@@ -22379,7 +22385,7 @@ function useFloating2(options2) {
22379
22385
  }
22380
22386
 
22381
22387
  // node_modules/react-datepicker/dist/index.es.js
22382
- var import_react_dom5 = __toESM(require("react-dom"));
22388
+ var import_react_dom6 = __toESM(require("react-dom"));
22383
22389
  var _extendStatics = function extendStatics(d, b2) {
22384
22390
  _extendStatics = Object.setPrototypeOf || {
22385
22391
  __proto__: []
@@ -25622,7 +25628,7 @@ var Portal = (
25622
25628
  }
25623
25629
  };
25624
25630
  Portal2.prototype.render = function() {
25625
- return import_react_dom5.default.createPortal(this.props.children, this.el);
25631
+ return import_react_dom6.default.createPortal(this.props.children, this.el);
25626
25632
  };
25627
25633
  return Portal2;
25628
25634
  }(import_react44.Component)
@@ -28190,7 +28196,7 @@ function _taggedTemplateLiteral(e3, t3) {
28190
28196
 
28191
28197
  // node_modules/react-select/dist/index-641ee5b8.esm.js
28192
28198
  var import_react50 = require("react");
28193
- var import_react_dom6 = require("react-dom");
28199
+ var import_react_dom7 = require("react-dom");
28194
28200
 
28195
28201
  // node_modules/use-isomorphic-layout-effect/dist/use-isomorphic-layout-effect.esm.js
28196
28202
  var import_react48 = require("react");
@@ -28693,7 +28699,7 @@ var MenuPortal = function MenuPortal2(props) {
28693
28699
  }), innerProps), children);
28694
28700
  return jsx81(PortalPlacementContext.Provider, {
28695
28701
  value: portalPlacementContext
28696
- }, appendTo ? /* @__PURE__ */ (0, import_react_dom6.createPortal)(menuWrapper, appendTo) : menuWrapper);
28702
+ }, appendTo ? /* @__PURE__ */ (0, import_react_dom7.createPortal)(menuWrapper, appendTo) : menuWrapper);
28697
28703
  };
28698
28704
  var containerCSS = function containerCSS2(_ref3) {
28699
28705
  var isDisabled = _ref3.isDisabled, isRtl = _ref3.isRtl;
@@ -31586,7 +31592,7 @@ var import_toConsumableArray2 = __toESM(require_toConsumableArray());
31586
31592
  var import_typeof5 = __toESM(require_typeof());
31587
31593
  var import_taggedTemplateLiteral2 = __toESM(require_taggedTemplateLiteral());
31588
31594
  var import_defineProperty3 = __toESM(require_defineProperty());
31589
- var import_react_dom7 = require("react-dom");
31595
+ var import_react_dom8 = require("react-dom");
31590
31596
  var StateManagedSelect = /* @__PURE__ */ (0, import_react53.forwardRef)(function(props, ref) {
31591
31597
  var baseSelectProps = useStateManager(props);
31592
31598
  return /* @__PURE__ */ React14.createElement(Select, _extends({
@@ -32118,7 +32124,7 @@ var FileUploadField = (props) => {
32118
32124
  );
32119
32125
  }
32120
32126
  }, [selectedFiles]);
32121
- return /* @__PURE__ */ (0, import_jsx_runtime86.jsxs)("div", { className: "file-upload-field", children: [
32127
+ return /* @__PURE__ */ (0, import_jsx_runtime86.jsxs)("div", { children: [
32122
32128
  selectedFiles?.length > 0 && selectedFiles?.map((fileItem, index4) => /* @__PURE__ */ (0, import_jsx_runtime86.jsx)(
32123
32129
  RenderFile,
32124
32130
  {
@@ -33533,7 +33539,7 @@ var StatusDropdownField = (props) => {
33533
33539
  };
33534
33540
 
33535
33541
  // src/widgets/basic/many2many-field/many2many.tsx
33536
- var import_react_dom8 = require("react-dom");
33542
+ var import_react_dom9 = require("react-dom");
33537
33543
  var import_react65 = require("react");
33538
33544
  var import_jsx_runtime104 = require("react/jsx-runtime");
33539
33545
  var Many2ManyField = (props) => {
@@ -33608,7 +33614,7 @@ var Many2ManyField = (props) => {
33608
33614
  typeof setGroupByList === "function" && setGroupByList(null);
33609
33615
  };
33610
33616
  }, [selectedTags]);
33611
- return (0, import_react_dom8.createPortal)(
33617
+ return (0, import_react_dom9.createPortal)(
33612
33618
  /* @__PURE__ */ (0, import_jsx_runtime104.jsxs)(
33613
33619
  "div",
33614
33620
  {
package/dist/index.mjs CHANGED
@@ -10009,8 +10009,8 @@ var en_default = {
10009
10009
  download_file: "Download this file",
10010
10010
  upload_success: "Upload file success",
10011
10011
  upload_failure: "Upload file failure",
10012
- file_accept_single: "Only JPEG, PNG, PDF, MP4, XLS, XLXS, ZIP formats are allowed, and each file should be up to 10MB.",
10013
- file_accept_total: "Only JPEG, PNG, PDF, MP4, XLS, XLXS, ZIP formats are allowed, and total should be up to 50MB.",
10012
+ file_accept_single: "Only JPEG, PNG, PDF, MP4, XLS, XLXS, ZIP, JSON formats are allowed, and each file should be up to 10MB.",
10013
+ file_accept_total: "Only JPEG, PNG, PDF, MP4, XLS, XLXS, ZIP, JSON formats are allowed, and total should be up to 50MB.",
10014
10014
  must_required: "is required",
10015
10015
  invalid_number: "Invalid number",
10016
10016
  active: "Active",
@@ -13104,6 +13104,7 @@ var M = e2.forwardRef(({ id: t3, anchorId: l2, anchorSelect: n4, content: i3, ht
13104
13104
  });
13105
13105
 
13106
13106
  // src/widgets/advanced/table/table-head.tsx
13107
+ import { createPortal as createPortal2 } from "react-dom";
13107
13108
  import { Fragment as Fragment4, jsx as jsx47, jsxs as jsxs26 } from "react/jsx-runtime";
13108
13109
  var TableHead = (props) => {
13109
13110
  const {
@@ -13145,27 +13146,31 @@ var TableHead = (props) => {
13145
13146
  return /* @__PURE__ */ jsx47(
13146
13147
  "th",
13147
13148
  {
13149
+ "data-rtc-resizable": col?.name,
13148
13150
  className: `column whitespace-nowrap text-left p-3 text-sm font-semibold capitalize text-[#060606]`,
13149
13151
  children: /* @__PURE__ */ jsxs26("div", { className: "cursor-pointer flex items-center gap-[4px] w-full min-w-max group relative", children: [
13150
13152
  col.title,
13151
13153
  col?.field?.help && /* @__PURE__ */ jsxs26(Fragment4, { children: [
13152
- /* @__PURE__ */ jsx47(
13153
- M,
13154
- {
13155
- style: {
13156
- padding: "6px 12px",
13157
- fontSize: "12px",
13158
- borderRadius: "4px",
13159
- maxWidth: "200%",
13160
- whiteSpace: "wrap",
13161
- fontWeight: 400,
13162
- textTransform: "none"
13163
- },
13164
- id: `field-help-${col?.field?.name}`,
13165
- content: col?.field?.help,
13166
- place: "top",
13167
- className: "z-30"
13168
- }
13154
+ createPortal2(
13155
+ /* @__PURE__ */ jsx47(
13156
+ M,
13157
+ {
13158
+ style: {
13159
+ padding: "6px 12px",
13160
+ fontSize: "12px",
13161
+ borderRadius: "4px",
13162
+ maxWidth: "200px",
13163
+ whiteSpace: "wrap",
13164
+ fontWeight: 400,
13165
+ textTransform: "none",
13166
+ zIndex: "9999"
13167
+ },
13168
+ id: `field-help-${col?.field?.name}`,
13169
+ content: col?.field?.help,
13170
+ place: "top"
13171
+ }
13172
+ ),
13173
+ document.body
13169
13174
  ),
13170
13175
  /* @__PURE__ */ jsx47(
13171
13176
  "span",
@@ -16292,7 +16297,7 @@ var ModalConfirm = ({
16292
16297
 
16293
16298
  // src/widgets/common/modal-detail.tsx
16294
16299
  import { useState as useState7 } from "react";
16295
- import { createPortal as createPortal2 } from "react-dom";
16300
+ import { createPortal as createPortal3 } from "react-dom";
16296
16301
  import { Fragment as Fragment13, jsx as jsx65, jsxs as jsxs41 } from "react/jsx-runtime";
16297
16302
  var ModalDetail = ({
16298
16303
  idToolTip,
@@ -16315,7 +16320,7 @@ var ModalDetail = ({
16315
16320
  sessionStorage.setItem("actionData", JSON.stringify(actionData));
16316
16321
  window.location.href = `/form/menu?model=${model}&id=${idForm}`;
16317
16322
  };
16318
- return createPortal2(
16323
+ return createPortal3(
16319
16324
  /* @__PURE__ */ jsx65(Fragment13, { children: showModalDetail && /* @__PURE__ */ jsxs41("div", { className: "fixed bottom-0 left-0 right-0 top-0 z-[100]", children: [
16320
16325
  /* @__PURE__ */ jsx65("div", { className: "absolute inset-0 bg-[rgba(27,27,27,0.48)]" }),
16321
16326
  /* @__PURE__ */ jsx65("div", { className: "absolute inset-0 overflow-auto flex flex-col justify-center items-center px-5", children: /* @__PURE__ */ jsxs41("div", { className: "relative z-[1] max-w-full p-4 flex flex-col gap-4 w-[1000px] transform rounded-3xl bg-[#FFF] h-[90%]", children: [
@@ -16856,7 +16861,8 @@ var ButtonSelectFiles = ({
16856
16861
  "application/zip",
16857
16862
  "application/x-zip-compressed",
16858
16863
  "application/vnd.ms-excel",
16859
- "application/vnd.openxmlformats-officedocument.spreadsheetml.sheet"
16864
+ "application/vnd.openxmlformats-officedocument.spreadsheetml.sheet",
16865
+ "application/json"
16860
16866
  ];
16861
16867
  const MAX_FILE_SIZE = 10 * 1024 * 1024;
16862
16868
  const MAX_TOTAL_SIZE = 50 * 1024 * 1024;
@@ -16957,7 +16963,7 @@ var ButtonSelectFiles = ({
16957
16963
  style: { display: "none" },
16958
16964
  onChange: handleOnChange,
16959
16965
  multiple: true,
16960
- accept: ".jpeg,.jpg,.png,.pdf,.mp4,.zip,application/vnd.openxmlformats-officedocument.spreadsheetml.sheet, application/vnd.ms-excel"
16966
+ accept: ".jpeg,.jpg,.png,.pdf,.json,.mp4,.zip,application/vnd.openxmlformats-officedocument.spreadsheetml.sheet, application/vnd.ms-excel"
16961
16967
  }
16962
16968
  )
16963
16969
  ] });
@@ -28067,7 +28073,7 @@ function _taggedTemplateLiteral(e3, t3) {
28067
28073
 
28068
28074
  // node_modules/react-select/dist/index-641ee5b8.esm.js
28069
28075
  import { useContext as useContext9, useRef as useRef13, useState as useState15, useMemo as useMemo7, useCallback as useCallback7, createContext as createContext5 } from "react";
28070
- import { createPortal as createPortal4 } from "react-dom";
28076
+ import { createPortal as createPortal5 } from "react-dom";
28071
28077
 
28072
28078
  // node_modules/use-isomorphic-layout-effect/dist/use-isomorphic-layout-effect.esm.js
28073
28079
  import { useLayoutEffect as useLayoutEffect4 } from "react";
@@ -28570,7 +28576,7 @@ var MenuPortal = function MenuPortal2(props) {
28570
28576
  }), innerProps), children);
28571
28577
  return jsx81(PortalPlacementContext.Provider, {
28572
28578
  value: portalPlacementContext
28573
- }, appendTo ? /* @__PURE__ */ createPortal4(menuWrapper, appendTo) : menuWrapper);
28579
+ }, appendTo ? /* @__PURE__ */ createPortal5(menuWrapper, appendTo) : menuWrapper);
28574
28580
  };
28575
28581
  var containerCSS = function containerCSS2(_ref3) {
28576
28582
  var isDisabled = _ref3.isDisabled, isRtl = _ref3.isRtl;
@@ -31995,7 +32001,7 @@ var FileUploadField = (props) => {
31995
32001
  );
31996
32002
  }
31997
32003
  }, [selectedFiles]);
31998
- return /* @__PURE__ */ jsxs58("div", { className: "file-upload-field", children: [
32004
+ return /* @__PURE__ */ jsxs58("div", { children: [
31999
32005
  selectedFiles?.length > 0 && selectedFiles?.map((fileItem, index4) => /* @__PURE__ */ jsx88(
32000
32006
  RenderFile,
32001
32007
  {
@@ -33410,7 +33416,7 @@ var StatusDropdownField = (props) => {
33410
33416
  };
33411
33417
 
33412
33418
  // src/widgets/basic/many2many-field/many2many.tsx
33413
- import { createPortal as createPortal5 } from "react-dom";
33419
+ import { createPortal as createPortal6 } from "react-dom";
33414
33420
  import { useEffect as useEffect26 } from "react";
33415
33421
  import { jsx as jsx106, jsxs as jsxs71 } from "react/jsx-runtime";
33416
33422
  var Many2ManyField = (props) => {
@@ -33485,7 +33491,7 @@ var Many2ManyField = (props) => {
33485
33491
  typeof setGroupByList === "function" && setGroupByList(null);
33486
33492
  };
33487
33493
  }, [selectedTags]);
33488
- return createPortal5(
33494
+ return createPortal6(
33489
33495
  /* @__PURE__ */ jsxs71(
33490
33496
  "div",
33491
33497
  {
package/dist/utils.js CHANGED
@@ -6894,8 +6894,8 @@ var en_default = {
6894
6894
  download_file: "Download this file",
6895
6895
  upload_success: "Upload file success",
6896
6896
  upload_failure: "Upload file failure",
6897
- file_accept_single: "Only JPEG, PNG, PDF, MP4, XLS, XLXS, ZIP formats are allowed, and each file should be up to 10MB.",
6898
- file_accept_total: "Only JPEG, PNG, PDF, MP4, XLS, XLXS, ZIP formats are allowed, and total should be up to 50MB.",
6897
+ file_accept_single: "Only JPEG, PNG, PDF, MP4, XLS, XLXS, ZIP, JSON formats are allowed, and each file should be up to 10MB.",
6898
+ file_accept_total: "Only JPEG, PNG, PDF, MP4, XLS, XLXS, ZIP, JSON formats are allowed, and total should be up to 50MB.",
6899
6899
  must_required: "is required",
6900
6900
  invalid_number: "Invalid number",
6901
6901
  active: "Active",
package/dist/utils.mjs CHANGED
@@ -6871,8 +6871,8 @@ var en_default = {
6871
6871
  download_file: "Download this file",
6872
6872
  upload_success: "Upload file success",
6873
6873
  upload_failure: "Upload file failure",
6874
- file_accept_single: "Only JPEG, PNG, PDF, MP4, XLS, XLXS, ZIP formats are allowed, and each file should be up to 10MB.",
6875
- file_accept_total: "Only JPEG, PNG, PDF, MP4, XLS, XLXS, ZIP formats are allowed, and total should be up to 50MB.",
6874
+ file_accept_single: "Only JPEG, PNG, PDF, MP4, XLS, XLXS, ZIP, JSON formats are allowed, and each file should be up to 10MB.",
6875
+ file_accept_total: "Only JPEG, PNG, PDF, MP4, XLS, XLXS, ZIP, JSON formats are allowed, and total should be up to 50MB.",
6876
6876
  must_required: "is required",
6877
6877
  invalid_number: "Invalid number",
6878
6878
  active: "Active",
package/dist/widgets.js CHANGED
@@ -7818,8 +7818,8 @@ var en_default = {
7818
7818
  download_file: "Download this file",
7819
7819
  upload_success: "Upload file success",
7820
7820
  upload_failure: "Upload file failure",
7821
- file_accept_single: "Only JPEG, PNG, PDF, MP4, XLS, XLXS, ZIP formats are allowed, and each file should be up to 10MB.",
7822
- file_accept_total: "Only JPEG, PNG, PDF, MP4, XLS, XLXS, ZIP formats are allowed, and total should be up to 50MB.",
7821
+ file_accept_single: "Only JPEG, PNG, PDF, MP4, XLS, XLXS, ZIP, JSON formats are allowed, and each file should be up to 10MB.",
7822
+ file_accept_total: "Only JPEG, PNG, PDF, MP4, XLS, XLXS, ZIP, JSON formats are allowed, and total should be up to 50MB.",
7823
7823
  must_required: "is required",
7824
7824
  invalid_number: "Invalid number",
7825
7825
  active: "Active",
@@ -12621,6 +12621,7 @@ var M = import_react16.default.forwardRef(({ id: t3, anchorId: l2, anchorSelect:
12621
12621
  });
12622
12622
 
12623
12623
  // src/widgets/advanced/table/table-head.tsx
12624
+ var import_react_dom2 = require("react-dom");
12624
12625
  var import_jsx_runtime47 = require("react/jsx-runtime");
12625
12626
  var TableHead = (props) => {
12626
12627
  const {
@@ -12662,27 +12663,31 @@ var TableHead = (props) => {
12662
12663
  return /* @__PURE__ */ (0, import_jsx_runtime47.jsx)(
12663
12664
  "th",
12664
12665
  {
12666
+ "data-rtc-resizable": col?.name,
12665
12667
  className: `column whitespace-nowrap text-left p-3 text-sm font-semibold capitalize text-[#060606]`,
12666
12668
  children: /* @__PURE__ */ (0, import_jsx_runtime47.jsxs)("div", { className: "cursor-pointer flex items-center gap-[4px] w-full min-w-max group relative", children: [
12667
12669
  col.title,
12668
12670
  col?.field?.help && /* @__PURE__ */ (0, import_jsx_runtime47.jsxs)(import_jsx_runtime47.Fragment, { children: [
12669
- /* @__PURE__ */ (0, import_jsx_runtime47.jsx)(
12670
- M,
12671
- {
12672
- style: {
12673
- padding: "6px 12px",
12674
- fontSize: "12px",
12675
- borderRadius: "4px",
12676
- maxWidth: "200%",
12677
- whiteSpace: "wrap",
12678
- fontWeight: 400,
12679
- textTransform: "none"
12680
- },
12681
- id: `field-help-${col?.field?.name}`,
12682
- content: col?.field?.help,
12683
- place: "top",
12684
- className: "z-30"
12685
- }
12671
+ (0, import_react_dom2.createPortal)(
12672
+ /* @__PURE__ */ (0, import_jsx_runtime47.jsx)(
12673
+ M,
12674
+ {
12675
+ style: {
12676
+ padding: "6px 12px",
12677
+ fontSize: "12px",
12678
+ borderRadius: "4px",
12679
+ maxWidth: "200px",
12680
+ whiteSpace: "wrap",
12681
+ fontWeight: 400,
12682
+ textTransform: "none",
12683
+ zIndex: "9999"
12684
+ },
12685
+ id: `field-help-${col?.field?.name}`,
12686
+ content: col?.field?.help,
12687
+ place: "top"
12688
+ }
12689
+ ),
12690
+ document.body
12686
12691
  ),
12687
12692
  /* @__PURE__ */ (0, import_jsx_runtime47.jsx)(
12688
12693
  "span",
@@ -15820,7 +15825,7 @@ var ModalConfirm = ({
15820
15825
 
15821
15826
  // src/widgets/common/modal-detail.tsx
15822
15827
  var import_react24 = require("react");
15823
- var import_react_dom2 = require("react-dom");
15828
+ var import_react_dom3 = require("react-dom");
15824
15829
  var import_jsx_runtime65 = require("react/jsx-runtime");
15825
15830
  var ModalDetail = ({
15826
15831
  idToolTip,
@@ -15843,7 +15848,7 @@ var ModalDetail = ({
15843
15848
  sessionStorage.setItem("actionData", JSON.stringify(actionData));
15844
15849
  window.location.href = `/form/menu?model=${model}&id=${idForm}`;
15845
15850
  };
15846
- return (0, import_react_dom2.createPortal)(
15851
+ return (0, import_react_dom3.createPortal)(
15847
15852
  /* @__PURE__ */ (0, import_jsx_runtime65.jsx)(import_jsx_runtime65.Fragment, { children: showModalDetail && /* @__PURE__ */ (0, import_jsx_runtime65.jsxs)("div", { className: "fixed bottom-0 left-0 right-0 top-0 z-[100]", children: [
15848
15853
  /* @__PURE__ */ (0, import_jsx_runtime65.jsx)("div", { className: "absolute inset-0 bg-[rgba(27,27,27,0.48)]" }),
15849
15854
  /* @__PURE__ */ (0, import_jsx_runtime65.jsx)("div", { className: "absolute inset-0 overflow-auto flex flex-col justify-center items-center px-5", children: /* @__PURE__ */ (0, import_jsx_runtime65.jsxs)("div", { className: "relative z-[1] max-w-full p-4 flex flex-col gap-4 w-[1000px] transform rounded-3xl bg-[#FFF] h-[90%]", children: [
@@ -16384,7 +16389,8 @@ var ButtonSelectFiles = ({
16384
16389
  "application/zip",
16385
16390
  "application/x-zip-compressed",
16386
16391
  "application/vnd.ms-excel",
16387
- "application/vnd.openxmlformats-officedocument.spreadsheetml.sheet"
16392
+ "application/vnd.openxmlformats-officedocument.spreadsheetml.sheet",
16393
+ "application/json"
16388
16394
  ];
16389
16395
  const MAX_FILE_SIZE = 10 * 1024 * 1024;
16390
16396
  const MAX_TOTAL_SIZE = 50 * 1024 * 1024;
@@ -16485,7 +16491,7 @@ var ButtonSelectFiles = ({
16485
16491
  style: { display: "none" },
16486
16492
  onChange: handleOnChange,
16487
16493
  multiple: true,
16488
- accept: ".jpeg,.jpg,.png,.pdf,.mp4,.zip,application/vnd.openxmlformats-officedocument.spreadsheetml.sheet, application/vnd.ms-excel"
16494
+ accept: ".jpeg,.jpg,.png,.pdf,.json,.mp4,.zip,application/vnd.openxmlformats-officedocument.spreadsheetml.sheet, application/vnd.ms-excel"
16489
16495
  }
16490
16496
  )
16491
16497
  ] });
@@ -21784,7 +21790,7 @@ function useFloating2(options2) {
21784
21790
  }
21785
21791
 
21786
21792
  // node_modules/react-datepicker/dist/index.es.js
21787
- var import_react_dom5 = __toESM(require("react-dom"));
21793
+ var import_react_dom6 = __toESM(require("react-dom"));
21788
21794
  var _extendStatics = function extendStatics(d, b2) {
21789
21795
  _extendStatics = Object.setPrototypeOf || {
21790
21796
  __proto__: []
@@ -25027,7 +25033,7 @@ var Portal = (
25027
25033
  }
25028
25034
  };
25029
25035
  Portal2.prototype.render = function() {
25030
- return import_react_dom5.default.createPortal(this.props.children, this.el);
25036
+ return import_react_dom6.default.createPortal(this.props.children, this.el);
25031
25037
  };
25032
25038
  return Portal2;
25033
25039
  }(import_react44.Component)
@@ -27595,7 +27601,7 @@ function _taggedTemplateLiteral(e3, t3) {
27595
27601
 
27596
27602
  // node_modules/react-select/dist/index-641ee5b8.esm.js
27597
27603
  var import_react50 = require("react");
27598
- var import_react_dom6 = require("react-dom");
27604
+ var import_react_dom7 = require("react-dom");
27599
27605
 
27600
27606
  // node_modules/use-isomorphic-layout-effect/dist/use-isomorphic-layout-effect.esm.js
27601
27607
  var import_react48 = require("react");
@@ -28098,7 +28104,7 @@ var MenuPortal = function MenuPortal2(props) {
28098
28104
  }), innerProps), children);
28099
28105
  return jsx81(PortalPlacementContext.Provider, {
28100
28106
  value: portalPlacementContext
28101
- }, appendTo ? /* @__PURE__ */ (0, import_react_dom6.createPortal)(menuWrapper, appendTo) : menuWrapper);
28107
+ }, appendTo ? /* @__PURE__ */ (0, import_react_dom7.createPortal)(menuWrapper, appendTo) : menuWrapper);
28102
28108
  };
28103
28109
  var containerCSS = function containerCSS2(_ref3) {
28104
28110
  var isDisabled = _ref3.isDisabled, isRtl = _ref3.isRtl;
@@ -30991,7 +30997,7 @@ var import_toConsumableArray2 = __toESM(require_toConsumableArray());
30991
30997
  var import_typeof5 = __toESM(require_typeof());
30992
30998
  var import_taggedTemplateLiteral2 = __toESM(require_taggedTemplateLiteral());
30993
30999
  var import_defineProperty3 = __toESM(require_defineProperty());
30994
- var import_react_dom7 = require("react-dom");
31000
+ var import_react_dom8 = require("react-dom");
30995
31001
  var StateManagedSelect = /* @__PURE__ */ (0, import_react53.forwardRef)(function(props, ref) {
30996
31002
  var baseSelectProps = useStateManager(props);
30997
31003
  return /* @__PURE__ */ React14.createElement(Select, _extends({
@@ -31523,7 +31529,7 @@ var FileUploadField = (props) => {
31523
31529
  );
31524
31530
  }
31525
31531
  }, [selectedFiles]);
31526
- return /* @__PURE__ */ (0, import_jsx_runtime86.jsxs)("div", { className: "file-upload-field", children: [
31532
+ return /* @__PURE__ */ (0, import_jsx_runtime86.jsxs)("div", { children: [
31527
31533
  selectedFiles?.length > 0 && selectedFiles?.map((fileItem, index4) => /* @__PURE__ */ (0, import_jsx_runtime86.jsx)(
31528
31534
  RenderFile,
31529
31535
  {
@@ -32938,7 +32944,7 @@ var StatusDropdownField = (props) => {
32938
32944
  };
32939
32945
 
32940
32946
  // src/widgets/basic/many2many-field/many2many.tsx
32941
- var import_react_dom8 = require("react-dom");
32947
+ var import_react_dom9 = require("react-dom");
32942
32948
  var import_react65 = require("react");
32943
32949
  var import_jsx_runtime104 = require("react/jsx-runtime");
32944
32950
  var Many2ManyField = (props) => {
@@ -33013,7 +33019,7 @@ var Many2ManyField = (props) => {
33013
33019
  typeof setGroupByList === "function" && setGroupByList(null);
33014
33020
  };
33015
33021
  }, [selectedTags]);
33016
- return (0, import_react_dom8.createPortal)(
33022
+ return (0, import_react_dom9.createPortal)(
33017
33023
  /* @__PURE__ */ (0, import_jsx_runtime104.jsxs)(
33018
33024
  "div",
33019
33025
  {
package/dist/widgets.mjs CHANGED
@@ -7755,8 +7755,8 @@ var en_default = {
7755
7755
  download_file: "Download this file",
7756
7756
  upload_success: "Upload file success",
7757
7757
  upload_failure: "Upload file failure",
7758
- file_accept_single: "Only JPEG, PNG, PDF, MP4, XLS, XLXS, ZIP formats are allowed, and each file should be up to 10MB.",
7759
- file_accept_total: "Only JPEG, PNG, PDF, MP4, XLS, XLXS, ZIP formats are allowed, and total should be up to 50MB.",
7758
+ file_accept_single: "Only JPEG, PNG, PDF, MP4, XLS, XLXS, ZIP, JSON formats are allowed, and each file should be up to 10MB.",
7759
+ file_accept_total: "Only JPEG, PNG, PDF, MP4, XLS, XLXS, ZIP, JSON formats are allowed, and total should be up to 50MB.",
7760
7760
  must_required: "is required",
7761
7761
  invalid_number: "Invalid number",
7762
7762
  active: "Active",
@@ -12558,6 +12558,7 @@ var M = e2.forwardRef(({ id: t3, anchorId: l2, anchorSelect: n4, content: i3, ht
12558
12558
  });
12559
12559
 
12560
12560
  // src/widgets/advanced/table/table-head.tsx
12561
+ import { createPortal as createPortal2 } from "react-dom";
12561
12562
  import { Fragment as Fragment4, jsx as jsx47, jsxs as jsxs26 } from "react/jsx-runtime";
12562
12563
  var TableHead = (props) => {
12563
12564
  const {
@@ -12599,27 +12600,31 @@ var TableHead = (props) => {
12599
12600
  return /* @__PURE__ */ jsx47(
12600
12601
  "th",
12601
12602
  {
12603
+ "data-rtc-resizable": col?.name,
12602
12604
  className: `column whitespace-nowrap text-left p-3 text-sm font-semibold capitalize text-[#060606]`,
12603
12605
  children: /* @__PURE__ */ jsxs26("div", { className: "cursor-pointer flex items-center gap-[4px] w-full min-w-max group relative", children: [
12604
12606
  col.title,
12605
12607
  col?.field?.help && /* @__PURE__ */ jsxs26(Fragment4, { children: [
12606
- /* @__PURE__ */ jsx47(
12607
- M,
12608
- {
12609
- style: {
12610
- padding: "6px 12px",
12611
- fontSize: "12px",
12612
- borderRadius: "4px",
12613
- maxWidth: "200%",
12614
- whiteSpace: "wrap",
12615
- fontWeight: 400,
12616
- textTransform: "none"
12617
- },
12618
- id: `field-help-${col?.field?.name}`,
12619
- content: col?.field?.help,
12620
- place: "top",
12621
- className: "z-30"
12622
- }
12608
+ createPortal2(
12609
+ /* @__PURE__ */ jsx47(
12610
+ M,
12611
+ {
12612
+ style: {
12613
+ padding: "6px 12px",
12614
+ fontSize: "12px",
12615
+ borderRadius: "4px",
12616
+ maxWidth: "200px",
12617
+ whiteSpace: "wrap",
12618
+ fontWeight: 400,
12619
+ textTransform: "none",
12620
+ zIndex: "9999"
12621
+ },
12622
+ id: `field-help-${col?.field?.name}`,
12623
+ content: col?.field?.help,
12624
+ place: "top"
12625
+ }
12626
+ ),
12627
+ document.body
12623
12628
  ),
12624
12629
  /* @__PURE__ */ jsx47(
12625
12630
  "span",
@@ -15757,7 +15762,7 @@ var ModalConfirm = ({
15757
15762
 
15758
15763
  // src/widgets/common/modal-detail.tsx
15759
15764
  import { useState as useState7 } from "react";
15760
- import { createPortal as createPortal2 } from "react-dom";
15765
+ import { createPortal as createPortal3 } from "react-dom";
15761
15766
  import { Fragment as Fragment13, jsx as jsx65, jsxs as jsxs41 } from "react/jsx-runtime";
15762
15767
  var ModalDetail = ({
15763
15768
  idToolTip,
@@ -15780,7 +15785,7 @@ var ModalDetail = ({
15780
15785
  sessionStorage.setItem("actionData", JSON.stringify(actionData));
15781
15786
  window.location.href = `/form/menu?model=${model}&id=${idForm}`;
15782
15787
  };
15783
- return createPortal2(
15788
+ return createPortal3(
15784
15789
  /* @__PURE__ */ jsx65(Fragment13, { children: showModalDetail && /* @__PURE__ */ jsxs41("div", { className: "fixed bottom-0 left-0 right-0 top-0 z-[100]", children: [
15785
15790
  /* @__PURE__ */ jsx65("div", { className: "absolute inset-0 bg-[rgba(27,27,27,0.48)]" }),
15786
15791
  /* @__PURE__ */ jsx65("div", { className: "absolute inset-0 overflow-auto flex flex-col justify-center items-center px-5", children: /* @__PURE__ */ jsxs41("div", { className: "relative z-[1] max-w-full p-4 flex flex-col gap-4 w-[1000px] transform rounded-3xl bg-[#FFF] h-[90%]", children: [
@@ -16321,7 +16326,8 @@ var ButtonSelectFiles = ({
16321
16326
  "application/zip",
16322
16327
  "application/x-zip-compressed",
16323
16328
  "application/vnd.ms-excel",
16324
- "application/vnd.openxmlformats-officedocument.spreadsheetml.sheet"
16329
+ "application/vnd.openxmlformats-officedocument.spreadsheetml.sheet",
16330
+ "application/json"
16325
16331
  ];
16326
16332
  const MAX_FILE_SIZE = 10 * 1024 * 1024;
16327
16333
  const MAX_TOTAL_SIZE = 50 * 1024 * 1024;
@@ -16422,7 +16428,7 @@ var ButtonSelectFiles = ({
16422
16428
  style: { display: "none" },
16423
16429
  onChange: handleOnChange,
16424
16430
  multiple: true,
16425
- accept: ".jpeg,.jpg,.png,.pdf,.mp4,.zip,application/vnd.openxmlformats-officedocument.spreadsheetml.sheet, application/vnd.ms-excel"
16431
+ accept: ".jpeg,.jpg,.png,.pdf,.json,.mp4,.zip,application/vnd.openxmlformats-officedocument.spreadsheetml.sheet, application/vnd.ms-excel"
16426
16432
  }
16427
16433
  )
16428
16434
  ] });
@@ -27532,7 +27538,7 @@ function _taggedTemplateLiteral(e3, t3) {
27532
27538
 
27533
27539
  // node_modules/react-select/dist/index-641ee5b8.esm.js
27534
27540
  import { useContext as useContext9, useRef as useRef13, useState as useState15, useMemo as useMemo7, useCallback as useCallback7, createContext as createContext5 } from "react";
27535
- import { createPortal as createPortal4 } from "react-dom";
27541
+ import { createPortal as createPortal5 } from "react-dom";
27536
27542
 
27537
27543
  // node_modules/use-isomorphic-layout-effect/dist/use-isomorphic-layout-effect.esm.js
27538
27544
  import { useLayoutEffect as useLayoutEffect4 } from "react";
@@ -28035,7 +28041,7 @@ var MenuPortal = function MenuPortal2(props) {
28035
28041
  }), innerProps), children);
28036
28042
  return jsx81(PortalPlacementContext.Provider, {
28037
28043
  value: portalPlacementContext
28038
- }, appendTo ? /* @__PURE__ */ createPortal4(menuWrapper, appendTo) : menuWrapper);
28044
+ }, appendTo ? /* @__PURE__ */ createPortal5(menuWrapper, appendTo) : menuWrapper);
28039
28045
  };
28040
28046
  var containerCSS = function containerCSS2(_ref3) {
28041
28047
  var isDisabled = _ref3.isDisabled, isRtl = _ref3.isRtl;
@@ -31460,7 +31466,7 @@ var FileUploadField = (props) => {
31460
31466
  );
31461
31467
  }
31462
31468
  }, [selectedFiles]);
31463
- return /* @__PURE__ */ jsxs58("div", { className: "file-upload-field", children: [
31469
+ return /* @__PURE__ */ jsxs58("div", { children: [
31464
31470
  selectedFiles?.length > 0 && selectedFiles?.map((fileItem, index4) => /* @__PURE__ */ jsx88(
31465
31471
  RenderFile,
31466
31472
  {
@@ -32875,7 +32881,7 @@ var StatusDropdownField = (props) => {
32875
32881
  };
32876
32882
 
32877
32883
  // src/widgets/basic/many2many-field/many2many.tsx
32878
- import { createPortal as createPortal5 } from "react-dom";
32884
+ import { createPortal as createPortal6 } from "react-dom";
32879
32885
  import { useEffect as useEffect26 } from "react";
32880
32886
  import { jsx as jsx106, jsxs as jsxs71 } from "react/jsx-runtime";
32881
32887
  var Many2ManyField = (props) => {
@@ -32950,7 +32956,7 @@ var Many2ManyField = (props) => {
32950
32956
  typeof setGroupByList === "function" && setGroupByList(null);
32951
32957
  };
32952
32958
  }, [selectedTags]);
32953
- return createPortal5(
32959
+ return createPortal6(
32954
32960
  /* @__PURE__ */ jsxs71(
32955
32961
  "div",
32956
32962
  {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@fctc/sme-widget-ui",
3
- "version": "1.9.2",
3
+ "version": "1.9.4",
4
4
  "main": "dist/index.cjs",
5
5
  "module": "dist/index.mjs",
6
6
  "types": "dist/index.d.ts",