Reference · Framing, geometry and quiz tools
InsetTransformtype
What to do to a region's own geometry to seat it in its box: a scale, and a move.
Import it
import type { InsetTransform } from "@johnmorrisdotca/chizu";
Definition
type InsetTransform = {
scale: number;
x: number;
y: number;
};
Members
| Name | Type | Description |
|---|---|---|
scale | number | |
x | number | |
y | number |
Examples
import { insetTransformAttribute, type InsetTransform } from "@johnmorrisdotca/chizu";
const move: InsetTransform = { scale: 0.5, x: 20, y: 610 };
console.log(insetTransformAttribute(move));
// translate(20 610) scale(0.5)translate(20 610) scale(0.5)What it prints (run when this page was built)