Commit fae3dee
Agents Manager: Adopt the chat UI design polish and expand the header menu (#113276)
* Agents Manager: Adopt the agenttic-ui 0.1.82 design polish
Chat header: Minimize moves first (custom bottom-bar icon in the shared
icons file), 32px buttons with 24px icons, 4px radius, 2px gap, muted
hover/focus background, keyboard-only focus rings, and the more-options
menu grouped so the "Switch to floating/sidebar" option (renamed from
"Pop out sidebar"/"Move to sidebar", now last) sits behind a full-width
divider with 2px item gaps.
Message actions: 28px icons in the existing 32px buttons, 4px radius,
muted hover with foreground icons, pressed feedback stays foreground
while the ghost style dims the disabled vote.
Companions for the new --color-input-border tokens: map them in the
dark color scheme's agenttic overrides, and keep image-studio's
composer borderless in its focused state. Grouped empty view title
matches the package's 14px suggestion labels; the AM-side empty view
icon now uses the package default.
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
* Agents Manager: Size the chat header actions row to its 32px buttons
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
* Agents Manager: Drop the hover/focus background on chat header buttons
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
* Agents Manager: Out-specify wp's small icon button sizing in the chat header
wp's `.components-button.is-small.has-icon:not(.has-text)` ties our
selector at (0,4,0) and wins by load order, shrinking the buttons to
24px wide with no padding. Adding `.has-icon` makes the header sizing
win regardless of stylesheet order.
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
* Agents Manager: Size the chat header buttons at 24x24
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
* Agents Manager: Drop redundant padding and radius on chat header buttons
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
* Agents Manager: Tighten a chat header comment
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
* Agents Manager: Inset the chat header menu groups 16px/6px
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
* Agents Manager: Pad the chat header menu items 16px/6px
Targets the real `.components-dropdown-menu__menu-item` class — the
previous hover rule aimed at `.components-menu-item__button`, which the
controls-based DropdownMenu never renders — and out-specifies wp's item
padding. Menu groups return to their uniform 8px.
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
* Agents Manager: 8px vertical padding for the chat header menu groups
Vertical-only group padding: the menu opens and closes with an 8px
inset, hover chips span the full popover width, and the item padding
alone provides the 16px text inset.
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
* Agents Manager: Rebalance chat header menu padding (groups 8px, items 6px 8px)
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
* Agents Manager: Style the chat header menu against its real DOM
The controls-based DropdownMenu renders a flat item list — control sets
add `has-separator` to an item instead of MenuGroup wrappers — so the
group-based popover rules never matched anything. Rebuild on the real
structure: 8px menu padding, 2px item gaps, 6px/8px item padding, and
wp's separator line stretched across the menu padding with 8px
clearance on both sides.
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
* Agents Manager: Round the chat header menu items 4px
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
* Agents Manager: Keep the menu label color steady on hover
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
* Agents Manager: Use the background as the menu items' focus indicator
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
* Agents Manager: No focus effect on disabled chat header menu items
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
* Agents Manager: Custom icons for the mode-switch menu options
Replaces wp's `login`/`drawerRight` with the AI-1096 Figma glyphs for
"Switch to floating" and "Switch to sidebar". The floating glyph's rect
keeps an explicit fill="none" so wp's `svg { fill: currentColor }`
doesn't flood the stroke-drawn square.
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
* Agents Manager: Move View history from the chat header into the menu
Pure relocation after "New chat" in the More Options menu: same
`! isReaderChat` gate (reader frontends have no user-accessible session
history), same `chat_history_open` tracking event, same `/history`
navigation, label, and `backup` icon. The gating tests move to the
agent-dock suite with the item.
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
* Agents Manager: Tune the menu separator spacing to 11px
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
* Agents Manager: Menu separator spacing at 12px
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
* Agents Manager: Tighten menu comments
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
* Agents Manager: Add Knowledge and memory + AI Agent settings menu items
Both sit after Split screen in the first control set, ahead of the
switch divider. The gear is wp's `cog`; the bookmark glyph has no
@wordpress/icons counterpart, so it joins the shared icons file.
Destinations follow AI-1096: the wp-admin guidelines page and the
site's WordPress.com AI tools settings, opened in a new tab.
The ticket's visibility rules (Dotcom-hosted only for settings, admin
role for both, omnibar-site resolution outside wp-admin) are not yet
implemented.
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
* Agents Manager: Use wp's heading glyph for Knowledge and memory
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
* Agents Manager: Drop a menu icon comment
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
* Agents Manager: Point AI Agent settings at the dashboard host per AI-1096
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
* Agents Manager: Show guidelines/settings menu items in wp-admin only
Their destinations (a relative wp-admin URL and the current host's
WordPress.com settings) can't resolve from Calypso-hosted chats. Gate
on the wp-admin body class — section names vary across wp-admin
screens, so they can't discriminate reliably.
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
* Agents Manager: Document the wp-admin detection choice
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
* Agents Manager: Extract isWpAdmin into utils
Follows the is-editor-page pattern (body-class detection with the
SSR guard) for reuse by the upcoming visibility rules.
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
* Agents Manager: Show AI Agent settings on Dotcom-hosted sites only
The linked WordPress.com settings page only exists for Simple/WoA
sites, and the wp-admin chat also ships to self-hosted Jetpack sites.
Gate on a new `agentsManagerData.isDotcomSite` flag injected
server-side via Jetpack's `Host::is_wpcom_platform_site()` (client-side
heuristics can't tell: `canAccessWpcomApis()` is false on Atomic).
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
* Agents Manager: Hostname fallback for the Dotcom settings gate
The vendored jetpack-status doesn't ship is_wpcom_platform_site(), so
the server-side isDotcomSite flag needs a Jetpack-package change before
it can exist. Until then, the wordpress.com hostname covers Simple
sites; WoA (custom domains) picks up when the flag ships.
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
* Agents Manager: Use the server-provided site domain for the settings URL
`site.domain` is the site's canonical slug; the wp-admin hostname only
coincides with it when the site serves on its primary domain.
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
* Agents Manager: Gate the settings item on the server-provided site domain
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
* Agents Manager: Name the Dotcom gate for readability
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
* Agents Manager: Rename the wp-admin gate for symmetry
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
* Agents Manager: Fix import order in the chat header
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
* Agents Manager: Address review feedback
- Clear both focus-ring mechanisms (outline and box-shadow) on pointer
focus — wp draws the ring differently across runtime versions
- Replace filter(Boolean)-plus-assertion with a narrowing type guard in
the chat header options builder
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
* Agents Manager: Format the menu option guard
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
* Agents Manager: Gate AI Agent settings on the server flag alone
This PR deploys together with the Jetpack-side isDotcomSite injection,
so the interim site-domain fallback goes: server truth or hidden. Sites
on older Jetpack packages simply don't see the item until they update.
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
* Agents Manager: Space the menu options preamble for readability
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
* Agents Manager: Drop the isDotcomSite gate from AI Agent settings
The Jetpack-side flag PR was closed; the item now shows for any
wp-admin chat, with a TODO to revisit the WP.com-host check.
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
* Agents Manager: Note the wp-admin gate is about site-based links
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
* Agents Manager: Fix import order and prettier formatting
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
* Agents Manager: Address code review follow-ups
- Make the copy button's keyboard-only focus ring load-order-proof
(the compound replaces the dropped !important)
- Hoist isMenuOption to module scope
- Sync the test icon mocks with the components' real imports and
assert the View history menu position its test title promises
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
* Agents Manager: Filter menu options with an inline predicate
TS 6 infers the type guard from the truthiness arrow, so the named
helper is unnecessary.
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
* Agents Manager: Cover the menu actions and switch options
Adds click tests for View history, Knowledge and memory, and AI Agent
settings, plus visibility and divider-grouping tests for the renamed
switch options.
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
* Note E2E follow-ups for the themed composer borders
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
* Agents Manager: Use base-styles variables for the polish spacing
Grid units and radii swap in for the raw px values with exact token
matches; the compiled CSS is byte-identical.
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
* Agents Manager: Keep the menu item padding literal
The 6px half has no base-styles token; a half-tokenized shorthand
reads worse than the plain values.
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
* Agents Manager: Keep the polish spacing as literal px values
Reverts the base-styles variable conversion — the polish is specced in
exact pixels, and literals can't drift with upstream token changes.
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
* Agents Manager: Correct the switch-option comment, drop a restating one
Docking isn't wp-admin-only (the Calypso dashboard docks too) and the
dock isn't a block-editor slot; the gate is about reader-chat frontends
lacking a sidebar layout.
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
* Agents Manager: Gate the site links on the injected site domain
Only the Jetpack package's wp-admin enqueue injects site, so its
domain replaces the body-class sniff and the hostname fallback —
no domain, no item, and never a malformed settings URL.
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
* Agents Manager: Simplify the site-gate comments
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
* Agents Manager: Gate the settings item on isWpcomPlatform and unify the menu tracks
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
* Agents Manager: Widen the chat-header actions gap to 4px
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
* Image Studio: Drop the dead composer border-token overrides
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
* Agents Manager: Drop the settled dark-scheme composer border TODO
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
* Agents Manager: Hide View history while the history view is open
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
* Agents Manager: Cover the dual-fired menu tracks with a test
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
* Agents Manager: Correct the popover comments, tighten the dual-fire note
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
* Agents Manager: Align the menu links on noopener,noreferrer
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
* Agents Manager: Drop the inert space-between override in the chat header
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
* Agents Manager: Fold the unified menu event into a local helper
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
* Agents Manager: Match the AM menu event name to its Big Sky analog
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
* Agents Manager: Use copySmall for the copy message action
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
* Update agenttic packages to 0.1.84
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
---------
Co-authored-by: Welly Shen <welly.shen@automattic.com>
Co-authored-by: Claude Fable 5 <noreply@anthropic.com>1 parent e39614f commit fae3dee
21 files changed
Lines changed: 526 additions & 171 deletions
File tree
- client
- lib/color-scheme
- packages
- agents-manager
- src
- components
- __tests__
- agent-chat
- agent-dock
- chat-header
- copy-action-button
- image-studio
- jetpack-ai-sidebar
- odie-client
- zendesk-client
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
821 | 821 | | |
822 | 822 | | |
823 | 823 | | |
| 824 | + | |
| 825 | + | |
| 826 | + | |
| 827 | + | |
| 828 | + | |
| 829 | + | |
824 | 830 | | |
825 | 831 | | |
826 | 832 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
14 | 14 | | |
15 | 15 | | |
16 | 16 | | |
17 | | - | |
| 17 | + | |
18 | 18 | | |
19 | 19 | | |
20 | 20 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
41 | 41 | | |
42 | 42 | | |
43 | 43 | | |
44 | | - | |
45 | | - | |
| 44 | + | |
| 45 | + | |
46 | 46 | | |
47 | 47 | | |
48 | 48 | | |
| |||
Lines changed: 217 additions & 21 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2 | 2 | | |
3 | 3 | | |
4 | 4 | | |
5 | | - | |
| 5 | + | |
6 | 6 | | |
7 | 7 | | |
8 | 8 | | |
| |||
15 | 15 | | |
16 | 16 | | |
17 | 17 | | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
18 | 21 | | |
19 | 22 | | |
20 | 23 | | |
| |||
46 | 49 | | |
47 | 50 | | |
48 | 51 | | |
| 52 | + | |
| 53 | + | |
49 | 54 | | |
50 | 55 | | |
51 | | - | |
52 | | - | |
53 | | - | |
| 56 | + | |
54 | 57 | | |
55 | 58 | | |
56 | 59 | | |
| |||
68 | 71 | | |
69 | 72 | | |
70 | 73 | | |
71 | | - | |
| 74 | + | |
72 | 75 | | |
73 | 76 | | |
74 | 77 | | |
| |||
103 | 106 | | |
104 | 107 | | |
105 | 108 | | |
106 | | - | |
| 109 | + | |
107 | 110 | | |
108 | 111 | | |
109 | 112 | | |
110 | 113 | | |
111 | 114 | | |
112 | | - | |
113 | | - | |
114 | | - | |
115 | | - | |
116 | | - | |
117 | | - | |
118 | | - | |
119 | | - | |
120 | | - | |
121 | | - | |
| 115 | + | |
| 116 | + | |
| 117 | + | |
| 118 | + | |
| 119 | + | |
| 120 | + | |
| 121 | + | |
| 122 | + | |
| 123 | + | |
| 124 | + | |
| 125 | + | |
| 126 | + | |
| 127 | + | |
122 | 128 | | |
123 | 129 | | |
124 | 130 | | |
| |||
138 | 144 | | |
139 | 145 | | |
140 | 146 | | |
141 | | - | |
| 147 | + | |
| 148 | + | |
| 149 | + | |
| 150 | + | |
| 151 | + | |
| 152 | + | |
| 153 | + | |
142 | 154 | | |
143 | 155 | | |
| 156 | + | |
| 157 | + | |
| 158 | + | |
| 159 | + | |
| 160 | + | |
144 | 161 | | |
145 | 162 | | |
146 | 163 | | |
| |||
160 | 177 | | |
161 | 178 | | |
162 | 179 | | |
163 | | - | |
| 180 | + | |
164 | 181 | | |
| 182 | + | |
165 | 183 | | |
166 | 184 | | |
167 | 185 | | |
| |||
201 | 219 | | |
202 | 220 | | |
203 | 221 | | |
| 222 | + | |
| 223 | + | |
204 | 224 | | |
205 | 225 | | |
206 | 226 | | |
| |||
420 | 440 | | |
421 | 441 | | |
422 | 442 | | |
| 443 | + | |
| 444 | + | |
| 445 | + | |
| 446 | + | |
| 447 | + | |
| 448 | + | |
| 449 | + | |
| 450 | + | |
| 451 | + | |
| 452 | + | |
| 453 | + | |
| 454 | + | |
| 455 | + | |
| 456 | + | |
| 457 | + | |
| 458 | + | |
| 459 | + | |
| 460 | + | |
| 461 | + | |
| 462 | + | |
| 463 | + | |
| 464 | + | |
| 465 | + | |
| 466 | + | |
| 467 | + | |
| 468 | + | |
| 469 | + | |
| 470 | + | |
| 471 | + | |
| 472 | + | |
| 473 | + | |
| 474 | + | |
| 475 | + | |
| 476 | + | |
| 477 | + | |
| 478 | + | |
| 479 | + | |
| 480 | + | |
| 481 | + | |
| 482 | + | |
| 483 | + | |
| 484 | + | |
| 485 | + | |
| 486 | + | |
| 487 | + | |
| 488 | + | |
| 489 | + | |
| 490 | + | |
| 491 | + | |
| 492 | + | |
| 493 | + | |
| 494 | + | |
| 495 | + | |
| 496 | + | |
| 497 | + | |
| 498 | + | |
| 499 | + | |
| 500 | + | |
| 501 | + | |
| 502 | + | |
| 503 | + | |
| 504 | + | |
| 505 | + | |
| 506 | + | |
| 507 | + | |
| 508 | + | |
| 509 | + | |
| 510 | + | |
| 511 | + | |
| 512 | + | |
| 513 | + | |
| 514 | + | |
| 515 | + | |
| 516 | + | |
| 517 | + | |
| 518 | + | |
| 519 | + | |
| 520 | + | |
| 521 | + | |
| 522 | + | |
| 523 | + | |
| 524 | + | |
| 525 | + | |
| 526 | + | |
| 527 | + | |
| 528 | + | |
| 529 | + | |
| 530 | + | |
| 531 | + | |
| 532 | + | |
| 533 | + | |
| 534 | + | |
| 535 | + | |
| 536 | + | |
| 537 | + | |
| 538 | + | |
| 539 | + | |
| 540 | + | |
| 541 | + | |
| 542 | + | |
| 543 | + | |
| 544 | + | |
| 545 | + | |
| 546 | + | |
| 547 | + | |
| 548 | + | |
| 549 | + | |
| 550 | + | |
| 551 | + | |
| 552 | + | |
| 553 | + | |
| 554 | + | |
| 555 | + | |
| 556 | + | |
| 557 | + | |
| 558 | + | |
| 559 | + | |
| 560 | + | |
| 561 | + | |
| 562 | + | |
| 563 | + | |
| 564 | + | |
| 565 | + | |
| 566 | + | |
| 567 | + | |
| 568 | + | |
| 569 | + | |
| 570 | + | |
| 571 | + | |
| 572 | + | |
| 573 | + | |
| 574 | + | |
| 575 | + | |
| 576 | + | |
| 577 | + | |
| 578 | + | |
| 579 | + | |
| 580 | + | |
| 581 | + | |
| 582 | + | |
| 583 | + | |
| 584 | + | |
| 585 | + | |
| 586 | + | |
| 587 | + | |
| 588 | + | |
| 589 | + | |
| 590 | + | |
| 591 | + | |
| 592 | + | |
| 593 | + | |
| 594 | + | |
| 595 | + | |
| 596 | + | |
| 597 | + | |
| 598 | + | |
| 599 | + | |
| 600 | + | |
| 601 | + | |
| 602 | + | |
| 603 | + | |
| 604 | + | |
| 605 | + | |
| 606 | + | |
| 607 | + | |
| 608 | + | |
| 609 | + | |
| 610 | + | |
| 611 | + | |
| 612 | + | |
| 613 | + | |
| 614 | + | |
| 615 | + | |
423 | 616 | | |
424 | 617 | | |
425 | 618 | | |
| |||
447 | 640 | | |
448 | 641 | | |
449 | 642 | | |
450 | | - | |
451 | | - | |
452 | | - | |
| 643 | + | |
| 644 | + | |
| 645 | + | |
| 646 | + | |
| 647 | + | |
| 648 | + | |
453 | 649 | | |
454 | 650 | | |
455 | 651 | | |
| |||
Lines changed: 0 additions & 23 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
28 | 28 | | |
29 | 29 | | |
30 | 30 | | |
31 | | - | |
32 | 31 | | |
33 | 32 | | |
34 | 33 | | |
35 | | - | |
36 | 34 | | |
37 | 35 | | |
38 | 36 | | |
| |||
59 | 57 | | |
60 | 58 | | |
61 | 59 | | |
62 | | - | |
63 | | - | |
64 | | - | |
65 | | - | |
66 | | - | |
67 | | - | |
68 | | - | |
69 | 60 | | |
70 | 61 | | |
71 | 62 | | |
| |||
101 | 92 | | |
102 | 93 | | |
103 | 94 | | |
104 | | - | |
105 | | - | |
106 | | - | |
107 | | - | |
108 | | - | |
109 | | - | |
110 | | - | |
111 | | - | |
112 | | - | |
113 | | - | |
114 | | - | |
115 | | - | |
116 | | - | |
117 | | - | |
118 | 95 | | |
119 | 96 | | |
120 | 97 | | |
| |||
0 commit comments