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

@dioramajs/transitions

Page transitions and flights of keyed elements.

View as Markdown
On this page
import { transition, TransitionError, transitionPlugin } from '@dioramajs/transitions'

Functions

transitionCalls `app.transition` if the plugin is running, otherwise runs `swap` once and returns a settled 'skipped' transition. Safe for routers that navigate before `app.start()` resolves.
transitionsPreset with the `transition` plugin, e.g. `presets: [effects(), transitions()]`.

Classes

TransitionErrorReported through `app.report` (the kernel wraps it as `REPORTED`) or logged in dev.

Constants

transitionPluginProvides `app.transition`, page transitions that fly the GL copies of keyed elements.

Interfaces

FlightEvery write requests a frame, so it can be tweened directly.
FlightOptionsHow copies fly between pages.
PageScopeThe current page: a scope closed when the next page replaces it.
PresenceAn unpaired copy that leaves or a new copy that enters.
PresenceOptionsHow unpaired copies leave and new ones enter.
TransitionThenable. Resolves with the result and never rejects.
TransitionApiThe `transition` service: call it with a swap to fly copies between pages.
TransitionOptionsOptions of one `app.transition` call. Unset fields take the plugin options.
TransitionResultHow a transition ended.
TransitionsOptionsOptions of the `transitions` preset.

Types

EaseAn easing function from 0..1 to 0..1.
FlightStateState of one flight.
SwapChanges the DOM. May return a thenable that settles once the router is done.
TransitionErrorCodeCodes of `TransitionError`.
TransitionPhasePhase of a transition: the swap runs, copies fly, or it is over.