🐛(telemetry) tag in-room permission failures with their own path

Since `ToggleDevice` renders on both the join screen and in the
room, `requestDevicePermission` was reporting in-room denials
through the join-preview handler, inflating the `join_preview_failure`
funnel.

Rename `onJoinPreviewError` to `onMediaPermissionError` and thread
a `path` parameter through, derived from `ToggleDevice`'s existing
`context` prop. In-room failures are now reported under a new
`room_media_failure` code, keeping `join_preview_failure` intact
for existing dashboards.
This commit is contained in:
lebaudantoine
2026-08-11 20:38:11 +02:00
committed by aleb_the_flash
parent 7d1ce5f215
commit ff7a1a4f33
3 changed files with 27 additions and 12 deletions
@@ -19,6 +19,7 @@ export const captureEvent = (
export type LogCode =
// media
| 'join_preview_failure'
| 'room_media_failure'
| 'livekit_room_error'
| 'device_switch_failure'
| 'permission_poll_failure'