Skip to content

GhostBoard reference ​

Package: @ghostvue/vue. Status: experimental (stability policy).

Headless board over app-owned columns and cards: columns render as headed sections and cards as ordered lists inside one named, focusable scroll region. Each movable card offers a native Move to… button that opens a modal dialog with Column and Position fields; confirming calls requestMove once with stable IDs ({ cardId, fromColumnId, toColumnId, placement }) and the application answers accepted, after applying the move to its records, or rejected with a reason that stays visible. The board never sorts, clones or mutates records, keeps focus on a card by ID through reorders, and announces outcomes. Direct dragging is not included.

Generated from the component manifest. Edit the manifest or Vue source, then rebuild the docs.

All component references

Props ​

NameTypeDefaultRequiredDescription
cardsreadonly TCard[]—YesApp-owned cards. Order within a column is array order. Never sorted, filtered, cloned or mutated.
columnsreadonly BoardColumn[]—YesApp-owned columns. Column order is array order. Never sorted, cloned or mutated.
describeMove((request: BoardMoveRequest, card: TCard) => BoardMoveNotice | undefined)—NoGuidance shown for the current complete, changed choice before confirmation. Synchronous and free of side effects; re-evaluated reactively.
headingLevelBoardHeadingLevel3NoLevel of each column heading.
messagesPartial<BoardMessages>—NoOverrides for labels, descriptions and announcements.
moveTransitionstring—NoClass prefix for animating reorders within a column: `<prefix>-move` is applied while a card slides from its previous on-screen position.
portalToGhostPortalTarget"body"NoTeleport target for the dialog and its select lists, so they can render inside a theme scope.
requestMove((request: BoardMoveRequest) => BoardMoveOutcome | PromiseLike<BoardMoveOutcome>)—NoMakes the board movable: called once per confirmed, changed move and answered with an outcome or a promise of one. Without it no card offers Move to….
suggestPlacement((context: BoardPlacementContext<TCard>) => BoardPlacement | undefined)—NoInitial placement each time a destination column is chosen. An invalid or missing suggestion falls back to the current position in the card's own column and to the end of any other column.

Emits ​

None declared.

Models ​

None declared.

Slots ​

NameDescription
cardCard content. May hold the app's own links and buttons. Bindings: `BoardCardSlotProps<TCard>` (`card`, `position`, `pending`, `moveError`). Default: `card.title`.
columnEmptyContent of a column with no cards. Default: `messages.emptyColumn`.
columnHeadingColumn heading content. Must render text; it names the column. Default: the title and count.
emptyContent of the scroll region when `columns` is empty.

Slot props: card ​

None declared.

Slot props: columnEmpty ​

NameTypeDescription
columnBoardColumnThe app's column record, unchanged.
countnumberNumber of cards supplied for the column.

Slot props: columnHeading ​

NameTypeDescription
columnBoardColumnThe app's column record, unchanged.
countnumberNumber of cards supplied for the column.

Slot props: empty ​

None declared.

Exposed members ​

NameTypeDescription
announce(message: string) => voidSends a polite message through the board's status element.
focusCard(id: BoardCardId) => booleanMoves focus to the card's Move to… button, or to the card itself when it has none, and scrolls it into view. `false` when the card is not shown.
openMove(id: BoardCardId, initial?: import('./ghost-board').BoardMoveInitial) => booleanOpens Move to… for the card, as its button does, so an app menu or shortcut can start a move. `initial` preselects a destination column and optionally a placement; it is validated like a suggestion and still needs confirmation. `false` when the card is not shown, is not movable, `requestMove` is not bound, or a dialog is already open.

Parts and data attributes ​

AttributeValueDescription
data-partrootOuter element. Consumer class and style land here.
data-partregionThe named role="region" scroll surface (tabindex="0"). Every other fallthrough attribute, including aria-label or aria-labelledby, lands here. Lay out columns with CSS on this part.
data-partcolumnA column <section> named by its heading (tabindex="-1" for focus recovery only).
data-partcolumn-headingThe column heading (h3 by default; headingLevel). Holds the columnHeading slot.
data-partcolumn-countDefault count text inside the heading.
data-partcardsThe <ol> of a column with cards. An empty column renders no list.
data-partcardA card <li> (tabindex="-1" for programmatic focus only).
data-partcard-contentWrapper of the card slot.
data-partmove-buttonNative Move to… button after the card content. Its name is the visible label plus the card title.
data-partmove-statusPending text or a late rejection reason on the card; describes the Move to… button.
data-partcolumn-emptyContent of a column with no cards (columnEmpty slot).
data-partstatusVisually hidden polite status element; one in the root and one inside the dialog.
data-ghost-boardpresentPresent on the root.
data-card-idpresentOn cards: the card ID.
data-column-idpresentOn columns: the column ID.
data-emptypresentPresent on a column with no cards.
data-movablepresentPresent on cards that offer Move to….
data-pendingpresentPresent on a card while a request for it is outstanding.
data-move-errorpresentPresent on a card with a rejection that arrived after its dialog closed.
data-board-partdialog, column-field, position-field, move-notice, move-error, move-confirm, move-cancelOn the roots of the reused dialog, field, alert and button parts, which keep their own data-part.
data-board-dialogpresentOn the dialog content: an ID that ties the teleported dialog to its board.
data-board-listcolumn, positionOn the Column and Position select lists, which are teleported with portalTo.
data-toneinfo, warningOn the move notice: the tone describeMove returned.
data-currentpresentOn the Position option that matches where the card already is.

CSS variables ​

None declared.

Accessibility ​

Role: region. APG pattern: https://www.w3.org/WAI/ARIA/apg/patterns/dialog-modal/.

Required ARIA attributes: aria-label, aria-labelledby, aria-describedby, aria-busy.

Keyboard ​

KeyActionAutomated browser test
TabMoves through the scroll region, then each card's own focusable content and its Move to… button, in column order. Inside the dialog, moves between its fields and buttons; focus stays in the dialog.GhostBoard @component:GhostBoard › same-column reorder by keyboard: Tab, Enter, Space, select keys, Escape, and focus on the moved card (@ghostvue/vue)
GhostBoard @component:GhostBoard › late outcomes after focus left keep focus by card ID (@ghostvue/vue)
Shift+TabThe same order backward.GhostBoard @component:GhostBoard › same-column reorder by keyboard: Tab, Enter, Space, select keys, Escape, and focus on the moved card (@ghostvue/vue)
EnterOn a Move to… button, opens the dialog. On Column or Position, opens the list or chooses the focused option. On Move, confirms; on Cancel or Close, activates.GhostBoard @component:GhostBoard › same-column reorder by keyboard: Tab, Enter, Space, select keys, Escape, and focus on the moved card (@ghostvue/vue)
GhostBoard @component:GhostBoard › rejected save: reason shown and announced, dialog stays open, revise and cancel (@ghostvue/vue)
GhostBoard @component:GhostBoard › missing anchor: Position is re-created empty, announced, and a new position is required (@ghostvue/vue)
SpaceOn a Move to… button, opens the dialog. On a dialog button, activates it.GhostBoard @component:GhostBoard › same-column reorder by keyboard: Tab, Enter, Space, select keys, Escape, and focus on the moved card (@ghostvue/vue)
EscapeIn the dialog: an open list closes first; otherwise Cancel while choosing and Close while a request is outstanding. Focus returns to the card's Move to… button.GhostBoard @component:GhostBoard › same-column reorder by keyboard: Tab, Enter, Space, select keys, Escape, and focus on the moved card (@ghostvue/vue)
GhostBoard @component:GhostBoard › late outcomes after focus left keep focus by card ID (@ghostvue/vue)
ArrowDownIn an open Column or Position list, the next option. On the focused scroll region, native scrolling.GhostBoard @component:GhostBoard › missing anchor: Position is re-created empty, announced, and a new position is required (@ghostvue/vue)
GhostBoard @component:GhostBoard › narrow viewport: the named region scrolls by keys and the page does not scroll sideways (@ghostvue/vue)
ArrowUpIn an open Column or Position list, the previous option. On the focused scroll region, native scrolling.GhostBoard @component:GhostBoard › narrow viewport: the named region scrolls by keys and the page does not scroll sideways (@ghostvue/vue)
ArrowRightOn the focused scroll region, native horizontal scrolling.GhostBoard @component:GhostBoard › narrow viewport: the named region scrolls by keys and the page does not scroll sideways (@ghostvue/vue)
ArrowLeftOn the focused scroll region, native horizontal scrolling.GhostBoard @component:GhostBoard › narrow viewport: the named region scrolls by keys and the page does not scroll sideways (@ghostvue/vue)
HomeIn an open list, the first option. On the focused scroll region, native scrolling to the start.GhostBoard @component:GhostBoard › same-column reorder by keyboard: Tab, Enter, Space, select keys, Escape, and focus on the moved card (@ghostvue/vue)
GhostBoard @component:GhostBoard › narrow viewport: the named region scrolls by keys and the page does not scroll sideways (@ghostvue/vue)
EndIn an open list, the last option. On the focused scroll region, native scrolling to the end.GhostBoard @component:GhostBoard › narrow viewport: the named region scrolls by keys and the page does not scroll sideways (@ghostvue/vue)
PageDownOn the focused scroll region, native scrolling by a page.GhostBoard @component:GhostBoard › narrow viewport: the named region scrolls by keys and the page does not scroll sideways (@ghostvue/vue)
PageUpOn the focused scroll region, native scrolling by a page.GhostBoard @component:GhostBoard › narrow viewport: the named region scrolls by keys and the page does not scroll sideways (@ghostvue/vue)

Verification ​

Each category is reviewed separately. Automated keyboard and axe results do not attest manual or assistive-technology review.

CategoryStatusEvidence
Automated keyboardPassedEvery declared key maps to a Chromium browser test that CI runs and requires to pass on every commit.
Manual interactionNot reviewedNo review recorded.
Assistive technologyNot reviewedNo review recorded.

Examples ​

board/triage ​

Example source

Triage board

Themed card content in a headless board. Move to… reorders within a column with the motion tokens, moves a card before another card or into an empty column, and shows a rejected save with its reason while the dialog stays open.

Triage 2 cards

  1. Crash on saveBug
  2. Add CSV exportFeature

To do 5 cards

  1. Update docsDocs
  2. Refactor authChore
  3. Bump dependenciesChore
  4. Write e2e testsChore
  5. Fix loginBug

In progress 1 card

  1. Upgrade VueChore

Done 0 cards

No cards

board/move-to ​

Example source

Move to… with app-owned order Headless

The headless board renders the application's columns and cards. Move to… requests a placement by stable IDs; the application applies it, rejects it with a reason, or reorders cards on its own.

Triage 2 cards

  1. Crash on saveBug
  2. Add CSV exportFeature

To do 3 cards

  1. Fix loginBug
  2. Update docsDocs
  3. Refactor authChore

In progress 1 card

  1. Upgrade VueChore

Done 0 cards

No cards