@epam/ai-dial-conversation-panel 1.0.0-dev.484 → 1.0.0-dev.486

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.
@@ -1 +1 @@
1
- {"version":3,"file":"FilterTabs.d.ts","sourceRoot":"","sources":["../../../src/components/FilterTabs/FilterTabs.tsx"],"names":[],"mappings":"AACA,OAAO,EAAE,KAAK,EAAE,EAAQ,MAAM,OAAO,CAAC;AACtC,OAAO,EAAE,KAAK,YAAY,EAAE,MAAM,0BAA0B,CAAC;AAC7D,OAAO,EAAE,SAAS,EAAE,MAAM,yCAAyC,CAAC;AAEpE,8BAA8B;AAC9B,MAAM,WAAW,eAAe;IAC9B,4BAA4B;IAC5B,SAAS,EAAE,SAAS,CAAC;IACrB,kEAAkE;IAClE,MAAM,EAAE,YAAY,CAAC;IACrB,oDAAoD;IACpD,QAAQ,EAAE,CAAC,GAAG,EAAE,SAAS,KAAK,IAAI,CAAC;IACnC,sEAAsE;IACtE,YAAY,CAAC,EAAE,MAAM,CAAC;CACvB;AASD,wEAAwE;AACxE,eAAO,MAAM,UAAU,EAAE,EAAE,CAAC,eAAe,CAc1C,CAAC"}
1
+ {"version":3,"file":"FilterTabs.d.ts","sourceRoot":"","sources":["../../../src/components/FilterTabs/FilterTabs.tsx"],"names":[],"mappings":"AAEA,OAAO,EAAE,KAAK,EAAE,EAAQ,MAAM,OAAO,CAAC;AACtC,OAAO,EAAE,KAAK,YAAY,EAAE,MAAM,0BAA0B,CAAC;AAC7D,OAAO,EAAE,SAAS,EAAE,MAAM,yCAAyC,CAAC;AAEpE,8BAA8B;AAC9B,MAAM,WAAW,eAAe;IAC9B,4BAA4B;IAC5B,SAAS,EAAE,SAAS,CAAC;IACrB,kEAAkE;IAClE,MAAM,EAAE,YAAY,CAAC;IACrB,oDAAoD;IACpD,QAAQ,EAAE,CAAC,GAAG,EAAE,SAAS,KAAK,IAAI,CAAC;IACnC,sEAAsE;IACtE,YAAY,CAAC,EAAE,MAAM,CAAC;CACvB;AASD,wEAAwE;AACxE,eAAO,MAAM,UAAU,EAAE,EAAE,CAAC,eAAe,CAc1C,CAAC"}
package/index.css CHANGED
@@ -1,2 +1,2 @@
1
- ._tab_1mi6x_1{color:var(--text-tertiary,#808898);background-color:#0000;border-color:#0000!important}._tab_1mi6x_1:hover{color:var(--text-secondary,#64748b);background-color:#5c8dea0f}._tab_1mi6x_1>span{text-align:center}._tab_1mi6x_1._tabActive_1mi6x_13{color:var(--text-secondary,#64748b);background-color:#2764d912}._tab_1mi6x_1._tabActive_1mi6x_13:hover{background-color:#5c8dea0f}.dial-primary-solid-button{background-image:linear-gradient(135deg, var(--bg-accent-secondary,#37babc) 0%, var(--bg-accent-primary,#5c8dea) 30%, var(--bg-accent-tertiary,#a972ff) 100%);border-style:none;border-radius:9999px;transition:box-shadow .2s,transform .15s;box-shadow:0 0 16px #37babc40,0 4px 12px #a972ff38;background-color:#0000!important;padding-inline:24px!important}@media (hover:hover){.dial-primary-solid-button:hover{background-color:#0000;background-image:linear-gradient(135deg, var(--bg-accent-secondary,#37babc) 0%, var(--bg-accent-primary,#5c8dea) 30%, var(--bg-accent-tertiary,#a972ff) 100%);transform:translateY(-1px);box-shadow:0 0 24px #37babc59,0 6px 18px #a972ff4d}}.dial-primary-solid-button:active{background-color:#0000;background-image:linear-gradient(135deg, var(--bg-accent-secondary,#37babc) 0%, var(--bg-accent-primary,#5c8dea) 30%, var(--bg-accent-tertiary,#a972ff) 100%);filter:brightness(.92);transform:translateY(0);box-shadow:0 0 10px #37babc33,0 2px 6px #a972ff29}.dial-primary-solid-button:disabled{box-shadow:none;cursor:not-allowed;background-image:none;transform:none;background-color:var(--controls-bg-disable,#d1dbea)!important;color:var(--text-white,#fff)!important}.dial-danger-solid-button{border-radius:9999px!important}.dial-primary-solid-button.dial-primary-solid-button{background-color:#0000;background-image:linear-gradient(135deg,#4b7be6 0%,#9355f4 100%);border:none;border-radius:9999px;transition:box-shadow .2s,transform .15s;box-shadow:0 4px 16px #5c8dea52}@media (hover:hover){.dial-primary-solid-button.dial-primary-solid-button:hover{background-color:#0000;background-image:linear-gradient(135deg,#4b7be6 0%,#9355f4 100%);transform:translateY(-1px);box-shadow:0 6px 20px #5c8dea6b}}.dial-primary-solid-button.dial-primary-solid-button:active{filter:brightness(.92);background-color:#0000;background-image:linear-gradient(135deg,#4b7be6 0%,#9355f4 100%);transform:translateY(0);box-shadow:0 2px 8px #5c8dea38}.dial-primary-solid-button.dial-primary-solid-button:disabled{box-shadow:none;background-image:none;transform:none}.dial-neutral-outlined-button{transition:background-color .15s,border-color .15s;color:var(--bg-accent-primary,#2764d9)!important;background-color:#2764d914!important;background-image:none!important;border:1px solid #2764d933!important;border-radius:9999px!important}@media (hover:hover){.dial-neutral-outlined-button:hover:enabled{background-color:#2764d921!important;border-color:#2764d959!important}}.dial-neutral-outlined-button:active:enabled{background-color:#2764d92e!important;border-color:#2764d973!important}.dial-neutral-outlined-button:disabled{border-color:var(--stroke-secondary,#d1dbea);color:var(--controls-text-neutral-disable,#575f73);background-color:#0000;background-image:none}.dial-primary-ghost-button:not(.dial-icon-button){border-style:none;border-radius:9999px;color:var(--bg-accent-primary,#2764d9)!important}@media (hover:hover){.dial-primary-ghost-button:not(.dial-icon-button):hover:enabled{background-color:#2764d90d!important}}.dial-primary-ghost-button:not(.dial-icon-button):active:enabled{background-color:#2764d914!important}.dial-icon-button{border-radius:6px!important}.dial-input:not(.dial-input-error){transition:border-color .15s,box-shadow .15s;border-color:var(--stroke-tertiary,#e0e6f0)!important;border-radius:.75rem!important}.dial-input:not(.dial-input-error):not(:disabled):hover{border-color:var(--stroke-accent-primary,#7da4ff)!important}.dial-input:not(.dial-input-error):not(:disabled):active,.dial-input:not(.dial-input-error):not(:disabled):focus,.dial-input:not(.dial-input-error):not(:disabled):focus-within{border-color:var(--stroke-accent-primary,#124ace)!important;box-shadow:0 0 0 4px var(--bg-accent-primary-alpha,#7da4ff2e)!important}.dial-input-error{border-radius:.75rem!important}._button_1ggx8_1{background:var(--cp-new-chat-bg,var(--bg-layer-0,#fcfcfc));box-shadow:0 1px 3px var(--cp-new-chat-shadow-blue,var(--bg-new-chat-shadow-blue,#5c8dea33)), 0 2px 10px var(--cp-new-chat-shadow-purple,var(--bg-new-chat-shadow-purple,#a972ff24));color:var(--cp-new-chat-text,var(--text-accent-primary,#124ace));transition:box-shadow .15s,background-color .15s}._button_1ggx8_1:hover{background:var(--cp-new-chat-hover,var(--bg-layer-0,#fcfcfc));box-shadow:0 2px 6px var(--cp-new-chat-shadow-blue-hover,var(--bg-new-chat-shadow-blue-hover,#5c8dea47)), 0 4px 16px var(--cp-new-chat-shadow-purple-hover,var(--bg-new-chat-shadow-purple-hover,#a972ff33))}._button_1ggx8_1:active{background:var(--cp-new-chat-active,var(--bg-layer-5,#f5f7fa));box-shadow:0 1px 2px var(--cp-new-chat-shadow-blue-active,var(--bg-new-chat-shadow-blue-active,#5c8dea26)), 0 1px 6px var(--cp-new-chat-shadow-purple-active,var(--bg-new-chat-shadow-purple-active,#a972ff1a))}._header_dr0k7_1,._item_dr0k7_5{color:var(--cp-text,var(--text-primary,#161b2d))}._item_dr0k7_5:hover{background:var(--cp-item-hover,var(--bg-layer-2,#eef1f7))}._item_dr0k7_5._itemActive_dr0k7_11{background:var(--cp-item-active,var(--bg-layer-2,#eef1f7));color:var(--cp-text,var(--text-primary,#161b2d))}._groupHeader_dr0k7_16{color:var(--cp-text-secondary,var(--text-primary,#161b2d))}._dropZoneActive_dr0k7_20{--tw-ring-offset-shadow:var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color);--tw-ring-shadow:var(--tw-ring-inset) 0 0 0 calc(1px + var(--tw-ring-offset-width)) var(--tw-ring-color);box-shadow:var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow,0 0 #0000);--tw-ring-inset:inset;--tw-ring-color:var(--cp-drop-zone-ring,var(--stroke-accent-primary,#124ace))}._trigger_dr0k7_28._triggerActive_dr0k7_28{background:var(--cp-trigger-bg,var(--controls-bg-accent-primary-alpha-active,#7da4ff5c))}._trigger_dr0k7_28._triggerActive_dr0k7_28 ._triggerIcon_dr0k7_31{color:var(--cp-trigger-icon,var(--text-accent-primary,#124ace))}._triggerIcon_dr0k7_31{color:var(--cp-trigger-icon-idle,var(--text-secondary,#575f73))}
1
+ ._tab_1mi6x_1{color:var(--text-tertiary,#808898);background-color:#0000;border-color:#0000!important}._tab_1mi6x_1:hover{color:var(--text-secondary,#64748b);background-color:#5c8dea0f}._tab_1mi6x_1>span{text-align:center}._tab_1mi6x_1._tabActive_1mi6x_13{color:var(--text-secondary,#64748b);background-color:#2764d912}._tab_1mi6x_1._tabActive_1mi6x_13:hover{background-color:#5c8dea0f}.dial-primary-solid-button{background-image:linear-gradient(135deg, var(--bg-accent-secondary,#37babc) 0%, var(--bg-accent-primary,#5c8dea) 30%, var(--bg-accent-tertiary,#a972ff) 100%);border-style:none;border-radius:9999px;transition:box-shadow .2s,transform .15s;box-shadow:0 0 16px #37babc40,0 4px 12px #a972ff38;background-color:#0000!important;padding-inline:24px!important}@media (hover:hover){.dial-primary-solid-button:hover{background-color:#0000;background-image:linear-gradient(135deg, var(--bg-accent-secondary,#37babc) 0%, var(--bg-accent-primary,#5c8dea) 30%, var(--bg-accent-tertiary,#a972ff) 100%);transform:translateY(-1px);box-shadow:0 0 24px #37babc59,0 6px 18px #a972ff4d}}.dial-primary-solid-button:active{background-color:#0000;background-image:linear-gradient(135deg, var(--bg-accent-secondary,#37babc) 0%, var(--bg-accent-primary,#5c8dea) 30%, var(--bg-accent-tertiary,#a972ff) 100%);filter:brightness(.92);transform:translateY(0);box-shadow:0 0 10px #37babc33,0 2px 6px #a972ff29}.dial-primary-solid-button:disabled{box-shadow:none;cursor:not-allowed;background-image:none;transform:none;background-color:var(--controls-bg-disable,#d1dbea)!important;color:var(--text-white,#fff)!important}.dial-danger-solid-button{border-radius:9999px!important}.dial-primary-solid-button.dial-primary-solid-button{background-color:#0000;background-image:linear-gradient(135deg,#4b7be6 0%,#9355f4 100%);border:none;border-radius:9999px;transition:box-shadow .2s,transform .15s;box-shadow:0 4px 16px #5c8dea52}@media (hover:hover){.dial-primary-solid-button.dial-primary-solid-button:hover{background-color:#0000;background-image:linear-gradient(135deg,#4b7be6 0%,#9355f4 100%);transform:translateY(-1px);box-shadow:0 6px 20px #5c8dea6b}}.dial-primary-solid-button.dial-primary-solid-button:active{filter:brightness(.92);background-color:#0000;background-image:linear-gradient(135deg,#4b7be6 0%,#9355f4 100%);transform:translateY(0);box-shadow:0 2px 8px #5c8dea38}.dial-primary-solid-button.dial-primary-solid-button:disabled{box-shadow:none;background-image:none;transform:none}.dial-neutral-outlined-button{transition:background-color .15s,border-color .15s;color:var(--bg-accent-primary,#2764d9)!important;background-color:#2764d914!important;background-image:none!important;border:1px solid #2764d933!important;border-radius:9999px!important}@media (hover:hover){.dial-neutral-outlined-button:hover:enabled{background-color:#2764d921!important;border-color:#2764d959!important}}.dial-neutral-outlined-button:active:enabled{background-color:#2764d92e!important;border-color:#2764d973!important}.dial-neutral-outlined-button:disabled{border-color:var(--stroke-secondary,#d1dbea);color:var(--controls-text-neutral-disable,#575f73);background-color:#0000;background-image:none}.dial-primary-ghost-button:not(.dial-icon-button){border-style:none;border-radius:9999px;color:var(--bg-accent-primary,#2764d9)!important}@media (hover:hover){.dial-primary-ghost-button:not(.dial-icon-button):hover:enabled{background-color:#2764d90d!important}}.dial-primary-ghost-button:not(.dial-icon-button):active:enabled{background-color:#2764d914!important}.dial-icon-button{border-radius:6px!important}.dial-input:not(.dial-input-error){transition:border-color .15s,box-shadow .15s;border-color:var(--stroke-tertiary,#e0e6f0)!important;border-radius:.75rem!important}.dial-input:not(.dial-input-error):not(:disabled):hover{border-color:var(--stroke-accent-primary,#7da4ff)!important}.dial-input:not(.dial-input-error):not(:disabled):active,.dial-input:not(.dial-input-error):not(:disabled):focus,.dial-input:not(.dial-input-error):not(:disabled):focus-within{border-color:var(--stroke-accent-primary,#124ace)!important;box-shadow:0 0 0 4px var(--bg-accent-primary-alpha,#7da4ff2e)!important}.dial-input-error{border-radius:.75rem!important}._button_1ggx8_1{background:var(--cp-new-chat-bg,var(--bg-layer-0,#fcfcfc));box-shadow:0 1px 3px var(--cp-new-chat-shadow-blue,var(--bg-new-chat-shadow-blue,#5c8dea33)), 0 2px 10px var(--cp-new-chat-shadow-purple,var(--bg-new-chat-shadow-purple,#a972ff24));color:var(--cp-new-chat-text,var(--text-accent-primary,#124ace));transition:box-shadow .15s,background-color .15s}._button_1ggx8_1:hover{background:var(--cp-new-chat-hover,var(--bg-layer-0,#fcfcfc));box-shadow:0 2px 6px var(--cp-new-chat-shadow-blue-hover,var(--bg-new-chat-shadow-blue-hover,#5c8dea47)), 0 4px 16px var(--cp-new-chat-shadow-purple-hover,var(--bg-new-chat-shadow-purple-hover,#a972ff33))}._button_1ggx8_1:active{background:var(--cp-new-chat-active,var(--bg-layer-5,#f5f7fa));box-shadow:0 1px 2px var(--cp-new-chat-shadow-blue-active,var(--bg-new-chat-shadow-blue-active,#5c8dea26)), 0 1px 6px var(--cp-new-chat-shadow-purple-active,var(--bg-new-chat-shadow-purple-active,#a972ff1a))}._header_1nqh6_1,._item_1nqh6_5{color:var(--cp-text,var(--text-primary,#161b2d))}._item_1nqh6_5:hover{background:var(--cp-item-hover,var(--bg-layer-2,#eef1f7))}._item_1nqh6_5._itemActive_1nqh6_11{background:var(--cp-item-active,var(--bg-layer-2,#eef1f7));color:var(--cp-text,var(--text-primary,#161b2d))}._groupHeader_1nqh6_16{color:var(--cp-text-secondary,var(--text-tertiary,#808898));opacity:.55}._dropZoneActive_1nqh6_21{--tw-ring-offset-shadow:var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color);--tw-ring-shadow:var(--tw-ring-inset) 0 0 0 calc(1px + var(--tw-ring-offset-width)) var(--tw-ring-color);box-shadow:var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow,0 0 #0000);--tw-ring-inset:inset;--tw-ring-color:var(--cp-drop-zone-ring,var(--stroke-accent-primary,#124ace))}._trigger_1nqh6_29._triggerActive_1nqh6_29{background:var(--cp-trigger-bg,var(--controls-bg-accent-primary-alpha-active,#7da4ff5c))}._trigger_1nqh6_29._triggerActive_1nqh6_29 ._triggerIcon_1nqh6_32{color:var(--cp-trigger-icon,var(--text-accent-primary,#124ace))}._triggerIcon_1nqh6_32{color:var(--cp-trigger-icon-idle,var(--text-secondary,#575f73))}
2
2
  /*$vite$:1*/
package/index.js CHANGED
@@ -1,12 +1,12 @@
1
1
  import { DeploymentIcon as e, Highlight as t, buildCssVars as n, mergeClasses as r } from "@epam/ai-dial-chat-shared";
2
2
  import { PanelEmpty as i, PanelNoResults as a, SearchInput as o, SidebarOrientation as s, SidebarPanel as c } from "@epam/ai-dial-sidebar";
3
- import { ButtonAppearance as l, DIAL_ICON_SIZE as u, DialButton as d, DialDropdown as f, DialEllipsisTooltip as p, DialIconButton as m, DialSkeleton as h, DialSkeletonVariant as g, DialTag as _, ElementSize as v } from "@epam/ai-dial-ui-kit";
4
- import { createElement as y, memo as b, useCallback as x, useEffect as S, useId as C, useImperativeHandle as w, useLayoutEffect as T, useMemo as E, useRef as D, useState as O } from "react";
5
- import { jsx as k, jsxs as A } from "react/jsx-runtime";
6
- import { IconCaretDownFilled as j, IconCaretRightFilled as M, IconDotsVertical as N, IconPlus as P } from "@tabler/icons-react";
3
+ import { ButtonAppearance as l, DIAL_ICON_SIZE as u, DialButton as d, DialDropdown as f, DialEllipsisTooltip as p, DialIconButton as m, DialSkeleton as h, DialSkeletonVariant as g, DialTag as _, ElementSize as v, mergeClasses as y } from "@epam/ai-dial-ui-kit";
4
+ import { createElement as b, memo as x, useCallback as S, useEffect as C, useId as w, useImperativeHandle as T, useLayoutEffect as E, useMemo as D, useRef as O, useState as k } from "react";
5
+ import { jsx as A, jsxs as j } from "react/jsx-runtime";
6
+ import { IconCaretDownFilled as M, IconCaretRightFilled as N, IconDotsVertical as P, IconPlus as F } from "@tabler/icons-react";
7
7
  //#region ../../node_modules/react-window/dist/react-window.js
8
- var F = typeof window < "u" ? T : S;
9
- function I(e) {
8
+ var I = typeof window < "u" ? E : C;
9
+ function L(e) {
10
10
  if (e !== void 0) switch (typeof e) {
11
11
  case "number": return e;
12
12
  case "string":
@@ -14,15 +14,15 @@ function I(e) {
14
14
  break;
15
15
  }
16
16
  }
17
- function ee({ box: e, defaultHeight: t, defaultWidth: n, disabled: r, element: i, mode: a, style: o }) {
18
- let { styleHeight: s, styleWidth: c } = E(() => ({
19
- styleHeight: I(o?.height),
20
- styleWidth: I(o?.width)
21
- }), [o?.height, o?.width]), [l, u] = O({
17
+ function R({ box: e, defaultHeight: t, defaultWidth: n, disabled: r, element: i, mode: a, style: o }) {
18
+ let { styleHeight: s, styleWidth: c } = D(() => ({
19
+ styleHeight: L(o?.height),
20
+ styleWidth: L(o?.width)
21
+ }), [o?.height, o?.width]), [l, u] = k({
22
22
  height: t,
23
23
  width: n
24
24
  }), d = r || a === "only-height" && s !== void 0 || a === "only-width" && c !== void 0 || s !== void 0 && c !== void 0;
25
- return F(() => {
25
+ return I(() => {
26
26
  if (i === null || d) return;
27
27
  let t = new ResizeObserver((e) => {
28
28
  for (let t of e) {
@@ -42,7 +42,7 @@ function ee({ box: e, defaultHeight: t, defaultWidth: n, disabled: r, element: i
42
42
  i,
43
43
  s,
44
44
  c
45
- ]), E(() => ({
45
+ ]), D(() => ({
46
46
  height: s ?? l.height,
47
47
  width: c ?? l.width
48
48
  }), [
@@ -51,26 +51,26 @@ function ee({ box: e, defaultHeight: t, defaultWidth: n, disabled: r, element: i
51
51
  c
52
52
  ]);
53
53
  }
54
- function L(e) {
55
- let t = D(() => {
54
+ function ee(e) {
55
+ let t = O(() => {
56
56
  throw Error("Cannot call during render.");
57
57
  });
58
- return F(() => {
58
+ return I(() => {
59
59
  t.current = e;
60
- }, [e]), x((e) => t.current?.(e), [t]);
60
+ }, [e]), S((e) => t.current?.(e), [t]);
61
61
  }
62
- var R = null;
63
- function z(e = !1) {
64
- if (R === null || e) {
62
+ var z = null;
63
+ function te(e = !1) {
64
+ if (z === null || e) {
65
65
  let e = document.createElement("div"), t = e.style;
66
66
  t.width = "50px", t.height = "50px", t.overflow = "scroll", t.direction = "rtl";
67
67
  let n = document.createElement("div"), r = n.style;
68
- return r.width = "100px", r.height = "100px", e.appendChild(n), document.body.appendChild(e), e.scrollLeft > 0 ? R = "positive-descending" : (e.scrollLeft = 1, R = e.scrollLeft === 0 ? "negative" : "positive-ascending"), document.body.removeChild(e), R;
68
+ return r.width = "100px", r.height = "100px", e.appendChild(n), document.body.appendChild(e), e.scrollLeft > 0 ? z = "positive-descending" : (e.scrollLeft = 1, z = e.scrollLeft === 0 ? "negative" : "positive-ascending"), document.body.removeChild(e), z;
69
69
  }
70
- return R;
70
+ return z;
71
71
  }
72
72
  function B({ containerElement: e, direction: t, isRtl: n, scrollOffset: r }) {
73
- if (t === "horizontal" && n) switch (z()) {
73
+ if (t === "horizontal" && n) switch (te()) {
74
74
  case "negative": return -r;
75
75
  case "positive-descending":
76
76
  if (e) {
@@ -98,7 +98,7 @@ function U({ cachedBounds: e, itemCount: t, itemSize: n }) {
98
98
  return V(n !== void 0, "Unexpected bounds cache miss"), t * ((n.scrollOffset + n.size) / e.size);
99
99
  }
100
100
  }
101
- function W({ align: e, cachedBounds: t, index: n, itemCount: r, itemSize: i, containerScrollOffset: a, containerSize: o }) {
101
+ function ne({ align: e, cachedBounds: t, index: n, itemCount: r, itemSize: i, containerScrollOffset: a, containerSize: o }) {
102
102
  if (n < 0 || n >= r) throw RangeError(`Invalid index specified: ${n}`, { cause: `Index ${n} is not within the range of 0 - ${r - 1}` });
103
103
  let s = U({
104
104
  cachedBounds: t,
@@ -112,7 +112,7 @@ function W({ align: e, cachedBounds: t, index: n, itemCount: r, itemSize: i, con
112
112
  default: return a >= u && a <= l ? a : a < u ? u : l;
113
113
  }
114
114
  }
115
- function G({ cachedBounds: e, containerScrollOffset: t, containerSize: n, itemCount: r, overscanCount: i }) {
115
+ function W({ cachedBounds: e, containerScrollOffset: t, containerSize: n, itemCount: r, overscanCount: i }) {
116
116
  let a = r - 1, o = 0, s = -1, c = 0, l = -1, u = 0;
117
117
  for (; u < a;) {
118
118
  let n = e.get(u);
@@ -131,7 +131,7 @@ function G({ cachedBounds: e, containerScrollOffset: t, containerSize: n, itemCo
131
131
  stopIndexOverscan: l
132
132
  };
133
133
  }
134
- function K({ itemCount: e, itemProps: t, itemSize: n }) {
134
+ function G({ itemCount: e, itemProps: t, itemSize: n }) {
135
135
  let r = /* @__PURE__ */ new Map();
136
136
  return {
137
137
  get(i) {
@@ -168,8 +168,8 @@ function K({ itemCount: e, itemProps: t, itemSize: n }) {
168
168
  }
169
169
  };
170
170
  }
171
- function q({ itemCount: e, itemProps: t, itemSize: n }) {
172
- return E(() => K({
171
+ function K({ itemCount: e, itemProps: t, itemSize: n }) {
172
+ return D(() => G({
173
173
  itemCount: e,
174
174
  itemProps: t,
175
175
  itemSize: n
@@ -179,7 +179,7 @@ function q({ itemCount: e, itemProps: t, itemSize: n }) {
179
179
  n
180
180
  ]);
181
181
  }
182
- function J({ containerSize: e, itemSize: t }) {
182
+ function re({ containerSize: e, itemSize: t }) {
183
183
  let n;
184
184
  switch (typeof t) {
185
185
  case "string":
@@ -191,21 +191,21 @@ function J({ containerSize: e, itemSize: t }) {
191
191
  }
192
192
  return n;
193
193
  }
194
- function te({ containerElement: e, containerStyle: t, defaultContainerSize: n = 0, direction: r, isRtl: i = !1, itemCount: a, itemProps: o, itemSize: s, onResize: c, overscanCount: l }) {
195
- let { height: u = n, width: d = n } = ee({
194
+ function ie({ containerElement: e, containerStyle: t, defaultContainerSize: n = 0, direction: r, isRtl: i = !1, itemCount: a, itemProps: o, itemSize: s, onResize: c, overscanCount: l }) {
195
+ let { height: u = n, width: d = n } = R({
196
196
  defaultHeight: r === "vertical" ? n : void 0,
197
197
  defaultWidth: r === "horizontal" ? n : void 0,
198
198
  element: e,
199
199
  mode: r === "vertical" ? "only-height" : "only-width",
200
200
  style: t
201
- }), f = D({
201
+ }), f = O({
202
202
  height: 0,
203
203
  width: 0
204
- }), p = r === "vertical" ? u : d, m = J({
204
+ }), p = r === "vertical" ? u : d, m = re({
205
205
  containerSize: p,
206
206
  itemSize: s
207
207
  });
208
- T(() => {
208
+ E(() => {
209
209
  if (typeof c == "function") {
210
210
  let e = f.current;
211
211
  (e.height !== u || e.width !== d) && (c({
@@ -218,22 +218,22 @@ function te({ containerElement: e, containerStyle: t, defaultContainerSize: n =
218
218
  c,
219
219
  d
220
220
  ]);
221
- let h = q({
221
+ let h = K({
222
222
  itemCount: a,
223
223
  itemProps: o,
224
224
  itemSize: m
225
- }), g = x((e) => h.get(e), [h]), [_, v] = O(() => G({
225
+ }), g = S((e) => h.get(e), [h]), [_, v] = k(() => W({
226
226
  cachedBounds: h,
227
227
  containerScrollOffset: 0,
228
228
  containerSize: p,
229
229
  itemCount: a,
230
230
  overscanCount: l
231
- })), { startIndexVisible: y, startIndexOverscan: b, stopIndexVisible: S, stopIndexOverscan: C } = {
231
+ })), { startIndexVisible: y, startIndexOverscan: b, stopIndexVisible: x, stopIndexOverscan: C } = {
232
232
  startIndexVisible: Math.min(a - 1, _.startIndexVisible),
233
233
  startIndexOverscan: Math.min(a - 1, _.startIndexOverscan),
234
234
  stopIndexVisible: Math.min(a - 1, _.stopIndexVisible),
235
235
  stopIndexOverscan: Math.min(a - 1, _.stopIndexOverscan)
236
- }, w = x(() => U({
236
+ }, w = S(() => U({
237
237
  cachedBounds: h,
238
238
  itemCount: a,
239
239
  itemSize: m
@@ -241,7 +241,7 @@ function te({ containerElement: e, containerStyle: t, defaultContainerSize: n =
241
241
  h,
242
242
  a,
243
243
  m
244
- ]), E = x((t) => G({
244
+ ]), T = S((t) => W({
245
245
  cachedBounds: h,
246
246
  containerScrollOffset: B({
247
247
  containerElement: e,
@@ -261,17 +261,17 @@ function te({ containerElement: e, containerStyle: t, defaultContainerSize: n =
261
261
  a,
262
262
  l
263
263
  ]);
264
- return F(() => {
265
- v(E((r === "vertical" ? e?.scrollTop : e?.scrollLeft) ?? 0));
264
+ return I(() => {
265
+ v(T((r === "vertical" ? e?.scrollTop : e?.scrollLeft) ?? 0));
266
266
  }, [
267
267
  e,
268
268
  r,
269
- E
270
- ]), F(() => {
269
+ T
270
+ ]), I(() => {
271
271
  if (!e) return;
272
272
  let t = () => {
273
273
  v((t) => {
274
- let { scrollLeft: n, scrollTop: o } = e, s = G({
274
+ let { scrollLeft: n, scrollTop: o } = e, s = W({
275
275
  cachedBounds: h,
276
276
  containerScrollOffset: B({
277
277
  containerElement: e,
@@ -299,8 +299,8 @@ function te({ containerElement: e, containerStyle: t, defaultContainerSize: n =
299
299
  ]), {
300
300
  getCellBounds: g,
301
301
  getEstimatedSize: w,
302
- scrollToIndex: L(({ align: t = "auto", containerScrollOffset: n, index: o }) => {
303
- let s = W({
302
+ scrollToIndex: ee(({ align: t = "auto", containerScrollOffset: n, index: o }) => {
303
+ let s = ne({
304
304
  align: t,
305
305
  cachedBounds: h,
306
306
  containerScrollOffset: n,
@@ -316,7 +316,7 @@ function te({ containerElement: e, containerStyle: t, defaultContainerSize: n =
316
316
  isRtl: i,
317
317
  scrollOffset: s
318
318
  }), typeof e.scrollTo != "function") {
319
- let e = E(s);
319
+ let e = T(s);
320
320
  H(_, e) || v(e);
321
321
  }
322
322
  return s;
@@ -325,38 +325,38 @@ function te({ containerElement: e, containerStyle: t, defaultContainerSize: n =
325
325
  startIndexOverscan: b,
326
326
  startIndexVisible: y,
327
327
  stopIndexOverscan: C,
328
- stopIndexVisible: S
328
+ stopIndexVisible: x
329
329
  };
330
330
  }
331
- function ne(e) {
332
- return E(() => e, Object.values(e));
331
+ function ae(e) {
332
+ return D(() => e, Object.values(e));
333
333
  }
334
- function re(e, t) {
334
+ function oe(e, t) {
335
335
  let { ariaAttributes: n, style: r, ...i } = e, { ariaAttributes: a, style: o, ...s } = t;
336
336
  return H(n, a) && H(r, o) && H(i, s);
337
337
  }
338
- function ie(e) {
338
+ function se(e) {
339
339
  return typeof e == "object" && !!e && "getAverageRowHeight" in e && typeof e.getAverageRowHeight == "function";
340
340
  }
341
- var ae = "data-react-window-index";
342
- function oe({ children: e, className: t, defaultHeight: n = 0, listRef: r, onResize: i, onRowsRendered: a, overscanCount: o = 3, rowComponent: s, rowCount: c, rowHeight: l, rowProps: u, tagName: d = "div", style: f, ...p }) {
343
- let m = ne(u), h = E(() => b(s, re), [s]), [g, _] = O(null), v = ie(l), { getCellBounds: x, getEstimatedSize: C, scrollToIndex: T, startIndexOverscan: D, startIndexVisible: A, stopIndexOverscan: j, stopIndexVisible: M } = te({
341
+ var ce = "data-react-window-index";
342
+ function le({ children: e, className: t, defaultHeight: n = 0, listRef: r, onResize: i, onRowsRendered: a, overscanCount: o = 3, rowComponent: s, rowCount: c, rowHeight: l, rowProps: u, tagName: d = "div", style: f, ...p }) {
343
+ let m = ae(u), h = D(() => x(s, oe), [s]), [g, _] = k(null), v = se(l), { getCellBounds: y, getEstimatedSize: S, scrollToIndex: w, startIndexOverscan: E, startIndexVisible: O, stopIndexOverscan: j, stopIndexVisible: M } = ie({
344
344
  containerElement: g,
345
345
  containerStyle: f,
346
346
  defaultContainerSize: n,
347
347
  direction: "vertical",
348
348
  itemCount: c,
349
349
  itemProps: m,
350
- itemSize: E(() => v ? (e) => l.getRowHeight(e) ?? l.getAverageRowHeight() : l, [v, l]),
350
+ itemSize: D(() => v ? (e) => l.getRowHeight(e) ?? l.getAverageRowHeight() : l, [v, l]),
351
351
  onResize: i,
352
352
  overscanCount: o
353
353
  });
354
- w(r, () => ({
354
+ T(r, () => ({
355
355
  get element() {
356
356
  return g;
357
357
  },
358
358
  scrollToRow({ align: e = "auto", behavior: t = "auto", index: n }) {
359
- let r = T({
359
+ let r = w({
360
360
  align: e,
361
361
  containerScrollOffset: g?.scrollTop ?? 0,
362
362
  index: n
@@ -366,40 +366,40 @@ function oe({ children: e, className: t, defaultHeight: n = 0, listRef: r, onRes
366
366
  top: r
367
367
  });
368
368
  }
369
- }), [g, T]), F(() => {
369
+ }), [g, w]), I(() => {
370
370
  if (!g) return;
371
371
  let e = Array.from(g.children).filter((e, t) => {
372
372
  if (e.hasAttribute("aria-hidden")) return !1;
373
- let n = `${D + t}`;
374
- return e.setAttribute(ae, n), !0;
373
+ let n = `${E + t}`;
374
+ return e.setAttribute(ce, n), !0;
375
375
  });
376
376
  if (v) return l.observeRowElements(e);
377
377
  }, [
378
378
  g,
379
379
  v,
380
380
  l,
381
- D,
381
+ E,
382
382
  j
383
- ]), S(() => {
384
- D >= 0 && j >= 0 && a && a({
385
- startIndex: A,
383
+ ]), C(() => {
384
+ E >= 0 && j >= 0 && a && a({
385
+ startIndex: O,
386
386
  stopIndex: M
387
387
  }, {
388
- startIndex: D,
388
+ startIndex: E,
389
389
  stopIndex: j
390
390
  });
391
391
  }, [
392
392
  a,
393
- D,
394
- A,
393
+ E,
394
+ O,
395
395
  j,
396
396
  M
397
397
  ]);
398
- let N = E(() => {
398
+ let N = D(() => {
399
399
  let e = [];
400
- if (c > 0) for (let t = D; t <= j; t++) {
401
- let n = x(t);
402
- e.push(/* @__PURE__ */ y(h, {
400
+ if (c > 0) for (let t = E; t <= j; t++) {
401
+ let n = y(t);
402
+ e.push(/* @__PURE__ */ b(h, {
403
403
  ...m,
404
404
  ariaAttributes: {
405
405
  "aria-posinset": t + 1,
@@ -420,21 +420,21 @@ function oe({ children: e, className: t, defaultHeight: n = 0, listRef: r, onRes
420
420
  return e;
421
421
  }, [
422
422
  h,
423
- x,
423
+ y,
424
424
  v,
425
425
  c,
426
426
  m,
427
- D,
427
+ E,
428
428
  j
429
- ]), P = /* @__PURE__ */ k("div", {
429
+ ]), P = /* @__PURE__ */ A("div", {
430
430
  "aria-hidden": !0,
431
431
  style: {
432
- height: C(),
432
+ height: S(),
433
433
  width: "100%",
434
434
  zIndex: -1
435
435
  }
436
436
  });
437
- return y(d, {
437
+ return b(d, {
438
438
  role: "list",
439
439
  ...p,
440
440
  className: t,
@@ -450,152 +450,152 @@ function oe({ children: e, className: t, defaultHeight: n = 0, listRef: r, onRes
450
450
  }
451
451
  //#endregion
452
452
  //#region src/types/virtual-row.ts
453
- var Y = /* @__PURE__ */ function(e) {
453
+ var q = /* @__PURE__ */ function(e) {
454
454
  return e.Header = "header", e.Item = "item", e;
455
- }({}), X = /* @__PURE__ */ function(e) {
455
+ }({}), J = /* @__PURE__ */ function(e) {
456
456
  return e.All = "all", e.Pinned = "pinned", e.MyChats = "my-chats", e.Shared = "shared", e.Organization = "organization", e;
457
- }({}), se = (e) => `${60 + e * 23 % 35}%`, ce = (e, t) => e ? t ? "pe-9" : "pe-2 group-hover/conversation:pe-9" : "pe-3", le = (e, t) => t.rows[e].kind === Y.Item ? 36 : e === 0 ? 24 : 56, ue = (e) => {
457
+ }({}), ue = (e) => `${60 + e * 23 % 35}%`, de = (e, t) => e ? t ? "pe-9" : "pe-2 group-hover/conversation:pe-9" : "pe-3", fe = (e, t) => t.rows[e].kind === q.Item ? 36 : e === 0 ? 24 : 56, pe = (e) => {
458
458
  switch (e) {
459
- case X.Shared: return X.Shared;
460
- case X.Organization: return X.Organization;
461
- default: return X.MyChats;
459
+ case J.Shared: return J.Shared;
460
+ case J.Organization: return J.Organization;
461
+ default: return J.MyChats;
462
462
  }
463
- }, de = (e, t) => {
463
+ }, me = (e, t) => {
464
464
  let n = null;
465
- for (let r of e) if (r.kind === Y.Header) n = r.groupKey;
465
+ for (let r of e) if (r.kind === q.Header) n = r.groupKey;
466
466
  else if (r.item.id === t) return n;
467
467
  return null;
468
- }, fe = (e, t, n) => {
468
+ }, he = (e, t, n) => {
469
469
  let r = /* @__PURE__ */ new Set();
470
- if (t != null && r.add(t), t === X.Pinned) {
470
+ if (t != null && r.add(t), t === J.Pinned) {
471
471
  let t = n.find((t) => t.id === e);
472
- t && r.add(ue(t.source));
473
- } else r.add(X.Pinned);
472
+ t && r.add(pe(t.source));
473
+ } else r.add(J.Pinned);
474
474
  return r;
475
- }, pe = (e, t, n, r) => {
475
+ }, ge = (e, t, n, r) => {
476
476
  let i = e.currentTarget.getBoundingClientRect();
477
477
  if (e.clientY >= i.top + i.height / 2) return t;
478
478
  let a = null, o = !1;
479
- for (let e of n) if (e.kind === Y.Header) o = e.groupKey === r;
479
+ for (let e of n) if (e.kind === q.Header) o = e.groupKey === r;
480
480
  else if (o) {
481
481
  if (e.item.id === t) return a;
482
482
  a = e.item.id;
483
483
  }
484
484
  return null;
485
- }, me = {
485
+ }, Y = {
486
486
  tab: "_tab_1mi6x_1",
487
487
  tabActive: "_tabActive_1mi6x_13"
488
- }, he = b(({ tabs: e, activeTabId: t, onTabChange: n, tabClassName: i = "dial-tiny-semi-text" }) => /* @__PURE__ */ k("div", {
488
+ }, _e = x(({ tabs: e, activeTabId: t, onTabChange: n, tabClassName: i = "dial-tiny-semi-text" }) => /* @__PURE__ */ A("div", {
489
489
  className: "flex flex-nowrap gap-1",
490
490
  children: e.map((e) => {
491
491
  let a = t === e.id;
492
- return /* @__PURE__ */ k(_, {
492
+ return /* @__PURE__ */ A(_, {
493
493
  label: e.label,
494
494
  selected: a,
495
495
  onClick: () => n(e.id),
496
- className: r("box-border h-auto shrink-0 justify-center rounded-full p-2 text-center", i, me.tab, a && me.tabActive)
496
+ className: r("box-border h-auto shrink-0 justify-center rounded-full p-2 text-center", i, Y.tab, a && Y.tabActive)
497
497
  }, e.id);
498
498
  })
499
- })), ge = [
499
+ })), ve = [
500
500
  {
501
- value: X.All,
501
+ value: J.All,
502
502
  labelKey: "all"
503
503
  },
504
504
  {
505
- value: X.MyChats,
505
+ value: J.MyChats,
506
506
  labelKey: "myChats"
507
507
  },
508
508
  {
509
- value: X.Shared,
509
+ value: J.Shared,
510
510
  labelKey: "shared"
511
511
  },
512
512
  {
513
- value: X.Organization,
513
+ value: J.Organization,
514
514
  labelKey: "organization"
515
515
  }
516
- ], _e = b(({ activeTab: e, labels: t, onChange: n, tabClassName: r = "dial-tiny-semi-text" }) => /* @__PURE__ */ k("div", {
516
+ ], ye = x(({ activeTab: e, labels: t, onChange: n, tabClassName: r = "dial-tiny-semi-text" }) => /* @__PURE__ */ A("div", {
517
517
  className: "mx-3 my-2",
518
- children: /* @__PURE__ */ k(he, {
519
- tabs: ge.map(({ value: e, labelKey: n }) => ({
518
+ children: /* @__PURE__ */ A(_e, {
519
+ tabs: ve.map(({ value: e, labelKey: n }) => ({
520
520
  id: e,
521
521
  label: t[n]
522
522
  })),
523
523
  activeTabId: e,
524
524
  onTabChange: (e) => n(e),
525
- tabClassName: r
525
+ tabClassName: y(r, "flex-1")
526
526
  })
527
- })), ve = { button: "_button_1ggx8_1" }, ye = b(({ label: e, onClick: t, labelClassName: n = "dial-small-semi-text" }) => /* @__PURE__ */ k("div", {
527
+ })), be = { button: "_button_1ggx8_1" }, xe = x(({ label: e, onClick: t, labelClassName: n = "dial-small-semi-text" }) => /* @__PURE__ */ A("div", {
528
528
  className: "px-3 py-2",
529
- children: /* @__PURE__ */ A("button", {
529
+ children: /* @__PURE__ */ j("button", {
530
530
  onClick: t,
531
531
  type: "button",
532
- className: r("flex h-[36px] w-full cursor-pointer items-center justify-center gap-2 rounded-full px-3 py-1", ve.button),
533
- children: [/* @__PURE__ */ k(P, {
532
+ className: r("flex h-[36px] w-full cursor-pointer items-center justify-center gap-2 rounded-full px-3 py-1", be.button),
533
+ children: [/* @__PURE__ */ A(F, {
534
534
  size: 18,
535
535
  stroke: 2,
536
536
  className: "shrink-0"
537
- }), /* @__PURE__ */ k("span", {
537
+ }), /* @__PURE__ */ A("span", {
538
538
  className: n,
539
539
  children: e
540
540
  })]
541
541
  })
542
- })), Z = {
542
+ })), X = {
543
543
  skeletonColor: "var(--cp-skeleton-color, var(--bg-layer-4, #d1dbea))",
544
- header: "_header_dr0k7_1",
545
- item: "_item_dr0k7_5",
546
- itemActive: "_itemActive_dr0k7_11",
547
- groupHeader: "_groupHeader_dr0k7_16",
548
- dropZoneActive: "_dropZoneActive_dr0k7_20",
549
- trigger: "_trigger_dr0k7_28",
550
- triggerActive: "_triggerActive_dr0k7_28",
551
- triggerIcon: "_triggerIcon_dr0k7_31"
552
- }, be = ({ item: n, isActive: i, onSelectConversation: a, searchQuery: o = "", getActions: s, onActionMenuOpen: c, actionsLabel: p = "More actions", itemTitleClassName: _ = "dial-small-text", itemIconBadgeClassName: y, rowGroupKey: b, rows: S, draggingId: C, dragOverId: w, allowedDropGroups: T, onDragStart: E, onDragEnd: j, onDragOver: M, onDragLeave: P, onDrop: F }) => {
553
- let [I, ee] = O(!1), L = D(null), R = x((e) => {
554
- ee(e), e && L.current && c?.(n, L.current);
555
- }, [n, c]), z = s?.(n) ?? [], B = z.length > 0, V = n.isIconLoading ? /* @__PURE__ */ k(h, {
544
+ header: "_header_1nqh6_1",
545
+ item: "_item_1nqh6_5",
546
+ itemActive: "_itemActive_1nqh6_11",
547
+ groupHeader: "_groupHeader_1nqh6_16",
548
+ dropZoneActive: "_dropZoneActive_1nqh6_21",
549
+ trigger: "_trigger_1nqh6_29",
550
+ triggerActive: "_triggerActive_1nqh6_29",
551
+ triggerIcon: "_triggerIcon_1nqh6_32"
552
+ }, Se = ({ item: n, isActive: i, onSelectConversation: a, searchQuery: o = "", getActions: s, onActionMenuOpen: c, actionsLabel: p = "More actions", itemTitleClassName: _ = "dial-small-text", itemIconBadgeClassName: y, rowGroupKey: b, rows: x, draggingId: C, dragOverId: w, allowedDropGroups: T, onDragStart: E, onDragEnd: D, onDragOver: M, onDragLeave: N, onDrop: F }) => {
553
+ let [I, L] = k(!1), R = O(null), ee = S((e) => {
554
+ L(e), e && R.current && c?.(n, R.current);
555
+ }, [n, c]), z = s?.(n) ?? [], te = z.length > 0, B = n.isIconLoading ? /* @__PURE__ */ A(h, {
556
556
  variant: g.Circular,
557
557
  width: u.LG,
558
558
  height: u.LG,
559
- color: Z.skeletonColor,
559
+ color: X.skeletonColor,
560
560
  "aria-hidden": !0
561
- }) : /* @__PURE__ */ k(e, {
561
+ }) : /* @__PURE__ */ A(e, {
562
562
  src: n.iconUrl,
563
563
  size: u.LG,
564
564
  initialsName: n.iconTooltip ?? "",
565
565
  tooltip: n.iconTooltip,
566
566
  badgeClassName: y
567
- }), H = ce(B, I), U = b != null, W = x((e) => {
568
- e.currentTarget.contains(e.relatedTarget) || P?.();
569
- }, [P]), G = x((e) => {
570
- if (!b || !S || !F) return;
567
+ }), V = de(te, I), H = b != null, U = S((e) => {
568
+ e.currentTarget.contains(e.relatedTarget) || N?.();
569
+ }, [N]), ne = S((e) => {
570
+ if (!b || !x || !F) return;
571
571
  e.preventDefault();
572
- let t = pe(e, n.id, S, b);
572
+ let t = ge(e, n.id, x, b);
573
573
  F(n.id, b, t);
574
574
  }, [
575
575
  n.id,
576
- S,
576
+ x,
577
577
  b,
578
578
  F
579
- ]), K = n.id === C, q = n.id === w, J = b != null && (T?.has(b) ?? !1), te = C != null;
580
- return /* @__PURE__ */ A("li", {
581
- className: r("group/conversation relative", K && "cursor-grabbing opacity-50", q && J && "rounded", q && J && Z.dropZoneActive, te && !K && !J && "cursor-not-allowed"),
582
- draggable: U || void 0,
583
- onDragStart: U ? () => E?.(n.id) : void 0,
584
- onDragEnd: U ? j : void 0,
585
- onDragOver: U ? (e) => {
579
+ ]), W = n.id === C, G = n.id === w, K = b != null && (T?.has(b) ?? !1), re = C != null;
580
+ return /* @__PURE__ */ j("li", {
581
+ className: r("group/conversation relative", W && "cursor-grabbing opacity-50", G && K && "rounded", G && K && X.dropZoneActive, re && !W && !K && "cursor-not-allowed"),
582
+ draggable: H || void 0,
583
+ onDragStart: H ? () => E?.(n.id) : void 0,
584
+ onDragEnd: H ? D : void 0,
585
+ onDragOver: H ? (e) => {
586
586
  e.preventDefault(), M?.(n.id);
587
587
  } : void 0,
588
- onDragLeave: U ? W : void 0,
589
- onDrop: U ? G : void 0,
590
- children: [/* @__PURE__ */ k("a", {
588
+ onDragLeave: H ? U : void 0,
589
+ onDrop: H ? ne : void 0,
590
+ children: [/* @__PURE__ */ A("a", {
591
591
  href: n.href,
592
592
  className: "contents",
593
593
  onClick: (e) => {
594
594
  n.href && (e.preventDefault(), a(n.id));
595
595
  },
596
- children: /* @__PURE__ */ k(d, {
597
- iconBefore: V,
598
- label: /* @__PURE__ */ k(t, {
596
+ children: /* @__PURE__ */ A(d, {
597
+ iconBefore: B,
598
+ label: /* @__PURE__ */ A(t, {
599
599
  text: n.title,
600
600
  query: o,
601
601
  className: _,
@@ -605,33 +605,33 @@ var Y = /* @__PURE__ */ function(e) {
605
605
  "aria-current": i ? "page" : void 0,
606
606
  onClick: n.href ? void 0 : () => a(n.id),
607
607
  tabIndex: n.href ? -1 : void 0,
608
- className: r("flex h-8 w-full items-center justify-start gap-2 rounded-xl py-2 ps-3", H, Z.item, i && Z.itemActive, I && Z.itemActive)
608
+ className: r("flex h-8 w-full items-center justify-start gap-2 rounded-xl py-2 ps-3", V, X.item, i && X.itemActive, I && X.itemActive)
609
609
  })
610
- }), B && /* @__PURE__ */ k("div", {
610
+ }), te && /* @__PURE__ */ A("div", {
611
611
  className: r("absolute inset-y-0 end-1 flex items-center", I ? "opacity-100" : "opacity-0 group-focus-within/conversation:opacity-100 group-hover/conversation:opacity-100"),
612
- children: /* @__PURE__ */ k(f, {
612
+ children: /* @__PURE__ */ A(f, {
613
613
  items: z,
614
- onOpenChange: R,
614
+ onOpenChange: ee,
615
615
  matchReferenceWidth: !1,
616
616
  listClassName: "w-[140px] cp-dropdown-overlay",
617
- children: /* @__PURE__ */ k(m, {
618
- ref: L,
619
- icon: /* @__PURE__ */ k(N, {
617
+ children: /* @__PURE__ */ A(m, {
618
+ ref: R,
619
+ icon: /* @__PURE__ */ A(P, {
620
620
  size: u.SM,
621
- className: Z.triggerIcon,
621
+ className: X.triggerIcon,
622
622
  "aria-hidden": !0
623
623
  }),
624
624
  appearance: l.Ghost,
625
625
  size: v.Small,
626
626
  "aria-label": p,
627
- className: r("flex items-center justify-center rounded", Z.trigger, I && Z.triggerActive)
627
+ className: r("flex items-center justify-center rounded", X.trigger, I && X.triggerActive)
628
628
  })
629
629
  })
630
630
  })]
631
631
  });
632
- }, xe = ({ label: e, isExpanded: t, onToggle: n, listId: i, className: a = "dial-tiny-semi-text uppercase", dropZoneGroupKey: o, isDragOver: s, onDragOver: c, onDragLeave: l, onDrop: u }) => {
632
+ }, Ce = ({ label: e, isExpanded: t, onToggle: n, listId: i, className: a = "dial-tiny-semi-text uppercase", dropZoneGroupKey: o, isDragOver: s, onDragOver: c, onDragLeave: l, onDrop: u }) => {
633
633
  let d = o != null;
634
- return /* @__PURE__ */ A("button", {
634
+ return /* @__PURE__ */ j("button", {
635
635
  type: "button",
636
636
  "aria-expanded": t,
637
637
  "aria-controls": i,
@@ -645,46 +645,46 @@ var Y = /* @__PURE__ */ function(e) {
645
645
  onDrop: d ? (e) => {
646
646
  d && (e.preventDefault(), u?.(o, o, null));
647
647
  } : void 0,
648
- className: r("flex h-6 w-full items-center gap-1 rounded py-1 pe-3 text-start", a, Z.groupHeader, s && Z.dropZoneActive),
649
- children: [t ? /* @__PURE__ */ k(j, {
648
+ className: r("flex h-6 w-full items-center gap-1 rounded py-1 pe-3 text-start", a, X.groupHeader, s && X.dropZoneActive),
649
+ children: [t ? /* @__PURE__ */ A(M, {
650
650
  stroke: .5,
651
651
  size: 12,
652
652
  className: "shrink-0",
653
653
  "aria-hidden": !0
654
- }) : /* @__PURE__ */ k(M, {
654
+ }) : /* @__PURE__ */ A(N, {
655
655
  stroke: .5,
656
656
  size: 12,
657
657
  className: "shrink-0 rtl:scale-x-[-1]",
658
658
  "aria-hidden": !0
659
- }), /* @__PURE__ */ k(p, { text: e })]
659
+ }), /* @__PURE__ */ A(p, { text: e })]
660
660
  });
661
- }, Se = ({ index: e, style: t, rows: n, expandedGroups: r, onToggleGroup: i, listId: a, activeConversationId: o, searchQuery: s, onSelectConversation: c, getActions: l, onActionMenuOpen: u, actionsLabel: d, styles: f, draggingId: p, dragOverId: m, allowedDropGroups: h, onDragStart: g, onDragEnd: _, onDragOver: v, onDragLeave: y, onDrop: b }) => {
661
+ }, we = ({ index: e, style: t, rows: n, expandedGroups: r, onToggleGroup: i, listId: a, activeConversationId: o, searchQuery: s, onSelectConversation: c, getActions: l, onActionMenuOpen: u, actionsLabel: d, styles: f, draggingId: p, dragOverId: m, allowedDropGroups: h, onDragStart: g, onDragEnd: _, onDragOver: v, onDragLeave: y, onDrop: b }) => {
662
662
  let x = n[e];
663
- if (x.kind === Y.Header) {
664
- let n = x.groupKey === X.Pinned;
665
- return /* @__PURE__ */ k("div", {
663
+ if (x.kind === q.Header) {
664
+ let n = x.groupKey === J.Pinned;
665
+ return /* @__PURE__ */ A("div", {
666
666
  role: "presentation",
667
667
  style: t,
668
668
  className: e === 0 ? "pt-0" : "pt-8",
669
- children: /* @__PURE__ */ k(xe, {
669
+ children: /* @__PURE__ */ A(Ce, {
670
670
  label: x.label,
671
671
  isExpanded: r.has(x.groupKey),
672
672
  onToggle: () => i(x.groupKey),
673
673
  listId: a,
674
674
  className: f?.groupHeaderClassName,
675
- dropZoneGroupKey: n ? X.Pinned : void 0,
676
- isDragOver: n && m === X.Pinned,
675
+ dropZoneGroupKey: n ? J.Pinned : void 0,
676
+ isDragOver: n && m === J.Pinned,
677
677
  onDragOver: n ? v : void 0,
678
678
  onDragLeave: n ? y : void 0,
679
679
  onDrop: n ? b : void 0
680
680
  })
681
681
  });
682
682
  }
683
- return /* @__PURE__ */ k("div", {
683
+ return /* @__PURE__ */ A("div", {
684
684
  role: "presentation",
685
685
  style: t,
686
686
  className: "pt-1",
687
- children: /* @__PURE__ */ k(be, {
687
+ children: /* @__PURE__ */ A(Se, {
688
688
  item: x.item,
689
689
  isActive: x.item.id === o,
690
690
  searchQuery: s,
@@ -706,42 +706,42 @@ var Y = /* @__PURE__ */ function(e) {
706
706
  onDrop: b
707
707
  })
708
708
  });
709
- }, Ce = (e, t) => t === X.All ? !0 : e.source === t, we = (e, t) => t ? e.title.toLowerCase().includes(t.toLowerCase()) : !0, Te = new Set([
710
- X.Pinned,
711
- X.MyChats,
712
- X.Shared,
713
- X.Organization
714
- ]), Ee = b(({ conversations: e, isLoading: t, isOpen: l, onSelectConversation: u, activeConversationId: d, labels: f, onNewChat: p, styles: m, className: g, getActions: _, onActionMenuOpen: v, onToggle: y, headerActions: b, onMoveConversation: w, activeFilter: T, onActiveFilterChange: j }) => {
715
- let { colors: M, typography: N } = m ?? {}, { title: P, emptyLabel: F, noResultsLabel: I, loadingLabel: ee = "Loading conversations", newChatLabel: L, searchPlaceholder: R, searchClearLabel: z, filterLabels: B, groupLabels: V, actionsLabel: H, closeAriaLabel: U } = f, [W, G] = O(""), [K, q] = O(X.All);
716
- S(() => {
717
- T != null && (q(T), j?.(T));
709
+ }, Te = (e, t) => t === J.All ? !0 : e.source === t, Ee = (e, t) => t ? e.title.toLowerCase().includes(t.toLowerCase()) : !0, De = new Set([
710
+ J.Pinned,
711
+ J.MyChats,
712
+ J.Shared,
713
+ J.Organization
714
+ ]), Z = x(({ conversations: e, isLoading: t, isOpen: l, onSelectConversation: u, activeConversationId: d, labels: f, onNewChat: p, styles: m, className: g, getActions: _, onActionMenuOpen: v, onToggle: y, headerActions: b, onMoveConversation: x, activeFilter: T, onActiveFilterChange: E }) => {
715
+ let { colors: M, typography: N } = m ?? {}, { title: P, emptyLabel: F, noResultsLabel: I, loadingLabel: L = "Loading conversations", newChatLabel: R, searchPlaceholder: ee, searchClearLabel: z, filterLabels: te, groupLabels: B, actionsLabel: V, closeAriaLabel: H } = f, [U, ne] = k(""), [W, G] = k(J.All);
716
+ C(() => {
717
+ T != null && (G(T), E?.(T));
718
718
  }, [T]);
719
- let [J, te] = O(() => Te), [ne, re] = O(5), ie = C(), ae = D(null), ce = D(null), [ue, pe] = O(null), [me, he] = O(null), [ge, ve] = O(null), Z = D(null), be = D(null), xe = x(({ height: e }) => {
720
- re(Math.ceil(e / 36 * 2));
721
- }, []), Ee = x((e) => {
722
- te((t) => {
719
+ let [K, re] = k(() => De), [ie, ae] = k(5), oe = w(), se = O(null), ce = O(null), [de, pe] = k(null), [ge, Y] = k(null), [_e, ve] = k(null), be = O(null), X = O(null), Se = S(({ height: e }) => {
720
+ ae(Math.ceil(e / 36 * 2));
721
+ }, []), Ce = S((e) => {
722
+ re((t) => {
723
723
  let n = new Set(t);
724
724
  return n.has(e) ? n.delete(e) : n.add(e), n;
725
725
  });
726
- }, []), De = x(() => {
727
- Z.current = null, be.current = null, pe(null), he(null), ve(null);
728
- }, []), Oe = x((t, n) => {
729
- let r = fe(t, de(n, t), e);
730
- Z.current = t, be.current = r, pe(t), ve(r);
731
- }, [e]), ke = x(() => {
732
- De();
733
- }, [De]), Ae = x((e) => {
734
- he(e);
735
- }, []), je = x(() => {
736
- he(null);
737
- }, []), Me = x((e, t, n) => {
738
- let r = Z.current, i = be.current;
739
- De(), r != null && r !== e && i?.has(t) && w?.({
726
+ }, []), Z = S(() => {
727
+ be.current = null, X.current = null, pe(null), Y(null), ve(null);
728
+ }, []), Oe = S((t, n) => {
729
+ let r = he(t, me(n, t), e);
730
+ be.current = t, X.current = r, pe(t), ve(r);
731
+ }, [e]), ke = S(() => {
732
+ Z();
733
+ }, [Z]), Ae = S((e) => {
734
+ Y(e);
735
+ }, []), je = S(() => {
736
+ Y(null);
737
+ }, []), Me = S((e, t, n) => {
738
+ let r = be.current, i = X.current;
739
+ Z(), r != null && r !== e && i?.has(t) && x?.({
740
740
  draggedId: r,
741
741
  targetGroupKey: t,
742
742
  afterId: n
743
743
  });
744
- }, [De, w]), Ne = n({
744
+ }, [Z, x]), Ne = n({
745
745
  "--cp-bg": M?.background,
746
746
  "--sb-border": M?.border,
747
747
  "--cp-item-hover": M?.itemHover,
@@ -763,60 +763,60 @@ var Y = /* @__PURE__ */ function(e) {
763
763
  "--cp-trigger-icon": M?.triggerIcon,
764
764
  "--cp-trigger-icon-idle": M?.triggerIconIdle,
765
765
  "--cp-skeleton-color": M?.skeletonColor
766
- }), Q = E(() => e.filter((e) => Ce(e, K) && we(e, W)), [
766
+ }), Q = D(() => e.filter((e) => Te(e, W) && Ee(e, U)), [
767
767
  e,
768
- K,
769
- W
770
- ]), Pe = E(() => Q.filter((e) => e.isPinned), [Q]), Fe = E(() => Q.filter((e) => !e.isPinned && e.source !== X.Shared && e.source !== X.Organization), [Q]), Ie = E(() => Q.filter((e) => !e.isPinned && e.source === X.Shared), [Q]), Le = E(() => Q.filter((e) => !e.isPinned && e.source === X.Organization), [Q]), Re = E(() => [
768
+ W,
769
+ U
770
+ ]), Pe = D(() => Q.filter((e) => e.isPinned), [Q]), Fe = D(() => Q.filter((e) => !e.isPinned && e.source !== J.Shared && e.source !== J.Organization), [Q]), Ie = D(() => Q.filter((e) => !e.isPinned && e.source === J.Shared), [Q]), Le = D(() => Q.filter((e) => !e.isPinned && e.source === J.Organization), [Q]), Re = D(() => [
771
771
  {
772
- key: X.Pinned,
773
- label: V?.pinned ?? "Pinned",
772
+ key: J.Pinned,
773
+ label: B?.pinned ?? "Pinned",
774
774
  items: Pe
775
775
  },
776
776
  {
777
- key: X.MyChats,
778
- label: V?.myChats ?? "My chats",
777
+ key: J.MyChats,
778
+ label: B?.myChats ?? "My chats",
779
779
  items: Fe
780
780
  },
781
781
  {
782
- key: X.Shared,
783
- label: V?.shared ?? "Shared",
782
+ key: J.Shared,
783
+ label: B?.shared ?? "Shared",
784
784
  items: Ie
785
785
  },
786
786
  {
787
- key: X.Organization,
788
- label: V?.organization ?? "Organization",
787
+ key: J.Organization,
788
+ label: B?.organization ?? "Organization",
789
789
  items: Le
790
790
  }
791
791
  ], [
792
- V,
792
+ B,
793
793
  Pe,
794
794
  Fe,
795
795
  Ie,
796
796
  Le
797
- ]), $ = E(() => {
797
+ ]), $ = D(() => {
798
798
  let e = [];
799
799
  for (let t of Re) if (t.items.length !== 0 && (e.push({
800
- kind: Y.Header,
800
+ kind: q.Header,
801
801
  groupKey: t.key,
802
802
  label: t.label
803
- }), J.has(t.key))) for (let n of t.items) e.push({
804
- kind: Y.Item,
803
+ }), K.has(t.key))) for (let n of t.items) e.push({
804
+ kind: q.Item,
805
805
  item: n,
806
806
  groupKey: t.key
807
807
  });
808
808
  return e;
809
- }, [Re, J]);
810
- S(() => {
809
+ }, [Re, K]);
810
+ C(() => {
811
811
  if (!d) return;
812
812
  let e = Re.find((e) => e.items.some((e) => e.id === d))?.key;
813
- if (e && !J.has(e)) {
814
- te((t) => new Set(t).add(e));
813
+ if (e && !K.has(e)) {
814
+ re((t) => new Set(t).add(e));
815
815
  return;
816
816
  }
817
817
  if (ce.current === d) return;
818
- let t = $.findIndex((e) => e.kind === Y.Item && e.item.id === d);
819
- t >= 0 && (ae.current?.scrollToRow({
818
+ let t = $.findIndex((e) => e.kind === q.Item && e.item.id === d);
819
+ t >= 0 && (se.current?.scrollToRow({
820
820
  index: t,
821
821
  align: "smart",
822
822
  behavior: "smooth"
@@ -824,28 +824,28 @@ var Y = /* @__PURE__ */ function(e) {
824
824
  }, [
825
825
  d,
826
826
  Re,
827
- J,
827
+ K,
828
828
  $
829
829
  ]);
830
- let ze = E(() => ({
830
+ let ze = D(() => ({
831
831
  rows: $,
832
- expandedGroups: J,
833
- onToggleGroup: Ee,
834
- listId: ie,
832
+ expandedGroups: K,
833
+ onToggleGroup: Ce,
834
+ listId: oe,
835
835
  activeConversationId: d,
836
- searchQuery: W,
836
+ searchQuery: U,
837
837
  onSelectConversation: u,
838
838
  getActions: _,
839
839
  onActionMenuOpen: v,
840
- actionsLabel: H,
840
+ actionsLabel: V,
841
841
  styles: {
842
842
  groupHeaderClassName: N?.groupHeaderClassName,
843
843
  itemTitleClassName: N?.itemTitleClassName,
844
844
  itemIconBadgeClassName: m?.itemIconBadgeClassName
845
845
  },
846
- draggingId: ue,
847
- dragOverId: me,
848
- allowedDropGroups: ge,
846
+ draggingId: de,
847
+ dragOverId: ge,
848
+ allowedDropGroups: _e,
849
849
  onDragStart: (e) => Oe(e, $),
850
850
  onDragEnd: ke,
851
851
  onDragOver: Ae,
@@ -853,34 +853,34 @@ var Y = /* @__PURE__ */ function(e) {
853
853
  onDrop: Me
854
854
  }), [
855
855
  $,
856
- J,
857
- Ee,
858
- ie,
856
+ K,
857
+ Ce,
858
+ oe,
859
859
  d,
860
- W,
860
+ U,
861
861
  u,
862
862
  _,
863
863
  v,
864
- H,
864
+ V,
865
865
  N?.groupHeaderClassName,
866
866
  N?.itemTitleClassName,
867
867
  m?.itemIconBadgeClassName,
868
- ue,
869
- me,
868
+ de,
870
869
  ge,
870
+ _e,
871
871
  Oe,
872
872
  ke,
873
873
  Ae,
874
874
  je,
875
875
  Me
876
876
  ]), Be = e.length === 0, Ve = e.length > 0 && Q.length === 0;
877
- return /* @__PURE__ */ A(c, {
877
+ return /* @__PURE__ */ j(c, {
878
878
  isOpen: l,
879
879
  orientation: s.Left,
880
880
  title: P,
881
881
  labels: {
882
882
  ariaLabel: P,
883
- closeLabel: U
883
+ closeLabel: H
884
884
  },
885
885
  onClose: y,
886
886
  styles: {
@@ -897,52 +897,52 @@ var Y = /* @__PURE__ */ function(e) {
897
897
  },
898
898
  rightActions: b,
899
899
  children: [
900
- /* @__PURE__ */ k(ye, {
901
- label: L,
900
+ /* @__PURE__ */ A(xe, {
901
+ label: R,
902
902
  onClick: p,
903
903
  labelClassName: N?.newChatLabelClassName
904
904
  }),
905
- /* @__PURE__ */ k(o, {
906
- placeholder: R,
907
- value: W,
908
- onChange: G,
905
+ /* @__PURE__ */ A(o, {
906
+ placeholder: ee,
907
+ value: U,
908
+ onChange: ne,
909
909
  clearLabel: z
910
910
  }),
911
- /* @__PURE__ */ k(_e, {
912
- activeTab: K,
913
- labels: B,
911
+ /* @__PURE__ */ A(ye, {
912
+ activeTab: W,
913
+ labels: te,
914
914
  onChange: (e) => {
915
- q(e), j?.(e);
915
+ G(e), E?.(e);
916
916
  },
917
917
  tabClassName: N?.tabClassName
918
918
  }),
919
- /* @__PURE__ */ k("span", {
919
+ /* @__PURE__ */ A("span", {
920
920
  role: "status",
921
921
  "aria-live": "polite",
922
922
  className: "sr-only",
923
- children: t ? ee : Be ? F : Ve ? I : ""
923
+ children: t ? L : Be ? F : Ve ? I : ""
924
924
  }),
925
- /* @__PURE__ */ k("div", {
925
+ /* @__PURE__ */ A("div", {
926
926
  className: "flex-1 overflow-hidden px-2 py-1",
927
- children: t ? /* @__PURE__ */ k("div", {
927
+ children: t ? /* @__PURE__ */ A("div", {
928
928
  className: "flex flex-col gap-3 px-2 py-3",
929
- children: Array.from({ length: 15 }, (e, t) => /* @__PURE__ */ k(h, {
929
+ children: Array.from({ length: 15 }, (e, t) => /* @__PURE__ */ A(h, {
930
930
  avatar: { size: 24 },
931
- showTitle: { width: se(t) },
931
+ showTitle: { width: ue(t) },
932
932
  paragraph: !1,
933
933
  active: !0,
934
934
  color: "var(--bg-layer-4)"
935
935
  }, t))
936
- }) : Be ? /* @__PURE__ */ k(i, { label: F }) : Ve ? /* @__PURE__ */ k(a, { label: I }) : /* @__PURE__ */ k(oe, {
937
- listRef: ae,
938
- id: ie,
936
+ }) : Be ? /* @__PURE__ */ A(i, { label: F }) : Ve ? /* @__PURE__ */ A(a, { label: I }) : /* @__PURE__ */ A(le, {
937
+ listRef: se,
938
+ id: oe,
939
939
  role: "list",
940
940
  style: { height: "100%" },
941
- rowComponent: Se,
941
+ rowComponent: we,
942
942
  rowCount: $.length,
943
- rowHeight: le,
944
- overscanCount: ne,
945
- onResize: xe,
943
+ rowHeight: fe,
944
+ overscanCount: ie,
945
+ onResize: Se,
946
946
  rowProps: ze
947
947
  })
948
948
  })
@@ -950,4 +950,4 @@ var Y = /* @__PURE__ */ function(e) {
950
950
  });
951
951
  });
952
952
  //#endregion
953
- export { Ee as ConversationPanel, X as FilterTab };
953
+ export { Z as ConversationPanel, J as FilterTab };
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@epam/ai-dial-conversation-panel",
3
3
  "description": "Virtualized sidebar panel for browsing conversation history with grouping, tabs, and search",
4
- "version": "1.0.0-dev.484",
4
+ "version": "1.0.0-dev.486",
5
5
  "license": "Apache-2.0",
6
6
  "type": "module",
7
7
  "main": "./index.js",
@@ -18,14 +18,14 @@
18
18
  },
19
19
  "dependencies": {
20
20
  "react-window": "^2.2.7",
21
- "@epam/ai-dial-kit": "1.0.0-dev.484"
21
+ "@epam/ai-dial-kit": "1.0.0-dev.486"
22
22
  },
23
23
  "peerDependencies": {
24
24
  "react": "^19.0.0",
25
25
  "@tabler/icons-react": "^3.0.0",
26
- "@epam/ai-dial-chat-shared": "1.0.0-dev.484",
26
+ "@epam/ai-dial-chat-shared": "1.0.0-dev.486",
27
27
  "@epam/ai-dial-ui-kit": "0.12.0-dev.28",
28
- "@epam/ai-dial-sidebar": "1.0.0-dev.484"
28
+ "@epam/ai-dial-sidebar": "1.0.0-dev.486"
29
29
  },
30
30
  "repository": {
31
31
  "type": "git",