@fctc/sme-widget-ui 2.0.6 → 2.0.8

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
@@ -4297,7 +4297,7 @@ var require_react_is_development = __commonJS({
4297
4297
  var ContextProvider = REACT_PROVIDER_TYPE;
4298
4298
  var Element2 = REACT_ELEMENT_TYPE;
4299
4299
  var ForwardRef = REACT_FORWARD_REF_TYPE;
4300
- var Fragment34 = REACT_FRAGMENT_TYPE;
4300
+ var Fragment33 = REACT_FRAGMENT_TYPE;
4301
4301
  var Lazy = REACT_LAZY_TYPE;
4302
4302
  var Memo = REACT_MEMO_TYPE;
4303
4303
  var Portal2 = REACT_PORTAL_TYPE;
@@ -4356,7 +4356,7 @@ var require_react_is_development = __commonJS({
4356
4356
  exports2.ContextProvider = ContextProvider;
4357
4357
  exports2.Element = Element2;
4358
4358
  exports2.ForwardRef = ForwardRef;
4359
- exports2.Fragment = Fragment34;
4359
+ exports2.Fragment = Fragment33;
4360
4360
  exports2.Lazy = Lazy;
4361
4361
  exports2.Memo = Memo;
4362
4362
  exports2.Portal = Portal2;
@@ -16762,6 +16762,7 @@ var VideoPlayer = ({ src }) => {
16762
16762
  };
16763
16763
 
16764
16764
  // src/widgets/basic/avatar-field/avatar.tsx
16765
+ var import_react_dom4 = require("react-dom");
16765
16766
  var import_jsx_runtime73 = require("react/jsx-runtime");
16766
16767
  var AvatarField = (props) => {
16767
16768
  const {
@@ -16786,7 +16787,7 @@ var AvatarField = (props) => {
16786
16787
  color: textColor,
16787
16788
  fontSize: `${size4 / 2.5}px`
16788
16789
  };
16789
- return /* @__PURE__ */ (0, import_jsx_runtime73.jsxs)(import_jsx_runtime73.Fragment, { children: [
16790
+ return /* @__PURE__ */ (0, import_jsx_runtime73.jsxs)("div", { className: "relative", children: [
16790
16791
  isForm && allowShowDetail && /* @__PURE__ */ (0, import_jsx_runtime73.jsx)(
16791
16792
  ModalDetail,
16792
16793
  {
@@ -16798,14 +16799,17 @@ var AvatarField = (props) => {
16798
16799
  place: "top-start"
16799
16800
  }
16800
16801
  ),
16801
- allowShowDetail && /* @__PURE__ */ (0, import_jsx_runtime73.jsx)(
16802
- M,
16803
- {
16804
- id: `avatar-widget-id-${id}`,
16805
- place: isForm ? "bottom" : "top",
16806
- content: fullName,
16807
- className: "z-20"
16808
- }
16802
+ allowShowDetail && (0, import_react_dom4.createPortal)(
16803
+ /* @__PURE__ */ (0, import_jsx_runtime73.jsx)(
16804
+ M,
16805
+ {
16806
+ id: `avatar-widget-id-${id}`,
16807
+ place: isForm ? "bottom" : "top",
16808
+ content: fullName,
16809
+ className: "z-20"
16810
+ }
16811
+ ),
16812
+ document.body
16809
16813
  ),
16810
16814
  avatarSrc ? /* @__PURE__ */ (0, import_jsx_runtime73.jsx)(
16811
16815
  "img",
@@ -22182,7 +22186,7 @@ function useFloating2(options2) {
22182
22186
  }
22183
22187
 
22184
22188
  // node_modules/react-datepicker/dist/index.es.js
22185
- var import_react_dom6 = __toESM(require("react-dom"));
22189
+ var import_react_dom7 = __toESM(require("react-dom"));
22186
22190
  var _extendStatics = function extendStatics(d, b2) {
22187
22191
  _extendStatics = Object.setPrototypeOf || {
22188
22192
  __proto__: []
@@ -25425,7 +25429,7 @@ var Portal = (
25425
25429
  }
25426
25430
  };
25427
25431
  Portal2.prototype.render = function() {
25428
- return import_react_dom6.default.createPortal(this.props.children, this.el);
25432
+ return import_react_dom7.default.createPortal(this.props.children, this.el);
25429
25433
  };
25430
25434
  return Portal2;
25431
25435
  }(import_react45.Component)
@@ -27993,7 +27997,7 @@ function _taggedTemplateLiteral(e3, t3) {
27993
27997
 
27994
27998
  // node_modules/react-select/dist/index-641ee5b8.esm.js
27995
27999
  var import_react51 = require("react");
27996
- var import_react_dom7 = require("react-dom");
28000
+ var import_react_dom8 = require("react-dom");
27997
28001
 
27998
28002
  // node_modules/use-isomorphic-layout-effect/dist/use-isomorphic-layout-effect.esm.js
27999
28003
  var import_react49 = require("react");
@@ -28496,7 +28500,7 @@ var MenuPortal = function MenuPortal2(props) {
28496
28500
  }), innerProps), children);
28497
28501
  return jsx83(PortalPlacementContext.Provider, {
28498
28502
  value: portalPlacementContext
28499
- }, appendTo ? /* @__PURE__ */ (0, import_react_dom7.createPortal)(menuWrapper, appendTo) : menuWrapper);
28503
+ }, appendTo ? /* @__PURE__ */ (0, import_react_dom8.createPortal)(menuWrapper, appendTo) : menuWrapper);
28500
28504
  };
28501
28505
  var containerCSS = function containerCSS2(_ref3) {
28502
28506
  var isDisabled = _ref3.isDisabled, isRtl = _ref3.isRtl;
@@ -31389,7 +31393,7 @@ var import_toConsumableArray2 = __toESM(require_toConsumableArray());
31389
31393
  var import_typeof5 = __toESM(require_typeof());
31390
31394
  var import_taggedTemplateLiteral2 = __toESM(require_taggedTemplateLiteral());
31391
31395
  var import_defineProperty3 = __toESM(require_defineProperty());
31392
- var import_react_dom8 = require("react-dom");
31396
+ var import_react_dom9 = require("react-dom");
31393
31397
  var StateManagedSelect = /* @__PURE__ */ (0, import_react54.forwardRef)(function(props, ref) {
31394
31398
  var baseSelectProps = useStateManager(props);
31395
31399
  return /* @__PURE__ */ React14.createElement(Select, _extends({
@@ -33339,7 +33343,7 @@ var StatusDropdownField = (props) => {
33339
33343
  };
33340
33344
 
33341
33345
  // src/widgets/basic/many2many-field/many2many.tsx
33342
- var import_react_dom9 = require("react-dom");
33346
+ var import_react_dom10 = require("react-dom");
33343
33347
  var import_react66 = require("react");
33344
33348
  var import_jsx_runtime106 = require("react/jsx-runtime");
33345
33349
  var Many2ManyField = (props) => {
@@ -33414,7 +33418,7 @@ var Many2ManyField = (props) => {
33414
33418
  typeof setGroupByList === "function" && setGroupByList(null);
33415
33419
  };
33416
33420
  }, [selectedTags]);
33417
- return (0, import_react_dom9.createPortal)(
33421
+ return (0, import_react_dom10.createPortal)(
33418
33422
  /* @__PURE__ */ (0, import_jsx_runtime106.jsxs)(
33419
33423
  "div",
33420
33424
  {
package/dist/index.mjs CHANGED
@@ -4297,7 +4297,7 @@ var require_react_is_development = __commonJS({
4297
4297
  var ContextProvider = REACT_PROVIDER_TYPE;
4298
4298
  var Element2 = REACT_ELEMENT_TYPE;
4299
4299
  var ForwardRef = REACT_FORWARD_REF_TYPE;
4300
- var Fragment34 = REACT_FRAGMENT_TYPE;
4300
+ var Fragment33 = REACT_FRAGMENT_TYPE;
4301
4301
  var Lazy = REACT_LAZY_TYPE;
4302
4302
  var Memo = REACT_MEMO_TYPE;
4303
4303
  var Portal2 = REACT_PORTAL_TYPE;
@@ -4356,7 +4356,7 @@ var require_react_is_development = __commonJS({
4356
4356
  exports.ContextProvider = ContextProvider;
4357
4357
  exports.Element = Element2;
4358
4358
  exports.ForwardRef = ForwardRef;
4359
- exports.Fragment = Fragment34;
4359
+ exports.Fragment = Fragment33;
4360
4360
  exports.Lazy = Lazy;
4361
4361
  exports.Memo = Memo;
4362
4362
  exports.Portal = Portal2;
@@ -16637,7 +16637,8 @@ var VideoPlayer = ({ src }) => {
16637
16637
  };
16638
16638
 
16639
16639
  // src/widgets/basic/avatar-field/avatar.tsx
16640
- import { Fragment as Fragment15, jsx as jsx73, jsxs as jsxs48 } from "react/jsx-runtime";
16640
+ import { createPortal as createPortal4 } from "react-dom";
16641
+ import { jsx as jsx73, jsxs as jsxs48 } from "react/jsx-runtime";
16641
16642
  var AvatarField = (props) => {
16642
16643
  const {
16643
16644
  isForm = false,
@@ -16661,7 +16662,7 @@ var AvatarField = (props) => {
16661
16662
  color: textColor,
16662
16663
  fontSize: `${size4 / 2.5}px`
16663
16664
  };
16664
- return /* @__PURE__ */ jsxs48(Fragment15, { children: [
16665
+ return /* @__PURE__ */ jsxs48("div", { className: "relative", children: [
16665
16666
  isForm && allowShowDetail && /* @__PURE__ */ jsx73(
16666
16667
  ModalDetail,
16667
16668
  {
@@ -16673,14 +16674,17 @@ var AvatarField = (props) => {
16673
16674
  place: "top-start"
16674
16675
  }
16675
16676
  ),
16676
- allowShowDetail && /* @__PURE__ */ jsx73(
16677
- M,
16678
- {
16679
- id: `avatar-widget-id-${id}`,
16680
- place: isForm ? "bottom" : "top",
16681
- content: fullName,
16682
- className: "z-20"
16683
- }
16677
+ allowShowDetail && createPortal4(
16678
+ /* @__PURE__ */ jsx73(
16679
+ M,
16680
+ {
16681
+ id: `avatar-widget-id-${id}`,
16682
+ place: isForm ? "bottom" : "top",
16683
+ content: fullName,
16684
+ className: "z-20"
16685
+ }
16686
+ ),
16687
+ document.body
16684
16688
  ),
16685
16689
  avatarSrc ? /* @__PURE__ */ jsx73(
16686
16690
  "img",
@@ -16704,7 +16708,7 @@ var AvatarField = (props) => {
16704
16708
 
16705
16709
  // src/widgets/basic/binary-field/binary.tsx
16706
16710
  import { useEffect as useEffect11, useState as useState11 } from "react";
16707
- import { Fragment as Fragment16, jsx as jsx74, jsxs as jsxs49 } from "react/jsx-runtime";
16711
+ import { Fragment as Fragment15, jsx as jsx74, jsxs as jsxs49 } from "react/jsx-runtime";
16708
16712
  var BinaryField = (props) => {
16709
16713
  const {
16710
16714
  name: name2,
@@ -16830,7 +16834,7 @@ var BinaryField = (props) => {
16830
16834
  },
16831
16835
  render: ({ field, fieldState: { error: error2 } }) => {
16832
16836
  const hasFile = !!fileInfo;
16833
- return /* @__PURE__ */ jsxs49(Fragment16, { children: [
16837
+ return /* @__PURE__ */ jsxs49(Fragment15, { children: [
16834
16838
  /* @__PURE__ */ jsx74(
16835
16839
  "div",
16836
16840
  {
@@ -17045,7 +17049,7 @@ var ButtonBadgeField = (props) => {
17045
17049
  };
17046
17050
 
17047
17051
  // src/widgets/basic/button-field/button.tsx
17048
- import { Fragment as Fragment17, jsx as jsx76, jsxs as jsxs50 } from "react/jsx-runtime";
17052
+ import { Fragment as Fragment16, jsx as jsx76, jsxs as jsxs50 } from "react/jsx-runtime";
17049
17053
  var ButtonField = (props) => {
17050
17054
  const {
17051
17055
  func,
@@ -17056,7 +17060,7 @@ var ButtonField = (props) => {
17056
17060
  type = "submit"
17057
17061
  } = props;
17058
17062
  const { t: t3 } = useI18n();
17059
- return /* @__PURE__ */ jsx76(Fragment17, { children: !loading ? /* @__PURE__ */ jsx76(
17063
+ return /* @__PURE__ */ jsx76(Fragment16, { children: !loading ? /* @__PURE__ */ jsx76(
17060
17064
  "button",
17061
17065
  {
17062
17066
  type,
@@ -17082,7 +17086,7 @@ var ButtonField = (props) => {
17082
17086
 
17083
17087
  // src/widgets/basic/char-field/char.tsx
17084
17088
  import { useEffect as useEffect12, useMemo as useMemo4 } from "react";
17085
- import { Fragment as Fragment18, jsx as jsx77, jsxs as jsxs51 } from "react/jsx-runtime";
17089
+ import { Fragment as Fragment17, jsx as jsx77, jsxs as jsxs51 } from "react/jsx-runtime";
17086
17090
  var WIDGET_AUTO_COMPUTE_DEPEND = "auto_compute_depend_field";
17087
17091
  var CharField = (props) => {
17088
17092
  const {
@@ -17166,7 +17170,7 @@ var CharField = (props) => {
17166
17170
  }
17167
17171
  return "";
17168
17172
  }, [widget, formValues]);
17169
- return /* @__PURE__ */ jsxs51(Fragment18, { children: [
17173
+ return /* @__PURE__ */ jsxs51(Fragment17, { children: [
17170
17174
  /* @__PURE__ */ jsx77(
17171
17175
  "input",
17172
17176
  {
@@ -17228,7 +17232,7 @@ var CharField = (props) => {
17228
17232
  `
17229
17233
  }
17230
17234
  ),
17231
- isEditTable ? /* @__PURE__ */ jsx77(Fragment18, {}) : /* @__PURE__ */ jsx77(Fragment18, { children: error2 && /* @__PURE__ */ jsx77("p", { className: "text-[#de4747] text-sm mt-1", children: error2.message }) })
17235
+ isEditTable ? /* @__PURE__ */ jsx77(Fragment17, {}) : /* @__PURE__ */ jsx77(Fragment17, { children: error2 && /* @__PURE__ */ jsx77("p", { className: "text-[#de4747] text-sm mt-1", children: error2.message }) })
17232
17236
  ] });
17233
17237
  }
17234
17238
  }
@@ -17310,7 +17314,7 @@ var CheckboxField = (props) => {
17310
17314
 
17311
17315
  // src/widgets/basic/color-field/color-wrapper.tsx
17312
17316
  import { useEffect as useEffect13, useRef as useRef7, useState as useState12 } from "react";
17313
- import { Fragment as Fragment19, jsx as jsx79, jsxs as jsxs52 } from "react/jsx-runtime";
17317
+ import { Fragment as Fragment18, jsx as jsx79, jsxs as jsxs52 } from "react/jsx-runtime";
17314
17318
  var ColorWrapper = (props) => {
17315
17319
  const {
17316
17320
  colors: colors2,
@@ -17361,7 +17365,7 @@ var ColorWrapper = (props) => {
17361
17365
  content: i18n_default.t(color?.name)
17362
17366
  }
17363
17367
  )
17364
- ] }, color?.id)) }) : /* @__PURE__ */ jsxs52(Fragment19, { children: [
17368
+ ] }, color?.id)) }) : /* @__PURE__ */ jsxs52(Fragment18, { children: [
17365
17369
  /* @__PURE__ */ jsx79(
17366
17370
  "button",
17367
17371
  {
@@ -21461,7 +21465,7 @@ function useEffectEvent(callback) {
21461
21465
  }
21462
21466
 
21463
21467
  // node_modules/react-datepicker/node_modules/@floating-ui/react/dist/floating-ui.react.mjs
21464
- import { jsx as jsx82, jsxs as jsxs54, Fragment as Fragment20 } from "react/jsx-runtime";
21468
+ import { jsx as jsx82, jsxs as jsxs54, Fragment as Fragment19 } from "react/jsx-runtime";
21465
21469
  import * as ReactDOM2 from "react-dom";
21466
21470
 
21467
21471
  // node_modules/@floating-ui/react-dom/dist/floating-ui.react-dom.mjs
@@ -26535,7 +26539,7 @@ function _toConsumableArray(r4) {
26535
26539
 
26536
26540
  // node_modules/react-select/dist/Select-ef7c0426.esm.js
26537
26541
  import * as React13 from "react";
26538
- import { useMemo as useMemo8, Fragment as Fragment23, useRef as useRef14, useCallback as useCallback8, useEffect as useEffect17, Component as Component2 } from "react";
26542
+ import { useMemo as useMemo8, Fragment as Fragment22, useRef as useRef14, useCallback as useCallback8, useEffect as useEffect17, Component as Component2 } from "react";
26539
26543
 
26540
26544
  // node_modules/@emotion/react/dist/emotion-element-d59e098f.esm.js
26541
26545
  import * as React11 from "react";
@@ -27868,7 +27872,7 @@ function _taggedTemplateLiteral(e3, t3) {
27868
27872
 
27869
27873
  // node_modules/react-select/dist/index-641ee5b8.esm.js
27870
27874
  import { useContext as useContext9, useRef as useRef13, useState as useState16, useMemo as useMemo7, useCallback as useCallback7, createContext as createContext5 } from "react";
27871
- import { createPortal as createPortal5 } from "react-dom";
27875
+ import { createPortal as createPortal6 } from "react-dom";
27872
27876
 
27873
27877
  // node_modules/use-isomorphic-layout-effect/dist/use-isomorphic-layout-effect.esm.js
27874
27878
  import { useLayoutEffect as useLayoutEffect4 } from "react";
@@ -28371,7 +28375,7 @@ var MenuPortal = function MenuPortal2(props) {
28371
28375
  }), innerProps), children);
28372
28376
  return jsx83(PortalPlacementContext.Provider, {
28373
28377
  value: portalPlacementContext
28374
- }, appendTo ? /* @__PURE__ */ createPortal5(menuWrapper, appendTo) : menuWrapper);
28378
+ }, appendTo ? /* @__PURE__ */ createPortal6(menuWrapper, appendTo) : menuWrapper);
28375
28379
  };
28376
28380
  var containerCSS = function containerCSS2(_ref3) {
28377
28381
  var isDisabled = _ref3.isDisabled, isRtl = _ref3.isRtl;
@@ -29100,7 +29104,7 @@ var LiveRegion = function LiveRegion2(props) {
29100
29104
  }
29101
29105
  return guidanceMsg;
29102
29106
  }, [ariaLabel, focusedOption, focusedValue, isMulti, isOptionDisabled3, isSearchable, menuIsOpen, messages, selectValue, tabSelectsValue, isInitialFocus]);
29103
- var ScreenReaderText = jsx83(Fragment23, null, jsx83("span", {
29107
+ var ScreenReaderText = jsx83(Fragment22, null, jsx83("span", {
29104
29108
  id: "aria-selection"
29105
29109
  }, ariaSelected), jsx83("span", {
29106
29110
  id: "aria-focused"
@@ -29109,7 +29113,7 @@ var LiveRegion = function LiveRegion2(props) {
29109
29113
  }, ariaResults), jsx83("span", {
29110
29114
  id: "aria-guidance"
29111
29115
  }, ariaGuidance));
29112
- return jsx83(Fragment23, null, jsx83(A11yText$1, {
29116
+ return jsx83(Fragment22, null, jsx83(A11yText$1, {
29113
29117
  id
29114
29118
  }, isInitialFocus && ScreenReaderText), jsx83(A11yText$1, {
29115
29119
  "aria-live": ariaLive,
@@ -29666,7 +29670,7 @@ function ScrollManager(_ref3) {
29666
29670
  setScrollCaptureTarget(element);
29667
29671
  setScrollLockTarget(element);
29668
29672
  };
29669
- return jsx83(Fragment23, null, lockEnabled && jsx83("div", {
29673
+ return jsx83(Fragment22, null, lockEnabled && jsx83("div", {
29670
29674
  onClick: blurSelectInput,
29671
29675
  css: _ref2$1
29672
29676
  }), children(targetRef));
@@ -31275,7 +31279,7 @@ var StateManagedSelect$1 = StateManagedSelect;
31275
31279
 
31276
31280
  // src/widgets/basic/date-field/date.tsx
31277
31281
  var import_moment2 = __toESM(require_moment());
31278
- import { Fragment as Fragment24, jsx as jsx85, jsxs as jsxs55 } from "react/jsx-runtime";
31282
+ import { Fragment as Fragment23, jsx as jsx85, jsxs as jsxs55 } from "react/jsx-runtime";
31279
31283
  var DateField = (props) => {
31280
31284
  const {
31281
31285
  name: name2,
@@ -31346,7 +31350,7 @@ var DateField = (props) => {
31346
31350
  }
31347
31351
  }, [value, clearErrors, name2]);
31348
31352
  const selectedDate = !methods ? value && (0, import_moment2.default)(value, formatDateParse).isValid() ? (0, import_moment2.default)(value, formatDateParse).add(7, "hours").toDate() : null : field?.value && (0, import_moment2.default)(field.value, formatDateParse).isValid() ? (0, import_moment2.default)(field.value, formatDateParse).add(7, "hours").toDate() : null;
31349
- return /* @__PURE__ */ jsxs55(Fragment24, { children: [
31353
+ return /* @__PURE__ */ jsxs55(Fragment23, { children: [
31350
31354
  /* @__PURE__ */ jsx85(
31351
31355
  DatePicker,
31352
31356
  {
@@ -31630,7 +31634,7 @@ var DropdownField = (props) => {
31630
31634
  };
31631
31635
 
31632
31636
  // src/widgets/basic/fee-field/fee.tsx
31633
- import { Fragment as Fragment25, jsx as jsx89, jsxs as jsxs59 } from "react/jsx-runtime";
31637
+ import { Fragment as Fragment24, jsx as jsx89, jsxs as jsxs59 } from "react/jsx-runtime";
31634
31638
  var FeeField = (props) => {
31635
31639
  const { value, formValues } = props;
31636
31640
  const { t: t3 } = useI18n();
@@ -31641,10 +31645,10 @@ var FeeField = (props) => {
31641
31645
  )
31642
31646
  ) + " VND";
31643
31647
  const remaining_amount = formatNumberOnly(parseFloat(formValues?.amount_residual ?? 0)) + " VND";
31644
- return /* @__PURE__ */ jsxs59(Fragment25, { children: [
31648
+ return /* @__PURE__ */ jsxs59(Fragment24, { children: [
31645
31649
  value?.subtotals?.map((sub) => {
31646
31650
  if (sub?.tax_amount > 0 && sub?.tax_groups?.length > 0) {
31647
- return /* @__PURE__ */ jsxs59(Fragment25, { children: [
31651
+ return /* @__PURE__ */ jsxs59(Fragment24, { children: [
31648
31652
  /* @__PURE__ */ jsxs59("div", { className: "grid grid-cols-2 gap-x-4 gap-y-2 min-w-[300px] max-w-fit ml-auto", children: [
31649
31653
  /* @__PURE__ */ jsxs59("div", { className: "text-[14px] leading-[21px] text-right", children: [
31650
31654
  sub?.name,
@@ -31837,7 +31841,7 @@ var FileUploadField = (props) => {
31837
31841
 
31838
31842
  // src/widgets/basic/float-field/float.tsx
31839
31843
  import { useEffect as useEffect20, useRef as useRef16, useState as useState19 } from "react";
31840
- import { Fragment as Fragment26, jsx as jsx91, jsxs as jsxs61 } from "react/jsx-runtime";
31844
+ import { Fragment as Fragment25, jsx as jsx91, jsxs as jsxs61 } from "react/jsx-runtime";
31841
31845
  var FloatField = (props) => {
31842
31846
  const {
31843
31847
  name: name2,
@@ -31964,7 +31968,7 @@ var FloatField = (props) => {
31964
31968
  }
31965
31969
  isDirtyRef.current = false;
31966
31970
  };
31967
- return /* @__PURE__ */ jsxs61(Fragment26, { children: [
31971
+ return /* @__PURE__ */ jsxs61(Fragment25, { children: [
31968
31972
  /* @__PURE__ */ jsx91(
31969
31973
  "input",
31970
31974
  {
@@ -31994,7 +31998,7 @@ var FloatField = (props) => {
31994
31998
 
31995
31999
  // src/widgets/basic/float-time-field/float-time.tsx
31996
32000
  import { useState as useState20 } from "react";
31997
- import { Fragment as Fragment27, jsx as jsx92, jsxs as jsxs62 } from "react/jsx-runtime";
32001
+ import { Fragment as Fragment26, jsx as jsx92, jsxs as jsxs62 } from "react/jsx-runtime";
31998
32002
  var FloatTimeField = (props) => {
31999
32003
  const {
32000
32004
  name: name2,
@@ -32074,7 +32078,7 @@ var FloatTimeField = (props) => {
32074
32078
  }
32075
32079
  onBlur();
32076
32080
  };
32077
- return /* @__PURE__ */ jsxs62(Fragment27, { children: [
32081
+ return /* @__PURE__ */ jsxs62(Fragment26, { children: [
32078
32082
  /* @__PURE__ */ jsx92(
32079
32083
  "input",
32080
32084
  {
@@ -32184,11 +32188,11 @@ var ImageField = (props) => {
32184
32188
  import React16, { useEffect as useEffect22, useMemo as useMemo10 } from "react";
32185
32189
 
32186
32190
  // src/widgets/basic/information-field/information.tsx
32187
- import { Fragment as Fragment28, jsx as jsx95, jsxs as jsxs63 } from "react/jsx-runtime";
32191
+ import { Fragment as Fragment27, jsx as jsx95, jsxs as jsxs63 } from "react/jsx-runtime";
32188
32192
  var InfomationField = (props) => {
32189
32193
  const { value, isForm = false, showName = true, stringToColor } = props;
32190
32194
  if (!value || Array.isArray(value) && value.length === 0) {
32191
- return /* @__PURE__ */ jsx95(Fragment28, {});
32195
+ return /* @__PURE__ */ jsx95(Fragment27, {});
32192
32196
  }
32193
32197
  const inforValues = Array.isArray(value) ? value : [value];
32194
32198
  return /* @__PURE__ */ jsx95("div", { className: "group relative flex items-center gap-1 rounded-lg transition-shadow duration-300", children: inforValues.length > 1 ? inforValues.map((item) => /* @__PURE__ */ jsx95(
@@ -32463,7 +32467,7 @@ var Many2ManyTagField = (props) => {
32463
32467
 
32464
32468
  // src/widgets/basic/monetary-field/monetary.tsx
32465
32469
  import { useEffect as useEffect23 } from "react";
32466
- import { Fragment as Fragment29, jsx as jsx97, jsxs as jsxs65 } from "react/jsx-runtime";
32470
+ import { Fragment as Fragment28, jsx as jsx97, jsxs as jsxs65 } from "react/jsx-runtime";
32467
32471
  var MonetaryField = (props) => {
32468
32472
  const { t: t3 } = useI18n();
32469
32473
  const {
@@ -32521,7 +32525,7 @@ var MonetaryField = (props) => {
32521
32525
  clearErrors(name2);
32522
32526
  }
32523
32527
  }, [value2]);
32524
- return /* @__PURE__ */ jsxs65(Fragment29, { children: [
32528
+ return /* @__PURE__ */ jsxs65(Fragment28, { children: [
32525
32529
  /* @__PURE__ */ jsx97(
32526
32530
  "input",
32527
32531
  {
@@ -32783,7 +32787,7 @@ var RemainingDaysField = (props) => {
32783
32787
  };
32784
32788
 
32785
32789
  // src/widgets/basic/select-dropdown-field/select-dropdown.tsx
32786
- import { Fragment as Fragment30, jsx as jsx103, jsxs as jsxs69 } from "react/jsx-runtime";
32790
+ import { Fragment as Fragment29, jsx as jsx103, jsxs as jsxs69 } from "react/jsx-runtime";
32787
32791
  var SelectDropdownField = (props) => {
32788
32792
  const { t: t3 } = useI18n();
32789
32793
  const {
@@ -32834,7 +32838,7 @@ var SelectDropdownField = (props) => {
32834
32838
  value: defaultValue || null,
32835
32839
  required: !invisible && required
32836
32840
  };
32837
- return /* @__PURE__ */ jsxs69(Fragment30, { children: [
32841
+ return /* @__PURE__ */ jsxs69(Fragment29, { children: [
32838
32842
  /* @__PURE__ */ jsx103("div", { className: "group", children: /* @__PURE__ */ jsx103(
32839
32843
  StateManagedSelect$1,
32840
32844
  {
@@ -33016,7 +33020,7 @@ var ToggleButtonField = (props) => {
33016
33020
 
33017
33021
  // src/widgets/basic/integer-field/integer.tsx
33018
33022
  import { useEffect as useEffect26, useRef as useRef18, useState as useState22 } from "react";
33019
- import { Fragment as Fragment31, jsx as jsx106, jsxs as jsxs71 } from "react/jsx-runtime";
33023
+ import { Fragment as Fragment30, jsx as jsx106, jsxs as jsxs71 } from "react/jsx-runtime";
33020
33024
  var IntegerField = (props) => {
33021
33025
  const {
33022
33026
  name: name2,
@@ -33115,7 +33119,7 @@ var IntegerField = (props) => {
33115
33119
  inputRef.current?.blur();
33116
33120
  clearErrors(name2);
33117
33121
  };
33118
- return /* @__PURE__ */ jsxs71(Fragment31, { children: [
33122
+ return /* @__PURE__ */ jsxs71(Fragment30, { children: [
33119
33123
  /* @__PURE__ */ jsx106(
33120
33124
  "input",
33121
33125
  {
@@ -33214,7 +33218,7 @@ var StatusDropdownField = (props) => {
33214
33218
  };
33215
33219
 
33216
33220
  // src/widgets/basic/many2many-field/many2many.tsx
33217
- import { createPortal as createPortal6 } from "react-dom";
33221
+ import { createPortal as createPortal7 } from "react-dom";
33218
33222
  import { useEffect as useEffect27 } from "react";
33219
33223
  import { jsx as jsx108, jsxs as jsxs73 } from "react/jsx-runtime";
33220
33224
  var Many2ManyField = (props) => {
@@ -33289,7 +33293,7 @@ var Many2ManyField = (props) => {
33289
33293
  typeof setGroupByList === "function" && setGroupByList(null);
33290
33294
  };
33291
33295
  }, [selectedTags]);
33292
- return createPortal6(
33296
+ return createPortal7(
33293
33297
  /* @__PURE__ */ jsxs73(
33294
33298
  "div",
33295
33299
  {
@@ -33496,7 +33500,7 @@ var Many2ManyField = (props) => {
33496
33500
 
33497
33501
  // src/widgets/basic/many2one-field/many2one.tsx
33498
33502
  import React18, { useEffect as useEffect28 } from "react";
33499
- import { Fragment as Fragment32, jsx as jsx109, jsxs as jsxs74 } from "react/jsx-runtime";
33503
+ import { Fragment as Fragment31, jsx as jsx109, jsxs as jsxs74 } from "react/jsx-runtime";
33500
33504
  var CustomMenuList2 = (props) => {
33501
33505
  const { t: t3 } = useI18n();
33502
33506
  const { options: options2, children, selectProps } = props;
@@ -33547,7 +33551,7 @@ var Many2OneField = (props) => {
33547
33551
  const { t: t3 } = useI18n();
33548
33552
  if (!isForm && !isEditTable) {
33549
33553
  const id = propValue && typeof propValue === "object" && "id" in propValue ? propValue?.id : propValue;
33550
- return /* @__PURE__ */ jsxs74(Fragment32, { children: [
33554
+ return /* @__PURE__ */ jsxs74(Fragment31, { children: [
33551
33555
  allowShowDetail && renderDetail({
33552
33556
  idToolTip: String(name2) + Number(index4),
33553
33557
  model: options2?.model ?? relation,
@@ -33565,7 +33569,7 @@ var Many2OneField = (props) => {
33565
33569
  )
33566
33570
  ] });
33567
33571
  }
33568
- return /* @__PURE__ */ jsxs74(Fragment32, { children: [
33572
+ return /* @__PURE__ */ jsxs74(Fragment31, { children: [
33569
33573
  allowShowDetail && renderDetail({
33570
33574
  idToolTip: String(name2),
33571
33575
  model: options2?.model ?? relation,
@@ -33798,7 +33802,7 @@ var StatusbarDurationField = (props) => {
33798
33802
 
33799
33803
  // src/widgets/basic/status-bar-field/option/option.tsx
33800
33804
  import { useMemo as useMemo11 } from "react";
33801
- import { Fragment as Fragment33, jsx as jsx111, jsxs as jsxs76 } from "react/jsx-runtime";
33805
+ import { Fragment as Fragment32, jsx as jsx111, jsxs as jsxs76 } from "react/jsx-runtime";
33802
33806
  var StatusBarOptionField = (props) => {
33803
33807
  const { selection, defaultValue } = props;
33804
33808
  const memoizedStatusOptions = useMemo11(() => selection, [selection]);
@@ -33814,7 +33818,7 @@ var StatusBarOptionField = (props) => {
33814
33818
  flexWrap: "wrap"
33815
33819
  },
33816
33820
  children: memoizedStatusOptions?.map((option, index4) => {
33817
- return /* @__PURE__ */ jsxs76(Fragment33, { children: [
33821
+ return /* @__PURE__ */ jsxs76(Fragment32, { children: [
33818
33822
  /* @__PURE__ */ jsxs76(
33819
33823
  "div",
33820
33824
  {
package/dist/widgets.js CHANGED
@@ -4297,7 +4297,7 @@ var require_react_is_development = __commonJS({
4297
4297
  var ContextProvider = REACT_PROVIDER_TYPE;
4298
4298
  var Element2 = REACT_ELEMENT_TYPE;
4299
4299
  var ForwardRef = REACT_FORWARD_REF_TYPE;
4300
- var Fragment34 = REACT_FRAGMENT_TYPE;
4300
+ var Fragment33 = REACT_FRAGMENT_TYPE;
4301
4301
  var Lazy = REACT_LAZY_TYPE;
4302
4302
  var Memo = REACT_MEMO_TYPE;
4303
4303
  var Portal2 = REACT_PORTAL_TYPE;
@@ -4356,7 +4356,7 @@ var require_react_is_development = __commonJS({
4356
4356
  exports2.ContextProvider = ContextProvider;
4357
4357
  exports2.Element = Element2;
4358
4358
  exports2.ForwardRef = ForwardRef;
4359
- exports2.Fragment = Fragment34;
4359
+ exports2.Fragment = Fragment33;
4360
4360
  exports2.Lazy = Lazy;
4361
4361
  exports2.Memo = Memo;
4362
4362
  exports2.Portal = Portal2;
@@ -16015,6 +16015,7 @@ var VideoPlayer = ({ src }) => {
16015
16015
  };
16016
16016
 
16017
16017
  // src/widgets/basic/avatar-field/avatar.tsx
16018
+ var import_react_dom4 = require("react-dom");
16018
16019
  var import_jsx_runtime73 = require("react/jsx-runtime");
16019
16020
  var AvatarField = (props) => {
16020
16021
  const {
@@ -16039,7 +16040,7 @@ var AvatarField = (props) => {
16039
16040
  color: textColor,
16040
16041
  fontSize: `${size4 / 2.5}px`
16041
16042
  };
16042
- return /* @__PURE__ */ (0, import_jsx_runtime73.jsxs)(import_jsx_runtime73.Fragment, { children: [
16043
+ return /* @__PURE__ */ (0, import_jsx_runtime73.jsxs)("div", { className: "relative", children: [
16043
16044
  isForm && allowShowDetail && /* @__PURE__ */ (0, import_jsx_runtime73.jsx)(
16044
16045
  ModalDetail,
16045
16046
  {
@@ -16051,14 +16052,17 @@ var AvatarField = (props) => {
16051
16052
  place: "top-start"
16052
16053
  }
16053
16054
  ),
16054
- allowShowDetail && /* @__PURE__ */ (0, import_jsx_runtime73.jsx)(
16055
- M,
16056
- {
16057
- id: `avatar-widget-id-${id}`,
16058
- place: isForm ? "bottom" : "top",
16059
- content: fullName,
16060
- className: "z-20"
16061
- }
16055
+ allowShowDetail && (0, import_react_dom4.createPortal)(
16056
+ /* @__PURE__ */ (0, import_jsx_runtime73.jsx)(
16057
+ M,
16058
+ {
16059
+ id: `avatar-widget-id-${id}`,
16060
+ place: isForm ? "bottom" : "top",
16061
+ content: fullName,
16062
+ className: "z-20"
16063
+ }
16064
+ ),
16065
+ document.body
16062
16066
  ),
16063
16067
  avatarSrc ? /* @__PURE__ */ (0, import_jsx_runtime73.jsx)(
16064
16068
  "img",
@@ -21435,7 +21439,7 @@ function useFloating2(options2) {
21435
21439
  }
21436
21440
 
21437
21441
  // node_modules/react-datepicker/dist/index.es.js
21438
- var import_react_dom6 = __toESM(require("react-dom"));
21442
+ var import_react_dom7 = __toESM(require("react-dom"));
21439
21443
  var _extendStatics = function extendStatics(d, b2) {
21440
21444
  _extendStatics = Object.setPrototypeOf || {
21441
21445
  __proto__: []
@@ -24678,7 +24682,7 @@ var Portal = (
24678
24682
  }
24679
24683
  };
24680
24684
  Portal2.prototype.render = function() {
24681
- return import_react_dom6.default.createPortal(this.props.children, this.el);
24685
+ return import_react_dom7.default.createPortal(this.props.children, this.el);
24682
24686
  };
24683
24687
  return Portal2;
24684
24688
  }(import_react45.Component)
@@ -27246,7 +27250,7 @@ function _taggedTemplateLiteral(e3, t3) {
27246
27250
 
27247
27251
  // node_modules/react-select/dist/index-641ee5b8.esm.js
27248
27252
  var import_react51 = require("react");
27249
- var import_react_dom7 = require("react-dom");
27253
+ var import_react_dom8 = require("react-dom");
27250
27254
 
27251
27255
  // node_modules/use-isomorphic-layout-effect/dist/use-isomorphic-layout-effect.esm.js
27252
27256
  var import_react49 = require("react");
@@ -27749,7 +27753,7 @@ var MenuPortal = function MenuPortal2(props) {
27749
27753
  }), innerProps), children);
27750
27754
  return jsx83(PortalPlacementContext.Provider, {
27751
27755
  value: portalPlacementContext
27752
- }, appendTo ? /* @__PURE__ */ (0, import_react_dom7.createPortal)(menuWrapper, appendTo) : menuWrapper);
27756
+ }, appendTo ? /* @__PURE__ */ (0, import_react_dom8.createPortal)(menuWrapper, appendTo) : menuWrapper);
27753
27757
  };
27754
27758
  var containerCSS = function containerCSS2(_ref3) {
27755
27759
  var isDisabled = _ref3.isDisabled, isRtl = _ref3.isRtl;
@@ -30642,7 +30646,7 @@ var import_toConsumableArray2 = __toESM(require_toConsumableArray());
30642
30646
  var import_typeof5 = __toESM(require_typeof());
30643
30647
  var import_taggedTemplateLiteral2 = __toESM(require_taggedTemplateLiteral());
30644
30648
  var import_defineProperty3 = __toESM(require_defineProperty());
30645
- var import_react_dom8 = require("react-dom");
30649
+ var import_react_dom9 = require("react-dom");
30646
30650
  var StateManagedSelect = /* @__PURE__ */ (0, import_react54.forwardRef)(function(props, ref) {
30647
30651
  var baseSelectProps = useStateManager(props);
30648
30652
  return /* @__PURE__ */ React14.createElement(Select, _extends({
@@ -32592,7 +32596,7 @@ var StatusDropdownField = (props) => {
32592
32596
  };
32593
32597
 
32594
32598
  // src/widgets/basic/many2many-field/many2many.tsx
32595
- var import_react_dom9 = require("react-dom");
32599
+ var import_react_dom10 = require("react-dom");
32596
32600
  var import_react66 = require("react");
32597
32601
  var import_jsx_runtime106 = require("react/jsx-runtime");
32598
32602
  var Many2ManyField = (props) => {
@@ -32667,7 +32671,7 @@ var Many2ManyField = (props) => {
32667
32671
  typeof setGroupByList === "function" && setGroupByList(null);
32668
32672
  };
32669
32673
  }, [selectedTags]);
32670
- return (0, import_react_dom9.createPortal)(
32674
+ return (0, import_react_dom10.createPortal)(
32671
32675
  /* @__PURE__ */ (0, import_jsx_runtime106.jsxs)(
32672
32676
  "div",
32673
32677
  {
package/dist/widgets.mjs CHANGED
@@ -4297,7 +4297,7 @@ var require_react_is_development = __commonJS({
4297
4297
  var ContextProvider = REACT_PROVIDER_TYPE;
4298
4298
  var Element2 = REACT_ELEMENT_TYPE;
4299
4299
  var ForwardRef = REACT_FORWARD_REF_TYPE;
4300
- var Fragment34 = REACT_FRAGMENT_TYPE;
4300
+ var Fragment33 = REACT_FRAGMENT_TYPE;
4301
4301
  var Lazy = REACT_LAZY_TYPE;
4302
4302
  var Memo = REACT_MEMO_TYPE;
4303
4303
  var Portal2 = REACT_PORTAL_TYPE;
@@ -4356,7 +4356,7 @@ var require_react_is_development = __commonJS({
4356
4356
  exports.ContextProvider = ContextProvider;
4357
4357
  exports.Element = Element2;
4358
4358
  exports.ForwardRef = ForwardRef;
4359
- exports.Fragment = Fragment34;
4359
+ exports.Fragment = Fragment33;
4360
4360
  exports.Lazy = Lazy;
4361
4361
  exports.Memo = Memo;
4362
4362
  exports.Portal = Portal2;
@@ -15953,7 +15953,8 @@ var VideoPlayer = ({ src }) => {
15953
15953
  };
15954
15954
 
15955
15955
  // src/widgets/basic/avatar-field/avatar.tsx
15956
- import { Fragment as Fragment15, jsx as jsx73, jsxs as jsxs48 } from "react/jsx-runtime";
15956
+ import { createPortal as createPortal4 } from "react-dom";
15957
+ import { jsx as jsx73, jsxs as jsxs48 } from "react/jsx-runtime";
15957
15958
  var AvatarField = (props) => {
15958
15959
  const {
15959
15960
  isForm = false,
@@ -15977,7 +15978,7 @@ var AvatarField = (props) => {
15977
15978
  color: textColor,
15978
15979
  fontSize: `${size4 / 2.5}px`
15979
15980
  };
15980
- return /* @__PURE__ */ jsxs48(Fragment15, { children: [
15981
+ return /* @__PURE__ */ jsxs48("div", { className: "relative", children: [
15981
15982
  isForm && allowShowDetail && /* @__PURE__ */ jsx73(
15982
15983
  ModalDetail,
15983
15984
  {
@@ -15989,14 +15990,17 @@ var AvatarField = (props) => {
15989
15990
  place: "top-start"
15990
15991
  }
15991
15992
  ),
15992
- allowShowDetail && /* @__PURE__ */ jsx73(
15993
- M,
15994
- {
15995
- id: `avatar-widget-id-${id}`,
15996
- place: isForm ? "bottom" : "top",
15997
- content: fullName,
15998
- className: "z-20"
15999
- }
15993
+ allowShowDetail && createPortal4(
15994
+ /* @__PURE__ */ jsx73(
15995
+ M,
15996
+ {
15997
+ id: `avatar-widget-id-${id}`,
15998
+ place: isForm ? "bottom" : "top",
15999
+ content: fullName,
16000
+ className: "z-20"
16001
+ }
16002
+ ),
16003
+ document.body
16000
16004
  ),
16001
16005
  avatarSrc ? /* @__PURE__ */ jsx73(
16002
16006
  "img",
@@ -16020,7 +16024,7 @@ var AvatarField = (props) => {
16020
16024
 
16021
16025
  // src/widgets/basic/binary-field/binary.tsx
16022
16026
  import { useEffect as useEffect11, useState as useState11 } from "react";
16023
- import { Fragment as Fragment16, jsx as jsx74, jsxs as jsxs49 } from "react/jsx-runtime";
16027
+ import { Fragment as Fragment15, jsx as jsx74, jsxs as jsxs49 } from "react/jsx-runtime";
16024
16028
  var BinaryField = (props) => {
16025
16029
  const {
16026
16030
  name: name2,
@@ -16146,7 +16150,7 @@ var BinaryField = (props) => {
16146
16150
  },
16147
16151
  render: ({ field, fieldState: { error: error2 } }) => {
16148
16152
  const hasFile = !!fileInfo;
16149
- return /* @__PURE__ */ jsxs49(Fragment16, { children: [
16153
+ return /* @__PURE__ */ jsxs49(Fragment15, { children: [
16150
16154
  /* @__PURE__ */ jsx74(
16151
16155
  "div",
16152
16156
  {
@@ -16361,7 +16365,7 @@ var ButtonBadgeField = (props) => {
16361
16365
  };
16362
16366
 
16363
16367
  // src/widgets/basic/button-field/button.tsx
16364
- import { Fragment as Fragment17, jsx as jsx76, jsxs as jsxs50 } from "react/jsx-runtime";
16368
+ import { Fragment as Fragment16, jsx as jsx76, jsxs as jsxs50 } from "react/jsx-runtime";
16365
16369
  var ButtonField = (props) => {
16366
16370
  const {
16367
16371
  func,
@@ -16372,7 +16376,7 @@ var ButtonField = (props) => {
16372
16376
  type = "submit"
16373
16377
  } = props;
16374
16378
  const { t: t3 } = useI18n();
16375
- return /* @__PURE__ */ jsx76(Fragment17, { children: !loading ? /* @__PURE__ */ jsx76(
16379
+ return /* @__PURE__ */ jsx76(Fragment16, { children: !loading ? /* @__PURE__ */ jsx76(
16376
16380
  "button",
16377
16381
  {
16378
16382
  type,
@@ -16398,7 +16402,7 @@ var ButtonField = (props) => {
16398
16402
 
16399
16403
  // src/widgets/basic/char-field/char.tsx
16400
16404
  import { useEffect as useEffect12, useMemo as useMemo4 } from "react";
16401
- import { Fragment as Fragment18, jsx as jsx77, jsxs as jsxs51 } from "react/jsx-runtime";
16405
+ import { Fragment as Fragment17, jsx as jsx77, jsxs as jsxs51 } from "react/jsx-runtime";
16402
16406
  var WIDGET_AUTO_COMPUTE_DEPEND = "auto_compute_depend_field";
16403
16407
  var CharField = (props) => {
16404
16408
  const {
@@ -16482,7 +16486,7 @@ var CharField = (props) => {
16482
16486
  }
16483
16487
  return "";
16484
16488
  }, [widget, formValues]);
16485
- return /* @__PURE__ */ jsxs51(Fragment18, { children: [
16489
+ return /* @__PURE__ */ jsxs51(Fragment17, { children: [
16486
16490
  /* @__PURE__ */ jsx77(
16487
16491
  "input",
16488
16492
  {
@@ -16544,7 +16548,7 @@ var CharField = (props) => {
16544
16548
  `
16545
16549
  }
16546
16550
  ),
16547
- isEditTable ? /* @__PURE__ */ jsx77(Fragment18, {}) : /* @__PURE__ */ jsx77(Fragment18, { children: error2 && /* @__PURE__ */ jsx77("p", { className: "text-[#de4747] text-sm mt-1", children: error2.message }) })
16551
+ isEditTable ? /* @__PURE__ */ jsx77(Fragment17, {}) : /* @__PURE__ */ jsx77(Fragment17, { children: error2 && /* @__PURE__ */ jsx77("p", { className: "text-[#de4747] text-sm mt-1", children: error2.message }) })
16548
16552
  ] });
16549
16553
  }
16550
16554
  }
@@ -16626,7 +16630,7 @@ var CheckboxField = (props) => {
16626
16630
 
16627
16631
  // src/widgets/basic/color-field/color-wrapper.tsx
16628
16632
  import { useEffect as useEffect13, useRef as useRef7, useState as useState12 } from "react";
16629
- import { Fragment as Fragment19, jsx as jsx79, jsxs as jsxs52 } from "react/jsx-runtime";
16633
+ import { Fragment as Fragment18, jsx as jsx79, jsxs as jsxs52 } from "react/jsx-runtime";
16630
16634
  var ColorWrapper = (props) => {
16631
16635
  const {
16632
16636
  colors: colors2,
@@ -16677,7 +16681,7 @@ var ColorWrapper = (props) => {
16677
16681
  content: i18n_default.t(color?.name)
16678
16682
  }
16679
16683
  )
16680
- ] }, color?.id)) }) : /* @__PURE__ */ jsxs52(Fragment19, { children: [
16684
+ ] }, color?.id)) }) : /* @__PURE__ */ jsxs52(Fragment18, { children: [
16681
16685
  /* @__PURE__ */ jsx79(
16682
16686
  "button",
16683
16687
  {
@@ -20777,7 +20781,7 @@ function useEffectEvent(callback) {
20777
20781
  }
20778
20782
 
20779
20783
  // node_modules/react-datepicker/node_modules/@floating-ui/react/dist/floating-ui.react.mjs
20780
- import { jsx as jsx82, jsxs as jsxs54, Fragment as Fragment20 } from "react/jsx-runtime";
20784
+ import { jsx as jsx82, jsxs as jsxs54, Fragment as Fragment19 } from "react/jsx-runtime";
20781
20785
  import * as ReactDOM2 from "react-dom";
20782
20786
 
20783
20787
  // node_modules/@floating-ui/react-dom/dist/floating-ui.react-dom.mjs
@@ -25851,7 +25855,7 @@ function _toConsumableArray(r4) {
25851
25855
 
25852
25856
  // node_modules/react-select/dist/Select-ef7c0426.esm.js
25853
25857
  import * as React13 from "react";
25854
- import { useMemo as useMemo8, Fragment as Fragment23, useRef as useRef14, useCallback as useCallback8, useEffect as useEffect17, Component as Component2 } from "react";
25858
+ import { useMemo as useMemo8, Fragment as Fragment22, useRef as useRef14, useCallback as useCallback8, useEffect as useEffect17, Component as Component2 } from "react";
25855
25859
 
25856
25860
  // node_modules/@emotion/react/dist/emotion-element-d59e098f.esm.js
25857
25861
  import * as React11 from "react";
@@ -27184,7 +27188,7 @@ function _taggedTemplateLiteral(e3, t3) {
27184
27188
 
27185
27189
  // node_modules/react-select/dist/index-641ee5b8.esm.js
27186
27190
  import { useContext as useContext9, useRef as useRef13, useState as useState16, useMemo as useMemo7, useCallback as useCallback7, createContext as createContext5 } from "react";
27187
- import { createPortal as createPortal5 } from "react-dom";
27191
+ import { createPortal as createPortal6 } from "react-dom";
27188
27192
 
27189
27193
  // node_modules/use-isomorphic-layout-effect/dist/use-isomorphic-layout-effect.esm.js
27190
27194
  import { useLayoutEffect as useLayoutEffect4 } from "react";
@@ -27687,7 +27691,7 @@ var MenuPortal = function MenuPortal2(props) {
27687
27691
  }), innerProps), children);
27688
27692
  return jsx83(PortalPlacementContext.Provider, {
27689
27693
  value: portalPlacementContext
27690
- }, appendTo ? /* @__PURE__ */ createPortal5(menuWrapper, appendTo) : menuWrapper);
27694
+ }, appendTo ? /* @__PURE__ */ createPortal6(menuWrapper, appendTo) : menuWrapper);
27691
27695
  };
27692
27696
  var containerCSS = function containerCSS2(_ref3) {
27693
27697
  var isDisabled = _ref3.isDisabled, isRtl = _ref3.isRtl;
@@ -28416,7 +28420,7 @@ var LiveRegion = function LiveRegion2(props) {
28416
28420
  }
28417
28421
  return guidanceMsg;
28418
28422
  }, [ariaLabel, focusedOption, focusedValue, isMulti, isOptionDisabled3, isSearchable, menuIsOpen, messages, selectValue, tabSelectsValue, isInitialFocus]);
28419
- var ScreenReaderText = jsx83(Fragment23, null, jsx83("span", {
28423
+ var ScreenReaderText = jsx83(Fragment22, null, jsx83("span", {
28420
28424
  id: "aria-selection"
28421
28425
  }, ariaSelected), jsx83("span", {
28422
28426
  id: "aria-focused"
@@ -28425,7 +28429,7 @@ var LiveRegion = function LiveRegion2(props) {
28425
28429
  }, ariaResults), jsx83("span", {
28426
28430
  id: "aria-guidance"
28427
28431
  }, ariaGuidance));
28428
- return jsx83(Fragment23, null, jsx83(A11yText$1, {
28432
+ return jsx83(Fragment22, null, jsx83(A11yText$1, {
28429
28433
  id
28430
28434
  }, isInitialFocus && ScreenReaderText), jsx83(A11yText$1, {
28431
28435
  "aria-live": ariaLive,
@@ -28982,7 +28986,7 @@ function ScrollManager(_ref3) {
28982
28986
  setScrollCaptureTarget(element);
28983
28987
  setScrollLockTarget(element);
28984
28988
  };
28985
- return jsx83(Fragment23, null, lockEnabled && jsx83("div", {
28989
+ return jsx83(Fragment22, null, lockEnabled && jsx83("div", {
28986
28990
  onClick: blurSelectInput,
28987
28991
  css: _ref2$1
28988
28992
  }), children(targetRef));
@@ -30591,7 +30595,7 @@ var StateManagedSelect$1 = StateManagedSelect;
30591
30595
 
30592
30596
  // src/widgets/basic/date-field/date.tsx
30593
30597
  var import_moment2 = __toESM(require_moment());
30594
- import { Fragment as Fragment24, jsx as jsx85, jsxs as jsxs55 } from "react/jsx-runtime";
30598
+ import { Fragment as Fragment23, jsx as jsx85, jsxs as jsxs55 } from "react/jsx-runtime";
30595
30599
  var DateField = (props) => {
30596
30600
  const {
30597
30601
  name: name2,
@@ -30662,7 +30666,7 @@ var DateField = (props) => {
30662
30666
  }
30663
30667
  }, [value, clearErrors, name2]);
30664
30668
  const selectedDate = !methods ? value && (0, import_moment2.default)(value, formatDateParse).isValid() ? (0, import_moment2.default)(value, formatDateParse).add(7, "hours").toDate() : null : field?.value && (0, import_moment2.default)(field.value, formatDateParse).isValid() ? (0, import_moment2.default)(field.value, formatDateParse).add(7, "hours").toDate() : null;
30665
- return /* @__PURE__ */ jsxs55(Fragment24, { children: [
30669
+ return /* @__PURE__ */ jsxs55(Fragment23, { children: [
30666
30670
  /* @__PURE__ */ jsx85(
30667
30671
  DatePicker,
30668
30672
  {
@@ -30946,7 +30950,7 @@ var DropdownField = (props) => {
30946
30950
  };
30947
30951
 
30948
30952
  // src/widgets/basic/fee-field/fee.tsx
30949
- import { Fragment as Fragment25, jsx as jsx89, jsxs as jsxs59 } from "react/jsx-runtime";
30953
+ import { Fragment as Fragment24, jsx as jsx89, jsxs as jsxs59 } from "react/jsx-runtime";
30950
30954
  var FeeField = (props) => {
30951
30955
  const { value, formValues } = props;
30952
30956
  const { t: t3 } = useI18n();
@@ -30957,10 +30961,10 @@ var FeeField = (props) => {
30957
30961
  )
30958
30962
  ) + " VND";
30959
30963
  const remaining_amount = formatNumberOnly(parseFloat(formValues?.amount_residual ?? 0)) + " VND";
30960
- return /* @__PURE__ */ jsxs59(Fragment25, { children: [
30964
+ return /* @__PURE__ */ jsxs59(Fragment24, { children: [
30961
30965
  value?.subtotals?.map((sub) => {
30962
30966
  if (sub?.tax_amount > 0 && sub?.tax_groups?.length > 0) {
30963
- return /* @__PURE__ */ jsxs59(Fragment25, { children: [
30967
+ return /* @__PURE__ */ jsxs59(Fragment24, { children: [
30964
30968
  /* @__PURE__ */ jsxs59("div", { className: "grid grid-cols-2 gap-x-4 gap-y-2 min-w-[300px] max-w-fit ml-auto", children: [
30965
30969
  /* @__PURE__ */ jsxs59("div", { className: "text-[14px] leading-[21px] text-right", children: [
30966
30970
  sub?.name,
@@ -31153,7 +31157,7 @@ var FileUploadField = (props) => {
31153
31157
 
31154
31158
  // src/widgets/basic/float-field/float.tsx
31155
31159
  import { useEffect as useEffect20, useRef as useRef16, useState as useState19 } from "react";
31156
- import { Fragment as Fragment26, jsx as jsx91, jsxs as jsxs61 } from "react/jsx-runtime";
31160
+ import { Fragment as Fragment25, jsx as jsx91, jsxs as jsxs61 } from "react/jsx-runtime";
31157
31161
  var FloatField = (props) => {
31158
31162
  const {
31159
31163
  name: name2,
@@ -31280,7 +31284,7 @@ var FloatField = (props) => {
31280
31284
  }
31281
31285
  isDirtyRef.current = false;
31282
31286
  };
31283
- return /* @__PURE__ */ jsxs61(Fragment26, { children: [
31287
+ return /* @__PURE__ */ jsxs61(Fragment25, { children: [
31284
31288
  /* @__PURE__ */ jsx91(
31285
31289
  "input",
31286
31290
  {
@@ -31310,7 +31314,7 @@ var FloatField = (props) => {
31310
31314
 
31311
31315
  // src/widgets/basic/float-time-field/float-time.tsx
31312
31316
  import { useState as useState20 } from "react";
31313
- import { Fragment as Fragment27, jsx as jsx92, jsxs as jsxs62 } from "react/jsx-runtime";
31317
+ import { Fragment as Fragment26, jsx as jsx92, jsxs as jsxs62 } from "react/jsx-runtime";
31314
31318
  var FloatTimeField = (props) => {
31315
31319
  const {
31316
31320
  name: name2,
@@ -31390,7 +31394,7 @@ var FloatTimeField = (props) => {
31390
31394
  }
31391
31395
  onBlur();
31392
31396
  };
31393
- return /* @__PURE__ */ jsxs62(Fragment27, { children: [
31397
+ return /* @__PURE__ */ jsxs62(Fragment26, { children: [
31394
31398
  /* @__PURE__ */ jsx92(
31395
31399
  "input",
31396
31400
  {
@@ -31500,11 +31504,11 @@ var ImageField = (props) => {
31500
31504
  import React16, { useEffect as useEffect22, useMemo as useMemo10 } from "react";
31501
31505
 
31502
31506
  // src/widgets/basic/information-field/information.tsx
31503
- import { Fragment as Fragment28, jsx as jsx95, jsxs as jsxs63 } from "react/jsx-runtime";
31507
+ import { Fragment as Fragment27, jsx as jsx95, jsxs as jsxs63 } from "react/jsx-runtime";
31504
31508
  var InfomationField = (props) => {
31505
31509
  const { value, isForm = false, showName = true, stringToColor } = props;
31506
31510
  if (!value || Array.isArray(value) && value.length === 0) {
31507
- return /* @__PURE__ */ jsx95(Fragment28, {});
31511
+ return /* @__PURE__ */ jsx95(Fragment27, {});
31508
31512
  }
31509
31513
  const inforValues = Array.isArray(value) ? value : [value];
31510
31514
  return /* @__PURE__ */ jsx95("div", { className: "group relative flex items-center gap-1 rounded-lg transition-shadow duration-300", children: inforValues.length > 1 ? inforValues.map((item) => /* @__PURE__ */ jsx95(
@@ -31779,7 +31783,7 @@ var Many2ManyTagField = (props) => {
31779
31783
 
31780
31784
  // src/widgets/basic/monetary-field/monetary.tsx
31781
31785
  import { useEffect as useEffect23 } from "react";
31782
- import { Fragment as Fragment29, jsx as jsx97, jsxs as jsxs65 } from "react/jsx-runtime";
31786
+ import { Fragment as Fragment28, jsx as jsx97, jsxs as jsxs65 } from "react/jsx-runtime";
31783
31787
  var MonetaryField = (props) => {
31784
31788
  const { t: t3 } = useI18n();
31785
31789
  const {
@@ -31837,7 +31841,7 @@ var MonetaryField = (props) => {
31837
31841
  clearErrors(name2);
31838
31842
  }
31839
31843
  }, [value2]);
31840
- return /* @__PURE__ */ jsxs65(Fragment29, { children: [
31844
+ return /* @__PURE__ */ jsxs65(Fragment28, { children: [
31841
31845
  /* @__PURE__ */ jsx97(
31842
31846
  "input",
31843
31847
  {
@@ -32099,7 +32103,7 @@ var RemainingDaysField = (props) => {
32099
32103
  };
32100
32104
 
32101
32105
  // src/widgets/basic/select-dropdown-field/select-dropdown.tsx
32102
- import { Fragment as Fragment30, jsx as jsx103, jsxs as jsxs69 } from "react/jsx-runtime";
32106
+ import { Fragment as Fragment29, jsx as jsx103, jsxs as jsxs69 } from "react/jsx-runtime";
32103
32107
  var SelectDropdownField = (props) => {
32104
32108
  const { t: t3 } = useI18n();
32105
32109
  const {
@@ -32150,7 +32154,7 @@ var SelectDropdownField = (props) => {
32150
32154
  value: defaultValue || null,
32151
32155
  required: !invisible && required
32152
32156
  };
32153
- return /* @__PURE__ */ jsxs69(Fragment30, { children: [
32157
+ return /* @__PURE__ */ jsxs69(Fragment29, { children: [
32154
32158
  /* @__PURE__ */ jsx103("div", { className: "group", children: /* @__PURE__ */ jsx103(
32155
32159
  StateManagedSelect$1,
32156
32160
  {
@@ -32332,7 +32336,7 @@ var ToggleButtonField = (props) => {
32332
32336
 
32333
32337
  // src/widgets/basic/integer-field/integer.tsx
32334
32338
  import { useEffect as useEffect26, useRef as useRef18, useState as useState22 } from "react";
32335
- import { Fragment as Fragment31, jsx as jsx106, jsxs as jsxs71 } from "react/jsx-runtime";
32339
+ import { Fragment as Fragment30, jsx as jsx106, jsxs as jsxs71 } from "react/jsx-runtime";
32336
32340
  var IntegerField = (props) => {
32337
32341
  const {
32338
32342
  name: name2,
@@ -32431,7 +32435,7 @@ var IntegerField = (props) => {
32431
32435
  inputRef.current?.blur();
32432
32436
  clearErrors(name2);
32433
32437
  };
32434
- return /* @__PURE__ */ jsxs71(Fragment31, { children: [
32438
+ return /* @__PURE__ */ jsxs71(Fragment30, { children: [
32435
32439
  /* @__PURE__ */ jsx106(
32436
32440
  "input",
32437
32441
  {
@@ -32530,7 +32534,7 @@ var StatusDropdownField = (props) => {
32530
32534
  };
32531
32535
 
32532
32536
  // src/widgets/basic/many2many-field/many2many.tsx
32533
- import { createPortal as createPortal6 } from "react-dom";
32537
+ import { createPortal as createPortal7 } from "react-dom";
32534
32538
  import { useEffect as useEffect27 } from "react";
32535
32539
  import { jsx as jsx108, jsxs as jsxs73 } from "react/jsx-runtime";
32536
32540
  var Many2ManyField = (props) => {
@@ -32605,7 +32609,7 @@ var Many2ManyField = (props) => {
32605
32609
  typeof setGroupByList === "function" && setGroupByList(null);
32606
32610
  };
32607
32611
  }, [selectedTags]);
32608
- return createPortal6(
32612
+ return createPortal7(
32609
32613
  /* @__PURE__ */ jsxs73(
32610
32614
  "div",
32611
32615
  {
@@ -32812,7 +32816,7 @@ var Many2ManyField = (props) => {
32812
32816
 
32813
32817
  // src/widgets/basic/many2one-field/many2one.tsx
32814
32818
  import React18, { useEffect as useEffect28 } from "react";
32815
- import { Fragment as Fragment32, jsx as jsx109, jsxs as jsxs74 } from "react/jsx-runtime";
32819
+ import { Fragment as Fragment31, jsx as jsx109, jsxs as jsxs74 } from "react/jsx-runtime";
32816
32820
  var CustomMenuList2 = (props) => {
32817
32821
  const { t: t3 } = useI18n();
32818
32822
  const { options: options2, children, selectProps } = props;
@@ -32863,7 +32867,7 @@ var Many2OneField = (props) => {
32863
32867
  const { t: t3 } = useI18n();
32864
32868
  if (!isForm && !isEditTable) {
32865
32869
  const id = propValue && typeof propValue === "object" && "id" in propValue ? propValue?.id : propValue;
32866
- return /* @__PURE__ */ jsxs74(Fragment32, { children: [
32870
+ return /* @__PURE__ */ jsxs74(Fragment31, { children: [
32867
32871
  allowShowDetail && renderDetail({
32868
32872
  idToolTip: String(name2) + Number(index4),
32869
32873
  model: options2?.model ?? relation,
@@ -32881,7 +32885,7 @@ var Many2OneField = (props) => {
32881
32885
  )
32882
32886
  ] });
32883
32887
  }
32884
- return /* @__PURE__ */ jsxs74(Fragment32, { children: [
32888
+ return /* @__PURE__ */ jsxs74(Fragment31, { children: [
32885
32889
  allowShowDetail && renderDetail({
32886
32890
  idToolTip: String(name2),
32887
32891
  model: options2?.model ?? relation,
@@ -33114,7 +33118,7 @@ var StatusbarDurationField = (props) => {
33114
33118
 
33115
33119
  // src/widgets/basic/status-bar-field/option/option.tsx
33116
33120
  import { useMemo as useMemo11 } from "react";
33117
- import { Fragment as Fragment33, jsx as jsx111, jsxs as jsxs76 } from "react/jsx-runtime";
33121
+ import { Fragment as Fragment32, jsx as jsx111, jsxs as jsxs76 } from "react/jsx-runtime";
33118
33122
  var StatusBarOptionField = (props) => {
33119
33123
  const { selection, defaultValue } = props;
33120
33124
  const memoizedStatusOptions = useMemo11(() => selection, [selection]);
@@ -33130,7 +33134,7 @@ var StatusBarOptionField = (props) => {
33130
33134
  flexWrap: "wrap"
33131
33135
  },
33132
33136
  children: memoizedStatusOptions?.map((option, index4) => {
33133
- return /* @__PURE__ */ jsxs76(Fragment33, { children: [
33137
+ return /* @__PURE__ */ jsxs76(Fragment32, { children: [
33134
33138
  /* @__PURE__ */ jsxs76(
33135
33139
  "div",
33136
33140
  {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@fctc/sme-widget-ui",
3
- "version": "2.0.6",
3
+ "version": "2.0.8",
4
4
  "main": "dist/index.cjs",
5
5
  "module": "dist/index.mjs",
6
6
  "types": "dist/index.d.ts",