Skip to content

Commit b708d6b

Browse files
committed
fix: rename "Add Server Manually" to "Add Custom Server" and preserve JSON key order
Rename the button and modal title from "Add Server Manually" to "Add Custom Server" across the UI and E2E test page objects. Enable serde_json's `preserve_order` feature so that reading and writing back JSON config files (e.g. when removing a server) no longer reorders unrelated keys alphabetically, preventing spurious diffs and conflicts. Closes #50 https://claude.ai/code/session_01V5tgbLyeWrPW5zZ1toRoPZ
1 parent 8cdc28e commit b708d6b

4 files changed

Lines changed: 4 additions & 4 deletions

File tree

Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ futures = "0.3"
2525

2626
# Serialization
2727
serde = { version = "1.0", features = ["derive"] }
28-
serde_json = "1.0"
28+
serde_json = { version = "1.0", features = ["preserve_order"] }
2929

3030
# Error handling
3131
anyhow = "1.0"

apps/desktop/src/components/ConfigEditorModal.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -165,7 +165,7 @@ export function ConfigEditorModal({ spaceId, spaceName, onClose, onSaved }: Conf
165165
<div className="flex items-center justify-between p-4 border-b border-[rgb(var(--border))]">
166166
<div>
167167
<h3 className="text-lg font-semibold flex items-center gap-2">
168-
Add Server Manually
168+
Add Custom Server
169169
</h3>
170170
<p className="text-sm text-[rgb(var(--muted))]">
171171
Edit the JSON configuration for space: {spaceName}

apps/desktop/src/features/servers/ServersPage.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -787,7 +787,7 @@ export function ServersPage() {
787787
className="flex items-center gap-2 px-4 py-2 text-sm border border-[rgb(var(--border))] rounded-lg hover:bg-[rgb(var(--surface-hover))] transition-colors"
788788
>
789789
<FileJson className="h-4 w-4" />
790-
Add Server Manually
790+
Add Custom Server
791791
</button>
792792
)}
793793
</div>

tests/e2e/pages/ServersPage.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ export class ServersPage extends BasePage {
1515
constructor(page: Page) {
1616
super(page);
1717
this.heading = page.getByRole('heading', { name: 'My Servers' });
18-
this.addServerButton = page.getByRole('button', { name: /Add Server Manually/i });
18+
this.addServerButton = page.getByRole('button', { name: /Add Custom Server/i });
1919
this.gatewayStatus = page.locator('text=Gateway Running, text=Gateway Stopped').first();
2020
this.startGatewayButton = page.getByRole('button', { name: 'Start Gateway' });
2121
this.serverList = page.locator('.space-y-3');

0 commit comments

Comments
 (0)