From 5d5b39bec18d470e03a0aa6634a3347a56262a6f Mon Sep 17 00:00:00 2001 From: Developer Date: Tue, 16 Jun 2026 14:47:37 +0000 Subject: [PATCH 1/2] feat(web/ui): refactor component inline styles into utility classes Pass 2 of the web UI spacing/typography/visual-rhythm rework. - Add layout, spacing, typography, visual, card, and component utilities - Add form-section, form-row, form-help, text-error, alert-success - Unify .form-group and .form-field; add .status-badge family - Alias legacy button classes to .btn primitives - Refactor ToolTypeListSidebar and ConfigProfileListSidebar to use .sidebar and var(--sidebar-width) instead of hardcoded 280px - Refactor ToolTypeEditorPanel, ConfigProfileEditorPanel, git-mount-editor, and manifest-editor to use utility classes Quality gates: npm run typecheck, npm run lint, npm run build pass. Inline style blocks in target components reduced from 198 to 11. --- .../ConfigProfileEditorPanel.tsx | 110 ++-- .../ConfigProfileListSidebar.tsx | 119 +--- .../features/git/git-mount-editor.tsx | 131 +--- .../tool-workshop/ToolTypeEditorPanel.tsx | 64 +- .../tool-workshop/ToolTypeListSidebar.tsx | 122 +--- .../features/tool/manifest-editor.tsx | 203 ++----- apps/web/src/styles/global.css | 205 ++++++- apps/web/src/styles/utilities.css | 574 +++++++++++++++++- 8 files changed, 957 insertions(+), 571 deletions(-) diff --git a/apps/web/src/components/features/config-profiles/ConfigProfileEditorPanel.tsx b/apps/web/src/components/features/config-profiles/ConfigProfileEditorPanel.tsx index 974d99a..e4480d4 100644 --- a/apps/web/src/components/features/config-profiles/ConfigProfileEditorPanel.tsx +++ b/apps/web/src/components/features/config-profiles/ConfigProfileEditorPanel.tsx @@ -86,24 +86,24 @@ export const ConfigProfileEditorPanel = ({ const hasSelection = isCreating || selectedProfile; return ( -
+
{!hasSelection ? ( -
-
+
+
-

Select a config profile

-

Choose a profile from the list to edit, or create a new one.

+

Select a config profile

+

Choose a profile from the list to edit, or create a new one.

) : ( -
-
+
+
-

+

{isCreating ? "Create Profile" : selectedProfile?.name}

{!isCreating && selectedProfile && ( -

+

{selectedProfile.project_id && `Project: ${projects.find((p) => p.id === selectedProfile.project_id)?.name || selectedProfile.project_id}`} {selectedProfile.project_id && selectedProfile.tool_type_id && " · "} @@ -113,8 +113,8 @@ export const ConfigProfileEditorPanel = ({ )}

{!isCreating && selectedProfile && ( -
-
- {error &&
{error}
} + {error &&
{error}
} {saveStatus === "saved" && ( -
+
Profile saved successfully
)} -
+
onFormChange("name", e.target.value)} placeholder="e.g., Development Environment" className="form-input" required /> @@ -145,8 +145,8 @@ export const ConfigProfileEditorPanel = ({ onFormChange("description", e.target.value || undefined)} placeholder="Optional description" className="form-input" />
-
-
+
+
-
+
{ if (e.target.value) { onAddInclude(e.target.value); e.target.value = ""; } }} className="form-input"> {availableProfiles.map((p) => ( @@ -217,11 +219,11 @@ export const ConfigProfileEditorPanel = ({
-

Environment Variables

+

Environment Variables

{Object.entries(formData.env_vars || {}).map(([key, value], idx) => ( -
- onUpdateEnvVar(key, e.target.value, value)} placeholder="VAR_NAME" className="form-input" style={{ flex: 1 }} /> - onUpdateEnvVar(key, key, e.target.value)} placeholder="value" className="form-input" style={{ flex: 1 }} /> +
+ onUpdateEnvVar(key, e.target.value, value)} placeholder="VAR_NAME" className="form-input" /> + onUpdateEnvVar(key, key, e.target.value)} placeholder="value" className="form-input" />
))} @@ -229,47 +231,47 @@ export const ConfigProfileEditorPanel = ({
-

Runtime Hints

-