jon.recoil.org

Module Js_top_worker_message.Widget_viewSource

Serializable view descriptions for interactive widgets.

No closures, no JS references. Event handlers are symbolic string identifiers resolved by the worker's handler registry.

Sourcetype event_id = string
Sourcetype attr =
  1. | Property of string * string
  2. | Style of string * string
  3. | Class of string
  4. | Handler of string * Js_top_worker_message.Widget_view.event_id
    (*

    event name, handler id

    *)
Sourcetype node =
  1. | Text of string
  2. | Element of {
    1. tag : string;
    2. attrs : Js_top_worker_message.Widget_view.attr list;
    3. children : Js_top_worker_message.Widget_view.node list;
    }
  3. | Managed of {
    1. kind : string;
    2. config : string;
    }
Sourcetype event_msg = {
  1. handler_id : Js_top_worker_message.Widget_view.event_id;
  2. event_type : string;
  3. value : string option;
}