Repository navigation
feat(prompts): keep the prompts table header and Prompt column pinned while scrolling - #1007
Merged
gkhngyk merged 1 commit intoOct 13, 2026
Conversation
… while scrolling With 100 prompts per page the column header scrolled out of view, so it was hard to tell Mentions, Citations and Runs apart further down the list. The shared Table component gains opt-in stickyHeader and stickyFirstColumn props, and the Tracked Prompts table turns both on. Co-Authored-By: Claude Opus 5.5 <[email protected]>
Collaborator
Author
|
@gkhngyk this is ready for review (PROMPT-011). Could you also approve the CI workflows so the checks can run? |
This was referenced Oct 13, 2026
gkhngyk
approved these changes
Oct 13, 2026
gkhngyk
left a comment
Contributor
There was a problem hiding this comment.
Looks good, thanks. Checked the build and the generated sticky and shadow CSS.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
On the Tracked Prompts table ("All Prompts"), the column header scrolled off screen after about 20 rows, so it was no longer clear which number belonged to Mentions, Citations or Runs. This PR keeps the header row and the Prompt column pinned while the table scrolls.
components/ui/table.tsx:Tablegets two opt-in props,stickyHeaderandstickyFirstColumn. A sticky cell pins to its nearest scrolling ancestor, so a sticky table scrolls inside its own height-capped container (max-h-[calc(100dvh-12rem)] overflow-auto). That keeps both the header (vertical) and the first column (horizontal) pinned. Sticky cells get an opaquebg-cardso rows don't show through. The first column repaints the row hover tint itself. A subtle shadow appears under the header (and beside the first column) only once the table has scrolled.dashboard/prompts/page.tsx: the Tracked Prompts table turns both props on.overflow-x-auto, no sticky classes).Because it lives in the shared component, the same behavior can be switched on later for other long tables (Content Opportunities, Action Center, Query Fan-out, Citations) with one prop.
Related issue
None. Product task PROMPT-011 ("Sticky column header in the prompts table").
Type of change
feat— New featurefix— Bug fixchore— Maintenance / dependenciesdocs— Documentation onlyrefactor— Code change that neither fixes a bug nor adds a featuretest— Adding or updating testsHow to test
Table(e.g. the prompt-suggestions table): no change.Tested locally with 57 prompts (header and first column stay pinned, sorting and tooltips work while pinned).
Notes for reviewers
overflow-x-autoremoved, which breaks horizontal scrolling.npm run version:checkfails onmaintoo (docker-compose images are 0.2.0 while the packages are 0.3.0). It is unrelated to this PR, so I left it alone.Checklist
feature/,fix/,chore/,docs/) — see CONTRIBUTING.mdyarn lintpasses (run fromweb/)yarn typecheckpasses (run fromweb/)yarn format:checkpasses (run fromweb/)yarn test(470 passed, 4 new incomponents/ui/table.test.ts) andyarn build(with the CI placeholder env) also pass.🤖 Generated with Claude Code