Ir al contenido
Español
Plegado en acordeón viene con Pro. La vista previa aparece al desbloquearlo.

Cómo funciona

Una figura de libro de texto sobre la geometría del plegado. Un anillo de papel (radio 6 cm, agujero 1,5 cm) tiene doce pliegues radiales, alternos en monte (línea continua) y en valle (discontinua), dibujado en axonometría con tonos neutros sobre la huella discontinua del anillo plano. El control fija el ángulo de los pliegues valle; como cada panel sigue siendo un sector plano de 30°, los pliegues monte lo acompañan y el anillo se eleva en una copa plisada. El borde exterior va marcado en el color de acento: zigzaguea entre los pliegues pero sigue midiendo 37,7 cm mientras el ancho de la copa se reduce. La fila bajo la figura muestra el patrón de pliegues con el ángulo de los pliegues monte, la longitud del borde y el ancho; tres ajustes saltan a plano, ángulo recto (90°) y completo.

Úsalo para

  • Teaching fold angles, mountain and valley creases, or why folding keeps lengths and areas.
  • Showing how one input angle drives a rigid folded form, with the derived values next to it.

Busca otra opción cuando

  • Arbitrary crease patterns or simulating paper bending; this figure folds one fixed pleated ring.
  • Choosing a plain number; use a regular slider.

Uso

import { PleatedLightCrown } from './PleatedLightCrown.jsx'

export function PleatLesson() {
  return (
    <PleatedLightCrown
      defaultValue={90}
      labels={{ title: 'Pleating a paper ring' }}
      onChange={(valley, { mountain, width }) => console.log(valley, mountain, width)}
    />
  )
}

Propiedades

PropiedadTipoPor defectoQué hace
valuenumber—Controlled valley fold angle in degrees, from 0 (flat) to 150 (the deepest fold). Pair with onChange.
defaultValuenumber90Starting valley fold angle when uncontrolled; Reset returns to it.
onChange(valley: number, info: { reason: 'press' | 'drag' | 'tap' | 'key' | 'preset' | 'reset' | 'cancel', mountain: number, width: number }) => void—Called with the new valley fold angle, the matching mountain fold angle (degrees) and the cup's width (cm). A glide after a preset reports only its target.
stepnumber1Keyboard step in degrees; Shift, Page Up and Page Down move 10°.
labelsobject—Replace any text: title, caption, valley, mountain, edge, width, presets, flat, right, full, valueText ({valley}, {mountain}), figure ({valley}), reset.
localestring'en'Locale used to format angles and lengths.

Accesibilidad

  • The slider has a label and announces both fold angles. Arrows move 1°, Shift or Page keys 10°, Home and End jump to flat and full. Presets are toggle buttons with aria-pressed.
  • On touch, a press on the track waits for a sideways move so the page can still scroll; the thumb drags at once. A cancelled touch restores the angle. Presets and Reset reach 44 pixels on touch.

Movimiento

Un ajuste predefinido o Restablecer se desliza hasta su ángulo en unos 240–480 ms con una curva de salida suave; al arrastrar, la figura sigue al puntero sin demora. Con movimiento reducido salta al ángulo sin transición.

Añádelo a tu proyecto

Los miembros Pro copian un prompt y su agente de programación instala el código, igual que con los gratuitos.

PleatedLightCrown.jsxpleated-light-crown.csstokens.cssREADME.md

Los dos archivos se instalan juntos. La hoja de estilos lee las variables de tokens.css y lleva valores de reserva, así que también funciona sola.

Formularios
Cuadrícula de disponibilidad viene con Pro. La vista previa aparece al desbloquearlo.
Operaciones booleanas viene con Pro. La vista previa aparece al desbloquearlo.
Selector en cascada viene con Pro. La vista previa aparece al desbloquearlo.