RFC 0075 — Pinned columns
Status: implemented (2026-11-29) · Target: 0.65.0 · builds on RFC 0068, RFC 0070 and RFC 0074 · see Decisions
Summary
A wide list scrolls sideways: twelve columns of an invoice, a customer's twenty fields. Once it scrolls, the column the row is known by (the number, the name) is gone, and the user reads "12 400,50 · Open · 2026-11-05" without knowing whose. RFC 0068 left "pinning a column to the left while the rest scrolls" for later; a spreadsheet's frozen column is what users reach for.
This RFC lets a Table pin columns at its start:
<Table
rows={invoices}
choosable
persist="invoices"
columns={[{ key: "number", pin: true }, "customer", "due", "status", "amount", "note", …]}
/>
- A column's
pin: true(the app's) keeps it at the table's start while the rest scroll under it; withchoosable, the user pins and unpins from the Columns menu and a header's menu (Pin Customer, Unpin Customer). - The pinned columns go first, in their order; the selection's checkboxes are pinned with them. A shadow at their edge says the rest have scrolled.
- The user's pins are kept with the columns' widths and order (
persist, RFC 0068) and in a saved view's columns (RFC 0070). - The actions stay at the end, pinned there while the table scrolls, so a row's Edit is always in reach.
Motivation
- A row is read by its key. A number or a name is what makes the rest of the row mean something; scrolled away, the row is anonymous.
- The width is the user's. RFC 0068 lets the user show twenty columns and resize them (RFC 0012's grips); the more they show, the more the table scrolls, and the more the first column matters.
- The actions too. A row's buttons in the last column are a scroll away on a wide table: the user scrolls right to act, then left to see which row they're on.
- Grids do it, and the users know it. Excel's Freeze First Column, Numbers', and every data grid's.
Current state (0.65, with RFCs 0073 and 0074)
Table's body is a<table>in a.scrollthat overflows sideways; the header row is sticky at the top (position: sticky; top: 0).choosable(RFC 0068) gives a Columns menu to show, hide and order the columns;persistkeeps{ widths, hidden, order }; a column'srequiredkeeps it shown. A header's right click opens the menu (RFC 0074's header menu has Group by there).arrange(cols, choice)ininternal/columns.jsmakes{ all, shown }in the user's order. A view'scolumnsis{ hidden, order }.- Widths come from
resizable(a column'swidth, or the user's), else the browser's layout. - RFC 0074's group headers span the first columns up to the first with a total.
Design
pin
A column's pin: true pins it. The user's choice, with choosable,
overrides the app's per column, as hidden does: choice.pinned is the
keys pinned, kept beside hidden and order.
The shown columns are arranged as: the pinned ones, in the user's order, then the rest, in theirs. Pinning a column moves it to the end of the pinned ones; unpinning moves it to the start of the rest. Order within each part is RFC 0068's, by drag or Alt+↑/↓.
What's drawn
- Sticky at the start: each pinned column's cells (header, body, foot,
RFC 0074's group headers) are
position: stickywithinset-inline-startthe sum of the widths before it, on the surface's background so the scrolled cells pass under them. The selection's checkbox column is pinned first whenever any column is. - The edge: while the table is scrolled sideways, the last pinned column has a shadow on its end edge; at the start, none.
- The actions column is pinned at the end
(
inset-inline-end: 0) while the table overflows, with the same shadow on its start edge while there's more to its left. - Widths: a pinned column's offset needs the widths before it. The
table measures the pinned headers (a
ResizeObserveron them) and sets each offset as a CSS variable; withresizable, the user's widths are used as they're set. - Too much pinned: when the pinned columns are wider than half the table's visible width, the ones past it scroll with the rest, until there's room again: a pin can't leave no room for what it pins against.
- Grouped (RFC 0074): a group's header cell is pinned too, so its name and count stay in view; its totals' cells scroll with their columns.
The menus
- The Columns menu (
choosable) has a pin button beside each column, as it has ↑/↓: Pin / Unpin (amenuitemcheckbox's own button, its state said: "Customer, pinned"). Alt+←/→ on an item pins and unpins. - A header's menu (a right click, Shift+F10; RFC 0074) has
Pin {column} or Unpin {column}, with
choosable. - A required column (RFC 0068) can be pinned and unpinned like any other. Reset columns takes the pins back to the app's.
Each is said in the table's live region: "Customer pinned", "Customer unpinned".
Kept and viewed
persistkeepspinnedbesidehiddenandorder; an older value without it is the app's pins.- A saved view's
columns(RFC 0070) is{ hidden, order, pinned }: a view made in 0.63 or 0.64 has none, which is the app's.
Focus and the keys
A focused cell's control scrolled under the pinned columns is brought
out: the scroll area's scroll-padding-inline-start is the pinned width,
so Tab into a cell's button or field scrolls it clear of them.
The row keys (↑/↓, Enter, Space) are unchanged.
On paper
Pinning is for a screen: printed (RFC 0062) or in a Report (RFC 0064),
the columns are in their order, pinned ones first, and nothing is sticky.
Implementation plan
internal/columns.js:pinnedinarrange(the order, the app's and the user's pins),keptOfreadingpinned,pinToggled(arranged, key). Tested alone.Table.svelte:pinon a column,choice.pinned, the sticky offsets (measured), the edge shadows, the actions pinned at the end, the Columns menu's pin buttons and Alt+←/→, the header menu's items,scroll-padding, the words (en, nb).views.js:pinnedin a view's columns.make:resource: the index view pins its first column (the record's link).- Docs:
table.md(Pinned columns), the ui skill; the CHANGELOG; the roadmap.
Open questions
- Pinned at the start only, or at the end too? Recommendation: the app's and the user's pins at the start; the actions column alone at the end. A column the user wants at the end is rare, and two pinned edges halve the room to scroll in.
- The actions pinned at the end by default?
Recommendation: yes, while the table overflows: it's what a row's
buttons are for, and they're narrow.
pinActions={false}lets them scroll. - Pin from the Columns menu and the header's menu, both?
Recommendation: both, with
choosable: the menu is where a column's other choices are, the header is where the user is looking. make:resourcepins the first column? Recommendation: yes: it's the record's link, the column a row is known by, and a resource's list grows wide as fields are added.- A limit on how much is pinned? Recommendation: half the visible width; past it, the pins that don't fit scroll until there's room. A fixed number of columns doesn't know how wide they are.
As built
internal/columns.js:arrangeputs the pinned columns first and answerspinned(the keys) andpinsChosen;pinToggled(arranged, key);keptOfreadspinned. A choice keepspinnedonly once the user has pinned or unpinned, so the app's pins stay the app's until then (and a choice kept by 0.63 or 0.64 has them).- The offsets are measured from the header cells (a
ResizeObserveron them and on the scroll area) and set as each cell'sinset-inline-start; the__pickcolumn first. The half-width limit uses the scroll area'sclientWidth; while that's unknown, none. - A header's right click with
choosableis now its menu (the runtime's context menu): Group by (RFC 0074), Pin/Unpin, and Columns, which opens the Columns menu as the right click did in 0.63. - The Columns menu's pin is a button beside ↑/↓ (for the pointer), and Alt+← pins, Alt+→ unpins on an item; a pinned item says ", pinned" to a screen reader.
- The pinned cells' background is
--elyra-table-bg, the window's (--elyra-bg) by default; the header, the foot and a group's header keep the surface's. The header row is above the pinned body cells as the body scrolls up. - Checked in Chromium: the reference's example scrolled 400 px, the pinned Number where it was, Customer scrolled under it, the edge's shadow, and the actions at the end; and in the resource smoke test, the list's first column sticky at 0.
Decisions
Accepted 2026-11-29, with every recommendation:
- The app's and the user's pins at the start; the actions column alone at the end.
- The actions pinned at the end while the table overflows;
pinActions={false}lets them scroll. - Pinning from the Columns menu and a header's menu, with
choosable. make:resource's lists pin their first column.- The pinned columns take at most half the visible width; the ones past it scroll until there's room.
Not in this RFC
- Pinned rows (a row kept at the top while the rest scroll), beyond the header and RFC 0074's groups.
- Columns pinned at the end other than the actions.
- Virtual scrolling of the columns (rendering only those in view).
Alternatives considered
- Two tables side by side, a pinned one and a scrolling one, as older
grids did. The rows' heights must then be kept equal by script, the
keys and a screen reader see two tables, and selection spans both.
position: stickykeeps one table. - Pin by count (
pinned={2}), the first n columns. Simple, but the user's order changes which columns those are; a pin belongs to a column.