@motionscript/core 0.1.0-alpha.5 → 0.1.0-alpha.7
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/CHANGELOG.md +55 -0
- package/README.md +2 -4
- package/dist/assets/errors.js +4 -5
- package/dist/assets/errors.js.map +1 -1
- package/dist/assets/scope.d.ts +1 -1
- package/dist/assets/scope.d.ts.map +1 -1
- package/dist/assets/scope.js +1 -1
- package/dist/assets/scope.js.map +1 -1
- package/dist/attributes/audio/schedule.d.ts +3 -18
- package/dist/attributes/audio/schedule.d.ts.map +1 -1
- package/dist/attributes/audio/schedule.js.map +1 -1
- package/dist/attributes/index.d.ts +3 -5
- package/dist/attributes/index.d.ts.map +1 -1
- package/dist/attributes/index.js +2 -2
- package/dist/attributes/index.js.map +1 -1
- package/dist/attributes/layout/insets.d.ts +1 -1
- package/dist/attributes/layout/insets.js.map +1 -1
- package/dist/attributes/layout/size.d.ts +1 -1
- package/dist/attributes/layout/size.js +1 -1
- package/dist/attributes/layout/size.js.map +1 -1
- package/dist/attributes/properties/decorator.d.ts +44 -11
- package/dist/attributes/properties/decorator.d.ts.map +1 -1
- package/dist/attributes/properties/decorator.js +37 -9
- package/dist/attributes/properties/decorator.js.map +1 -1
- package/dist/attributes/properties/inputs.d.ts +1 -1
- package/dist/attributes/properties/inputs.js +1 -1
- package/dist/attributes/properties/inputs.js.map +1 -1
- package/dist/attributes/properties/typed.d.ts +19 -140
- package/dist/attributes/properties/typed.d.ts.map +1 -1
- package/dist/attributes/properties/typed.js +12 -108
- package/dist/attributes/properties/typed.js.map +1 -1
- package/dist/attributes/shape/corners/corner-radius.d.ts +1 -1
- package/dist/attributes/shape/corners/corner-radius.js +1 -1
- package/dist/attributes/shape/corners/corner-radius.js.map +1 -1
- package/dist/attributes/shape/effects/implementations/drop-shadow.d.ts +1 -1
- package/dist/attributes/shape/effects/implementations/drop-shadow.js.map +1 -1
- package/dist/attributes/shape/fill/color/parser.d.ts +1 -1
- package/dist/attributes/shape/fill/color/parser.js +1 -1
- package/dist/attributes/shape/fill/color/parser.js.map +1 -1
- package/dist/attributes/shape/fill/implementations/canvas3d.d.ts +2 -2
- package/dist/attributes/shape/fill/implementations/canvas3d.js.map +1 -1
- package/dist/attributes/shape/fill/implementations/shader.d.ts +2 -2
- package/dist/attributes/shape/fill/implementations/shader.js.map +1 -1
- package/dist/attributes/shape/fill/implementations/video.d.ts +1 -1
- package/dist/attributes/shape/fill/implementations/video.js +1 -1
- package/dist/attributes/shape/fill/implementations/video.js.map +1 -1
- package/dist/attributes/shape/fill/lerp.d.ts +1 -1
- package/dist/attributes/shape/fill/lerp.js.map +1 -1
- package/dist/attributes/shape/filters/chain.d.ts +1 -1
- package/dist/attributes/shape/filters/chain.js +1 -1
- package/dist/attributes/shape/filters/chain.js.map +1 -1
- package/dist/attributes/shape/filters/union.d.ts +4 -3
- package/dist/attributes/shape/filters/union.d.ts.map +1 -1
- package/dist/attributes/shape/filters/union.js.map +1 -1
- package/dist/attributes/shape/path/ops.d.ts +1 -2
- package/dist/attributes/shape/path/ops.d.ts.map +1 -1
- package/dist/attributes/shape/path/ops.js.map +1 -1
- package/dist/attributes/shared/operators.d.ts +2 -2
- package/dist/attributes/shared/operators.js.map +1 -1
- package/dist/attributes/text/types.d.ts +2 -3
- package/dist/attributes/text/types.d.ts.map +1 -1
- package/dist/attributes/text/types.js.map +1 -1
- package/dist/browser/chunks/chunk-D4FSTPML.js +14 -0
- package/dist/browser/chunks/chunk-D4FSTPML.js.map +7 -0
- package/dist/browser/chunks/chunk-LKUYVFU3.js +2 -0
- package/dist/browser/chunks/chunk-LKUYVFU3.js.map +7 -0
- package/dist/browser/chunks/chunk-RTNATFWX.js +5 -0
- package/dist/browser/chunks/chunk-RTNATFWX.js.map +7 -0
- package/dist/browser/chunks/chunk-ZRPZPWZU.js +3 -0
- package/dist/browser/chunks/chunk-ZRPZPWZU.js.map +7 -0
- package/dist/browser/component.js +1 -1
- package/dist/browser/component.js.map +4 -4
- package/dist/browser/experimental.js +2 -0
- package/dist/browser/index.js +1 -1
- package/dist/browser/index.js.map +4 -4
- package/dist/browser/manifest.json +3 -4
- package/dist/browser/sdk.js +1 -1
- package/dist/component/api.d.ts +508 -0
- package/dist/component/api.d.ts.map +1 -0
- package/dist/component/api.js +4 -0
- package/dist/component/api.js.map +1 -0
- package/dist/component/builtins/audio.d.ts +26 -0
- package/dist/component/builtins/audio.d.ts.map +1 -0
- package/dist/component/builtins/audio.js +41 -0
- package/dist/component/builtins/audio.js.map +1 -0
- package/dist/component/builtins/canvas3d.d.ts +98 -0
- package/dist/component/builtins/canvas3d.d.ts.map +1 -0
- package/dist/component/builtins/canvas3d.js +21 -0
- package/dist/component/builtins/canvas3d.js.map +1 -0
- package/dist/component/builtins/composite.d.ts +56 -0
- package/dist/component/builtins/composite.d.ts.map +1 -0
- package/dist/component/builtins/composite.js +25 -0
- package/dist/component/builtins/composite.js.map +1 -0
- package/dist/component/builtins/geometry.d.ts +505 -0
- package/dist/component/builtins/geometry.d.ts.map +1 -0
- package/dist/component/builtins/geometry.js +107 -0
- package/dist/component/builtins/geometry.js.map +1 -0
- package/dist/component/builtins/layout.d.ts +88 -0
- package/dist/component/builtins/layout.d.ts.map +1 -0
- package/dist/component/builtins/layout.js +84 -0
- package/dist/component/builtins/layout.js.map +1 -0
- package/dist/component/builtins/media.d.ts +95 -0
- package/dist/component/builtins/media.d.ts.map +1 -0
- package/dist/component/builtins/media.js +149 -0
- package/dist/component/builtins/media.js.map +1 -0
- package/dist/component/builtins/providers.d.ts +23 -0
- package/dist/component/builtins/providers.d.ts.map +1 -0
- package/dist/component/builtins/providers.js +30 -0
- package/dist/component/builtins/providers.js.map +1 -0
- package/dist/component/builtins/text.d.ts +193 -0
- package/dist/component/builtins/text.d.ts.map +1 -0
- package/dist/component/builtins/text.js +113 -0
- package/dist/component/builtins/text.js.map +1 -0
- package/dist/component/builtins/three.d.ts +1085 -0
- package/dist/component/builtins/three.d.ts.map +1 -0
- package/dist/component/builtins/three.js +265 -0
- package/dist/component/builtins/three.js.map +1 -0
- package/dist/component/clip-of.d.ts +5 -0
- package/dist/component/clip-of.d.ts.map +1 -0
- package/dist/component/clip-of.js +33 -0
- package/dist/component/clip-of.js.map +1 -0
- package/dist/component/commands-for.d.ts +19 -0
- package/dist/component/commands-for.d.ts.map +1 -0
- package/dist/component/commands-for.js +5 -0
- package/dist/component/commands-for.js.map +1 -0
- package/dist/component/component-audio.d.ts +9 -0
- package/dist/component/component-audio.d.ts.map +1 -0
- package/dist/component/component-audio.js +18 -0
- package/dist/component/component-audio.js.map +1 -0
- package/dist/component/component2d.d.ts +9 -0
- package/dist/component/component2d.d.ts.map +1 -0
- package/dist/component/component2d.js +239 -0
- package/dist/component/component2d.js.map +1 -0
- package/dist/component/component3d.d.ts +9 -0
- package/dist/component/component3d.d.ts.map +1 -0
- package/dist/component/component3d.js +99 -0
- package/dist/component/component3d.js.map +1 -0
- package/dist/component/factory.d.ts +63 -0
- package/dist/component/factory.d.ts.map +1 -0
- package/dist/component/factory.js +313 -0
- package/dist/component/factory.js.map +1 -0
- package/dist/component/modules/aim.d.ts +30 -0
- package/dist/component/modules/aim.d.ts.map +1 -0
- package/dist/component/modules/aim.js +39 -0
- package/dist/component/modules/aim.js.map +1 -0
- package/dist/component/modules/corners.d.ts +13 -0
- package/dist/component/modules/corners.d.ts.map +1 -0
- package/dist/component/modules/corners.js +12 -0
- package/dist/component/modules/corners.js.map +1 -0
- package/dist/component/modules/flow.d.ts +26 -0
- package/dist/component/modules/flow.d.ts.map +1 -0
- package/dist/component/modules/flow.js +55 -0
- package/dist/component/modules/flow.js.map +1 -0
- package/dist/component/modules/material.d.ts +40 -0
- package/dist/component/modules/material.d.ts.map +1 -0
- package/dist/component/modules/material.js +75 -0
- package/dist/component/modules/material.js.map +1 -0
- package/dist/component/modules/paint.d.ts +71 -0
- package/dist/component/modules/paint.d.ts.map +1 -0
- package/dist/component/modules/paint.js +106 -0
- package/dist/component/modules/paint.js.map +1 -0
- package/dist/component/modules/shapes.d.ts +31 -0
- package/dist/component/modules/shapes.d.ts.map +1 -0
- package/dist/component/modules/shapes.js +43 -0
- package/dist/component/modules/shapes.js.map +1 -0
- package/dist/component/modules/text-layout.d.ts +26 -0
- package/dist/component/modules/text-layout.d.ts.map +1 -0
- package/dist/component/modules/text-layout.js +57 -0
- package/dist/component/modules/text-layout.js.map +1 -0
- package/dist/component/modules/text-style.d.ts +48 -0
- package/dist/component/modules/text-style.d.ts.map +1 -0
- package/dist/component/modules/text-style.js +63 -0
- package/dist/component/modules/text-style.js.map +1 -0
- package/dist/component/modules/three-entries.d.ts +23 -0
- package/dist/component/modules/three-entries.d.ts.map +1 -0
- package/dist/component/modules/three-entries.js +41 -0
- package/dist/component/modules/three-entries.js.map +1 -0
- package/dist/component/modules/view3d.d.ts +55 -0
- package/dist/component/modules/view3d.d.ts.map +1 -0
- package/dist/component/modules/view3d.js +160 -0
- package/dist/component/modules/view3d.js.map +1 -0
- package/dist/component/timeline.d.ts +22 -0
- package/dist/component/timeline.d.ts.map +1 -0
- package/dist/component/timeline.js +128 -0
- package/dist/component/timeline.js.map +1 -0
- package/dist/component/type-def.d.ts +26 -0
- package/dist/component/type-def.d.ts.map +1 -0
- package/dist/component/type-def.js +16 -0
- package/dist/component/type-def.js.map +1 -0
- package/dist/component/types.d.ts +91 -0
- package/dist/component/types.d.ts.map +1 -0
- package/dist/component/types.js +88 -0
- package/dist/component/types.js.map +1 -0
- package/dist/component/views.d.ts +121 -0
- package/dist/component/views.d.ts.map +1 -0
- package/dist/component/views.js +413 -0
- package/dist/component/views.js.map +1 -0
- package/dist/component.d.ts +10 -19
- package/dist/component.d.ts.map +1 -1
- package/dist/component.js +10 -19
- package/dist/component.js.map +1 -1
- package/dist/components/builtins/audio/audio.d.ts +53 -0
- package/dist/components/builtins/audio/audio.d.ts.map +1 -0
- package/dist/components/builtins/audio/audio.js +41 -0
- package/dist/components/builtins/audio/audio.js.map +1 -0
- package/dist/components/builtins/geometry/composite.d.ts +93 -0
- package/dist/components/builtins/geometry/composite.d.ts.map +1 -0
- package/dist/components/builtins/geometry/composite.js +25 -0
- package/dist/components/builtins/geometry/composite.js.map +1 -0
- package/dist/components/builtins/geometry/geometry.d.ts +921 -0
- package/dist/components/builtins/geometry/geometry.d.ts.map +1 -0
- package/dist/components/builtins/geometry/geometry.js +107 -0
- package/dist/components/builtins/geometry/geometry.js.map +1 -0
- package/dist/components/builtins/geometry/shape-outline.d.ts +93 -0
- package/dist/components/builtins/geometry/shape-outline.d.ts.map +1 -0
- package/dist/components/builtins/geometry/shape-outline.js +470 -0
- package/dist/components/builtins/geometry/shape-outline.js.map +1 -0
- package/dist/components/builtins/layout/layout.d.ts +186 -0
- package/dist/components/builtins/layout/layout.d.ts.map +1 -0
- package/dist/components/builtins/layout/layout.js +84 -0
- package/dist/components/builtins/layout/layout.js.map +1 -0
- package/dist/components/builtins/media/media.d.ts +240 -0
- package/dist/components/builtins/media/media.d.ts.map +1 -0
- package/dist/components/builtins/media/media.js +149 -0
- package/dist/components/builtins/media/media.js.map +1 -0
- package/dist/components/builtins/providers/providers.d.ts +47 -0
- package/dist/components/builtins/providers/providers.d.ts.map +1 -0
- package/dist/components/builtins/providers/providers.js +30 -0
- package/dist/components/builtins/providers/providers.js.map +1 -0
- package/dist/components/builtins/text/number-format.d.ts +66 -0
- package/dist/components/builtins/text/number-format.d.ts.map +1 -0
- package/dist/components/builtins/text/number-format.js +227 -0
- package/dist/components/builtins/text/number-format.js.map +1 -0
- package/dist/components/builtins/text/number-pattern.d.ts +51 -0
- package/dist/components/builtins/text/number-pattern.d.ts.map +1 -0
- package/dist/components/builtins/text/number-pattern.js +77 -0
- package/dist/components/builtins/text/number-pattern.js.map +1 -0
- package/dist/components/builtins/text/text-defaults.d.ts +32 -0
- package/dist/components/builtins/text/text-defaults.d.ts.map +1 -0
- package/dist/components/builtins/text/text-defaults.js +37 -0
- package/dist/components/builtins/text/text-defaults.js.map +1 -0
- package/dist/components/builtins/text/text-layout.d.ts +82 -0
- package/dist/components/builtins/text/text-layout.d.ts.map +1 -0
- package/dist/components/builtins/text/text-layout.js +331 -0
- package/dist/components/builtins/text/text-layout.js.map +1 -0
- package/dist/components/builtins/text/text.d.ts +409 -0
- package/dist/components/builtins/text/text.d.ts.map +1 -0
- package/dist/components/builtins/text/text.js +113 -0
- package/dist/components/builtins/text/text.js.map +1 -0
- package/dist/components/builtins/three/canvas3d.d.ts +245 -0
- package/dist/components/builtins/three/canvas3d.d.ts.map +1 -0
- package/dist/components/builtins/three/canvas3d.js +21 -0
- package/dist/components/builtins/three/canvas3d.js.map +1 -0
- package/dist/components/builtins/three/grid-geometry3d.d.ts +62 -0
- package/dist/components/builtins/three/grid-geometry3d.d.ts.map +1 -0
- package/dist/components/builtins/three/grid-geometry3d.js +114 -0
- package/dist/components/builtins/three/grid-geometry3d.js.map +1 -0
- package/dist/components/builtins/three/three.d.ts +1889 -0
- package/dist/components/builtins/three/three.d.ts.map +1 -0
- package/dist/components/builtins/three/three.js +305 -0
- package/dist/components/builtins/three/three.js.map +1 -0
- package/dist/components/factory/api.d.ts +516 -0
- package/dist/components/factory/api.d.ts.map +1 -0
- package/dist/components/factory/api.js +4 -0
- package/dist/components/factory/api.js.map +1 -0
- package/dist/components/factory/clip-of.d.ts +5 -0
- package/dist/components/factory/clip-of.d.ts.map +1 -0
- package/dist/components/factory/clip-of.js +33 -0
- package/dist/components/factory/clip-of.js.map +1 -0
- package/dist/components/factory/commands-for.d.ts +19 -0
- package/dist/components/factory/commands-for.d.ts.map +1 -0
- package/dist/components/factory/commands-for.js +5 -0
- package/dist/components/factory/commands-for.js.map +1 -0
- package/dist/components/factory/component-audio.d.ts +9 -0
- package/dist/components/factory/component-audio.d.ts.map +1 -0
- package/dist/components/factory/component-audio.js +18 -0
- package/dist/components/factory/component-audio.js.map +1 -0
- package/dist/components/factory/component2d.d.ts +8 -0
- package/dist/components/factory/component2d.d.ts.map +1 -0
- package/dist/components/factory/component2d.js +240 -0
- package/dist/components/factory/component2d.js.map +1 -0
- package/dist/components/factory/component3d.d.ts +9 -0
- package/dist/components/factory/component3d.d.ts.map +1 -0
- package/dist/components/factory/component3d.js +99 -0
- package/dist/components/factory/component3d.js.map +1 -0
- package/dist/components/factory/factory.d.ts +63 -0
- package/dist/components/factory/factory.d.ts.map +1 -0
- package/dist/components/factory/factory.js +313 -0
- package/dist/components/factory/factory.js.map +1 -0
- package/dist/components/factory/timeline.d.ts +22 -0
- package/dist/components/factory/timeline.d.ts.map +1 -0
- package/dist/components/factory/timeline.js +128 -0
- package/dist/components/factory/timeline.js.map +1 -0
- package/dist/components/factory/type-def.d.ts +26 -0
- package/dist/components/factory/type-def.d.ts.map +1 -0
- package/dist/components/factory/type-def.js +16 -0
- package/dist/components/factory/type-def.js.map +1 -0
- package/dist/components/factory/types.d.ts +91 -0
- package/dist/components/factory/types.d.ts.map +1 -0
- package/dist/components/factory/types.js +88 -0
- package/dist/components/factory/types.js.map +1 -0
- package/dist/components/factory/views.d.ts +121 -0
- package/dist/components/factory/views.d.ts.map +1 -0
- package/dist/components/factory/views.js +413 -0
- package/dist/components/factory/views.js.map +1 -0
- package/dist/components/modules/aim.d.ts +30 -0
- package/dist/components/modules/aim.d.ts.map +1 -0
- package/dist/components/modules/aim.js +39 -0
- package/dist/components/modules/aim.js.map +1 -0
- package/dist/components/modules/corners.d.ts +13 -0
- package/dist/components/modules/corners.d.ts.map +1 -0
- package/dist/components/modules/corners.js +12 -0
- package/dist/components/modules/corners.js.map +1 -0
- package/dist/components/modules/flow.d.ts +26 -0
- package/dist/components/modules/flow.d.ts.map +1 -0
- package/dist/components/modules/flow.js +57 -0
- package/dist/components/modules/flow.js.map +1 -0
- package/dist/components/modules/material.d.ts +40 -0
- package/dist/components/modules/material.d.ts.map +1 -0
- package/dist/components/modules/material.js +75 -0
- package/dist/components/modules/material.js.map +1 -0
- package/dist/components/modules/paint.d.ts +71 -0
- package/dist/components/modules/paint.d.ts.map +1 -0
- package/dist/components/modules/paint.js +106 -0
- package/dist/components/modules/paint.js.map +1 -0
- package/dist/components/modules/shapes.d.ts +31 -0
- package/dist/components/modules/shapes.d.ts.map +1 -0
- package/dist/components/modules/shapes.js +43 -0
- package/dist/components/modules/shapes.js.map +1 -0
- package/dist/components/modules/text-layout.d.ts +26 -0
- package/dist/components/modules/text-layout.d.ts.map +1 -0
- package/dist/components/modules/text-layout.js +57 -0
- package/dist/components/modules/text-layout.js.map +1 -0
- package/dist/components/modules/text-style.d.ts +48 -0
- package/dist/components/modules/text-style.d.ts.map +1 -0
- package/dist/components/modules/text-style.js +63 -0
- package/dist/components/modules/text-style.js.map +1 -0
- package/dist/components/modules/three-entries.d.ts +23 -0
- package/dist/components/modules/three-entries.d.ts.map +1 -0
- package/dist/components/modules/three-entries.js +41 -0
- package/dist/components/modules/three-entries.js.map +1 -0
- package/dist/components/modules/view3d.d.ts +59 -0
- package/dist/components/modules/view3d.d.ts.map +1 -0
- package/dist/components/modules/view3d.js +171 -0
- package/dist/components/modules/view3d.js.map +1 -0
- package/dist/components/trees/2d/group-bounds.d.ts +56 -0
- package/dist/components/trees/2d/group-bounds.d.ts.map +1 -0
- package/dist/components/trees/2d/group-bounds.js +87 -0
- package/dist/components/trees/2d/group-bounds.js.map +1 -0
- package/dist/components/trees/2d/node-lifecycle.d.ts +46 -0
- package/dist/components/trees/2d/node-lifecycle.d.ts.map +1 -0
- package/dist/components/trees/2d/node-lifecycle.js +264 -0
- package/dist/components/trees/2d/node-lifecycle.js.map +1 -0
- package/dist/components/trees/2d/node-motion.d.ts +56 -0
- package/dist/components/trees/2d/node-motion.d.ts.map +1 -0
- package/dist/components/trees/2d/node-motion.js +86 -0
- package/dist/components/trees/2d/node-motion.js.map +1 -0
- package/dist/components/trees/2d/node-render.d.ts +36 -0
- package/dist/components/trees/2d/node-render.d.ts.map +1 -0
- package/dist/components/trees/2d/node-render.js +67 -0
- package/dist/components/trees/2d/node-render.js.map +1 -0
- package/dist/components/trees/2d/node-space.d.ts +63 -0
- package/dist/components/trees/2d/node-space.d.ts.map +1 -0
- package/dist/components/trees/2d/node-space.js +131 -0
- package/dist/components/trees/2d/node-space.js.map +1 -0
- package/dist/components/trees/2d/node-transform.d.ts +55 -0
- package/dist/components/trees/2d/node-transform.d.ts.map +1 -0
- package/dist/components/trees/2d/node-transform.js +73 -0
- package/dist/components/trees/2d/node-transform.js.map +1 -0
- package/dist/components/trees/2d/node2d.d.ts +1020 -0
- package/dist/components/trees/2d/node2d.d.ts.map +1 -0
- package/dist/components/trees/2d/node2d.js +1481 -0
- package/dist/components/trees/2d/node2d.js.map +1 -0
- package/dist/components/trees/audio/index.d.ts +2 -0
- package/dist/components/trees/audio/index.d.ts.map +1 -0
- package/dist/components/trees/audio/index.js +2 -0
- package/dist/components/trees/audio/index.js.map +1 -0
- package/dist/components/trees/audio/node-audio.d.ts +109 -0
- package/dist/components/trees/audio/node-audio.d.ts.map +1 -0
- package/dist/components/trees/audio/node-audio.js +167 -0
- package/dist/components/trees/audio/node-audio.js.map +1 -0
- package/dist/components/trees/index.d.ts +10 -0
- package/dist/components/trees/index.d.ts.map +1 -0
- package/dist/components/trees/index.js +14 -0
- package/dist/components/trees/index.js.map +1 -0
- package/dist/components/trees/node/node-editor-state.d.ts +53 -0
- package/dist/components/trees/node/node-editor-state.d.ts.map +1 -0
- package/dist/components/trees/node/node-editor-state.js +23 -0
- package/dist/components/trees/node/node-editor-state.js.map +1 -0
- package/dist/components/trees/node/node-reactive.d.ts +89 -0
- package/dist/components/trees/node/node-reactive.d.ts.map +1 -0
- package/dist/components/trees/node/node-reactive.js +135 -0
- package/dist/components/trees/node/node-reactive.js.map +1 -0
- package/dist/components/trees/node/node-time.d.ts +39 -0
- package/dist/components/trees/node/node-time.d.ts.map +1 -0
- package/dist/components/trees/node/node-time.js +14 -0
- package/dist/components/trees/node/node-time.js.map +1 -0
- package/dist/components/trees/node/node-walk.d.ts +46 -0
- package/dist/components/trees/node/node-walk.d.ts.map +1 -0
- package/dist/components/trees/node/node-walk.js +74 -0
- package/dist/components/trees/node/node-walk.js.map +1 -0
- package/dist/components/trees/node/node.d.ts +401 -0
- package/dist/components/trees/node/node.d.ts.map +1 -0
- package/dist/components/trees/node/node.js +680 -0
- package/dist/components/trees/node/node.js.map +1 -0
- package/dist/components/trees/root/canvas2d-node.d.ts +163 -0
- package/dist/components/trees/root/canvas2d-node.d.ts.map +1 -0
- package/dist/components/trees/root/canvas2d-node.js +216 -0
- package/dist/components/trees/root/canvas2d-node.js.map +1 -0
- package/dist/components/trees/three/node3d.d.ts +222 -0
- package/dist/components/trees/three/node3d.d.ts.map +1 -0
- package/dist/components/trees/three/node3d.js +289 -0
- package/dist/components/trees/three/node3d.js.map +1 -0
- package/dist/document/audio.d.ts +9 -1
- package/dist/document/audio.d.ts.map +1 -1
- package/dist/document/audio.js +41 -0
- package/dist/document/audio.js.map +1 -1
- package/dist/document/builtins.d.ts.map +1 -1
- package/dist/document/builtins.js +13 -31
- package/dist/document/builtins.js.map +1 -1
- package/dist/document/command-traits.d.ts +2 -2
- package/dist/document/command-traits.js +4 -1
- package/dist/document/command-traits.js.map +1 -1
- package/dist/document/deny-globals.d.ts +2 -2
- package/dist/document/deny-globals.js +2 -2
- package/dist/document/deny-globals.js.map +1 -1
- package/dist/document/diff.d.ts.map +1 -1
- package/dist/document/diff.js +3 -3
- package/dist/document/diff.js.map +1 -1
- package/dist/document/doc-index.d.ts.map +1 -1
- package/dist/document/doc-index.js +3 -3
- package/dist/document/doc-index.js.map +1 -1
- package/dist/document/expression/index.d.ts +1 -1
- package/dist/document/expression/index.js +1 -1
- package/dist/document/expression/index.js.map +1 -1
- package/dist/document/expression/ops.js +1 -1
- package/dist/document/expression/ops.js.map +1 -1
- package/dist/document/index.d.ts +1 -2
- package/dist/document/index.d.ts.map +1 -1
- package/dist/document/index.js +1 -2
- package/dist/document/index.js.map +1 -1
- package/dist/document/node-decorator.d.ts +14 -10
- package/dist/document/node-decorator.d.ts.map +1 -1
- package/dist/document/node-decorator.js +14 -10
- package/dist/document/node-decorator.js.map +1 -1
- package/dist/document/node-descriptor.d.ts +9 -3
- package/dist/document/node-descriptor.d.ts.map +1 -1
- package/dist/document/node-descriptor.js.map +1 -1
- package/dist/document/placement.js +2 -2
- package/dist/document/placement.js.map +1 -1
- package/dist/document/registry.d.ts +29 -36
- package/dist/document/registry.d.ts.map +1 -1
- package/dist/document/registry.js +29 -35
- package/dist/document/registry.js.map +1 -1
- package/dist/document/settled-index.d.ts +49 -0
- package/dist/document/settled-index.d.ts.map +1 -0
- package/dist/document/settled-index.js +247 -0
- package/dist/document/settled-index.js.map +1 -0
- package/dist/document/timeline.d.ts +29 -3
- package/dist/document/timeline.d.ts.map +1 -1
- package/dist/document/timeline.js +99 -3
- package/dist/document/timeline.js.map +1 -1
- package/dist/document/types.d.ts +4 -4
- package/dist/document/types.js.map +1 -1
- package/dist/document/validate.d.ts +1 -1
- package/dist/document/validate.js.map +1 -1
- package/dist/experimental.d.ts +22 -0
- package/dist/experimental.d.ts.map +1 -0
- package/dist/experimental.js +20 -0
- package/dist/experimental.js.map +1 -0
- package/dist/index.d.ts +10 -2
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +10 -2
- package/dist/index.js.map +1 -1
- package/dist/layout/types.d.ts +1 -1
- package/dist/layout/types.js.map +1 -1
- package/dist/nodes/audio/index.d.ts +2 -2
- package/dist/nodes/audio/index.d.ts.map +1 -1
- package/dist/nodes/audio/index.js +0 -2
- package/dist/nodes/audio/index.js.map +1 -1
- package/dist/nodes/audio/sound-node.d.ts +2 -1
- package/dist/nodes/audio/sound-node.d.ts.map +1 -1
- package/dist/nodes/audio/sound-node.js +3 -0
- package/dist/nodes/audio/sound-node.js.map +1 -1
- package/dist/nodes/index.d.ts +39 -27
- package/dist/nodes/index.d.ts.map +1 -1
- package/dist/nodes/index.js +16 -30
- package/dist/nodes/index.js.map +1 -1
- package/dist/nodes/node/node.d.ts +7 -1
- package/dist/nodes/node/node.d.ts.map +1 -1
- package/dist/nodes/node/node.js +23 -8
- package/dist/nodes/node/node.js.map +1 -1
- package/dist/nodes/root/canvas2d-node.d.ts +2 -1
- package/dist/nodes/root/canvas2d-node.d.ts.map +1 -1
- package/dist/nodes/root/canvas2d-node.js +3 -0
- package/dist/nodes/root/canvas2d-node.js.map +1 -1
- package/dist/nodes/text/richtext-node.d.ts +0 -5
- package/dist/nodes/text/richtext-node.d.ts.map +1 -1
- package/dist/nodes/text/richtext-node.js +5 -71
- package/dist/nodes/text/richtext-node.js.map +1 -1
- package/dist/nodes/text/text-base.d.ts +5 -22
- package/dist/nodes/text/text-base.d.ts.map +1 -1
- package/dist/nodes/text/text-base.js +12 -363
- package/dist/nodes/text/text-base.js.map +1 -1
- package/dist/nodes/text/text-layout.d.ts +87 -0
- package/dist/nodes/text/text-layout.d.ts.map +1 -0
- package/dist/nodes/text/text-layout.js +368 -0
- package/dist/nodes/text/text-layout.js.map +1 -0
- package/dist/nodes/three/canvas3d-node.d.ts +3 -1
- package/dist/nodes/three/canvas3d-node.d.ts.map +1 -1
- package/dist/nodes/three/canvas3d-node.js +6 -0
- package/dist/nodes/three/canvas3d-node.js.map +1 -1
- package/dist/props/host.d.ts +1 -1
- package/dist/props/host.js.map +1 -1
- package/dist/props/slot.d.ts +1 -1
- package/dist/props/slot.js +1 -1
- package/dist/props/slot.js.map +1 -1
- package/dist/render/clip.d.ts +1 -1
- package/dist/render/clip.js +1 -1
- package/dist/render/clip.js.map +1 -1
- package/dist/render/descriptors/rect.js.map +1 -1
- package/dist/render/descriptors/text.d.ts +11 -5
- package/dist/render/descriptors/text.d.ts.map +1 -1
- package/dist/render/descriptors/text.js +7 -1
- package/dist/render/descriptors/text.js.map +1 -1
- package/dist/render/render-context2d.d.ts +2 -2
- package/dist/render/render-context2d.js.map +1 -1
- package/dist/render3d/builders.d.ts +1 -1
- package/dist/render3d/builders.js +1 -1
- package/dist/render3d/builders.js.map +1 -1
- package/dist/render3d/graphics3d.d.ts +13 -19
- package/dist/render3d/graphics3d.d.ts.map +1 -1
- package/dist/render3d/graphics3d.js +13 -19
- package/dist/render3d/graphics3d.js.map +1 -1
- package/dist/render3d/scene3d.d.ts +1 -1
- package/dist/render3d/scene3d.js +1 -1
- package/dist/render3d/scene3d.js.map +1 -1
- package/dist/render3d/texture.d.ts +2 -2
- package/dist/render3d/texture.d.ts.map +1 -1
- package/dist/render3d/texture.js.map +1 -1
- package/dist/render3d/vector3.d.ts +2 -2
- package/dist/render3d/vector3.js +2 -2
- package/dist/render3d/vector3.js.map +1 -1
- package/dist/runtime/asset-refine.d.ts +1 -1
- package/dist/runtime/asset-refine.d.ts.map +1 -1
- package/dist/runtime/asset-refine.js +1 -1
- package/dist/runtime/asset-refine.js.map +1 -1
- package/dist/runtime/asset-update.js +1 -1
- package/dist/runtime/asset-update.js.map +1 -1
- package/dist/runtime/audio-index.d.ts +0 -11
- package/dist/runtime/audio-index.d.ts.map +1 -1
- package/dist/runtime/audio-index.js +0 -25
- package/dist/runtime/audio-index.js.map +1 -1
- package/dist/runtime/clip-instance.d.ts +7 -4
- package/dist/runtime/clip-instance.d.ts.map +1 -1
- package/dist/runtime/clip-instance.js +21 -7
- package/dist/runtime/clip-instance.js.map +1 -1
- package/dist/runtime/clip-store.d.ts +11 -3
- package/dist/runtime/clip-store.d.ts.map +1 -1
- package/dist/runtime/clip-store.js +83 -23
- package/dist/runtime/clip-store.js.map +1 -1
- package/dist/runtime/engine.d.ts +3 -3
- package/dist/runtime/engine.js +2 -2
- package/dist/runtime/engine.js.map +1 -1
- package/dist/runtime/node-picking.d.ts +2 -2
- package/dist/runtime/node-picking.d.ts.map +1 -1
- package/dist/runtime/node-picking.js +9 -10
- package/dist/runtime/node-picking.js.map +1 -1
- package/dist/runtime/node-picking3d.d.ts +12 -5
- package/dist/runtime/node-picking3d.d.ts.map +1 -1
- package/dist/runtime/node-picking3d.js +6 -1
- package/dist/runtime/node-picking3d.js.map +1 -1
- package/dist/runtime/playback-controller.d.ts +2 -2
- package/dist/runtime/playback-controller.d.ts.map +1 -1
- package/dist/runtime/playback-controller.js +1 -1
- package/dist/runtime/playback-controller.js.map +1 -1
- package/dist/runtime/state-evaluator.d.ts +2 -2
- package/dist/runtime/state-evaluator.d.ts.map +1 -1
- package/dist/runtime/state-evaluator.js.map +1 -1
- package/dist/runtime/text-geometry.d.ts +1 -1
- package/dist/runtime/text-geometry.d.ts.map +1 -1
- package/dist/runtime/text-geometry.js +6 -3
- package/dist/runtime/text-geometry.js.map +1 -1
- package/dist/sdk/index.d.ts +46 -21
- package/dist/sdk/index.d.ts.map +1 -1
- package/dist/sdk/index.js +47 -43
- package/dist/sdk/index.js.map +1 -1
- package/dist/tween/command-decorator.d.ts +7 -9
- package/dist/tween/command-decorator.d.ts.map +1 -1
- package/dist/tween/command-decorator.js +2 -2
- package/dist/tween/command-decorator.js.map +1 -1
- package/dist/tween/command.d.ts +13 -1
- package/dist/tween/command.d.ts.map +1 -1
- package/dist/tween/command.js +14 -0
- package/dist/tween/command.js.map +1 -1
- package/dist/tween/index.d.ts +2 -1
- package/dist/tween/index.d.ts.map +1 -1
- package/dist/tween/index.js +1 -1
- package/dist/tween/index.js.map +1 -1
- package/dist/tween/loop.d.ts +1 -1
- package/dist/tween/loop.js +1 -1
- package/dist/tween/loop.js.map +1 -1
- package/dist/util/reference.d.ts +6 -6
- package/dist/util/reference.js.map +1 -1
- package/package.json +7 -10
- package/dist/browser/chunks/chunk-FUZVFT3W.js +0 -18
- package/dist/browser/chunks/chunk-FUZVFT3W.js.map +0 -7
- package/dist/browser/chunks/chunk-QG6C23IJ.js +0 -3
- package/dist/browser/chunks/chunk-QG6C23IJ.js.map +0 -7
- package/dist/browser/chunks/chunk-SFNJRPBV.js +0 -2
- package/dist/browser/chunks/chunk-SFNJRPBV.js.map +0 -7
- package/dist/browser/jsx-jsx-dev-runtime.js +0 -2
- package/dist/browser/jsx-jsx-runtime.js +0 -2
- package/dist/browser/jsx-jsx-runtime.js.map +0 -7
- /package/dist/browser/{jsx-jsx-dev-runtime.js.map → experimental.js.map} +0 -0
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
import type { NodeOf } from "../../component/api.js";
|
|
2
|
+
/** A clip from the catalog, playing into the buses it sits in. */
|
|
3
|
+
export declare const SoundNode: import("../../component/api.js").Component<"sound", import("../../component/api.js").Merge<import("../../component/api.js").BoxAudioState, {
|
|
4
|
+
readonly src: import("../../component/api.js").Type<string, string, false>;
|
|
5
|
+
readonly trimStart: 0;
|
|
6
|
+
readonly trimEnd: import("../../component/api.js").Type<number | undefined, number | undefined, false>;
|
|
7
|
+
readonly loop: false;
|
|
8
|
+
readonly speed: 1;
|
|
9
|
+
}>, {
|
|
10
|
+
readonly play: unknown;
|
|
11
|
+
}, readonly [], import("../../index.js").NodeAudio<import("../../index.js").NodeAudioProps>, import("../../component/api.js").TreeCallProps<import("../../component/api.js").Merge<import("../../component/api.js").BoxAudioState, {
|
|
12
|
+
readonly src: import("../../component/api.js").Type<string, string, false>;
|
|
13
|
+
readonly trimStart: 0;
|
|
14
|
+
readonly trimEnd: import("../../component/api.js").Type<number | undefined, number | undefined, false>;
|
|
15
|
+
readonly loop: false;
|
|
16
|
+
readonly speed: 1;
|
|
17
|
+
}>>>;
|
|
18
|
+
/** A mix of the sounds and buses in it; `solo` silences its siblings. */
|
|
19
|
+
export declare const AudioBus: import("../../component/api.js").Component<"audioBus", import("../../component/api.js").Merge<import("../../component/api.js").BoxAudioState, {
|
|
20
|
+
readonly solo: false;
|
|
21
|
+
}>, {}, null, import("../../index.js").NodeAudio<import("../../index.js").NodeAudioProps>, import("../../component/api.js").TreeCallProps<import("../../component/api.js").Merge<import("../../component/api.js").BoxAudioState, {
|
|
22
|
+
readonly solo: false;
|
|
23
|
+
}>>>;
|
|
24
|
+
export type SoundNode = NodeOf<typeof SoundNode>;
|
|
25
|
+
export type AudioBus = NodeOf<typeof AudioBus>;
|
|
26
|
+
//# sourceMappingURL=audio.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"audio.d.ts","sourceRoot":"","sources":["../../../src/component/builtins/audio.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,iBAAiB,CAAC;AAkB9C,kEAAkE;AAClE,eAAO,MAAM,SAAS;;;;;;;;;;;;;;IAepB,CAAC;AAEH,yEAAyE;AACzE,eAAO,MAAM,QAAQ;;;;IAGnB,CAAC;AAEH,MAAM,MAAM,SAAS,GAAG,MAAM,CAAC,OAAO,SAAS,CAAC,CAAC;AACjD,MAAM,MAAM,QAAQ,GAAG,MAAM,CAAC,OAAO,QAAQ,CAAC,CAAC"}
|
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
import { AudioFilters } from "../../attributes/audio/filters/chain.js";
|
|
2
|
+
import { staticValue } from "../../attributes/audio/filters/curve.js";
|
|
3
|
+
import { componentAudio } from "../../component/component-audio.js";
|
|
4
|
+
import { Types } from "../../component/types.js";
|
|
5
|
+
/**
|
|
6
|
+
* The audio built-ins. A sound plays when a command says so: its `play` runs
|
|
7
|
+
* for the command's span, or to the source's end when the command has no length.
|
|
8
|
+
* A document's `sound` row with no `play` of its own gets one over its span.
|
|
9
|
+
*/
|
|
10
|
+
/** Its own filters, then its level, then its speed: the chain a sound plays through. */
|
|
11
|
+
function chainOf(s) {
|
|
12
|
+
const chain = [...s.filters];
|
|
13
|
+
if (staticValue(s.volume, 1) !== 1 || typeof s.volume !== "number")
|
|
14
|
+
chain.push(...AudioFilters.gain(s.volume));
|
|
15
|
+
if (s.speed !== 1)
|
|
16
|
+
chain.push(...AudioFilters.speed(s.speed));
|
|
17
|
+
return chain;
|
|
18
|
+
}
|
|
19
|
+
/** A clip from the catalog, playing into the buses it sits in. */
|
|
20
|
+
export const SoundNode = componentAudio({
|
|
21
|
+
key: "sound",
|
|
22
|
+
state: {
|
|
23
|
+
src: Types.custom(undefined),
|
|
24
|
+
trimStart: 0,
|
|
25
|
+
trimEnd: Types.custom(undefined),
|
|
26
|
+
loop: false,
|
|
27
|
+
speed: 1,
|
|
28
|
+
},
|
|
29
|
+
allowedChildren: [],
|
|
30
|
+
commands: {
|
|
31
|
+
play: (timeline, state) => timeline.sound(state.src, {
|
|
32
|
+
trimStart: state.trimStart, trimEnd: state.trimEnd, loop: state.loop, filters: chainOf(state),
|
|
33
|
+
}),
|
|
34
|
+
},
|
|
35
|
+
});
|
|
36
|
+
/** A mix of the sounds and buses in it; `solo` silences its siblings. */
|
|
37
|
+
export const AudioBus = componentAudio({
|
|
38
|
+
key: "audioBus",
|
|
39
|
+
state: { solo: false },
|
|
40
|
+
});
|
|
41
|
+
//# sourceMappingURL=audio.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"audio.js","sourceRoot":"","sources":["../../../src/component/builtins/audio.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,YAAY,EAAE,MAAM,kCAAkC,CAAC;AAChE,OAAO,EAAE,WAAW,EAAc,MAAM,kCAAkC,CAAC;AAG3E,OAAO,EAAE,cAAc,EAAE,MAAM,6BAA6B,CAAC;AAC7D,OAAO,EAAE,KAAK,EAAE,MAAM,mBAAmB,CAAC;AAE1C;;;;GAIG;AAEH,wFAAwF;AACxF,SAAS,OAAO,CAAC,CAA0F;IACvG,MAAM,KAAK,GAAsB,CAAC,GAAG,CAAC,CAAC,OAAO,CAAC,CAAC;IAChD,IAAI,WAAW,CAAC,CAAC,CAAC,MAAM,EAAE,CAAC,CAAC,KAAK,CAAC,IAAI,OAAO,CAAC,CAAC,MAAM,KAAK,QAAQ;QAAE,KAAK,CAAC,IAAI,CAAC,GAAG,YAAY,CAAC,IAAI,CAAC,CAAC,CAAC,MAAM,CAAC,CAAC,CAAC;IAC/G,IAAI,CAAC,CAAC,KAAK,KAAK,CAAC;QAAE,KAAK,CAAC,IAAI,CAAC,GAAG,YAAY,CAAC,KAAK,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC;IAC9D,OAAO,KAAK,CAAC;AACjB,CAAC;AAED,kEAAkE;AAClE,MAAM,CAAC,MAAM,SAAS,GAAG,cAAc,CAAC;IACpC,GAAG,EAAE,OAAO;IACZ,KAAK,EAAE;QACH,GAAG,EAAE,KAAK,CAAC,MAAM,CAAS,SAA8B,CAAC;QACzD,SAAS,EAAE,CAAC;QACZ,OAAO,EAAE,KAAK,CAAC,MAAM,CAAqB,SAAS,CAAC;QACpD,IAAI,EAAE,KAAK;QACX,KAAK,EAAE,CAAC;KACX;IACD,eAAe,EAAE,EAAE;IACnB,QAAQ,EAAE;QACN,IAAI,EAAE,CAAC,QAAQ,EAAE,KAAK,EAAE,EAAE,CAAC,QAAQ,CAAC,KAAK,CAAC,KAAK,CAAC,GAAG,EAAE;YACjD,SAAS,EAAE,KAAK,CAAC,SAAS,EAAE,OAAO,EAAE,KAAK,CAAC,OAAO,EAAE,IAAI,EAAE,KAAK,CAAC,IAAI,EAAE,OAAO,EAAE,OAAO,CAAC,KAAK,CAAC;SAChG,CAAC;KACL;CACJ,CAAC,CAAC;AAEH,yEAAyE;AACzE,MAAM,CAAC,MAAM,QAAQ,GAAG,cAAc,CAAC;IACnC,GAAG,EAAE,UAAU;IACf,KAAK,EAAE,EAAE,IAAI,EAAE,KAAK,EAAE;CACzB,CAAC,CAAC","sourcesContent":["import { AudioFilters } from \"@/attributes/audio/filters/chain\";\r\nimport { staticValue, type Param } from \"@/attributes/audio/filters/curve\";\r\nimport type { AudioFilterItem } from \"@/attributes/audio/filters/union\";\r\nimport type { NodeOf } from \"@/component/api\";\r\nimport { componentAudio } from \"@/component/component-audio\";\r\nimport { Types } from \"@/component/types\";\r\n\r\n/**\r\n * The audio built-ins. A sound plays when a command says so: its `play` runs\r\n * for the command's span, or to the source's end when the command has no length.\r\n * A document's `sound` row with no `play` of its own gets one over its span.\r\n */\r\n\r\n/** Its own filters, then its level, then its speed: the chain a sound plays through. */\r\nfunction chainOf(s: { readonly filters: AudioFilterItem[]; readonly volume: Param; readonly speed: number }): AudioFilterItem[] {\r\n const chain: AudioFilterItem[] = [...s.filters];\r\n if (staticValue(s.volume, 1) !== 1 || typeof s.volume !== \"number\") chain.push(...AudioFilters.gain(s.volume));\r\n if (s.speed !== 1) chain.push(...AudioFilters.speed(s.speed));\r\n return chain;\r\n}\r\n\r\n/** A clip from the catalog, playing into the buses it sits in. */\r\nexport const SoundNode = componentAudio({\r\n key: \"sound\",\r\n state: {\r\n src: Types.custom<string>(undefined as unknown as string),\r\n trimStart: 0,\r\n trimEnd: Types.custom<number | undefined>(undefined),\r\n loop: false,\r\n speed: 1,\r\n },\r\n allowedChildren: [],\r\n commands: {\r\n play: (timeline, state) => timeline.sound(state.src, {\r\n trimStart: state.trimStart, trimEnd: state.trimEnd, loop: state.loop, filters: chainOf(state),\r\n }),\r\n },\r\n});\r\n\r\n/** A mix of the sounds and buses in it; `solo` silences its siblings. */\r\nexport const AudioBus = componentAudio({\r\n key: \"audioBus\",\r\n state: { solo: false },\r\n});\r\n\r\nexport type SoundNode = NodeOf<typeof SoundNode>;\r\nexport type AudioBus = NodeOf<typeof AudioBus>;\r\n"]}
|
|
@@ -0,0 +1,98 @@
|
|
|
1
|
+
import type { NodeOf } from "../../component/api.js";
|
|
2
|
+
/**
|
|
3
|
+
* The 3D viewport: a rect whose top fill layer is its 3D children's scene, seen
|
|
4
|
+
* by their camera (or the default one), with its 2D children drawn over it.
|
|
5
|
+
*/
|
|
6
|
+
export declare const Canvas3D: import("../../component/api.js").Component<"canvas3d", import("../../component/api.js").Merge<import("../../component/api.js").Box2DState, {
|
|
7
|
+
readonly orbit: import("../../component/api.js").Type<number, number, false>;
|
|
8
|
+
readonly elevation: import("../../component/api.js").Type<number, number, false>;
|
|
9
|
+
readonly zoom: import("../../component/api.js").Type<number, number, false>;
|
|
10
|
+
readonly fov: import("../../component/api.js").Type<number, number, false>;
|
|
11
|
+
readonly ambientIntensity: import("../../component/api.js").Type<number, number, false>;
|
|
12
|
+
readonly ambientColor: import("../../component/api.js").Type<import("../../index.js").Color, import("../../index.js").NormalizedColor, false>;
|
|
13
|
+
readonly keyIntensity: import("../../component/api.js").Type<number, number, false>;
|
|
14
|
+
readonly keyColor: import("../../component/api.js").Type<import("../../index.js").Color, import("../../index.js").NormalizedColor, false>;
|
|
15
|
+
readonly showGrid: import("../../component/api.js").Type<boolean, boolean, false>;
|
|
16
|
+
readonly gridSize: import("../../component/api.js").Type<number, number, false>;
|
|
17
|
+
readonly gridDivisions: import("../../component/api.js").Type<number, number, false>;
|
|
18
|
+
readonly gridMajorEvery: import("../../component/api.js").Type<number, number, false>;
|
|
19
|
+
readonly gridColor: import("../../component/api.js").Type<import("../../index.js").Color, import("../../index.js").NormalizedColor, false>;
|
|
20
|
+
readonly gridMajorColor: import("../../component/api.js").Type<import("../../index.js").Color, import("../../index.js").NormalizedColor, false>;
|
|
21
|
+
readonly showAxes: import("../../component/api.js").Type<boolean, boolean, false>;
|
|
22
|
+
readonly axisXColor: import("../../component/api.js").Type<import("../../index.js").Color, import("../../index.js").NormalizedColor, false>;
|
|
23
|
+
readonly axisZColor: import("../../component/api.js").Type<import("../../index.js").Color, import("../../index.js").NormalizedColor, false>;
|
|
24
|
+
readonly gridFade: import("../../component/api.js").Type<number, number, false>;
|
|
25
|
+
readonly gridFadeColor: import("../../component/api.js").Type<import("../../index.js").Color, import("../../index.js").NormalizedColor, false>;
|
|
26
|
+
readonly maxPixelRatio: import("../../component/api.js").Type<number, number, false>;
|
|
27
|
+
readonly antialias: import("../../component/api.js").Type<boolean, boolean, false>;
|
|
28
|
+
readonly shadows: import("../../component/api.js").Type<import("../../index.js").Shadows3D, import("../../index.js").Shadows3D, false>;
|
|
29
|
+
readonly tone: import("../../component/api.js").Type<import("../../index.js").ToneMapping3D | undefined, import("../../index.js").ToneMapping3D | undefined, false>;
|
|
30
|
+
readonly exposure: import("../../component/api.js").Type<number | undefined, number | undefined, false>;
|
|
31
|
+
readonly post: import("../../component/api.js").Type<import("../../index.js").PostEffect3D | readonly import("../../index.js").PostEffect3D[] | undefined, import("../../index.js").PostEffect3D | readonly import("../../index.js").PostEffect3D[] | undefined, false>;
|
|
32
|
+
readonly cornerRadius: import("../types.js").Attribute<import("../../index.js").RectCornerRadius, import("../../index.js").CornerRadiusResolved>;
|
|
33
|
+
readonly cornerStyle: import("../types.js").Attribute<import("../../index.js").RectCornerStyle, import("../../index.js").CornerStyleResolved>;
|
|
34
|
+
readonly flow: import("../../component/api.js").Type<import("../../index.js").FlowMode, import("../../index.js").FlowResolved, false>;
|
|
35
|
+
readonly gap: import("../../component/api.js").Type<import("../../index.js").GapSize, import("../../index.js").GapSize, false>;
|
|
36
|
+
readonly wrap: boolean;
|
|
37
|
+
readonly crossGap: import("../../component/api.js").Type<number | undefined, number | undefined, false>;
|
|
38
|
+
readonly columns: import("../../component/api.js").Type<number, number, false>;
|
|
39
|
+
readonly align: import("../types.js").Attribute<import("../../index.js").Alignment, import("../../index.js").Vector2>;
|
|
40
|
+
readonly fill: import("../types.js").Attribute<import("../../index.js").Fill, import("../../index.js").FillResolved[]>;
|
|
41
|
+
readonly stroke: import("../types.js").Attribute<import("../../index.js").Stroke, import("../../index.js").StrokeResolved[]>;
|
|
42
|
+
readonly shadow: import("../types.js").Attribute<import("../../index.js").Shadow, import("../../index.js").ShadowResolved[]>;
|
|
43
|
+
readonly overlay: import("../types.js").Attribute<import("../../index.js").Fill, import("../../index.js").FillResolved[]>;
|
|
44
|
+
readonly start: import("../../component/api.js").Type<number, number, false>;
|
|
45
|
+
readonly end: import("../../component/api.js").Type<number, number, false>;
|
|
46
|
+
}>, {
|
|
47
|
+
readonly orbitTo: readonly ["orbit", "elevation", "zoom"];
|
|
48
|
+
readonly fillTo: readonly ["fill"];
|
|
49
|
+
readonly strokeTo: readonly ["stroke"];
|
|
50
|
+
readonly shadowTo: readonly ["shadow"];
|
|
51
|
+
readonly overlayTo: readonly ["overlay"];
|
|
52
|
+
readonly progressTo: readonly ["start", "end"];
|
|
53
|
+
readonly flash: {
|
|
54
|
+
readonly portion: import("../../component/api.js").Type<number, number, false>;
|
|
55
|
+
};
|
|
56
|
+
}, readonly ["2d", "3d"], import("../../index.js").Node2D<import("../../index.js").Node2DProps>, import("../../component/api.js").CallProps<import("../../component/api.js").Merge<import("../../component/api.js").Box2DState, {
|
|
57
|
+
readonly orbit: import("../../component/api.js").Type<number, number, false>;
|
|
58
|
+
readonly elevation: import("../../component/api.js").Type<number, number, false>;
|
|
59
|
+
readonly zoom: import("../../component/api.js").Type<number, number, false>;
|
|
60
|
+
readonly fov: import("../../component/api.js").Type<number, number, false>;
|
|
61
|
+
readonly ambientIntensity: import("../../component/api.js").Type<number, number, false>;
|
|
62
|
+
readonly ambientColor: import("../../component/api.js").Type<import("../../index.js").Color, import("../../index.js").NormalizedColor, false>;
|
|
63
|
+
readonly keyIntensity: import("../../component/api.js").Type<number, number, false>;
|
|
64
|
+
readonly keyColor: import("../../component/api.js").Type<import("../../index.js").Color, import("../../index.js").NormalizedColor, false>;
|
|
65
|
+
readonly showGrid: import("../../component/api.js").Type<boolean, boolean, false>;
|
|
66
|
+
readonly gridSize: import("../../component/api.js").Type<number, number, false>;
|
|
67
|
+
readonly gridDivisions: import("../../component/api.js").Type<number, number, false>;
|
|
68
|
+
readonly gridMajorEvery: import("../../component/api.js").Type<number, number, false>;
|
|
69
|
+
readonly gridColor: import("../../component/api.js").Type<import("../../index.js").Color, import("../../index.js").NormalizedColor, false>;
|
|
70
|
+
readonly gridMajorColor: import("../../component/api.js").Type<import("../../index.js").Color, import("../../index.js").NormalizedColor, false>;
|
|
71
|
+
readonly showAxes: import("../../component/api.js").Type<boolean, boolean, false>;
|
|
72
|
+
readonly axisXColor: import("../../component/api.js").Type<import("../../index.js").Color, import("../../index.js").NormalizedColor, false>;
|
|
73
|
+
readonly axisZColor: import("../../component/api.js").Type<import("../../index.js").Color, import("../../index.js").NormalizedColor, false>;
|
|
74
|
+
readonly gridFade: import("../../component/api.js").Type<number, number, false>;
|
|
75
|
+
readonly gridFadeColor: import("../../component/api.js").Type<import("../../index.js").Color, import("../../index.js").NormalizedColor, false>;
|
|
76
|
+
readonly maxPixelRatio: import("../../component/api.js").Type<number, number, false>;
|
|
77
|
+
readonly antialias: import("../../component/api.js").Type<boolean, boolean, false>;
|
|
78
|
+
readonly shadows: import("../../component/api.js").Type<import("../../index.js").Shadows3D, import("../../index.js").Shadows3D, false>;
|
|
79
|
+
readonly tone: import("../../component/api.js").Type<import("../../index.js").ToneMapping3D | undefined, import("../../index.js").ToneMapping3D | undefined, false>;
|
|
80
|
+
readonly exposure: import("../../component/api.js").Type<number | undefined, number | undefined, false>;
|
|
81
|
+
readonly post: import("../../component/api.js").Type<import("../../index.js").PostEffect3D | readonly import("../../index.js").PostEffect3D[] | undefined, import("../../index.js").PostEffect3D | readonly import("../../index.js").PostEffect3D[] | undefined, false>;
|
|
82
|
+
readonly cornerRadius: import("../types.js").Attribute<import("../../index.js").RectCornerRadius, import("../../index.js").CornerRadiusResolved>;
|
|
83
|
+
readonly cornerStyle: import("../types.js").Attribute<import("../../index.js").RectCornerStyle, import("../../index.js").CornerStyleResolved>;
|
|
84
|
+
readonly flow: import("../../component/api.js").Type<import("../../index.js").FlowMode, import("../../index.js").FlowResolved, false>;
|
|
85
|
+
readonly gap: import("../../component/api.js").Type<import("../../index.js").GapSize, import("../../index.js").GapSize, false>;
|
|
86
|
+
readonly wrap: boolean;
|
|
87
|
+
readonly crossGap: import("../../component/api.js").Type<number | undefined, number | undefined, false>;
|
|
88
|
+
readonly columns: import("../../component/api.js").Type<number, number, false>;
|
|
89
|
+
readonly align: import("../types.js").Attribute<import("../../index.js").Alignment, import("../../index.js").Vector2>;
|
|
90
|
+
readonly fill: import("../types.js").Attribute<import("../../index.js").Fill, import("../../index.js").FillResolved[]>;
|
|
91
|
+
readonly stroke: import("../types.js").Attribute<import("../../index.js").Stroke, import("../../index.js").StrokeResolved[]>;
|
|
92
|
+
readonly shadow: import("../types.js").Attribute<import("../../index.js").Shadow, import("../../index.js").ShadowResolved[]>;
|
|
93
|
+
readonly overlay: import("../types.js").Attribute<import("../../index.js").Fill, import("../../index.js").FillResolved[]>;
|
|
94
|
+
readonly start: import("../../component/api.js").Type<number, number, false>;
|
|
95
|
+
readonly end: import("../../component/api.js").Type<number, number, false>;
|
|
96
|
+
}>, readonly ["2d", "3d"]>>;
|
|
97
|
+
export type Canvas3D = NodeOf<typeof Canvas3D>;
|
|
98
|
+
//# sourceMappingURL=canvas3d.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"canvas3d.d.ts","sourceRoot":"","sources":["../../../src/component/builtins/canvas3d.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,iBAAiB,CAAC;AAO9C;;;GAGG;AACH,eAAO,MAAM,QAAQ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;2BAUnB,CAAC;AAEH,MAAM,MAAM,QAAQ,GAAG,MAAM,CAAC,OAAO,QAAQ,CAAC,CAAC"}
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import { component2d } from "../../component/component2d.js";
|
|
2
|
+
import * as Corners from "../../component/modules/corners.js";
|
|
3
|
+
import * as Flow from "../../component/modules/flow.js";
|
|
4
|
+
import * as Paint from "../../component/modules/paint.js";
|
|
5
|
+
import * as View3D from "../../component/modules/view3d.js";
|
|
6
|
+
/**
|
|
7
|
+
* The 3D viewport: a rect whose top fill layer is its 3D children's scene, seen
|
|
8
|
+
* by their camera (or the default one), with its 2D children drawn over it.
|
|
9
|
+
*/
|
|
10
|
+
export const Canvas3D = component2d({
|
|
11
|
+
key: "canvas3d",
|
|
12
|
+
state: { ...Paint.state, ...Flow.state, ...Corners.state, ...View3D.state },
|
|
13
|
+
defaults: { width: "fill", height: "fill" },
|
|
14
|
+
commands: { ...Paint.commands, ...View3D.commands },
|
|
15
|
+
allowedChildren: ["2d", "3d"],
|
|
16
|
+
load: (loader) => View3D.load(loader),
|
|
17
|
+
measure: (measurer, state, children) => Flow.measure(measurer, state, children, Paint.inset(state)),
|
|
18
|
+
layout: (box, state, children) => Flow.layout(box, state, children, Paint.inset(state)),
|
|
19
|
+
render: (ctx, state) => View3D.draw(ctx, state),
|
|
20
|
+
});
|
|
21
|
+
//# sourceMappingURL=canvas3d.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"canvas3d.js","sourceRoot":"","sources":["../../../src/component/builtins/canvas3d.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,WAAW,EAAE,MAAM,yBAAyB,CAAC;AACtD,OAAO,KAAK,OAAO,MAAM,6BAA6B,CAAC;AACvD,OAAO,KAAK,IAAI,MAAM,0BAA0B,CAAC;AACjD,OAAO,KAAK,KAAK,MAAM,2BAA2B,CAAC;AACnD,OAAO,KAAK,MAAM,MAAM,4BAA4B,CAAC;AAErD;;;GAGG;AACH,MAAM,CAAC,MAAM,QAAQ,GAAG,WAAW,CAAC;IAChC,GAAG,EAAE,UAAU;IACf,KAAK,EAAE,EAAE,GAAG,KAAK,CAAC,KAAK,EAAE,GAAG,IAAI,CAAC,KAAK,EAAE,GAAG,OAAO,CAAC,KAAK,EAAE,GAAG,MAAM,CAAC,KAAK,EAAE;IAC3E,QAAQ,EAAE,EAAE,KAAK,EAAE,MAAM,EAAE,MAAM,EAAE,MAAM,EAAE;IAC3C,QAAQ,EAAE,EAAE,GAAG,KAAK,CAAC,QAAQ,EAAE,GAAG,MAAM,CAAC,QAAQ,EAAE;IACnD,eAAe,EAAE,CAAC,IAAI,EAAE,IAAI,CAAC;IAC7B,IAAI,EAAE,CAAC,MAAM,EAAE,EAAE,CAAC,MAAM,CAAC,IAAI,CAAC,MAAM,CAAC;IACrC,OAAO,EAAE,CAAC,QAAQ,EAAE,KAAK,EAAE,QAAQ,EAAE,EAAE,CAAC,IAAI,CAAC,OAAO,CAAC,QAAQ,EAAE,KAAK,EAAE,QAAQ,EAAE,KAAK,CAAC,KAAK,CAAC,KAAK,CAAC,CAAC;IACnG,MAAM,EAAE,CAAC,GAAG,EAAE,KAAK,EAAE,QAAQ,EAAE,EAAE,CAAC,IAAI,CAAC,MAAM,CAAC,GAAG,EAAE,KAAK,EAAE,QAAQ,EAAE,KAAK,CAAC,KAAK,CAAC,KAAK,CAAC,CAAC;IACvF,MAAM,EAAE,CAAC,GAAG,EAAE,KAAK,EAAE,EAAE,CAAC,MAAM,CAAC,IAAI,CAAC,GAAG,EAAE,KAAK,CAAC;CAClD,CAAC,CAAC","sourcesContent":["import type { NodeOf } from \"@/component/api\";\r\nimport { component2d } from \"@/component/component2d\";\r\nimport * as Corners from \"@/component/modules/corners\";\r\nimport * as Flow from \"@/component/modules/flow\";\r\nimport * as Paint from \"@/component/modules/paint\";\r\nimport * as View3D from \"@/component/modules/view3d\";\r\n\r\n/**\r\n * The 3D viewport: a rect whose top fill layer is its 3D children's scene, seen\r\n * by their camera (or the default one), with its 2D children drawn over it.\r\n */\r\nexport const Canvas3D = component2d({\r\n key: \"canvas3d\",\r\n state: { ...Paint.state, ...Flow.state, ...Corners.state, ...View3D.state },\r\n defaults: { width: \"fill\", height: \"fill\" },\r\n commands: { ...Paint.commands, ...View3D.commands },\r\n allowedChildren: [\"2d\", \"3d\"],\r\n load: (loader) => View3D.load(loader),\r\n measure: (measurer, state, children) => Flow.measure(measurer, state, children, Paint.inset(state)),\r\n layout: (box, state, children) => Flow.layout(box, state, children, Paint.inset(state)),\r\n render: (ctx, state) => View3D.draw(ctx, state),\r\n});\r\n\r\nexport type Canvas3D = NodeOf<typeof Canvas3D>;\r\n"]}
|
|
@@ -0,0 +1,56 @@
|
|
|
1
|
+
import type { NodeOf } from "../../component/api.js";
|
|
2
|
+
/**
|
|
3
|
+
* The compositing built-ins: children drawn as one. `op`, `mode` and
|
|
4
|
+
* `inverted` are entries, where the classes kept them in unlisted slots, so a
|
|
5
|
+
* host lists them and a command can switch them.
|
|
6
|
+
*/
|
|
7
|
+
/** Its children become one shape by `op`, painted with its own fill, stroke and shadow. */
|
|
8
|
+
export declare const BooleanGroup: import("../../component/api.js").Component<"boolean", import("../../component/api.js").Merge<import("../../component/api.js").Box2DState, {
|
|
9
|
+
readonly op: import("../../component/api.js").Type<"union" | "subtract" | "intersect" | "exclude", "union" | "subtract" | "intersect" | "exclude", false>;
|
|
10
|
+
readonly flow: import("../../component/api.js").Type<import("../../index.js").FlowMode, import("../../index.js").FlowResolved, false>;
|
|
11
|
+
readonly gap: import("../../component/api.js").Type<import("../../index.js").GapSize, import("../../index.js").GapSize, false>;
|
|
12
|
+
readonly wrap: boolean;
|
|
13
|
+
readonly crossGap: import("../../component/api.js").Type<number | undefined, number | undefined, false>;
|
|
14
|
+
readonly columns: import("../../component/api.js").Type<number, number, false>;
|
|
15
|
+
readonly align: import("../../component/types.js").Attribute<import("../../index.js").Alignment, import("../../index.js").Vector2>;
|
|
16
|
+
readonly fill: import("../../component/types.js").Attribute<import("../../index.js").Fill, import("../../index.js").FillResolved[]>;
|
|
17
|
+
readonly stroke: import("../../component/types.js").Attribute<import("../../index.js").Stroke, import("../../index.js").StrokeResolved[]>;
|
|
18
|
+
readonly shadow: import("../../component/types.js").Attribute<import("../../index.js").Shadow, import("../../index.js").ShadowResolved[]>;
|
|
19
|
+
readonly overlay: import("../../component/types.js").Attribute<import("../../index.js").Fill, import("../../index.js").FillResolved[]>;
|
|
20
|
+
readonly start: import("../../component/api.js").Type<number, number, false>;
|
|
21
|
+
readonly end: import("../../component/api.js").Type<number, number, false>;
|
|
22
|
+
}>, {
|
|
23
|
+
readonly fillTo: readonly ["fill"];
|
|
24
|
+
readonly strokeTo: readonly ["stroke"];
|
|
25
|
+
readonly shadowTo: readonly ["shadow"];
|
|
26
|
+
readonly overlayTo: readonly ["overlay"];
|
|
27
|
+
readonly progressTo: readonly ["start", "end"];
|
|
28
|
+
readonly flash: {
|
|
29
|
+
readonly portion: import("../../component/api.js").Type<number, number, false>;
|
|
30
|
+
};
|
|
31
|
+
}, null, import("../../index.js").Node2D<import("../../index.js").Node2DProps>, import("../../component/api.js").CallProps<import("../../component/api.js").Merge<import("../../component/api.js").Box2DState, {
|
|
32
|
+
readonly op: import("../../component/api.js").Type<"union" | "subtract" | "intersect" | "exclude", "union" | "subtract" | "intersect" | "exclude", false>;
|
|
33
|
+
readonly flow: import("../../component/api.js").Type<import("../../index.js").FlowMode, import("../../index.js").FlowResolved, false>;
|
|
34
|
+
readonly gap: import("../../component/api.js").Type<import("../../index.js").GapSize, import("../../index.js").GapSize, false>;
|
|
35
|
+
readonly wrap: boolean;
|
|
36
|
+
readonly crossGap: import("../../component/api.js").Type<number | undefined, number | undefined, false>;
|
|
37
|
+
readonly columns: import("../../component/api.js").Type<number, number, false>;
|
|
38
|
+
readonly align: import("../../component/types.js").Attribute<import("../../index.js").Alignment, import("../../index.js").Vector2>;
|
|
39
|
+
readonly fill: import("../../component/types.js").Attribute<import("../../index.js").Fill, import("../../index.js").FillResolved[]>;
|
|
40
|
+
readonly stroke: import("../../component/types.js").Attribute<import("../../index.js").Stroke, import("../../index.js").StrokeResolved[]>;
|
|
41
|
+
readonly shadow: import("../../component/types.js").Attribute<import("../../index.js").Shadow, import("../../index.js").ShadowResolved[]>;
|
|
42
|
+
readonly overlay: import("../../component/types.js").Attribute<import("../../index.js").Fill, import("../../index.js").FillResolved[]>;
|
|
43
|
+
readonly start: import("../../component/api.js").Type<number, number, false>;
|
|
44
|
+
readonly end: import("../../component/api.js").Type<number, number, false>;
|
|
45
|
+
}>, null>>;
|
|
46
|
+
/** Its first child is the stencil the rest draw through. */
|
|
47
|
+
export declare const MaskGroup: import("../../component/api.js").Component<"mask", import("../../component/api.js").Merge<import("../../component/api.js").Box2DState, {
|
|
48
|
+
readonly mode: import("../../component/api.js").Type<"alpha" | "vector" | "luminance", "alpha" | "vector" | "luminance", false>;
|
|
49
|
+
readonly inverted: false;
|
|
50
|
+
}>, {}, null, import("../../index.js").Node2D<import("../../index.js").Node2DProps>, import("../../component/api.js").CallProps<import("../../component/api.js").Merge<import("../../component/api.js").Box2DState, {
|
|
51
|
+
readonly mode: import("../../component/api.js").Type<"alpha" | "vector" | "luminance", "alpha" | "vector" | "luminance", false>;
|
|
52
|
+
readonly inverted: false;
|
|
53
|
+
}>, null>>;
|
|
54
|
+
export type BooleanGroup = NodeOf<typeof BooleanGroup>;
|
|
55
|
+
export type MaskGroup = NodeOf<typeof MaskGroup>;
|
|
56
|
+
//# sourceMappingURL=composite.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"composite.d.ts","sourceRoot":"","sources":["../../../src/component/builtins/composite.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,iBAAiB,CAAC;AAM9C;;;;GAIG;AAEH,2FAA2F;AAC3F,eAAO,MAAM,YAAY;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;UAOvB,CAAC;AAEH,4DAA4D;AAC5D,eAAO,MAAM,SAAS;;;;;;UAIpB,CAAC;AAEH,MAAM,MAAM,YAAY,GAAG,MAAM,CAAC,OAAO,YAAY,CAAC,CAAC;AACvD,MAAM,MAAM,SAAS,GAAG,MAAM,CAAC,OAAO,SAAS,CAAC,CAAC"}
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
import { component2d } from "../../component/component2d.js";
|
|
2
|
+
import { Types } from "../../component/types.js";
|
|
3
|
+
import * as Flow from "../../component/modules/flow.js";
|
|
4
|
+
import * as Paint from "../../component/modules/paint.js";
|
|
5
|
+
/**
|
|
6
|
+
* The compositing built-ins: children drawn as one. `op`, `mode` and
|
|
7
|
+
* `inverted` are entries, where the classes kept them in unlisted slots, so a
|
|
8
|
+
* host lists them and a command can switch them.
|
|
9
|
+
*/
|
|
10
|
+
/** Its children become one shape by `op`, painted with its own fill, stroke and shadow. */
|
|
11
|
+
export const BooleanGroup = component2d({
|
|
12
|
+
key: "boolean",
|
|
13
|
+
state: { ...Paint.state, ...Flow.state, op: Types.oneOf(["union", "subtract", "intersect", "exclude"]) },
|
|
14
|
+
commands: { ...Paint.commands },
|
|
15
|
+
measure: (measurer, state, children) => Flow.measure(measurer, state, children, Paint.inset(state)),
|
|
16
|
+
layout: (box, state, children) => Flow.layout(box, state, children, Paint.inset(state)),
|
|
17
|
+
render: (ctx, state) => ctx.merge(state.op, state),
|
|
18
|
+
});
|
|
19
|
+
/** Its first child is the stencil the rest draw through. */
|
|
20
|
+
export const MaskGroup = component2d({
|
|
21
|
+
key: "mask",
|
|
22
|
+
state: { mode: Types.oneOf(["alpha", "vector", "luminance"]), inverted: false },
|
|
23
|
+
render: (ctx, state) => ctx.mask(state),
|
|
24
|
+
});
|
|
25
|
+
//# sourceMappingURL=composite.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"composite.js","sourceRoot":"","sources":["../../../src/component/builtins/composite.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,WAAW,EAAE,MAAM,yBAAyB,CAAC;AACtD,OAAO,EAAE,KAAK,EAAE,MAAM,mBAAmB,CAAC;AAC1C,OAAO,KAAK,IAAI,MAAM,0BAA0B,CAAC;AACjD,OAAO,KAAK,KAAK,MAAM,2BAA2B,CAAC;AAEnD;;;;GAIG;AAEH,2FAA2F;AAC3F,MAAM,CAAC,MAAM,YAAY,GAAG,WAAW,CAAC;IACpC,GAAG,EAAE,SAAS;IACd,KAAK,EAAE,EAAE,GAAG,KAAK,CAAC,KAAK,EAAE,GAAG,IAAI,CAAC,KAAK,EAAE,EAAE,EAAE,KAAK,CAAC,KAAK,CAAC,CAAC,OAAO,EAAE,UAAU,EAAE,WAAW,EAAE,SAAS,CAAC,CAAC,EAAE;IACxG,QAAQ,EAAE,EAAE,GAAG,KAAK,CAAC,QAAQ,EAAE;IAC/B,OAAO,EAAE,CAAC,QAAQ,EAAE,KAAK,EAAE,QAAQ,EAAE,EAAE,CAAC,IAAI,CAAC,OAAO,CAAC,QAAQ,EAAE,KAAK,EAAE,QAAQ,EAAE,KAAK,CAAC,KAAK,CAAC,KAAK,CAAC,CAAC;IACnG,MAAM,EAAE,CAAC,GAAG,EAAE,KAAK,EAAE,QAAQ,EAAE,EAAE,CAAC,IAAI,CAAC,MAAM,CAAC,GAAG,EAAE,KAAK,EAAE,QAAQ,EAAE,KAAK,CAAC,KAAK,CAAC,KAAK,CAAC,CAAC;IACvF,MAAM,EAAE,CAAC,GAAG,EAAE,KAAK,EAAE,EAAE,CAAC,GAAG,CAAC,KAAK,CAAC,KAAK,CAAC,EAAE,EAAE,KAAK,CAAC;CACrD,CAAC,CAAC;AAEH,4DAA4D;AAC5D,MAAM,CAAC,MAAM,SAAS,GAAG,WAAW,CAAC;IACjC,GAAG,EAAE,MAAM;IACX,KAAK,EAAE,EAAE,IAAI,EAAE,KAAK,CAAC,KAAK,CAAC,CAAC,OAAO,EAAE,QAAQ,EAAE,WAAW,CAAC,CAAC,EAAE,QAAQ,EAAE,KAAK,EAAE;IAC/E,MAAM,EAAE,CAAC,GAAG,EAAE,KAAK,EAAE,EAAE,CAAC,GAAG,CAAC,IAAI,CAAC,KAAK,CAAC;CAC1C,CAAC,CAAC","sourcesContent":["import type { NodeOf } from \"@/component/api\";\r\nimport { component2d } from \"@/component/component2d\";\r\nimport { Types } from \"@/component/types\";\r\nimport * as Flow from \"@/component/modules/flow\";\r\nimport * as Paint from \"@/component/modules/paint\";\r\n\r\n/**\r\n * The compositing built-ins: children drawn as one. `op`, `mode` and\r\n * `inverted` are entries, where the classes kept them in unlisted slots, so a\r\n * host lists them and a command can switch them.\r\n */\r\n\r\n/** Its children become one shape by `op`, painted with its own fill, stroke and shadow. */\r\nexport const BooleanGroup = component2d({\r\n key: \"boolean\",\r\n state: { ...Paint.state, ...Flow.state, op: Types.oneOf([\"union\", \"subtract\", \"intersect\", \"exclude\"]) },\r\n commands: { ...Paint.commands },\r\n measure: (measurer, state, children) => Flow.measure(measurer, state, children, Paint.inset(state)),\r\n layout: (box, state, children) => Flow.layout(box, state, children, Paint.inset(state)),\r\n render: (ctx, state) => ctx.merge(state.op, state),\r\n});\r\n\r\n/** Its first child is the stencil the rest draw through. */\r\nexport const MaskGroup = component2d({\r\n key: \"mask\",\r\n state: { mode: Types.oneOf([\"alpha\", \"vector\", \"luminance\"]), inverted: false },\r\n render: (ctx, state) => ctx.mask(state),\r\n});\r\n\r\nexport type BooleanGroup = NodeOf<typeof BooleanGroup>;\r\nexport type MaskGroup = NodeOf<typeof MaskGroup>;\r\n"]}
|