Skip to content

docs(web-views): document how browser view events are delivered - #5

Open
Klo1337 wants to merge 1 commit into
mafia2online:mainfrom
Klo1337:docs/browser-view-events
Open

Klo1337 wants to merge 1 commit into
mafia2online:mainfrom
Klo1337:docs/browser-view-events

Conversation

@Klo1337

@Klo1337 Klo1337 commented Aug 30, 2026

Copy link
Copy Markdown
Contributor

The client contract declares the Browser*Event payload interfaces (BrowserInputFocusChangeEvent, BrowserCursorChangeEvent, BrowserResourceBlockedEvent, …), but they are not in EventMap and Web.on does not receive them, so the reference gives no way to find out how to subscribe.

Verified on a live server (build 1.0.0-3a40a8f): they are dispatched to the shared Events.on table under camelCase names derived from the payload interface (browserInputFocusChange, browserCursorChange), with the payload object as a single argument; a parallel Web.on(viewId, ...) subscription with the same names never fires.

This adds a short subsection to the web-views guide, right after the paragraph that points at the payload family in the client reference: the delivery channel, the viewId filtering caveat, and the main practical use (browserInputFocusChange as the reliable hotkey gate while typing into a page).

Rebased onto the reorganised guides (the original change targeted guides/events.md, which has since become guides/concepts/events.md; the web-views guide is the better home now that it exists).

@Klo1337
Klo1337 force-pushed the docs/browser-view-events branch from 94510b8 to f0282a6 Compare September 7, 2026 19:39
@Klo1337 Klo1337 changed the title docs(events): document the delivery channel for browser view events docs(web-views): document how browser view events are delivered Sep 7, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant