@vibecook/ice 0.10.0 → 0.14.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +79 -50
- package/dist/chunk-BA7XJC27.js +2429 -0
- package/dist/chunk-BA7XJC27.js.map +1 -0
- package/dist/chunk-BKV4ZEU3.js +1 -0
- package/dist/chunk-BKV4ZEU3.js.map +1 -0
- package/dist/{chunk-5FQS7V2C.js → chunk-DYK6KNLG.js} +13303 -7485
- package/dist/chunk-DYK6KNLG.js.map +1 -0
- package/dist/chunk-ENIFIUEP.js +155 -0
- package/dist/chunk-ENIFIUEP.js.map +1 -0
- package/dist/chunk-IBWWLA6D.js +634 -0
- package/dist/chunk-IBWWLA6D.js.map +1 -0
- package/dist/{chunk-OR5FNVUE.js → chunk-JS6PG6YD.js} +398 -167
- package/dist/chunk-JS6PG6YD.js.map +1 -0
- package/dist/chunk-QXOCF56A.js +148 -0
- package/dist/chunk-QXOCF56A.js.map +1 -0
- package/dist/chunk-ZPUPBULB.js +7399 -0
- package/dist/chunk-ZPUPBULB.js.map +1 -0
- package/dist/desk-engine.js +36 -0
- package/dist/desk-engine.js.map +1 -0
- package/dist/desk-kit.js +244 -0
- package/dist/desk-kit.js.map +1 -0
- package/dist/desk-objects.js +12728 -0
- package/dist/desk-objects.js.map +1 -0
- package/dist/desk.js +469 -0
- package/dist/desk.js.map +1 -0
- package/dist/devtools.js +233 -189
- package/dist/devtools.js.map +1 -1
- package/dist/dom.js +7 -19
- package/dist/index.js +232 -20
- package/dist/kernel.js +53 -25
- package/dist/react.js +1045 -38
- package/dist/react.js.map +1 -1
- package/dist/types/packages/core/src/behavior/define-behavior.d.ts +11 -0
- package/dist/types/packages/core/src/behavior/runtime.d.ts +4 -0
- package/dist/types/packages/core/src/canvas/define-canvas-type.d.ts +86 -0
- package/dist/types/packages/core/src/canvas/define-container.d.ts +17 -0
- package/dist/types/packages/core/src/canvas/diagnostics.d.ts +27 -0
- package/dist/types/packages/core/src/canvas/engine-catalog.d.ts +70 -0
- package/dist/types/packages/core/src/canvas/extensions.d.ts +125 -0
- package/dist/types/packages/core/src/canvas/frame-behavior-host.d.ts +16 -0
- package/dist/types/packages/core/src/canvas/frame-preview.d.ts +79 -0
- package/dist/types/packages/core/src/canvas/frame-projection.d.ts +38 -0
- package/dist/types/packages/core/src/canvas/frame-view.d.ts +36 -0
- package/dist/types/packages/core/src/canvas/migrate.d.ts +14 -0
- package/dist/types/packages/core/src/canvas/placement.d.ts +30 -0
- package/dist/types/packages/core/src/canvas/presentation-transition.d.ts +100 -0
- package/dist/types/packages/core/src/canvas/runtime-extension-host.d.ts +16 -0
- package/dist/types/packages/core/src/canvas/session.d.ts +47 -0
- package/dist/types/packages/core/src/catalog/camera-derived.d.ts +16 -27
- package/dist/types/packages/core/src/catalog/desk.d.ts +326 -0
- package/dist/types/packages/core/src/catalog/gesture.d.ts +51 -0
- package/dist/types/packages/core/src/catalog/graph.d.ts +2 -2
- package/dist/types/packages/core/src/catalog/index.d.ts +2 -0
- package/dist/types/packages/core/src/catalog/pointer.d.ts +42 -0
- package/dist/types/packages/core/src/catalog/selection-presence.d.ts +7 -0
- package/dist/types/packages/core/src/catalog/settings-resources.d.ts +28 -2
- package/dist/types/packages/core/src/catalog/surface.d.ts +1 -0
- package/dist/types/packages/core/src/doc/doc-commit-sink.d.ts +18 -2
- package/dist/types/packages/core/src/doc/doc-kit.d.ts +21 -2
- package/dist/types/packages/core/src/doc/envelope.d.ts +5 -2
- package/dist/types/packages/core/src/doc/schema-migrate.d.ts +1 -1
- package/dist/types/packages/core/src/doc/version-gate.d.ts +21 -3
- package/dist/types/packages/core/src/engine/commit-sink.d.ts +10 -1
- package/dist/types/packages/core/src/engine/engine.d.ts +6 -0
- package/dist/types/packages/core/src/engine/frame-control.d.ts +74 -0
- package/dist/types/packages/core/src/engine/guests.d.ts +4 -1
- package/dist/types/packages/core/src/engine/world-doors.d.ts +12 -0
- package/dist/types/packages/core/src/facade/create-canvas-engine.d.ts +146 -13
- package/dist/types/packages/core/src/index.d.ts +34 -13
- package/dist/types/packages/core/src/input/queue.d.ts +3 -1
- package/dist/types/packages/core/src/interaction/install.d.ts +30 -0
- package/dist/types/packages/core/src/interaction/wakes.d.ts +24 -0
- package/dist/types/packages/core/src/nav/nav-geometry.d.ts +100 -0
- package/dist/types/packages/core/src/nav/nested-canvas.d.ts +47 -4
- package/dist/types/packages/core/src/ops/cascade.d.ts +2 -1
- package/dist/types/packages/core/src/ops/claims.d.ts +6 -0
- package/dist/types/packages/core/src/ops/insert.d.ts +4 -0
- package/dist/types/packages/core/src/ops/point-pick.d.ts +4 -1
- package/dist/types/packages/core/src/ops/sibling-order.d.ts +14 -4
- package/dist/types/packages/core/src/ops/tray.d.ts +48 -0
- package/dist/types/packages/core/src/presence/presence-kit.d.ts +5 -0
- package/dist/types/packages/core/src/schema/meta.d.ts +10 -0
- package/dist/types/packages/core/src/schema/prefab.d.ts +8 -0
- package/dist/types/packages/core/src/settings/defaults.d.ts +25 -6
- package/dist/types/packages/core/src/surface/gpu-device.d.ts +55 -0
- package/dist/types/packages/core/src/systems/camera-sim.d.ts +29 -0
- package/dist/types/packages/core/src/systems/chrome.d.ts +15 -23
- package/dist/types/packages/core/src/systems/drag-mods.d.ts +34 -0
- package/dist/types/packages/core/src/systems/held.d.ts +71 -0
- package/dist/types/packages/core/src/systems/insert-ghost.d.ts +2 -0
- package/dist/types/packages/core/src/systems/l0-input.d.ts +14 -0
- package/dist/types/packages/core/src/systems/l1-pick.d.ts +37 -1
- package/dist/types/packages/core/src/systems/l2-arbitrate.d.ts +18 -4
- package/dist/types/packages/core/src/systems/l3-behave.d.ts +4 -1
- package/dist/types/packages/core/src/systems/l3-claim.d.ts +7 -0
- package/dist/types/packages/core/src/systems/l3-connect.d.ts +1 -1
- package/dist/types/packages/core/src/systems/l3-drop.d.ts +30 -1
- package/dist/types/packages/core/src/systems/l3-marquee.d.ts +2 -1
- package/dist/types/packages/core/src/systems/l3-ports.d.ts +1 -1
- package/dist/types/packages/core/src/systems/l4-cursor.d.ts +5 -0
- package/dist/types/packages/core/src/systems/nav-flight.d.ts +85 -3
- package/dist/types/packages/core/src/systems/nav-tap.d.ts +44 -0
- package/dist/types/packages/core/src/systems/press-wheel.d.ts +11 -0
- package/dist/types/packages/core/src/systems/tray.d.ts +108 -0
- package/dist/types/packages/core/src/systems/zoom-through.d.ts +30 -0
- package/dist/types/packages/core/src/tools/define-tool.d.ts +10 -0
- package/dist/types/packages/core/src/widget/define-widget.d.ts +166 -63
- package/dist/types/packages/core/src/widget/equip.d.ts +14 -2
- package/dist/types/packages/core/src/widget/held-tools.d.ts +83 -0
- package/dist/types/packages/core/src/widget/menu-actions.d.ts +44 -0
- package/dist/types/packages/core/src/widget/mount-store.d.ts +21 -46
- package/dist/types/packages/core/src/widget/spawn.d.ts +1 -1
- package/dist/types/packages/desk/src/assets/blue-noise.gen.d.ts +10 -0
- package/dist/types/packages/desk/src/card/card.d.ts +103 -0
- package/dist/types/packages/desk/src/compose/ambient.d.ts +59 -0
- package/dist/types/packages/desk/src/compose/builder.d.ts +285 -0
- package/dist/types/packages/desk/src/compose/children.d.ts +3 -0
- package/dist/types/packages/desk/src/compose/index.d.ts +14 -0
- package/dist/types/packages/desk/src/compose/marks.d.ts +126 -0
- package/dist/types/packages/desk/src/compose/pick.d.ts +5 -0
- package/dist/types/packages/desk/src/compose/reflector.d.ts +111 -0
- package/dist/types/packages/desk/src/compose/tap.d.ts +5 -0
- package/dist/types/packages/desk/src/docs.d.ts +23 -0
- package/dist/types/packages/desk/src/engine/budget.d.ts +38 -0
- package/dist/types/packages/desk/src/engine/device.d.ts +54 -0
- package/dist/types/packages/desk/src/engine/index.d.ts +5 -0
- package/dist/types/packages/desk/src/engine/pipeline.d.ts +36 -0
- package/dist/types/packages/desk/src/engine/rasters.d.ts +66 -0
- package/dist/types/packages/desk/src/engine/records.d.ts +56 -0
- package/dist/types/packages/desk/src/engine/shader.d.ts +22 -0
- package/dist/types/packages/desk/src/engine/struct.d.ts +39 -0
- package/dist/types/packages/desk/src/engine/target.d.ts +26 -0
- package/dist/types/packages/desk/src/gpu-ablation.d.ts +61 -0
- package/dist/types/packages/desk/src/gpu-memory.d.ts +54 -0
- package/dist/types/packages/desk/src/gpu-profiler.d.ts +141 -0
- package/dist/types/packages/desk/src/gpu-wrap.d.ts +8 -0
- package/dist/types/packages/desk/src/ground.d.ts +388 -0
- package/dist/types/packages/desk/src/hold/focus.d.ts +53 -0
- package/dist/types/packages/desk/src/hold/pose.d.ts +132 -0
- package/dist/types/packages/desk/src/hold/shaders.d.ts +9 -0
- package/dist/types/packages/desk/src/host/editor.d.ts +18 -0
- package/dist/types/packages/desk/src/host/index.d.ts +9 -0
- package/dist/types/packages/desk/src/host/ink.d.ts +18 -0
- package/dist/types/packages/desk/src/host/layer.d.ts +430 -0
- package/dist/types/packages/desk/src/host/picture.d.ts +2 -0
- package/dist/types/packages/desk/src/host/surface.d.ts +5 -0
- package/dist/types/packages/desk/src/index.d.ts +13 -0
- package/dist/types/packages/desk/src/kind.d.ts +187 -0
- package/dist/types/packages/desk/src/kinds/world.d.ts +429 -0
- package/dist/types/packages/desk/src/kit/arrays.d.ts +88 -0
- package/dist/types/packages/desk/src/kit/blobs.d.ts +40 -0
- package/dist/types/packages/desk/src/kit/book.d.ts +2 -0
- package/dist/types/packages/desk/src/kit/editor.d.ts +103 -0
- package/dist/types/packages/desk/src/kit/eye.d.ts +37 -0
- package/dist/types/packages/desk/src/kit/hold.d.ts +1 -0
- package/dist/types/packages/desk/src/kit/index.d.ts +26 -0
- package/dist/types/packages/desk/src/kit/inside.d.ts +116 -0
- package/dist/types/packages/desk/src/kit/layer.d.ts +159 -0
- package/dist/types/packages/desk/src/kit/light.d.ts +3 -0
- package/dist/types/packages/desk/src/kit/mesh.d.ts +29 -0
- package/dist/types/packages/desk/src/kit/mips.d.ts +2 -0
- package/dist/types/packages/desk/src/kit/nav.d.ts +2 -0
- package/dist/types/packages/desk/src/kit/paper-tex.d.ts +5 -0
- package/dist/types/packages/desk/src/kit/physics.d.ts +44 -0
- package/dist/types/packages/desk/src/kit/place.d.ts +44 -0
- package/dist/types/packages/desk/src/kit/print.d.ts +30 -0
- package/dist/types/packages/desk/src/kit/raster.d.ts +34 -0
- package/dist/types/packages/desk/src/kit/sdf.d.ts +1 -0
- package/dist/types/packages/desk/src/kit/seeds.d.ts +11 -0
- package/dist/types/packages/desk/src/kit/services.d.ts +34 -0
- package/dist/types/packages/desk/src/kit/springs.d.ts +12 -0
- package/dist/types/packages/desk/src/kit/strokes.d.ts +93 -0
- package/dist/types/packages/desk/src/kit/text.d.ts +142 -0
- package/dist/types/packages/desk/src/kit/uniform.d.ts +8 -0
- package/dist/types/packages/desk/src/kit/view.d.ts +39 -0
- package/dist/types/packages/desk/src/kit/wgsl.d.ts +15 -0
- package/dist/types/packages/desk/src/lattice/line.d.ts +15 -0
- package/dist/types/packages/desk/src/lattice/lod.d.ts +52 -0
- package/dist/types/packages/desk/src/lattice/ruler.d.ts +88 -0
- package/dist/types/packages/desk/src/marks/assemble.d.ts +65 -0
- package/dist/types/packages/desk/src/marks/ease.d.ts +4 -0
- package/dist/types/packages/desk/src/marks/laser.d.ts +41 -0
- package/dist/types/packages/desk/src/marks/layout.d.ts +167 -0
- package/dist/types/packages/desk/src/marks/pass.d.ts +59 -0
- package/dist/types/packages/desk/src/marks/shaders.d.ts +12 -0
- package/dist/types/packages/desk/src/mat/grid.d.ts +50 -0
- package/dist/types/packages/desk/src/mat/lamp.d.ts +14 -0
- package/dist/types/packages/desk/src/mat/layout.d.ts +144 -0
- package/dist/types/packages/desk/src/mat/mat-pass.d.ts +83 -0
- package/dist/types/packages/desk/src/mat/night.d.ts +95 -0
- package/dist/types/packages/desk/src/mat/projector.d.ts +39 -0
- package/dist/types/packages/desk/src/mat/shaders.d.ts +17 -0
- package/dist/types/packages/desk/src/mat/tilt.d.ts +14 -0
- package/dist/types/packages/desk/src/nav/flight.d.ts +186 -0
- package/dist/types/packages/desk/src/nav/portal.d.ts +95 -0
- package/dist/types/packages/desk/src/object.d.ts +46 -0
- package/dist/types/packages/desk/src/pass-instrument.d.ts +89 -0
- package/dist/types/packages/desk/src/shaders.d.ts +12 -0
- package/dist/types/packages/desk/src/shaders.gen.d.ts +16 -0
- package/dist/types/packages/desk/src/submit-instrument.d.ts +36 -0
- package/dist/types/packages/desk/src/theme.d.ts +475 -0
- package/dist/types/packages/desk/src/tray/carry.d.ts +99 -0
- package/dist/types/packages/desk/src/tray/drawer.d.ts +113 -0
- package/dist/types/packages/desk/src/tray/flux.d.ts +46 -0
- package/dist/types/packages/desk/src/tray/index.d.ts +4 -0
- package/dist/types/packages/desk/src/tray/lattice.d.ts +71 -0
- package/dist/types/packages/desk/src/tray/layout.d.ts +7 -0
- package/dist/types/packages/desk/src/tray/look.d.ts +29 -0
- package/dist/types/packages/desk/src/tray/pass.d.ts +96 -0
- package/dist/types/packages/desk/src/tray/shaders.d.ts +10 -0
- package/dist/types/packages/desk/src/tray/specimens.d.ts +199 -0
- package/dist/types/packages/devtools/src/attach.d.ts +22 -8
- package/dist/types/packages/devtools/src/dock.d.ts +18 -14
- package/dist/types/packages/devtools/src/gpu-panel.d.ts +105 -0
- package/dist/types/packages/devtools/src/index.d.ts +5 -4
- package/dist/types/packages/dom/src/desk-host.d.ts +91 -0
- package/dist/types/packages/dom/src/host.d.ts +13 -14
- package/dist/types/packages/dom/src/index.d.ts +12 -10
- package/dist/types/packages/dom/src/loop.d.ts +18 -1
- package/dist/types/packages/dom/src/pointer-adapter.d.ts +5 -29
- package/dist/types/packages/dom/src/widget-focus.d.ts +17 -13
- package/dist/types/packages/ice/src/desk-engine.d.ts +2 -0
- package/dist/types/packages/ice/src/desk-kit.d.ts +6 -0
- package/dist/types/packages/ice/src/desk-objects.d.ts +5 -0
- package/dist/types/packages/ice/src/desk.d.ts +5 -0
- package/dist/types/packages/kernel/src/atlas-pack.d.ts +157 -0
- package/dist/types/packages/kernel/src/bezier.d.ts +0 -15
- package/dist/types/packages/kernel/src/coords.d.ts +0 -39
- package/dist/types/packages/kernel/src/index.d.ts +2 -2
- package/dist/types/packages/kernel/src/nav-flight.d.ts +6 -0
- package/dist/types/packages/kernel/src/tray.d.ts +155 -0
- package/dist/types/packages/objects/src/board/board-pass.d.ts +180 -0
- package/dist/types/packages/objects/src/board/board-pen.d.ts +36 -0
- package/dist/types/packages/objects/src/board/board.d.ts +104 -0
- package/dist/types/packages/objects/src/board/data.d.ts +31 -0
- package/dist/types/packages/objects/src/board/history.d.ts +33 -0
- package/dist/types/packages/objects/src/board/kind.d.ts +208 -0
- package/dist/types/packages/objects/src/board/layout.d.ts +102 -0
- package/dist/types/packages/objects/src/board/object.d.ts +7 -0
- package/dist/types/packages/objects/src/board/pen.d.ts +71 -0
- package/dist/types/packages/objects/src/board/shaders.d.ts +36 -0
- package/dist/types/packages/objects/src/board/stroke.d.ts +99 -0
- package/dist/types/packages/objects/src/board/theme.d.ts +150 -0
- package/dist/types/packages/objects/src/calendar/data.d.ts +97 -0
- package/dist/types/packages/objects/src/calendar/events.d.ts +58 -0
- package/dist/types/packages/objects/src/calendar/hand.d.ts +53 -0
- package/dist/types/packages/objects/src/calendar/host/input.d.ts +67 -0
- package/dist/types/packages/objects/src/calendar/host/print.d.ts +9 -0
- package/dist/types/packages/objects/src/calendar/kind.d.ts +297 -0
- package/dist/types/packages/objects/src/calendar/law.d.ts +151 -0
- package/dist/types/packages/objects/src/calendar/layout.d.ts +47 -0
- package/dist/types/packages/objects/src/calendar/month.d.ts +75 -0
- package/dist/types/packages/objects/src/calendar/object.d.ts +45 -0
- package/dist/types/packages/objects/src/calendar/pad.d.ts +42 -0
- package/dist/types/packages/objects/src/calendar/pass.d.ts +229 -0
- package/dist/types/packages/objects/src/calendar/print.d.ts +87 -0
- package/dist/types/packages/objects/src/calendar/printing.d.ts +80 -0
- package/dist/types/packages/objects/src/calendar/roll.d.ts +45 -0
- package/dist/types/packages/objects/src/calendar/shaders.d.ts +12 -0
- package/dist/types/packages/objects/src/calendar/sheet.d.ts +43 -0
- package/dist/types/packages/objects/src/calendar/tiles.d.ts +67 -0
- package/dist/types/packages/objects/src/calendar/turn.d.ts +73 -0
- package/dist/types/packages/objects/src/calendar/writing.d.ts +42 -0
- package/dist/types/packages/objects/src/index.d.ts +22 -0
- package/dist/types/packages/objects/src/kinds.d.ts +24 -0
- package/dist/types/packages/objects/src/minimat/inside.d.ts +17 -0
- package/dist/types/packages/objects/src/minimat/kind.d.ts +51 -0
- package/dist/types/packages/objects/src/minimat/layout.d.ts +83 -0
- package/dist/types/packages/objects/src/minimat/minimat.d.ts +179 -0
- package/dist/types/packages/objects/src/minimat/object.d.ts +8 -0
- package/dist/types/packages/objects/src/minimat/pass.d.ts +61 -0
- package/dist/types/packages/objects/src/minimat/shaders.d.ts +10 -0
- package/dist/types/packages/objects/src/minimat/theme.d.ts +98 -0
- package/dist/types/packages/objects/src/notebook/ink.d.ts +70 -0
- package/dist/types/packages/objects/src/notebook/kind.d.ts +236 -0
- package/dist/types/packages/objects/src/notebook/law.d.ts +129 -0
- package/dist/types/packages/objects/src/notebook/layout.d.ts +46 -0
- package/dist/types/packages/objects/src/notebook/leaf.d.ts +44 -0
- package/dist/types/packages/objects/src/notebook/mesh.d.ts +20 -0
- package/dist/types/packages/objects/src/notebook/motion.d.ts +107 -0
- package/dist/types/packages/objects/src/notebook/object.d.ts +8 -0
- package/dist/types/packages/objects/src/notebook/pages.d.ts +56 -0
- package/dist/types/packages/objects/src/notebook/pass.d.ts +197 -0
- package/dist/types/packages/objects/src/notebook/pick.d.ts +30 -0
- package/dist/types/packages/objects/src/notebook/raster.d.ts +28 -0
- package/dist/types/packages/objects/src/notebook/shaders.d.ts +11 -0
- package/dist/types/packages/objects/src/notebook/shape.d.ts +155 -0
- package/dist/types/packages/objects/src/notebook/theme.d.ts +76 -0
- package/dist/types/packages/objects/src/palette.d.ts +577 -0
- package/dist/types/packages/objects/src/paper/host/body.d.ts +30 -0
- package/dist/types/packages/objects/src/paper/kind.d.ts +81 -0
- package/dist/types/packages/objects/src/paper/layout.d.ts +73 -0
- package/dist/types/packages/objects/src/paper/object.d.ts +31 -0
- package/dist/types/packages/objects/src/paper/pages.d.ts +43 -0
- package/dist/types/packages/objects/src/paper/paper-pass.d.ts +86 -0
- package/dist/types/packages/objects/src/paper/paper.d.ts +117 -0
- package/dist/types/packages/objects/src/paper/shaders.d.ts +18 -0
- package/dist/types/packages/objects/src/paper/theme.d.ts +58 -0
- package/dist/types/packages/objects/src/paper/typing.d.ts +51 -0
- package/dist/types/packages/objects/src/paper/writing.d.ts +161 -0
- package/dist/types/packages/objects/src/photo/carry.d.ts +33 -0
- package/dist/types/packages/objects/src/photo/kind.d.ts +136 -0
- package/dist/types/packages/objects/src/photo/layout.d.ts +39 -0
- package/dist/types/packages/objects/src/photo/object.d.ts +5 -0
- package/dist/types/packages/objects/src/photo/photo-pass.d.ts +104 -0
- package/dist/types/packages/objects/src/photo/photo.d.ts +262 -0
- package/dist/types/packages/objects/src/photo/pictures.d.ts +152 -0
- package/dist/types/packages/objects/src/photo/sample.d.ts +9 -0
- package/dist/types/packages/objects/src/photo/shaders.d.ts +18 -0
- package/dist/types/packages/objects/src/preset.d.ts +44 -0
- package/dist/types/packages/objects/src/shaders.d.ts +3 -0
- package/dist/types/packages/objects/src/shaders.gen.d.ts +21 -0
- package/dist/types/packages/react/src/canvas-hooks.d.ts +12 -0
- package/dist/types/packages/react/src/desk.d.ts +56 -0
- package/dist/types/packages/react/src/engine-context.d.ts +2 -2
- package/dist/types/packages/react/src/frame-preview-boundary.d.ts +19 -0
- package/dist/types/packages/react/src/hooks.d.ts +9 -14
- package/dist/types/packages/react/src/index.d.ts +16 -9
- package/dist/types/packages/react/src/keymap.d.ts +21 -2
- package/dist/types/packages/react/src/selection-menu.d.ts +171 -0
- package/dist/types/packages/react/src/tray-bar.d.ts +124 -0
- package/package.json +64 -31
- package/dist/chunk-5FQS7V2C.js.map +0 -1
- package/dist/chunk-JWRHAM7L.js +0 -1163
- package/dist/chunk-JWRHAM7L.js.map +0 -1
- package/dist/chunk-MFTMPJUF.js +0 -681
- package/dist/chunk-MFTMPJUF.js.map +0 -1
- package/dist/chunk-OR5FNVUE.js.map +0 -1
- package/dist/ground.js +0 -1213
- package/dist/ground.js.map +0 -1
- package/dist/r3f.js +0 -1644
- package/dist/r3f.js.map +0 -1
- package/dist/types/packages/core/src/input/measure-queue.d.ts +0 -30
- package/dist/types/packages/core/src/settings/ground-config.d.ts +0 -103
- package/dist/types/packages/core/src/systems/measure-ingest.d.ts +0 -26
- package/dist/types/packages/devtools/src/gl-panel.d.ts +0 -69
- package/dist/types/packages/dom/src/measure-adapter.d.ts +0 -31
- package/dist/types/packages/dom/src/measure-wiring.d.ts +0 -49
- package/dist/types/packages/dom/src/planes.d.ts +0 -33
- package/dist/types/packages/dom/src/reflectors/chrome.d.ts +0 -33
- package/dist/types/packages/dom/src/reflectors/dom-widgets.d.ts +0 -59
- package/dist/types/packages/dom/src/reflectors/graybox.d.ts +0 -31
- package/dist/types/packages/dom/src/reflectors/plane-transform.d.ts +0 -38
- package/dist/types/packages/ground/src/index.d.ts +0 -69
- package/dist/types/packages/ground/src/layer.d.ts +0 -40
- package/dist/types/packages/ground/src/pass.d.ts +0 -41
- package/dist/types/packages/ground/src/passes/grid-classic.d.ts +0 -30
- package/dist/types/packages/ground/src/passes/grid-magnet.d.ts +0 -31
- package/dist/types/packages/ground/src/passes/grid.d.ts +0 -28
- package/dist/types/packages/ground/src/passes/guides-collect.d.ts +0 -14
- package/dist/types/packages/ground/src/passes/guides.d.ts +0 -3
- package/dist/types/packages/ground/src/passes/magnet-collect.d.ts +0 -63
- package/dist/types/packages/ground/src/passes/soup-collect.d.ts +0 -35
- package/dist/types/packages/ground/src/passes/soup-mesh.d.ts +0 -8
- package/dist/types/packages/ground/src/passes/wires-collect.d.ts +0 -35
- package/dist/types/packages/ground/src/passes/wires.d.ts +0 -10
- package/dist/types/packages/ground/src/poles.d.ts +0 -47
- package/dist/types/packages/ground/src/renderer.d.ts +0 -15
- package/dist/types/packages/ice/src/ground.d.ts +0 -1
- package/dist/types/packages/ice/src/r3f.d.ts +0 -1
- package/dist/types/packages/kernel/src/eviction.d.ts +0 -23
- package/dist/types/packages/kernel/src/zoom-bands.d.ts +0 -19
- package/dist/types/packages/r3f/src/bridge.d.ts +0 -129
- package/dist/types/packages/r3f/src/composite-material.d.ts +0 -26
- package/dist/types/packages/r3f/src/compositor-pass.d.ts +0 -105
- package/dist/types/packages/r3f/src/dev-write-trap.d.ts +0 -30
- package/dist/types/packages/r3f/src/gl-root.d.ts +0 -96
- package/dist/types/packages/r3f/src/gl-router.d.ts +0 -70
- package/dist/types/packages/r3f/src/index.d.ts +0 -17
- package/dist/types/packages/r3f/src/island-state.d.ts +0 -112
- package/dist/types/packages/r3f/src/island.d.ts +0 -13
- package/dist/types/packages/r3f/src/pool.d.ts +0 -56
- package/dist/types/packages/r3f/src/preview-capture.d.ts +0 -19
- package/dist/types/packages/r3f/src/resource-registry.d.ts +0 -30
- package/dist/types/packages/r3f/src/self-sustain.d.ts +0 -39
- package/dist/types/packages/r3f/src/use-island-frame.d.ts +0 -39
- package/dist/types/packages/react/src/infinite-canvas.d.ts +0 -140
- package/dist/types/packages/react/src/preview-snapshots.d.ts +0 -17
- package/dist/types/packages/react/src/widget-preview.d.ts +0 -14
- package/dist/types/packages/react/src/widget-root.d.ts +0 -33
|
@@ -0,0 +1,99 @@
|
|
|
1
|
+
import type { RGB } from "../../../desk/src/index";
|
|
2
|
+
import { BOARD } from "./theme";
|
|
3
|
+
/** A stamp's floats: x, y (world units from the melamine's top-left) · dir x, y · s (arc length) · flow · size · seed. */
|
|
4
|
+
export declare const STAMP_FLOATS = 8;
|
|
5
|
+
/** A felt tip, world units: half extents (along the tip's long axis, across it), corner radius, edge softness, the angle it is held at (radians, screen space, y down). */
|
|
6
|
+
export interface Tip {
|
|
7
|
+
readonly half: readonly [number, number];
|
|
8
|
+
readonly radius: number;
|
|
9
|
+
readonly softness: number;
|
|
10
|
+
readonly angle: number;
|
|
11
|
+
}
|
|
12
|
+
export type TipName = keyof typeof BOARD.tips;
|
|
13
|
+
export declare const TIP_NAMES: readonly TipName[];
|
|
14
|
+
/** A tip from the theme's numbers (degrees → radians). */
|
|
15
|
+
export declare const tipOf: (t: {
|
|
16
|
+
readonly half: readonly [number, number];
|
|
17
|
+
readonly radius: number;
|
|
18
|
+
readonly softness: number;
|
|
19
|
+
readonly angle: number;
|
|
20
|
+
}) => Tip;
|
|
21
|
+
export declare const TIPS: Record<TipName, Tip>;
|
|
22
|
+
export declare const ERASER_TIP: Tip;
|
|
23
|
+
/** What lays the stamps down: a marker (its ink in LINEAR rgb, the coverage one pass lays) or the eraser. */
|
|
24
|
+
export interface Tool {
|
|
25
|
+
readonly mode: "ink" | "erase";
|
|
26
|
+
readonly color: RGB;
|
|
27
|
+
readonly opacity: number;
|
|
28
|
+
readonly tip: Tip;
|
|
29
|
+
/** The felt's streaks, 0..1 — none for the eraser's own pattern. */
|
|
30
|
+
readonly streak: number;
|
|
31
|
+
}
|
|
32
|
+
export interface FeltLaw {
|
|
33
|
+
readonly streak: number;
|
|
34
|
+
readonly lanes: number;
|
|
35
|
+
readonly along: readonly [number, number];
|
|
36
|
+
readonly dry: readonly [number, number];
|
|
37
|
+
readonly dryLoss: number;
|
|
38
|
+
readonly bleed: {
|
|
39
|
+
readonly after: number;
|
|
40
|
+
readonly grow: number;
|
|
41
|
+
readonly tau: number;
|
|
42
|
+
};
|
|
43
|
+
readonly pitch: {
|
|
44
|
+
readonly k: number;
|
|
45
|
+
readonly min: number;
|
|
46
|
+
readonly max: number;
|
|
47
|
+
};
|
|
48
|
+
}
|
|
49
|
+
export declare const DEFAULT_FELT: FeltLaw;
|
|
50
|
+
export declare function markerTool(color: RGB, opacity: number, tip: Tip, felt?: FeltLaw): Tool;
|
|
51
|
+
export declare const ERASER_TOOL: Tool;
|
|
52
|
+
/** The distance between stamps for a tip: a fraction of its narrow half, clamped (world units). */
|
|
53
|
+
export declare const pitchOf: (tip: Tip, felt?: FeltLaw) => number;
|
|
54
|
+
/**
|
|
55
|
+
* One stroke being drawn. `begin` at the press, `move` per pointer sample (coalesced events
|
|
56
|
+
* in order), `hold` once a frame while the pen rests (its bleed), `end` at the lift. Times are
|
|
57
|
+
* milliseconds (the events' own clock), positions the melamine's world units. `pending()`
|
|
58
|
+
* hands the stamps made since the last call — what the pass uploads this frame — and
|
|
59
|
+
* `stamps()` all of them, for the history.
|
|
60
|
+
*/
|
|
61
|
+
export declare class StrokeBuilder {
|
|
62
|
+
readonly tool: Tool;
|
|
63
|
+
readonly seed: number;
|
|
64
|
+
readonly spacing: number;
|
|
65
|
+
private readonly felt;
|
|
66
|
+
private buf;
|
|
67
|
+
private n;
|
|
68
|
+
private sent;
|
|
69
|
+
private x;
|
|
70
|
+
private y;
|
|
71
|
+
private t;
|
|
72
|
+
private dirX;
|
|
73
|
+
private dirY;
|
|
74
|
+
private s;
|
|
75
|
+
private carry;
|
|
76
|
+
private speed;
|
|
77
|
+
private flow;
|
|
78
|
+
private size;
|
|
79
|
+
private lastMove;
|
|
80
|
+
private active;
|
|
81
|
+
constructor(tool: Tool, seed: number, felt?: FeltLaw);
|
|
82
|
+
get count(): number;
|
|
83
|
+
get live(): boolean;
|
|
84
|
+
private push;
|
|
85
|
+
/** The press: the first footprint, where the tip lands. */
|
|
86
|
+
begin(x: number, y: number, t: number, size?: number): void;
|
|
87
|
+
/** A pointer sample: footprints every `spacing` along the segment since the last, the flow and size interpolated. */
|
|
88
|
+
move(x: number, y: number, t: number, size?: number): void;
|
|
89
|
+
/** The pen held still: past `bleed.after` ms the ink spreads into the melamine, growing toward `1 + grow`. */
|
|
90
|
+
hold(now: number): void;
|
|
91
|
+
/** The lift: the last sample's footprints; the stroke is complete. */
|
|
92
|
+
end(x?: number, y?: number, t?: number, size?: number): void;
|
|
93
|
+
/** The stamps made since the last call (a view — copy it before the next push). */
|
|
94
|
+
pending(): Float32Array;
|
|
95
|
+
/** Every stamp of the stroke, as its own array. */
|
|
96
|
+
stamps(): Float32Array;
|
|
97
|
+
}
|
|
98
|
+
/** A stroke's path for a reader — an agent, an export: one point per `every` stamps, world units from the melamine's top-left. */
|
|
99
|
+
export declare function pathOf(stamps: Float32Array, every?: number): Array<readonly [number, number]>;
|
|
@@ -0,0 +1,150 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* The WHITEBOARD (BOARD.md) — a desk dry-erase board under the mat's one lamp, ONE PHYSICS with
|
|
3
|
+
* the note and the notebook: it lifts as they lift (`PAPER.lift`), its slab casts the note's
|
|
4
|
+
* penumbra swept down its height with the notebook's contact term at its base (`BOOK.shadow`),
|
|
5
|
+
* and a face reads by the notebook's light (`BOOK.light`). What a board has of its own is the
|
|
6
|
+
* research whiteboard (research/whiteboard): melamine with an orange-peel grain and a sheen that
|
|
7
|
+
* slides with the eye, felt-tip ink laid by max-blended stamps — streaky when fast, bleeding when
|
|
8
|
+
* held, glossy while wet — and an eraser that leaves a ghost. The board is 3:2 like every
|
|
9
|
+
* whiteboard, on the tree-shadow design's 80-unit module, at the notebook's scale: 480 × 320
|
|
10
|
+
* beside the A6 notebook's 176 × 248 is a ~29 × 19 cm desk board. World units throughout; the
|
|
11
|
+
* research's tip and stroke numbers were CSS px on a full-screen board and are scaled into them.
|
|
12
|
+
* The colours are the product's (lab/theme.ts `BOARD_LOOK`, `MARKERS`).
|
|
13
|
+
*/
|
|
14
|
+
export declare const BOARD: {
|
|
15
|
+
/** A board as a host spawns one: its outer size, the aluminium frame's width, the frame's outer radius, the slab's height, the melamine's recess below the frame's top. */
|
|
16
|
+
readonly spec: {
|
|
17
|
+
readonly width: 480;
|
|
18
|
+
readonly height: 320;
|
|
19
|
+
readonly frame: 9;
|
|
20
|
+
readonly radius: 7;
|
|
21
|
+
readonly thick: 8;
|
|
22
|
+
readonly recess: 1.2;
|
|
23
|
+
};
|
|
24
|
+
readonly lift: {
|
|
25
|
+
readonly height: 12;
|
|
26
|
+
readonly scale: 1.03;
|
|
27
|
+
};
|
|
28
|
+
readonly shadow: {
|
|
29
|
+
readonly penumbra: {
|
|
30
|
+
readonly sigma0: 2.2;
|
|
31
|
+
readonly sigmaPerHeight: 0.9;
|
|
32
|
+
readonly alpha: 0.36;
|
|
33
|
+
};
|
|
34
|
+
readonly contact: {
|
|
35
|
+
readonly sigma: 1.1;
|
|
36
|
+
readonly alpha: 0.3;
|
|
37
|
+
readonly reach: 2.5;
|
|
38
|
+
};
|
|
39
|
+
readonly slopeMax: 2.2;
|
|
40
|
+
};
|
|
41
|
+
readonly light: {
|
|
42
|
+
readonly ambient: 0.5;
|
|
43
|
+
readonly cap: 1.35;
|
|
44
|
+
};
|
|
45
|
+
/**
|
|
46
|
+
* The melamine: its tone's drift (±), its orange-peel grain (±/255), the ghost old erasures
|
|
47
|
+
* leave; the SHEEN — the window's reflection — its strength, its spread, the eye's height over
|
|
48
|
+
* the board (× the board's height) and how far it slides with the pointer; the frame's lip on
|
|
49
|
+
* the surface: its shadow's alpha and σ.
|
|
50
|
+
*/
|
|
51
|
+
readonly surface: {
|
|
52
|
+
readonly tone: 0.012;
|
|
53
|
+
readonly grain: number;
|
|
54
|
+
readonly ghost: 0.012;
|
|
55
|
+
readonly sheen: 0.16;
|
|
56
|
+
readonly spread: 0.35;
|
|
57
|
+
readonly eye: 1.6;
|
|
58
|
+
readonly parallax: 0.12;
|
|
59
|
+
readonly lip: {
|
|
60
|
+
readonly alpha: 0.2;
|
|
61
|
+
readonly sigma: 0.9;
|
|
62
|
+
};
|
|
63
|
+
};
|
|
64
|
+
/** The frame: brushed along its length (±/255), its profile's roll at the rims (rad), the metal's glint. */
|
|
65
|
+
readonly frame: {
|
|
66
|
+
readonly brushed: number;
|
|
67
|
+
readonly roll: 0.85;
|
|
68
|
+
readonly glint: 0.35;
|
|
69
|
+
};
|
|
70
|
+
/** The ink raster (texels per world unit — the open board fills the view at ~1.8× on a 2× display), how long fresh ink stays wet (s) and how dark it lays wet, the film's edge relief. */
|
|
71
|
+
readonly ink: {
|
|
72
|
+
readonly density: 4;
|
|
73
|
+
readonly wetSeconds: 1.2;
|
|
74
|
+
readonly wetDarken: 0.8;
|
|
75
|
+
readonly film: 0.04;
|
|
76
|
+
};
|
|
77
|
+
/** The tips, world units: half extents (along, across the tip), corner radius, edge softness, the angle it is held at (deg). The research's, scaled to the desk board. */
|
|
78
|
+
readonly tips: {
|
|
79
|
+
readonly fine: {
|
|
80
|
+
readonly half: readonly [0.75, 0.75];
|
|
81
|
+
readonly radius: 0.75;
|
|
82
|
+
readonly softness: 0.3;
|
|
83
|
+
readonly angle: 0;
|
|
84
|
+
};
|
|
85
|
+
readonly bullet: {
|
|
86
|
+
readonly half: readonly [1.35, 1.35];
|
|
87
|
+
readonly radius: 1.35;
|
|
88
|
+
readonly softness: 0.35;
|
|
89
|
+
readonly angle: 0;
|
|
90
|
+
};
|
|
91
|
+
readonly chisel: {
|
|
92
|
+
readonly half: readonly [2.4, 0.9];
|
|
93
|
+
readonly radius: 0.5;
|
|
94
|
+
readonly softness: 0.35;
|
|
95
|
+
readonly angle: -50;
|
|
96
|
+
};
|
|
97
|
+
};
|
|
98
|
+
readonly eraser: {
|
|
99
|
+
readonly half: readonly [16, 7];
|
|
100
|
+
readonly radius: 2.5;
|
|
101
|
+
readonly softness: 1.6;
|
|
102
|
+
readonly angle: 8;
|
|
103
|
+
};
|
|
104
|
+
/**
|
|
105
|
+
* The felt: its streaks (strength, lanes per world unit across, drift along ×2), how fast a
|
|
106
|
+
* stroke runs dry (world units/s: from, full) and how much flow it loses, a held pen's bleed
|
|
107
|
+
* (after ms, growth, its time constant ms), and the stamps' pitch (× the tip's narrow half, clamped).
|
|
108
|
+
*/
|
|
109
|
+
readonly felt: {
|
|
110
|
+
readonly streak: 0.45;
|
|
111
|
+
readonly lanes: 0.75;
|
|
112
|
+
readonly along: readonly [0.058, 0.145];
|
|
113
|
+
readonly dry: readonly [200, 1450];
|
|
114
|
+
readonly dryLoss: 0.16;
|
|
115
|
+
readonly bleed: {
|
|
116
|
+
readonly after: 150;
|
|
117
|
+
readonly grow: 0.35;
|
|
118
|
+
readonly tau: 700;
|
|
119
|
+
};
|
|
120
|
+
readonly pitch: {
|
|
121
|
+
readonly k: 0.3;
|
|
122
|
+
readonly min: 0.12;
|
|
123
|
+
readonly max: 0.5;
|
|
124
|
+
};
|
|
125
|
+
};
|
|
126
|
+
/** The pen in the hand and on the board: its length, barrel radius, the cap's length, how steeply it rises from the tip (height per unit of length), how high it hovers unpressed, its lean with speed (rad). */
|
|
127
|
+
readonly pen: {
|
|
128
|
+
readonly length: 150;
|
|
129
|
+
readonly radius: 6.5;
|
|
130
|
+
readonly cap: 42;
|
|
131
|
+
readonly rise: 0.18;
|
|
132
|
+
readonly hover: 6;
|
|
133
|
+
readonly lean: 0.16;
|
|
134
|
+
};
|
|
135
|
+
/** The eraser in the hand: the felt block's half extents, the felt's and the wooden back's heights. */
|
|
136
|
+
readonly block: {
|
|
137
|
+
readonly half: readonly [18, 8];
|
|
138
|
+
readonly felt: 4;
|
|
139
|
+
readonly wood: 10;
|
|
140
|
+
};
|
|
141
|
+
readonly ring: 1.5;
|
|
142
|
+
/** The open board: CSS px kept clear round it and for the tray under it, the zoom band, and the pinch-out that closes it (× the framing's zoom). */
|
|
143
|
+
readonly focus: {
|
|
144
|
+
readonly pad: 48;
|
|
145
|
+
readonly tray: 92;
|
|
146
|
+
readonly minZoom: 0.5;
|
|
147
|
+
readonly maxZoom: 3;
|
|
148
|
+
readonly close: 0.72;
|
|
149
|
+
};
|
|
150
|
+
};
|
|
@@ -0,0 +1,97 @@
|
|
|
1
|
+
import { type Entity, type GuardedTx, type World } from "../../../core/src/index";
|
|
2
|
+
import type { CalEvent } from "./events";
|
|
3
|
+
import { type CalendarLaw } from "./law";
|
|
4
|
+
/** A pad's event: a line on a day or a band across days (`start` … `end`, inclusive ISO day keys). */
|
|
5
|
+
export declare const CalendarEvent: import("@vibecook/strata-ecs").Component<import("@vibecook/strata-ecs").ValueOf<{
|
|
6
|
+
readonly start: import("@vibecook/strata-ecs").FieldSpec<"string", true>;
|
|
7
|
+
readonly end: import("@vibecook/strata-ecs").FieldSpec<"string", true>;
|
|
8
|
+
readonly text: import("@vibecook/strata-ecs").FieldSpec<"string", true>;
|
|
9
|
+
readonly seeds: import("@vibecook/strata-ecs").FieldSpec<"string", true>;
|
|
10
|
+
readonly ink: import("@vibecook/strata-ecs").FieldSpec<"string", true>;
|
|
11
|
+
}>, {
|
|
12
|
+
readonly start: import("@vibecook/strata-ecs").FieldSpec<"string", true>;
|
|
13
|
+
readonly end: import("@vibecook/strata-ecs").FieldSpec<"string", true>;
|
|
14
|
+
readonly text: import("@vibecook/strata-ecs").FieldSpec<"string", true>;
|
|
15
|
+
readonly seeds: import("@vibecook/strata-ecs").FieldSpec<"string", true>;
|
|
16
|
+
readonly ink: import("@vibecook/strata-ecs").FieldSpec<"string", true>;
|
|
17
|
+
}>;
|
|
18
|
+
export declare const EVENT_TYPE = "desk.event";
|
|
19
|
+
export declare const EventPrefab: import("../../../core/src/index").Prefab;
|
|
20
|
+
/** A note stuck to a day of a pad: the pin's day (ISO key); its note by the `PinsNote` edge. */
|
|
21
|
+
export declare const NotePin: import("@vibecook/strata-ecs").Component<import("@vibecook/strata-ecs").ValueOf<{
|
|
22
|
+
readonly day: import("@vibecook/strata-ecs").FieldSpec<"string", true>;
|
|
23
|
+
}>, {
|
|
24
|
+
readonly day: import("@vibecook/strata-ecs").FieldSpec<"string", true>;
|
|
25
|
+
}>;
|
|
26
|
+
/**
|
|
27
|
+
* pin → the note it holds (a reified edge: the day is the pin's cell). DEPENDENT (D3t-c — core's `defineRelation({ dependent })`):
|
|
28
|
+
* the pin dies with its note in the same transaction (a stuck note deleted leaves no pin behind; one ⌘Z brings both back).
|
|
29
|
+
*/
|
|
30
|
+
export declare const PinsNote: import("@vibecook/strata-ecs").Relation;
|
|
31
|
+
/** The notes stuck to a pad, with their days (its pins' edges) — what rides with it, what goes with its months. */
|
|
32
|
+
export declare function pinnedNotes(world: World, pad: Entity): {
|
|
33
|
+
readonly pin: Entity;
|
|
34
|
+
readonly note: Entity;
|
|
35
|
+
readonly day: string;
|
|
36
|
+
}[];
|
|
37
|
+
export declare const PIN_TYPE = "desk.pin";
|
|
38
|
+
export declare const PinPrefab: import("../../../core/src/index").Prefab;
|
|
39
|
+
/**
|
|
40
|
+
* Runtime, on a pad: the USER's selection on it (D3t-c) — a run of days (`anchor` … `focus`, day keys; "" none) or one entry
|
|
41
|
+
* (`entry`, an event child; 0 none) — and `home`, bumped by the held bar's today (the hand then rolls home and selects today).
|
|
42
|
+
* The user's fact, as `Selected` is: never in the document, a peer's selection its own. Its writers: the calendar's hand
|
|
43
|
+
* (objects/calendar-hand.ts, host/calendar-input.ts) and the today tool's bump.
|
|
44
|
+
*/
|
|
45
|
+
export declare const PadSelection: import("@vibecook/strata-ecs").Component<import("@vibecook/strata-ecs").ValueOf<{
|
|
46
|
+
readonly anchor: import("@vibecook/strata-ecs").FieldSpec<"string", true>;
|
|
47
|
+
readonly focus: import("@vibecook/strata-ecs").FieldSpec<"string", true>;
|
|
48
|
+
readonly entry: import("@vibecook/strata-ecs").FieldSpec<"eid", true>;
|
|
49
|
+
readonly home: import("@vibecook/strata-ecs").FieldSpec<"u32", true>;
|
|
50
|
+
}>, {
|
|
51
|
+
readonly anchor: import("@vibecook/strata-ecs").FieldSpec<"string", true>;
|
|
52
|
+
readonly focus: import("@vibecook/strata-ecs").FieldSpec<"string", true>;
|
|
53
|
+
readonly entry: import("@vibecook/strata-ecs").FieldSpec<"eid", true>;
|
|
54
|
+
readonly home: import("@vibecook/strata-ecs").FieldSpec<"u32", true>;
|
|
55
|
+
}>;
|
|
56
|
+
/** An event as an author states one. */
|
|
57
|
+
export interface EventSpec {
|
|
58
|
+
readonly start: string;
|
|
59
|
+
readonly end?: string;
|
|
60
|
+
readonly text?: string;
|
|
61
|
+
readonly seeds?: string;
|
|
62
|
+
readonly ink?: string;
|
|
63
|
+
}
|
|
64
|
+
/** Write an event on a pad — one entity, the pad's newest child — inside the caller's transaction. */
|
|
65
|
+
export declare function addEvent(tx: GuardedTx, pad: Entity, s: EventSpec): Entity;
|
|
66
|
+
/** Stick a note to a day of a pad — the pin a child of the pad, its edge to the note — inside the caller's transaction. */
|
|
67
|
+
export declare function pinNote(tx: GuardedTx, pad: Entity, note: Entity, day: string): Entity;
|
|
68
|
+
/** A month index as its key ("2026-09"). */
|
|
69
|
+
export declare function monthKeyOf(m: number): string;
|
|
70
|
+
/** A month key (YYYY-MM) as the law's month index; undefined when it is not one. */
|
|
71
|
+
export declare function monthOfKey(key: string): number | undefined;
|
|
72
|
+
/**
|
|
73
|
+
* Where a note stuck to `day` lies on a pad centred at (cx, cy) — its day's slot on the month that day is in (the
|
|
74
|
+
* lab's `slotOf`; the oracle's `pinnedAt`), world units. Throws for a day off its month's sheet.
|
|
75
|
+
*/
|
|
76
|
+
export declare function daySlot(cx: number, cy: number, day: string, weekStart?: 0 | 1, law?: CalendarLaw): {
|
|
77
|
+
readonly x: number;
|
|
78
|
+
readonly y: number;
|
|
79
|
+
};
|
|
80
|
+
/** An event's cell as a reader takes it (a tolerant reader: a string field strata hands back as null reads as its default). */
|
|
81
|
+
export interface EventRow {
|
|
82
|
+
readonly start: string | null;
|
|
83
|
+
readonly end: string | null;
|
|
84
|
+
readonly text: string | null;
|
|
85
|
+
readonly seeds: string | null;
|
|
86
|
+
readonly ink: string | null;
|
|
87
|
+
}
|
|
88
|
+
/** A day key's day number, or undefined when it is not one (YYYY-MM-DD, a real day). */
|
|
89
|
+
export declare function dayOr(key: string): number | undefined;
|
|
90
|
+
/**
|
|
91
|
+
* An event entity as the PRINT takes it (calendar/events.ts `CalEvent`, the prototype's): its days as day numbers, its text and
|
|
92
|
+
* its hand's seeds decoded, and two numbers the prototype kept on the event and the world does not (D-D3t-c.2): its own `seed`
|
|
93
|
+
* — the band's wobble, the hand of a glyph with no stored seed — made from what the entry IS (its days and its ink, so it holds
|
|
94
|
+
* still while the entry is written), identical on every peer; and its `rev`, a hash of its whole cell (a cell edited redraws
|
|
95
|
+
* the tiles over it). Null for a cell whose days are not days.
|
|
96
|
+
*/
|
|
97
|
+
export declare function calEventOf(entity: Entity, row: EventRow): CalEvent | null;
|
|
@@ -0,0 +1,58 @@
|
|
|
1
|
+
/** One entry on the calendar. */
|
|
2
|
+
export interface CalEvent {
|
|
3
|
+
readonly id: number;
|
|
4
|
+
/** First and last day (day numbers, inclusive); equal for a one-day line. */
|
|
5
|
+
start: number;
|
|
6
|
+
end: number;
|
|
7
|
+
text: string;
|
|
8
|
+
/** Each glyph's seed — its hand (paper/text.ts `carrySeeds`). */
|
|
9
|
+
seeds: number[];
|
|
10
|
+
seed: number;
|
|
11
|
+
/** The pen (a line) or the highlighter (a band) — the host's names; the law never reads them. */
|
|
12
|
+
ink: string;
|
|
13
|
+
/** Bumped on every edit: part of the raster's key. */
|
|
14
|
+
rev: number;
|
|
15
|
+
}
|
|
16
|
+
export declare const isSpan: (e: CalEvent) => boolean;
|
|
17
|
+
/**
|
|
18
|
+
* A time at the head of an entry: `9:30`, `14:00`, `9am`, `9.30pm`, `3 pm`, `12a` — hours and minutes,
|
|
19
|
+
* or an hour with am/pm. A bare number is not a time ("3 apples"). Returns minutes after midnight
|
|
20
|
+
* and how many characters it took (with the space after it), or null.
|
|
21
|
+
*/
|
|
22
|
+
export declare function parseTime(text: string): {
|
|
23
|
+
readonly minutes: number;
|
|
24
|
+
readonly len: number;
|
|
25
|
+
} | null;
|
|
26
|
+
/** An event's time, or null (an all-day line). */
|
|
27
|
+
export declare const timeOf: (e: CalEvent) => number | null;
|
|
28
|
+
/** The order of a day's one-day lines: untimed first (as written, by id), then timed by the clock. */
|
|
29
|
+
export declare function compareLines(a: CalEvent, b: CalEvent): number;
|
|
30
|
+
/** One week's piece of a band: the columns it covers in that row, its lane, whether the event starts or ends in it. */
|
|
31
|
+
export interface SpanSeg {
|
|
32
|
+
readonly event: CalEvent;
|
|
33
|
+
readonly row: number;
|
|
34
|
+
readonly col0: number;
|
|
35
|
+
readonly col1: number;
|
|
36
|
+
readonly lane: number;
|
|
37
|
+
readonly head: boolean;
|
|
38
|
+
readonly tail: boolean;
|
|
39
|
+
}
|
|
40
|
+
/** A day's lines as its cell writes them (an entry may take two lines: `layoutMonth`'s `size`). */
|
|
41
|
+
export interface CellLines {
|
|
42
|
+
readonly day: number;
|
|
43
|
+
/** Lines the week's bands take at the top of this cell (their lanes through it). */
|
|
44
|
+
readonly lanes: number;
|
|
45
|
+
/** The one-day lines, sorted; those that fit and those that do not. */
|
|
46
|
+
readonly shown: readonly CalEvent[];
|
|
47
|
+
readonly hidden: number;
|
|
48
|
+
}
|
|
49
|
+
/**
|
|
50
|
+
* Lay a grid's weeks out: every band cut into its week rows and given a lane that holds across the row
|
|
51
|
+
* (sorted by start, the longer first; the first lane free for all its columns), and every day's one-day
|
|
52
|
+
* lines. `capacity(day, lanes)` says how many lines a cell has in all (the host knows the cell's height
|
|
53
|
+
* and whether a note hangs in it); `size(e)` how many a one-day entry takes (its writing wraps).
|
|
54
|
+
*/
|
|
55
|
+
export declare function layoutMonth(events: readonly CalEvent[], first: number, rows: number, capacity: (day: number, lanes: number) => number, size?: (e: CalEvent) => number): {
|
|
56
|
+
readonly spans: readonly SpanSeg[];
|
|
57
|
+
readonly cells: readonly CellLines[];
|
|
58
|
+
};
|
|
@@ -0,0 +1,53 @@
|
|
|
1
|
+
import { type Entity, type World } from "../../../core/src/index";
|
|
2
|
+
import { type CalendarLaw } from "./law";
|
|
3
|
+
import { type Pads } from "./kind";
|
|
4
|
+
import type { CalendarWriting } from "./writing";
|
|
5
|
+
import { type TypingDocs } from "../../../desk/src/index";
|
|
6
|
+
export interface CalendarHandOptions {
|
|
7
|
+
readonly world: World;
|
|
8
|
+
readonly docs: TypingDocs;
|
|
9
|
+
readonly pads: () => Pads | undefined;
|
|
10
|
+
readonly writing: CalendarWriting;
|
|
11
|
+
/** The editor's caret on the line being written — its index and when its blink restarted (the hand's clock) — and the newest glyph's wipe. */
|
|
12
|
+
readonly caret: () => {
|
|
13
|
+
readonly index: number;
|
|
14
|
+
readonly t0: number;
|
|
15
|
+
readonly wipe: {
|
|
16
|
+
readonly index: number;
|
|
17
|
+
readonly t0: number;
|
|
18
|
+
} | null;
|
|
19
|
+
} | null;
|
|
20
|
+
/** The caret's blink, ms (530). */
|
|
21
|
+
readonly blinkMs?: number;
|
|
22
|
+
/** The newest glyph's wipe, ms (the hand's 110). */
|
|
23
|
+
readonly wipeMs?: number;
|
|
24
|
+
/** Where a transaction runs: out of the frame (a microtask) unless a test says. */
|
|
25
|
+
readonly defer?: (fn: () => void) => void;
|
|
26
|
+
/** The builder's word on a pad — its geometry as drawn, the hand's frame, the held pose (the roll by hand reads them; absent: no hands). */
|
|
27
|
+
readonly geometryOf?: (e: Entity) => unknown;
|
|
28
|
+
readonly hand?: () => {
|
|
29
|
+
readonly entity: Entity;
|
|
30
|
+
readonly landing: boolean;
|
|
31
|
+
readonly frame: {
|
|
32
|
+
readonly cx: number;
|
|
33
|
+
readonly cy: number;
|
|
34
|
+
readonly s: number;
|
|
35
|
+
};
|
|
36
|
+
} | undefined;
|
|
37
|
+
readonly heldToWorld?: (e: Entity, x: number, y: number) => readonly [number, number] | undefined;
|
|
38
|
+
readonly isPad?: (e: Entity) => boolean;
|
|
39
|
+
/** Is this entity a sticky note (it may be stuck to a day)? Absent: nothing sticks. */
|
|
40
|
+
readonly isNote?: (e: Entity) => boolean;
|
|
41
|
+
/** The glide into a day's slot, ms (the prototype's 3.2 Hz spring, as a tween). */
|
|
42
|
+
readonly glideMs?: number;
|
|
43
|
+
readonly law?: CalendarLaw;
|
|
44
|
+
}
|
|
45
|
+
export interface CalendarHand {
|
|
46
|
+
/** Once a frame, before the kinds' clocks: the marks on every pad; the bar's today acted on. */
|
|
47
|
+
follow(now: number): void;
|
|
48
|
+
/** Nothing to follow (D7 #14): no pad on the desk, nothing in hand, no press, no selection, no note carried, no glide owed. */
|
|
49
|
+
idle(): boolean;
|
|
50
|
+
/** Leave the document's commit door (the landing's extender). */
|
|
51
|
+
dispose(): void;
|
|
52
|
+
}
|
|
53
|
+
export declare function createCalendarHand(opts: CalendarHandOptions): CalendarHand;
|
|
@@ -0,0 +1,67 @@
|
|
|
1
|
+
import { type Entity, type WidgetType, type World } from "../../../../core/src/index";
|
|
2
|
+
import { type CalendarLaw } from "../law";
|
|
3
|
+
import type { EventLine } from "../print";
|
|
4
|
+
import { type CalendarPart } from "../kind";
|
|
5
|
+
import type { CalendarDriver } from "../object";
|
|
6
|
+
import { type TypingDocs } from "../../../../desk/src/index";
|
|
7
|
+
import type { DeskEditor } from "../../../../desk/src/kit/index";
|
|
8
|
+
/** The desk calendar's text part's name (K8a) — a day's line: what the editor's lease carries while the calendar holds it. */
|
|
9
|
+
export declare const CALENDAR_LINE = "calendar.line";
|
|
10
|
+
export interface CalendarInputOptions {
|
|
11
|
+
readonly container: HTMLElement;
|
|
12
|
+
readonly world: World;
|
|
13
|
+
/** The builder's word on a pad: its geometry as drawn, the hand's frame, the held pose (host/layer.ts hands the builder). */
|
|
14
|
+
readonly geometryOf: (e: Entity) => unknown;
|
|
15
|
+
readonly hand: () => {
|
|
16
|
+
readonly entity: Entity;
|
|
17
|
+
readonly landing: boolean;
|
|
18
|
+
readonly frame: {
|
|
19
|
+
readonly cx: number;
|
|
20
|
+
readonly cy: number;
|
|
21
|
+
readonly s: number;
|
|
22
|
+
};
|
|
23
|
+
} | undefined;
|
|
24
|
+
readonly heldToWorld: (e: Entity, x: number, y: number) => readonly [number, number] | undefined;
|
|
25
|
+
readonly editor: DeskEditor;
|
|
26
|
+
/** The calendar's driver (`CalendarDriver`, D-D7-A.3): this is the CALENDAR's DOM half, which the calendar declares (K4b) — the host hands it the calendar's own and it joins it; none, no input. */
|
|
27
|
+
readonly driver: CalendarDriver | undefined;
|
|
28
|
+
/** The calendar object (its compiled widget type — its first group is a pad's props: its month, its week start). */
|
|
29
|
+
readonly object: WidgetType;
|
|
30
|
+
readonly docs: TypingDocs;
|
|
31
|
+
/** The calendar's look as the desk composed it (the highlighters a band is drawn in). */
|
|
32
|
+
readonly look: () => unknown;
|
|
33
|
+
readonly law?: CalendarLaw;
|
|
34
|
+
/** The hand's clock (the caret's blink, the wipe): `performance.now` unless a test says. */
|
|
35
|
+
readonly now?: () => number;
|
|
36
|
+
readonly wake: () => void;
|
|
37
|
+
}
|
|
38
|
+
export interface CalendarInput {
|
|
39
|
+
/** The caret on the line being written — its index, its blink's restart, the newest glyph's wipe — for the hand's marks. */
|
|
40
|
+
caret(): {
|
|
41
|
+
readonly index: number;
|
|
42
|
+
readonly t0: number;
|
|
43
|
+
readonly wipe: {
|
|
44
|
+
readonly index: number;
|
|
45
|
+
readonly t0: number;
|
|
46
|
+
} | null;
|
|
47
|
+
} | null;
|
|
48
|
+
/** Select days on a pad (a rig's door, the keys' own path): a run from `anchor` to `focus`; lends the editor. */
|
|
49
|
+
selectDays(pad: Entity, anchor: number, focus: number): void;
|
|
50
|
+
/** Select an entry on a pad; lends the editor. */
|
|
51
|
+
selectEntry(pad: Entity, entry: Entity): void;
|
|
52
|
+
/** Let go of the selection (and the editor). */
|
|
53
|
+
clear(): void;
|
|
54
|
+
/** Begin writing a new line on the selected days (the ⏎'s path); true when it began. */
|
|
55
|
+
write(): boolean;
|
|
56
|
+
/** Write into an entry, the caret at `index` (the end by default). */
|
|
57
|
+
edit(pad: Entity, entry: Entity, index?: number): boolean;
|
|
58
|
+
/** What a client point lands on — the pad and its part — as a click would read it (a rig's door). */
|
|
59
|
+
partAtClient(clientX: number, clientY: number): {
|
|
60
|
+
readonly pad: Entity;
|
|
61
|
+
readonly part: CalendarPart;
|
|
62
|
+
} | null;
|
|
63
|
+
dispose(): void;
|
|
64
|
+
}
|
|
65
|
+
/** The caret index nearest a sheet point on a line — where a tap puts the pen (the prototype's `caretIndexAt`). */
|
|
66
|
+
export declare function caretIndexAt(line: EventLine, sx: number, sy: number): number;
|
|
67
|
+
export declare function createCalendarInput(opts: CalendarInputOptions): CalendarInput | undefined;
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { type TextRaster, type PrintRaster } from "../../../../desk/src/kit/index";
|
|
2
|
+
import { type SheetPrint } from "../print";
|
|
3
|
+
export interface PrintRasterOptions {
|
|
4
|
+
/** The desk's text raster: the hand's face and its metrics (the note's). */
|
|
5
|
+
readonly text: TextRaster;
|
|
6
|
+
/** The hand's face by name (`PEN_FACES` — the note's Caveat unless a host says). */
|
|
7
|
+
readonly face?: string;
|
|
8
|
+
}
|
|
9
|
+
export declare function printRaster(opts: PrintRasterOptions): PrintRaster<SheetPrint>;
|