@epam/ai-dial-conversation-panel 1.0.0-dev.464 → 1.0.0-dev.469
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.
|
@@ -9,7 +9,10 @@ export interface FilterTabsProps {
|
|
|
9
9
|
labels: FilterLabels;
|
|
10
10
|
/** Called when the user selects a different tab. */
|
|
11
11
|
onChange: (tab: FilterTab) => void;
|
|
12
|
-
/**
|
|
12
|
+
/**
|
|
13
|
+
* Class applied to each tab. Defaults to `'flex-1 dial-tiny-semi-text'` so
|
|
14
|
+
* the tabs fill the row equally, overriding `PillTabs`'s own `shrink-0` default.
|
|
15
|
+
*/
|
|
13
16
|
tabClassName?: string;
|
|
14
17
|
}
|
|
15
18
|
/** Segmented pill-tab control for filtering conversations by source. */
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"FilterTabs.d.ts","sourceRoot":"","sources":["../../../src/components/FilterTabs/FilterTabs.tsx"],"names":[],"mappings":"
|
|
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,wBAAwB,CAAC;AAEnD,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;;;OAGG;IACH,YAAY,CAAC,EAAE,MAAM,CAAC;CACvB;AASD,wEAAwE;AACxE,eAAO,MAAM,UAAU,EAAE,EAAE,CAAC,eAAe,CAmB1C,CAAC"}
|
package/index.css
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
.
|
|
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_1blz1_1{background:var(--cp-new-chat-bg,var(--bg-layer-0,#fff));color:var(--text-accent-primary,#2764d9);border-radius:9999px;transition:box-shadow .15s,background-color .15s;box-shadow:0 1px 3px #5c8dea33,0 2px 10px #a972ff24}._button_1blz1_1:hover{background:var(--cp-new-chat-hover,var(--bg-layer-0,#fff));box-shadow:0 2px 6px #5c8dea47,0 4px 16px #a972ff33}._button_1blz1_1:active{background:var(--cp-new-chat-active,var(--bg-layer-5,#f5f7fa));box-shadow:0 1px 2px #5c8dea26,0 1px 6px #a972ff1a}._header_1o9mn_1,._item_1o9mn_5{color:var(--cp-text,var(--text-primary,#161b2d))}._item_1o9mn_5:hover{background:var(--cp-item-hover,var(--bg-layer-2,#eeeef0))}._item_1o9mn_5._itemActive_1o9mn_11{background:var(--cp-item-active,var(--bg-layer-2,#eeeef0));color:var(--cp-text,var(--text-primary,#161b2d))}._groupHeader_1o9mn_16{color:var(--cp-text-secondary,var(--text-tertiary,#808898));opacity:.55}._trigger_1o9mn_21._triggerActive_1o9mn_21{background:var(--cp-trigger-bg,var(--controls-bg-accent-primary-alpha-active,#7da4ff5c))}._trigger_1o9mn_21._triggerActive_1o9mn_21 ._triggerIcon_1o9mn_24{color:var(--cp-trigger-icon,var(--text-accent-primary,#124ace))}._triggerIcon_1o9mn_24{color:var(--cp-trigger-icon-idle,var(--text-secondary,#575f73))}
|
|
2
2
|
/*$vite$:1*/
|
package/index.js
CHANGED
|
@@ -486,11 +486,21 @@ var K = /* @__PURE__ */ function(e) {
|
|
|
486
486
|
a = e.item.id;
|
|
487
487
|
}
|
|
488
488
|
return null;
|
|
489
|
-
},
|
|
490
|
-
|
|
491
|
-
|
|
492
|
-
|
|
493
|
-
|
|
489
|
+
}, ge = {
|
|
490
|
+
tab: "_tab_1mi6x_1",
|
|
491
|
+
tabActive: "_tabActive_1mi6x_13"
|
|
492
|
+
}, _e = b(({ tabs: e, activeTabId: t, onTabChange: n, tabClassName: i = "dial-tiny-semi-text" }) => /* @__PURE__ */ O("div", {
|
|
493
|
+
className: "flex flex-nowrap gap-1",
|
|
494
|
+
children: e.map((e) => {
|
|
495
|
+
let a = t === e.id;
|
|
496
|
+
return /* @__PURE__ */ O(_, {
|
|
497
|
+
label: e.label,
|
|
498
|
+
selected: a,
|
|
499
|
+
onClick: () => n(e.id),
|
|
500
|
+
className: r("box-border h-auto shrink-0 justify-center rounded-full p-2 text-center", i, ge.tab, a && ge.tabActive)
|
|
501
|
+
}, e.id);
|
|
502
|
+
})
|
|
503
|
+
})), ve = [
|
|
494
504
|
{
|
|
495
505
|
value: Y.All,
|
|
496
506
|
labelKey: "all"
|
|
@@ -507,20 +517,23 @@ var K = /* @__PURE__ */ function(e) {
|
|
|
507
517
|
value: Y.Organization,
|
|
508
518
|
labelKey: "organization"
|
|
509
519
|
}
|
|
510
|
-
],
|
|
511
|
-
className:
|
|
512
|
-
children:
|
|
513
|
-
|
|
514
|
-
|
|
515
|
-
|
|
516
|
-
|
|
517
|
-
|
|
518
|
-
|
|
520
|
+
], ye = b(({ activeTab: e, labels: t, onChange: n, tabClassName: r = "flex-1 dial-tiny-semi-text" }) => /* @__PURE__ */ O("div", {
|
|
521
|
+
className: "mx-3 my-2",
|
|
522
|
+
children: /* @__PURE__ */ O(_e, {
|
|
523
|
+
tabs: ve.map(({ value: e, labelKey: n }) => ({
|
|
524
|
+
id: e,
|
|
525
|
+
label: t[n]
|
|
526
|
+
})),
|
|
527
|
+
activeTabId: e,
|
|
528
|
+
onTabChange: (e) => n(e),
|
|
529
|
+
tabClassName: r
|
|
530
|
+
})
|
|
531
|
+
})), be = { button: "_button_1blz1_1" }, xe = b(({ label: e, onClick: t, labelClassName: n = "dial-small-semi-text" }) => /* @__PURE__ */ O("div", {
|
|
519
532
|
className: "px-3 py-2",
|
|
520
533
|
children: /* @__PURE__ */ k("button", {
|
|
521
534
|
onClick: t,
|
|
522
535
|
type: "button",
|
|
523
|
-
className: r("flex h-[36px] w-full cursor-pointer items-center justify-center gap-2 px-3 py-1",
|
|
536
|
+
className: r("flex h-[36px] w-full cursor-pointer items-center justify-center gap-2 px-3 py-1", be.button),
|
|
524
537
|
children: [/* @__PURE__ */ O(N, {
|
|
525
538
|
size: 18,
|
|
526
539
|
stroke: 2,
|
|
@@ -530,7 +543,7 @@ var K = /* @__PURE__ */ function(e) {
|
|
|
530
543
|
children: e
|
|
531
544
|
})]
|
|
532
545
|
})
|
|
533
|
-
})),
|
|
546
|
+
})), X = {
|
|
534
547
|
header: "_header_1o9mn_1",
|
|
535
548
|
item: "_item_1o9mn_5",
|
|
536
549
|
itemActive: "_itemActive_1o9mn_11",
|
|
@@ -538,7 +551,7 @@ var K = /* @__PURE__ */ function(e) {
|
|
|
538
551
|
trigger: "_trigger_1o9mn_21",
|
|
539
552
|
triggerActive: "_triggerActive_1o9mn_21",
|
|
540
553
|
triggerIcon: "_triggerIcon_1o9mn_24"
|
|
541
|
-
},
|
|
554
|
+
}, Se = ({ item: n, isActive: i, onSelectConversation: a, searchQuery: o = "", getActions: s, actionsLabel: c = "More actions", itemTitleClassName: p = "dial-small-text", itemIconBadgeClassName: _, rowGroupKey: y, rows: b, draggingId: S, dragOverId: C, allowedDropGroups: w, onDragStart: T, onDragEnd: E, onDragOver: A, onDragLeave: j, onDrop: N }) => {
|
|
542
555
|
let [P, F] = D(!1), ee = s?.(n) ?? [], te = ee.length > 0, I = n.isIconLoading ? /* @__PURE__ */ O(h, {
|
|
543
556
|
variant: g.Circular,
|
|
544
557
|
width: u.LG,
|
|
@@ -590,7 +603,7 @@ var K = /* @__PURE__ */ function(e) {
|
|
|
590
603
|
"aria-current": i ? "page" : void 0,
|
|
591
604
|
onClick: () => a(n.id),
|
|
592
605
|
tabIndex: n.href ? -1 : void 0,
|
|
593
|
-
className: r("flex h-8 w-full items-center justify-start gap-2 rounded-xl py-2 ps-3", ne,
|
|
606
|
+
className: r("flex h-8 w-full items-center justify-start gap-2 rounded-xl py-2 ps-3", ne, X.item, i && X.itemActive, P && X.itemActive)
|
|
594
607
|
})
|
|
595
608
|
}), te && /* @__PURE__ */ O("div", {
|
|
596
609
|
className: r("absolute inset-y-0 end-1 flex items-center", P ? "opacity-100" : "opacity-0 group-hover/conversation:opacity-100"),
|
|
@@ -602,17 +615,17 @@ var K = /* @__PURE__ */ function(e) {
|
|
|
602
615
|
children: /* @__PURE__ */ O(m, {
|
|
603
616
|
icon: /* @__PURE__ */ O(M, {
|
|
604
617
|
size: u.SM,
|
|
605
|
-
className:
|
|
618
|
+
className: X.triggerIcon
|
|
606
619
|
}),
|
|
607
620
|
appearance: l.Ghost,
|
|
608
621
|
size: v.Small,
|
|
609
622
|
"aria-label": c,
|
|
610
|
-
className: r("flex items-center justify-center rounded",
|
|
623
|
+
className: r("flex items-center justify-center rounded", X.trigger, P && X.triggerActive)
|
|
611
624
|
})
|
|
612
625
|
})
|
|
613
626
|
})]
|
|
614
627
|
});
|
|
615
|
-
},
|
|
628
|
+
}, Ce = ({ label: e, isExpanded: t, onToggle: n, className: i = "dial-tiny-semi-text uppercase", dropZoneGroupKey: a, isDragOver: o, onDragOver: s, onDragLeave: c, onDrop: l }) => {
|
|
616
629
|
let u = a != null;
|
|
617
630
|
return /* @__PURE__ */ k("button", {
|
|
618
631
|
type: "button",
|
|
@@ -627,21 +640,21 @@ var K = /* @__PURE__ */ function(e) {
|
|
|
627
640
|
onDrop: u ? (e) => {
|
|
628
641
|
u && (e.preventDefault(), l?.(a, a, null));
|
|
629
642
|
} : void 0,
|
|
630
|
-
className: r("flex h-6 w-full items-center gap-1 rounded py-1 pe-3 text-start", i,
|
|
643
|
+
className: r("flex h-6 w-full items-center gap-1 rounded py-1 pe-3 text-start", i, X.groupHeader, o && "ring-accent-secondary ring-1 ring-inset"),
|
|
631
644
|
children: [O(t ? A : j, {
|
|
632
645
|
stroke: .5,
|
|
633
646
|
size: 12,
|
|
634
647
|
className: "shrink-0"
|
|
635
648
|
}), /* @__PURE__ */ O(p, { text: e })]
|
|
636
649
|
});
|
|
637
|
-
},
|
|
650
|
+
}, we = ({ index: e, style: t, rows: n, expandedGroups: r, onToggleGroup: i, activeConversationId: a, searchQuery: o, onSelectConversation: s, getActions: c, actionsLabel: l, groupHeaderClassName: u, itemTitleClassName: d, itemIconBadgeClassName: f, draggingId: p, dragOverId: m, allowedDropGroups: h, onDragStart: g, onDragEnd: _, onDragOver: v, onDragLeave: y, onDrop: b }) => {
|
|
638
651
|
let x = n[e];
|
|
639
652
|
if (x.kind === K.Header) {
|
|
640
653
|
let n = x.groupKey === q.Pinned;
|
|
641
654
|
return /* @__PURE__ */ O("div", {
|
|
642
655
|
style: t,
|
|
643
656
|
className: e === 0 ? "pt-0" : "pt-8",
|
|
644
|
-
children: /* @__PURE__ */ O(
|
|
657
|
+
children: /* @__PURE__ */ O(Ce, {
|
|
645
658
|
label: x.label,
|
|
646
659
|
isExpanded: r.has(x.groupKey),
|
|
647
660
|
onToggle: () => i(x.groupKey),
|
|
@@ -657,7 +670,7 @@ var K = /* @__PURE__ */ function(e) {
|
|
|
657
670
|
return /* @__PURE__ */ O("div", {
|
|
658
671
|
style: t,
|
|
659
672
|
className: "pt-1",
|
|
660
|
-
children: /* @__PURE__ */ O(
|
|
673
|
+
children: /* @__PURE__ */ O(Se, {
|
|
661
674
|
item: x.item,
|
|
662
675
|
isActive: x.item.id === a,
|
|
663
676
|
searchQuery: o,
|
|
@@ -678,37 +691,37 @@ var K = /* @__PURE__ */ function(e) {
|
|
|
678
691
|
onDrop: b
|
|
679
692
|
})
|
|
680
693
|
});
|
|
681
|
-
},
|
|
694
|
+
}, Te = (e, t) => t === Y.All ? !0 : e.source === t, Ee = (e, t) => t ? e.title.toLowerCase().includes(t.toLowerCase()) : !0, De = new Set(Object.values(q)), Oe = b(({ conversations: e, isLoading: t, isOpen: l, onSelectConversation: u, activeConversationId: d, title: f, emptyLabel: p, noResultsLabel: m, onNewChat: g, newChatLabel: _, searchPlaceholder: v, searchClearLabel: y, filterLabels: b, groupLabels: C, styles: w, className: A, getActions: j, actionsLabel: M, onToggle: N, closeAriaLabel: P, resizable: F, defaultPanelWidth: ee = 325, minPanelWidth: te = 312, maxPanelWidth: I = 600, onPanelResizeStop: ne, headerActions: L, onMoveConversation: R, activeFilter: z, onActiveFilterChange: B }) => {
|
|
682
695
|
let { colors: V, typography: H } = w ?? {}, [U, re] = D(""), [W, ie] = D(Y.All);
|
|
683
696
|
S(() => {
|
|
684
697
|
z != null && (ie(z), B?.(z));
|
|
685
698
|
}, [z]);
|
|
686
|
-
let [G, ae] = D(() =>
|
|
699
|
+
let [G, ae] = D(() => De), [oe, se] = D(5), ue = E(null), fe = E(null), [he, ge] = D(null), [_e, ve] = D(null), [be, X] = D(null), Se = E(null), Ce = E(null), Oe = x(({ height: e }) => {
|
|
687
700
|
se(Math.ceil(e / 36 * 2));
|
|
688
|
-
}, []),
|
|
701
|
+
}, []), ke = x((e) => {
|
|
689
702
|
ae((t) => {
|
|
690
703
|
let n = new Set(t);
|
|
691
704
|
return n.has(e) ? n.delete(e) : n.add(e), n;
|
|
692
705
|
});
|
|
693
|
-
}, []),
|
|
694
|
-
|
|
695
|
-
}, []),
|
|
706
|
+
}, []), Ae = x(() => {
|
|
707
|
+
Se.current = null, Ce.current = null, ge(null), ve(null), X(null);
|
|
708
|
+
}, []), je = x((t, n) => {
|
|
696
709
|
let r = me(t, pe(n, t), e);
|
|
697
|
-
|
|
698
|
-
}, [e]),
|
|
699
|
-
|
|
700
|
-
}, [
|
|
710
|
+
Se.current = t, Ce.current = r, ge(t), X(r);
|
|
711
|
+
}, [e]), Me = x(() => {
|
|
712
|
+
Ae();
|
|
713
|
+
}, [Ae]), Ne = x((e) => {
|
|
701
714
|
ve(e);
|
|
702
|
-
}, []),
|
|
715
|
+
}, []), Pe = x(() => {
|
|
703
716
|
ve(null);
|
|
704
|
-
}, []),
|
|
705
|
-
let r =
|
|
706
|
-
|
|
717
|
+
}, []), Fe = x((e, t, n) => {
|
|
718
|
+
let r = Se.current, i = Ce.current;
|
|
719
|
+
Ae(), r != null && r !== e && i?.has(t) && R?.({
|
|
707
720
|
draggedId: r,
|
|
708
721
|
targetGroupKey: t,
|
|
709
722
|
afterId: n
|
|
710
723
|
});
|
|
711
|
-
}, [
|
|
724
|
+
}, [Ae, R]), Ie = n({
|
|
712
725
|
"--cp-bg": V?.background,
|
|
713
726
|
"--sb-border": V?.border,
|
|
714
727
|
"--cp-item-hover": V?.itemHover,
|
|
@@ -718,40 +731,40 @@ var K = /* @__PURE__ */ function(e) {
|
|
|
718
731
|
"--cp-new-chat-hover": V?.newChatHoverBackground,
|
|
719
732
|
"--cp-new-chat-active": V?.newChatActiveBackground,
|
|
720
733
|
"--cp-new-chat-bg": V?.newChatBackground
|
|
721
|
-
}),
|
|
734
|
+
}), Z = T(() => e.filter((e) => Te(e, W) && Ee(e, U)), [
|
|
722
735
|
e,
|
|
723
736
|
W,
|
|
724
737
|
U
|
|
725
|
-
]),
|
|
738
|
+
]), Le = T(() => Z.filter((e) => e.isPinned), [Z]), Re = T(() => Z.filter((e) => !e.isPinned && e.source !== J.Shared && e.source !== J.Organization), [Z]), ze = T(() => Z.filter((e) => !e.isPinned && e.source === J.Shared), [Z]), Be = T(() => Z.filter((e) => !e.isPinned && e.source === J.Organization), [Z]), Q = T(() => [
|
|
726
739
|
{
|
|
727
740
|
key: q.Pinned,
|
|
728
741
|
label: C?.pinned ?? "Pinned",
|
|
729
|
-
items:
|
|
742
|
+
items: Le
|
|
730
743
|
},
|
|
731
744
|
{
|
|
732
745
|
key: q.MyChats,
|
|
733
746
|
label: C?.myChats ?? "My chats",
|
|
734
|
-
items:
|
|
747
|
+
items: Re
|
|
735
748
|
},
|
|
736
749
|
{
|
|
737
750
|
key: q.Shared,
|
|
738
751
|
label: C?.shared ?? "Shared",
|
|
739
|
-
items:
|
|
752
|
+
items: ze
|
|
740
753
|
},
|
|
741
754
|
{
|
|
742
755
|
key: q.Organization,
|
|
743
756
|
label: C?.organization ?? "Organization",
|
|
744
|
-
items:
|
|
757
|
+
items: Be
|
|
745
758
|
}
|
|
746
759
|
], [
|
|
747
760
|
C,
|
|
748
|
-
Ie,
|
|
749
761
|
Le,
|
|
750
762
|
Re,
|
|
751
|
-
ze
|
|
763
|
+
ze,
|
|
764
|
+
Be
|
|
752
765
|
]), $ = T(() => {
|
|
753
766
|
let e = [];
|
|
754
|
-
for (let t of
|
|
767
|
+
for (let t of Q) if (t.items.length !== 0 && (e.push({
|
|
755
768
|
kind: K.Header,
|
|
756
769
|
groupKey: t.key,
|
|
757
770
|
label: t.label
|
|
@@ -761,10 +774,10 @@ var K = /* @__PURE__ */ function(e) {
|
|
|
761
774
|
groupKey: t.key
|
|
762
775
|
});
|
|
763
776
|
return e;
|
|
764
|
-
}, [
|
|
777
|
+
}, [Q, G]);
|
|
765
778
|
S(() => {
|
|
766
779
|
if (!d) return;
|
|
767
|
-
let e =
|
|
780
|
+
let e = Q.find((e) => e.items.some((e) => e.id === d))?.key;
|
|
768
781
|
if (e && !G.has(e)) {
|
|
769
782
|
ae((t) => new Set(t).add(e));
|
|
770
783
|
return;
|
|
@@ -778,14 +791,14 @@ var K = /* @__PURE__ */ function(e) {
|
|
|
778
791
|
}), fe.current = d);
|
|
779
792
|
}, [
|
|
780
793
|
d,
|
|
781
|
-
|
|
794
|
+
Q,
|
|
782
795
|
G,
|
|
783
796
|
$
|
|
784
797
|
]);
|
|
785
798
|
let Ve = T(() => ({
|
|
786
799
|
rows: $,
|
|
787
800
|
expandedGroups: G,
|
|
788
|
-
onToggleGroup:
|
|
801
|
+
onToggleGroup: ke,
|
|
789
802
|
activeConversationId: d,
|
|
790
803
|
searchQuery: U,
|
|
791
804
|
onSelectConversation: u,
|
|
@@ -795,17 +808,17 @@ var K = /* @__PURE__ */ function(e) {
|
|
|
795
808
|
itemTitleClassName: H?.itemTitleClassName,
|
|
796
809
|
itemIconBadgeClassName: H?.itemIconBadgeClassName,
|
|
797
810
|
draggingId: he,
|
|
798
|
-
dragOverId:
|
|
799
|
-
allowedDropGroups:
|
|
800
|
-
onDragStart: (e) =>
|
|
801
|
-
onDragEnd:
|
|
802
|
-
onDragOver:
|
|
803
|
-
onDragLeave:
|
|
804
|
-
onDrop:
|
|
811
|
+
dragOverId: _e,
|
|
812
|
+
allowedDropGroups: be,
|
|
813
|
+
onDragStart: (e) => je(e, $),
|
|
814
|
+
onDragEnd: Me,
|
|
815
|
+
onDragOver: Ne,
|
|
816
|
+
onDragLeave: Pe,
|
|
817
|
+
onDrop: Fe
|
|
805
818
|
}), [
|
|
806
819
|
$,
|
|
807
820
|
G,
|
|
808
|
-
|
|
821
|
+
ke,
|
|
809
822
|
d,
|
|
810
823
|
U,
|
|
811
824
|
u,
|
|
@@ -815,14 +828,14 @@ var K = /* @__PURE__ */ function(e) {
|
|
|
815
828
|
H?.itemTitleClassName,
|
|
816
829
|
H?.itemIconBadgeClassName,
|
|
817
830
|
he,
|
|
818
|
-
|
|
819
|
-
|
|
820
|
-
Ae,
|
|
831
|
+
_e,
|
|
832
|
+
be,
|
|
821
833
|
je,
|
|
822
834
|
Me,
|
|
823
835
|
Ne,
|
|
824
|
-
Pe
|
|
825
|
-
|
|
836
|
+
Pe,
|
|
837
|
+
Fe
|
|
838
|
+
]), He = e.length === 0, Ue = e.length > 0 && Z.length === 0;
|
|
826
839
|
return /* @__PURE__ */ k(c, {
|
|
827
840
|
isOpen: l,
|
|
828
841
|
orientation: s.Left,
|
|
@@ -838,7 +851,7 @@ var K = /* @__PURE__ */ function(e) {
|
|
|
838
851
|
},
|
|
839
852
|
typography: { fontClassName: H?.fontClassName },
|
|
840
853
|
bodyClassName: "flex flex-col overflow-hidden p-0 gap-3",
|
|
841
|
-
cssVars:
|
|
854
|
+
cssVars: Ie,
|
|
842
855
|
titleClassName: H?.fontClassName
|
|
843
856
|
},
|
|
844
857
|
className: r(l ? F ? "border-l border-r mobile:w-full" : "w-[325px] border-l border-r mobile:w-full" : "w-0", A),
|
|
@@ -849,7 +862,7 @@ var K = /* @__PURE__ */ function(e) {
|
|
|
849
862
|
onResizeStop: ne,
|
|
850
863
|
rightActions: L,
|
|
851
864
|
children: [
|
|
852
|
-
/* @__PURE__ */ O(
|
|
865
|
+
/* @__PURE__ */ O(xe, {
|
|
853
866
|
label: _,
|
|
854
867
|
onClick: g,
|
|
855
868
|
labelClassName: H?.newChatLabelClassName
|
|
@@ -860,7 +873,7 @@ var K = /* @__PURE__ */ function(e) {
|
|
|
860
873
|
onChange: re,
|
|
861
874
|
clearLabel: y
|
|
862
875
|
}),
|
|
863
|
-
/* @__PURE__ */ O(
|
|
876
|
+
/* @__PURE__ */ O(ye, {
|
|
864
877
|
activeTab: W,
|
|
865
878
|
labels: b,
|
|
866
879
|
onChange: (e) => {
|
|
@@ -883,11 +896,11 @@ var K = /* @__PURE__ */ function(e) {
|
|
|
883
896
|
listRef: ue,
|
|
884
897
|
role: "list",
|
|
885
898
|
style: { height: "100%" },
|
|
886
|
-
rowComponent:
|
|
899
|
+
rowComponent: we,
|
|
887
900
|
rowCount: $.length,
|
|
888
901
|
rowHeight: de,
|
|
889
902
|
overscanCount: oe,
|
|
890
|
-
onResize:
|
|
903
|
+
onResize: Oe,
|
|
891
904
|
rowProps: Ve
|
|
892
905
|
})
|
|
893
906
|
})
|
|
@@ -895,4 +908,4 @@ var K = /* @__PURE__ */ function(e) {
|
|
|
895
908
|
});
|
|
896
909
|
});
|
|
897
910
|
//#endregion
|
|
898
|
-
export { q as ConversationGroupKey,
|
|
911
|
+
export { q as ConversationGroupKey, Oe as ConversationPanel, J as ConversationSource, Y as FilterTab };
|
package/models/panel-props.d.ts
CHANGED
|
@@ -58,7 +58,7 @@ export interface ConversationHistoryTypography {
|
|
|
58
58
|
itemTitleClassName?: string;
|
|
59
59
|
/** Typography class applied to the New chat button label. Defaults to `'dial-small-text'`. */
|
|
60
60
|
newChatLabelClassName?: string;
|
|
61
|
-
/**
|
|
61
|
+
/** Class applied to each filter tab. Defaults to `'flex-1 dial-tiny-semi-text'`. */
|
|
62
62
|
tabClassName?: string;
|
|
63
63
|
/** Text color class applied to each filter tab label. Defaults to `'text-primary'`. */
|
|
64
64
|
tabColorClassName?: string;
|
|
@@ -1 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AE,CAAC,IAAI,EAAE,uBAAuB,KAAK,YAAY,EAAE,CAAC;IAC/D,yFAAyF;IACzF,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB;;;;OAIG;IACH,QAAQ,CAAC,EAAE,MAAM,IAAI,CAAC;IACtB,iGAAiG;IACjG,cAAc,CAAC,EAAE,MAAM,CAAC;IACxB;;;;OAIG;IACH,SAAS,CAAC,EAAE,OAAO,CAAC;IACpB,gFAAgF;IAChF,iBAAiB,CAAC,EAAE,MAAM,CAAC;IAC3B,gFAAgF;IAChF,aAAa,CAAC,EAAE,MAAM,CAAC;IACvB,gFAAgF;IAChF,aAAa,CAAC,EAAE,MAAM,CAAC;IACvB,4EAA4E;IAC5E,iBAAiB,CAAC,EAAE,CAAC,KAAK,EAAE,MAAM,KAAK,IAAI,CAAC;IAC5C;;;OAGG;IACH,aAAa,CAAC,EAAE,SAAS,CAAC;IAC1B;;;;;;;;;;;OAWG;IACH,kBAAkB,CAAC,EAAE,CAAC,IAAI,EAAE,gBAAgB,KAAK,IAAI,CAAC;IACtD;;;;OAIG;IACH,YAAY,CAAC,EAAE,SAAS,CAAC;IACzB;;;OAGG;IACH,oBAAoB,CAAC,EAAE,CAAC,GAAG,EAAE,SAAS,KAAK,IAAI,CAAC;CACjD;AAED,0EAA0E;AAC1E,MAAM,WAAW,gBAAgB;IAC/B,+CAA+C;IAC/C,SAAS,EAAE,MAAM,CAAC;IAClB,2CAA2C;IAC3C,cAAc,EAAE,oBAAoB,CAAC;IACrC;;;OAGG;IACH,OAAO,EAAE,MAAM,GAAG,IAAI,CAAC;CACxB"}
|
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.
|
|
4
|
+
"version": "1.0.0-dev.469",
|
|
5
5
|
"license": "Apache-2.0",
|
|
6
6
|
"type": "module",
|
|
7
7
|
"main": "./index.js",
|
|
@@ -17,14 +17,15 @@
|
|
|
17
17
|
}
|
|
18
18
|
},
|
|
19
19
|
"dependencies": {
|
|
20
|
-
"react-window": "^2.2.7"
|
|
20
|
+
"react-window": "^2.2.7",
|
|
21
|
+
"@epam/ai-dial-kit": "1.0.0-dev.469"
|
|
21
22
|
},
|
|
22
23
|
"peerDependencies": {
|
|
23
24
|
"react": "^19.0.0",
|
|
24
25
|
"@tabler/icons-react": "^3.0.0",
|
|
25
|
-
"@epam/ai-dial-chat-shared": "1.0.0-dev.
|
|
26
|
-
"@epam/ai-dial-ui-kit": "0.12.0-dev.
|
|
27
|
-
"@epam/ai-dial-sidebar": "1.0.0-dev.
|
|
26
|
+
"@epam/ai-dial-chat-shared": "1.0.0-dev.469",
|
|
27
|
+
"@epam/ai-dial-ui-kit": "0.12.0-dev.28",
|
|
28
|
+
"@epam/ai-dial-sidebar": "1.0.0-dev.469"
|
|
28
29
|
},
|
|
29
30
|
"repository": {
|
|
30
31
|
"type": "git",
|