laymur 0.11.3 → 0.11.5
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 +0 -1
- package/dist/constraints/{UIAspectConstraint.Internal.d.ts → UIAspectConstraint/UIAspectConstraint.Internal.d.ts} +1 -1
- package/dist/constraints/{UIAspectConstraint.d.ts → UIAspectConstraint/UIAspectConstraint.d.ts} +2 -2
- package/dist/constraints/{UIHeightConstraint.Internal.d.ts → UIHeightConstraint/UIHeightConstraint.Internal.d.ts} +1 -1
- package/dist/constraints/{UIHeightConstraint.d.ts → UIHeightConstraint/UIHeightConstraint.d.ts} +2 -2
- package/dist/constraints/{UIHorizontalDistanceConstraint.Internal.d.ts → UIHorizontalDistanceConstraint/UIHorizontalDistanceConstraint.Internal.d.ts} +1 -1
- package/dist/constraints/{UIHorizontalDistanceConstraint.d.ts → UIHorizontalDistanceConstraint/UIHorizontalDistanceConstraint.d.ts} +2 -2
- package/dist/constraints/UIHorizontalInterpolationConstraint/UIHorizontalInterpolationConstraint.Internal.d.ts +14 -0
- package/dist/constraints/UIHorizontalInterpolationConstraint/UIHorizontalInterpolationConstraint.d.ts +44 -0
- package/dist/constraints/{UIHorizontalProportionConstraint.Internal.d.ts → UIHorizontalProportionConstraint/UIHorizontalProportionConstraint.Internal.d.ts} +1 -1
- package/dist/constraints/{UIHorizontalProportionConstraint.d.ts → UIHorizontalProportionConstraint/UIHorizontalProportionConstraint.d.ts} +2 -2
- package/dist/constraints/{UIVerticalDistanceConstraint.Internal.d.ts → UIVerticalDistanceConstraint/UIVerticalDistanceConstraint.Internal.d.ts} +1 -1
- package/dist/constraints/{UIVerticalDistanceConstraint.d.ts → UIVerticalDistanceConstraint/UIVerticalDistanceConstraint.d.ts} +2 -2
- package/dist/constraints/UIVerticalInterpolationConstraint/UIVerticalInterpolationConstraint.Internal.d.ts +14 -0
- package/dist/constraints/UIVerticalInterpolationConstraint/UIVerticalInterpolationConstraint.d.ts +44 -0
- package/dist/constraints/{UIVerticalProportionConstraint.Internal.d.ts → UIVerticalProportionConstraint/UIVerticalProportionConstraint.Internal.d.ts} +1 -1
- package/dist/constraints/{UIVerticalProportionConstraint.d.ts → UIVerticalProportionConstraint/UIVerticalProportionConstraint.d.ts} +2 -2
- package/dist/constraints/{UIWidthConstraint.Internal.d.ts → UIWidthConstraint/UIWidthConstraint.Internal.d.ts} +1 -1
- package/dist/constraints/{UIWidthConstraint.d.ts → UIWidthConstraint/UIWidthConstraint.d.ts} +2 -2
- package/dist/constraints/builders/UIConstraint2DBuilder.Internal.d.ts +21 -2
- package/dist/constraints/builders/UIConstraint2DBuilder.d.ts +20 -9
- package/dist/constraints/builders/UICoverConstraintBuilder.d.ts +6 -6
- package/dist/constraints/builders/UIFitConstraintBuilder.d.ts +6 -6
- package/dist/elements/{UIAnchor.d.ts → UIAnchor/UIAnchor.d.ts} +3 -3
- package/dist/elements/{UIAnimatedImage.Internal.d.ts → UIAnimatedImage/UIAnimatedImage.Internal.d.ts} +2 -2
- package/dist/elements/{UIAnimatedImage.d.ts → UIAnimatedImage/UIAnimatedImage.d.ts} +6 -6
- package/dist/elements/UIElement/UIElement.Internal.d.ts +11 -0
- package/dist/elements/{UIElement.d.ts → UIElement/UIElement.d.ts} +9 -9
- package/dist/elements/{UIGraphics.Internal.d.ts → UIGraphics/UIGraphics.Internal.d.ts} +2 -2
- package/dist/elements/{UIGraphics.d.ts → UIGraphics/UIGraphics.d.ts} +3 -3
- package/dist/elements/{UIImage.Internal.d.ts → UIImage/UIImage.Internal.d.ts} +2 -2
- package/dist/elements/{UIImage.d.ts → UIImage/UIImage.d.ts} +6 -6
- package/dist/elements/{UIDummy.Internal.d.ts → UIInputDummy/UIInputDummy.Internal.d.ts} +5 -5
- package/dist/elements/{UIDummy.d.ts → UIInputDummy/UIInputDummy.d.ts} +11 -11
- package/dist/elements/{UINineSlice.Internal.d.ts → UINineSlice/UINineSlice.Internal.d.ts} +5 -5
- package/dist/elements/{UINineSlice.d.ts → UINineSlice/UINineSlice.d.ts} +9 -9
- package/dist/elements/{UIProgress.Internal.d.ts → UIProgress/UIProgress.Internal.d.ts} +3 -3
- package/dist/elements/{UIProgress.d.ts → UIProgress/UIProgress.d.ts} +10 -9
- package/dist/elements/{UIScene.Internal.d.ts → UIScene/UIScene.Internal.d.ts} +3 -3
- package/dist/elements/{UIScene.d.ts → UIScene/UIScene.d.ts} +3 -3
- package/dist/elements/UIText/UIText.Internal.d.ts +3 -3
- package/dist/elements/UIText/UIText.d.ts +3 -3
- package/dist/index.d.ts +19 -17
- package/dist/index.js +893 -295
- package/dist/index.js.map +1 -1
- package/dist/index.min.js +1 -1
- package/dist/index.min.js.map +1 -1
- package/dist/layers/UILayer.d.ts +1 -1
- package/dist/miscellaneous/asserts.d.ts +21 -54
- package/dist/miscellaneous/color/UIColor.d.ts +1 -0
- package/dist/miscellaneous/insets/UIInsets.Internal.d.ts +11 -0
- package/dist/miscellaneous/{padding/UIPadding.d.ts → insets/UIInsets.d.ts} +15 -15
- package/dist/miscellaneous/shared.d.ts +46 -0
- package/dist/miscellaneous/texture/UITextureView.d.ts +13 -9
- package/package.json +6 -3
- package/dist/elements/UIElement.Internal.d.ts +0 -11
- package/dist/miscellaneous/padding/UIPadding.Internal.d.ts +0 -11
- /package/dist/elements/{UIAnchor.Internal.d.ts → UIAnchor/UIAnchor.Internal.d.ts} +0 -0
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import type { UILayer } from "
|
|
2
|
-
import { UIColor } from "
|
|
3
|
-
import {
|
|
4
|
-
import { UITextureView } from "
|
|
5
|
-
import type { UITextureConfig } from "
|
|
6
|
-
import { UIElement } from "
|
|
1
|
+
import type { UILayer } from "../../layers/UILayer";
|
|
2
|
+
import { UIColor } from "../../miscellaneous/color/UIColor";
|
|
3
|
+
import { UIInsets } from "../../miscellaneous/insets/UIInsets";
|
|
4
|
+
import { UITextureView } from "../../miscellaneous/texture/UITextureView";
|
|
5
|
+
import type { UITextureConfig } from "../../miscellaneous/texture/UITextureView.Internal";
|
|
6
|
+
import { UIElement } from "../UIElement/UIElement";
|
|
7
7
|
import type { UINineSliceOptions } from "./UINineSlice.Internal";
|
|
8
8
|
import { UINineSliceRegionMode } from "./UINineSlice.Internal";
|
|
9
9
|
/** Scalable textured image preserving border regions */
|
|
@@ -13,9 +13,9 @@ export declare class UINineSlice extends UIElement {
|
|
|
13
13
|
/** Multiplicative tint. Alpha channel controls opacity. */
|
|
14
14
|
readonly color: UIColor;
|
|
15
15
|
/** Border size in normalized texture coordinates (0 to 1) */
|
|
16
|
-
readonly sliceBorders:
|
|
16
|
+
readonly sliceBorders: UIInsets;
|
|
17
17
|
/** Region size. Interpretation depends on regionMode. */
|
|
18
|
-
readonly sliceRegions:
|
|
18
|
+
readonly sliceRegions: UIInsets;
|
|
19
19
|
private regionModeInternal;
|
|
20
20
|
private regionModeDirty;
|
|
21
21
|
private readonly textureTransform;
|
|
@@ -37,7 +37,7 @@ export declare class UINineSlice extends UIElement {
|
|
|
37
37
|
get regionMode(): UINineSliceRegionMode;
|
|
38
38
|
/** Controls how sliceRegions values are interpreted */
|
|
39
39
|
set regionMode(value: UINineSliceRegionMode);
|
|
40
|
-
protected
|
|
40
|
+
protected setPlaneTransform(): void;
|
|
41
41
|
private calculateSliceBordersForShader;
|
|
42
42
|
private calculateSliceRegionsForShader;
|
|
43
43
|
private checkDimensionsDirty;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import type { UIColorConfig } from "
|
|
2
|
-
import type { UIProgressMaskFunction } from "
|
|
3
|
-
import type { UIElementOptions } from "
|
|
1
|
+
import type { UIColorConfig } from "../../miscellaneous/color/UIColor.Internal";
|
|
2
|
+
import type { UIProgressMaskFunction } from "../../miscellaneous/mask-function/UIProgressMaskFunction";
|
|
3
|
+
import type { UIElementOptions } from "../UIElement/UIElement.Internal";
|
|
4
4
|
/** Configuration options for UIProgress */
|
|
5
5
|
export interface UIProgressOptions extends UIElementOptions {
|
|
6
6
|
/** Multiplicative tint */
|
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import type
|
|
2
|
-
import type { UILayer } from "
|
|
3
|
-
import { UIColor } from "
|
|
4
|
-
import type { UIProgressMaskFunction } from "
|
|
5
|
-
import { UITextureView } from "
|
|
6
|
-
import { UIElement } from "
|
|
1
|
+
import { type Texture } from "three";
|
|
2
|
+
import type { UILayer } from "../../layers/UILayer";
|
|
3
|
+
import { UIColor } from "../../miscellaneous/color/UIColor";
|
|
4
|
+
import type { UIProgressMaskFunction } from "../../miscellaneous/mask-function/UIProgressMaskFunction";
|
|
5
|
+
import { UITextureView } from "../../miscellaneous/texture/UITextureView";
|
|
6
|
+
import { UIElement } from "../UIElement/UIElement";
|
|
7
7
|
import type { UIProgressOptions } from "./UIProgress.Internal";
|
|
8
8
|
/** Progress bar with customizable fill direction */
|
|
9
9
|
export declare class UIProgress extends UIElement {
|
|
@@ -16,7 +16,8 @@ export declare class UIProgress extends UIElement {
|
|
|
16
16
|
private readonly textureTransform;
|
|
17
17
|
private readonly textureResolution;
|
|
18
18
|
private progressInternal;
|
|
19
|
-
private
|
|
19
|
+
private progressDirty;
|
|
20
|
+
private textureResolutionDirty;
|
|
20
21
|
/**
|
|
21
22
|
* Creates a new UIProgress instance.
|
|
22
23
|
*
|
|
@@ -29,8 +30,8 @@ export declare class UIProgress extends UIElement {
|
|
|
29
30
|
constructor(layer: UILayer, texture: Texture, options?: Partial<UIProgressOptions>);
|
|
30
31
|
/** Progress from 0 (empty) to 1 (full) */
|
|
31
32
|
get progress(): number;
|
|
32
|
-
/** Progress from 0 (empty) to 1 (full). Clamped
|
|
33
|
+
/** Progress from 0 (empty) to 1 (full). Clamped. */
|
|
33
34
|
set progress(value: number);
|
|
34
|
-
protected
|
|
35
|
+
protected setPlaneTransform(): void;
|
|
35
36
|
private readonly onTextureDimensionsChanged;
|
|
36
37
|
}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import type { Camera, Scene } from "three";
|
|
2
|
-
import { UIColor } from "
|
|
3
|
-
import type { UIColorConfig } from "
|
|
4
|
-
import type { UIElementOptions } from "
|
|
2
|
+
import { UIColor } from "../../miscellaneous/color/UIColor";
|
|
3
|
+
import type { UIColorConfig } from "../../miscellaneous/color/UIColor.Internal";
|
|
4
|
+
import type { UIElementOptions } from "../UIElement/UIElement.Internal";
|
|
5
5
|
/** Controls when scene re-renders */
|
|
6
6
|
export declare enum UISceneUpdateMode {
|
|
7
7
|
/** Re-render every frame */
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import type { Camera, WebGLRenderer } from "three";
|
|
2
2
|
import { Scene } from "three";
|
|
3
|
-
import type { UILayer } from "
|
|
4
|
-
import { UIColor } from "
|
|
5
|
-
import { UIElement } from "
|
|
3
|
+
import type { UILayer } from "../../layers/UILayer";
|
|
4
|
+
import { UIColor } from "../../miscellaneous/color/UIColor";
|
|
5
|
+
import { UIElement } from "../UIElement/UIElement";
|
|
6
6
|
import type { UISceneOptions } from "./UIScene.Internal";
|
|
7
7
|
import { UISceneUpdateMode } from "./UIScene.Internal";
|
|
8
8
|
/** Renders Three.js scene to texture */
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import type { UIColorConfig } from "../../miscellaneous/color/UIColor.Internal";
|
|
2
|
-
import type {
|
|
2
|
+
import type { UIInsetsConfig } from "../../miscellaneous/insets/UIInsets.Internal";
|
|
3
3
|
import type { UITextStyleConfig } from "../../miscellaneous/text-style/UITextStyle.Internal";
|
|
4
|
-
import type { UIElementOptions } from "../UIElement.Internal";
|
|
4
|
+
import type { UIElementOptions } from "../UIElement/UIElement.Internal";
|
|
5
5
|
/** Controls how text adapts to element size */
|
|
6
6
|
export declare enum UITextResizeMode {
|
|
7
7
|
/** Break text into multiple lines when narrower than content*/
|
|
@@ -14,7 +14,7 @@ export interface UITextOptions extends UIElementOptions {
|
|
|
14
14
|
/** Multiplicative tint */
|
|
15
15
|
color: UIColorConfig;
|
|
16
16
|
/** Text padding in world units */
|
|
17
|
-
padding:
|
|
17
|
+
padding: UIInsetsConfig;
|
|
18
18
|
/** Default style applied to all spans */
|
|
19
19
|
commonStyle: Partial<UITextStyleConfig>;
|
|
20
20
|
/** How text adapts to size constraints */
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import type { WebGLRenderer } from "three";
|
|
2
2
|
import type { UILayer } from "../../layers/UILayer";
|
|
3
3
|
import { UIColor } from "../../miscellaneous/color/UIColor";
|
|
4
|
-
import {
|
|
4
|
+
import { UIInsets } from "../../miscellaneous/insets/UIInsets";
|
|
5
5
|
import { UITextSpan } from "../../miscellaneous/text-span/UITextSpan";
|
|
6
6
|
import { UITextStyle } from "../../miscellaneous/text-style/UITextStyle";
|
|
7
|
-
import { UIElement } from "../UIElement";
|
|
7
|
+
import { UIElement } from "../UIElement/UIElement";
|
|
8
8
|
import type { UITextContent } from "./UIText.Interfaces";
|
|
9
9
|
import type { UITextOptions } from "./UIText.Internal";
|
|
10
10
|
import { UITextResizeMode } from "./UIText.Internal";
|
|
@@ -13,7 +13,7 @@ export declare class UIText extends UIElement {
|
|
|
13
13
|
/** Multiplicative tint. Alpha channel controls opacity. */
|
|
14
14
|
readonly color: UIColor;
|
|
15
15
|
/** Text padding in world units */
|
|
16
|
-
readonly padding:
|
|
16
|
+
readonly padding: UIInsets;
|
|
17
17
|
/** Default style applied to all text spans */
|
|
18
18
|
readonly commonStyle: UITextStyle;
|
|
19
19
|
private readonly canvas;
|
package/dist/index.d.ts
CHANGED
|
@@ -1,25 +1,27 @@
|
|
|
1
1
|
export { UIConstraint2DBuilder } from "./constraints/builders/UIConstraint2DBuilder";
|
|
2
2
|
export { UICoverConstraintBuilder } from "./constraints/builders/UICoverConstraintBuilder";
|
|
3
3
|
export { UIFitConstraintBuilder } from "./constraints/builders/UIFitConstraintBuilder";
|
|
4
|
-
export { UIAspectConstraint } from "./constraints/UIAspectConstraint";
|
|
4
|
+
export { UIAspectConstraint } from "./constraints/UIAspectConstraint/UIAspectConstraint";
|
|
5
5
|
export { UICustomConstraint } from "./constraints/UICustomConstraint";
|
|
6
|
-
export { UIHeightConstraint } from "./constraints/UIHeightConstraint";
|
|
7
|
-
export { UIHorizontalDistanceConstraint } from "./constraints/UIHorizontalDistanceConstraint";
|
|
8
|
-
export {
|
|
6
|
+
export { UIHeightConstraint } from "./constraints/UIHeightConstraint/UIHeightConstraint";
|
|
7
|
+
export { UIHorizontalDistanceConstraint } from "./constraints/UIHorizontalDistanceConstraint/UIHorizontalDistanceConstraint";
|
|
8
|
+
export { UIHorizontalInterpolationConstraint } from "./constraints/UIHorizontalInterpolationConstraint/UIHorizontalInterpolationConstraint";
|
|
9
|
+
export { UIHorizontalProportionConstraint } from "./constraints/UIHorizontalProportionConstraint/UIHorizontalProportionConstraint";
|
|
9
10
|
export { UISingleParameterConstraint } from "./constraints/UISingleParameterConstraint";
|
|
10
|
-
export { UIVerticalDistanceConstraint } from "./constraints/UIVerticalDistanceConstraint";
|
|
11
|
-
export {
|
|
12
|
-
export {
|
|
13
|
-
export {
|
|
14
|
-
export {
|
|
15
|
-
export {
|
|
16
|
-
export { UIGraphics } from "./elements/UIGraphics";
|
|
17
|
-
export { UIImage } from "./elements/UIImage";
|
|
18
|
-
export {
|
|
19
|
-
export {
|
|
20
|
-
export {
|
|
21
|
-
export {
|
|
22
|
-
export {
|
|
11
|
+
export { UIVerticalDistanceConstraint } from "./constraints/UIVerticalDistanceConstraint/UIVerticalDistanceConstraint";
|
|
12
|
+
export { UIVerticalInterpolationConstraint } from "./constraints/UIVerticalInterpolationConstraint/UIVerticalInterpolationConstraint";
|
|
13
|
+
export { UIVerticalProportionConstraint } from "./constraints/UIVerticalProportionConstraint/UIVerticalProportionConstraint";
|
|
14
|
+
export { UIWidthConstraint } from "./constraints/UIWidthConstraint/UIWidthConstraint";
|
|
15
|
+
export { UIAnchor } from "./elements/UIAnchor/UIAnchor";
|
|
16
|
+
export { UIAnimatedImage } from "./elements/UIAnimatedImage/UIAnimatedImage";
|
|
17
|
+
export { UIGraphics } from "./elements/UIGraphics/UIGraphics";
|
|
18
|
+
export { UIImage } from "./elements/UIImage/UIImage";
|
|
19
|
+
export { UIInputDummy } from "./elements/UIInputDummy/UIInputDummy";
|
|
20
|
+
export { UINineSlice } from "./elements/UINineSlice/UINineSlice";
|
|
21
|
+
export { UINineSliceRegionMode } from "./elements/UINineSlice/UINineSlice.Internal";
|
|
22
|
+
export { UIProgress } from "./elements/UIProgress/UIProgress";
|
|
23
|
+
export { UIScene } from "./elements/UIScene/UIScene";
|
|
24
|
+
export { UISceneUpdateMode } from "./elements/UIScene/UIScene.Internal";
|
|
23
25
|
export { UIText } from "./elements/UIText/UIText";
|
|
24
26
|
export { UITextResizeMode } from "./elements/UIText/UIText.Internal";
|
|
25
27
|
export { UIFullscreenLayer } from "./layers/UIFullscreenLayer";
|