Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
229 changes: 213 additions & 16 deletions apps/web/app/globals.css
Original file line number Diff line number Diff line change
Expand Up @@ -127,22 +127,6 @@
text-overflow: ellipsis;
}

.workspace-topbar-capacity {
flex-shrink: 0;
padding: 4px 8px;
border: 1px solid rgba(237, 238, 240, 0.14);
border-radius: 999px;
color: var(--workspace-muted);
font-size: 11px;
white-space: nowrap;
}

.workspace-topbar-capacity.is-live {
border-color: rgba(63, 191, 122, 0.45);
background: rgba(63, 191, 122, 0.12);
color: #d7f7de;
}

.workspace-topbar-actions {
display: flex;
flex-shrink: 0;
Expand Down Expand Up @@ -170,6 +154,219 @@
background: var(--teal-soft);
}

.workspace-presence,
.workspace-topbar-more {
position: relative;
}

.workspace-presence-trigger,
.workspace-topbar-more > summary {
display: inline-flex;
min-width: 36px;
height: 32px;
align-items: center;
justify-content: center;
gap: 5px;
padding: 0 7px;
border: 1px solid rgba(237, 238, 240, 0.14);
border-radius: 8px;
background: transparent;
color: var(--workspace-ink);
cursor: pointer;
list-style: none;
}

.workspace-topbar-more > summary::-webkit-details-marker {
display: none;
}

.workspace-presence-trigger:hover,
.workspace-topbar-more > summary:hover {
border-color: var(--teal);
background: var(--teal-soft);
}

.workspace-presence-trigger:focus-visible,
.workspace-topbar-more > summary:focus-visible,
.workspace-presence-popover button:focus-visible,
.workspace-topbar-menu a:focus-visible {
outline: 2px solid var(--gold-bright);
outline-offset: 2px;
}

.workspace-avatar-stack {
display: flex;
align-items: center;
padding-left: 6px;
}
.workspace-avatar {
display: inline-flex;
width: 25px;
height: 25px;
align-items: center;
justify-content: center;
overflow: hidden;
margin-left: -6px;
border: 2px solid var(--workspace-surface-2);
border-radius: 50%;
background: #354052;
color: #fff;
font-size: 9px;
font-weight: 700;
}
.workspace-avatar img {
width: 100%;
height: 100%;
object-fit: cover;
}
.workspace-presence-count {
color: var(--workspace-muted);
font-size: 11px;
}

.workspace-presence-popover,
.workspace-topbar-menu {
position: absolute;
z-index: 80;
top: calc(100% + 8px);
right: 0;
width: min(340px, calc(100vw - 24px));
padding: 10px;
border: 1px solid rgba(237, 238, 240, 0.14);
border-radius: 12px;
background: var(--workspace-surface-2);
box-shadow: 0 16px 40px rgba(0, 0, 0, 0.42);
}
.workspace-presence-heading,
.workspace-presence-agents {
display: flex;
align-items: center;
justify-content: space-between;
gap: 12px;
}
.workspace-presence-heading > div {
display: flex;
flex-direction: column;
gap: 2px;
}
.workspace-presence-heading strong,
.workspace-presence-agents strong {
font-size: 12px;
}
.workspace-presence-heading span,
.workspace-presence-agents span {
color: var(--workspace-muted);
font-size: 10px;
}
.workspace-presence-heading button {
min-height: 32px;
padding: 0 9px;
border: 1px solid rgba(237, 238, 240, 0.14);
border-radius: 7px;
background: transparent;
color: var(--workspace-ink);
cursor: pointer;
font-size: 11px;
}
.workspace-presence-list {
display: grid;
gap: 2px;
margin: 9px 0;
padding: 0;
list-style: none;
}
.workspace-presence-list li {
display: flex;
min-width: 0;
align-items: center;
gap: 9px;
padding: 7px 5px;
border-radius: 8px;
}
.workspace-presence-list .workspace-avatar {
flex: 0 0 auto;
margin: 0;
}
.workspace-presence-person {
display: flex;
min-width: 0;
flex: 1;
flex-direction: column;
}
.workspace-presence-person strong,
.workspace-presence-person span {
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
}
.workspace-presence-person strong {
font-size: 12px;
}
.workspace-presence-person span,
.workspace-presence-list li > span:last-child {
color: var(--workspace-muted);
font-size: 10px;
}
.workspace-presence-list li > span.is-online:last-child {
color: #79d693;
}
.workspace-presence-agents {
padding: 9px 5px 4px;
border-top: 1px solid var(--line);
}
.workspace-presence-agent {
display: flex;
justify-content: space-between;
gap: 10px;
padding: 5px;
font-size: 11px;
}
.workspace-presence-agent span:last-child {
overflow: hidden;
color: var(--workspace-muted);
text-overflow: ellipsis;
white-space: nowrap;
}
.workspace-topbar-menu {
width: 210px;
padding: 5px;
}
.workspace-topbar-menu a {
display: flex;
min-height: 34px;
align-items: center;
gap: 8px;
padding: 0 9px;
border-radius: 7px;
color: var(--workspace-ink);
font-size: 12px;
text-decoration: none;
}
.workspace-topbar-menu a:hover {
background: rgba(237, 238, 240, 0.08);
}

@media (max-width: 767px) {
.workspace-topbar {
padding-left: 8px;
}
.workspace-topbar-repo {
max-width: 30%;
}
.workspace-topbar-share {
width: 44px;
height: 44px;
justify-content: center;
padding: 0;
font-size: 0;
}
.workspace-presence-trigger,
.workspace-topbar-more > summary {
min-width: 44px;
height: 44px;
}
}

.workspace-status {
display: flex;
flex: 1;
Expand Down
2 changes: 1 addition & 1 deletion apps/web/app/workspaces/[workspaceId]/activity/page.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ import { loadActivityAuditSnapshot } from "@/lib/activity-audit-server";
import { requireUser } from "@/lib/session";
import { getWorkspaceForMember } from "@/lib/workspaces";

export const metadata: Metadata = { title: "Workspace activity" };
export const metadata: Metadata = { title: "Workspace history" };

const PAGE_SIZE = 30;

Expand Down
10 changes: 5 additions & 5 deletions apps/web/components/orca-workspace.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -128,7 +128,7 @@ describe("createOrcaManagedProposal", () => {
});

describe("WorkspaceTopBar", () => {
it("shows the reconciled three-agent worktree capacity", () => {
it("shows the compact people and agent-session control", () => {
render(
createElement(WorkspaceTopBar, {
repository: "yousef20920/CoDev",
Expand All @@ -138,8 +138,8 @@ describe("WorkspaceTopBar", () => {
);

expect(
screen.getByLabelText("Agent worktree capacity: 3 slots"),
).toHaveTextContent("3 agent worktree slots");
screen.getByLabelText("0 people here, 0 active agent sessions"),
).toHaveAttribute("aria-haspopup", "dialog");
});

it("shows how many agents are live without opening a panel", () => {
Expand All @@ -153,8 +153,8 @@ describe("WorkspaceTopBar", () => {
);

expect(
screen.getByLabelText("Active agents: 2 of 3 live"),
).toHaveTextContent("2 of 3 agents live");
screen.getByLabelText("0 people here, 2 active agent sessions"),
).toBeInTheDocument();
});
});

Expand Down
Loading
Loading