Skip to content

[#196] Post-creation buttons: View your story + Go home#203

Merged
realproject7 merged 1 commit intomainfrom
task/196-post-creation-buttons
Mar 16, 2026
Merged

[#196] Post-creation buttons: View your story + Go home#203
realproject7 merged 1 commit intomainfrom
task/196-post-creation-buttons

Conversation

@realproject7
Copy link
Copy Markdown
Owner

Summary

  • usePublish now exposes the transaction receipt for callers to decode events
  • Create page decodes StorylineCreated event from receipt to get the new storyline ID
  • Success buttons: "View your story" → /story/[id], "Go home" → /
  • Replaces old "Discover" + "Create another" buttons

Fixes #196

Test plan

  • tsc --noEmit — zero errors
  • next build — clean
  • After creating a storyline, "View your story" links to correct story page
  • "Go home" links to home page

🤖 Generated with Claude Code

- usePublish now exposes transaction receipt for callers to decode
- Create page decodes StorylineCreated event to get new storyline ID
- Success buttons: "View your story" → /story/[id], "Go home" → /
- Replaces old "Discover" + "Create another" buttons

Fixes #196

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Copy link
Copy Markdown
Collaborator

@project7-interns project7-interns left a comment

Choose a reason for hiding this comment

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

T2b APPROVE

Well-implemented:

  1. usePublish — Clean addition of receipt state, exposed in return, reset on clear. Minimal change to shared hook.
  2. Event decoding — Topic pre-computed at module level via encodeEventTopics. Log lookup + decodeEventLog with try/catch for safety. Correct pattern.
  3. UX — "View your story" links to decoded storyline ID, "Go home" replaces old "Discover"/"Create another". Conditional render when storylineId available.

No issues.

Copy link
Copy Markdown
Collaborator

@project7-interns project7-interns left a comment

Choose a reason for hiding this comment

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

Verdict: APPROVE

Summary

This PR replaces the low-value post-creation actions with the two expected destinations and derives the new storyline route from the confirmed transaction receipt by decoding the StorylineCreated event. The implementation is focused, keeps the success UI simple, and avoids guessing the new ID.

Findings

  • [info] No remaining blocking findings.
    • File: src/app/create/page.tsx:58
    • Suggestion: None.

Decision

Approving because the post-creation buttons now match issue #196, the new storyline link is sourced from on-chain event data, and validation is clean.

@realproject7 realproject7 merged commit 8e40f83 into main Mar 16, 2026
1 check 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.

[UX] Post-creation buttons: View your story + Go home

2 participants