VirtualElement.prototype.options exposes a select-only readonly getter through the generic HTMLElement base. An autonomous custom element therefore appears to inherit options, even though a browser's generic HTMLElement has no such member. Code preserving native DOM properties then cannot install its own object-valued options prop.
This blocks retained STX component library hydration and property-upgrade regressions while fixing stacksjs/stx#2129. The same getter also returns an empty list for datalist elements instead of their option descendants.
The HTML Standard defines options on select and datalist interfaces. Source regressions reproduce the generic base leak and the datalist failure, while the existing select lookup continues to pass.
Acceptance:
- Keep
optionsoff generic HTMLElement and ordinary/custom element instances. - Expose it on select and datalist constructors and document-created elements.
- Preserve readonly lookup behavior after option changes and cloning, plus select value behavior.
- Preserve the current VirtualElement TypeScript surface while placing the runtime accessor on matching controls.
- Pass relevant and full tests, lint, types, build and normal patch release checks.
- Verify original publication and adopt it normally in STX, retaining its original hydration and upgrade tests.