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
style(md): update code colors in md themes (#3069)
Seamus765ed0d09cf9
diff --git a/js/app/packages/core/component/LexicalMarkdown/component/accessory/CodeBoxAccessory.tsx b/js/app/packages/core/component/LexicalMarkdown/component/accessory/CodeBoxAccessory.tsxindex 67d5abfae9..30b4ee64da 100644--- a/js/app/packages/core/component/LexicalMarkdown/component/accessory/CodeBoxAccessory.tsx+++ b/js/app/packages/core/component/LexicalMarkdown/component/accessory/CodeBoxAccessory.tsx@@ -76,7 +76,7 @@ const LanguageIcons: Record<function StaticLabel(props: { language: SupportedLanguage }) {return (- <div class="text-sm font-sans font-medium flex items-center gap-2 p-2 text-ink-extra-muted">+ <div class="text-xs font-sans font-medium flex items-center gap-1 p-2 text-ink-extra-muted/50"><Dynamic component={LanguageIcons[props.language]} class="size-4" /><span>{LanguageDefinitions[props.language].label}</span></div>@@ -108,7 +108,6 @@ export function CodeLanguageSelector(props: {fallback={<StaticLabel language={validCurrentLanguage()} />}><Button- // TODO: Icon mapping moved to frontend packagevariant="ghost"size="sm"class="text-ink-extra-muted/50 rounded-xs p-1.5"@@ -234,7 +233,7 @@ export function CodeBoxAccessory(props: {}));}}>- <div class="w-full flex justify-between content-center items-start p-1 pointer-events-auto text-ink-extra-muted">+ <div class="w-full flex justify-between content-center items-start p-1 pointer-events-auto text-ink-extra-muted/50"><CodeLanguageSelectorlanguage={language}setLanguage={setLanguageOnNode}@@ -243,7 +242,7 @@ export function CodeBoxAccessory(props: {<div class="flex gap-2 items-center h-full"><Show when={showPreviewToggle()}><div class="flex items-center gap-2">- <div class="text-xs text-ink-extra-muted">Preview</div>+ <div class="text-xs text-ink-extra-muted/50">Preview</div><Switchchecked={isPreviewMode()}onChange={(enabled) => {@@ -261,7 +260,7 @@ export function CodeBoxAccessory(props: {<Buttonvariant="ghost"size="icon-sm"- class="text-ink-extra-muted rounded-xs h-full"+ class="text-ink-extra-muted/50 rounded-xs h-full"tooltip="Copy Code"on:click={(e) => {e.stopPropagation();@@ -305,7 +304,7 @@ function SvgPreview(props: { svgContent: () => string; overlay?: boolean }) {const content = props.svgContent();if (!content.trim()) {return (- <div class="flex items-center justify-center h-full text-ink-muted text-sm">+ <div class="flex items-center justify-center h-full text-ink-extra-muted/50 text-sm">No SVG content</div>);@@ -396,7 +395,7 @@ export const StaticCodeBoxAccessory = (props: {}};- const textColor = () => 'text-ink-extra-muted';+ const textColor = () => 'text-ink-extra-muted/50';const language = () => normalizedLanguage(props.language);const showPreviewToggle = () => {@@ -428,7 +427,7 @@ export const StaticCodeBoxAccessory = (props: {<Buttonvariant="ghost"size="icon-sm"- class="text-ink-extra-muted rounded-xs h-full"+ class="text-ink-extra-muted/50 rounded-xs h-full"tooltip="Copy Code"on:click={(e) => {e.stopPropagation();diff --git a/js/app/packages/core/component/LexicalMarkdown/theme.ts b/js/app/packages/core/component/LexicalMarkdown/theme.tsindex e428f6a65a..ab7a2ff803 100644--- a/js/app/packages/core/component/LexicalMarkdown/theme.ts+++ b/js/app/packages/core/component/LexicalMarkdown/theme.ts@@ -42,7 +42,7 @@ export const theme: EditorThemeClasses = {text: {bold: 'font-bold',italic: 'italic',- code: 'bg-edge font-mono rounded-xs md-inline-code p-0.5',+ code: 'bg-message font-mono rounded-xs md-inline-code p-0.5',strikethrough: 'md-strike',underline: 'md-underline',highlight: 'text-accent font-semibold',@@ -68,9 +68,9 @@ export const theme: EditorThemeClasses = {},link: 'text-accent-ink underline hover:underline cursor-default underline-offset-[0.15em]',quote: 'md-quote border-l-2 border-edge pl-4 py-2 italic text-ink-muted my-4',- code: 'bg-edge font-mono p-3 rounded block md-code-box before:text-ink-extra-muted/70 whitespace-pre mb-4',+ code: 'bg-message font-mono p-3 rounded block md-code-box before:text-ink-extra-muted/70 whitespace-pre mb-4',static: {- 'code-container': 'bg-edge rounded',+ 'code-container': 'bg-message rounded','table-container': 'my-4 max-w-full',},codeHighlight,@@ -156,7 +156,7 @@ export const aiChatTheme = createTheme(},code: 'w-full bg-transparent',static: {- 'code-container': 'bg-edge m-2',+ 'code-container': 'bg-message m-2',},},theme,@@ -168,7 +168,7 @@ export const channelTheme = createTheme(root: 'channel-markdown max-w-full min-w-0',code: 'rounded w-full bg-transparent',static: {- 'code-container': 'bg-edge rounded m-2',+ 'code-container': 'bg-message rounded m-2',},},theme,@@ -201,7 +201,7 @@ export const embeddedCodeBlock = createTheme({});export const unifiedListMarkdownTheme = createTheme({- code: 'font-mono overflow-hidden px-1.5 py-0.5 rounded bg-edge inline-block',+ code: 'font-mono overflow-hidden px-1.5 py-0.5 rounded bg-message inline-block',quote: 'border-l-2 border-current/20 pl-1 italic text-current/80',static: {'code-container':