Skip to content

Port /feedback and /missions into the campaign app - #315

Closed
mikepsinn wants to merge 1 commit into
mainfrom
feature/port-feedback-missions
Closed

Port /feedback and /missions into the campaign app#315
mikepsinn wants to merge 1 commit into
mainfrom
feature/port-feedback-missions

Conversation

@mikepsinn

Copy link
Copy Markdown
Owner

Summary

/feedback and /missions were menu entries that still resolved only on optimitron.com and returned 404 on warondisease.org. This ports both pages into apps/warondisease. Copy, form fields, validation, and post-submit behavior are unchanged from the source pages.

What changed

Feedback

  • apps/warondisease/app/feedback/page.tsx — the form, wrapped in the campaign Layout. Same fields (message, page URL, email), same lengths, same honeypot, same ?sent=1 confirmation state.
  • packages/site-kit/src/lib/feedback.server.ts — the intake, moved into site-kit so any site app can mount the form. Uses the site-kit Prisma shim. Optimitron builds the task through its generic createTask; this intake has one fixed shape (private, explicit parent, first-admin assignee), so it writes the resolved row directly, the way the other site-kit task writers do. Honeypot rejection, the 20-per-10-minutes global burst limit, URL/email cleaning, the task title prefix, the description template, and the contextJson metadata are all carried over unchanged.

Missions

  • apps/warondisease/app/missions/page.tsx — the landing page, wrapped in Layout.
  • apps/warondisease/app/missions/missions.server.ts — the one slice of Optimitron's 910-line dating.server.ts this page needs: the visitor's own mission-profile status. Profiles, photos, blocks, matches, and messaging stay on optimitron.com.
  • apps/warondisease/app/missions/mission-safety-notice.tsx and mission-safety.ts — the safety notice and its copy.
  • Profile, people, and messages links go through OPTIMITRON_LINKS / optimitronUrl() from packages/site-kit/src/lib/optimitron-links.ts.

Registration

  • scripts/site-app-visual-routes.mjs — both routes added to publicSiteAppRoutes.warondisease.
  • apps/warondisease/app/search/campaign-search.server.ts — both pages added to CAMPAIGN_PAGES.
  • Generated page.logged-out.md snapshots for both routes via pnpm copy warondisease.

packages/site-kit/src/lib/nav-items.ts and site-config.ts are untouched; the menu is handled separately.

Pages to review

The preview root is in the Vercel comment on this PR.

  • /feedback?logout=1
  • /feedback?sent=1&logout=1 — the post-submit confirmation state
  • /missions?logout=1
  • /missions?login=demo — adds the mission-status card

Verification

  • pnpm --filter @apps/warondisease typecheck — passes
  • pnpm --filter @apps/warondisease lint — passes
  • pnpm --filter @apps/warondisease test:unit — 19 files, 75 tests, all pass
  • pnpm test:site-app-navigation — 19/19 pass
  • Server action smoke-tested end to end through the honeypot-rejection path, which returns before any database write, so no task was created.
  • Screenshots captured and inspected locally at 1280 and 390 wide, before from optimitron.com and after from a local dev server. No layout breakage; both pages pick up the campaign shell cleanly.

🤖 Generated with Claude Code

Both routes still lived only on optimitron.com and 404'd on
warondisease.org. Feedback intake moves to packages/site-kit so any site
app can mount the form; the missions page takes only the profile-status
slice of Optimitron's dating.server.ts and links profiles, discovery, and
messages back to optimitron.com through optimitronUrl().

Copy, form fields, validation, honeypot, and rate limiting are unchanged
from the source pages.

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Copilot AI lite review requested due to automatic review settings September 3, 2026 17:47
@vercel

vercel Bot commented Sep 3, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated
acceleratedmedicine Error Error Sep 3, 2026 6:39pm UTC
warondisease Ready Ready Preview Sep 3, 2026 6:39pm UTC
1 Skipped Deployment
Project Deployment Actions Updated
optimitron-web Ignored Ignored Sep 3, 2026 6:39pm UTC

@coderabbitai

coderabbitai Bot commented Sep 3, 2026

Copy link
Copy Markdown

Warning

Review limit reached

Next included review available in 58 minutes.

Check out review usage here.

View limit details

Limit details: You’ve used the included review currently available.

You've used all free OSS reviews for now. Wait for the free limit to reset to keep reviewing this public repository.

Learn how review limits work.

Review configuration:

⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Team

Run ID: 740c466e-52b5-476e-8417-770501db65f1

📥 Commits

Reviewing files that changed from the base of the PR and between fe62d6b and 7adaaf7.

📒 Files selected for processing (10)
  • apps/warondisease/app/feedback/page.logged-out.md
  • apps/warondisease/app/feedback/page.tsx
  • apps/warondisease/app/missions/mission-safety-notice.tsx
  • apps/warondisease/app/missions/mission-safety.ts
  • apps/warondisease/app/missions/missions.server.ts
  • apps/warondisease/app/missions/page.logged-out.md
  • apps/warondisease/app/missions/page.tsx
  • apps/warondisease/app/search/campaign-search.server.ts
  • packages/site-kit/src/lib/feedback.server.ts
  • scripts/site-app-visual-routes.mjs

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Sep 3, 2026

Copy link
Copy Markdown

Codex Review Summary

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review Completed 2026-09-03T17:51:38.105014Z 7adaaf7 PR opened
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 7adaaf747d

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread apps/warondisease/app/missions/page.tsx
Comment thread scripts/site-app-visual-routes.mjs

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🟢 Approval recommended

The port closely mirrors the existing Optimitron implementations, and the new site-kit intake + new warondisease routes appear consistent and type-safe with no verified functional or security regressions in the diff.

Pull request overview

Ports the previously optimitron.com-only /feedback and /missions pages into the apps/warondisease campaign app so the menu entries resolve on warondisease.org (instead of 404), while keeping copy, form behavior, and mission-status display aligned with the Optimitron originals.

Changes:

  • Added /missions campaign page (plus safety notice + minimal server-side status fetch) that links back to optimitron.com for profile/discovery/messages.
  • Added /feedback campaign page and moved the feedback intake into packages/site-kit so multiple site apps can reuse it.
  • Registered both routes for visual-route coverage and campaign search indexing, and added logged-out copy snapshots.
File summaries
File Description
scripts/site-app-visual-routes.mjs Registers /missions and /feedback for the public warondisease visual routes list (with covers mapping).
packages/site-kit/src/lib/feedback.server.ts Implements reusable server-side feedback intake that creates a private task under the Optimitron dev parent.
apps/warondisease/app/search/campaign-search.server.ts Adds /missions and /feedback to campaign search documents for discoverability.
apps/warondisease/app/missions/page.tsx Adds the campaign-facing Missions landing page, wrapping in campaign Layout and linking into optimitron.com for deeper flows.
apps/warondisease/app/missions/page.logged-out.md Generated logged-out snapshot for copy/visual review coverage of /missions.
apps/warondisease/app/missions/missions.server.ts Adds the minimal Prisma query needed to show the signed-in user’s mission-profile status.
apps/warondisease/app/missions/mission-safety.ts Ports the mission safety copy and computed daily-deaths figure used in the notice.
apps/warondisease/app/missions/mission-safety-notice.tsx Renders the mission safety notice (compact/full).
apps/warondisease/app/feedback/page.tsx Adds the campaign feedback form page + server action wiring to create feedback tasks.
apps/warondisease/app/feedback/page.logged-out.md Generated logged-out snapshot for copy/visual review coverage of /feedback.
Review details
  • Files reviewed: 10/10 changed files
  • Comments generated: 0
  • Review effort level: Lite

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

@github-actions

github-actions Bot commented Sep 3, 2026

Copy link
Copy Markdown
Contributor

PR review packet

Start here

  • 🖼️ Visual review
  • 📏 Screenshot baseline: exact PR base main@fe62d6b1fda5 from CI run 33776252522.
  • 🚀 War on Disease preview
  • ☝️ Cmd/Ctrl-click review links to keep this PR open.
  • 🔑 ?login=demo signs in as the demo user; ?logout=1 clears the session.
  • 💬 For a visual problem, use the comment button in latest.html or reply here with @claude and the checklist item.

Agent preflight

The agent checks this only after rerunning the review until every diff is intentional. It resets for each commit.

  • Opened the generated visual review, inspected every changed and copy-only route, and fixed all unexplained drift.

Human review checklist

Agents leave these boxes unchecked. Mike checks them after reviewing the linked evidence.

Changed files considered
  • apps/warondisease/app/feedback/page.logged-out.md
  • apps/warondisease/app/feedback/page.tsx
  • apps/warondisease/app/missions/mission-safety-notice.tsx
  • apps/warondisease/app/missions/mission-safety.ts
  • apps/warondisease/app/missions/missions.server.ts
  • apps/warondisease/app/missions/page.logged-out.md
  • apps/warondisease/app/missions/page.tsx
  • apps/warondisease/app/search/campaign-search.server.ts
  • packages/site-kit/src/lib/feedback.server.ts
  • scripts/site-app-visual-routes.mjs

Updated automatically when this PR's preview or visual review reruns.

@mikepsinn

Copy link
Copy Markdown
Owner Author

Superseded by #319, which merges this branch with --no-ff so its commits and review threads carry over.

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