Evenfire is an intelligence layer platform for running LLM agents that take real actions, on your infrastructure
TypeScript
fix(control-ui): r1-h1 restore host approval row layout
Josué90ea3131ff04
diff --git a/control-ui/app/globals.css b/control-ui/app/globals.cssindex f3b7e51eb..a6c52a6ce 100644--- a/control-ui/app/globals.css+++ b/control-ui/app/globals.css@@ -9264,6 +9264,20 @@ td.cu-registry-description {}}+/* HostApprovalSection keeps approval values aligned beside their tool names. */+.cu-access-row {+ display: flex;+ align-items: center;+ justify-content: space-between;+ gap: var(--cu-space-3);+ padding: var(--cu-space-2) 0;+ border-bottom: 1px solid var(--cu-border-subtle);+}++.cu-access-row:last-child {+ border-bottom: none;+}+/* Review R1-H1: member Agents rows lead with the display name (spec.host) and* stack the immutable slug underneath whenever the two differ — display names* are not unique, the slug is the stable identity for navigation, grants, anddiff --git a/control-ui/components/__tests__/HostApprovalSection.test.tsx b/control-ui/components/__tests__/HostApprovalSection.test.tsxindex 36418ce64..e1bf015a0 100644--- a/control-ui/components/__tests__/HostApprovalSection.test.tsx+++ b/control-ui/components/__tests__/HostApprovalSection.test.tsx@@ -1,10 +1,14 @@import { afterEach, beforeEach, describe, expect, it, vi } from 'vitest'import { act, renderHook } from '@testing-library/react'import { cleanup, fireEvent, render, screen } from '@testing-library/react'+import { readFileSync } from 'node:fs'+import { resolve } from 'node:path'import { HostApprovalSection } from '../HostApprovalSection'import { NATIVE_TOOLS } from '../HostApprovalSection/constants'import { useApprovalToolsDraft } from '../HostApprovalSection/hooks'+const controlUiCss = readFileSync(resolve(__dirname, '../../app/globals.css'), 'utf8')+describe('HostApprovalSection — constants', () => {it('contains exactly the 12 always-on native tools verified during the back-end smoke', () => {const expected = [@@ -164,6 +168,14 @@ describe('HostApprovalSection — component', () => {afterEach(() => cleanup())+ it('keeps approval rows in a horizontal shared layout', () => {+ const rowRule = controlUiCss.match(/(?:^|\n)\.cu-access-row\s*\{([^}]*)\}/)?.[1] ?? ''++ expect(rowRule).toMatch(/display:\s*flex/)+ expect(rowRule).toMatch(/align-items:\s*center/)+ expect(rowRule).toMatch(/justify-content:\s*space-between/)+ })+describe('read-only — no overrides', () => {it('renders the empty state and an Edit button when canWrite=true', () => {render(@@ -205,6 +217,7 @@ describe('HostApprovalSection — component', () => {)// Both overrides shownexpect(screen.getByText('http_request')).toBeInTheDocument()+ expect(screen.getByText('http_request').closest('.cu-access-row')).not.toBeNull()expect(screen.getByText('file_write')).toBeInTheDocument()// Tools with no override are NOT renderedexpect(screen.queryByText('shell_exec')).not.toBeInTheDocument()diff --git a/control-ui/package-lock.json b/control-ui/package-lock.jsonindex ace5d18fc..49209391b 100644--- a/control-ui/package-lock.json+++ b/control-ui/package-lock.json@@ -1,12 +1,12 @@{"name": "clerum-control-ui",- "version": "0.1.704",+ "version": "0.1.705","lockfileVersion": 3,"requires": true,"packages": {"": {"name": "clerum-control-ui",- "version": "0.1.704",+ "version": "0.1.705","dependencies": {"@clerum/display-field": "file:../packages/display-field","@clerum/frontend-components": "file:../packages/frontend-components",diff --git a/control-ui/package.json b/control-ui/package.jsonindex 7b4f7e30a..9380f9917 100644--- a/control-ui/package.json+++ b/control-ui/package.json@@ -1,6 +1,6 @@{"name": "clerum-control-ui",- "version": "0.1.704",+ "version": "0.1.705","private": true,"scripts": {"dev": "NEXT_IGNORE_INCORRECT_LOCKFILE=1 next dev",