@reactunity/renderer 0.13.2 → 0.14.0
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/dist/src/helpers/icons.d.ts +2 -2
- package/dist/src/models/base.d.ts +8 -8
- package/dist/src/models/editor/components.d.ts +2 -2
- package/dist/src/models/editor/events.d.ts +4 -4
- package/dist/src/models/editor/jsx.d.ts +5 -5
- package/dist/src/models/environment/dom/common.d.ts +5 -5
- package/dist/src/models/environment/dom/fetch.d.ts +10 -10
- package/dist/src/models/environment/dom/xhr.d.ts +2 -2
- package/dist/src/models/environment/interop.d.ts +2 -2
- package/dist/src/models/generated/editor.d.ts +15016 -11979
- package/dist/src/models/generated/editor.js +1 -1
- package/dist/src/models/generated/react.d.ts +1336 -417
- package/dist/src/models/generated/react.js +1 -1
- package/dist/src/models/generated/system.d.ts +2602 -2704
- package/dist/src/models/generated/system.js +2 -2
- package/dist/src/models/generated/tests.d.ts +228 -231
- package/dist/src/models/generated/tests.js +1 -1
- package/dist/src/models/generated/unity.d.ts +7998 -14519
- package/dist/src/models/generated/unity.js +2 -2
- package/dist/src/models/generated/yoga.d.ts +1 -1
- package/dist/src/models/generated/yoga.js +1 -1
- package/dist/src/models/properties/colors.d.ts +1 -1
- package/dist/src/models/properties/style.d.ts +7 -2
- package/dist/src/models/properties/styles-enums.d.ts +24 -19
- package/dist/src/models/properties/styles.d.ts +76 -60
- package/dist/src/models/properties/values.d.ts +16 -16
- package/dist/src/models/properties/yoga-enums.d.ts +8 -8
- package/dist/src/models/properties/yoga.d.ts +16 -16
- package/dist/src/models/renderer.d.ts +14 -14
- package/dist/src/models/richtext.d.ts +2 -2
- package/dist/src/models/svg.d.ts +2 -2
- package/dist/src/models/ugui/components.d.ts +1 -1
- package/dist/src/models/ugui/events.d.ts +7 -7
- package/dist/src/models/ugui/input.d.ts +6 -6
- package/dist/src/models/ugui/jsx.d.ts +2 -2
- package/dist/src/models/uitoolkit/components.d.ts +2 -2
- package/dist/src/models/uitoolkit/events.d.ts +4 -4
- package/dist/src/models/uitoolkit/jsx.d.ts +2 -2
- package/dist/src/renderer/async/commands.d.ts +14 -14
- package/dist/src/renderer/async/types.d.ts +10 -10
- package/dist/src/renderer/diffing.d.ts +1 -1
- package/dist/src/version.d.ts +1 -1
- package/dist/src/version.js +1 -1
- package/package.json +5 -5
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
export
|
|
1
|
+
export type BatchUpdateProps = {
|
|
2
2
|
[key: string]: string | number | object;
|
|
3
3
|
};
|
|
4
|
-
export
|
|
5
|
-
export
|
|
4
|
+
export type AsyncCallback = (...args: any[]) => any;
|
|
5
|
+
export type BatchUpdateCallbacks = {
|
|
6
6
|
[key: string]: number;
|
|
7
7
|
};
|
|
8
|
-
|
|
8
|
+
type ApplyUpdatesParams = {
|
|
9
9
|
t: string;
|
|
10
10
|
r: number;
|
|
11
11
|
c?: string;
|
|
@@ -13,35 +13,35 @@ declare type ApplyUpdatesParams = {
|
|
|
13
13
|
e?: BatchUpdateCallbacks;
|
|
14
14
|
o?: BatchUpdateCallbacks;
|
|
15
15
|
};
|
|
16
|
-
export
|
|
16
|
+
export type CreateInstanceCommand = ['c', ApplyUpdatesParams & {
|
|
17
17
|
k?: string;
|
|
18
18
|
}];
|
|
19
|
-
export
|
|
19
|
+
export type CreateTextInstanceCommand = ['t', {
|
|
20
20
|
r: number;
|
|
21
21
|
c?: string;
|
|
22
22
|
}];
|
|
23
|
-
export
|
|
23
|
+
export type AppendChildCommand = ['a', {
|
|
24
24
|
p: number;
|
|
25
25
|
c: number;
|
|
26
26
|
}];
|
|
27
|
-
export
|
|
27
|
+
export type RemoveChildCommand = ['r', {
|
|
28
28
|
p: number;
|
|
29
29
|
c: number;
|
|
30
30
|
}];
|
|
31
|
-
export
|
|
31
|
+
export type InsertChildCommand = ['i', {
|
|
32
32
|
p: number;
|
|
33
33
|
c: number;
|
|
34
34
|
i?: number;
|
|
35
35
|
}];
|
|
36
|
-
export
|
|
37
|
-
export
|
|
36
|
+
export type ApplyUpdatesCommand = ['u', ApplyUpdatesParams];
|
|
37
|
+
export type TextUpdateCommand = ['x', {
|
|
38
38
|
r: number;
|
|
39
39
|
c: string;
|
|
40
40
|
}];
|
|
41
|
-
export
|
|
41
|
+
export type ToggleHideCommand = ['h', {
|
|
42
42
|
r: number;
|
|
43
43
|
h: boolean;
|
|
44
44
|
}];
|
|
45
|
-
export
|
|
46
|
-
export
|
|
45
|
+
export type ClearContainerCommand = ['o'];
|
|
46
|
+
export type BatchCommand = CreateInstanceCommand | CreateTextInstanceCommand | AppendChildCommand | RemoveChildCommand | InsertChildCommand | ApplyUpdatesCommand | TextUpdateCommand | ToggleHideCommand | ClearContainerCommand | null;
|
|
47
47
|
export {};
|
|
@@ -3,31 +3,31 @@ import { ReactUnity } from '../../models/generated';
|
|
|
3
3
|
import { ChildSet, HydratableInstance, InstanceTag, NoTimeout, Props, TimeoutHandle, UpdatePayload } from '../../models/renderer';
|
|
4
4
|
import { BatchCommand } from './commands';
|
|
5
5
|
import { ObjectsRepo } from './objects';
|
|
6
|
-
export
|
|
7
|
-
export
|
|
8
|
-
export
|
|
6
|
+
export type AsyncHostContext = AsyncNativeInstance | AsyncSubContext;
|
|
7
|
+
export type AsyncInstance = AsyncNativeInstance | AsyncSubContext;
|
|
8
|
+
export type AsyncNativeInstance = {
|
|
9
9
|
context: ReactUnity.ReactContext;
|
|
10
10
|
commands: BatchCommand[];
|
|
11
11
|
refId: number;
|
|
12
12
|
type: 'native';
|
|
13
13
|
subContext?: AsyncSubContext;
|
|
14
14
|
};
|
|
15
|
-
export
|
|
16
|
-
export
|
|
15
|
+
export type AsyncSubContext = RichTextContext | SvgContext;
|
|
16
|
+
export type RichTextContext = {
|
|
17
17
|
hostContext: AsyncNativeInstance;
|
|
18
18
|
type: 'richtext';
|
|
19
19
|
node: RichTextNode;
|
|
20
20
|
root: AsyncNativeInstance;
|
|
21
21
|
parent: RichTextContext;
|
|
22
22
|
};
|
|
23
|
-
export
|
|
23
|
+
export type SvgContext = {
|
|
24
24
|
hostContext: AsyncNativeInstance;
|
|
25
25
|
type: 'svg';
|
|
26
26
|
node: RichTextNode;
|
|
27
27
|
root: AsyncNativeInstance;
|
|
28
28
|
parent: SvgContext;
|
|
29
29
|
};
|
|
30
|
-
export
|
|
30
|
+
export type RichTextNode = ({
|
|
31
31
|
tag: string;
|
|
32
32
|
attributes: Record<string, any>;
|
|
33
33
|
children: RichTextNode[];
|
|
@@ -36,10 +36,10 @@ export declare type RichTextNode = ({
|
|
|
36
36
|
text: string;
|
|
37
37
|
hidden?: boolean;
|
|
38
38
|
});
|
|
39
|
-
export
|
|
39
|
+
export type AsyncContainerInstance = AsyncNativeInstance & {
|
|
40
40
|
component: ReactUnity.IReactComponent;
|
|
41
41
|
fiberCache: ObjectsRepo | null;
|
|
42
42
|
};
|
|
43
|
-
|
|
44
|
-
export
|
|
43
|
+
type AsyncPublicInstance = ReactUnity.IReactComponent;
|
|
44
|
+
export type AsyncReconcilerConfig = Reconciler.HostConfig<InstanceTag, Props, AsyncContainerInstance, AsyncInstance, AsyncInstance, AsyncNativeInstance, HydratableInstance, AsyncPublicInstance, AsyncHostContext, UpdatePayload, ChildSet, TimeoutHandle, NoTimeout>;
|
|
45
45
|
export {};
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
export
|
|
1
|
+
export type DiffResult = null | Record<string, any>;
|
|
2
2
|
export declare const styleStringSymbol = "__style_as_string__";
|
|
3
3
|
export declare function diffProperties(lastProps: Record<string, any>, nextProps: Record<string, any>, deepDiffing?: number): DiffResult;
|
package/dist/src/version.d.ts
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export declare const version = "0.
|
|
1
|
+
export declare const version = "0.14.0";
|
package/dist/src/version.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export var version = '0.
|
|
1
|
+
export var version = '0.14.0';
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@reactunity/renderer",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.14.0",
|
|
4
4
|
"description": "React renderer for Unity3D",
|
|
5
5
|
"types": "dist/index.d.ts",
|
|
6
6
|
"typings": "dist/index.d.ts",
|
|
@@ -61,9 +61,9 @@
|
|
|
61
61
|
"react": "^18.0.0"
|
|
62
62
|
},
|
|
63
63
|
"devDependencies": {
|
|
64
|
-
"@reactunity/scripts": "^0.
|
|
65
|
-
"@types/react-reconciler": "^0.28.
|
|
66
|
-
"rimraf": "^
|
|
67
|
-
"typescript": "^4.
|
|
64
|
+
"@reactunity/scripts": "^0.14.0",
|
|
65
|
+
"@types/react-reconciler": "^0.28.2",
|
|
66
|
+
"rimraf": "^4.0.6",
|
|
67
|
+
"typescript": "^4.9.4"
|
|
68
68
|
}
|
|
69
69
|
}
|