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

arrange function

Lays out the cards of callouts on a model that spans `left` to `right` in a `width` × `height` host: each on the side of the model its point is on, just past the model's edge but inside the host, and on each side spread up and down so no two cards overlap.

View as Markdown
import { arrange } from '@dioramajs/model/hotspots'

.

function arrange(
  list: readonly Callout[],
  left: number,
  right: number,
  width: number,
  height: number,
): void

Parameters

NameTypeDescription
listreadonly Callout[]
leftnumber
rightnumber
widthnumber
heightnumber

Defined in packages/model/src/hotspots.ts.