Skip to content

Add feedback widget and update CTA#485

Merged
samkim merged 5 commits intomainfrom
suggestion-ui
Mar 12, 2026
Merged

Add feedback widget and update CTA#485
samkim merged 5 commits intomainfrom
suggestion-ui

Conversation

@samkim
Copy link
Member

@samkim samkim commented Jan 16, 2026

Summary

  • Adds an interactive feedback widget to the documentation sidebar
  • Updates the CTA component with improved styling and refreshed content
  • Creates a new wrapper component for TOC extra content

Test plan

  • Visit documentation pages and verify the feedback widget appears in the right sidebar
  • Test the feedback widget in both light and dark modes
  • Verify the CTA displays correctly on AuthZed product pages

🤖 Generated with Claude Code

@vercel
Copy link
Contributor

vercel bot commented Jan 16, 2026

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

Project Deployment Review Updated (UTC)
docs Ready Ready Preview, Comment Jan 16, 2026 7:36am

Review with Vercel Agent

samkim and others added 4 commits March 3, 2026 23:23
Implements a new feedback component in the TOC sidebar that allows users to provide feedback about documentation pages. Also updates the CTA component with improved styling and new demo booking link.

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
- Replace helpful options with: Accurate info, Solved my problem, Easy to understand, Something else
- Replace not-helpful options with: Inaccurate, Couldn't find what I was looking for, Difficult to understand, Code sample error, Other
- Add contextual textarea placeholder per branch
- Mark email field as optional, show notification hint only on not-helpful branch

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
@github-actions
Copy link
Contributor

github-actions bot commented Mar 4, 2026

Preview deployment status for this pull request.

Name Status Preview Updated (UTC)
docs 🟢 Ready Visit Preview Mar 10, 2026 09:30pm

Copy link

@Corey-T1000 Corey-T1000 left a comment

Choose a reason for hiding this comment

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

Review

Nice widget — the UX flow (thumbs → form → thank you) is clean. A few things worth addressing:

Event name collision (strongest concern)

Both the initial vote (lines 41/47) and the detailed form submission (line 57) fire a "docs-feedback" event with different schemas. This means a query like "count positive feedback" would double-count users who click thumbs-up AND submit the form. Consider either:

  • Distinct event names (docs-feedback-vote vs docs-feedback-detail)
  • Or removing the initial capture and only firing on form submit

posthog.identify(formData.email) — product decision

Line 54 uses the optional email field as the PostHog distinct ID. This merges the anonymous docs browsing session with the email identity. Not a security issue — it's a documented PostHog pattern — but worth confirming this is the intended behavior for anonymous docs visitors who happen to leave feedback.

editLink={null} — intentional?

This removes the "Edit this page on GitHub" link. The feedback widget replaces the old "Something unclear? Create an issue" link, which makes sense. But the edit link was a separate contribution path — worth confirming this removal is deliberate.

Minor nits

  • text-stone-400 in the open-source CTA subtitle while the rest of the component uses gray-* — probably should be text-gray-400 for palette consistency
  • The positive/negative checkbox lists have significant markup duplication — a .map() over an array of options would cut ~100 lines of near-identical JSX, but not blocking

Overall: solid addition. The event name collision is the main thing I'd want addressed before merge.

- Rename PostHog events to docs-feedback-vote and docs-feedback-detail to avoid double-counting
- Restore editLink (removed editLink={null}) to keep the GitHub edit path
- Fix text-stone-400 to text-gray-400 for palette consistency
- Add hover style to non-commercial CTA button
- Tighten separator spacing between CTA and feedback widget

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
@samkim samkim merged commit 744f492 into main Mar 12, 2026
10 of 11 checks passed
@samkim samkim deleted the suggestion-ui branch March 12, 2026 17:57
@github-actions github-actions bot locked and limited conversation to collaborators Mar 12, 2026
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants