# HTMLElement and Link Extensions

Layout and scroll helpers on `HTMLElement.prototype`, plus navigation helpers on `HTMLLinkElement.prototype`.

## HTMLElement

Source: `src/prototype/HTMLElement.ts`

| Method / Property | Description |
| --- | --- |
| `el._display(value)` | Chainable `style.display = value` |
| `el.width(v)` / `height(v)` / `paddingTop(v)` / `paddingLeft(v)` / `paddingBottom(v)` / `paddingRight(v)` / `marginTop(v)` / `marginLeft(v)` / `marginBottom(v)` / `marginRight(v)` | Chainable numeric style setters; a bare number/numeric-string gets `px` appended automatically |
| `el.padding(top, right?, bottom?, left?)` / `el.margin(...)` | CSS-shorthand-style chainable setter (1–4 args, same fallback rules as the `padding`/`margin` CSS property) |
| `el.scrollToX(value, animation?)` / `el.scrollToY(value, animation?)` | Scrolls to an absolute offset (clamped to content bounds), optionally with `behavior: "smooth"` |
| `el.scrollToT(animation?)` / `el.scrollToB(animation?)` | Scroll to the top / bottom edge |
| `el.scrollToL(animation?)` / `el.scrollToR(animation?)` | Scroll to the left / right edge |

## HTMLLinkElement

Source: `src/prototype/HTMLLinkElement.ts`

| Method | Description |
| --- | --- |
| `a._go(href?)` | Chainable: sets `href` (if given) and navigates in the current tab (`target = "_self"`) |
| `a._open(href?)` | Chainable: sets `href` (if given) and navigates in a new tab (`target = "_blank"`) |
