You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@maka.apache.org by xx...@apache.org on 2026/10/16 12:47:30 UTC

(maka) branch feat/assistant-inbox-bot updated: fix(assistant): use Astryx summary button and update SendUser fixtures

This is an automated email from the ASF dual-hosted git repository.

xxhZs pushed a commit to branch feat/assistant-inbox-bot
in repository https://gitbox.apache.org/repos/asf/maka.git


The following commit(s) were added to refs/heads/feat/assistant-inbox-bot by this push:
     new e781f3f69c fix(assistant): use Astryx summary button and update SendUser fixtures
e781f3f69c is described below

commit e781f3f69c7e168dbc4d7ef363ef4a7779d5cb28
Author: xxhZs <84...@users.noreply.github.com>
AuthorDate: Fri Oct 16 20:47:08 2026 +0800

    fix(assistant): use Astryx summary button and update SendUser fixtures
---
 docs/astryx-surface-file-inventory.md                      |  7 +++++--
 docs/astryx-surface-file-inventory.paths                   |  3 +++
 .../proactive-matters/test/assistant-loop.test.ts          |  4 ++--
 .../proactive-matters/test/source-assistant-loop.test.ts   |  2 +-
 packages/ui/src/message-summary.tsx                        |  8 ++++++--
 packages/ui/src/styles.css                                 | 14 ++------------
 6 files changed, 19 insertions(+), 19 deletions(-)

diff --git a/docs/astryx-surface-file-inventory.md b/docs/astryx-surface-file-inventory.md
index 2d98c9f6c2..8bb739814e 100644
--- a/docs/astryx-surface-file-inventory.md
+++ b/docs/astryx-surface-file-inventory.md
@@ -6,7 +6,7 @@ Generated against `@astryxdesign/core@0.6.3` (195 component exports).
 
 Wiki bar: Design Conventions · API Use-the-System · Theming · Container Padding.
 
-**Totals:** 340 files — blocker 0, reimplementation 0, polish 4, aligned 336.
+**Totals:** 343 files — blocker 0, reimplementation 0, polish 5, aligned 338.
 
 ## Exclusions (explicit)
 
@@ -98,9 +98,11 @@ Wiki bar: Design Conventions · API Use-the-System · Theming · Container Paddi
 | `apps/desktop/src/renderer/features/overlays/ui/overlays-context.tsx` | other | none | aligned — no raw controls; no Astryx JSX usage | aligned |
 | `apps/desktop/src/renderer/features/overlays/ui/overlays-root.tsx` | other | none | aligned — no raw controls; no Astryx JSX usage | aligned |
 | `apps/desktop/src/renderer/features/overlays/ui/search-modal-host.tsx` | dialog-overlay | none | aligned — no raw controls; no Astryx JSX usage | aligned |
+| `apps/desktop/src/renderer/features/personal-assistant/avatar.tsx` | other | none | aligned — no raw controls; no Astryx JSX usage | aligned |
 | `apps/desktop/src/renderer/features/personal-assistant/original-reader.css` | styles | n/a (css) | aligned — no off-rhythm control heights flagged | aligned |
 | `apps/desktop/src/renderer/features/personal-assistant/original-reader.tsx` | other | Button | aligned — uses Astryx (Button) | aligned |
-| `apps/desktop/src/renderer/features/personal-assistant/personal-assistant.css` | styles | n/a (css) | aligned — no off-rhythm control heights flagged | aligned |
+| `apps/desktop/src/renderer/features/personal-assistant/personal-assistant.css` | styles | n/a (css) | off-rhythm control height 30px (Design size) | polish |
+| `apps/desktop/src/renderer/features/personal-assistant/typing.tsx` | other | none | aligned — no raw controls; no Astryx JSX usage | aligned |
 | `apps/desktop/src/renderer/features/runtime-host-management/services-context.tsx` | other | none | aligned — no raw controls; no Astryx JSX usage | aligned |
 | `apps/desktop/src/renderer/features/runtime-host-management/ui/peer-mesh-peer-id-button.tsx` | other | Button | aligned — uses Astryx (Button) | aligned |
 | `apps/desktop/src/renderer/features/runtime-host-management/ui/runtime-host-add-computer-menu.tsx` | other | DropdownMenu, DropdownMenuItem | aligned — uses Astryx (DropdownMenu, DropdownMenuItem) | aligned |
@@ -323,6 +325,7 @@ Wiki bar: Design Conventions · API Use-the-System · Theming · Container Paddi
 | `packages/ui/src/markdown-math.tsx` | ui-composition | none | aligned — no raw controls; no Astryx JSX usage | aligned |
 | `packages/ui/src/markdown.tsx` | ui-composition | none | aligned — no raw controls; no Astryx JSX usage | aligned |
 | `packages/ui/src/mermaid-diagram.tsx` | ui-composition | Button, CodeBlock, Collapsible, Dialog, IconButton, Toolbar | aligned — uses Astryx (Button, CodeBlock, Collapsible, Dialog, IconButton, Toolbar) | aligned |
+| `packages/ui/src/message-summary.tsx` | ui-composition | Button | aligned — uses Astryx (Button) | aligned |
 | `packages/ui/src/model-picker-internals.tsx` | ui-composition | SelectorOption | aligned — uses Astryx (SelectorOption) | aligned |
 | `packages/ui/src/model-picker-panel.tsx` | shell-chrome-or-panel | Button, TextInput | aligned — uses Astryx (Button, TextInput) | aligned |
 | `packages/ui/src/model-picker.tsx` | ui-composition | Selector | aligned — uses Astryx (Selector) | aligned |
diff --git a/docs/astryx-surface-file-inventory.paths b/docs/astryx-surface-file-inventory.paths
index c1f0a48937..357cbcf35e 100644
--- a/docs/astryx-surface-file-inventory.paths
+++ b/docs/astryx-surface-file-inventory.paths
@@ -67,9 +67,11 @@ apps/desktop/src/renderer/features/overlays/ui/keyboard-help-modal.tsx
 apps/desktop/src/renderer/features/overlays/ui/overlays-context.tsx
 apps/desktop/src/renderer/features/overlays/ui/overlays-root.tsx
 apps/desktop/src/renderer/features/overlays/ui/search-modal-host.tsx
+apps/desktop/src/renderer/features/personal-assistant/avatar.tsx
 apps/desktop/src/renderer/features/personal-assistant/original-reader.css
 apps/desktop/src/renderer/features/personal-assistant/original-reader.tsx
 apps/desktop/src/renderer/features/personal-assistant/personal-assistant.css
+apps/desktop/src/renderer/features/personal-assistant/typing.tsx
 apps/desktop/src/renderer/features/runtime-host-management/services-context.tsx
 apps/desktop/src/renderer/features/runtime-host-management/ui/peer-mesh-peer-id-button.tsx
 apps/desktop/src/renderer/features/runtime-host-management/ui/runtime-host-add-computer-menu.tsx
@@ -292,6 +294,7 @@ packages/ui/src/markdown-image.tsx
 packages/ui/src/markdown-math.tsx
 packages/ui/src/markdown.tsx
 packages/ui/src/mermaid-diagram.tsx
+packages/ui/src/message-summary.tsx
 packages/ui/src/model-picker-internals.tsx
 packages/ui/src/model-picker-panel.tsx
 packages/ui/src/model-picker.tsx
diff --git a/packages/runtime-host/test/assistant/proactive-matters/test/assistant-loop.test.ts b/packages/runtime-host/test/assistant/proactive-matters/test/assistant-loop.test.ts
index 5ca1c508a6..d7da4f0460 100644
--- a/packages/runtime-host/test/assistant/proactive-matters/test/assistant-loop.test.ts
+++ b/packages/runtime-host/test/assistant/proactive-matters/test/assistant-loop.test.ts
@@ -43,7 +43,7 @@ test('unified entry + background index + timed task + parent feedback run togeth
           if (JSON.parse(message.content).status === 'completed')
             await invoke('SendUser', {
               messageId: 'acceptance-complete',
-              messages: ['已核对,验收通过。'],
+              messages: [{ text: '已核对,验收通过。' }],
             });
         }
         await invoke('Sleep', {});
@@ -189,7 +189,7 @@ test('Bot delegates for the visible owner and delivers task completion through S
               if (report.status === 'completed')
                 await invoke('SendUser', {
                   messageId: 'delegated-result',
-                  messages: ['验收结果已经核对完成。'],
+                  messages: [{ text: '验收结果已经核对完成。' }],
                 });
             }
           }
diff --git a/packages/runtime-host/test/assistant/proactive-matters/test/source-assistant-loop.test.ts b/packages/runtime-host/test/assistant/proactive-matters/test/source-assistant-loop.test.ts
index b8c4e2534a..32324eac6b 100644
--- a/packages/runtime-host/test/assistant/proactive-matters/test/source-assistant-loop.test.ts
+++ b/packages/runtime-host/test/assistant/proactive-matters/test/source-assistant-loop.test.ts
@@ -146,7 +146,7 @@ test('source sync → stale index → fresh original → discovery Inbox → Bot
                   ? '已核对最新原文,委派任务完成。'
                   : undefined;
             if (text) {
-              await invoke('SendUser', { messageId: row.id, messages: [text] });
+              await invoke('SendUser', { messageId: row.id, messages: [{ text }] });
               visible.push(text);
             }
           }
diff --git a/packages/ui/src/message-summary.tsx b/packages/ui/src/message-summary.tsx
index fb49f307fe..5f4eb68b8e 100644
--- a/packages/ui/src/message-summary.tsx
+++ b/packages/ui/src/message-summary.tsx
@@ -18,6 +18,7 @@
  */
 
 import { useId, useState, type ReactNode } from 'react';
+import { Button } from '@astryxdesign/core';
 import { Markdown } from './markdown.js';
 import { ChevronDown } from './icons.js';
 import { assistantChatCopy } from './assistant-chat-copy.js';
@@ -34,8 +35,11 @@ export function MessageSummary({ summary, children }: { summary?: string; childr
     <div className="maka-message-summary">
       <div className="maka-message-summary-preview"><Markdown text={summary} density="compact" /></div>
       <div id={bodyId} className="maka-message-summary-body" hidden={!expanded}>{children}</div>
-      <button
+      <Button
         type="button"
+        label={expanded ? labels.collapse : labels.expand}
+        variant="ghost"
+        size="sm"
         className="maka-message-summary-toggle"
         aria-expanded={expanded}
         aria-controls={bodyId}
@@ -43,7 +47,7 @@ export function MessageSummary({ summary, children }: { summary?: string; childr
       >
         {expanded ? labels.collapse : labels.expand}
         <ChevronDown size={14} aria-hidden="true" />
-      </button>
+      </Button>
     </div>
   );
 }
diff --git a/packages/ui/src/styles.css b/packages/ui/src/styles.css
index 4b244b1c9d..a06b8c9a5f 100644
--- a/packages/ui/src/styles.css
+++ b/packages/ui/src/styles.css
@@ -1261,15 +1261,5 @@
 }
 .maka-message-summary-body:not([hidden]) { padding-top: 12px; }
 .maka-message-summary-body[hidden] { display: none; }
-.maka-message-summary-toggle {
-  display: flex; align-items: center; gap: 4px;
-  appearance: none; border: 0; background: transparent;
-  padding: 8px 0 0; margin: 0; font: inherit; font-size: 12px;
-  color: var(--muted-foreground); cursor: pointer;
-}
-.maka-message-summary-toggle:hover { color: var(--foreground); }
-.maka-message-summary-toggle:focus-visible {
-  outline: 2px solid var(--ring); outline-offset: 3px; border-radius: 3px;
-}
-
-.maka-message-summary-toggle[aria-expanded='true'] > svg { transform: rotate(180deg); }
+.maka-message-summary-toggle { margin-top: 8px; }
+.maka-message-summary-toggle[aria-expanded='true'] svg { transform: rotate(180deg); }


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@maka.apache.org
For additional commands, e-mail: commits-help@maka.apache.org