@dcl/react-ecs 7.0.6-3987590195.commit-4fc1536 → 7.0.6-3999809037.commit-0a47a3c

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.
@@ -2,6 +2,6 @@ import { UiLabelProps } from '../Label/types';
2
2
  /**
3
3
  * @public
4
4
  */
5
- export declare type UiButtonProps = UiLabelProps & {
5
+ export type UiButtonProps = UiLabelProps & {
6
6
  type?: 'primary' | 'secondary';
7
7
  };
@@ -3,7 +3,7 @@ import { TextAlignType, UiFontType } from '../Label/types';
3
3
  /**
4
4
  * @public
5
5
  */
6
- export declare type UiDropdownProps = Partial<Omit<PBUiDropdown, 'textAlign' | 'font'>> & {
6
+ export type UiDropdownProps = Partial<Omit<PBUiDropdown, 'textAlign' | 'font'>> & {
7
7
  onChange?(value: number): void;
8
8
  font?: UiFontType;
9
9
  textAlign?: TextAlignType;
@@ -3,7 +3,7 @@ import { TextAlignType, UiFontType } from '../Label/types';
3
3
  /**
4
4
  * @public
5
5
  */
6
- export declare type UiInputProps = Omit<PBUiInput, 'font' | 'textAlign'> & {
6
+ export type UiInputProps = Omit<PBUiInput, 'font' | 'textAlign'> & {
7
7
  onChange?(value: string): void;
8
8
  font?: UiFontType;
9
9
  textAlign?: TextAlignType;
@@ -2,7 +2,7 @@ import { PBUiText } from '@dcl/ecs';
2
2
  /**
3
3
  * @public
4
4
  */
5
- export declare type UiLabelProps = Omit<PBUiText, 'textAlign' | 'font'> & {
5
+ export type UiLabelProps = Omit<PBUiText, 'textAlign' | 'font'> & {
6
6
  /** default='middle-center' */
7
7
  textAlign?: TextAlignType | undefined;
8
8
  /** default='sans-serif' */
@@ -11,8 +11,8 @@ export declare type UiLabelProps = Omit<PBUiText, 'textAlign' | 'font'> & {
11
11
  /**
12
12
  * @public
13
13
  */
14
- export declare type UiFontType = 'sans-serif' | 'serif' | 'monospace';
14
+ export type UiFontType = 'sans-serif' | 'serif' | 'monospace';
15
15
  /**
16
16
  * @public
17
17
  */
18
- export declare type TextAlignType = 'top-left' | 'top-center' | 'top-right' | 'middle-left' | 'middle-center' | 'middle-right' | 'bottom-left' | 'bottom-center' | 'bottom-right';
18
+ export type TextAlignType = 'top-left' | 'top-center' | 'top-right' | 'middle-left' | 'middle-center' | 'middle-right' | 'bottom-left' | 'bottom-center' | 'bottom-right';
@@ -1,5 +1,5 @@
1
- export declare type Callback = () => void;
2
- export declare type Listeners = {
1
+ export type Callback = () => void;
2
+ export type Listeners = {
3
3
  onMouseDown?: Callback;
4
4
  onMouseUp?: Callback;
5
5
  };
@@ -4,13 +4,13 @@ import { UiTransformProps } from './uiTransform/types';
4
4
  /**
5
5
  * @public
6
6
  */
7
- export declare type EntityPropTypes = {
7
+ export type EntityPropTypes = {
8
8
  uiTransform?: UiTransformProps;
9
9
  uiBackground?: UiBackgroundProps;
10
10
  } & Listeners & Pick<CommonProps, 'key'>;
11
- export declare type Key = number | string;
12
- export declare type Children = unknown;
13
- export declare type CommonProps = {
11
+ export type Key = number | string;
12
+ export type Children = unknown;
13
+ export type CommonProps = {
14
14
  key?: Key;
15
15
  children?: Children;
16
16
  };
@@ -3,7 +3,7 @@ import { Color4 } from '@dcl/ecs/dist/components/generated/pb/decentraland/commo
3
3
  /**
4
4
  * @public
5
5
  */
6
- export declare type UiBackgroundProps = {
6
+ export type UiBackgroundProps = {
7
7
  color?: Color4 | undefined;
8
8
  textureMode?: TextureMode;
9
9
  textureSlices?: BorderRect | undefined;
@@ -12,11 +12,11 @@ export declare type UiBackgroundProps = {
12
12
  /**
13
13
  * @public
14
14
  */
15
- export declare type UiTextureUnion = UiAvatarTexture | UiTexture;
15
+ export type UiTextureUnion = UiAvatarTexture | UiTexture;
16
16
  /**
17
17
  * @public
18
18
  */
19
- export declare type UiAvatarTexture = {
19
+ export type UiAvatarTexture = {
20
20
  avatarTexture?: {
21
21
  userId: string;
22
22
  wrapMode?: TextureWrapType;
@@ -26,7 +26,7 @@ export declare type UiAvatarTexture = {
26
26
  /**
27
27
  * @public
28
28
  */
29
- export declare type UiTexture = {
29
+ export type UiTexture = {
30
30
  texture?: {
31
31
  src: string;
32
32
  wrapMode?: TextureWrapType;
@@ -36,11 +36,11 @@ export declare type UiTexture = {
36
36
  /**
37
37
  * @public
38
38
  */
39
- export declare type TextureWrapType = 'repeat' | 'clamp' | 'mirror' | 'mirror-once';
39
+ export type TextureWrapType = 'repeat' | 'clamp' | 'mirror' | 'mirror-once';
40
40
  /**
41
41
  * @public
42
42
  */
43
- export declare type TextureFilterType = 'point' | 'bi-linear' | 'tri-linear';
43
+ export type TextureFilterType = 'point' | 'bi-linear' | 'tri-linear';
44
44
  /**
45
45
  * @public
46
46
  * NINE_SLICES - https://docs.unity3d.com/Manual/UIE-USS-SupportedProperties.html (Slicing section)
@@ -55,4 +55,4 @@ export declare type TextureFilterType = 'point' | 'bi-linear' | 'tri-linear';
55
55
  * STRETCH - STRETCH enables the texture to cover all the area of the container,
56
56
  * adopting its aspect ratio.
57
57
  */
58
- export declare type TextureMode = 'nine-slices' | 'center' | 'stretch';
58
+ export type TextureMode = 'nine-slices' | 'center' | 'stretch';
@@ -1,8 +1,8 @@
1
- export declare type PositionUnit = `${number}px` | `${number}%` | number;
1
+ export type PositionUnit = `${number}px` | `${number}%` | number;
2
2
  /**
3
3
  * @public
4
4
  */
5
- export declare type Position = {
5
+ export type Position = {
6
6
  top: PositionUnit;
7
7
  right: PositionUnit;
8
8
  bottom: PositionUnit;
@@ -11,31 +11,31 @@ export declare type Position = {
11
11
  /**
12
12
  * @public
13
13
  */
14
- export declare type DisplayType = 'flex' | 'none';
14
+ export type DisplayType = 'flex' | 'none';
15
15
  /**
16
16
  * @public
17
17
  */
18
- export declare type JustifyType = 'flex-start' | 'center' | 'flex-end' | 'space-between' | 'space-around' | 'space-evenly';
18
+ export type JustifyType = 'flex-start' | 'center' | 'flex-end' | 'space-between' | 'space-around' | 'space-evenly';
19
19
  /**
20
20
  * @public
21
21
  */
22
- export declare type AlignType = 'auto' | 'flex-start' | 'center' | 'flex-end' | 'stretch' | 'baseline' | 'space-between' | 'space-around';
22
+ export type AlignType = 'auto' | 'flex-start' | 'center' | 'flex-end' | 'stretch' | 'baseline' | 'space-between' | 'space-around';
23
23
  /**
24
24
  * @public
25
25
  */
26
- export declare type FlexDirectionType = 'row' | 'column' | 'column-reverse' | 'row-reverse';
26
+ export type FlexDirectionType = 'row' | 'column' | 'column-reverse' | 'row-reverse';
27
27
  /**
28
28
  * @public
29
29
  */
30
- export declare type FlexWrapType = 'wrap' | 'nowrap' | 'wrap-reverse';
30
+ export type FlexWrapType = 'wrap' | 'nowrap' | 'wrap-reverse';
31
31
  /**
32
32
  * @public
33
33
  */
34
- export declare type OverflowType = 'hidden' | 'scroll' | 'visible';
34
+ export type OverflowType = 'hidden' | 'scroll' | 'visible';
35
35
  /**
36
36
  * @public
37
37
  */
38
- export declare type PositionType = 'absolute' | 'relative';
38
+ export type PositionType = 'absolute' | 'relative';
39
39
  /**
40
40
  * @public
41
41
  */
@@ -1,18 +1,18 @@
1
1
  import { YGUnit } from '@dcl/ecs';
2
2
  import { Position, PositionUnit } from './types';
3
- declare type PropName = 'position' | 'margin' | 'padding';
4
- declare type PropKey = `${PropName}${Capitalize<keyof Position>}`;
5
- declare type PropKeyUnit = `${PropName}${Capitalize<keyof Position>}Unit`;
6
- declare type PositionParsed = {
3
+ type PropName = 'position' | 'margin' | 'padding';
4
+ type PropKey = `${PropName}${Capitalize<keyof Position>}`;
5
+ type PropKeyUnit = `${PropName}${Capitalize<keyof Position>}Unit`;
6
+ type PositionParsed = {
7
7
  [key in PropKey]?: number;
8
8
  } & {
9
9
  [key in PropKeyUnit]?: YGUnit;
10
10
  };
11
11
  export declare function parsePosition<T extends PropName>(position: Partial<Position> | undefined, prop: T): Partial<PositionParsed>;
12
- declare type HeightWidth = 'height' | 'width';
13
- declare type SizePropName = HeightWidth | `max${Capitalize<HeightWidth>}` | `min${Capitalize<HeightWidth>}`;
14
- declare type SizePropKeyUnit = `${SizePropName}Unit`;
15
- declare type SizeReturnType = {
12
+ type HeightWidth = 'height' | 'width';
13
+ type SizePropName = HeightWidth | `max${Capitalize<HeightWidth>}` | `min${Capitalize<HeightWidth>}`;
14
+ type SizePropKeyUnit = `${SizePropName}Unit`;
15
+ type SizeReturnType = {
16
16
  [key in SizePropName]: number;
17
17
  } & {
18
18
  [key in SizePropKeyUnit]: YGUnit;
@@ -1,10 +1,10 @@
1
1
  import { PBUiBackground, PBUiText, PBUiTransform, PBUiInput, PBUiDropdown } from '@dcl/ecs';
2
2
  import { Callback } from './components';
3
3
  import { CommonProps } from './components/types';
4
- export declare type EcsElements = {
4
+ export type EcsElements = {
5
5
  entity: Partial<EntityComponents & CommonProps>;
6
6
  };
7
- export declare type EntityComponents = {
7
+ export type EntityComponents = {
8
8
  uiTransform: PBUiTransform;
9
9
  uiText: PBUiText;
10
10
  uiBackground: PBUiBackground;
@@ -1,27 +1,27 @@
1
1
  import type { Entity } from '@dcl/ecs';
2
2
  import { CommonProps, Listeners } from '../components';
3
3
  import type { EntityComponents } from '../react-ecs';
4
- export declare type EngineComponents = Omit<EntityComponents, keyof Listeners>;
5
- export declare type OpaqueHandle = any;
6
- export declare type Type = 'entity';
7
- export declare type Props = EntityComponents & CommonProps;
8
- export declare type Container = Document | Instance | any;
9
- export declare type Instance = {
4
+ export type EngineComponents = Omit<EntityComponents, keyof Listeners>;
5
+ export type OpaqueHandle = any;
6
+ export type Type = 'entity';
7
+ export type Props = EntityComponents & CommonProps;
8
+ export type Container = Document | Instance | any;
9
+ export type Instance = {
10
10
  entity: Entity;
11
11
  parent?: Entity;
12
12
  rightOf?: Entity;
13
13
  _child: Instance[];
14
14
  };
15
- export declare type TextInstance = never;
16
- export declare type SuspenseInstance = never;
17
- export declare type HydratableInstance = never;
18
- export declare type PublicInstance = Instance;
19
- export declare type HostContext = null;
20
- export declare type UpdatePayload = Changes[];
21
- export declare type _ChildSet = never;
22
- export declare type TimeoutHandle = any;
23
- export declare type NoTimeout = number;
24
- export declare type Changes<K extends keyof EntityComponents = keyof EntityComponents> = {
15
+ export type TextInstance = never;
16
+ export type SuspenseInstance = never;
17
+ export type HydratableInstance = never;
18
+ export type PublicInstance = Instance;
19
+ export type HostContext = null;
20
+ export type UpdatePayload = Changes[];
21
+ export type _ChildSet = never;
22
+ export type TimeoutHandle = any;
23
+ export type NoTimeout = number;
24
+ export type Changes<K extends keyof EntityComponents = keyof EntityComponents> = {
25
25
  type: 'delete' | 'add' | 'put';
26
26
  props?: Partial<EntityComponents[K]>;
27
27
  component: K;
package/dist/system.d.ts CHANGED
@@ -1,7 +1,7 @@
1
1
  import type { IEngine, PointerEventsSystem } from '@dcl/ecs';
2
2
  import type { JSX } from './react-ecs';
3
- export declare type UiComponent = () => JSX.Element;
4
- export declare type ReactBasedUiSystem = {
3
+ export type UiComponent = () => JSX.Element;
4
+ export type ReactBasedUiSystem = {
5
5
  destroy(): void;
6
6
  setUiRenderer(ui: UiComponent): void;
7
7
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@dcl/react-ecs",
3
- "version": "7.0.6-3987590195.commit-4fc1536",
3
+ "version": "7.0.6-3999809037.commit-0a47a3c",
4
4
  "description": "Decentraland ECS",
5
5
  "main": "./dist/index.js",
6
6
  "types": "./dist/index.d.ts",
@@ -42,5 +42,5 @@
42
42
  "displayName": "React ECS",
43
43
  "tsconfig": "./tsconfig.json"
44
44
  },
45
- "commit": "4fc1536e9bdd2501b3d9918ec7345084f7a49aca"
45
+ "commit": "0a47a3c6e7e075d98d04c5ceab1eb8185c70bd9c"
46
46
  }