@agent-native/toolkit 0.217.0 → 0.218.0
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/agent-native.eject.json +21 -0
- package/dist/app/agent-page/AgentContextTab.d.ts.map +1 -1
- package/dist/app/agent-page/AgentContextTab.js +1 -0
- package/dist/app/agent-page/AgentContextTab.js.map +1 -1
- package/dist/app/agentkit/react/components.d.ts.map +1 -1
- package/dist/app/agentkit/react/components.js +1 -1
- package/dist/app/agentkit/react/components.js.map +1 -1
- package/dist/app/agentkit/react/context.d.ts +4 -1
- package/dist/app/agentkit/react/context.d.ts.map +1 -1
- package/dist/app/agentkit/react/context.js +3 -1
- package/dist/app/agentkit/react/context.js.map +1 -1
- package/dist/app/agentkit/react/data-chart-layout.d.ts +30 -0
- package/dist/app/agentkit/react/data-chart-layout.d.ts.map +1 -0
- package/dist/app/agentkit/react/data-chart-layout.js +2 -0
- package/dist/app/agentkit/react/data-chart-layout.js.map +1 -0
- package/dist/app/agentkit/react/index.d.ts +1 -0
- package/dist/app/agentkit/react/index.d.ts.map +1 -1
- package/dist/app/agentkit/react/index.js +1 -0
- package/dist/app/agentkit/react/index.js.map +1 -1
- package/dist/app/agentkit/react/root.d.ts +3 -1
- package/dist/app/agentkit/react/root.d.ts.map +1 -1
- package/dist/app/agentkit/react/root.js +2 -2
- package/dist/app/agentkit/react/root.js.map +1 -1
- package/dist/app/agentkit/react/styles.css +18 -0
- package/dist/app/agentkit/react/transcript-layout.d.ts +2 -0
- package/dist/app/agentkit/react/transcript-layout.d.ts.map +1 -1
- package/dist/app/agentkit/react/transcript-layout.js.map +1 -1
- package/dist/app/chat/AgentKitAssistantChat.d.ts.map +1 -1
- package/dist/app/chat/AgentKitAssistantChat.js +2 -2
- package/dist/app/chat/AgentKitAssistantChat.js.map +1 -1
- package/dist/app/chat/MultiTabAssistantChat.d.ts.map +1 -1
- package/dist/app/chat/MultiTabAssistantChat.js +51 -93
- package/dist/app/chat/MultiTabAssistantChat.js.map +1 -1
- package/dist/app/chat/agentkit-chat/action-widget.d.ts.map +1 -1
- package/dist/app/chat/agentkit-chat/action-widget.js +3 -1
- package/dist/app/chat/agentkit-chat/action-widget.js.map +1 -1
- package/dist/app/chat/agentkit-chat/rail.d.ts +1 -1
- package/dist/app/chat/agentkit-chat/rail.d.ts.map +1 -1
- package/dist/app/chat/agentkit-chat/rail.js +1 -1
- package/dist/app/chat/agentkit-chat/rail.js.map +1 -1
- package/dist/app/chat/chat/index.d.ts +2 -1
- package/dist/app/chat/chat/index.d.ts.map +1 -1
- package/dist/app/chat/chat/index.js +1 -1
- package/dist/app/chat/chat/index.js.map +1 -1
- package/dist/app/chat/chat/surface-types.d.ts +3 -0
- package/dist/app/chat/chat/surface-types.d.ts.map +1 -1
- package/dist/app/chat/chat/surface-types.js.map +1 -1
- package/dist/app/chat/chat/tool-call-display.d.ts +3 -1
- package/dist/app/chat/chat/tool-call-display.d.ts.map +1 -1
- package/dist/app/chat/chat/tool-call-display.js +4 -3
- package/dist/app/chat/chat/tool-call-display.js.map +1 -1
- package/dist/app/chat/chat/tool-render-registry.d.ts +2 -0
- package/dist/app/chat/chat/tool-render-registry.d.ts.map +1 -1
- package/dist/app/chat/chat/tool-render-registry.js.map +1 -1
- package/dist/app/chat/chat/widgets/DataChartRenderer.d.ts +3 -1
- package/dist/app/chat/chat/widgets/DataChartRenderer.d.ts.map +1 -1
- package/dist/app/chat/chat/widgets/DataChartRenderer.js +116 -26
- package/dist/app/chat/chat/widgets/DataChartRenderer.js.map +1 -1
- package/dist/app/chat/chat/widgets/DataChartWidget.d.ts +3 -1
- package/dist/app/chat/chat/widgets/DataChartWidget.d.ts.map +1 -1
- package/dist/app/chat/chat/widgets/DataChartWidget.js +21 -2
- package/dist/app/chat/chat/widgets/DataChartWidget.js.map +1 -1
- package/dist/app/chat/chat/widgets/DataInsightsWidget.d.ts +3 -1
- package/dist/app/chat/chat/widgets/DataInsightsWidget.d.ts.map +1 -1
- package/dist/app/chat/chat/widgets/DataInsightsWidget.js +2 -2
- package/dist/app/chat/chat/widgets/DataInsightsWidget.js.map +1 -1
- package/dist/app/chat/chat/widgets/DataWidgetDisplayControls.d.ts +1 -1
- package/dist/app/chat/chat/widgets/DataWidgetDisplayControls.d.ts.map +1 -1
- package/dist/app/chat/chat/widgets/DataWidgetDisplayControls.js +3 -1
- package/dist/app/chat/chat/widgets/DataWidgetDisplayControls.js.map +1 -1
- package/dist/app/chat/chat/widgets/builtin-tool-renderers.d.ts.map +1 -1
- package/dist/app/chat/chat/widgets/builtin-tool-renderers.js +2 -2
- package/dist/app/chat/chat/widgets/builtin-tool-renderers.js.map +1 -1
- package/dist/app/chat/chat-first/chat-history.d.ts +13 -2
- package/dist/app/chat/chat-first/chat-history.d.ts.map +1 -1
- package/dist/app/chat/chat-first/chat-history.js +24 -3
- package/dist/app/chat/chat-first/chat-history.js.map +1 -1
- package/dist/app/chat/ownership-history/ChatOwnerAvatar.d.ts +6 -0
- package/dist/app/chat/ownership-history/ChatOwnerAvatar.d.ts.map +1 -0
- package/dist/app/chat/ownership-history/ChatOwnerAvatar.js +9 -0
- package/dist/app/chat/ownership-history/ChatOwnerAvatar.js.map +1 -0
- package/dist/app/chat/ownership-history/index.d.ts +11 -0
- package/dist/app/chat/ownership-history/index.d.ts.map +1 -0
- package/dist/app/chat/ownership-history/index.js +22 -0
- package/dist/app/chat/ownership-history/index.js.map +1 -0
- package/dist/app/chat/ownership-history/rows.d.ts +27 -0
- package/dist/app/chat/ownership-history/rows.d.ts.map +1 -0
- package/dist/app/chat/ownership-history/rows.js +101 -0
- package/dist/app/chat/ownership-history/rows.js.map +1 -0
- package/dist/app/chat/ownership-history/useOwnershipChatHistory.d.ts +52 -0
- package/dist/app/chat/ownership-history/useOwnershipChatHistory.d.ts.map +1 -0
- package/dist/app/chat/ownership-history/useOwnershipChatHistory.js +497 -0
- package/dist/app/chat/ownership-history/useOwnershipChatHistory.js.map +1 -0
- package/dist/app/i18n/catalogs/ar-SA.d.ts.map +1 -1
- package/dist/app/i18n/catalogs/ar-SA.js +3 -0
- package/dist/app/i18n/catalogs/ar-SA.js.map +1 -1
- package/dist/app/i18n/catalogs/de-DE.d.ts.map +1 -1
- package/dist/app/i18n/catalogs/de-DE.js +3 -0
- package/dist/app/i18n/catalogs/de-DE.js.map +1 -1
- package/dist/app/i18n/catalogs/en-US.d.ts +3 -0
- package/dist/app/i18n/catalogs/en-US.d.ts.map +1 -1
- package/dist/app/i18n/catalogs/en-US.js +3 -0
- package/dist/app/i18n/catalogs/en-US.js.map +1 -1
- package/dist/app/i18n/catalogs/es-ES.d.ts.map +1 -1
- package/dist/app/i18n/catalogs/es-ES.js +3 -0
- package/dist/app/i18n/catalogs/es-ES.js.map +1 -1
- package/dist/app/i18n/catalogs/fr-FR.d.ts.map +1 -1
- package/dist/app/i18n/catalogs/fr-FR.js +3 -0
- package/dist/app/i18n/catalogs/fr-FR.js.map +1 -1
- package/dist/app/i18n/catalogs/hi-IN.d.ts.map +1 -1
- package/dist/app/i18n/catalogs/hi-IN.js +3 -0
- package/dist/app/i18n/catalogs/hi-IN.js.map +1 -1
- package/dist/app/i18n/catalogs/ja-JP.d.ts.map +1 -1
- package/dist/app/i18n/catalogs/ja-JP.js +3 -0
- package/dist/app/i18n/catalogs/ja-JP.js.map +1 -1
- package/dist/app/i18n/catalogs/ko-KR.d.ts.map +1 -1
- package/dist/app/i18n/catalogs/ko-KR.js +3 -0
- package/dist/app/i18n/catalogs/ko-KR.js.map +1 -1
- package/dist/app/i18n/catalogs/pt-BR.d.ts.map +1 -1
- package/dist/app/i18n/catalogs/pt-BR.js +3 -0
- package/dist/app/i18n/catalogs/pt-BR.js.map +1 -1
- package/dist/app/i18n/catalogs/zh-CN.d.ts.map +1 -1
- package/dist/app/i18n/catalogs/zh-CN.js +3 -0
- package/dist/app/i18n/catalogs/zh-CN.js.map +1 -1
- package/dist/app/i18n/catalogs/zh-TW.d.ts.map +1 -1
- package/dist/app/i18n/catalogs/zh-TW.js +3 -0
- package/dist/app/i18n/catalogs/zh-TW.js.map +1 -1
- package/dist/app/sharing/ShareButton.d.ts.map +1 -1
- package/dist/app/sharing/ShareButton.js +9 -8
- package/dist/app/sharing/ShareButton.js.map +1 -1
- package/dist/chat-history/ChatHistoryList.d.ts +16 -3
- package/dist/chat-history/ChatHistoryList.d.ts.map +1 -1
- package/dist/chat-history/ChatHistoryList.js +25 -15
- package/dist/chat-history/ChatHistoryList.js.map +1 -1
- package/dist/chat-history.css +109 -9
- package/package.json +10 -3
- package/src/app/agent-page/AgentContextTab.spec.ts +50 -2
- package/src/app/agent-page/AgentContextTab.tsx +1 -0
- package/src/app/agentkit/react/components.interaction.spec.tsx +2 -0
- package/src/app/agentkit/react/components.spec.tsx +4 -1
- package/src/app/agentkit/react/components.tsx +3 -0
- package/src/app/agentkit/react/context.tsx +6 -0
- package/src/app/agentkit/react/data-chart-layout.ts +25 -0
- package/src/app/agentkit/react/index.ts +1 -0
- package/src/app/agentkit/react/root.tsx +4 -0
- package/src/app/agentkit/react/styles.css +18 -0
- package/src/app/agentkit/react/transcript-layout.ts +2 -0
- package/src/app/chat/AgentKitAssistantChat.tsx +2 -0
- package/src/app/chat/MultiTabAssistantChat.spec.tsx +270 -3
- package/src/app/chat/MultiTabAssistantChat.tsx +79 -156
- package/src/app/chat/agentkit-chat/action-widget.tsx +3 -0
- package/src/app/chat/agentkit-chat/rail.ts +11 -0
- package/src/app/chat/chat/index.ts +10 -0
- package/src/app/chat/chat/surface-types.ts +3 -0
- package/src/app/chat/chat/tool-call-display.spec.tsx +29 -0
- package/src/app/chat/chat/tool-call-display.tsx +7 -0
- package/src/app/chat/chat/tool-render-registry.tsx +3 -0
- package/src/app/chat/chat/widgets/DataChartRenderer.spec.tsx +377 -17
- package/src/app/chat/chat/widgets/DataChartRenderer.tsx +232 -63
- package/src/app/chat/chat/widgets/DataChartWidget.spec.tsx +67 -0
- package/src/app/chat/chat/widgets/DataChartWidget.tsx +39 -5
- package/src/app/chat/chat/widgets/DataInsightsWidget.tsx +13 -2
- package/src/app/chat/chat/widgets/DataWidgetDisplayControls.tsx +6 -4
- package/src/app/chat/chat/widgets/builtin-tool-renderers.tsx +5 -1
- package/src/app/chat/chat-first/chat-history.spec.tsx +79 -0
- package/src/app/chat/chat-first/chat-history.tsx +75 -22
- package/src/app/chat/ownership-history/ChatOwnerAvatar.tsx +27 -0
- package/src/app/chat/ownership-history/index.tsx +67 -0
- package/src/app/chat/ownership-history/ownership-history.spec.tsx +3146 -0
- package/src/app/chat/ownership-history/rows.ts +156 -0
- package/src/app/chat/ownership-history/useOwnershipChatHistory.ts +709 -0
- package/src/app/i18n/catalogs/ar-SA.ts +3 -0
- package/src/app/i18n/catalogs/de-DE.ts +3 -0
- package/src/app/i18n/catalogs/en-US.ts +3 -0
- package/src/app/i18n/catalogs/es-ES.ts +3 -0
- package/src/app/i18n/catalogs/fr-FR.ts +3 -0
- package/src/app/i18n/catalogs/hi-IN.ts +3 -0
- package/src/app/i18n/catalogs/ja-JP.ts +3 -0
- package/src/app/i18n/catalogs/ko-KR.ts +3 -0
- package/src/app/i18n/catalogs/pt-BR.ts +3 -0
- package/src/app/i18n/catalogs/zh-CN.ts +3 -0
- package/src/app/i18n/catalogs/zh-TW.ts +3 -0
- package/src/app/sharing/ShareButton.tsx +12 -10
- package/src/chat-history/ChatHistoryList.spec.tsx +51 -0
- package/src/chat-history/ChatHistoryList.tsx +87 -26
- package/src/chat-history/ChatHistoryRailSections.spec.tsx +12 -4
- package/src/chat-history.css +109 -9
|
@@ -480,6 +480,9 @@ const messages: ToolkitAgentChatTranslation = {
|
|
|
480
480
|
"history.ownedBy": "Eigentümer: {{name}}",
|
|
481
481
|
"history.accessDirect": "Mit dir geteilt",
|
|
482
482
|
"history.accessOrganization": "Mit deiner Organisation geteilt",
|
|
483
|
+
"history.copyLink": "Link kopieren",
|
|
484
|
+
"history.linkCopied": "Link kopiert",
|
|
485
|
+
"history.copyLinkFailed": "Link konnte nicht kopiert werden",
|
|
483
486
|
"integrations.availableSection": "Verfügbare Integrationen",
|
|
484
487
|
"integrations.connectedSection": "Verbunden",
|
|
485
488
|
"integrations.goToApiKeys": "Zu den API-Schlüsseln",
|
|
@@ -769,6 +769,9 @@ const messages = {
|
|
|
769
769
|
"history.ownedBy": "Owner: {{name}}",
|
|
770
770
|
"history.accessDirect": "Shared with you",
|
|
771
771
|
"history.accessOrganization": "Shared with your organization",
|
|
772
|
+
"history.copyLink": "Copy link",
|
|
773
|
+
"history.linkCopied": "Link copied",
|
|
774
|
+
"history.copyLinkFailed": "Couldn't copy the link",
|
|
772
775
|
"integrations.availableSection": "Available integrations",
|
|
773
776
|
"integrations.connectedSection": "Connected",
|
|
774
777
|
"integrations.goToApiKeys": "Go to API keys",
|
|
@@ -479,6 +479,9 @@ const messages: ToolkitAgentChatTranslation = {
|
|
|
479
479
|
"history.ownedBy": "Propietario: {{name}}",
|
|
480
480
|
"history.accessDirect": "Compartidos contigo",
|
|
481
481
|
"history.accessOrganization": "Compartido con tu organización",
|
|
482
|
+
"history.copyLink": "Copiar enlace",
|
|
483
|
+
"history.linkCopied": "Enlace copiado",
|
|
484
|
+
"history.copyLinkFailed": "No se pudo copiar el enlace",
|
|
482
485
|
"integrations.availableSection": "Integraciones disponibles",
|
|
483
486
|
"integrations.connectedSection": "Conectado",
|
|
484
487
|
"integrations.goToApiKeys": "Ir a claves de API",
|
|
@@ -478,6 +478,9 @@ const messages: ToolkitAgentChatTranslation = {
|
|
|
478
478
|
"history.ownedBy": "Propriétaire : {{name}}",
|
|
479
479
|
"history.accessDirect": "Partagés avec vous",
|
|
480
480
|
"history.accessOrganization": "Partagé avec votre organisation",
|
|
481
|
+
"history.copyLink": "Copier le lien",
|
|
482
|
+
"history.linkCopied": "Lien copié",
|
|
483
|
+
"history.copyLinkFailed": "Impossible de copier le lien",
|
|
481
484
|
"integrations.availableSection": "Intégrations disponibles",
|
|
482
485
|
"integrations.connectedSection": "Connecté",
|
|
483
486
|
"integrations.goToApiKeys": "Aller aux clés API",
|
|
@@ -759,6 +759,9 @@ const messages: ToolkitAgentChatTranslation = {
|
|
|
759
759
|
"history.ownedBy": "मालिक: {{name}}",
|
|
760
760
|
"history.accessDirect": "आपके साथ साझा",
|
|
761
761
|
"history.accessOrganization": "आपके संगठन के साथ साझा",
|
|
762
|
+
"history.copyLink": "लिंक कॉपी करें",
|
|
763
|
+
"history.linkCopied": "लिंक कॉपी हो गया",
|
|
764
|
+
"history.copyLinkFailed": "लिंक कॉपी नहीं हो सका",
|
|
762
765
|
"integrations.availableSection": "उपलब्ध इंटीग्रेशन",
|
|
763
766
|
"integrations.connectedSection": "कनेक्ट किए गए",
|
|
764
767
|
"integrations.goToApiKeys": "API कुंजियों पर जाएं",
|
|
@@ -783,6 +783,9 @@ const messages: ToolkitAgentChatTranslation = {
|
|
|
783
783
|
"history.ownedBy": "所有者: {{name}}",
|
|
784
784
|
"history.accessDirect": "共有されたチャット",
|
|
785
785
|
"history.accessOrganization": "組織と共有",
|
|
786
|
+
"history.copyLink": "リンクをコピー",
|
|
787
|
+
"history.linkCopied": "リンクをコピーしました",
|
|
788
|
+
"history.copyLinkFailed": "リンクをコピーできませんでした",
|
|
786
789
|
"integrations.availableSection": "利用可能な連携",
|
|
787
790
|
"integrations.connectedSection": "接続済み",
|
|
788
791
|
"integrations.goToApiKeys": "API キーへ移動",
|
|
@@ -762,6 +762,9 @@ const messages: ToolkitAgentChatTranslation = {
|
|
|
762
762
|
"history.ownedBy": "소유자: {{name}}",
|
|
763
763
|
"history.accessDirect": "나와 공유된 채팅",
|
|
764
764
|
"history.accessOrganization": "조직과 공유됨",
|
|
765
|
+
"history.copyLink": "링크 복사",
|
|
766
|
+
"history.linkCopied": "링크를 복사했어요",
|
|
767
|
+
"history.copyLinkFailed": "링크를 복사하지 못했어요",
|
|
765
768
|
"integrations.availableSection": "사용 가능한 연동",
|
|
766
769
|
"integrations.connectedSection": "연결됨",
|
|
767
770
|
"integrations.goToApiKeys": "API 키로 이동",
|
|
@@ -473,6 +473,9 @@ const messages: ToolkitAgentChatTranslation = {
|
|
|
473
473
|
"history.ownedBy": "Proprietário: {{name}}",
|
|
474
474
|
"history.accessDirect": "Compartilhados com você",
|
|
475
475
|
"history.accessOrganization": "Compartilhado com sua organização",
|
|
476
|
+
"history.copyLink": "Copiar link",
|
|
477
|
+
"history.linkCopied": "Link copiado",
|
|
478
|
+
"history.copyLinkFailed": "Não foi possível copiar o link",
|
|
476
479
|
"integrations.availableSection": "Integrações disponíveis",
|
|
477
480
|
"integrations.connectedSection": "Conectado",
|
|
478
481
|
"integrations.goToApiKeys": "Ir para chaves de API",
|
|
@@ -726,6 +726,9 @@ const messages: ToolkitAgentChatTranslation = {
|
|
|
726
726
|
"history.ownedBy": "所有者:{{name}}",
|
|
727
727
|
"history.accessDirect": "与您共享",
|
|
728
728
|
"history.accessOrganization": "与您的组织共享",
|
|
729
|
+
"history.copyLink": "复制链接",
|
|
730
|
+
"history.linkCopied": "链接已复制",
|
|
731
|
+
"history.copyLinkFailed": "无法复制链接",
|
|
729
732
|
"integrations.availableSection": "可用集成",
|
|
730
733
|
"integrations.connectedSection": "已连接",
|
|
731
734
|
"integrations.goToApiKeys": "前往 API 密钥",
|
|
@@ -728,6 +728,9 @@ const messages: ToolkitAgentChatTranslation = {
|
|
|
728
728
|
"history.ownedBy": "擁有者:{{name}}",
|
|
729
729
|
"history.accessDirect": "與您共用",
|
|
730
730
|
"history.accessOrganization": "與您的組織共用",
|
|
731
|
+
"history.copyLink": "複製連結",
|
|
732
|
+
"history.linkCopied": "已複製連結",
|
|
733
|
+
"history.copyLinkFailed": "無法複製連結",
|
|
731
734
|
"integrations.availableSection": "可用整合",
|
|
732
735
|
"integrations.connectedSection": "已連線",
|
|
733
736
|
"integrations.goToApiKeys": "前往 API 金鑰",
|
|
@@ -1150,6 +1150,12 @@ function MemberAutocomplete({
|
|
|
1150
1150
|
activeIndex >= 0 && activeIndex < suggestions.length
|
|
1151
1151
|
? suggestions[activeIndex]
|
|
1152
1152
|
: null;
|
|
1153
|
+
const listOpen =
|
|
1154
|
+
open &&
|
|
1155
|
+
(suggestions.length > 0 ||
|
|
1156
|
+
search.isLoading ||
|
|
1157
|
+
Boolean(search.error) ||
|
|
1158
|
+
value.trim().length > 0);
|
|
1153
1159
|
|
|
1154
1160
|
useEffect(() => {
|
|
1155
1161
|
setActiveIndex(-1);
|
|
@@ -1230,7 +1236,7 @@ function MemberAutocomplete({
|
|
|
1230
1236
|
};
|
|
1231
1237
|
|
|
1232
1238
|
return (
|
|
1233
|
-
<Popover open={
|
|
1239
|
+
<Popover open={listOpen} onOpenChange={onOpenChange}>
|
|
1234
1240
|
<PopoverAnchor asChild>
|
|
1235
1241
|
<div className="flex h-9 min-w-0 flex-1 items-center overflow-hidden rounded-md border border-input bg-card focus-within:ring-1 focus-within:ring-ring">
|
|
1236
1242
|
<input
|
|
@@ -1238,8 +1244,8 @@ function MemberAutocomplete({
|
|
|
1238
1244
|
type="text"
|
|
1239
1245
|
role="combobox"
|
|
1240
1246
|
aria-autocomplete="list"
|
|
1241
|
-
aria-expanded={
|
|
1242
|
-
aria-controls={
|
|
1247
|
+
aria-expanded={listOpen}
|
|
1248
|
+
aria-controls={listOpen ? listboxId : undefined}
|
|
1243
1249
|
aria-activedescendant={
|
|
1244
1250
|
activeIndex >= 0 ? optionId(listboxId, activeIndex) : undefined
|
|
1245
1251
|
}
|
|
@@ -1361,13 +1367,9 @@ function MemberAutocomplete({
|
|
|
1361
1367
|
|
|
1362
1368
|
{!search.isLoading && !search.error && suggestions.length === 0 ? (
|
|
1363
1369
|
<div className="px-3 py-3 text-sm text-muted-foreground">
|
|
1364
|
-
{
|
|
1365
|
-
|
|
1366
|
-
|
|
1367
|
-
})
|
|
1368
|
-
: t("agentChat.share.noPeopleFound", {
|
|
1369
|
-
defaultValue: "No people found.",
|
|
1370
|
-
})}
|
|
1370
|
+
{t("agentChat.share.noMatches", {
|
|
1371
|
+
defaultValue: "No matches.",
|
|
1372
|
+
})}
|
|
1371
1373
|
</div>
|
|
1372
1374
|
) : null}
|
|
1373
1375
|
|
|
@@ -635,4 +635,55 @@ describe("ChatHistoryList", () => {
|
|
|
635
635
|
});
|
|
636
636
|
expect(container.querySelector(".an-chat-history-row__menu")).toBeNull();
|
|
637
637
|
});
|
|
638
|
+
|
|
639
|
+
it("keeps a read-only row to its owner header and Copy link", async () => {
|
|
640
|
+
const onCopyLink = vi.fn();
|
|
641
|
+
const onDelete = vi.fn();
|
|
642
|
+
act(() => {
|
|
643
|
+
root.render(
|
|
644
|
+
<ChatHistoryList
|
|
645
|
+
items={[
|
|
646
|
+
item({
|
|
647
|
+
id: "shared",
|
|
648
|
+
readOnly: true,
|
|
649
|
+
ownerAvatar: <span data-testid="avatar">P</span>,
|
|
650
|
+
ownerLabel: "pat@example.com",
|
|
651
|
+
accessLabel: "Shared with your organization",
|
|
652
|
+
accessBasis: "organization",
|
|
653
|
+
}),
|
|
654
|
+
]}
|
|
655
|
+
onSelect={() => {}}
|
|
656
|
+
onRename={() => {}}
|
|
657
|
+
onDelete={onDelete}
|
|
658
|
+
onTogglePin={() => {}}
|
|
659
|
+
onCopyLink={onCopyLink}
|
|
660
|
+
/>,
|
|
661
|
+
);
|
|
662
|
+
});
|
|
663
|
+
|
|
664
|
+
const row = container.querySelector<HTMLElement>(".an-chat-history-row")!;
|
|
665
|
+
const mark = row.querySelector(".an-chat-history-row__owner-mark");
|
|
666
|
+
expect(mark?.getAttribute("data-access-basis")).toBe("organization");
|
|
667
|
+
expect(mark?.querySelector("[data-testid='avatar']")).not.toBeNull();
|
|
668
|
+
expect(
|
|
669
|
+
row.querySelector(".an-chat-history-row__topline")?.textContent,
|
|
670
|
+
).toBe("sharedP");
|
|
671
|
+
|
|
672
|
+
await openMenu(
|
|
673
|
+
row.querySelector<HTMLButtonElement>(
|
|
674
|
+
".an-chat-history-row__menu-trigger",
|
|
675
|
+
)!,
|
|
676
|
+
);
|
|
677
|
+
expect(
|
|
678
|
+
document.body.querySelector(".an-chat-history-row__menu-owner")
|
|
679
|
+
?.textContent,
|
|
680
|
+
).toBe("Ppat@example.comShared with your organization");
|
|
681
|
+
expect(getMenuItems().map((element) => element.textContent)).toEqual([
|
|
682
|
+
"Copy link",
|
|
683
|
+
]);
|
|
684
|
+
|
|
685
|
+
act(() => getMenuItems()[0]?.click());
|
|
686
|
+
expect(onCopyLink).toHaveBeenCalledWith("shared");
|
|
687
|
+
expect(onDelete).not.toHaveBeenCalled();
|
|
688
|
+
});
|
|
638
689
|
});
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import * as DropdownMenuPrimitive from "@radix-ui/react-dropdown-menu";
|
|
2
2
|
import {
|
|
3
3
|
IconDots,
|
|
4
|
+
IconLink,
|
|
4
5
|
IconPencil,
|
|
5
6
|
IconPinned,
|
|
6
7
|
IconPinnedOff,
|
|
@@ -9,7 +10,7 @@ import {
|
|
|
9
10
|
} from "@tabler/icons-react";
|
|
10
11
|
import React, { useMemo, useRef, useState } from "react";
|
|
11
12
|
|
|
12
|
-
import { Skeleton } from "../design-system/components.js";
|
|
13
|
+
import { Skeleton, Tooltip } from "../design-system/components.js";
|
|
13
14
|
import { cn } from "../utils.js";
|
|
14
15
|
|
|
15
16
|
/** How the viewer got access to a chat; the app supplies the translated copy. */
|
|
@@ -25,7 +26,12 @@ export interface ChatHistoryItem {
|
|
|
25
26
|
titleText?: string;
|
|
26
27
|
subtitle?: React.ReactNode;
|
|
27
28
|
detail?: React.ReactNode;
|
|
28
|
-
/**
|
|
29
|
+
/**
|
|
30
|
+
* A shared row's owner mark, kept on one line beside the timestamp. Hovering
|
|
31
|
+
* it shows `ownerLabel` and `accessLabel`, which also head the row menu.
|
|
32
|
+
*/
|
|
33
|
+
ownerAvatar?: React.ReactNode;
|
|
34
|
+
/** Already-translated owner name for a shared row. */
|
|
29
35
|
ownerLabel?: React.ReactNode;
|
|
30
36
|
/** Already-translated access description, e.g. "Shared with you". */
|
|
31
37
|
accessLabel?: React.ReactNode;
|
|
@@ -33,9 +39,14 @@ export interface ChatHistoryItem {
|
|
|
33
39
|
timestamp?: React.ReactNode;
|
|
34
40
|
pinned?: boolean;
|
|
35
41
|
disabled?: boolean;
|
|
42
|
+
/**
|
|
43
|
+
* The viewer can open the chat but not rename, pin or delete it, e.g. a chat
|
|
44
|
+
* someone shared. The menu keeps the owner header and Copy link.
|
|
45
|
+
*/
|
|
46
|
+
readOnly?: boolean;
|
|
36
47
|
/**
|
|
37
48
|
* Presentation only: drops the row menu and context menu while the row stays
|
|
38
|
-
* selectable.
|
|
49
|
+
* selectable, e.g. for a draft that has not been saved yet.
|
|
39
50
|
*/
|
|
40
51
|
hideActions?: boolean;
|
|
41
52
|
}
|
|
@@ -59,6 +70,7 @@ export interface ChatHistoryListLabels {
|
|
|
59
70
|
rename: string;
|
|
60
71
|
pin: string;
|
|
61
72
|
unpin: string;
|
|
73
|
+
copyLink: string;
|
|
62
74
|
delete: string;
|
|
63
75
|
}
|
|
64
76
|
|
|
@@ -72,6 +84,8 @@ export interface ChatHistoryListProps {
|
|
|
72
84
|
onRename?: (id: string, nextTitle: string) => void;
|
|
73
85
|
renameMaxLength?: number;
|
|
74
86
|
onDelete?: (id: string) => void;
|
|
87
|
+
/** Shown on every row, read-only ones included. */
|
|
88
|
+
onCopyLink?: (id: string) => void;
|
|
75
89
|
renderRowActions?: (item: ChatHistoryItem) => React.ReactNode;
|
|
76
90
|
renderAdditionalRowActions?: (
|
|
77
91
|
item: ChatHistoryItem,
|
|
@@ -104,6 +118,7 @@ const DEFAULT_LABELS: ChatHistoryListLabels = {
|
|
|
104
118
|
rename: "Rename",
|
|
105
119
|
pin: "Pin to top",
|
|
106
120
|
unpin: "Unpin from top",
|
|
121
|
+
copyLink: "Copy link",
|
|
107
122
|
delete: "Delete",
|
|
108
123
|
};
|
|
109
124
|
|
|
@@ -117,6 +132,7 @@ export function ChatHistoryList({
|
|
|
117
132
|
onRename,
|
|
118
133
|
renameMaxLength,
|
|
119
134
|
onDelete,
|
|
135
|
+
onCopyLink,
|
|
120
136
|
renderRowActions,
|
|
121
137
|
renderAdditionalRowActions,
|
|
122
138
|
searchValue,
|
|
@@ -141,9 +157,11 @@ export function ChatHistoryList({
|
|
|
141
157
|
rename: labels?.rename ?? DEFAULT_LABELS.rename,
|
|
142
158
|
pin: labels?.pin ?? DEFAULT_LABELS.pin,
|
|
143
159
|
unpin: labels?.unpin ?? DEFAULT_LABELS.unpin,
|
|
160
|
+
copyLink: labels?.copyLink ?? DEFAULT_LABELS.copyLink,
|
|
144
161
|
delete: labels?.delete ?? DEFAULT_LABELS.delete,
|
|
145
162
|
}),
|
|
146
163
|
[
|
|
164
|
+
labels?.copyLink,
|
|
147
165
|
labels?.delete,
|
|
148
166
|
labels?.options,
|
|
149
167
|
labels?.pin,
|
|
@@ -252,6 +270,7 @@ export function ChatHistoryList({
|
|
|
252
270
|
onRename={onRename}
|
|
253
271
|
renameMaxLength={renameMaxLength}
|
|
254
272
|
onDelete={onDelete}
|
|
273
|
+
onCopyLink={onCopyLink}
|
|
255
274
|
renderRowActions={renderRowActions}
|
|
256
275
|
renderAdditionalRowActions={renderAdditionalRowActions}
|
|
257
276
|
labels={resolvedLabels}
|
|
@@ -289,6 +308,7 @@ type ChatHistoryRowProps = {
|
|
|
289
308
|
onRename?: (id: string, nextTitle: string) => void;
|
|
290
309
|
renameMaxLength?: number;
|
|
291
310
|
onDelete?: (id: string) => void;
|
|
311
|
+
onCopyLink?: (id: string) => void;
|
|
292
312
|
renderRowActions?: (item: ChatHistoryItem) => React.ReactNode;
|
|
293
313
|
renderAdditionalRowActions?: (
|
|
294
314
|
item: ChatHistoryItem,
|
|
@@ -297,6 +317,21 @@ type ChatHistoryRowProps = {
|
|
|
297
317
|
labels: ChatHistoryListLabels;
|
|
298
318
|
};
|
|
299
319
|
|
|
320
|
+
function ChatHistoryOwnerSummary({ item }: { item: ChatHistoryItem }) {
|
|
321
|
+
return (
|
|
322
|
+
<span className="an-chat-history-owner">
|
|
323
|
+
{item.ownerLabel != null && (
|
|
324
|
+
<span className="an-chat-history-owner__name">{item.ownerLabel}</span>
|
|
325
|
+
)}
|
|
326
|
+
{item.accessLabel != null && (
|
|
327
|
+
<span className="an-chat-history-owner__access">
|
|
328
|
+
{item.accessLabel}
|
|
329
|
+
</span>
|
|
330
|
+
)}
|
|
331
|
+
</span>
|
|
332
|
+
);
|
|
333
|
+
}
|
|
334
|
+
|
|
300
335
|
const ChatHistoryRow = React.memo(function ChatHistoryRow({
|
|
301
336
|
item,
|
|
302
337
|
active,
|
|
@@ -306,6 +341,7 @@ const ChatHistoryRow = React.memo(function ChatHistoryRow({
|
|
|
306
341
|
onRename,
|
|
307
342
|
renameMaxLength,
|
|
308
343
|
onDelete,
|
|
344
|
+
onCopyLink,
|
|
309
345
|
renderRowActions,
|
|
310
346
|
renderAdditionalRowActions,
|
|
311
347
|
labels,
|
|
@@ -315,12 +351,13 @@ const ChatHistoryRow = React.memo(function ChatHistoryRow({
|
|
|
315
351
|
const [menuOpen, setMenuOpen] = useState(false);
|
|
316
352
|
const renameInputRef = useRef<HTMLInputElement | null>(null);
|
|
317
353
|
|
|
354
|
+
const editable = !item.readOnly;
|
|
355
|
+
const hasOwner = item.ownerLabel != null || item.accessLabel != null;
|
|
318
356
|
const hasMenu =
|
|
319
357
|
!item.hideActions &&
|
|
320
358
|
Boolean(
|
|
321
|
-
onTogglePin ||
|
|
322
|
-
|
|
323
|
-
onDelete ||
|
|
359
|
+
(editable && (onTogglePin || onRename || onDelete)) ||
|
|
360
|
+
onCopyLink ||
|
|
324
361
|
renderRowActions ||
|
|
325
362
|
renderAdditionalRowActions,
|
|
326
363
|
);
|
|
@@ -402,6 +439,22 @@ const ChatHistoryRow = React.memo(function ChatHistoryRow({
|
|
|
402
439
|
>
|
|
403
440
|
<div className="an-chat-history-row__topline">
|
|
404
441
|
<span className="an-chat-history-row__title">{item.title}</span>
|
|
442
|
+
{item.ownerAvatar != null && (
|
|
443
|
+
<Tooltip
|
|
444
|
+
trigger={
|
|
445
|
+
<span
|
|
446
|
+
className="an-chat-history-row__owner-mark"
|
|
447
|
+
data-access-basis={item.accessBasis}
|
|
448
|
+
>
|
|
449
|
+
{item.ownerAvatar}
|
|
450
|
+
</span>
|
|
451
|
+
}
|
|
452
|
+
content={
|
|
453
|
+
hasOwner ? <ChatHistoryOwnerSummary item={item} /> : null
|
|
454
|
+
}
|
|
455
|
+
disabled={!hasOwner}
|
|
456
|
+
/>
|
|
457
|
+
)}
|
|
405
458
|
{item.timestamp != null && (
|
|
406
459
|
<span className="an-chat-history-row__timestamp">
|
|
407
460
|
{item.timestamp}
|
|
@@ -414,23 +467,6 @@ const ChatHistoryRow = React.memo(function ChatHistoryRow({
|
|
|
414
467
|
{item.detail != null && (
|
|
415
468
|
<div className="an-chat-history-row__detail">{item.detail}</div>
|
|
416
469
|
)}
|
|
417
|
-
{(item.ownerLabel != null || item.accessLabel != null) && (
|
|
418
|
-
<div
|
|
419
|
-
className="an-chat-history-row__access"
|
|
420
|
-
data-access-basis={item.accessBasis}
|
|
421
|
-
>
|
|
422
|
-
{item.ownerLabel != null && (
|
|
423
|
-
<span className="an-chat-history-row__owner">
|
|
424
|
-
{item.ownerLabel}
|
|
425
|
-
</span>
|
|
426
|
-
)}
|
|
427
|
-
{item.accessLabel != null && (
|
|
428
|
-
<span className="an-chat-history-row__access-label">
|
|
429
|
-
{item.accessLabel}
|
|
430
|
-
</span>
|
|
431
|
-
)}
|
|
432
|
-
</div>
|
|
433
|
-
)}
|
|
434
470
|
</button>
|
|
435
471
|
)}
|
|
436
472
|
|
|
@@ -463,11 +499,22 @@ const ChatHistoryRow = React.memo(function ChatHistoryRow({
|
|
|
463
499
|
side="bottom"
|
|
464
500
|
sideOffset={4}
|
|
465
501
|
>
|
|
502
|
+
{hasOwner && (
|
|
503
|
+
<div
|
|
504
|
+
className="an-chat-history-row__menu-owner"
|
|
505
|
+
data-access-basis={item.accessBasis}
|
|
506
|
+
>
|
|
507
|
+
{item.ownerAvatar != null && (
|
|
508
|
+
<span aria-hidden="true">{item.ownerAvatar}</span>
|
|
509
|
+
)}
|
|
510
|
+
<ChatHistoryOwnerSummary item={item} />
|
|
511
|
+
</div>
|
|
512
|
+
)}
|
|
466
513
|
{renderRowActions ? (
|
|
467
514
|
renderRowActions(item)
|
|
468
515
|
) : (
|
|
469
516
|
<>
|
|
470
|
-
{onRename && (
|
|
517
|
+
{editable && onRename && (
|
|
471
518
|
<button
|
|
472
519
|
type="button"
|
|
473
520
|
role="menuitem"
|
|
@@ -478,7 +525,7 @@ const ChatHistoryRow = React.memo(function ChatHistoryRow({
|
|
|
478
525
|
<span>{labels.rename}</span>
|
|
479
526
|
</button>
|
|
480
527
|
)}
|
|
481
|
-
{onTogglePin && (
|
|
528
|
+
{editable && onTogglePin && (
|
|
482
529
|
<button
|
|
483
530
|
type="button"
|
|
484
531
|
role="menuitem"
|
|
@@ -496,10 +543,24 @@ const ChatHistoryRow = React.memo(function ChatHistoryRow({
|
|
|
496
543
|
<span>{item.pinned ? labels.unpin : labels.pin}</span>
|
|
497
544
|
</button>
|
|
498
545
|
)}
|
|
546
|
+
{onCopyLink && (
|
|
547
|
+
<button
|
|
548
|
+
type="button"
|
|
549
|
+
role="menuitem"
|
|
550
|
+
className="an-chat-history-row__menu-item"
|
|
551
|
+
onClick={() => {
|
|
552
|
+
setMenuOpen(false);
|
|
553
|
+
onCopyLink(item.id);
|
|
554
|
+
}}
|
|
555
|
+
>
|
|
556
|
+
<IconLink size={13} strokeWidth={1.8} />
|
|
557
|
+
<span>{labels.copyLink}</span>
|
|
558
|
+
</button>
|
|
559
|
+
)}
|
|
499
560
|
{renderAdditionalRowActions?.(item, () =>
|
|
500
561
|
setMenuOpen(false),
|
|
501
562
|
)}
|
|
502
|
-
{onDelete && (
|
|
563
|
+
{editable && onDelete && (
|
|
503
564
|
<button
|
|
504
565
|
type="button"
|
|
505
566
|
role="menuitem"
|
|
@@ -273,7 +273,7 @@ describe("ChatHistoryRail sections", () => {
|
|
|
273
273
|
expect(onLoadMore).toHaveBeenCalledOnce();
|
|
274
274
|
});
|
|
275
275
|
|
|
276
|
-
it("
|
|
276
|
+
it("keeps a shared row on one line with the owner mark", () => {
|
|
277
277
|
renderRail([
|
|
278
278
|
{
|
|
279
279
|
id: "shared",
|
|
@@ -281,16 +281,24 @@ describe("ChatHistoryRail sections", () => {
|
|
|
281
281
|
{
|
|
282
282
|
id: "s1",
|
|
283
283
|
title: "Roadmap",
|
|
284
|
+
ownerAvatar: <span>P</span>,
|
|
284
285
|
ownerLabel: "Pat Lee",
|
|
285
286
|
accessLabel: "Shared with your organization",
|
|
286
287
|
accessBasis: "organization",
|
|
288
|
+
readOnly: true,
|
|
287
289
|
},
|
|
288
290
|
],
|
|
289
291
|
},
|
|
290
292
|
]);
|
|
291
|
-
const
|
|
292
|
-
expect(
|
|
293
|
-
|
|
293
|
+
const row = container.querySelector(".an-chat-history-row")!;
|
|
294
|
+
expect(
|
|
295
|
+
row
|
|
296
|
+
.querySelector(".an-chat-history-row__owner-mark")
|
|
297
|
+
?.getAttribute("data-access-basis"),
|
|
298
|
+
).toBe("organization");
|
|
299
|
+
expect(row.querySelector(".an-chat-history-row__button")?.textContent).toBe(
|
|
300
|
+
"RoadmapP",
|
|
301
|
+
);
|
|
294
302
|
});
|
|
295
303
|
|
|
296
304
|
it("selecting a section row and New chat work as in the flat rail", () => {
|
package/src/chat-history.css
CHANGED
|
@@ -46,6 +46,11 @@
|
|
|
46
46
|
min-height: 0;
|
|
47
47
|
}
|
|
48
48
|
|
|
49
|
+
/* A rail inside a popover, such as All chats, scrolls instead of growing. */
|
|
50
|
+
.an-chat-history--rail.an-chat-history--capped .an-chat-history__list {
|
|
51
|
+
max-height: 16rem;
|
|
52
|
+
}
|
|
53
|
+
|
|
49
54
|
.an-chat-history-rail .an-chat-history__state:empty {
|
|
50
55
|
display: none;
|
|
51
56
|
}
|
|
@@ -71,19 +76,60 @@
|
|
|
71
76
|
padding: 0 4px;
|
|
72
77
|
}
|
|
73
78
|
|
|
74
|
-
.an-chat-history-
|
|
79
|
+
.an-chat-history-row__owner-mark {
|
|
80
|
+
display: inline-flex;
|
|
81
|
+
flex-shrink: 0;
|
|
82
|
+
align-self: center;
|
|
83
|
+
}
|
|
84
|
+
|
|
85
|
+
/* The active row has no timestamp; keep its avatar clear of the ⋯ trigger. */
|
|
86
|
+
.an-chat-history--rail
|
|
87
|
+
.an-chat-history-row--has-menu
|
|
88
|
+
.an-chat-history-row__owner-mark:last-child {
|
|
89
|
+
margin-inline-end: 18px;
|
|
90
|
+
}
|
|
91
|
+
|
|
92
|
+
.an-chat-owner-avatar {
|
|
93
|
+
display: inline-flex;
|
|
94
|
+
align-items: center;
|
|
95
|
+
justify-content: center;
|
|
96
|
+
flex-shrink: 0;
|
|
97
|
+
width: 16px;
|
|
98
|
+
height: 16px;
|
|
99
|
+
overflow: hidden;
|
|
100
|
+
border-radius: 9999px;
|
|
101
|
+
background: hsl(var(--muted));
|
|
102
|
+
/* guard:allow-raw-color — the initial sits on an emailToColor badge in both themes */
|
|
103
|
+
color: #fff;
|
|
104
|
+
font-size: 8px;
|
|
105
|
+
font-weight: 600;
|
|
106
|
+
line-height: 1;
|
|
107
|
+
}
|
|
108
|
+
|
|
109
|
+
.an-chat-owner-avatar__image {
|
|
110
|
+
width: 100%;
|
|
111
|
+
height: 100%;
|
|
112
|
+
object-fit: cover;
|
|
113
|
+
}
|
|
114
|
+
|
|
115
|
+
.an-chat-history-owner {
|
|
75
116
|
display: flex;
|
|
76
|
-
|
|
117
|
+
flex-direction: column;
|
|
118
|
+
gap: 1px;
|
|
77
119
|
min-width: 0;
|
|
78
|
-
|
|
79
|
-
font-size: 10px;
|
|
80
|
-
color: hsl(var(--muted-foreground) / 0.7);
|
|
120
|
+
text-align: start;
|
|
81
121
|
}
|
|
82
122
|
|
|
83
|
-
.an-chat-history-
|
|
123
|
+
.an-chat-history-owner__name {
|
|
124
|
+
min-width: 0;
|
|
84
125
|
overflow: hidden;
|
|
85
126
|
text-overflow: ellipsis;
|
|
86
127
|
white-space: nowrap;
|
|
128
|
+
font-weight: 500;
|
|
129
|
+
}
|
|
130
|
+
|
|
131
|
+
.an-chat-history-owner__access {
|
|
132
|
+
color: hsl(var(--muted-foreground));
|
|
87
133
|
}
|
|
88
134
|
|
|
89
135
|
.an-chat-history__state--error {
|
|
@@ -149,7 +195,10 @@
|
|
|
149
195
|
}
|
|
150
196
|
|
|
151
197
|
.an-chat-history-rail__disclosure,
|
|
152
|
-
.an-chat-history-rail__new-chat
|
|
198
|
+
.an-chat-history-rail__new-chat,
|
|
199
|
+
.an-chat-history-rail__section-toggle,
|
|
200
|
+
.an-chat-history-rail__load-more,
|
|
201
|
+
.an-chat-history-rail__retry {
|
|
153
202
|
display: flex;
|
|
154
203
|
align-items: center;
|
|
155
204
|
border: 0;
|
|
@@ -160,17 +209,52 @@
|
|
|
160
209
|
}
|
|
161
210
|
|
|
162
211
|
.an-chat-history-rail__disclosure:hover,
|
|
163
|
-
.an-chat-history-rail__new-chat:hover
|
|
212
|
+
.an-chat-history-rail__new-chat:hover,
|
|
213
|
+
.an-chat-history-rail__section-toggle:hover,
|
|
214
|
+
.an-chat-history-rail__load-more:hover,
|
|
215
|
+
.an-chat-history-rail__retry:hover {
|
|
164
216
|
background: hsl(var(--accent) / 0.5);
|
|
165
217
|
color: hsl(var(--accent-foreground));
|
|
166
218
|
}
|
|
167
219
|
|
|
168
220
|
.an-chat-history-rail__disclosure:focus-visible,
|
|
169
|
-
.an-chat-history-rail__new-chat:focus-visible
|
|
221
|
+
.an-chat-history-rail__new-chat:focus-visible,
|
|
222
|
+
.an-chat-history-rail__section-toggle:focus-visible,
|
|
223
|
+
.an-chat-history-rail__load-more:focus-visible,
|
|
224
|
+
.an-chat-history-rail__retry:focus-visible {
|
|
170
225
|
outline: 2px solid hsl(var(--ring));
|
|
171
226
|
outline-offset: -2px;
|
|
172
227
|
}
|
|
173
228
|
|
|
229
|
+
/* Show all, Load more and Retry match New chat: 12px muted text, not a button. */
|
|
230
|
+
.an-chat-history-rail__section-toggle,
|
|
231
|
+
.an-chat-history-rail__load-more,
|
|
232
|
+
.an-chat-history-rail__retry {
|
|
233
|
+
flex: 0 0 auto;
|
|
234
|
+
gap: 4px;
|
|
235
|
+
height: auto;
|
|
236
|
+
min-height: 26px;
|
|
237
|
+
padding: 4px 10px;
|
|
238
|
+
font-size: 12px;
|
|
239
|
+
font-weight: 500;
|
|
240
|
+
line-height: 1.4;
|
|
241
|
+
box-shadow: none;
|
|
242
|
+
}
|
|
243
|
+
|
|
244
|
+
.an-chat-history-rail__section-toggle svg,
|
|
245
|
+
.an-chat-history-rail__load-more svg,
|
|
246
|
+
.an-chat-history-rail__retry svg {
|
|
247
|
+
width: 13px;
|
|
248
|
+
height: 13px;
|
|
249
|
+
}
|
|
250
|
+
|
|
251
|
+
.an-chat-history__state .an-chat-history-rail__retry {
|
|
252
|
+
display: inline-flex;
|
|
253
|
+
min-height: 22px;
|
|
254
|
+
margin-inline-start: 4px;
|
|
255
|
+
padding: 2px 6px;
|
|
256
|
+
}
|
|
257
|
+
|
|
174
258
|
.an-chat-history-rail__disclosure {
|
|
175
259
|
justify-content: center;
|
|
176
260
|
flex: 0 0 auto;
|
|
@@ -267,6 +351,7 @@
|
|
|
267
351
|
|
|
268
352
|
.an-chat-history-row__title {
|
|
269
353
|
min-width: 0;
|
|
354
|
+
margin-inline-end: auto;
|
|
270
355
|
overflow: hidden;
|
|
271
356
|
text-overflow: ellipsis;
|
|
272
357
|
white-space: nowrap;
|
|
@@ -435,6 +520,21 @@
|
|
|
435
520
|
box-shadow: var(--agent-kit-overlay-elevation);
|
|
436
521
|
}
|
|
437
522
|
|
|
523
|
+
.an-chat-history-row__menu-owner {
|
|
524
|
+
display: flex;
|
|
525
|
+
align-items: center;
|
|
526
|
+
gap: 8px;
|
|
527
|
+
max-width: 260px;
|
|
528
|
+
margin-bottom: 4px;
|
|
529
|
+
padding: 6px 8px 8px;
|
|
530
|
+
border-bottom: 1px solid hsl(var(--border));
|
|
531
|
+
font-size: 12px;
|
|
532
|
+
}
|
|
533
|
+
|
|
534
|
+
.an-chat-history-row__menu-owner .an-chat-history-owner__access {
|
|
535
|
+
font-size: 11px;
|
|
536
|
+
}
|
|
537
|
+
|
|
438
538
|
.an-chat-history-row__menu-item {
|
|
439
539
|
display: flex;
|
|
440
540
|
align-items: center;
|