You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
feat(citations): show full prompt text on hover in the prompt filter dropdown #298
On the Citations page (/dashboard/citations), the Prompt filter dropdown truncates long prompts so they can't be read in full. Truncation is fine for the dropdown width, but there's currently no way to see the complete prompt text — hovering an option shows nothing.
Worse, the full text is discarded before render. In web/src/app/[locale]/(dashboard)/dashboard/citations/page.tsx (~line 391), the combobox items are built as:
So each item only keeps a pre-sliced label — the original p.text is gone. On top of that, ComboboxItem already applies the Tailwind truncate class (web/src/components/ui/combobox.tsx:115), so the manual slice(0, 80) is redundant for the visual layout and only serves to throw the full text away.
Proposed change
Keep the full prompt on each item: add fullText: p.text.
Drop the manual slice(0, 80) — let the existing CSS truncate handle visual overflow, so the option fits the dropdown width without losing data.
Pass title={item.fullText} to ComboboxItem (it already spreads {...props} onto the underlying element) → native browser tooltip on hover, also read by screen readers. No new dependency or tooltip component needed.
Files to touch
web/src/app/[locale]/(dashboard)/dashboard/citations/page.tsx — add fullText, drop the slice, pass title to ComboboxItem
web/src/components/ui/combobox.tsx — only if title doesn't already reach the DOM node via {...props} (it should, so likely no change)
How to test
Open /dashboard/citations for a brand with at least one long prompt (>80 chars).
Open the Prompt filter dropdown — long options are visually truncated with an ellipsis (unchanged).
Hover a truncated option → the full prompt text appears as a native tooltip.
Short prompts render and behave exactly as before (no regression).
Activity