@oliasoft-open-source/react-ui-library 5.18.0-beta-1 → 5.18.1

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.
Files changed (2) hide show
  1. package/dist/index.js +24 -24
  2. package/package.json +1 -1
package/dist/index.js CHANGED
@@ -965,30 +965,30 @@ const Trigger$1 = React.forwardRef(({ active: e, isDisabled: t, badgeTitle: n, b
965
965
  var isMenuEmpty = (e) => {
966
966
  let { sections: t } = e;
967
967
  return !isValidElement(t) && (!Array.isArray(t) || t.every((e) => isEmpty(e)));
968
- }, useContextMenu = ({ sections: e, width: t, placement: n, possiblePlacements: r, closeOnOptionClick: i, closeParent: a, tree: o, path: s, groupOrder: c, overflowContainer: l, maxHeight: u, testId: d }) => {
969
- let { hasMousePosition: f, resetMousePosition: p, handleMouseEvent: m, trigger: h } = useMousePositionAsTrigger(), g = p, _ = f, { layerProps: v, renderLayer: y } = useLayer({
970
- isOpen: _,
971
- trigger: h,
968
+ }, useContextMenu = ({ sections: e, width: t, placement: n, possiblePlacements: r, closeOnOptionClick: i, closeParent: a, tree: o, path: s, overflowContainer: c, maxHeight: l, testId: u }) => {
969
+ let { hasMousePosition: d, resetMousePosition: f, handleMouseEvent: p, trigger: m } = useMousePositionAsTrigger(), h = f, g = d, { layerProps: _, renderLayer: v } = useLayer({
970
+ isOpen: g,
971
+ trigger: m,
972
972
  ...placementOptions$1(n),
973
973
  possiblePlacements: r,
974
974
  ResizeObserver: ResizeObserver$1,
975
- onOutsideClick: g,
976
- overflowContainer: l
975
+ onOutsideClick: h,
976
+ overflowContainer: c
977
977
  });
978
- return [_ && y(/* @__PURE__ */ jsx("div", {
979
- ...v,
978
+ return [g && v(/* @__PURE__ */ jsx("div", {
979
+ ..._,
980
980
  children: /* @__PURE__ */ jsx(Layer$2, {
981
981
  isNested: !1,
982
982
  width: t,
983
983
  sections: e,
984
984
  closeOnOptionClick: i,
985
- close: a || g,
985
+ close: a || h,
986
986
  tree: o,
987
987
  path: s,
988
- maxHeight: u,
989
- testId: d && `${d}-layer`
988
+ maxHeight: l,
989
+ testId: u && `${u}-layer`
990
990
  })
991
- })), m];
991
+ })), p];
992
992
  }, ContextMenu = ({ menu: e, width: t, disabled: n = !1, closeOnOptionClick: r = !0, closeParent: i, tree: a, path: o, groupOrder: c, testId: l }) => {
993
993
  let u = useContext(DisabledContext), { label: d, trigger: f, fullHeightTrigger: p, colored: m, small: h, component: g, placement: _, possiblePlacements: v = ["bottom-start", "top-start"] } = e, [y, b] = useContextMenu({
994
994
  sections: e.sections,
@@ -3137,24 +3137,24 @@ const InputGroupAddon = ({ children: e, groupOrder: t, small: n = !1 }) => {
3137
3137
  })
3138
3138
  ]
3139
3139
  });
3140
- }, Footer = ({ colSpan: e, pagination: t, actions: n, content: r, testId: i }) => {
3141
- let a = n && n.length, o = r != null, s = () => {
3142
- if (t) {
3143
- var e;
3144
- let { rowCount: n, rowsPerPage: r } = t;
3145
- return n > Number(r == null || (e = r.options) == null || (e = e[0]) == null ? void 0 : e.value);
3140
+ }, Footer = ({ pagination: e, actions: t, content: n, testId: r }) => {
3141
+ let i = t && t.length, a = n != null, o = () => {
3142
+ if (e) {
3143
+ var t;
3144
+ let { rowCount: n, rowsPerPage: r } = e;
3145
+ return n > Number(r == null || (t = r.options) == null || (t = t[0]) == null ? void 0 : t.value);
3146
3146
  }
3147
3147
  return !1;
3148
3148
  };
3149
- return a || o || s() ? /* @__PURE__ */ jsxs("div", {
3149
+ return i || a || o() ? /* @__PURE__ */ jsxs("div", {
3150
3150
  className: footer_module_default.footer,
3151
- "data-testid": `${i == null ? "pagination" : i}-footer`,
3152
- children: [o ? /* @__PURE__ */ jsx("div", {
3151
+ "data-testid": `${r == null ? "pagination" : r}-footer`,
3152
+ children: [a ? /* @__PURE__ */ jsx("div", {
3153
3153
  className: footer_module_default.section,
3154
- children: /* @__PURE__ */ jsx("div", { children: r })
3155
- }) : null, a || s() ? /* @__PURE__ */ jsxs("div", {
3154
+ children: /* @__PURE__ */ jsx("div", { children: n })
3155
+ }) : null, i || o() ? /* @__PURE__ */ jsxs("div", {
3156
3156
  className: footer_module_default.section,
3157
- children: [t && s() ? /* @__PURE__ */ jsx(Pagination, { pagination: t }) : /* @__PURE__ */ jsx("div", {}), a && /* @__PURE__ */ jsx("div", { children: /* @__PURE__ */ jsx(Actions, { actions: n }) })]
3157
+ children: [e && o() ? /* @__PURE__ */ jsx(Pagination, { pagination: e }) : /* @__PURE__ */ jsx("div", {}), i && /* @__PURE__ */ jsx("div", { children: /* @__PURE__ */ jsx(Actions, { actions: t }) })]
3158
3158
  }) : null]
3159
3159
  }) : null;
3160
3160
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@oliasoft-open-source/react-ui-library",
3
- "version": "5.18.0-beta-1",
3
+ "version": "5.18.1",
4
4
  "description": "Reusable UI components for React projects",
5
5
  "homepage": "https://oliasoft-open-source.gitlab.io/react-ui-library",
6
6
  "bugs": {