What problem does it solve?
This Skill solves the challenge of aligning interactive HTML elements (inputs, iframes, videos, custom UI) with PixiJS objects as the canvas transforms and the scene graph moves.
Core Features & Use Cases
- DOMContainer-based HTML overlays: Positions an HTMLElement over the PixiJS canvas and keeps it synchronized to a scene-graph display object's transform.
- Anchor-driven placement and CSS transforms: Uses an
anchor to define the element’s origin (top-left, center, bottom-right) and applies PixiJS transforms as CSS transform/opacity updates.
- DOMPipe integration and pointer-events control: Registers the required
pixi.js/dom side-effect (or combined import), syncs visibility, and supports correct click behavior by setting pointer-events appropriately.
Use case example: You need a rich in-canvas search box (or an embedded settings iframe) that moves, scales, and fades exactly with a PixiJS sprite while remaining a real DOM element for form submission and accessibility.
Quick Start
Create an input element, import pixi.js/dom, instantiate DOMContainer with the input and an anchor (e.g., 0.5), set its position to your desired scene coordinates, and add it to the PixiJS stage.