theatrical cartoons, 1940s–50s

toon-ui

A thick ink outline of variable weight, flat cel fills, hard offset shadows, and motion that squashes, overshoots and lands in a puff of dust. No Material underneath.

31components
3themes
MITlicence
A list of plans in the Ink & Gouache theme
The dialog at 0 ms
0 ms
The dialog at 60 ms
60 ms
The dialog at 120 ms
120 ms
The dialog at 200 ms
200 ms
The dialog at 400 ms
400 ms

A dialog opening. Curves are functions of elapsed time, so a test reads them at the design's own timestamps.

Why it exists

Material decides how a press feels and how a surface ends, and a skin over it inherits both. This kit draws its own: all 27 components of the design, and four of the library's besides — a list of cards, a screen-transition host, a pull-to-refresh box that pulls its content, and the stage the rest stand on.

Held to the design twice, then allowed to leave it

Each component started from the design and is checked twice over: its geometry, frame by frame, against the design's own drawing engine run in Node, and its pixels against references rendered from the design in Chrome.

The code is primary, though. Where the running kit showed something the design gets wrong — a seam under the tooltip's tail, a stripe across the menu's rolls, half the slider's rope standing still in a drag — the component departs from it. Each departure is listed with its reason, and the checks skip exactly the listed cells, so everything else is still the design's.

Motion you can test

Curves are functions of elapsed time, ported from the design's engine, not spring() calls. A test reads them at the design's own timestamps, and motion the design does not draw is tested at every millisecond for a jump, with a mutant that brings the jump back to prove the test can see it.

Reduce motion follows the design's word for each animation — a fade, a static spinner, or nothing — rather than switching everything off.

Install

repositories {
    maven("https://reposilite.kotlin.website/snapshots") {
        mavenContent { includeGroupAndSubgroups("io.github.youndie") }
    }
}

dependencies {
    implementation("io.github.youndie:toon-core:0.1.0.<build>")
}

Every build of main publishes a version, and the latest is the last one in maven-metadata.xml. There is no release yet.

ToonTheme(ToonThemes.InkGouacheLight) {
    ToonStage {
        ToonFxHost {
            ToonButton("Add plan", onClick = {})
        }
    }
}

ToonStage paints the theme's backdrop and texture; ToonFxHost draws the dust, stars and speed lines the components fire. Targets: desktop (JVM), Android, iOS and wasm.