SD-2663 - feature: support table of contents hovering#3333
Conversation
Codecov Report✅ All modified and coverable lines are covered by tests. 📢 Thoughts on this report? Let us know! |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 4544d0019d
ℹ️ About Codex in GitHub
Codex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".
luccas-harbour
left a comment
There was a problem hiding this comment.
hey @chittolinag!
codex flagged this issue below which I had noticed while testing this manually: https://www.loom.com/share/8047b874a3894628bbc6d13936ee8f43
you can see as I move the mouse around the TOC, the background flashes.
- [P2] Preserve TOC hover while crossing entry gaps — packages/super-editor/src/editors/v1/core/presentation-editor/PresentationEditor.ts:6773-6781
When the cursor moves from one TOC entry into the paragraph-spacing gap,relatedTargetis the underlying page/container rather than another.superdoc-toc-entry(the gap filler is a pseudo-element, not a DOM entry), so this immediately clearstoc-group-hover. That makes the intended continuous grey hover block disappear/flicker in the exact spacing gap that--toc-gap-belowis trying to cover; keep the group active while the pointer is inside the measured gap or otherwise make the gap participate in the hover target.
claude found some other things that I thought were relevant. I added them as inline comments, hopefully they should be easy fixes!
thanks!
There was a problem hiding this comment.
1 issue found across 14 files
Reply with feedback, questions, or to request a fix.
Fix all with cubic | Re-trigger cubic
Co-authored-by: cubic-dev-ai[bot] <191113872+cubic-dev-ai[bot]@users.noreply.github.com>
…re-support-table-of-contents-interactions
|
🎉 This PR is included in superdoc-cli v0.17.0 The release is available on GitHub release |
|
🎉 This PR is included in superdoc-sdk v1.16.0 |
|
🎉 This PR is included in @superdoc-dev/mcp v0.12.0 The release is available on GitHub release |
|
🎉 This PR is included in superdoc v1.40.0 The release is available on GitHub release |
|
🎉 This PR is included in @superdoc-dev/react v1.11.0 The release is available on GitHub release |
|
🎉 This PR is included in vscode-ext v2.12.0 |
Introducing a new hover state for TOCs. Like MS Word does, when you hover in a TOC, we provide a visual feedback to the user with a grey background.