Repository navigation
feat(screenshare): answering the question that gets asked in every meeting - can you see my screen - #217
Conversation
There was a problem hiding this comment.
Superseded by the review of
95a68ca1.
This review, of 272e221e
💬 Approved with comments — No blocking or warning-level problems. Four INFO notes: visibility reports trust the viewerId in the payload, viewer list rebuilds scale with meeting size, one tsconfig exclude matches no files, and a table header in a skill file is duplicated.
Findings: 4 info (4 are inline comments on the diff)
The decision is advisory: this review is a comment and never approves, blocks or requests changes on the pull request.
🔒 Security: 💬 1 info
Low impact: the viewer identity in visibility reports comes from the payload, not from the message sender.
Recommendation: 💬 Optional Nits
- [INFO] Visibility reports trust
payload.viewerIdinstead of the message sender, so one participant can mark another as viewing (packages/core/src/components/rtk-screenshare-view/rtk-screenshare-view.tsx:191)
View full review
rtk-screenshare-view.tsx:191-211:handleScreenShareVisibilityNotificationreadsviewerIdfrom the broadcast payload. It checks the id againsttrackedViewerIds, but never against the participant who actually sent the message. Any participant who knows theproducerIdcan mark another participant as viewing or not viewing. The only effect is a wrong indicator on the sharer's screen; no data is exposed.
📋 Code Quality: 💬 1 info
One harmless tsconfig exclude that matches no files.
Recommendation: 💬 Optional Nits
- [INFO]
src/**/*.test.jsexclude in packages/core/tsconfig.json matches no files (packages/core/tsconfig.json:22)
View full review
packages/core/tsconfig.json:22: the newsrc/**/*.test.jsexclude matches no files. The new test isscripts/screenshare-visibility.test.js, which is outsidesrc.
⚡ Performance: 💬 1 info
The sharer's viewer bookkeeping rebuilds arrays on every event, which only matters in very large meetings.
Recommendation: 💬 Optional Nits
- [INFO] Viewer lists are rebuilt as O(n) arrays on every join, leave and visibility message (
packages/core/src/components/rtk-screenshare-view/rtk-screenshare-view.tsx:138)
View full review
- The sharer rebuilds
trackedViewerIdsandnotActivelySeenByon every participant join or leave and on every visibility message. When a share starts, each of the n viewers sends one message, so the total work is O(n²) plus n re-renders. That is negligible at typical meeting sizes. If large meetings matter, keep the viewer ids in aSetand batch the updates.
📝 Documentation: 💬 1 info
Duplicated table header in the test setup skill.
Recommendation: 💬 Optional Nits
- [INFO] Duplicated
Goal | Commandheader in the commands table (.opencode/skills/realtimekit-test-setup/SKILL.md:23)
View full review
.opencode/skills/realtimekit-test-setup/SKILL.md:23-24repeats the table header and separator.
✅ All other checks passed
📖 AGENTS.md: ✅ LGTM
The AGENTS.md additions are consistent with the repository conventions.
Reviewed commit: 272e221e
There was a problem hiding this comment.
Superseded by the review of
66df4a8c.
This review, of 95a68ca1
💬 Approved with comments — No blocking or warning-level problems. Two INFO notes remain open: visibility reports trust the viewerId in the payload, and the viewer lists are rebuilt as O(n) arrays on every update.
Findings: 2 info
The decision is advisory: this review is a comment and never approves, blocks or requests changes on the pull request.
🔒 Security: 💬 1 info
One INFO note from the last review is still open: visibility reports trust the viewerId in the payload
Recommendation: 💬 Optional Nits
- [INFO] Visibility reports trust
payload.viewerIdinstead of the message sender, so one participant can mark another as viewing (packages/core/src/components/rtk-screenshare-view/rtk-screenshare-view.tsx:191)
View full review
rtk-screenshare-view.tsx:191-211:handleScreenShareVisibilityNotificationusespayload.viewerIdand never checks it against the participant who sent the message. Any participant who knows theproducerIdcan make the sharer's indicator show the wrong state. No data is exposed.
⚡ Performance: 💬 1 info
One INFO note from the last review is still open: viewer lists are rebuilt on every update
Recommendation: 💬 Optional Nits
- [INFO] Viewer lists are rebuilt as O(n) arrays on every join, leave and visibility message (
packages/core/src/components/rtk-screenshare-view/rtk-screenshare-view.tsx:138)
View full review
rtk-screenshare-view.tsx:138-160, 198-210: on every join, leave and visibility message, the sharer rebuildstrackedViewerIdsandnotActivelySeenByand scans them linearly. When a share starts, the total work is O(n²). This is negligible at typical meeting sizes.
✅ All other checks passed
📖 AGENTS.md: ✅ LGTM
The AGENTS.md additions are consistent with the repository conventions.
📋 Code Quality: ✅ LGTM
The tsconfig exclude note no longer applies, because that file is not changed in this pull request. Every listener added in meetingChanged and participantChanged has a matching remove in cleanup, and the spec tests check this. The generated components.d.ts and Angular wrapper changes match the component source.
📝 Documentation: ✅ LGTM
The commands table in .opencode/skills/realtimekit-test-setup/SKILL.md now has a single header row.
Reviewed commit: 95a68ca1
There was a problem hiding this comment.
Superseded by the review of
57c41853.
This review, of 66df4a8c
💬 Approved with comments — No blocking or warning-level problems. Two INFO notes remain open: visibility reports trust the viewerId in the payload, and the viewer lists are rebuilt as O(n) arrays on every update.
Findings: 2 info
The decision is advisory: this review is a comment and never approves, blocks or requests changes on the pull request.
🔒 Security: 💬 1 info
One INFO note from the last review is still open: visibility reports trust the viewerId in the payload
Recommendation: 💬 Optional Nits
- [INFO] Visibility reports trust
payload.viewerIdinstead of the message sender, so one participant can mark another as viewing (packages/core/src/components/rtk-screenshare-view/rtk-screenshare-view.tsx:191)
View full review
rtk-screenshare-view.tsx:191-211:handleScreenShareVisibilityNotificationusespayload.viewerIdand never checks it against the participant who sent the message. Any participant who knows theproducerIdcan make the sharer's indicator show the wrong state. No data is exposed.
⚡ Performance: 💬 1 info
One INFO note from the last review is still open: viewer lists are rebuilt on every update
Recommendation: 💬 Optional Nits
- [INFO] Viewer lists are rebuilt as O(n) arrays on every join, leave and visibility message (
packages/core/src/components/rtk-screenshare-view/rtk-screenshare-view.tsx:138)
View full review
rtk-screenshare-view.tsx:138-160, 198-210: on every join, leave and visibility message, the sharer rebuildstrackedViewerIdsandnotActivelySeenByand scans them linearly. When a share starts, the total work is O(n²). This is negligible at typical meeting sizes.
✅ All other checks passed
📖 AGENTS.md: ✅ LGTM
The AGENTS.md additions are consistent with the repository conventions.
📋 Code Quality: ✅ LGTM
The tsconfig exclude note no longer applies, because that file is not changed in this pull request. Every listener added in meetingChanged and participantChanged has a matching remove in cleanup, and the spec tests check this. The generated components.d.ts and Angular wrapper changes match the component source.
📝 Documentation: ✅ LGTM
The commands table in .opencode/skills/realtimekit-test-setup/SKILL.md now has a single header row.
Reviewed commit: 66df4a8c — same changes as 95a68ca1, so this is that commit's review (no new review was run; line numbers are as of 95a68ca1)
There was a problem hiding this comment.
💬 Approved with comments — Both notes from the last review are fixed, and no correctness or security problems were found. One suggestion remains: restore the missing final newline in packages/core/package.json.
Findings: 1 suggestion (1 is an inline comment on the diff)
The decision is advisory: this review is a comment and never approves, blocks or requests changes on the pull request.
📋 Code Quality: 💬 1 suggestion
No correctness problems; one end-of-file newline nit.
Recommendation: 💬 Optional Nits
- [SUGGESTION] packages/core/package.json no longer ends with a newline, a change unrelated to the SDK version bump. (
packages/core/package.json:99)
View full review
packages/core/package.json: the diff ends with\ No newline at end of file. The only intended change in this file is the bump of@cloudflare/realtimekitto^2.2.0-staging.10.- Every listener added in
meetingChangedandparticipantChangedis removed again incleanupMeetingandcleanupParticipant.disconnectedCallbackcalls both cleanups, and a spec test checks that no listeners remain. - The generated
components.d.tsand Angular wrapper changes match the component source.
✅ All other checks passed
🔒 Security: ✅ LGTM
handleScreenShareVisibilityNotification now uses the peerId of the broadcastedMessage event instead of a viewer ID in the payload. It also checks four things:
sharerIdequalsmeeting.self.id.producerIdmatches the tracked screen-share producer.visibleis a boolean.- The sender is in
participants.joined.
A participant can now only change its own entry in the sharer's indicator.
📖 AGENTS.md: ✅ LGTM
The skills now live under .agents/skills, as the inline comment requested, and the AGENTS.md additions match.
⚡ Performance: ✅ LGTM
Viewer tracking now keeps a single pendingViewerIds Set, updated in O(1) per message. The render loop stops once it has the avatars it needs to show.
📝 Documentation: ✅ LGTM
No documentation issues.
Reviewed commit: 57c41853
# [2.2.0-staging.4](https://github.com/cloudflare/realtimekit-ui/compare/@cloudflare/realtimekit-ui-v2.2.0-staging.3...@cloudflare/realtimekit-ui-v2.2.0-staging.4) (2026-11-26) ### Features * **screenshare:** answering the question that gets asked in every meeting - can you see my screen ([#217](#217)) ([33a08b4](33a08b4)) skip-checks: true
|
🎉 This PR is included in version 2.2.0-staging.4 🎉 The release is available on GitHub release Your semantic-release bot 📦🚀 |
Description
No one is viewing

Everyone is viewing

Only some are viewing
