Documentation
    Preparing search index...

    Function dispatchThreePhase

    • Dispatches event along path (root first, target last) in the three phases of §72.

      1. Capture — root → target, delivering captureKey.
      2. Target — the last path entry, which receives its capture-keyed listeners at the end of phase 1 and its plain-keyed listeners at the start of phase 3. (The DOM does the same: a capture listener registered on the target fires in the at-target phase, before that node's bubble listeners.)
      3. Bubble — target → root, delivering type.

      SceneInputEvent.stopPropagation is honoured between nodes: the node dispatching when it is called finishes its listener list, and no further node is visited — in either direction. A capture listener that stops propagation therefore also prevents the target from seeing the event.

      An empty path dispatches nothing, which is what makes a resolution failure (a pointer that hit nothing, a keystroke with nothing focused) a no-op rather than a special case at every call site.

      CaptureKey is constrained to type's own "capture:"-prefixed key, so the two arguments cannot come from different event families (see the module header). Both call sites already pass CAPTURE_KEYS[type], which is exactly that key.

      Type Parameters

      • BubbleKey extends keyof NodeEventMap
      • CaptureKey extends
            | "capture:pointerdown"
            | "capture:pointerup"
            | "capture:pointermove"
            | "capture:pointercancel"
            | "capture:click"
            | "capture:keydown"
            | "capture:keyup"

      Parameters

      Returns void