Diorama

Made for a big screen.

This site is one 3D scene, built for a computer: a wide window and a mouse. Open dioramajs.dev on a desktop or a laptop to see it.This site is one 3D scene, built for a wide window. Make this one wider, or open dioramajs.dev on a larger screen.

GitHub

DioramaDocs

board function

The keys of the text: a row per visual line in reading order, one key per letter, a space bar where the DOM has a space, a wider key for a legend that does not fit one.

View as Markdown
import { board } from '@dioramajs/text/keycaps'

. Keys are KEY em apart, smaller when the board would not fit. The case is the element's box with fill, otherwise a rim round the keys, aligned to the text like the text is aligned in its box.

function board(
  pieces: readonly Piece[],
  ink: readonly Ink[],
  options: BoardOptions,
): Board

Parameters

NameTypeDescription
piecesreadonly Piece[]
inkreadonly Ink[]
optionsBoardOptions

Defined in packages/text/src/keycaps.ts.