@epam/ai-dial-ui-kit 0.15.0-dev.37 → 0.15.0-dev.38

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.
@@ -13,9 +13,9 @@ const Z = '[role="menuitem"], [role="menuitemcheckbox"], [role="menuitemradio"],
13
13
  const s = t === "ArrowDown" ? 1 : -1;
14
14
  return n === -1 ? s === 1 ? 0 : o - 1 : (n + s + o) % o;
15
15
  };
16
- function ce(t, n = "menu", o = !1, s) {
17
- const [r, i] = b(!1), l = M(), { refs: a, elements: p, floatingStyles: S, context: u } = k({
18
- nodeId: l,
16
+ function le(t, n = "menu", o = !1, s) {
17
+ const [r, i] = b(!1), u = M(), { refs: a, elements: p, floatingStyles: S, context: c } = k({
18
+ nodeId: u,
19
19
  placement: "right-start",
20
20
  open: r,
21
21
  onOpenChange: i,
@@ -25,7 +25,7 @@ function ce(t, n = "menu", o = !1, s) {
25
25
  H({ padding: t }),
26
26
  L({ padding: t })
27
27
  ]
28
- }), O = B(u, {
28
+ }), O = B(c, {
29
29
  enabled: !o,
30
30
  move: !1,
31
31
  /* Lets the pointer travel into a nested floating element — an
@@ -34,9 +34,10 @@ function ce(t, n = "menu", o = !1, s) {
34
34
  wiring the trigger's own `nodeId` connects to. */
35
35
  handleClose: V(),
36
36
  delay: { open: 80, close: 80 }
37
- }), D = j(u, { enabled: !o }), R = q(u, {
37
+ }), D = j(c, { enabled: !o }), R = q(c, {
38
+ ancestorScroll: !0,
38
39
  bubbles: { escapeKey: !1, outsidePress: !0 }
39
- }), T = z(u, { role: n }), {
40
+ }), T = z(c, { role: n }), {
40
41
  getReferenceProps: g,
41
42
  getFloatingProps: y
42
43
  } = X([O, D, R, T]), [w, h] = b(!1), d = p.floating;
@@ -57,10 +58,10 @@ function ce(t, n = "menu", o = !1, s) {
57
58
  }
58
59
  if (!$.includes(e.key)) return;
59
60
  e.preventDefault(), e.stopPropagation();
60
- const c = A(e.currentTarget);
61
- if (c.length === 0) return;
62
- const I = e.currentTarget.ownerDocument.activeElement, K = c.findIndex((C) => C === I);
63
- c[oe(e.key, K, c.length)]?.focus();
61
+ const l = A(e.currentTarget);
62
+ if (l.length === 0) return;
63
+ const I = e.currentTarget.ownerDocument.activeElement, K = l.findIndex((C) => C === I);
64
+ l[oe(e.key, K, l.length)]?.focus();
64
65
  },
65
66
  [a.domReference]
66
67
  ), x = f(
@@ -78,22 +79,22 @@ function ce(t, n = "menu", o = !1, s) {
78
79
  );
79
80
  return {
80
81
  isOpen: r,
81
- nodeId: l,
82
+ nodeId: u,
82
83
  refs: a,
83
84
  floatingStyles: S,
84
- context: u,
85
+ context: c,
85
86
  getReferenceProps: x,
86
87
  getFloatingProps: N
87
88
  };
88
89
  }
89
- const ne = "rounded bg-layer-0 shadow", le = ({
90
+ const ne = "rounded bg-layer-0 shadow", ue = ({
90
91
  refs: t,
91
92
  floatingStyles: n,
92
93
  context: o,
93
94
  getFloatingProps: s,
94
95
  role: r,
95
96
  surfaceClassName: i,
96
- className: l,
97
+ className: u,
97
98
  children: a
98
99
  }) => {
99
100
  const p = W();
@@ -114,7 +115,7 @@ const ne = "rounded bg-layer-0 shadow", le = ({
114
115
  "z-floating overflow-auto text-primary focus-visible:outline-none",
115
116
  i ?? ne,
116
117
  p,
117
- l
118
+ u
118
119
  ),
119
120
  ...s(),
120
121
  children: a
@@ -124,6 +125,6 @@ const ne = "rounded bg-layer-0 shadow", le = ({
124
125
  ) });
125
126
  };
126
127
  export {
127
- le as SubMenuPanel,
128
- ce as useSubMenuFloating
128
+ ue as SubMenuPanel,
129
+ le as useSubMenuFloating
129
130
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@epam/ai-dial-ui-kit",
3
- "version": "0.15.0-dev.37",
3
+ "version": "0.15.0-dev.38",
4
4
  "type": "module",
5
5
  "license": "Apache-2.0",
6
6
  "description": "A modern UI kit for building AI DIAL interfaces with React",
@@ -81,13 +81,8 @@
81
81
  ]
82
82
  },
83
83
  "overrides": {
84
- "lodash": "4.18.1",
85
- "dompurify": "3.4.12",
86
- "shell-quote": "1.10.0",
87
- "esbuild": "0.28.1",
88
- "undici": "^6.28.1",
89
- "brace-expansion": "^5.0.12",
90
- "minimatch": "^10.2.5"
84
+ "dompurify": "3.4.16",
85
+ "postcss-selector-parser": "^7.1.6"
91
86
  },
92
87
  "dependencies": {
93
88
  "@floating-ui/react": "^0.27.19",