Macro is a unified workspace for teams: email, chat, docs, tasks, agents, calls, and CRM — @-linked together with shared AI memory.
TypeScript agentaiai-agentsall-in-onecrmcrm-systememaillinearmcpmessagingnotesnotionofficerustslackslack-alternativestartupstartup-toolstypescriptworkspace
fix(comments): use the shared caret for the document Discussion toggle (#6990)
gbirman08c5d5fe0f8c
diff --git a/apps/web/src/lib/core/messages/DocumentConversation.test.tsx b/apps/web/src/lib/core/messages/DocumentConversation.test.tsxindex 2295bce3d5..fda78ef964 100644--- a/apps/web/src/lib/core/messages/DocumentConversation.test.tsx+++ b/apps/web/src/lib/core/messages/DocumentConversation.test.tsx@@ -130,6 +130,13 @@ function discussion(}describe('DocumentConversation placement', () => {+ it('renders the Discussion disclosure as an icon instead of a text glyph', () => {+ const view = discussion([[]]);+ const button = view.getByRole('button', { name: 'Discussion' });+ expect(button.querySelector('svg')).toBeTruthy();+ expect(button.textContent?.trim()).toBe('Discussion');+ });+it('leaves the inline composer to a floating placement and hides an empty conversation on request', () => {const view = discussion([[]], undefined, {canWrite: true,diff --git a/apps/web/src/lib/core/messages/DocumentConversation.tsx b/apps/web/src/lib/core/messages/DocumentConversation.tsxindex 32bc246a34..d9e09c6bcb 100644--- a/apps/web/src/lib/core/messages/DocumentConversation.tsx+++ b/apps/web/src/lib/core/messages/DocumentConversation.tsx@@ -3,6 +3,8 @@ import { buildPostMessageSendPayload } from '@channel/Input/message-payload';import { useMessageBotMentionUsers } from '@channel/use-channel-bot-mention-users';import { StaticMarkdownContext } from '@core/component/LexicalMarkdown/component/core/StaticMarkdown';import { useUserId } from '@core/context/user';+import CaretDown from '@phosphor/caret-down.svg';+import CaretRight from '@phosphor/caret-right.svg';import { useMessageLink } from '@queries/messages/document-messages';import {newMessageId,@@ -96,10 +98,15 @@ export function DocumentConversation(props: {<section class="mt-3 pb-12" data-document-conversation><buttontype="button"- class="text-xs"+ class="flex items-center gap-1"onClick={() => setExpanded(!expanded())}>- {expanded() ? '▾' : '▸'} {props.label ?? 'Discussion'}+ {expanded() ? (+ <CaretDown class="size-3" />+ ) : (+ <CaretRight class="size-3" />+ )}+ <span class="text-xs">{props.label ?? 'Discussion'}</span></button><Show when={expanded() || props.targetId}><StaticMarkdownContext>