-
Notifications
You must be signed in to change notification settings - Fork 53
feat: comment highlight config #1798
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 30c0a7d3fe
ℹ️ About Codex in GitHub
Your team has set up Codex to 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 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| return `${color}${alpha}`; | ||
| const highlightColors = editor.options.comments?.highlightColors || {}; | ||
| const highlightOpacity = editor.options.comments?.highlightOpacity || {}; | ||
| const isActive = activeThreadId === threadId; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Preserve loose ID match for active highlight detection
The new strict comparison in getHighlightColor makes active detection depend on activeThreadId and threadId having the same type. Elsewhere IDs are explicitly matched with loose equality (e.g., commentId == id in packages/superdoc/src/stores/comments-store.js), which implies numeric IDs can flow in from external data/imports. If a mark stores a numeric commentId but the active thread is set from a string ID (or vice versa), isActive will never be true and the active highlight/opacity will never show. Consider normalizing IDs to a consistent type or using a loose comparison here.
Useful? React with 👍 / 👎.
# [1.8.0-next.7](v1.8.0-next.6...v1.8.0-next.7) (2026-01-21) ### Bug Fixes * **search:** preserve leading/trailing whitespace in flexible matches ([#1788](#1788)) ([c5d6751](c5d6751)) ### Features * comment anchor helpers ([#1796](#1796)) ([595bdc6](595bdc6)) * comment highlight config ([#1798](#1798)) ([aa7e957](aa7e957)) * **comments:** add position-ordered comments getter ([#1774](#1774)) ([bdac914](bdac914))
|
🎉 This PR is included in version 1.8.0-next.7 🎉 The release is available on:
Your semantic-release bot 📦🚀 |
No description provided.