Locator
<Locator name="p" value="1,0.5"> inside a <Plot> -- a point ON the picture that you drag about it, Wolfram's Locator. It sits over the plot area in the plot's own coordinates, so the binding _p is the List [x, y] where the dot is (or the complex x + y i, with complex), and a template that reads _p gets a point on the curve's axes. The arrows nudge it by a hundredth of the window, Shift ten times that, Alt a tenth.
``html <DynamicModule> <Plot value="Sin(x)" domain="-6.283,6.283"> <Locator name="p" value="0,0" /> </Plot> The dot is at <Dynamic value="_p" />. </DynamicModule> ``
A <Slider2D> is the same control on a square of its own, off the picture.
Props
| Prop | Type | Default | Notes |
|---|---|---|---|
name | string | "" | The binding this point drives: name="p" fills the wildcard _p.reflects |
value | string | "0,0" | The starting point, x,y -- or a+bi with complex. |
complex | boolean | false | Bind a complex number x + y i rather than a list.reflects |
As a web component
Plain custom elements, no framework required: import @enumeratio/frontend for the side effect and write <locator-box> in any HTML. Attributes are kebab-case and always strings; the props table above names each one's attribute where it differs from its prop.