import type { RefObject } from 'react'; /** Domain object noun for XYO UI events (payload, address, schema, etc.). */ export type EventNoun = 'payload' | 'boundwitness' | 'address' | 'hash' | 'signature' | 'schema'; /** Extends {@link EventNoun} with additional string nouns when provided. */ export type ExtendEventNoun = Extension extends string ? Extension : EventNoun; /** Verb describing the user interaction for an XYO UI event. */ export type EventVerb = 'click' | 'favorite'; /** Optional data attached to a dispatched XYO UI event. */ export interface EventData { sourceEvent?: globalThis.Event; } /** Structured XYO UI event with noun, verb, and optional data. */ export interface Event { data?: TData; noun: TNoun; sourceEvent?: globalThis.Event; verb: TVerb; } /** Function signature for dispatching structured XYO UI events. */ export type EventDispatch = (noun: TNoun, verb: TVerb, data?: TData, sourceEvent?: globalThis.Event) => boolean | void; /** Hook that listens for and dispatches structured XYO UI events on an element. */ export declare const useEvent: (listener?: EventDispatch, sharableRef?: RefObject) => [RefObject, EventDispatch]; //# sourceMappingURL=useEvent.d.ts.map