feat(webapp): New campaign's "setup of one of yours" opens the full copy dialog (#1223) #1291

Merged
claude-bot merged 3 commits from feat/1223-new-campaign-full-copy into main 2026-10-30 23:40:59 +00:00
Collaborator

Closes #1223, the owner's Q193 answer (a).

Frontend (NewCampaign.jsx):

  • Choosing "The setup of one of yours" keeps the "Which of yours" picker (campaigns you GM, not archived), and the submit opens the existing StartFromThisDialog (mode="clone", unchanged) on the chosen campaign.
  • The Name field and game picker are hidden for that choice, because the dialog asks for the name. Focus returns to the button on close (Modal, tested).

Backend: the old settings-only path is removed. Nothing else sent template: {from_campaign_id} (frontend, bot, e2e and tests grepped). Removed:

  • CampaignFromCampaign, _settings_from_campaign, and TemplateCampaignNotFound / TemplateCampaignForbidden, with their router handling.
  • About 15 tests of that path.

A template object naming from_campaign_id is now a 422. SETTINGS_COPIED_FROM_TEMPLATE and _clamp_copied_retention stay, because the clone (setup_archive.py) uses them.

Docs: docs/API.md points to POST /clone; there's a new CATALOGUE row (IS-537) and a changelog fragment.

Wording, held for the owner on the Wording Review page, part i. Don't merge until it's decided:

  • The description becomes "Its scheduling and reminders, and whatever else you choose to take: pages, maps, people." It was "Settings only — scheduling, reminders, wiki kinds. Nothing from its story comes with it."
  • New button label: "Choose what to take".

Note: the dialog ticks the world pages by default (the owner's Q189). So to get exactly what the old settings-only copy gave, untick everything in the dialog.

Checked:

  • vitest: NewCampaign and StartFromThisDialog, 37/37 passed.
  • eslint is clean, and ruff format and check pass.
  • backend on docker-test: test_campaign_templates, test_campaign_setup_copy, wiki/test_title_readers and export/test_import_bounds, 198 passed.

Not run: the full suites (CI runs them), and no render check yet.

🤖 Generated with Claude Code

Closes #1223, the owner's Q193 answer (a). **Frontend (`NewCampaign.jsx`):** - Choosing "The setup of one of yours" keeps the "Which of yours" picker (campaigns you GM, not archived), and the submit opens the existing `StartFromThisDialog` (`mode="clone"`, unchanged) on the chosen campaign. - The Name field and game picker are hidden for that choice, because the dialog asks for the name. Focus returns to the button on close (`Modal`, tested). **Backend: the old settings-only path is removed.** Nothing else sent `template: {from_campaign_id}` (frontend, bot, e2e and tests grepped). Removed: - `CampaignFromCampaign`, `_settings_from_campaign`, and `TemplateCampaignNotFound` / `TemplateCampaignForbidden`, with their router handling. - About 15 tests of that path. A `template` object naming `from_campaign_id` is now a 422. `SETTINGS_COPIED_FROM_TEMPLATE` and `_clamp_copied_retention` stay, because the clone (`setup_archive.py`) uses them. **Docs:** `docs/API.md` points to `POST /clone`; there's a new CATALOGUE row (IS-537) and a changelog fragment. **Wording, held for the owner** on the Wording Review page, part i. **Don't merge until it's decided:** - The description becomes "Its scheduling and reminders, and whatever else you choose to take: pages, maps, people." It was "Settings only — scheduling, reminders, wiki kinds. Nothing from its story comes with it." - New button label: "Choose what to take". **Note:** the dialog ticks the world pages by default (the owner's Q189). So to get exactly what the old settings-only copy gave, untick everything in the dialog. **Checked:** - vitest: NewCampaign and StartFromThisDialog, 37/37 passed. - eslint is clean, and ruff format and check pass. - backend on docker-test: `test_campaign_templates`, `test_campaign_setup_copy`, `wiki/test_title_readers` and `export/test_import_bounds`, 198 passed. **Not run:** the full suites (CI runs them), and no render check yet. 🤖 Generated with [Claude Code](https://claude.com/claude-code)
Removes the settings-only template.from_campaign_id path from POST /api/campaigns.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
style: unused imports in the template tests
All checks were successful
CI / Backend lint (ruff) (pull_request) Successful in 30s
CI / Bot/backend version sync (pull_request) Successful in 31s
CI / Summarisation accuracy eval harness (stub provider) (pull_request) Successful in 2m6s
CI / Feedback site tests (pull_request) Successful in 1m30s
CI / Does this change touch the recording path? (pull_request) Successful in 22s
CI / Synthetic session harness (no GPU, no LLM) (pull_request) Has been skipped
CI / Bot tests and audit (pull_request) Successful in 2m17s
CI / Which journeys does this change need? (pull_request) Successful in 28s
CI / Docker image build (pull_request) Successful in 5m6s
CI / Frontend (shard 2/2) (pull_request) Successful in 7m27s
CI / Frontend (shard 1/2) (pull_request) Successful in 19m47s
CI / End-to-end journeys (desktop) (pull_request) Successful in 15m31s
CI / Backend migration, tests, and audit (pull_request) Successful in 1h1m44s
eb75888214
Merge remote-tracking branch 'origin/main' into feat/1223-new-campaign-full-copy
All checks were successful
CI / Backend lint (ruff) (pull_request) Successful in 53s
CI / Summarisation accuracy eval harness (stub provider) (pull_request) Successful in 1m48s
CI / Does this change touch the recording path? (pull_request) Successful in 13s
CI / Synthetic session harness (no GPU, no LLM) (pull_request) Has been skipped
CI / Bot/backend version sync (pull_request) Successful in 28s
CI / Which journeys does this change need? (pull_request) Successful in 16s
CI / Docker image build (pull_request) Successful in 31s
CI / Feedback site tests (pull_request) Successful in 1m15s
CI / Bot tests and audit (pull_request) Successful in 3m28s
CI / Frontend (shard 2/2) (pull_request) Successful in 9m1s
CI / Frontend (shard 1/2) (pull_request) Successful in 10m54s
CI / End-to-end journeys (desktop) (pull_request) Successful in 31m52s
CI / Backend migration, tests, and audit (pull_request) Successful in 38m19s
eda59910e1
claude-bot scheduled this pull request to auto merge when all checks succeed 2026-10-30 23:02:22 +00:00
claude-bot deleted branch feat/1223-new-campaign-full-copy 2026-10-30 23:41:00 +00:00
Sign in to join this conversation.
No description provided.