Skip to content

armgit / macro

Public Imported from GitHub
0

Macro is a unified workspace for teams: email, chat, docs, tasks, agents, calls, and CRM — @-linked together with shared AI memory.

fix(styling): toolbar dropdown and unread messages (#3413)

Jacob Beckermand7f61a471b0f
diff --git a/js/app/packages/app/component/app-sidebar/channels-unread-widget.tsx b/js/app/packages/app/component/app-sidebar/channels-unread-widget.tsx
index 0c9f6a2227..067cfe1a10 100644
--- a/js/app/packages/app/component/app-sidebar/channels-unread-widget.tsx
+++ b/js/app/packages/app/component/app-sidebar/channels-unread-widget.tsx
@@ -197,7 +197,9 @@ function ChannelGroupItem(props: {
<Button
class={cn(
'flex items-center cursor-default rounded-md text-ink-extra-muted not-disabled:hover:bg-ink/3',
- isSlim() ? 'justify-center size-8' : 'justify-start gap-2 w-full py-1'
+ isSlim()
+ ? 'justify-center size-8'
+ : 'justify-start gap-2 w-full h-8 py-1'
)}
draggable={false}
variant="ghost"
diff --git a/js/app/packages/app/component/next-soup/soup-view/NewCallButton.tsx b/js/app/packages/app/component/next-soup/soup-view/NewCallButton.tsx
index 03f291d02c..eb7c806008 100644
--- a/js/app/packages/app/component/next-soup/soup-view/NewCallButton.tsx
+++ b/js/app/packages/app/component/next-soup/soup-view/NewCallButton.tsx
@@ -10,6 +10,7 @@ import XIcon from '@phosphor/x.svg';
import { commsServiceClient } from '@service-comms/client';
import { Button, Dialog, Surface } from '@ui';
import { createSignal } from 'solid-js';
+import { CREATE_BUTTON_CLASS } from './create-button-style';
export function NewCallButton() {
const [isOpen, setIsOpen] = createSignal(false);
@@ -83,7 +84,7 @@ export function NewCallButton() {
<Button
variant="accent-reverse"
size="sm"
- class="rounded-md whitespace-nowrap px-2"
+ class={CREATE_BUTTON_CLASS}
onClick={() => setIsOpen(true)}
>
<PlusCircleIcon class="size-3.5" />
diff --git a/js/app/packages/app/component/next-soup/soup-view/create-button-style.ts b/js/app/packages/app/component/next-soup/soup-view/create-button-style.ts
new file mode 100644
index 0000000000..eef131bf7c
--- /dev/null
+++ b/js/app/packages/app/component/next-soup/soup-view/create-button-style.ts
@@ -0,0 +1 @@
+export const CREATE_BUTTON_CLASS = 'rounded-full px-3 py-2 font-bold';
diff --git a/js/app/packages/app/component/next-soup/soup-view/soup-view-create-button.tsx b/js/app/packages/app/component/next-soup/soup-view/soup-view-create-button.tsx
index bb778f3a84..cfc6c573e7 100644
--- a/js/app/packages/app/component/next-soup/soup-view/soup-view-create-button.tsx
+++ b/js/app/packages/app/component/next-soup/soup-view/soup-view-create-button.tsx
@@ -15,6 +15,7 @@ import PlusCircleIcon from '@phosphor/plus-circle.svg';
import UploadIcon from '@phosphor/upload-simple.svg';
import { Button, Dropdown, Layer } from '@ui';
import { createMemo, For, Show } from 'solid-js';
+import { CREATE_BUTTON_CLASS } from './create-button-style';
import { NewCallButton } from './NewCallButton';
// Which blocks to show as create options per view, in order
@@ -62,8 +63,6 @@ const VIEW_CREATE_LABELS: Partial<Record<ListView, string>> = {
tasks: 'Task',
};
-const CREATE_BUTTON_CLASS = 'rounded-full px-1 py-2 font-bold';
-
function getViewCreateOptions(view: ListView): CreateOption[] {
const createNames = VIEW_CREATE_BLOCKNAMES[view] ?? [];
const options: CreateOption[] = createNames.flatMap((name) => {
diff --git a/js/app/packages/app/component/split-layout/components/SplitFileMenu.tsx b/js/app/packages/app/component/split-layout/components/SplitFileMenu.tsx
index d95d7c4c18..39ea405e0b 100644
--- a/js/app/packages/app/component/split-layout/components/SplitFileMenu.tsx
+++ b/js/app/packages/app/component/split-layout/components/SplitFileMenu.tsx
@@ -3,6 +3,7 @@ import type { BlockTool } from '@app/component/ResponsiveBlockToolbar';
import { ResponsiveDropdown } from '@app/component/SimpleDropdown';
import { useBlockAliasedName, useBlockName } from '@core/block';
import { useItemOperations } from '@core/component/FileList/useItemOperations';
+import { MENU_CONTENT_CLASS } from '@core/component/Menu';
import { toast } from '@core/component/Toast/Toast';
import { triggerFocusInput } from '@core/directive/focusInput';
import { useIsDocumentOwner } from '@core/signal/permissions';
@@ -199,7 +200,7 @@ export function SplitFileMenu(props: {
</ResponsiveDropdown.Trigger>
<ResponsiveDropdown.Portal>
<Layer depth={2}>
- <ResponsiveDropdown.Content class="w-fit">
+ <ResponsiveDropdown.Content class={cn(MENU_CONTENT_CLASS, 'w-fit')}>
<For each={ops()}>
{(op, i) => (
<>