@docyrus/ui-pro-ai-assistant 0.3.4 → 0.3.5
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
|
@@ -22763,14 +22763,14 @@ var AssistantView = ({ ref, ...props }) => {
|
|
|
22763
22763
|
] })
|
|
22764
22764
|
] }),
|
|
22765
22765
|
/* @__PURE__ */ jsxs("div", { className: "flex-1 flex flex-row min-h-0 overflow-hidden relative", children: [
|
|
22766
|
-
!isSidebarOpen && /* @__PURE__ */ jsxs("div", { className: "absolute top-2 left-2 z-40 flex flex-col gap-1", children: [
|
|
22766
|
+
!isSidebarOpen && /* @__PURE__ */ jsxs("div", { className: "absolute top-2 left-2 z-40 flex flex-col gap-1 rounded-md bg-background/80 backdrop-blur-sm p-0.5", children: [
|
|
22767
22767
|
enableSidebar && onToggleSidebar && /* @__PURE__ */ jsx(
|
|
22768
22768
|
Button,
|
|
22769
22769
|
{
|
|
22770
22770
|
variant: "ghost",
|
|
22771
22771
|
size: "icon",
|
|
22772
22772
|
onClick: onToggleSidebar,
|
|
22773
|
-
className: "h-8 w-8 text-foreground hover:bg-accent hover:text-accent-foreground rounded-md
|
|
22773
|
+
className: "h-8 w-8 text-foreground hover:bg-accent hover:text-accent-foreground rounded-md",
|
|
22774
22774
|
title: t("tabs.sessions"),
|
|
22775
22775
|
children: /* @__PURE__ */ jsx(PanelLeft, { className: "w-4 h-4" })
|
|
22776
22776
|
}
|
|
@@ -22782,7 +22782,7 @@ var AssistantView = ({ ref, ...props }) => {
|
|
|
22782
22782
|
size: "icon",
|
|
22783
22783
|
onClick: () => onTabChange(activeTab === 4 ? 0 : 4),
|
|
22784
22784
|
className: cn(
|
|
22785
|
-
"h-8 w-8 text-foreground hover:bg-accent hover:text-accent-foreground rounded-md
|
|
22785
|
+
"h-8 w-8 text-foreground hover:bg-accent hover:text-accent-foreground rounded-md",
|
|
22786
22786
|
activeTab === 4 && "bg-background text-foreground shadow"
|
|
22787
22787
|
),
|
|
22788
22788
|
title: t("tabs.memories"),
|
|
@@ -22795,7 +22795,7 @@ var AssistantView = ({ ref, ...props }) => {
|
|
|
22795
22795
|
variant: "ghost",
|
|
22796
22796
|
size: "icon",
|
|
22797
22797
|
onClick: onNewChat,
|
|
22798
|
-
className: "h-8 w-8 text-foreground hover:bg-accent hover:text-accent-foreground rounded-md
|
|
22798
|
+
className: "h-8 w-8 text-foreground hover:bg-accent hover:text-accent-foreground rounded-md",
|
|
22799
22799
|
title: t("buttons.start_new_thread"),
|
|
22800
22800
|
children: /* @__PURE__ */ jsx(Edit, { className: "w-4 h-4" })
|
|
22801
22801
|
}
|
|
@@ -23257,7 +23257,7 @@ function MemoryDialog({
|
|
|
23257
23257
|
] })
|
|
23258
23258
|
] }) });
|
|
23259
23259
|
}
|
|
23260
|
-
var MemoriesPanel = ({ t }) => {
|
|
23260
|
+
var MemoriesPanel = ({ t, sidebarOffset }) => {
|
|
23261
23261
|
const apiClient = useApiClient();
|
|
23262
23262
|
const [memories, setMemories] = useState([]);
|
|
23263
23263
|
const [loading, setLoading] = useState(false);
|
|
@@ -23319,7 +23319,7 @@ var MemoriesPanel = ({ t }) => {
|
|
|
23319
23319
|
return m.title.toLowerCase().includes(q) || m.content.toLowerCase().includes(q);
|
|
23320
23320
|
});
|
|
23321
23321
|
return /* @__PURE__ */ jsxs("div", { className: "flex-1 flex flex-col overflow-y-auto p-6", children: [
|
|
23322
|
-
/* @__PURE__ */ jsxs("div", { className: "flex items-center justify-between mb-6", children: [
|
|
23322
|
+
/* @__PURE__ */ jsxs("div", { className: cn("flex items-center justify-between mb-6", sidebarOffset && "ml-6"), children: [
|
|
23323
23323
|
/* @__PURE__ */ jsx("div", { className: "flex flex-col min-w-0", children: /* @__PURE__ */ jsx("h1", { className: "text-2xl font-semibold ps-2", children: t("tabs.memories") }) }),
|
|
23324
23324
|
/* @__PURE__ */ jsxs(
|
|
23325
23325
|
Button,
|
|
@@ -23433,12 +23433,13 @@ var AssistantProjectDetailView = ({
|
|
|
23433
23433
|
enableVoice,
|
|
23434
23434
|
isRecording,
|
|
23435
23435
|
recognition,
|
|
23436
|
-
onMicrophoneClick
|
|
23436
|
+
onMicrophoneClick,
|
|
23437
|
+
sidebarOffset
|
|
23437
23438
|
}) => {
|
|
23438
23439
|
const { t } = useAssistantTranslation();
|
|
23439
23440
|
const [activeTab, setActiveTab] = useState("sessions");
|
|
23440
23441
|
return /* @__PURE__ */ jsxs("div", { className: "flex-1 flex flex-col px-6 mt-2 overflow-y-auto", children: [
|
|
23441
|
-
/* @__PURE__ */ jsxs("div", { className: "flex items-center gap-2 mb-2", children: [
|
|
23442
|
+
/* @__PURE__ */ jsxs("div", { className: cn("flex items-center gap-2 mb-2", sidebarOffset && "ml-6"), children: [
|
|
23442
23443
|
/* @__PURE__ */ jsx(
|
|
23443
23444
|
Button,
|
|
23444
23445
|
{
|
|
@@ -23771,10 +23772,11 @@ var SessionsListView = ({
|
|
|
23771
23772
|
onSessionClick,
|
|
23772
23773
|
onEditSession,
|
|
23773
23774
|
onDeleteSession,
|
|
23774
|
-
t
|
|
23775
|
+
t,
|
|
23776
|
+
sidebarOffset
|
|
23775
23777
|
}) => {
|
|
23776
23778
|
return /* @__PURE__ */ jsxs("div", { className: "flex-1 flex flex-col overflow-y-auto p-6", children: [
|
|
23777
|
-
/* @__PURE__ */ jsxs("div", { className: "flex items-center justify-between mb-6", children: [
|
|
23779
|
+
/* @__PURE__ */ jsxs("div", { className: cn("flex items-center justify-between mb-6", sidebarOffset && "ml-6"), children: [
|
|
23778
23780
|
/* @__PURE__ */ jsx("div", { className: "flex flex-col min-w-0", children: /* @__PURE__ */ jsx("h1", { className: "text-2xl font-semibold ps-2", children: t("tabs.sessions") }) }),
|
|
23779
23781
|
/* @__PURE__ */ jsxs(Button, { size: "sm", onClick: onNewSession, className: "shrink-0", children: [
|
|
23780
23782
|
/* @__PURE__ */ jsx(Plus, { className: "w-4 h-4" }),
|
|
@@ -25368,7 +25370,8 @@ var DocyAssistant = ({
|
|
|
25368
25370
|
sessionActions.selectSession(session);
|
|
25369
25371
|
sessionActions.setDeleteDialogOpen(true);
|
|
25370
25372
|
},
|
|
25371
|
-
t
|
|
25373
|
+
t,
|
|
25374
|
+
sidebarOffset: !uiState.isSidebarOpen && enableSidebar
|
|
25372
25375
|
}
|
|
25373
25376
|
),
|
|
25374
25377
|
renderProjectsView: () => projectState.view === "create" ? /* @__PURE__ */ jsxs("div", { className: "flex-1 flex flex-col p-6", children: [
|
|
@@ -25478,7 +25481,8 @@ var DocyAssistant = ({
|
|
|
25478
25481
|
enableVoice,
|
|
25479
25482
|
isRecording,
|
|
25480
25483
|
recognition,
|
|
25481
|
-
onMicrophoneClick: handleMicrophoneClick
|
|
25484
|
+
onMicrophoneClick: handleMicrophoneClick,
|
|
25485
|
+
sidebarOffset: !uiState.isSidebarOpen && enableSidebar
|
|
25482
25486
|
}
|
|
25483
25487
|
) : /* @__PURE__ */ jsx(
|
|
25484
25488
|
AssistantProjectsPanel,
|
|
@@ -25505,7 +25509,7 @@ var DocyAssistant = ({
|
|
|
25505
25509
|
t
|
|
25506
25510
|
}
|
|
25507
25511
|
),
|
|
25508
|
-
renderMemoriesView: () => /* @__PURE__ */ jsx(MemoriesPanel, { t }),
|
|
25512
|
+
renderMemoriesView: () => /* @__PURE__ */ jsx(MemoriesPanel, { t, sidebarOffset: !uiState.isSidebarOpen && enableSidebar }),
|
|
25509
25513
|
renderWorksView: () => worksState.detailViewWork ? /* @__PURE__ */ jsx("div", { className: "flex-1 flex flex-col overflow-y-auto", children: /* @__PURE__ */ jsx(
|
|
25510
25514
|
AssistantWorkDetailView,
|
|
25511
25515
|
{
|
|
@@ -25514,7 +25518,7 @@ var DocyAssistant = ({
|
|
|
25514
25518
|
onBack: () => worksActions.setDetailViewWork(null)
|
|
25515
25519
|
}
|
|
25516
25520
|
) }) : /* @__PURE__ */ jsxs("div", { className: "flex-1 flex flex-col overflow-y-auto p-6", children: [
|
|
25517
|
-
/* @__PURE__ */ jsxs("div", { className: "flex items-center justify-between mb-6", children: [
|
|
25521
|
+
/* @__PURE__ */ jsxs("div", { className: cn("flex items-center justify-between mb-6", !uiState.isSidebarOpen && enableSidebar && "ml-6"), children: [
|
|
25518
25522
|
/* @__PURE__ */ jsxs("div", { className: "flex flex-col min-w-0", children: [
|
|
25519
25523
|
/* @__PURE__ */ jsx("h1", { className: "text-2xl font-semibold ps-2", children: t("tabs.works") }),
|
|
25520
25524
|
/* @__PURE__ */ jsx("div", { className: "text-sm text-muted-foreground ps-2", children: t("descriptions.manage_works") })
|