laymur 0.11.3 → 0.11.4
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/builders/UIConstraint2DBuilder.d.ts +1 -1
- 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/UIGraphics.Internal.d.ts +9 -0
- package/dist/elements/{UIGraphics.d.ts → UIGraphics/UIGraphics.d.ts} +4 -4
- package/dist/elements/UIImage/UIImage.Internal.d.ts +9 -0
- package/dist/elements/{UIImage.d.ts → UIImage/UIImage.d.ts} +7 -7
- 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} +5 -3
- package/dist/elements/{UIProgress.d.ts → UIProgress/UIProgress.d.ts} +8 -7
- 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 +10 -10
- package/dist/index.js +290 -179
- package/dist/index.js.map +1 -1
- package/dist/index.min.js +1 -1
- package/dist/index.min.js.map +1 -1
- 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/texture/UITextureView.d.ts +13 -9
- package/package.json +1 -1
- package/dist/elements/UIElement.Internal.d.ts +0 -11
- package/dist/elements/UIGraphics.Internal.d.ts +0 -7
- package/dist/elements/UIImage.Internal.d.ts +0 -7
- package/dist/miscellaneous/padding/UIPadding.Internal.d.ts +0 -11
- /package/dist/elements/{UIAnchor.Internal.d.ts → UIAnchor/UIAnchor.Internal.d.ts} +0 -0
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
/** Insets configuration as number, per-side, or per-axis */
|
|
2
|
+
export type UIInsetsConfig = {
|
|
3
|
+
horizontal: number;
|
|
4
|
+
vertical: number;
|
|
5
|
+
} | {
|
|
6
|
+
left: number;
|
|
7
|
+
right: number;
|
|
8
|
+
top: number;
|
|
9
|
+
bottom: number;
|
|
10
|
+
} | number;
|
|
11
|
+
export declare const INSETS_DEFAULT_VALUE = 0;
|
|
@@ -1,33 +1,33 @@
|
|
|
1
1
|
import { Vector4 } from "three";
|
|
2
|
-
import type {
|
|
3
|
-
/**
|
|
4
|
-
export declare class
|
|
2
|
+
import type { UIInsetsConfig } from "./UIInsets.Internal";
|
|
3
|
+
/** Insets values for four sides */
|
|
4
|
+
export declare class UIInsets {
|
|
5
5
|
private lInternal;
|
|
6
6
|
private rInternal;
|
|
7
7
|
private tInternal;
|
|
8
8
|
private bInternal;
|
|
9
9
|
private dirtyInternal;
|
|
10
10
|
/**
|
|
11
|
-
* Creates
|
|
11
|
+
* Creates UIInsets instance.
|
|
12
12
|
*
|
|
13
|
-
* @param config -
|
|
13
|
+
* @param config - Insets configuration
|
|
14
14
|
*/
|
|
15
|
-
constructor(config?:
|
|
16
|
-
/** Left
|
|
15
|
+
constructor(config?: UIInsetsConfig);
|
|
16
|
+
/** Left inset */
|
|
17
17
|
get left(): number;
|
|
18
|
-
/** Right
|
|
18
|
+
/** Right inset */
|
|
19
19
|
get right(): number;
|
|
20
|
-
/** Top
|
|
20
|
+
/** Top inset */
|
|
21
21
|
get top(): number;
|
|
22
|
-
/** Bottom
|
|
22
|
+
/** Bottom inset */
|
|
23
23
|
get bottom(): number;
|
|
24
|
-
/** Left
|
|
24
|
+
/** Left inset */
|
|
25
25
|
set left(value: number);
|
|
26
|
-
/** Right
|
|
26
|
+
/** Right inset */
|
|
27
27
|
set right(value: number);
|
|
28
|
-
/** Top
|
|
28
|
+
/** Top inset */
|
|
29
29
|
set top(value: number);
|
|
30
|
-
/** Bottom
|
|
30
|
+
/** Bottom inset */
|
|
31
31
|
set bottom(value: number);
|
|
32
32
|
/** Sets left and right to same value */
|
|
33
33
|
setHorizontal(value: number): void;
|
|
@@ -42,5 +42,5 @@ export declare class UIPadding {
|
|
|
42
42
|
/** Resets all sides to 0 */
|
|
43
43
|
reset(): void;
|
|
44
44
|
/** Copies from another instance */
|
|
45
|
-
copy(other:
|
|
45
|
+
copy(other: UIInsets): void;
|
|
46
46
|
}
|
|
@@ -4,19 +4,21 @@ import type { UITextureConfig, UITextureTrim } from "./UITextureView.Internal";
|
|
|
4
4
|
/** Wrapper for Three.js texture with atlas and trim support. Does not own the underlying texture; user must dispose it. */
|
|
5
5
|
export declare class UITextureView extends Eventail {
|
|
6
6
|
private textureInternal;
|
|
7
|
-
private
|
|
7
|
+
private sourceWidth;
|
|
8
|
+
private sourceHeight;
|
|
8
9
|
private frameX;
|
|
9
10
|
private frameY;
|
|
10
11
|
private frameWidth;
|
|
11
12
|
private frameHeight;
|
|
12
|
-
private
|
|
13
|
-
private
|
|
13
|
+
private rotatedInternal;
|
|
14
|
+
private scaleInternal;
|
|
14
15
|
private trimLeft;
|
|
15
16
|
private trimRight;
|
|
16
17
|
private trimTop;
|
|
17
18
|
private trimBottom;
|
|
18
|
-
private
|
|
19
|
-
private
|
|
19
|
+
private textureDirtyInternal;
|
|
20
|
+
private uvTransformDirtyInternal;
|
|
21
|
+
private trimDirtyInternal;
|
|
20
22
|
/** @param config Texture or atlas configuration */
|
|
21
23
|
constructor(config?: UITextureConfig);
|
|
22
24
|
/** Original width before trimming in world units */
|
|
@@ -35,8 +37,12 @@ export declare class UITextureView extends Eventail {
|
|
|
35
37
|
get scale(): number;
|
|
36
38
|
/** Transparent padding around visible content */
|
|
37
39
|
get trim(): Readonly<UITextureTrim>;
|
|
38
|
-
|
|
39
|
-
|
|
40
|
+
get textureDirty(): boolean;
|
|
41
|
+
/** Whether UV transform inputs changed since last check */
|
|
42
|
+
get uvTransformDirty(): boolean;
|
|
43
|
+
/** Whether trim values changed since last check */
|
|
44
|
+
get trimDirty(): boolean;
|
|
45
|
+
setTextureDirtyFalse(): void;
|
|
40
46
|
/**
|
|
41
47
|
* Calculates UV transform matrix for shader sampling.
|
|
42
48
|
* @param result Matrix to store result in
|
|
@@ -54,8 +60,6 @@ export declare class UITextureView extends Eventail {
|
|
|
54
60
|
* @param config Texture or atlas configuration
|
|
55
61
|
*/
|
|
56
62
|
set(config: UITextureConfig): void;
|
|
57
|
-
/** Resets to default empty texture */
|
|
58
|
-
reset(): void;
|
|
59
63
|
private setFromTexture;
|
|
60
64
|
private setFromAtlasConfig;
|
|
61
65
|
}
|
package/package.json
CHANGED
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
import type { UIMicroConfig } from "../miscellaneous/micro/UIMicro.Internal";
|
|
2
|
-
import { UITransparencyMode } from "../miscellaneous/UITransparencyMode";
|
|
3
|
-
import type { UIDummyOptions } from "./UIDummy.Internal";
|
|
4
|
-
/** Configuration options for UIElement */
|
|
5
|
-
export interface UIElementOptions extends UIDummyOptions {
|
|
6
|
-
/** Transforms that don't affect constraints */
|
|
7
|
-
micro: UIMicroConfig;
|
|
8
|
-
/** Alpha blending mode */
|
|
9
|
-
transparencyMode: UITransparencyMode;
|
|
10
|
-
}
|
|
11
|
-
export declare const ELEMENT_DEFAULT_TRANSPARENCY_MODE = UITransparencyMode.BLEND;
|
|
@@ -1,7 +0,0 @@
|
|
|
1
|
-
import type { UIColorConfig } from "../miscellaneous/color/UIColor.Internal";
|
|
2
|
-
import type { UIElementOptions } from "./UIElement.Internal";
|
|
3
|
-
/** Configuration options for UIGraphics */
|
|
4
|
-
export interface UIGraphicsOptions extends UIElementOptions {
|
|
5
|
-
/** Multiplicative tint */
|
|
6
|
-
color: UIColorConfig;
|
|
7
|
-
}
|
|
@@ -1,7 +0,0 @@
|
|
|
1
|
-
import type { UIColorConfig } from "../miscellaneous/color/UIColor.Internal";
|
|
2
|
-
import type { UIElementOptions } from "./UIElement.Internal";
|
|
3
|
-
/** Configuration options for UIImage */
|
|
4
|
-
export interface UIImageOptions extends UIElementOptions {
|
|
5
|
-
/** Multiplicative tint */
|
|
6
|
-
color: UIColorConfig;
|
|
7
|
-
}
|
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
/** Padding configuration as number, per-side, or per-axis */
|
|
2
|
-
export type UIPaddingConfig = {
|
|
3
|
-
horizontal: number;
|
|
4
|
-
vertical: number;
|
|
5
|
-
} | {
|
|
6
|
-
left: number;
|
|
7
|
-
right: number;
|
|
8
|
-
top: number;
|
|
9
|
-
bottom: number;
|
|
10
|
-
} | number;
|
|
11
|
-
export declare const PADDING_DEFAULT_VALUE = 0;
|
|
File without changes
|