@swiss-ai-hub/web 0.290.11
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/LICENSE +661 -0
- package/README.md +479 -0
- package/app.config.ts +1 -0
- package/app.vue +52 -0
- package/assets/css/main.css +4 -0
- package/assets/images/logo.png +0 -0
- package/components/Agent/Avatar.vue +40 -0
- package/components/Agent/Card.vue +139 -0
- package/components/Agent/Configuration.vue +20 -0
- package/components/Agent/CreateModal.vue +287 -0
- package/components/Agent/EmptyCard.vue +35 -0
- package/components/Agent/List.vue +85 -0
- package/components/Agent/TemplateCard.vue +58 -0
- package/components/AppLoader.vue +55 -0
- package/components/Chat/Message.vue +90 -0
- package/components/Chat/SourceNodes.vue +120 -0
- package/components/Chat/Thread.vue +134 -0
- package/components/Costs/Table.vue +56 -0
- package/components/Dashboard/Component/BarChart.vue +46 -0
- package/components/Dashboard/Component/LineChart.vue +138 -0
- package/components/Dashboard/Component/Number.vue +31 -0
- package/components/Dashboard/Grid.vue +214 -0
- package/components/Dashboard/Item.vue +75 -0
- package/components/Dashboard/Trend.vue +34 -0
- package/components/Display/List/DisplayList.vue +93 -0
- package/components/Evaluation/Dataset/Card.vue +70 -0
- package/components/Evaluation/Dataset/Create.vue +81 -0
- package/components/Evaluation/Dataset/Edit.vue +132 -0
- package/components/Event/Display/AddMemoryToChatHistoryEvent.vue +60 -0
- package/components/Event/Display/AgentInTheLoopRequestEvent.vue +56 -0
- package/components/Event/Display/AgentInTheLoopResponseEvent.vue +17 -0
- package/components/Event/Display/Base.vue +125 -0
- package/components/Event/Display/BaseRetrieveMemoryEvent.vue +101 -0
- package/components/Event/Display/BaseStoreMemoryEvent.vue +182 -0
- package/components/Event/Display/ChunkEvent.vue +40 -0
- package/components/Event/Display/EmbeddingEvent.vue +25 -0
- package/components/Event/Display/ExceptionEvent.vue +21 -0
- package/components/Event/Display/GuardAcceptEvent.vue +25 -0
- package/components/Event/Display/GuardEvent.vue +17 -0
- package/components/Event/Display/GuardRejectionEvent.vue +25 -0
- package/components/Event/Display/HumanInTheLoopRequestEvent.vue +53 -0
- package/components/Event/Display/HumanInTheLoopResponseEvent.vue +40 -0
- package/components/Event/Display/LLMCostEvent.vue +25 -0
- package/components/Event/Display/LLMEvent.vue +92 -0
- package/components/Event/Display/LimitChatHistoryEvent.vue +60 -0
- package/components/Event/Display/RAGFailureStopEvent.vue +28 -0
- package/components/Event/Display/RAGStartEvent.vue +77 -0
- package/components/Event/Display/RAGSuccessStopEvent.vue +16 -0
- package/components/Event/Display/RawDataContent.vue +69 -0
- package/components/Event/Display/RerankerEvent.vue +39 -0
- package/components/Event/Display/RetrieverEvent.vue +22 -0
- package/components/Event/Display/RouterEvent.vue +54 -0
- package/components/Event/Display/StandaloneQuestionCondenserEvent.vue +38 -0
- package/components/Event/Display/StopEvent.vue +16 -0
- package/components/Event/Display/ThoughtEvent.vue +20 -0
- package/components/Event/Display/ToolEvent.vue +38 -0
- package/components/Event/Display/UnknownEvent.vue +17 -0
- package/components/Event/Display/UserMessageEvent.vue +35 -0
- package/components/Event/List/EventList.vue +249 -0
- package/components/Event/Statistics.vue +49 -0
- package/components/Event/Timeseries.vue +224 -0
- package/components/FormKit/AgentSelector.vue +307 -0
- package/components/FormKit/ChipsInput.vue +62 -0
- package/components/FormKit/DynamicConfiguration.vue +155 -0
- package/components/FormKit/IconSelector.vue +72 -0
- package/components/FormKit/KnowledgeDatabaseSelector.vue +92 -0
- package/components/FormKit/LocaleInput.vue +150 -0
- package/components/FormKit/ModelSelect.vue +110 -0
- package/components/FormKit/Repeater.vue +93 -0
- package/components/FormKit/VectorStoreInput.vue +247 -0
- package/components/Knowledge/Document/List.vue +140 -0
- package/components/Knowledge/Document/Overview.vue +28 -0
- package/components/Knowledge/Document/UploadModal.vue +298 -0
- package/components/Knowledge/Document/WithNodes.vue +105 -0
- package/components/Knowledge/Namespace/Card.vue +108 -0
- package/components/Knowledge/Namespace/CreateModal.vue +203 -0
- package/components/Knowledge/Namespace/EditModal.vue +134 -0
- package/components/Knowledge/Namespace/EmptyCard.vue +35 -0
- package/components/Knowledge/Node/Content.vue +71 -0
- package/components/Markdown/Renderer.vue +87 -0
- package/components/Memory/DetailPage.vue +48 -0
- package/components/Memory/Edit.vue +241 -0
- package/components/Memory/Graph.vue +318 -0
- package/components/Memory/List.vue +155 -0
- package/components/Memory/MemoryManagementPage.vue +178 -0
- package/components/Memory/OpenWebUIContent.vue +96 -0
- package/components/Memory/PageLayout.vue +72 -0
- package/components/Models/ModelDetailsPanel.vue +250 -0
- package/components/Models/NamespaceCard.vue +79 -0
- package/components/Navigation/Left.vue +85 -0
- package/components/Navigation/Top.vue +31 -0
- package/components/Notification/Item.vue +88 -0
- package/components/Notification/NotificationsOverlay.vue +164 -0
- package/components/Process/Card.vue +119 -0
- package/components/Process/Configuration.vue +20 -0
- package/components/Process/CreateModal.vue +276 -0
- package/components/Process/EmptyCard.vue +35 -0
- package/components/Process/Form.vue +153 -0
- package/components/Process/Starts.vue +44 -0
- package/components/Process/Walkthrough/List.vue +162 -0
- package/components/Role/AccessRulesEditor.vue +132 -0
- package/components/Role/Card.vue +68 -0
- package/components/Role/Create.vue +55 -0
- package/components/Role/Edit.vue +82 -0
- package/components/Role/UsageLimitsEditor.vue +225 -0
- package/components/Service/Selection.vue +148 -0
- package/components/Structural/Column.vue +74 -0
- package/components/Structural/Screen.vue +10 -0
- package/components/Structural/Substructure.vue +5 -0
- package/components/Tenant/Switcher.vue +102 -0
- package/components/Thread/Details.vue +135 -0
- package/components/Thread/Hierarchy.vue +136 -0
- package/components/Thread/Info.vue +41 -0
- package/components/Thread/List.vue +136 -0
- package/components/User/Bar.vue +74 -0
- package/components/User/List.vue +86 -0
- package/components/User/RoleChips.vue +83 -0
- package/components/User/Settings.vue +79 -0
- package/components/Workflow/Modal.vue +39 -0
- package/components/Workflow/NodeCard.vue +41 -0
- package/components/Workflow/StartNode.vue +24 -0
- package/components/Workflow/StepNode.vue +27 -0
- package/components/Workflow/StopNode.vue +24 -0
- package/components/Workflow/Visualization.vue +265 -0
- package/components/mdc/MarkdownFigure.vue +9 -0
- package/components/mdc/MarkdownTable.vue +9 -0
- package/components/mdc/ResolveImageComponent.vue +58 -0
- package/composables/agent/useAgentClass.ts +27 -0
- package/composables/agent/useAgentClassInstances.ts +27 -0
- package/composables/agent/useAgentClasses.ts +27 -0
- package/composables/agent/useAgentIconFromThread.ts +8 -0
- package/composables/agent/useAgentInstance.ts +28 -0
- package/composables/agent/useAgentInstanceThreads.ts +76 -0
- package/composables/agent/useAgentInstances.ts +25 -0
- package/composables/agent/useAgentNavigation.ts +35 -0
- package/composables/agent/useCreateAgentInstance.ts +33 -0
- package/composables/agent/useDeleteAgentInstance.ts +31 -0
- package/composables/agent/useUpdateAgentInstance.ts +40 -0
- package/composables/auth/useAuth.ts +54 -0
- package/composables/auth/useAuthProviders.ts +14 -0
- package/composables/chat/useChatCompletions.ts +30 -0
- package/composables/dashboard/useAgentNameFromDashboardWidget.ts +27 -0
- package/composables/dashboard/useDashboardComponent.ts +27 -0
- package/composables/dashboard/useSaveDashboard.ts +21 -0
- package/composables/document/useCreateNamespace.ts +26 -0
- package/composables/document/useDatabases.ts +23 -0
- package/composables/document/useDocument.ts +29 -0
- package/composables/document/useDocumentUrl.ts +20 -0
- package/composables/document/useDocuments.ts +107 -0
- package/composables/document/useNodes.ts +29 -0
- package/composables/document/useSummaryNodes.ts +32 -0
- package/composables/document/useUpdateNamespace.ts +22 -0
- package/composables/evaluation/useCreateDataset.ts +19 -0
- package/composables/evaluation/useDataset.ts +26 -0
- package/composables/evaluation/useDatasets.ts +25 -0
- package/composables/evaluation/useUpdateDataset.ts +23 -0
- package/composables/event/useBasicEventStatistics.ts +83 -0
- package/composables/event/useEventColor.ts +25 -0
- package/composables/event/useEventComponent.ts +87 -0
- package/composables/event/useEventTimeseries.ts +39 -0
- package/composables/event/useEventTimeseriesStats.ts +26 -0
- package/composables/file/useFileUpload.ts +91 -0
- package/composables/file/useSupportedFileTypes.ts +22 -0
- package/composables/form/useCreateInstanceForm.ts +251 -0
- package/composables/form/useFormKitTransform.ts +753 -0
- package/composables/memory/useMemoryCRUD.ts +88 -0
- package/composables/memory/useMemoryFactory.ts +319 -0
- package/composables/memory/useMemorySearchFilter.ts +74 -0
- package/composables/models/useModelsList.ts +24 -0
- package/composables/models/useSingleModel.ts +30 -0
- package/composables/notification/useNotificationPoller.ts +58 -0
- package/composables/notification/useNotifications.ts +57 -0
- package/composables/notification/useUpdateMultipleNotifications.ts +17 -0
- package/composables/notification/useUpdateNotification.ts +17 -0
- package/composables/process/useCreateProcessInstance.ts +32 -0
- package/composables/process/useDeleteProcessInstance.ts +31 -0
- package/composables/process/useProcessClasses.ts +27 -0
- package/composables/process/useProcessInstance.ts +28 -0
- package/composables/process/useProcessInstances.ts +27 -0
- package/composables/process/useProcessWalkthroughs.ts +73 -0
- package/composables/process/useSendProcessStartForm.ts +43 -0
- package/composables/process/useUpdateProcessInstance.ts +40 -0
- package/composables/role/useCreateRole.ts +19 -0
- package/composables/role/useDeleteRole.ts +21 -0
- package/composables/role/useRole.ts +30 -0
- package/composables/role/useRoles.ts +25 -0
- package/composables/role/useUpdateRole.ts +22 -0
- package/composables/suite/useApps.ts +31 -0
- package/composables/suite/useSuite.ts +26 -0
- package/composables/tenant/useActiveTenant.ts +27 -0
- package/composables/tenant/useSysadminNavigation.ts +19 -0
- package/composables/tenant/useTenant.ts +38 -0
- package/composables/tenant/useTenantMemberships.ts +15 -0
- package/composables/tenant/useTenantPath.ts +20 -0
- package/composables/tenant/useTenantPolling.ts +30 -0
- package/composables/tenant/useTenantReady.ts +12 -0
- package/composables/theme/useDarkMode.ts +5 -0
- package/composables/thread/useThread.ts +27 -0
- package/composables/thread/useThreadEvents.ts +91 -0
- package/composables/thread/useThreadUtils.ts +49 -0
- package/composables/thread/useThreads.ts +64 -0
- package/composables/thread/useThreadsInfinite.ts +56 -0
- package/composables/translation/useTranslate.ts +20 -0
- package/composables/useRouteReady.ts +21 -0
- package/composables/useTimeAgo.ts +40 -0
- package/composables/user/useAssignRoleToUser.ts +22 -0
- package/composables/user/useMyUser.ts +25 -0
- package/composables/user/useRevokeRoleFromUser.ts +21 -0
- package/composables/user/useUser.ts +30 -0
- package/composables/user/useUsers.ts +63 -0
- package/composables/utils/useJsonTree.ts +138 -0
- package/formkit.config.ts +44 -0
- package/i18n/locales/de.yaml +815 -0
- package/i18n/locales/en.yaml +804 -0
- package/i18n/locales/fr.yaml +812 -0
- package/i18n/locales/it.yaml +808 -0
- package/layouts/anonymous.vue +8 -0
- package/layouts/default.vue +116 -0
- package/middleware/auth.global.ts +62 -0
- package/nuxt.config.ts +145 -0
- package/package.json +114 -0
- package/pages/[tenant]/index.vue +31 -0
- package/pages/[tenant]/notifications/index.vue +235 -0
- package/pages/[tenant]/service/agents/[agent_class]-[agent_id]/chat.vue +67 -0
- package/pages/[tenant]/service/agents/[agent_class]-[agent_id]/configuration.vue +122 -0
- package/pages/[tenant]/service/agents/[agent_class]-[agent_id]/memories/[memory_id].vue +3 -0
- package/pages/[tenant]/service/agents/[agent_class]-[agent_id]/memories.vue +20 -0
- package/pages/[tenant]/service/agents/[agent_class]-[agent_id]/overview.vue +72 -0
- package/pages/[tenant]/service/agents/[agent_class]-[agent_id]/threads.vue +52 -0
- package/pages/[tenant]/service/agents/[agent_class]-[agent_id]/workflow.vue +19 -0
- package/pages/[tenant]/service/agents/[agent_class]-[agent_id].vue +63 -0
- package/pages/[tenant]/service/agents/templates.vue +102 -0
- package/pages/[tenant]/service/agents.vue +185 -0
- package/pages/[tenant]/service/datasets/[dataset_id].vue +81 -0
- package/pages/[tenant]/service/datasets.vue +53 -0
- package/pages/[tenant]/service/health/index.vue +3 -0
- package/pages/[tenant]/service/knowledge/[db]/[namespace]/[document_id]/nodes.vue +20 -0
- package/pages/[tenant]/service/knowledge/[db]/[namespace]/[document_id]/overview.vue +40 -0
- package/pages/[tenant]/service/knowledge/[db]/[namespace]/[document_id]/summary.vue +88 -0
- package/pages/[tenant]/service/knowledge/[db]/[namespace]/[document_id].vue +48 -0
- package/pages/[tenant]/service/knowledge/[db]/[namespace].vue +144 -0
- package/pages/[tenant]/service/knowledge.vue +126 -0
- package/pages/[tenant]/service/models/[model_name].vue +84 -0
- package/pages/[tenant]/service/models.vue +61 -0
- package/pages/[tenant]/service/my-account.vue +117 -0
- package/pages/[tenant]/service/openai/[thread_id]/[display_id]/memories.vue +66 -0
- package/pages/[tenant]/service/openai/[thread_id]/[display_id]/sources.vue +100 -0
- package/pages/[tenant]/service/openai/[thread_id]/[display_id]/tracing.vue +49 -0
- package/pages/[tenant]/service/openai.vue +101 -0
- package/pages/[tenant]/service/organization-memories/graph.vue +97 -0
- package/pages/[tenant]/service/organization-memories/list/[memory_id].vue +3 -0
- package/pages/[tenant]/service/organization-memories/list.vue +150 -0
- package/pages/[tenant]/service/organization-memories.vue +3 -0
- package/pages/[tenant]/service/processes/[process_class]-[process_id]/[process_walkthrough_id].vue +7 -0
- package/pages/[tenant]/service/processes/[process_class]-[process_id]/configuration.vue +106 -0
- package/pages/[tenant]/service/processes/[process_class]-[process_id]/overview.vue +67 -0
- package/pages/[tenant]/service/processes/[process_class]-[process_id]/start.vue +26 -0
- package/pages/[tenant]/service/processes/[process_class]-[process_id]/walkthroughs/[process_walkthrough_id]/overview.vue +14 -0
- package/pages/[tenant]/service/processes/[process_class]-[process_id]/walkthroughs.vue +54 -0
- package/pages/[tenant]/service/processes/[process_class]-[process_id].vue +60 -0
- package/pages/[tenant]/service/processes.vue +129 -0
- package/pages/[tenant]/service/roles/[role_id].vue +54 -0
- package/pages/[tenant]/service/roles.vue +84 -0
- package/pages/[tenant]/service/threads/[thread_id]/chat.vue +51 -0
- package/pages/[tenant]/service/threads/[thread_id]/display/[display_id].vue +21 -0
- package/pages/[tenant]/service/threads/[thread_id]/display.vue +29 -0
- package/pages/[tenant]/service/threads/[thread_id]/hierarchy.vue +14 -0
- package/pages/[tenant]/service/threads/[thread_id]/memories/[memory_id].vue +3 -0
- package/pages/[tenant]/service/threads/[thread_id]/memories.vue +19 -0
- package/pages/[tenant]/service/threads/[thread_id]/overview.vue +100 -0
- package/pages/[tenant]/service/threads/[thread_id].vue +54 -0
- package/pages/[tenant]/service/threads.vue +52 -0
- package/pages/[tenant]/service/user-memories/graph.vue +97 -0
- package/pages/[tenant]/service/user-memories/list/[memory_id].vue +3 -0
- package/pages/[tenant]/service/user-memories/list.vue +150 -0
- package/pages/[tenant]/service/user-memories.vue +3 -0
- package/pages/[tenant]/service/users/[user_id].vue +117 -0
- package/pages/[tenant]/service/users.vue +88 -0
- package/pages/auth/callback.vue +52 -0
- package/pages/auth/login.vue +80 -0
- package/pages/auth/renew.vue +24 -0
- package/pages/index.vue +59 -0
- package/pages/select-tenant.vue +76 -0
- package/plugins/0.runtime-config.client.ts +55 -0
- package/plugins/apexcharts.client.ts +5 -0
- package/plugins/api-client.client.ts +38 -0
- package/plugins/dark-mode.client.ts +12 -0
- package/plugins/keycloak-client.ts +41 -0
- package/plugins/oidc-client.ts +78 -0
- package/sdk/client/client/client.gen.ts +237 -0
- package/sdk/client/client/index.ts +24 -0
- package/sdk/client/client/types.gen.ts +213 -0
- package/sdk/client/client/utils.gen.ts +407 -0
- package/sdk/client/client.gen.ts +25 -0
- package/sdk/client/core/auth.gen.ts +42 -0
- package/sdk/client/core/bodySerializer.gen.ts +96 -0
- package/sdk/client/core/params.gen.ts +181 -0
- package/sdk/client/core/pathSerializer.gen.ts +180 -0
- package/sdk/client/core/queryKeySerializer.gen.ts +136 -0
- package/sdk/client/core/serverSentEvents.gen.ts +265 -0
- package/sdk/client/core/types.gen.ts +118 -0
- package/sdk/client/core/utils.gen.ts +143 -0
- package/sdk/client/index.ts +1013 -0
- package/sdk/client/schemas.gen.ts +35395 -0
- package/sdk/client/sdk.gen.ts +3438 -0
- package/sdk/client/transformers.gen.ts +143 -0
- package/sdk/client/types.gen.ts +27567 -0
- package/tailwind.config.mjs +27 -0
- package/themes/aihub-theme.ts +125 -0
- package/types/DashboardWidget.ts +13 -0
- package/types/EventChartInput.ts +7 -0
- package/types/NavItem.ts +6 -0
- package/types/TimeseriesInput.ts +7 -0
|
@@ -0,0 +1,148 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<Button
|
|
3
|
+
aria-label="Menu"
|
|
4
|
+
variant="text"
|
|
5
|
+
@click="toggle"
|
|
6
|
+
>
|
|
7
|
+
<template #icon>
|
|
8
|
+
<Icon
|
|
9
|
+
name="mage:dots-menu"
|
|
10
|
+
size="xl"
|
|
11
|
+
/>
|
|
12
|
+
</template>
|
|
13
|
+
</Button>
|
|
14
|
+
<Popover
|
|
15
|
+
ref="op"
|
|
16
|
+
class="[--p-popover-background:#f9f9f9] [--p-popover-border-color:#e3e3e3] dark:[--p-popover-background:#0d0d0d] dark:[--p-popover-border-color:#333]"
|
|
17
|
+
>
|
|
18
|
+
<div
|
|
19
|
+
v-focustrap
|
|
20
|
+
class="flex flex-col gap-4 p-5"
|
|
21
|
+
>
|
|
22
|
+
<div>
|
|
23
|
+
<h2 class="text-xl">
|
|
24
|
+
{{ t('service.selection.title') }}
|
|
25
|
+
</h2>
|
|
26
|
+
<p class="text-sm">
|
|
27
|
+
{{ t('service.selection.description') }}
|
|
28
|
+
</p>
|
|
29
|
+
</div>
|
|
30
|
+
<IconField>
|
|
31
|
+
<InputIcon>
|
|
32
|
+
<i class="pi pi-search" />
|
|
33
|
+
</InputIcon>
|
|
34
|
+
<InputText
|
|
35
|
+
id="input"
|
|
36
|
+
v-model="search"
|
|
37
|
+
size="small"
|
|
38
|
+
type="text"
|
|
39
|
+
:placeholder="t('service.selection.search')"
|
|
40
|
+
autofocus
|
|
41
|
+
fluid
|
|
42
|
+
@keydown.enter="onEnter"
|
|
43
|
+
/>
|
|
44
|
+
</IconField>
|
|
45
|
+
</div>
|
|
46
|
+
<div class="relative grid grid-cols-4 gap-3 p-5">
|
|
47
|
+
<template v-if="appsLoading">
|
|
48
|
+
<skeleton
|
|
49
|
+
v-for="i in 6"
|
|
50
|
+
:key="i"
|
|
51
|
+
width="5rem"
|
|
52
|
+
height="5rem"
|
|
53
|
+
/>
|
|
54
|
+
</template>
|
|
55
|
+
<template
|
|
56
|
+
v-else
|
|
57
|
+
>
|
|
58
|
+
<div
|
|
59
|
+
v-for="app in shownApps"
|
|
60
|
+
:key="app.path"
|
|
61
|
+
:class="[
|
|
62
|
+
'rounded-2xl border p-3 transition-colors hover:border-primary-500 dark:border-primary-900 hover:dark:border-primary-400',
|
|
63
|
+
isActiveApp(app.path)
|
|
64
|
+
? 'bg-surface-200 dark:bg-surface-800'
|
|
65
|
+
: 'bg-surface-100 dark:bg-surface-900',
|
|
66
|
+
]"
|
|
67
|
+
>
|
|
68
|
+
<NuxtLink
|
|
69
|
+
:to="app.path === '/' ? tenantPath('/') : tenantPath(app.path)"
|
|
70
|
+
class="flex h-[50px] items-center justify-center"
|
|
71
|
+
@click="toggle"
|
|
72
|
+
>
|
|
73
|
+
<div class="flex h-[60px] min-w-[80px] flex-col items-center justify-center gap-2">
|
|
74
|
+
<Icon
|
|
75
|
+
:name="app.icon"
|
|
76
|
+
class="size-6"
|
|
77
|
+
/>
|
|
78
|
+
<p
|
|
79
|
+
:class="[
|
|
80
|
+
'text-sm font-medium',
|
|
81
|
+
]"
|
|
82
|
+
>
|
|
83
|
+
{{ app.label }}
|
|
84
|
+
</p>
|
|
85
|
+
</div>
|
|
86
|
+
</NuxtLink>
|
|
87
|
+
</div>
|
|
88
|
+
<div
|
|
89
|
+
v-for="i in 4"
|
|
90
|
+
:key="i"
|
|
91
|
+
class="px-3"
|
|
92
|
+
>
|
|
93
|
+
<div class="h-0 min-w-[80px]" />
|
|
94
|
+
</div>
|
|
95
|
+
</template>
|
|
96
|
+
</div>
|
|
97
|
+
</Popover>
|
|
98
|
+
</template>
|
|
99
|
+
|
|
100
|
+
<script setup lang="ts">
|
|
101
|
+
import type { MenuItem } from 'primevue/menuitem'
|
|
102
|
+
|
|
103
|
+
const router = useRouter()
|
|
104
|
+
const route = useRoute()
|
|
105
|
+
const tenantPath = useTenantPath()
|
|
106
|
+
|
|
107
|
+
const { apps, appsLoading } = useApps()
|
|
108
|
+
const { t } = useI18n()
|
|
109
|
+
|
|
110
|
+
const shownApps = computed(() => {
|
|
111
|
+
return search.value
|
|
112
|
+
? apps.value.filter((app: MenuItem) => {
|
|
113
|
+
const label = typeof app.label === 'string'
|
|
114
|
+
? app.label
|
|
115
|
+
: ''
|
|
116
|
+
return label.toLowerCase().includes(search.value.toLowerCase())
|
|
117
|
+
})
|
|
118
|
+
: apps.value
|
|
119
|
+
})
|
|
120
|
+
|
|
121
|
+
const isActiveApp = (appPath: string | undefined) => {
|
|
122
|
+
if (!appPath) return false
|
|
123
|
+
const localizedPath = tenantPath(appPath)
|
|
124
|
+
// For home page, only match exact path
|
|
125
|
+
if (appPath === '/') {
|
|
126
|
+
return route.path === localizedPath
|
|
127
|
+
}
|
|
128
|
+
// For other pages, match exact or nested routes
|
|
129
|
+
return route.path === localizedPath || route.path.startsWith(localizedPath + '/')
|
|
130
|
+
}
|
|
131
|
+
|
|
132
|
+
const search = ref('')
|
|
133
|
+
watch(() => route.path, () => {
|
|
134
|
+
search.value = ''
|
|
135
|
+
})
|
|
136
|
+
|
|
137
|
+
const op = ref()
|
|
138
|
+
const toggle = (event: Event) => {
|
|
139
|
+
op.value.toggle(event)
|
|
140
|
+
}
|
|
141
|
+
|
|
142
|
+
const onEnter = (event: Event) => {
|
|
143
|
+
if (shownApps.value.length > 0) {
|
|
144
|
+
router.push(tenantPath(shownApps.value[0].path))
|
|
145
|
+
toggle(event)
|
|
146
|
+
}
|
|
147
|
+
}
|
|
148
|
+
</script>
|
|
@@ -0,0 +1,74 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<div class="relative flex flex-col gap-3 max-2xl:w-full">
|
|
3
|
+
<div
|
|
4
|
+
:class="[
|
|
5
|
+
'overflow-hidden rounded-3xl bg-white dark:bg-surface-900 max-2xl:w-full max-2xl:max-w-full',
|
|
6
|
+
sizeClass,
|
|
7
|
+
]"
|
|
8
|
+
>
|
|
9
|
+
<ProgressBar
|
|
10
|
+
v-if="loading"
|
|
11
|
+
mode="indeterminate"
|
|
12
|
+
style="height: 2px"
|
|
13
|
+
/>
|
|
14
|
+
<div
|
|
15
|
+
v-else
|
|
16
|
+
class="h-[2px] w-full"
|
|
17
|
+
/>
|
|
18
|
+
<div
|
|
19
|
+
v-if="loading === undefined || loading === false"
|
|
20
|
+
class="p-6"
|
|
21
|
+
>
|
|
22
|
+
<div class="flex items-center justify-between font-bold">
|
|
23
|
+
<h2
|
|
24
|
+
v-if="!childColumn"
|
|
25
|
+
class="text-2xl"
|
|
26
|
+
>
|
|
27
|
+
{{ title }}
|
|
28
|
+
</h2>
|
|
29
|
+
<h3
|
|
30
|
+
v-else
|
|
31
|
+
class="text-xl"
|
|
32
|
+
>
|
|
33
|
+
{{ title }}
|
|
34
|
+
</h3>
|
|
35
|
+
<i
|
|
36
|
+
v-if="closeRoute"
|
|
37
|
+
class="pi pi-times cursor-pointer text-xl"
|
|
38
|
+
@click="close"
|
|
39
|
+
/>
|
|
40
|
+
</div>
|
|
41
|
+
<Divider />
|
|
42
|
+
<slot />
|
|
43
|
+
</div>
|
|
44
|
+
</div>
|
|
45
|
+
</div>
|
|
46
|
+
</template>
|
|
47
|
+
|
|
48
|
+
<script setup lang="ts">
|
|
49
|
+
const props = withDefaults(defineProps<{
|
|
50
|
+
title: string
|
|
51
|
+
closeRoute?: string
|
|
52
|
+
size?: 'small' | 'normal' | 'large'
|
|
53
|
+
loading?: boolean
|
|
54
|
+
childColumn?: boolean
|
|
55
|
+
}>(), {
|
|
56
|
+
size: 'normal',
|
|
57
|
+
loading: false,
|
|
58
|
+
childColumn: false,
|
|
59
|
+
})
|
|
60
|
+
|
|
61
|
+
const sizeClass = computed<string>(() => {
|
|
62
|
+
return {
|
|
63
|
+
small: '2xl:w-[680px]',
|
|
64
|
+
normal: '2xl:w-[920px]',
|
|
65
|
+
large: '2xl:w-[1440px]',
|
|
66
|
+
}[props.size]
|
|
67
|
+
})
|
|
68
|
+
|
|
69
|
+
const router = useRouter()
|
|
70
|
+
const tenantPath = useTenantPath()
|
|
71
|
+
const close = () => {
|
|
72
|
+
router.push(tenantPath(props.closeRoute))
|
|
73
|
+
}
|
|
74
|
+
</script>
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<div class="flex h-[calc(100vh-50px)] w-full flex-col justify-start gap-2 overflow-auto bg-surface-50 dark:bg-surface-950">
|
|
3
|
+
<div class="px-8 pt-8">
|
|
4
|
+
<slot name="top" />
|
|
5
|
+
</div>
|
|
6
|
+
<div class="flex flex-col justify-start gap-8 px-8 2xl:flex-row">
|
|
7
|
+
<slot />
|
|
8
|
+
</div>
|
|
9
|
+
</div>
|
|
10
|
+
</template>
|
|
@@ -0,0 +1,102 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<div class="flex items-center gap-2">
|
|
3
|
+
<button
|
|
4
|
+
v-tooltip.bottom="{ value: t('tenant.switcher_label') }"
|
|
5
|
+
class="flex max-w-48 items-center gap-1.5 rounded px-2 py-1 text-sm text-surface-600 transition-colors dark:text-surface-300"
|
|
6
|
+
:class="hasMultipleTenants || isSysAdmin ? 'cursor-pointer hover:bg-surface-100 dark:hover:bg-surface-800' : 'cursor-default'"
|
|
7
|
+
:disabled="!hasMultipleTenants && !isSysAdmin"
|
|
8
|
+
:aria-label="t('tenant.switcher_label')"
|
|
9
|
+
@click="toggle"
|
|
10
|
+
>
|
|
11
|
+
<i class="pi pi-building shrink-0 text-xs" />
|
|
12
|
+
<span class="truncate">{{ currentTenantDisplayName }}</span>
|
|
13
|
+
<i
|
|
14
|
+
v-if="hasMultipleTenants || isSysAdmin"
|
|
15
|
+
class="pi pi-chevron-down shrink-0 text-xs opacity-60"
|
|
16
|
+
/>
|
|
17
|
+
</button>
|
|
18
|
+
|
|
19
|
+
<Popover ref="popoverRef">
|
|
20
|
+
<div class="flex w-64 flex-col gap-2 p-2">
|
|
21
|
+
<p class="text-sm font-bold text-muted-color">
|
|
22
|
+
{{ t('tenant.switcher_label') }}
|
|
23
|
+
</p>
|
|
24
|
+
<div
|
|
25
|
+
v-for="tenant in tenants"
|
|
26
|
+
:key="tenant.id"
|
|
27
|
+
class="cursor-pointer rounded-md px-3 py-2 transition-colors hover:bg-surface-100 dark:hover:bg-surface-700"
|
|
28
|
+
:class="{ 'bg-primary/10 font-semibold': tenant.id === tenantId }"
|
|
29
|
+
@click="onSelect(tenant)"
|
|
30
|
+
>
|
|
31
|
+
<p class="text-sm">
|
|
32
|
+
{{ tenant.name }}
|
|
33
|
+
</p>
|
|
34
|
+
<p
|
|
35
|
+
v-if="tenant.description"
|
|
36
|
+
class="text-xs text-muted-color"
|
|
37
|
+
>
|
|
38
|
+
{{ tenant.description }}
|
|
39
|
+
</p>
|
|
40
|
+
</div>
|
|
41
|
+
|
|
42
|
+
<div
|
|
43
|
+
v-if="isSysAdmin"
|
|
44
|
+
class="border-t border-surface-200 pt-2 dark:border-surface-700"
|
|
45
|
+
>
|
|
46
|
+
<div
|
|
47
|
+
class="flex cursor-pointer items-center gap-2 rounded-md px-3 py-2 transition-colors hover:bg-surface-100 dark:hover:bg-surface-700"
|
|
48
|
+
@click="enterSysAdmin"
|
|
49
|
+
>
|
|
50
|
+
<i class="pi pi-cog text-xs text-primary" />
|
|
51
|
+
<p class="text-sm">
|
|
52
|
+
{{ t('tenant.administration_title') }}
|
|
53
|
+
</p>
|
|
54
|
+
</div>
|
|
55
|
+
</div>
|
|
56
|
+
|
|
57
|
+
<p
|
|
58
|
+
v-if="!tenants?.length && !tenantsAreLoading"
|
|
59
|
+
class="text-sm text-muted-color"
|
|
60
|
+
>
|
|
61
|
+
{{ t('tenant.no_tenant_description') }}
|
|
62
|
+
</p>
|
|
63
|
+
<ProgressSpinner
|
|
64
|
+
v-if="tenantsAreLoading"
|
|
65
|
+
style="width: 1.5rem; height: 1.5rem"
|
|
66
|
+
/>
|
|
67
|
+
</div>
|
|
68
|
+
</Popover>
|
|
69
|
+
</div>
|
|
70
|
+
</template>
|
|
71
|
+
|
|
72
|
+
<script setup lang="ts">
|
|
73
|
+
import Popover from 'primevue/popover'
|
|
74
|
+
|
|
75
|
+
import type { TenantMembershipDto } from '@core/sdk/client'
|
|
76
|
+
|
|
77
|
+
const { t } = useI18n()
|
|
78
|
+
const { tenantId, setTenant } = useTenant()
|
|
79
|
+
const { tenants, tenantsAreLoading, isSysAdmin } = useTenantMemberships()
|
|
80
|
+
const { enterSysadmin } = useSysadminNavigation()
|
|
81
|
+
|
|
82
|
+
const hasMultipleTenants = computed(() => (tenants.value?.length ?? 0) > 1)
|
|
83
|
+
const currentTenantDisplayName = computed(() => {
|
|
84
|
+
const current = tenants.value?.find(t => t.id === tenantId.value)
|
|
85
|
+
return current?.name ?? tenantId.value ?? ''
|
|
86
|
+
})
|
|
87
|
+
const popoverRef = ref<InstanceType<typeof Popover>>()
|
|
88
|
+
|
|
89
|
+
function toggle(event: Event) {
|
|
90
|
+
popoverRef.value?.toggle(event)
|
|
91
|
+
}
|
|
92
|
+
|
|
93
|
+
async function onSelect(tenant: TenantMembershipDto) {
|
|
94
|
+
popoverRef.value?.hide()
|
|
95
|
+
await setTenant(tenant.id)
|
|
96
|
+
}
|
|
97
|
+
|
|
98
|
+
function enterSysAdmin() {
|
|
99
|
+
popoverRef.value?.hide()
|
|
100
|
+
enterSysadmin()
|
|
101
|
+
}
|
|
102
|
+
</script>
|
|
@@ -0,0 +1,135 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<div>
|
|
3
|
+
<Tabs
|
|
4
|
+
v-model:value="activeDisplayId"
|
|
5
|
+
scrollable
|
|
6
|
+
>
|
|
7
|
+
<TabList>
|
|
8
|
+
<Tab
|
|
9
|
+
v-for="display in thread.displays"
|
|
10
|
+
:key="display.display_id"
|
|
11
|
+
:value="display.display_id"
|
|
12
|
+
>
|
|
13
|
+
{{ displayNameFn(display) }}
|
|
14
|
+
<i
|
|
15
|
+
v-if="display.has_errors"
|
|
16
|
+
class="pi pi-exclamation-triangle text-red-500"
|
|
17
|
+
/>
|
|
18
|
+
<i
|
|
19
|
+
v-if="display.has_pending"
|
|
20
|
+
class="pi pi-exclamation-triangle text-yellow-500"
|
|
21
|
+
/>
|
|
22
|
+
</Tab>
|
|
23
|
+
</TabList>
|
|
24
|
+
<TabPanels>
|
|
25
|
+
<TabPanel
|
|
26
|
+
v-for="display in thread.displays"
|
|
27
|
+
:key="display.display_id"
|
|
28
|
+
:value="display.display_id"
|
|
29
|
+
>
|
|
30
|
+
<div class="flex flex-col gap-12 pt-4">
|
|
31
|
+
<Panel class="panel pt-5">
|
|
32
|
+
<div class="grid grid-cols-2 gap-4 xl:grid-cols-4">
|
|
33
|
+
<div class="flex flex-col items-start gap-2">
|
|
34
|
+
<span class="font-semibold">
|
|
35
|
+
{{ t('event.list.firstInteraction') }}
|
|
36
|
+
</span>
|
|
37
|
+
<Tag
|
|
38
|
+
:value="formattedDate(display.started_at)"
|
|
39
|
+
severity="secondary"
|
|
40
|
+
/>
|
|
41
|
+
</div>
|
|
42
|
+
<div class="flex flex-col items-start gap-2">
|
|
43
|
+
<span class="font-semibold">
|
|
44
|
+
{{ t('event.list.lastInteraction') }}
|
|
45
|
+
</span>
|
|
46
|
+
<Tag
|
|
47
|
+
:value="formattedDate(display.ended_at)"
|
|
48
|
+
severity="secondary"
|
|
49
|
+
/>
|
|
50
|
+
</div>
|
|
51
|
+
<div class="flex flex-col items-start gap-2">
|
|
52
|
+
<span class="font-semibold">
|
|
53
|
+
{{ t('event.list.pending') }}
|
|
54
|
+
</span>
|
|
55
|
+
<Tag
|
|
56
|
+
v-if="display.has_pending"
|
|
57
|
+
severity="warn"
|
|
58
|
+
:value="pendingType(display)"
|
|
59
|
+
/>
|
|
60
|
+
<Tag
|
|
61
|
+
v-else
|
|
62
|
+
severity="success"
|
|
63
|
+
:value="t('event.list.no')"
|
|
64
|
+
/>
|
|
65
|
+
</div>
|
|
66
|
+
<div class="flex flex-col items-start gap-2">
|
|
67
|
+
<span class="font-semibold">
|
|
68
|
+
{{ t('event.list.status') }}
|
|
69
|
+
</span>
|
|
70
|
+
<Tag
|
|
71
|
+
v-if="display.has_errors"
|
|
72
|
+
severity="danger"
|
|
73
|
+
:value="t('event.list.error')"
|
|
74
|
+
/>
|
|
75
|
+
<Tag
|
|
76
|
+
v-else
|
|
77
|
+
severity="success"
|
|
78
|
+
:value="t('event.list.successful')"
|
|
79
|
+
/>
|
|
80
|
+
</div>
|
|
81
|
+
</div>
|
|
82
|
+
</Panel>
|
|
83
|
+
<EventList
|
|
84
|
+
:events="events"
|
|
85
|
+
:thread="thread"
|
|
86
|
+
:display-id="activeDisplayId"
|
|
87
|
+
:show-chat="showChat"
|
|
88
|
+
/>
|
|
89
|
+
</div>
|
|
90
|
+
</TabPanel>
|
|
91
|
+
</TabPanels>
|
|
92
|
+
</Tabs>
|
|
93
|
+
</div>
|
|
94
|
+
</template>
|
|
95
|
+
|
|
96
|
+
<script setup lang="ts">
|
|
97
|
+
import { format } from 'date-fns'
|
|
98
|
+
|
|
99
|
+
import type {
|
|
100
|
+
DisplayStatistics,
|
|
101
|
+
ThreadDto,
|
|
102
|
+
ContextualizedAgentEvent,
|
|
103
|
+
} from '@core/sdk/client'
|
|
104
|
+
|
|
105
|
+
const props = withDefaults(defineProps<{
|
|
106
|
+
events: ContextualizedAgentEvent[]
|
|
107
|
+
thread: ThreadDto
|
|
108
|
+
displayId?: string
|
|
109
|
+
showChat?: boolean
|
|
110
|
+
}>(), {
|
|
111
|
+
showChat: false,
|
|
112
|
+
})
|
|
113
|
+
|
|
114
|
+
const { pendingType } = useThreadUtils()
|
|
115
|
+
const { t } = useI18n()
|
|
116
|
+
|
|
117
|
+
const activeDisplayId = ref(props.thread.displays?.at(-1)?.display_id)
|
|
118
|
+
|
|
119
|
+
watch(() => props.displayId, (newDisplayId) => {
|
|
120
|
+
activeDisplayId.value = newDisplayId
|
|
121
|
+
})
|
|
122
|
+
|
|
123
|
+
const displayNameFn = (display: DisplayStatistics) => format(new Date(display.started_at), 'dd.MM.yyyy HH:mm')
|
|
124
|
+
const formattedDate = (datestr: string) => useDateFormat(new Date(datestr), 'DD.MM.YYYY HH:mm:ss')
|
|
125
|
+
</script>
|
|
126
|
+
|
|
127
|
+
<style scoped>
|
|
128
|
+
.customized-timeline :deep(.p-timeline-event-opposite){
|
|
129
|
+
width: 60px;
|
|
130
|
+
max-width: 60px;
|
|
131
|
+
}
|
|
132
|
+
.panel :deep(.p-panel-header) {
|
|
133
|
+
padding: 0 !important;
|
|
134
|
+
}
|
|
135
|
+
</style>
|
|
@@ -0,0 +1,136 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<div class="hierarchy w-full overflow-x-auto">
|
|
3
|
+
<OrganizationChart
|
|
4
|
+
:value="chartData"
|
|
5
|
+
collapsible
|
|
6
|
+
:selection-mode="'single'"
|
|
7
|
+
@node-select="toNode"
|
|
8
|
+
>
|
|
9
|
+
<template #thread="{ node }">
|
|
10
|
+
<span>{{ node.data.name }}</span>
|
|
11
|
+
</template>
|
|
12
|
+
|
|
13
|
+
<template #display="{ node }">
|
|
14
|
+
<div class="flex flex-col gap-2">
|
|
15
|
+
<Tag
|
|
16
|
+
:value="formattedDate(node.data.started_at)"
|
|
17
|
+
severity="secondary"
|
|
18
|
+
/>
|
|
19
|
+
<Badge :value="node.data.duration + 's'" />
|
|
20
|
+
</div>
|
|
21
|
+
</template>
|
|
22
|
+
|
|
23
|
+
<template #run="{ node }">
|
|
24
|
+
<div class="flex flex-col gap-2">
|
|
25
|
+
<AgentAvatar :agent="node.data.agent" />
|
|
26
|
+
<Tag
|
|
27
|
+
v-if="node.data.has_pending"
|
|
28
|
+
severity="warn"
|
|
29
|
+
:value="pendingType(node.data)"
|
|
30
|
+
/>
|
|
31
|
+
<Tag
|
|
32
|
+
v-else
|
|
33
|
+
severity="success"
|
|
34
|
+
value="Completed"
|
|
35
|
+
/>
|
|
36
|
+
<Tag
|
|
37
|
+
v-if="node.data.has_errors"
|
|
38
|
+
severity="danger"
|
|
39
|
+
value="Error"
|
|
40
|
+
/>
|
|
41
|
+
<Tag
|
|
42
|
+
v-else
|
|
43
|
+
severity="success"
|
|
44
|
+
value="No Errors"
|
|
45
|
+
/>
|
|
46
|
+
</div>
|
|
47
|
+
</template>
|
|
48
|
+
</OrganizationChart>
|
|
49
|
+
</div>
|
|
50
|
+
</template>
|
|
51
|
+
|
|
52
|
+
<script setup lang="ts">
|
|
53
|
+
import { format } from 'date-fns'
|
|
54
|
+
import OrganizationChart, { type OrganizationChartNode } from 'primevue/organizationchart'
|
|
55
|
+
import { computed } from 'vue'
|
|
56
|
+
|
|
57
|
+
import type { ThreadDto, DisplayStatistics, RunStatistics } from '@core/sdk/client'
|
|
58
|
+
|
|
59
|
+
// Define the props
|
|
60
|
+
const props = defineProps<{
|
|
61
|
+
thread: ThreadDto
|
|
62
|
+
}>()
|
|
63
|
+
|
|
64
|
+
const router = useRouter()
|
|
65
|
+
const tenantPath = useTenantPath()
|
|
66
|
+
const { pendingType } = useThreadUtils()
|
|
67
|
+
|
|
68
|
+
const toNode = (node: OrganizationChartNode) => {
|
|
69
|
+
let displayId: string | undefined
|
|
70
|
+
if (node.data.display_id) {
|
|
71
|
+
displayId = node.data.display_id
|
|
72
|
+
}
|
|
73
|
+
if (node.data.run_id) {
|
|
74
|
+
const display = props.thread.displays?.find((display: DisplayStatistics) => {
|
|
75
|
+
return display?.runs?.some((run: RunStatistics) => run.run_id === node.data.run_id)
|
|
76
|
+
})
|
|
77
|
+
displayId = display?.display_id
|
|
78
|
+
}
|
|
79
|
+
if (displayId) {
|
|
80
|
+
router.push(tenantPath(`/service/threads/${props.thread.id}/display/${displayId}`))
|
|
81
|
+
}
|
|
82
|
+
else {
|
|
83
|
+
router.push(tenantPath(`/service/threads/${props.thread.id}/display`))
|
|
84
|
+
}
|
|
85
|
+
}
|
|
86
|
+
|
|
87
|
+
const formattedDate = (datestr: string) => format(new Date(datestr), 'yyyy.MM.dd HH:mm')
|
|
88
|
+
|
|
89
|
+
// Computed property to transform ThreadDto into OrganizationChart data structure
|
|
90
|
+
const chartData = computed<OrganizationChartNode>(() => {
|
|
91
|
+
if (!props.thread) return {} as OrganizationChartNode
|
|
92
|
+
|
|
93
|
+
// Function to transform RunStatistics
|
|
94
|
+
const mapRun = (run: RunStatistics): OrganizationChartNode => ({
|
|
95
|
+
key: run.run_id,
|
|
96
|
+
type: 'run',
|
|
97
|
+
data: run,
|
|
98
|
+
children: [],
|
|
99
|
+
})
|
|
100
|
+
|
|
101
|
+
// Function to transform DisplayStatistics
|
|
102
|
+
const mapDisplay = (display: DisplayStatistics): OrganizationChartNode => ({
|
|
103
|
+
key: display.display_id,
|
|
104
|
+
type: 'display',
|
|
105
|
+
data: display,
|
|
106
|
+
children: (display.runs ?? []).map(mapRun),
|
|
107
|
+
})
|
|
108
|
+
|
|
109
|
+
// Transform the main thread data
|
|
110
|
+
const rootNode: OrganizationChartNode = {
|
|
111
|
+
key: props.thread.id,
|
|
112
|
+
type: 'thread',
|
|
113
|
+
data: props.thread,
|
|
114
|
+
children: (props.thread.displays ?? []).map(mapDisplay),
|
|
115
|
+
}
|
|
116
|
+
return rootNode
|
|
117
|
+
})
|
|
118
|
+
</script>
|
|
119
|
+
|
|
120
|
+
<style scoped>
|
|
121
|
+
/* Add some basic styling for better readability */
|
|
122
|
+
.hierarchy :deep(.p-organizationchart-node-content) {
|
|
123
|
+
padding: 0;
|
|
124
|
+
border: none;
|
|
125
|
+
}
|
|
126
|
+
|
|
127
|
+
.hierarchy :deep(.p-organizationchart-line-down) {
|
|
128
|
+
background-color: #adb5bd; /* primevue gray-400 */
|
|
129
|
+
}
|
|
130
|
+
.hierarchy :deep(.p-organizationchart-line-left) {
|
|
131
|
+
border-right: 1px solid #adb5bd;
|
|
132
|
+
}
|
|
133
|
+
.hierarchy :deep(.p-organizationchart-line-top) {
|
|
134
|
+
border-top: 1px solid #adb5bd;
|
|
135
|
+
}
|
|
136
|
+
</style>
|
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<div
|
|
3
|
+
class="flex flex-col gap-3"
|
|
4
|
+
>
|
|
5
|
+
<div class="flex w-full">
|
|
6
|
+
<div class="flex w-1/2 flex-col gap-2">
|
|
7
|
+
<h3 class="font-bold">
|
|
8
|
+
{{ t('thread.users') }}
|
|
9
|
+
</h3>
|
|
10
|
+
<UserAvatar
|
|
11
|
+
v-for="user in users"
|
|
12
|
+
:key="user.id"
|
|
13
|
+
:user="user"
|
|
14
|
+
/>
|
|
15
|
+
</div>
|
|
16
|
+
<div class="flex w-1/2 flex-col gap-2">
|
|
17
|
+
<h3 class="font-bold">
|
|
18
|
+
{{ t('thread.assistants') }}
|
|
19
|
+
</h3>
|
|
20
|
+
<AgentAvatar
|
|
21
|
+
v-for="agent in agents"
|
|
22
|
+
:key="agent.agent_class + agent.agent_id"
|
|
23
|
+
:agent="agent"
|
|
24
|
+
/>
|
|
25
|
+
</div>
|
|
26
|
+
</div>
|
|
27
|
+
</div>
|
|
28
|
+
</template>
|
|
29
|
+
|
|
30
|
+
<script setup lang="ts">
|
|
31
|
+
import type { MinimalAgentInstanceDto, ThreadDto, MinimalUserDto } from '@core/sdk/client'
|
|
32
|
+
|
|
33
|
+
const { t } = useI18n()
|
|
34
|
+
|
|
35
|
+
const props = defineProps<{
|
|
36
|
+
thread: ThreadDto
|
|
37
|
+
}>()
|
|
38
|
+
|
|
39
|
+
const users = computed<MinimalUserDto[]>(() => props.thread.users ?? [])
|
|
40
|
+
const agents = computed<MinimalAgentInstanceDto[]>(() => props.thread.agents ?? [])
|
|
41
|
+
</script>
|