From 51c30ed73d1c08b2fb28e29ed6a54f2032a7bee3 Mon Sep 17 00:00:00 2001 From: saravanakumardb1 Date: Fri, 29 May 2026 06:46:39 -0700 Subject: [PATCH] feat(tracker-web): roadmap submit + email-prompt modals via shared Modal (UX-3.2) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Replace the bespoke local Modal (and its slate/blue/white chrome) with the shared @bytelyst/ui Modal (Radix dialog — focus-trap/Esc/scroll-lock) for both the Submit Idea and vote email-prompt dialogs. The dialog titles become the accessible heading; form fields move to Input/Select/Textarea and the submit-result message to AlertBanner. Behaviour preserved. Generated with [Devin](https://cli.devin.ai/docs) Co-Authored-By: Devin <158243242+devin-ai-integration[bot]@users.noreply.github.com> --- .../tracker-web/src/app/roadmap/page.tsx | 196 ++++++++---------- 1 file changed, 89 insertions(+), 107 deletions(-) diff --git a/dashboards/tracker-web/src/app/roadmap/page.tsx b/dashboards/tracker-web/src/app/roadmap/page.tsx index 5ed5dd87..4abf0206 100644 --- a/dashboards/tracker-web/src/app/roadmap/page.tsx +++ b/dashboards/tracker-web/src/app/roadmap/page.tsx @@ -6,6 +6,8 @@ import { Button, Input, Select, + Textarea, + Modal, Badge, StatusDot, MetricCard, @@ -352,127 +354,118 @@ export default function RoadmapPage() { {/* Email prompt modal */} - {showEmailPrompt && ( - { + { + if (!open) { setShowEmailPrompt(false); setPendingVoteId(null); - }} - > -

Enter your email to vote

-

- We use your email to track your votes. One vote per item. -

- +
+ setVoteEmail(e.target.value)} - className="w-full px-3 py-2 border border-slate-300 dark:border-slate-600 rounded-lg bg-white dark:bg-slate-800 text-sm mb-4" onKeyDown={e => e.key === 'Enter' && handleEmailSubmit()} autoFocus />
- - + +
- - )} +
+
{/* Submit modal */} - {showSubmit && ( - { + { + if (!open) { setShowSubmit(false); setSubmitSuccess(''); - }} - > -

Submit an Idea

- {submitSuccess ? ( -
- {submitSuccess} -
- ) : null} -
-
- setSubmitForm({ ...submitForm, name: e.target.value })} - required - className="px-3 py-2 border border-slate-300 dark:border-slate-600 rounded-lg bg-white dark:bg-slate-800 text-sm" - /> - setSubmitForm({ ...submitForm, email: e.target.value })} - required - className="px-3 py-2 border border-slate-300 dark:border-slate-600 rounded-lg bg-white dark:bg-slate-800 text-sm" - /> -
- - + {submitSuccess ? ( + + {submitSuccess} + + ) : null} + +
+ setSubmitForm({ ...submitForm, title: e.target.value })} + aria-label="Your name" + placeholder="Your name" + value={submitForm.name} + onChange={e => setSubmitForm({ ...submitForm, name: e.target.value })} required - maxLength={500} - className="w-full px-3 py-2 border border-slate-300 dark:border-slate-600 rounded-lg bg-white dark:bg-slate-800 text-sm" /> -