laymur 0.17.0 → 0.17.2
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 +5 -0
- package/{src/core/constraints/UIAspectConstraint/UIAspectConstraint.Internal.ts → dist/core/constraints/UIAspectConstraint/UIAspectConstraint.Internal.d.ts} +2 -3
- package/dist/core/constraints/UIAspectConstraint/UIAspectConstraint.d.ts +22 -0
- package/dist/core/constraints/UIAspectConstraint/UIAspectConstraint.js +41 -0
- package/dist/core/constraints/UIConstraint.d.ts +12 -0
- package/dist/core/constraints/UIConstraint.js +11 -0
- package/dist/core/constraints/UICustomConstraint.d.ts +28 -0
- package/dist/core/constraints/UICustomConstraint.js +37 -0
- package/{src/core/constraints/UIHeightConstraint/UIHeightConstraint.Internal.ts → dist/core/constraints/UIHeightConstraint/UIHeightConstraint.Internal.d.ts} +2 -3
- package/dist/core/constraints/UIHeightConstraint/UIHeightConstraint.d.ts +20 -0
- package/dist/core/constraints/UIHeightConstraint/UIHeightConstraint.js +34 -0
- package/dist/core/constraints/UIHorizontalDistanceConstraint/UIHorizontalDistanceConstraint.Internal.d.ts +11 -0
- package/dist/core/constraints/UIHorizontalDistanceConstraint/UIHorizontalDistanceConstraint.Internal.js +3 -0
- package/dist/core/constraints/UIHorizontalDistanceConstraint/UIHorizontalDistanceConstraint.d.ts +36 -0
- package/dist/core/constraints/UIHorizontalDistanceConstraint/UIHorizontalDistanceConstraint.js +100 -0
- package/dist/core/constraints/UIHorizontalInterpolationConstraint/UIHorizontalInterpolationConstraint.Internal.d.ts +14 -0
- package/dist/core/constraints/UIHorizontalInterpolationConstraint/UIHorizontalInterpolationConstraint.Internal.js +4 -0
- package/dist/core/constraints/UIHorizontalInterpolationConstraint/UIHorizontalInterpolationConstraint.d.ts +44 -0
- package/dist/core/constraints/UIHorizontalInterpolationConstraint/UIHorizontalInterpolationConstraint.js +136 -0
- package/{src/core/constraints/UIHorizontalProportionConstraint/UIHorizontalProportionConstraint.Internal.ts → dist/core/constraints/UIHorizontalProportionConstraint/UIHorizontalProportionConstraint.Internal.d.ts} +2 -3
- package/dist/core/constraints/UIHorizontalProportionConstraint/UIHorizontalProportionConstraint.d.ts +22 -0
- package/dist/core/constraints/UIHorizontalProportionConstraint/UIHorizontalProportionConstraint.js +40 -0
- package/{src/core/constraints/UISingleParameterConstraint/UISingleParameterConstraint.Internal.ts → dist/core/constraints/UISingleParameterConstraint/UISingleParameterConstraint.Internal.d.ts} +8 -9
- package/dist/core/constraints/UISingleParameterConstraint/UISingleParameterConstraint.d.ts +43 -0
- package/dist/core/constraints/UISingleParameterConstraint/UISingleParameterConstraint.js +71 -0
- package/dist/core/constraints/UIVerticalDistanceConstraint/UIVerticalDistanceConstraint.Internal.d.ts +11 -0
- package/dist/core/constraints/UIVerticalDistanceConstraint/UIVerticalDistanceConstraint.Internal.js +3 -0
- package/dist/core/constraints/UIVerticalDistanceConstraint/UIVerticalDistanceConstraint.d.ts +32 -0
- package/dist/core/constraints/UIVerticalDistanceConstraint/UIVerticalDistanceConstraint.js +100 -0
- package/dist/core/constraints/UIVerticalInterpolationConstraint/UIVerticalInterpolationConstraint.Internal.d.ts +14 -0
- package/dist/core/constraints/UIVerticalInterpolationConstraint/UIVerticalInterpolationConstraint.Internal.js +4 -0
- package/dist/core/constraints/UIVerticalInterpolationConstraint/UIVerticalInterpolationConstraint.d.ts +44 -0
- package/dist/core/constraints/UIVerticalInterpolationConstraint/UIVerticalInterpolationConstraint.js +136 -0
- package/{src/core/constraints/UIVerticalProportionConstraint/UIVerticalProportionConstraint.Internal.ts → dist/core/constraints/UIVerticalProportionConstraint/UIVerticalProportionConstraint.Internal.d.ts} +2 -3
- package/dist/core/constraints/UIVerticalProportionConstraint/UIVerticalProportionConstraint.d.ts +22 -0
- package/dist/core/constraints/UIVerticalProportionConstraint/UIVerticalProportionConstraint.js +40 -0
- package/{src/core/constraints/UIWidthConstraint/UIWidthConstraint.Internal.ts → dist/core/constraints/UIWidthConstraint/UIWidthConstraint.Internal.d.ts} +2 -3
- package/dist/core/constraints/UIWidthConstraint/UIWidthConstraint.d.ts +20 -0
- package/dist/core/constraints/UIWidthConstraint/UIWidthConstraint.js +34 -0
- package/dist/core/constraints/builders/UIConstraint2DBuilder.Internal.d.ts +64 -0
- package/dist/core/constraints/builders/UIConstraint2DBuilder.Internal.js +19 -0
- package/dist/core/constraints/builders/UIConstraint2DBuilder.d.ts +46 -0
- package/dist/core/constraints/builders/UIConstraint2DBuilder.js +138 -0
- package/dist/core/constraints/builders/UICoverConstraintBuilder.Internal.d.ts +13 -0
- package/dist/core/constraints/builders/UICoverConstraintBuilder.Internal.js +3 -0
- package/dist/core/constraints/builders/UICoverConstraintBuilder.d.ts +29 -0
- package/dist/core/constraints/builders/UICoverConstraintBuilder.js +63 -0
- package/dist/core/constraints/builders/UIFitConstraintBuilder.Internal.d.ts +13 -0
- package/dist/core/constraints/builders/UIFitConstraintBuilder.Internal.js +3 -0
- package/dist/core/constraints/builders/UIFitConstraintBuilder.d.ts +29 -0
- package/dist/core/constraints/builders/UIFitConstraintBuilder.js +63 -0
- package/dist/core/elements/UIAnchor/UIAnchor.Internal.d.ts +12 -0
- package/dist/core/elements/UIAnchor/UIAnchor.Internal.js +5 -0
- package/dist/core/elements/UIAnchor/UIAnchor.d.ts +32 -0
- package/dist/core/elements/UIAnchor/UIAnchor.js +49 -0
- package/dist/core/elements/UIAnimatedImage/UIAnimatedImage.Internal.d.ts +27 -0
- package/dist/core/elements/UIAnimatedImage/UIAnimatedImage.Internal.js +15 -0
- package/dist/core/elements/UIAnimatedImage/UIAnimatedImage.d.ts +77 -0
- package/dist/core/elements/UIAnimatedImage/UIAnimatedImage.js +259 -0
- package/dist/core/elements/UIDummy/UIDummy.Internal.d.ts +30 -0
- package/dist/core/elements/UIDummy/UIDummy.Internal.js +8 -0
- package/dist/core/elements/UIDummy/UIDummy.d.ts +82 -0
- package/dist/core/elements/UIDummy/UIDummy.js +173 -0
- package/{src/core/elements/UIElement/UIElement.Internal.ts → dist/core/elements/UIElement/UIElement.Internal.d.ts} +5 -7
- package/dist/core/elements/UIElement/UIElement.Internal.js +5 -0
- package/dist/core/elements/UIElement/UIElement.d.ts +38 -0
- package/dist/core/elements/UIElement/UIElement.js +74 -0
- package/{src/core/elements/UIGraphics/UIGraphics.Internal.ts → dist/core/elements/UIGraphics/UIGraphics.Internal.d.ts} +5 -7
- package/dist/core/elements/UIGraphics/UIGraphics.Internal.js +7 -0
- package/dist/core/elements/UIGraphics/UIGraphics.d.ts +51 -0
- package/dist/core/elements/UIGraphics/UIGraphics.js +126 -0
- package/{src/core/elements/UIImage/UIImage.Internal.ts → dist/core/elements/UIImage/UIImage.Internal.d.ts} +2 -3
- package/dist/core/elements/UIImage/UIImage.d.ts +32 -0
- package/dist/core/elements/UIImage/UIImage.js +85 -0
- package/dist/core/elements/UINineSlice/UINineSlice.Internal.d.ts +23 -0
- package/dist/core/elements/UINineSlice/UINineSlice.Internal.js +12 -0
- package/dist/core/elements/UINineSlice/UINineSlice.d.ts +60 -0
- package/dist/core/elements/UINineSlice/UINineSlice.js +188 -0
- package/dist/core/elements/UIProgress/UIProgress.Internal.d.ts +14 -0
- package/dist/core/elements/UIProgress/UIProgress.Internal.js +3 -0
- package/dist/core/elements/UIProgress/UIProgress.d.ts +45 -0
- package/dist/core/elements/UIProgress/UIProgress.js +165 -0
- package/dist/core/elements/UIScene/UIScene.Internal.d.ts +43 -0
- package/dist/core/elements/UIScene/UIScene.Internal.js +27 -0
- package/dist/core/elements/UIScene/UIScene.d.ts +59 -0
- package/dist/core/elements/UIScene/UIScene.js +157 -0
- package/{src/core/elements/UIText/UIText.Interfaces.ts → dist/core/elements/UIText/UIText.Interfaces.d.ts} +16 -21
- package/dist/core/elements/UIText/UIText.Internal.d.ts +26 -0
- package/dist/core/elements/UIText/UIText.Internal.js +12 -0
- package/dist/core/elements/UIText/UIText.Measuring.d.ts +50 -0
- package/dist/core/elements/UIText/UIText.Measuring.js +153 -0
- package/dist/core/elements/UIText/UIText.Rendering.d.ts +20 -0
- package/dist/core/elements/UIText/UIText.Rendering.js +61 -0
- package/dist/core/elements/UIText/UIText.d.ts +71 -0
- package/dist/core/elements/UIText/UIText.js +265 -0
- package/{src/core/layers/UIFullscreenLayer/UIFullscreenLayer.Internal.ts → dist/core/layers/UIFullscreenLayer/UIFullscreenLayer.Internal.d.ts} +11 -14
- package/dist/core/layers/UIFullscreenLayer/UIFullscreenLayer.Internal.js +5 -0
- package/dist/core/layers/UIFullscreenLayer/UIFullscreenLayer.d.ts +63 -0
- package/dist/core/layers/UIFullscreenLayer/UIFullscreenLayer.js +147 -0
- package/{src/core/layers/UILayer/UILayer.Internal.ts → dist/core/layers/UILayer/UILayer.Internal.d.ts} +11 -15
- package/dist/core/layers/UILayer/UILayer.Internal.js +7 -0
- package/dist/core/layers/UILayer/UILayer.d.ts +49 -0
- package/dist/core/layers/UILayer/UILayer.js +113 -0
- package/dist/core/miscellaneous/UIExpression.d.ts +69 -0
- package/dist/core/miscellaneous/UIExpression.js +128 -0
- package/dist/core/miscellaneous/UIMode.d.ts +23 -0
- package/dist/core/miscellaneous/UIMode.js +30 -0
- package/dist/core/miscellaneous/UIOrientation.d.ts +15 -0
- package/dist/core/miscellaneous/UIOrientation.js +20 -0
- package/dist/core/miscellaneous/UIPriority.d.ts +32 -0
- package/dist/core/miscellaneous/UIPriority.js +63 -0
- package/dist/core/miscellaneous/UIRelation.d.ts +23 -0
- package/dist/core/miscellaneous/UIRelation.js +40 -0
- package/dist/core/miscellaneous/UITransparencyMode.d.ts +9 -0
- package/dist/core/miscellaneous/UITransparencyMode.js +12 -0
- package/dist/core/miscellaneous/area/UIArea.d.ts +3 -0
- package/dist/core/miscellaneous/area/UIArea.js +5 -0
- package/dist/core/miscellaneous/area/UIAreaCircle.d.ts +15 -0
- package/dist/core/miscellaneous/area/UIAreaCircle.js +32 -0
- package/dist/core/miscellaneous/area/UIAreaPolygon.d.ts +12 -0
- package/dist/core/miscellaneous/area/UIAreaPolygon.js +40 -0
- package/dist/core/miscellaneous/area/UIAreaRectangle.d.ts +17 -0
- package/dist/core/miscellaneous/area/UIAreaRectangle.js +36 -0
- package/dist/core/miscellaneous/area/UIAreaRoundedRectangle.d.ts +21 -0
- package/dist/core/miscellaneous/area/UIAreaRoundedRectangle.js +72 -0
- package/dist/core/miscellaneous/asserts.d.ts +43 -0
- package/dist/core/miscellaneous/asserts.js +163 -0
- package/dist/core/miscellaneous/canvas.d.ts +31 -0
- package/dist/core/miscellaneous/canvas.js +37 -0
- package/dist/core/miscellaneous/color/UIColor.Internal.d.ts +7 -0
- package/dist/core/miscellaneous/color/UIColor.Internal.js +42 -0
- package/dist/core/miscellaneous/color/UIColor.d.ts +234 -0
- package/dist/core/miscellaneous/color/UIColor.js +636 -0
- package/dist/core/miscellaneous/computeTransform.d.ts +18 -0
- package/dist/core/miscellaneous/computeTransform.js +82 -0
- package/dist/core/miscellaneous/generic-plane/UIGenericInstancedPlane/UIGenericInstancedPlane.Internal.d.ts +19 -0
- package/dist/core/miscellaneous/generic-plane/UIGenericInstancedPlane/UIGenericInstancedPlane.Internal.js +168 -0
- package/dist/core/miscellaneous/generic-plane/UIGenericInstancedPlane/UIGenericInstancedPlane.d.ts +1 -0
- package/dist/core/miscellaneous/generic-plane/UIGenericInstancedPlane/UIGenericInstancedPlane.js +349 -0
- package/{src/core/miscellaneous/generic-plane/UIGenericPlaneRegistry/UIGenericPlaneRegistry.Internal.ts → dist/core/miscellaneous/generic-plane/UIGenericPlaneRegistry/UIGenericPlaneRegistry.Internal.d.ts} +8 -10
- package/dist/core/miscellaneous/generic-plane/UIGenericPlaneRegistry/UIGenericPlaneRegistry.d.ts +1 -0
- package/dist/core/miscellaneous/generic-plane/UIGenericPlaneRegistry/UIGenericPlaneRegistry.js +357 -0
- package/dist/core/miscellaneous/generic-plane/shared.d.ts +38 -0
- package/dist/core/miscellaneous/generic-plane/shared.js +228 -0
- package/dist/core/miscellaneous/insets/UIInsets.Internal.d.ts +11 -0
- package/dist/core/miscellaneous/insets/UIInsets.Internal.js +3 -0
- package/dist/core/miscellaneous/insets/UIInsets.d.ts +48 -0
- package/dist/core/miscellaneous/insets/UIInsets.js +224 -0
- package/dist/core/miscellaneous/mask-function/UIProgressMaskFunction.d.ts +9 -0
- package/dist/core/miscellaneous/mask-function/UIProgressMaskFunction.js +19 -0
- package/dist/core/miscellaneous/mask-function/UIProgressMaskFunctionCircular.d.ts +21 -0
- package/dist/core/miscellaneous/mask-function/UIProgressMaskFunctionCircular.js +51 -0
- package/dist/core/miscellaneous/mask-function/UIProgressMaskFunctionDirectional.d.ts +16 -0
- package/dist/core/miscellaneous/mask-function/UIProgressMaskFunctionDirectional.js +48 -0
- package/dist/core/miscellaneous/math.d.ts +7 -0
- package/dist/core/miscellaneous/math.js +11 -0
- package/dist/core/miscellaneous/micro/UIMicro.Internal.d.ts +31 -0
- package/dist/core/miscellaneous/micro/UIMicro.Internal.js +15 -0
- package/dist/core/miscellaneous/micro/UIMicro.d.ts +59 -0
- package/dist/core/miscellaneous/micro/UIMicro.js +181 -0
- package/dist/core/miscellaneous/resize-policy/UIResizePolicy.d.ts +3 -0
- package/dist/core/miscellaneous/resize-policy/UIResizePolicy.js +9 -0
- package/dist/core/miscellaneous/resize-policy/UIResizePolicyCover.d.ts +22 -0
- package/dist/core/miscellaneous/resize-policy/UIResizePolicyCover.js +50 -0
- package/dist/core/miscellaneous/resize-policy/UIResizePolicyCross.d.ts +22 -0
- package/dist/core/miscellaneous/resize-policy/UIResizePolicyCross.js +52 -0
- package/dist/core/miscellaneous/resize-policy/UIResizePolicyCrossInverted.d.ts +22 -0
- package/dist/core/miscellaneous/resize-policy/UIResizePolicyCrossInverted.js +52 -0
- package/dist/core/miscellaneous/resize-policy/UIResizePolicyFit.d.ts +22 -0
- package/dist/core/miscellaneous/resize-policy/UIResizePolicyFit.js +50 -0
- package/dist/core/miscellaneous/resize-policy/UIResizePolicyFixedHeight.d.ts +22 -0
- package/dist/core/miscellaneous/resize-policy/UIResizePolicyFixedHeight.js +52 -0
- package/dist/core/miscellaneous/resize-policy/UIResizePolicyFixedWidth.d.ts +22 -0
- package/dist/core/miscellaneous/resize-policy/UIResizePolicyFixedWidth.js +52 -0
- package/dist/core/miscellaneous/resize-policy/UIResizePolicyNone.d.ts +5 -0
- package/dist/core/miscellaneous/resize-policy/UIResizePolicyNone.js +13 -0
- package/dist/core/miscellaneous/shared.d.ts +46 -0
- package/dist/core/miscellaneous/shared.js +37 -0
- package/{src/core/miscellaneous/text-span/UITextSpan.Internal.ts → dist/core/miscellaneous/text-span/UITextSpan.Internal.d.ts} +4 -5
- package/dist/core/miscellaneous/text-span/UITextSpan.d.ts +14 -0
- package/dist/core/miscellaneous/text-span/UITextSpan.js +36 -0
- package/dist/core/miscellaneous/text-style/UITextStyle.Internal.d.ts +48 -0
- package/dist/core/miscellaneous/text-style/UITextStyle.Internal.js +17 -0
- package/dist/core/miscellaneous/text-style/UITextStyle.d.ts +85 -0
- package/dist/core/miscellaneous/text-style/UITextStyle.js +372 -0
- package/dist/core/miscellaneous/texture/UITextureView.Internal.d.ts +49 -0
- package/dist/core/miscellaneous/texture/UITextureView.Internal.js +6 -0
- package/dist/core/miscellaneous/texture/UITextureView.d.ts +67 -0
- package/dist/core/miscellaneous/texture/UITextureView.js +234 -0
- package/dist/core/miscellaneous/webglCapabilities.d.ts +2 -0
- package/dist/core/miscellaneous/webglCapabilities.js +103 -0
- package/dist/core/shaders/UIImage.glsl.js +3 -0
- package/dist/core/shaders/UINineSlice.glsl.js +3 -0
- package/dist/core/shaders/UIProgress.glsl.js +3 -0
- package/dist/core/shaders/UIProgressMaskFunctionCircular.glsl.js +3 -0
- package/dist/core/shaders/UIProgressMaskFunctionDirectional.glsl.js +3 -0
- package/dist/core/wrappers/UIInputWrapper/UIInputWrapper.Internal.d.ts +17 -0
- package/dist/core/wrappers/UIInputWrapper/UIInputWrapper.d.ts +13 -0
- package/dist/core/wrappers/UIInputWrapper/UIInputWrapper.js +108 -0
- package/dist/core/wrappers/UISceneWrapper/UISceneWrapper.Internal.d.ts +13 -0
- package/dist/core/wrappers/UISceneWrapper/UISceneWrapper.d.ts +20 -0
- package/dist/core/wrappers/UISceneWrapper/UISceneWrapper.js +75 -0
- package/dist/core/wrappers/UISolverWrapper/UISolverWrapper.Internal.d.ts +49 -0
- package/dist/core/wrappers/UISolverWrapper/UISolverWrapper.d.ts +215 -0
- package/dist/core/wrappers/UISolverWrapper/UISolverWrapper.js +505 -0
- package/dist/index.js +51 -0
- package/dist/particles/behaviorModules/UIBehaviorDirectionalGravity.d.ts +21 -0
- package/dist/particles/behaviorModules/UIBehaviorDirectionalGravity.js +47 -0
- package/dist/particles/behaviorModules/UIBehaviorModule.d.ts +14 -0
- package/dist/particles/behaviorModules/UIBehaviorModule.js +9 -0
- package/dist/particles/behaviorModules/UIBehaviorPointGravity.d.ts +39 -0
- package/dist/particles/behaviorModules/UIBehaviorPointGravity.js +110 -0
- package/dist/particles/behaviorModules/UIBehaviorScaleOverLife.d.ts +22 -0
- package/dist/particles/behaviorModules/UIBehaviorScaleOverLife.js +66 -0
- package/dist/particles/behaviorModules/UIBehaviorTorqueDamping.d.ts +20 -0
- package/dist/particles/behaviorModules/UIBehaviorTorqueDamping.js +48 -0
- package/dist/particles/behaviorModules/UIBehaviorTorqueNoise.d.ts +26 -0
- package/dist/particles/behaviorModules/UIBehaviorTorqueNoise.js +66 -0
- package/dist/particles/behaviorModules/UIBehaviorVelocityDamping.d.ts +20 -0
- package/dist/particles/behaviorModules/UIBehaviorVelocityDamping.js +49 -0
- package/dist/particles/behaviorModules/UIBehaviorVelocityNoise.d.ts +26 -0
- package/dist/particles/behaviorModules/UIBehaviorVelocityNoise.js +70 -0
- package/dist/particles/elements/UIEmitter.Internal.d.ts +15 -0
- package/dist/particles/elements/UIEmitter.Internal.js +11 -0
- package/dist/particles/elements/UIEmitter.d.ts +68 -0
- package/dist/particles/elements/UIEmitter.js +203 -0
- package/dist/particles/index.js +18 -0
- package/dist/particles/instancedParticle/UIInstancedParticle.Internal.d.ts +13 -0
- package/dist/particles/instancedParticle/UIInstancedParticle.Internal.js +211 -0
- package/dist/particles/instancedParticle/UIInstancedParticle.d.ts +17 -0
- package/dist/particles/instancedParticle/UIInstancedParticle.js +93 -0
- package/dist/particles/miscellaneous/miscellaneous.d.ts +32 -0
- package/dist/particles/miscellaneous/miscellaneous.js +67 -0
- package/dist/particles/renderingModules/UIRenderingColorOverLife.d.ts +14 -0
- package/dist/particles/renderingModules/UIRenderingColorOverLife.js +32 -0
- package/dist/particles/renderingModules/UIRenderingColorOverVelocity.d.ts +15 -0
- package/dist/particles/renderingModules/UIRenderingColorOverVelocity.js +37 -0
- package/dist/particles/renderingModules/UIRenderingModule.d.ts +8 -0
- package/dist/particles/renderingModules/UIRenderingModule.js +9 -0
- package/dist/particles/renderingModules/UIRenderingTexture.d.ts +14 -0
- package/dist/particles/renderingModules/UIRenderingTexture.js +26 -0
- package/dist/particles/shaders/UIRenderingColorOverLife.glsl.js +3 -0
- package/dist/particles/shaders/UIRenderingColorOverVelocity.glsl.js +3 -0
- package/dist/particles/shaders/UIRenderingTexture.glsl.js +3 -0
- package/dist/particles/spawnModules/UISpawnModule.d.ts +9 -0
- package/dist/particles/spawnModules/UISpawnModule.js +9 -0
- package/dist/particles/spawnModules/UISpawnOffset.d.ts +21 -0
- package/dist/particles/spawnModules/UISpawnOffset.js +46 -0
- package/dist/particles/spawnModules/UISpawnRandomLifetime.d.ts +20 -0
- package/dist/particles/spawnModules/UISpawnRandomLifetime.js +47 -0
- package/dist/particles/spawnModules/UISpawnRandomRotation.d.ts +20 -0
- package/dist/particles/spawnModules/UISpawnRandomRotation.js +45 -0
- package/dist/particles/spawnModules/UISpawnRandomScale.d.ts +26 -0
- package/dist/particles/spawnModules/UISpawnRandomScale.js +60 -0
- package/dist/particles/spawnModules/UISpawnRandomTorque.d.ts +20 -0
- package/dist/particles/spawnModules/UISpawnRandomTorque.js +45 -0
- package/dist/particles/spawnModules/UISpawnRandomVelocity.d.ts +26 -0
- package/dist/particles/spawnModules/UISpawnRandomVelocity.js +64 -0
- package/dist/particles/spawnModules/UISpawnRectangle.d.ts +27 -0
- package/dist/particles/spawnModules/UISpawnRectangle.js +62 -0
- package/package.json +8 -1
- package/.claude/settings.local.json +0 -9
- package/.editorconfig +0 -14
- package/CLAUDE.md +0 -181
- package/assets/logotype.png +0 -0
- package/eslint.config.js +0 -111
- package/rollup.config.js +0 -52
- package/src/core/constraints/UIAspectConstraint/UIAspectConstraint.ts +0 -60
- package/src/core/constraints/UIConstraint.ts +0 -20
- package/src/core/constraints/UICustomConstraint.ts +0 -62
- package/src/core/constraints/UIHeightConstraint/UIHeightConstraint.ts +0 -52
- package/src/core/constraints/UIHorizontalDistanceConstraint/UIHorizontalDistanceConstraint.Internal.ts +0 -13
- package/src/core/constraints/UIHorizontalDistanceConstraint/UIHorizontalDistanceConstraint.ts +0 -139
- package/src/core/constraints/UIHorizontalInterpolationConstraint/UIHorizontalInterpolationConstraint.Internal.ts +0 -16
- package/src/core/constraints/UIHorizontalInterpolationConstraint/UIHorizontalInterpolationConstraint.ts +0 -189
- package/src/core/constraints/UIHorizontalProportionConstraint/UIHorizontalProportionConstraint.ts +0 -68
- package/src/core/constraints/UISingleParameterConstraint/UISingleParameterConstraint.ts +0 -94
- package/src/core/constraints/UIVerticalDistanceConstraint/UIVerticalDistanceConstraint.Internal.ts +0 -13
- package/src/core/constraints/UIVerticalDistanceConstraint/UIVerticalDistanceConstraint.ts +0 -135
- package/src/core/constraints/UIVerticalInterpolationConstraint/UIVerticalInterpolationConstraint.Internal.ts +0 -16
- package/src/core/constraints/UIVerticalInterpolationConstraint/UIVerticalInterpolationConstraint.ts +0 -189
- package/src/core/constraints/UIVerticalProportionConstraint/UIVerticalProportionConstraint.ts +0 -68
- package/src/core/constraints/UIWidthConstraint/UIWidthConstraint.ts +0 -52
- package/src/core/constraints/builders/UIConstraint2DBuilder.Internal.ts +0 -84
- package/src/core/constraints/builders/UIConstraint2DBuilder.ts +0 -168
- package/src/core/constraints/builders/UICoverConstraintBuilder.Internal.ts +0 -15
- package/src/core/constraints/builders/UICoverConstraintBuilder.ts +0 -84
- package/src/core/constraints/builders/UIFitConstraintBuilder.Internal.ts +0 -15
- package/src/core/constraints/builders/UIFitConstraintBuilder.ts +0 -84
- package/src/core/elements/UIAnchor/UIAnchor.Internal.ts +0 -13
- package/src/core/elements/UIAnchor/UIAnchor.ts +0 -70
- package/src/core/elements/UIAnimatedImage/UIAnimatedImage.Internal.ts +0 -30
- package/src/core/elements/UIAnimatedImage/UIAnimatedImage.ts +0 -355
- package/src/core/elements/UIDummy/UIDummy.Internal.ts +0 -33
- package/src/core/elements/UIDummy/UIDummy.ts +0 -244
- package/src/core/elements/UIElement/UIElement.ts +0 -127
- package/src/core/elements/UIGraphics/UIGraphics.ts +0 -168
- package/src/core/elements/UIImage/UIImage.ts +0 -138
- package/src/core/elements/UINineSlice/UINineSlice.Internal.ts +0 -26
- package/src/core/elements/UINineSlice/UINineSlice.ts +0 -296
- package/src/core/elements/UIProgress/UIProgress.Internal.ts +0 -24
- package/src/core/elements/UIProgress/UIProgress.ts +0 -259
- package/src/core/elements/UIScene/UIScene.Internal.ts +0 -46
- package/src/core/elements/UIScene/UIScene.ts +0 -259
- package/src/core/elements/UIText/UIText.Internal.ts +0 -29
- package/src/core/elements/UIText/UIText.Measuring.ts +0 -183
- package/src/core/elements/UIText/UIText.Rendering.ts +0 -83
- package/src/core/elements/UIText/UIText.ts +0 -376
- package/src/core/layers/UIFullscreenLayer/UIFullscreenLayer.ts +0 -233
- package/src/core/layers/UILayer/UILayer.ts +0 -156
- package/src/core/miscellaneous/UIExpression.ts +0 -142
- package/src/core/miscellaneous/UIMode.ts +0 -29
- package/src/core/miscellaneous/UIOrientation.ts +0 -18
- package/src/core/miscellaneous/UIPriority.ts +0 -63
- package/src/core/miscellaneous/UIRelation.ts +0 -39
- package/src/core/miscellaneous/UITransparencyMode.ts +0 -9
- package/src/core/miscellaneous/area/UIArea.ts +0 -5
- package/src/core/miscellaneous/area/UIAreaCircle.ts +0 -32
- package/src/core/miscellaneous/area/UIAreaPolygon.ts +0 -50
- package/src/core/miscellaneous/area/UIAreaRectangle.ts +0 -38
- package/src/core/miscellaneous/area/UIAreaRoundedRectangle.ts +0 -78
- package/src/core/miscellaneous/asserts.ts +0 -187
- package/src/core/miscellaneous/canvas.ts +0 -73
- package/src/core/miscellaneous/color/UIColor.Internal.ts +0 -89
- package/src/core/miscellaneous/color/UIColor.ts +0 -844
- package/src/core/miscellaneous/computeTransform.ts +0 -127
- package/src/core/miscellaneous/generic-plane/UIGenericInstancedPlane/UIGenericInstancedPlane.Internal.ts +0 -235
- package/src/core/miscellaneous/generic-plane/UIGenericInstancedPlane/UIGenericInstancedPlane.ts +0 -524
- package/src/core/miscellaneous/generic-plane/UIGenericPlaneRegistry/UIGenericPlaneRegistry.ts +0 -448
- package/src/core/miscellaneous/generic-plane/shared.ts +0 -323
- package/src/core/miscellaneous/insets/UIInsets.Internal.ts +0 -9
- package/src/core/miscellaneous/insets/UIInsets.ts +0 -248
- package/src/core/miscellaneous/mask-function/UIProgressMaskFunction.ts +0 -24
- package/src/core/miscellaneous/mask-function/UIProgressMaskFunctionCircular.ts +0 -58
- package/src/core/miscellaneous/mask-function/UIProgressMaskFunctionDirectional.ts +0 -52
- package/src/core/miscellaneous/math.ts +0 -16
- package/src/core/miscellaneous/micro/UIMicro.Internal.ts +0 -33
- package/src/core/miscellaneous/micro/UIMicro.ts +0 -222
- package/src/core/miscellaneous/resize-policy/UIResizePolicy.ts +0 -8
- package/src/core/miscellaneous/resize-policy/UIResizePolicyCover.ts +0 -57
- package/src/core/miscellaneous/resize-policy/UIResizePolicyCross.ts +0 -65
- package/src/core/miscellaneous/resize-policy/UIResizePolicyCrossInverted.ts +0 -65
- package/src/core/miscellaneous/resize-policy/UIResizePolicyFit.ts +0 -57
- package/src/core/miscellaneous/resize-policy/UIResizePolicyFixedHeight.ts +0 -65
- package/src/core/miscellaneous/resize-policy/UIResizePolicyFixedWidth.ts +0 -65
- package/src/core/miscellaneous/resize-policy/UIResizePolicyNone.ts +0 -11
- package/src/core/miscellaneous/shared.ts +0 -73
- package/src/core/miscellaneous/text-span/UITextSpan.ts +0 -43
- package/src/core/miscellaneous/text-style/UITextStyle.Internal.ts +0 -52
- package/src/core/miscellaneous/text-style/UITextStyle.ts +0 -479
- package/src/core/miscellaneous/texture/UITextureView.Internal.ts +0 -55
- package/src/core/miscellaneous/texture/UITextureView.ts +0 -308
- package/src/core/miscellaneous/webglCapabilities.ts +0 -129
- package/src/core/shaders/UIImage.glsl +0 -10
- package/src/core/shaders/UINineSlice.glsl +0 -53
- package/src/core/shaders/UIProgress.glsl +0 -15
- package/src/core/shaders/UIProgressMaskFunctionCircular.glsl +0 -13
- package/src/core/shaders/UIProgressMaskFunctionDirectional.glsl +0 -12
- package/src/core/shaders/glsl.d.ts +0 -27
- package/src/core/wrappers/UIInputWrapper/UIInputWrapper.Internal.ts +0 -23
- package/src/core/wrappers/UIInputWrapper/UIInputWrapper.ts +0 -124
- package/src/core/wrappers/UISceneWrapper/UISceneWrapper.Internal.ts +0 -22
- package/src/core/wrappers/UISceneWrapper/UISceneWrapper.ts +0 -101
- package/src/core/wrappers/UISolverWrapper/UISolverWrapper.Internal.ts +0 -58
- package/src/core/wrappers/UISolverWrapper/UISolverWrapper.ts +0 -605
- package/src/particles/behaviorModules/UIBehaviorDirectionalGravity.ts +0 -70
- package/src/particles/behaviorModules/UIBehaviorModule.ts +0 -20
- package/src/particles/behaviorModules/UIBehaviorPointGravity.ts +0 -173
- package/src/particles/behaviorModules/UIBehaviorScaleOverLife.ts +0 -104
- package/src/particles/behaviorModules/UIBehaviorTorqueDamping.ts +0 -75
- package/src/particles/behaviorModules/UIBehaviorTorqueNoise.ts +0 -115
- package/src/particles/behaviorModules/UIBehaviorVelocityDamping.ts +0 -77
- package/src/particles/behaviorModules/UIBehaviorVelocityNoise.ts +0 -118
- package/src/particles/elements/UIEmitter.Internal.ts +0 -22
- package/src/particles/elements/UIEmitter.ts +0 -313
- package/src/particles/instancedParticle/UIInstancedParticle.Internal.ts +0 -263
- package/src/particles/instancedParticle/UIInstancedParticle.ts +0 -138
- package/src/particles/miscellaneous/miscellaneous.ts +0 -115
- package/src/particles/renderingModules/UIRenderingColorOverLife.ts +0 -39
- package/src/particles/renderingModules/UIRenderingColorOverVelocity.ts +0 -49
- package/src/particles/renderingModules/UIRenderingModule.ts +0 -17
- package/src/particles/renderingModules/UIRenderingTexture.ts +0 -30
- package/src/particles/shaders/UIRenderingColorOverLife.glsl +0 -4
- package/src/particles/shaders/UIRenderingColorOverVelocity.glsl +0 -6
- package/src/particles/shaders/UIRenderingTexture.glsl +0 -4
- package/src/particles/spawnModules/UISpawnModule.ts +0 -22
- package/src/particles/spawnModules/UISpawnOffset.ts +0 -62
- package/src/particles/spawnModules/UISpawnRandomLifetime.ts +0 -68
- package/src/particles/spawnModules/UISpawnRandomRotation.ts +0 -60
- package/src/particles/spawnModules/UISpawnRandomScale.ts +0 -81
- package/src/particles/spawnModules/UISpawnRandomTorque.ts +0 -62
- package/src/particles/spawnModules/UISpawnRandomVelocity.ts +0 -92
- package/src/particles/spawnModules/UISpawnRectangle.ts +0 -81
- package/tsconfig.json +0 -29
- /package/{src/core/index.ts → dist/core/index.d.ts} +0 -0
- /package/{src/particles/index.ts → dist/particles/index.d.ts} +0 -0
|
@@ -1,187 +0,0 @@
|
|
|
1
|
-
import { UILayer } from "../layers/UILayer/UILayer";
|
|
2
|
-
import { EPSILON } from "./math";
|
|
3
|
-
import { isUILayerElement } from "./shared";
|
|
4
|
-
|
|
5
|
-
/**
|
|
6
|
-
* Validates value is finite number within safe range.
|
|
7
|
-
* @param value Number to validate
|
|
8
|
-
* @param subject Value name for error messages
|
|
9
|
-
* @throws If value is not finite or exceeds safe range
|
|
10
|
-
*/
|
|
11
|
-
export function assertValidNumber(value: number, subject: string): void {
|
|
12
|
-
if (process.env.NODE_ENV !== "production") {
|
|
13
|
-
if (!Number.isFinite(value)) {
|
|
14
|
-
throw new Error(`${subject}: value must be a finite number`);
|
|
15
|
-
}
|
|
16
|
-
|
|
17
|
-
if (Math.abs(value) > Number.MAX_SAFE_INTEGER) {
|
|
18
|
-
throw new Error(`${subject}: value exceeds maximum safe integer range`);
|
|
19
|
-
}
|
|
20
|
-
}
|
|
21
|
-
}
|
|
22
|
-
|
|
23
|
-
/**
|
|
24
|
-
* Validates value is positive (>= EPSILON).
|
|
25
|
-
* @param value Number to validate
|
|
26
|
-
* @param subject Value name for error messages
|
|
27
|
-
* @throws If value is invalid or below EPSILON
|
|
28
|
-
*/
|
|
29
|
-
export function assertValidPositiveNumber(value: number, subject: string): void {
|
|
30
|
-
if (process.env.NODE_ENV !== "production") {
|
|
31
|
-
assertValidNumber(value, subject);
|
|
32
|
-
if (value < EPSILON) {
|
|
33
|
-
throw new Error(`${subject}: value must be greater than or equal to ${EPSILON}`);
|
|
34
|
-
}
|
|
35
|
-
}
|
|
36
|
-
}
|
|
37
|
-
|
|
38
|
-
/**
|
|
39
|
-
* Validates value is non-negative (>= 0).
|
|
40
|
-
* @param value Number to validate
|
|
41
|
-
* @param subject Value name for error messages
|
|
42
|
-
* @throws If value is invalid or negative
|
|
43
|
-
*/
|
|
44
|
-
export function assertValidNonNegativeNumber(value: number, subject: string): void {
|
|
45
|
-
if (process.env.NODE_ENV !== "production") {
|
|
46
|
-
assertValidNumber(value, subject);
|
|
47
|
-
if (value < 0) {
|
|
48
|
-
throw new Error(`${subject}: value must be greater than or equal to 0`);
|
|
49
|
-
}
|
|
50
|
-
}
|
|
51
|
-
}
|
|
52
|
-
|
|
53
|
-
/**
|
|
54
|
-
* Validates constraint arguments are from same layer.
|
|
55
|
-
* @param a First constraint subject
|
|
56
|
-
* @param b Second constraint subject
|
|
57
|
-
* @param subject Constraint name for error messages
|
|
58
|
-
* @returns Common layer for both subjects
|
|
59
|
-
* @throws If subjects are invalid or from different layers
|
|
60
|
-
*/
|
|
61
|
-
export function assertValidConstraintArguments(a: unknown, b: unknown, subject: string): UILayer {
|
|
62
|
-
if (process.env.NODE_ENV !== "production") {
|
|
63
|
-
if (a instanceof UILayer && b instanceof UILayer) {
|
|
64
|
-
throw new Error(`${subject}: layer cannot be snapped to another layer`);
|
|
65
|
-
}
|
|
66
|
-
|
|
67
|
-
let layerA: UILayer;
|
|
68
|
-
let layerB: UILayer;
|
|
69
|
-
|
|
70
|
-
if (a instanceof UILayer) {
|
|
71
|
-
layerA = a;
|
|
72
|
-
} else if (isUILayerElement(a)) {
|
|
73
|
-
layerA = a.layer;
|
|
74
|
-
} else {
|
|
75
|
-
throw new Error(`${subject}: A must be a UILayer or a UILayerElement`);
|
|
76
|
-
}
|
|
77
|
-
|
|
78
|
-
if (b instanceof UILayer) {
|
|
79
|
-
layerB = b;
|
|
80
|
-
} else if (isUILayerElement(b)) {
|
|
81
|
-
layerB = b.layer;
|
|
82
|
-
} else {
|
|
83
|
-
throw new Error(`${subject}: B must be a UILayer or a UILayerElement`);
|
|
84
|
-
}
|
|
85
|
-
|
|
86
|
-
if (layerA !== layerB) {
|
|
87
|
-
throw new Error(`${subject}: elements must be on the same layer`);
|
|
88
|
-
}
|
|
89
|
-
|
|
90
|
-
return layerA;
|
|
91
|
-
}
|
|
92
|
-
|
|
93
|
-
if (a instanceof UILayer) {
|
|
94
|
-
return a;
|
|
95
|
-
}
|
|
96
|
-
if (isUILayerElement(a)) {
|
|
97
|
-
return a.layer;
|
|
98
|
-
}
|
|
99
|
-
if (b instanceof UILayer) {
|
|
100
|
-
return b;
|
|
101
|
-
}
|
|
102
|
-
if (isUILayerElement(b)) {
|
|
103
|
-
return b.layer;
|
|
104
|
-
}
|
|
105
|
-
|
|
106
|
-
throw new Error(`${subject}: no valid subjects found`);
|
|
107
|
-
}
|
|
108
|
-
|
|
109
|
-
/**
|
|
110
|
-
* Validates interpolation constraint subjects.
|
|
111
|
-
* @param subject Constraint name for error messages
|
|
112
|
-
* @param a First element
|
|
113
|
-
* @param b Second element
|
|
114
|
-
* @param c Element to interpolate
|
|
115
|
-
* @param anchorA Anchor on element A
|
|
116
|
-
* @param anchorB Anchor on element B
|
|
117
|
-
* @returns Common layer for all subjects
|
|
118
|
-
* @throws If subjects violate interpolation constraints
|
|
119
|
-
*/
|
|
120
|
-
export function assertValidInterpolationConstraintArguments(
|
|
121
|
-
subject: string,
|
|
122
|
-
a: unknown,
|
|
123
|
-
b: unknown,
|
|
124
|
-
c: unknown,
|
|
125
|
-
anchorA: number,
|
|
126
|
-
anchorB: number,
|
|
127
|
-
): UILayer {
|
|
128
|
-
if (process.env.NODE_ENV !== "production") {
|
|
129
|
-
if (c instanceof UILayer) {
|
|
130
|
-
throw new Error(`${subject}: C cannot be a layer`);
|
|
131
|
-
}
|
|
132
|
-
|
|
133
|
-
if (!isUILayerElement(c)) {
|
|
134
|
-
throw new Error(`${subject}: C must be a UILayerElement`);
|
|
135
|
-
}
|
|
136
|
-
|
|
137
|
-
let layerA: UILayer;
|
|
138
|
-
let layerB: UILayer;
|
|
139
|
-
|
|
140
|
-
if (a instanceof UILayer || isUILayerElement(a)) {
|
|
141
|
-
layerA = a instanceof UILayer ? a : a.layer;
|
|
142
|
-
} else {
|
|
143
|
-
throw new Error(`${subject}: A must be UILayer or UILayerElement`);
|
|
144
|
-
}
|
|
145
|
-
|
|
146
|
-
if (b instanceof UILayer || isUILayerElement(b)) {
|
|
147
|
-
layerB = b instanceof UILayer ? b : b.layer;
|
|
148
|
-
} else {
|
|
149
|
-
throw new Error(`${subject}: B must be UILayer or UILayerElement`);
|
|
150
|
-
}
|
|
151
|
-
|
|
152
|
-
const layerC = c.layer;
|
|
153
|
-
|
|
154
|
-
if (layerA !== layerB || layerA !== layerC) {
|
|
155
|
-
throw new Error(`${subject}: all elements must be on the same layer`);
|
|
156
|
-
}
|
|
157
|
-
|
|
158
|
-
if (c === a || c === b) {
|
|
159
|
-
throw new Error(`${subject}: C cannot be equal to A or B`);
|
|
160
|
-
}
|
|
161
|
-
|
|
162
|
-
if (a === b) {
|
|
163
|
-
if (Math.abs(anchorA - anchorB) <= EPSILON) {
|
|
164
|
-
throw new Error(
|
|
165
|
-
`${subject}: when A and B are the same, anchorA and anchorB must differ by more than ${EPSILON}`,
|
|
166
|
-
);
|
|
167
|
-
}
|
|
168
|
-
}
|
|
169
|
-
|
|
170
|
-
return layerA;
|
|
171
|
-
}
|
|
172
|
-
|
|
173
|
-
if (isUILayerElement(a)) {
|
|
174
|
-
return a.layer;
|
|
175
|
-
}
|
|
176
|
-
if (isUILayerElement(b)) {
|
|
177
|
-
return b.layer;
|
|
178
|
-
}
|
|
179
|
-
if (a instanceof UILayer) {
|
|
180
|
-
return a;
|
|
181
|
-
}
|
|
182
|
-
if (b instanceof UILayer) {
|
|
183
|
-
return b;
|
|
184
|
-
}
|
|
185
|
-
|
|
186
|
-
throw new Error(`${subject}: no valid subjects found`);
|
|
187
|
-
}
|
|
@@ -1,73 +0,0 @@
|
|
|
1
|
-
import {
|
|
2
|
-
CanvasTexture,
|
|
3
|
-
ClampToEdgeWrapping,
|
|
4
|
-
LinearFilter,
|
|
5
|
-
RGBAFormat,
|
|
6
|
-
UnsignedByteType,
|
|
7
|
-
UVMapping,
|
|
8
|
-
SRGBColorSpace,
|
|
9
|
-
NoColorSpace,
|
|
10
|
-
} from "three";
|
|
11
|
-
import { checkOffscreenCanvasSupport, checkSRGBSupport } from "./webglCapabilities";
|
|
12
|
-
|
|
13
|
-
/** Canvas type that works both in main thread and workers */
|
|
14
|
-
export type UICanvas = HTMLCanvasElement | OffscreenCanvas;
|
|
15
|
-
|
|
16
|
-
/** 2D rendering context type for UICanvas */
|
|
17
|
-
export type UICanvasRenderingContext2D =
|
|
18
|
-
| CanvasRenderingContext2D
|
|
19
|
-
| OffscreenCanvasRenderingContext2D;
|
|
20
|
-
|
|
21
|
-
/**
|
|
22
|
-
* Creates a canvas using OffscreenCanvas if available, otherwise falls back to HTMLCanvasElement.
|
|
23
|
-
*
|
|
24
|
-
* @param width - Canvas width in pixels
|
|
25
|
-
* @param height - Canvas height in pixels
|
|
26
|
-
* @returns Canvas instance
|
|
27
|
-
*/
|
|
28
|
-
export function createCanvas(width: number, height: number): UICanvas {
|
|
29
|
-
if (checkOffscreenCanvasSupport()) {
|
|
30
|
-
return new OffscreenCanvas(width, height);
|
|
31
|
-
}
|
|
32
|
-
const canvasElement = document.createElement("canvas");
|
|
33
|
-
canvasElement.width = width;
|
|
34
|
-
canvasElement.height = height;
|
|
35
|
-
return canvasElement;
|
|
36
|
-
}
|
|
37
|
-
|
|
38
|
-
/**
|
|
39
|
-
* Gets the 2D rendering context for a UICanvas.
|
|
40
|
-
*
|
|
41
|
-
* @param canvas - Canvas instance
|
|
42
|
-
* @returns 2D rendering context or null
|
|
43
|
-
*/
|
|
44
|
-
export function getCanvas2DContext(canvas: UICanvas): UICanvasRenderingContext2D | null {
|
|
45
|
-
return canvas.getContext("2d");
|
|
46
|
-
}
|
|
47
|
-
|
|
48
|
-
/**
|
|
49
|
-
* Creates a CanvasTexture with maximum WebGL1/WebGL2 compatibility.
|
|
50
|
-
* - ClampToEdge wrapping (required for NPOT in WebGL1)
|
|
51
|
-
* - Linear filtering without mipmaps (NPOT-safe)
|
|
52
|
-
* - RGBA/UnsignedByte format (no extensions needed)
|
|
53
|
-
* - sRGB colorspace only if supported
|
|
54
|
-
*
|
|
55
|
-
* @param canvas - Source canvas
|
|
56
|
-
* @returns Configured CanvasTexture
|
|
57
|
-
*/
|
|
58
|
-
export function createCanvasTexture(canvas: UICanvas): CanvasTexture {
|
|
59
|
-
const texture = new CanvasTexture(
|
|
60
|
-
canvas,
|
|
61
|
-
UVMapping,
|
|
62
|
-
ClampToEdgeWrapping,
|
|
63
|
-
ClampToEdgeWrapping,
|
|
64
|
-
LinearFilter,
|
|
65
|
-
LinearFilter,
|
|
66
|
-
RGBAFormat,
|
|
67
|
-
UnsignedByteType,
|
|
68
|
-
1,
|
|
69
|
-
);
|
|
70
|
-
texture.colorSpace = checkSRGBSupport() ? SRGBColorSpace : NoColorSpace;
|
|
71
|
-
texture.generateMipmaps = false;
|
|
72
|
-
return texture;
|
|
73
|
-
}
|
|
@@ -1,89 +0,0 @@
|
|
|
1
|
-
import type { Color } from "three";
|
|
2
|
-
import type { UIColor } from "./UIColor";
|
|
3
|
-
|
|
4
|
-
/** Color configuration as Three.js Color, hex number, hex string, or UIColor */
|
|
5
|
-
export type UIColorConfig = Color | number | string | UIColor;
|
|
6
|
-
|
|
7
|
-
/** Predefined color names */
|
|
8
|
-
export type UIColorName =
|
|
9
|
-
| "black"
|
|
10
|
-
| "white"
|
|
11
|
-
| "red"
|
|
12
|
-
| "green"
|
|
13
|
-
| "blue"
|
|
14
|
-
| "yellow"
|
|
15
|
-
| "cyan"
|
|
16
|
-
| "magenta"
|
|
17
|
-
| "gray"
|
|
18
|
-
| "grey"
|
|
19
|
-
| "silver"
|
|
20
|
-
| "maroon"
|
|
21
|
-
| "olive"
|
|
22
|
-
| "lime"
|
|
23
|
-
| "aqua"
|
|
24
|
-
| "teal"
|
|
25
|
-
| "navy"
|
|
26
|
-
| "fuchsia"
|
|
27
|
-
| "purple"
|
|
28
|
-
| "orange"
|
|
29
|
-
| "pink"
|
|
30
|
-
| "brown"
|
|
31
|
-
| "gold"
|
|
32
|
-
| "violet"
|
|
33
|
-
| "indigo"
|
|
34
|
-
| "coral"
|
|
35
|
-
| "salmon"
|
|
36
|
-
| "khaki"
|
|
37
|
-
| "plum"
|
|
38
|
-
| "orchid"
|
|
39
|
-
| "tan"
|
|
40
|
-
| "beige"
|
|
41
|
-
| "mint"
|
|
42
|
-
| "lavender"
|
|
43
|
-
| "crimson"
|
|
44
|
-
| "azure"
|
|
45
|
-
| "ivory"
|
|
46
|
-
| "snow";
|
|
47
|
-
|
|
48
|
-
export const COLORS: Record<string, number | undefined> = {
|
|
49
|
-
black: 0x000000,
|
|
50
|
-
white: 0xffffff,
|
|
51
|
-
red: 0xff0000,
|
|
52
|
-
green: 0x008000,
|
|
53
|
-
blue: 0x0000ff,
|
|
54
|
-
yellow: 0xffff00,
|
|
55
|
-
cyan: 0x00ffff,
|
|
56
|
-
magenta: 0xff00ff,
|
|
57
|
-
|
|
58
|
-
gray: 0x808080,
|
|
59
|
-
grey: 0x808080,
|
|
60
|
-
silver: 0xc0c0c0,
|
|
61
|
-
maroon: 0x800000,
|
|
62
|
-
olive: 0x808000,
|
|
63
|
-
lime: 0x00ff00,
|
|
64
|
-
aqua: 0x00ffff,
|
|
65
|
-
teal: 0x008080,
|
|
66
|
-
navy: 0x000080,
|
|
67
|
-
fuchsia: 0xff00ff,
|
|
68
|
-
purple: 0x800080,
|
|
69
|
-
|
|
70
|
-
orange: 0xffa500,
|
|
71
|
-
pink: 0xffc0cb,
|
|
72
|
-
brown: 0xa52a2a,
|
|
73
|
-
gold: 0xffd700,
|
|
74
|
-
violet: 0xee82ee,
|
|
75
|
-
indigo: 0x4b0082,
|
|
76
|
-
coral: 0xff7f50,
|
|
77
|
-
salmon: 0xfa8072,
|
|
78
|
-
khaki: 0xf0e68c,
|
|
79
|
-
plum: 0xdda0dd,
|
|
80
|
-
orchid: 0xda70d6,
|
|
81
|
-
tan: 0xd2b48c,
|
|
82
|
-
beige: 0xf5f5dc,
|
|
83
|
-
mint: 0x98fb98,
|
|
84
|
-
lavender: 0xe6e6fa,
|
|
85
|
-
crimson: 0xdc143c,
|
|
86
|
-
azure: 0xf0ffff,
|
|
87
|
-
ivory: 0xfffff0,
|
|
88
|
-
snow: 0xfffafa,
|
|
89
|
-
};
|