diff --git a/docs/design/evidence/task-031-revoked-by-after-mobile.png b/docs/design/evidence/task-031-revoked-by-after-mobile.png index 84f5c0e93..ad7180ba7 100644 Binary files a/docs/design/evidence/task-031-revoked-by-after-mobile.png and b/docs/design/evidence/task-031-revoked-by-after-mobile.png differ diff --git a/frontend/src/v2/__tests__/V2ConnectorTools.test.tsx b/frontend/src/v2/__tests__/V2ConnectorTools.test.tsx index a9842e358..286ecc929 100644 --- a/frontend/src/v2/__tests__/V2ConnectorTools.test.tsx +++ b/frontend/src/v2/__tests__/V2ConnectorTools.test.tsx @@ -92,6 +92,7 @@ test('rows carry the states table: a live grant pulses when used in the last 10 await waitFor(() => expect(liveDot).toHaveClass('v2-connector-row__dot--pulse')); const gone = screen.getByRole('button', { name: 'View GitHub in Ops' }); expect(within(gone).getByText('revoked by sam 10m ago')).toBeInTheDocument(); + expect(gone.closest('.v2-connector-row')).toHaveClass('v2-connector-row--dead'); expect(gone.querySelector('.v2-connector-row__dot')).toHaveClass('v2-connector-row__dot--empty'); // No not-yet row and no Add without a catalogue: nothing the server does not enforce. expect(screen.queryByText('not granted')).not.toBeInTheDocument(); @@ -137,7 +138,7 @@ test('Revoke is two-click and posts the revoke verb, then reloads; a dead grant fireEvent.click(screen.getByRole('button', { name: 'View GitHub in Ops' })); const gone = await screen.findByRole('complementary', { name: 'Grant details' }); expect(within(gone).queryByRole('button', { name: 'Revoke' })).not.toBeInTheDocument(); - expect(within(gone).getByText(/Revoked 10m ago\./)).toBeInTheDocument(); + expect(within(gone).getByText(/Revoked by sam 10m ago\./)).toBeInTheDocument(); await waitFor(() => expect(within(gone).getByText('No calls yet.')).toBeInTheDocument()); }); diff --git a/frontend/src/v2/__tests__/v2-layout-invariants.test.ts b/frontend/src/v2/__tests__/v2-layout-invariants.test.ts index c8c372181..a1ac74618 100644 --- a/frontend/src/v2/__tests__/v2-layout-invariants.test.ts +++ b/frontend/src/v2/__tests__/v2-layout-invariants.test.ts @@ -1773,6 +1773,7 @@ describe('v2 layout invariants (CSS rule presence)', () => { expect(connectorCss).toMatch(/@media \(max-width: 760px\) \{[\s\S]*?\.v2-connectors \{ min-height: 0; gap: 24px; margin: -12px -18px 0;/); expect(connectorCss).toMatch(/\.v2-root button\.v2-connector-row__selection \{ grid-column: 1 \/ -1;/); expect(connectorCss).toMatch(/\.v2-root button\.v2-connector-row__selection \.v2-connector-row__details \{ grid-column: 1 \/ -1; grid-row: 2;/); + expect(connectorCss).toMatch(/\.v2-connector-row:not\(.v2-connector-row--dead\) \.v2-connector-row__detail \{ display: none; \}/); }); describe('TASK-122 Phase A — the ruled restyle (Sam, 2026-09-03; spec on TASK-122)', () => { diff --git a/frontend/src/v2/components/V2ConnectorTools.tsx b/frontend/src/v2/components/V2ConnectorTools.tsx index 551f484a5..7d1c6aba3 100644 --- a/frontend/src/v2/components/V2ConnectorTools.tsx +++ b/frontend/src/v2/components/V2ConnectorTools.tsx @@ -378,7 +378,7 @@ const V2ConnectorTools: React.FC = ({ pods }) => { : t('tools.expiredLine', { defaultValue: 'expired {{rel}}', rel: relativeTime(grant.expiresAt) })) : `${audienceLabels(grant)} ${t('tools.mayUse', { defaultValue: 'may use it' })} · ${asksFirst(grant)}`; return ( -
+