Fix types + build issue

This commit is contained in:
Stephen Hellings 2026-03-08 23:38:12 -04:00
parent e03fe3739f
commit d184ab69e4
2 changed files with 10 additions and 10 deletions

View file

@ -1,8 +1,8 @@
{ {
"name": "wo-types", "name": "@wl-wo/wo-types",
"module": "index.ts", "module": "index.ts",
"type": "module", "type": "module",
"private": true, "version": "0.2.0",
"devDependencies": { "devDependencies": {
"@types/bun": "latest" "@types/bun": "latest"
}, },

View file

@ -227,13 +227,13 @@ export interface Compositor {
/** /**
* Create a damage helper for optimized rendering * Create a damage helper for optimized rendering
*/ */
createDamageHelper?(options: RendererDamageHelperOptions): RendererDamageHelper; createDamageHelper(options: RendererDamageHelperOptions): RendererDamageHelper;
/** /**
* Forward a keyboard event from a canvas window to the compositor. * Forward a keyboard event from a canvas window to the compositor.
* evdevKey is the Linux evdev keycode; time is milliseconds. * evdevKey is the Linux evdev keycode; time is milliseconds.
*/ */
forwardKeyboard?(windowName: string, evdevKey: number, pressed: boolean, time: number): void; forwardKeyboard(windowName: string, evdevKey: number, pressed: boolean, time: number): void;
/** /**
* Quit the compositor * Quit the compositor
@ -253,35 +253,35 @@ export interface Compositor {
/** /**
* Submit a damaged frame from the renderer * Submit a damaged frame from the renderer
*/ */
submitDamageFrame?(payload: DamageFramePayload): Promise<{ ok: boolean }>; submitDamageFrame(payload: DamageFramePayload): Promise<{ ok: boolean }>;
/** /**
* Subscribe to Wayland surface pixel buffer updates from the compositor. * Subscribe to Wayland surface pixel buffer updates from the compositor.
* The compositor captures each Wayland window's content offscreen and sends * The compositor captures each Wayland window's content offscreen and sends
* raw ARGB8888 pixel data for the client to render. * raw ARGB8888 pixel data for the client to render.
*/ */
onSurfaceBuffer?(callback: (data: SurfaceBufferData) => void): Unsubscribe; onSurfaceBuffer(callback: (data: SurfaceBufferData) => void): Unsubscribe;
/** /**
* Subscribe to notification events from the compositor * Subscribe to notification events from the compositor
*/ */
onNotification?(callback: (data: NotificationData) => void): Unsubscribe; onNotification(callback: (data: NotificationData) => void): Unsubscribe;
/** /**
* Forward relative mouse motion from the web UI to the compositor. * Forward relative mouse motion from the web UI to the compositor.
*/ */
forwardRelativePointer?(windowName: string, dx: number, dy: number): void; forwardRelativePointer(windowName: string, dx: number, dy: number): void;
/** /**
* Subscribe to pointer lock requests from the compositor. * Subscribe to pointer lock requests from the compositor.
*/ */
onPointerLockRequest?(callback: (data: { window: string; lock: boolean }) => void): Unsubscribe; onPointerLockRequest(callback: (data: { window: string; lock: boolean }) => void): Unsubscribe;
/** /**
* Subscribe to generic portal requests so clients can provide custom UI. * Subscribe to generic portal requests so clients can provide custom UI.
*/ */
onPortalRequest?(callback: (data: PortalRequestEvent) => void): Unsubscribe; onPortalRequest(callback: (data: PortalRequestEvent) => void): Unsubscribe;
} }
/** Alias for Compositor to match preload.ts imports */ /** Alias for Compositor to match preload.ts imports */