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

scrub function

The stage of a scrubbed heading, 0 condensed to 1 gone, and where its smoke goes: 1 up and away as it leaves the top, -1 drifting in from below as it comes up.

View as Markdown
import { scrub } from '@dioramajs/text/smoke'

. start is the middle of the box on the page's first screen, so a heading there starts condensed.

function scrub(
  middle: number,
  height: number,
  viewport: number,
  start: number,
): [number, number]

Parameters

NameTypeDescription
middlenumber
heightnumber
viewportnumber
startnumber

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