How it works
A textbook figure of a solid cut by a level plane. The solid is an axonometric line drawing in neutral tones: the part under the plane is solid with its hidden edges dashed, the part above it is a pale ghost, and the section is the one shape in the accent colour. A ruler at the plane's left corner reads the height, with the value in an ink pill; the round grip on the plane's right corner is the slider. The row under the figure names the section, draws it to scale as seen from above (so it grows and shrinks as the plane moves) and gives its area. Three key cuts per solid jump to the heights worth seeing, such as the regular hexagon halfway up a cube standing on a corner.
Use it for
- Teach solid geometry: let learners discover which polygons a plane can cut from a cube, or why every cut of a sphere is a circle.
- Introduce Cavalieri's principle or volumes by slicing: read the area of the section at each height.
Look elsewhere when
- For an arbitrary model from a CAD file, use a 3D viewer with a clipping plane: this figure draws four built-in solids with a level plane.
Usage
import React, { useState } from 'react'
import { KilnSectionPlane } from './KilnSectionPlane.jsx'
export function SectionLesson() {
const [height, setHeight] = useState(3.46)
return (
<KilnSectionPlane
solid="cube"
value={height}
onChange={(next, { shape, area }) => setHeight(next)}
labels={{ title: 'Sections of a cube' }}
/>
)
}Props
| Prop | Type | Default | What it does |
|---|---|---|---|
solid | 'cube' | 'tetrahedron' | 'cone' | 'sphere' | 'cube' | The solid: a cube of side 4 standing on a corner, a regular tetrahedron of edge 5 resting on an edge, a cone (radius 2.5, height 5) or a sphere (radius 2.5). Each comes with three key cuts. |
value | number | — | Controlled height of the plane in centimetres, from 0 to the solid's height (rounded to two decimals). |
defaultValue | number | — | Starting height when uncontrolled, and what Reset returns to. Defaults to halfway up (a quarter of the way up for the sphere). |
onChange | (height, { reason, shape, area }) => void | — | Called with the new height and { reason ('press', 'drag', 'tap', 'key', 'cut', 'cancel' or 'reset'), shape (point, segment, triangle, square, rectangle, hexagon, regularHexagon, circle or polygon), area in cm² }. |
step | number | 0.1 | Height step for the arrow keys. Shift with an arrow, or Page Up and Page Down, move ten steps. |
labels | object | — | Replaces any built-in text: title, caption, height, heightText ('{h}', '{unit}', '{shape}'), unit, area, areaUnit, cuts, reset and shapes (an object with point, segment, triangle, square, rectangle, hexagon, regularHexagon, circle and polygon). |
locale | string | 'en' | Language tag for the decimal readouts. |
className | string | — | Extra class on the card, for example to set its width (30rem by default, never wider than its container). |
Accessibility
- The grip is a vertical slider labelled with the plane height: Up and Down (or Right and Left) move 0.1 cm, Shift with an arrow or Page Up and Page Down move 1 cm, Home and End go to the bottom and the top. Its value text reads the height and the name of the section.
- The name and area of the section are a polite live region. Each key cut is a toggle button that is pressed while the plane is at its height. Reset is marked unavailable while nothing has changed.
- Dragging uses pointer capture. The grip and the height pill take touch drags; a tap elsewhere on the figure moves the plane there, and a vertical swipe on the figure still scrolls the page. A cancelled gesture restores the height it started from.
- Colour is not the only cue: the section is also named in words and drawn on its own from above.
Motion
After a key, a key cut or Reset the plane glides to its new height in 240ms, and the section changes shape on the way. While dragged it follows the pointer directly. With reduced motion every change lands at once.
Add it to your project
Pro members copy a prompt and their coding agent installs the source, the same way as the free components.
KilnSectionPlane.jsxkiln-section-plane.csstokens.cssREADME.md
Both files install together. The stylesheet reads the design tokens in tokens.css and carries fallbacks, so it also works alone.







