Skip to content

Let the user rename a box on the box details page - #199

Merged
splitbrain merged 1 commit into
splitbrain:mainfrom
splitbrain-bot:rename-box
Nov 29, 2026
Merged

splitbrain merged 1 commit into
splitbrain:mainfrom
splitbrain-bot:rename-box

Conversation

@splitbrain-bot

Copy link
Copy Markdown

The name of a box was set at creation and could not change. The name is only a label, because the orchestrator and the runtime identify a box by its id.

Changes

  • The Details card of the box details page has a name field with a Rename button. The button is active only when the field contains a new name that is not empty.
  • The new route PUT /api/boxes/:id/name accepts { "name": "…" } and answers with the BoxDetail. The route applies the same rules as POST /api/boxes: the orchestrator trims the name, and an empty name or a name of more than 100 characters gets a 400.
  • doc/rest.md and doc/boxes.md describe the route and the name field.

Tests

A test in app.test.ts covers the rename, the refused names and an unknown box. A test in views.test.ts renames a box on the details page and checks the heading and the box list. Biome, the type checks, the orchestrator API tests and the browser tests of the details page pass.

The name of a box was set at creation and could not change. The name is only a label, because the orchestrator and
the runtime identify a box by its id.

The Details card now has a name field with a Rename button. The new route PUT /api/boxes/:id/name stores the name
and applies the same rules as the creation of a box.
@splitbrain
splitbrain merged commit fea4637 into splitbrain:main Nov 29, 2026
5 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants