@my-react/react-reconciler-compact 0.0.14 → 0.0.16
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/constants.js +1 -1
- package/dist/cjs/index.development.js +366 -577
- package/dist/cjs/index.production.js +366 -573
- package/dist/cjs/preload.development.js +548 -0
- package/dist/cjs/preload.production.js +548 -0
- package/dist/esm/index.mjs +475 -674
- package/dist/esm/preload.mjs +544 -0
- package/dist/types/dispatch-map.d.ts.map +1 -1
- package/dist/types/dispatch.d.ts +18 -18
- package/dist/types/dispatch.d.ts.map +1 -1
- package/dist/types/feature.d.ts +51 -201
- package/dist/types/feature.d.ts.map +1 -1
- package/dist/types/index.d.ts +4 -0
- package/dist/types/index.d.ts.map +1 -1
- package/dist/types/polyfill.d.ts.map +1 -1
- package/dist/types/portal.d.ts +2 -2
- package/dist/types/portal.d.ts.map +1 -1
- package/dist/types/preload.d.ts +4 -0
- package/dist/types/preload.d.ts.map +1 -0
- package/index.d.ts +3 -1
- package/package.json +30 -4
- package/preload.d.ts +1 -0
- package/preload.js +7 -0
package/dist/types/feature.d.ts
CHANGED
|
@@ -1,6 +1,5 @@
|
|
|
1
|
-
import { type MyReactElementNode } from "@my-react/react";
|
|
2
|
-
import { MyReactFiberNode
|
|
3
|
-
import { STATE_TYPE } from "@my-react/react-shared";
|
|
1
|
+
import { type MyReactElementNode } from "@my-react/react/type";
|
|
2
|
+
import { MyReactFiberNode } from "@my-react/react-reconciler";
|
|
4
3
|
import type { ReconcilerDispatch } from "./dispatch";
|
|
5
4
|
export type RenderContainer = Record<string, any> & {
|
|
6
5
|
__flag__: number;
|
|
@@ -8,208 +7,59 @@ export type RenderContainer = Record<string, any> & {
|
|
|
8
7
|
__container__: ReconcilerDispatch;
|
|
9
8
|
};
|
|
10
9
|
export declare const Reconciler: (_config: any) => {
|
|
11
|
-
createPortal: (_element: MyReactElementNode, _container: RenderContainer) => import("@my-react/react").MyReactElement;
|
|
10
|
+
createPortal: (_element: MyReactElementNode, _container: RenderContainer) => import("@my-react/react/type").MyReactElement;
|
|
12
11
|
createContainer: (_container: RenderContainer, flag: number) => RenderContainer;
|
|
12
|
+
createHydrationContainer: (_initialChildren: MyReactElementNode, _callback: (() => void) | null | undefined, _container: RenderContainer, flag: number, _hydrationCallbacks: any, _isStrictMode: boolean, _concurrentUpdatesByDefaultOverride: boolean | null, _identifierPrefix: string, _onRecoverableError: (error: Error) => void, _transitionCallbacks: any) => RenderContainer;
|
|
13
13
|
updateContainer: (_element: MyReactElementNode, _container: RenderContainer, _ignore: any, _cb: () => void) => void;
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
runtimeDom: {
|
|
19
|
-
hostContextMap: WeakMap<MyReactFiberNode, any>;
|
|
20
|
-
elementMap: WeakMap<MyReactFiberNode, MyReactFiberNode>;
|
|
21
|
-
};
|
|
22
|
-
runtimeRef: Record<"typeForRef" | "typeForCreate" | "typeForUpdate" | "typeForAppend" | "typeForNativeNode", import("@my-react/react-reconciler").NODE_TYPE>;
|
|
23
|
-
dispatchFiber(_fiber: MyReactFiberNode): void;
|
|
24
|
-
commitCreate(_fiber: MyReactFiberNode): void;
|
|
25
|
-
commitUpdate(_fiber: MyReactFiberNode): void;
|
|
26
|
-
commitAppend(_fiber: MyReactFiberNode): void;
|
|
27
|
-
commitPosition(_fiber: MyReactFiberNode): void;
|
|
28
|
-
commitSetRef(_fiber: MyReactFiberNode): void;
|
|
29
|
-
commitUnsetRef(_fiber: MyReactFiberNode): void;
|
|
30
|
-
commitClear(_fiber: MyReactFiberNode): void;
|
|
31
|
-
reconcileCommit(_fiber: MyReactFiberNode): void;
|
|
32
|
-
reconcileUpdate(_list: import("@my-react/react-shared").ListTree<MyReactFiberNode>, sync?: boolean): void;
|
|
33
|
-
patchToFiberInitial(_fiber: MyReactFiberNode): void;
|
|
34
|
-
patchToFiberUnmount(_fiber: MyReactFiberNode): void;
|
|
35
|
-
dispatchState(_params: import("@my-react/react").UpdateQueue): void;
|
|
36
|
-
dispatchHook(_params: import("@my-react/react").RenderHookParams): unknown;
|
|
37
|
-
dispatchPromise(_params: {
|
|
38
|
-
fiber?: MyReactFiberNode;
|
|
39
|
-
promise?: Promise<unknown>;
|
|
40
|
-
}): MyReactElementNode;
|
|
41
|
-
dispatchSuspensePromise(_params: {
|
|
42
|
-
fiber?: MyReactFiberNode;
|
|
43
|
-
promise?: Promise<unknown>;
|
|
44
|
-
}): MyReactElementNode;
|
|
45
|
-
dispatchError(_params: {
|
|
46
|
-
fiber?: MyReactFiberNode;
|
|
47
|
-
error?: Error;
|
|
48
|
-
}): MyReactElementNode;
|
|
49
|
-
readonly rootNode: any;
|
|
50
|
-
readonly rootFiber: MyReactFiberNode;
|
|
51
|
-
isAppMounted: boolean;
|
|
52
|
-
isAppCrashed: boolean;
|
|
53
|
-
isAppUnmounted: boolean;
|
|
54
|
-
version: string;
|
|
55
|
-
id: string;
|
|
56
|
-
mode: string;
|
|
57
|
-
enableNewEntry?: boolean;
|
|
58
|
-
enableConcurrentMode?: boolean;
|
|
59
|
-
renderMode: string;
|
|
60
|
-
renderPackage?: string;
|
|
61
|
-
pendingCommitFiberList: import("@my-react/react-shared").ListTree<MyReactFiberNode> | null;
|
|
62
|
-
pendingCommitFiberPatch: import("@my-react/react-shared").PATCH_TYPE;
|
|
63
|
-
pendingUpdateFiberArray: import("@my-react/react-shared").UniqueArray<MyReactFiberNode>;
|
|
64
|
-
pendingSuspenseFiberArray: import("@my-react/react-shared").UniqueArray<MyReactFiberNode>;
|
|
65
|
-
performanceLogTimeLimit?: number;
|
|
66
|
-
uniqueIdCount: number;
|
|
67
|
-
beforeCommit?: () => void;
|
|
68
|
-
afterCommit?: () => void;
|
|
69
|
-
beforeUpdate?: () => void;
|
|
70
|
-
afterUpdate?: () => void;
|
|
71
|
-
beforeUnmount?: () => void;
|
|
72
|
-
afterUnmount?: () => void;
|
|
73
|
-
generateCommitList(_fiber: MyReactFiberNode): void;
|
|
74
|
-
pendingCreate(_fiber: MyReactFiberNode): void;
|
|
75
|
-
pendingUpdate(_fiber: MyReactFiberNode): void;
|
|
76
|
-
pendingAppend(_fiber: MyReactFiberNode): void;
|
|
77
|
-
pendingPosition(_fiber: MyReactFiberNode): void;
|
|
78
|
-
pendingRef(_fiber: MyReactFiberNode): void;
|
|
79
|
-
pendingUnmount(_fiber: MyReactFiberNode, _pendingUnmount: MyReactFiberNode): void;
|
|
80
|
-
pendingEffect(_fiber: MyReactFiberNode, _effect: () => void, option?: {
|
|
81
|
-
stickyToHead?: boolean;
|
|
82
|
-
stickyToFoot?: boolean;
|
|
83
|
-
}): void;
|
|
84
|
-
pendingLayoutEffect(_fiber: MyReactFiberNode, _layoutEffect: () => void, option?: {
|
|
85
|
-
stickyToHead?: boolean;
|
|
86
|
-
stickyToFoot?: boolean;
|
|
87
|
-
}): void;
|
|
88
|
-
pendingInsertionEffect(_fiber: MyReactFiberNode, _insertionEffect: () => void, option?: {
|
|
89
|
-
stickyToHead?: boolean;
|
|
90
|
-
stickyToFoot?: boolean;
|
|
91
|
-
}): void;
|
|
92
|
-
patchToFiberUpdate(_fiber: MyReactFiberNode): void;
|
|
93
|
-
processLazy(_elementType: ReturnType<typeof import("@my-react/react").lazy>): Promise<void>;
|
|
94
|
-
processPromise(_promise: import("@my-react/react-reconciler").PromiseWithState<unknown>): Promise<void>;
|
|
95
|
-
resolveStrict(_fiber: MyReactFiberNode): boolean;
|
|
96
|
-
resolveScope(_fiber: MyReactFiberNode): MyReactFiberNode | null;
|
|
97
|
-
resolveSuspenseValue(_fiber: MyReactFiberNode): MyReactElementNode;
|
|
98
|
-
resolveSuspenseFiber(_fiber: MyReactFiberNode): MyReactFiberNode | null;
|
|
99
|
-
resolveErrorBoundaries(_fiber: MyReactFiberNode): MyReactFiberNode | null;
|
|
100
|
-
resolveContextFiber(_fiber: MyReactFiberNode, _contextObject?: ReturnType<typeof import("@my-react/react").createContext> | null): MyReactFiberNode | null;
|
|
101
|
-
resolveContextValue(_fiber: MyReactFiberNode | null, _contextObject?: ReturnType<typeof import("@my-react/react").createContext> | null): Record<string, unknown> | null;
|
|
102
|
-
reconcileUnmount(): void;
|
|
103
|
-
shouldYield(): boolean;
|
|
104
|
-
resetYield(): void;
|
|
105
|
-
resetUpdateFlowRuntimeFiber(): void;
|
|
106
|
-
getFiberTree(_fiber: MyReactFiberNode): string;
|
|
107
|
-
readPromise(_params: Promise<unknown>): unknown;
|
|
108
|
-
readContext(_params: ReturnType<typeof import("@my-react/react").createContext>): unknown;
|
|
109
|
-
runtimeMap: import("@my-react/react-reconciler").RenderDispatch["runtimeMap"];
|
|
110
|
-
runtimeFiber: import("@my-react/react-reconciler").RenderDispatch["runtimeFiber"];
|
|
111
|
-
dispatcher: import("@my-react/react-reconciler").RenderDispatch["dispatcher"];
|
|
112
|
-
rootElement: MyReactElementNode;
|
|
113
|
-
trigger(_fiber: MyReactFiberNode, _state?: STATE_TYPE, cb?: () => void): void;
|
|
114
|
-
onFiberInitial(cb: (_fiber: MyReactFiberNode) => void): () => boolean;
|
|
115
|
-
onceFiberInitial(cb: (_fiber: MyReactFiberNode) => void): void;
|
|
116
|
-
callOnFiberInitial(_fiber: MyReactFiberNode): void;
|
|
117
|
-
onFiberUpdate(cb: (_fiber: MyReactFiberNode) => void): () => boolean;
|
|
118
|
-
onceFiberUpdate(cb: (_fiber: MyReactFiberNode) => void): void;
|
|
119
|
-
callOnFiberUpdate(_fiber: MyReactFiberNode): void;
|
|
120
|
-
onFiberChange(cb: (_list: import("@my-react/react-shared").ListTree<MyReactFiberNode>) => void): () => boolean;
|
|
121
|
-
onceFiberChange(cb: (_list: import("@my-react/react-shared").ListTree<MyReactFiberNode>) => void): void;
|
|
122
|
-
callOnFiberChange(_list: import("@my-react/react-shared").ListTree<MyReactFiberNode>): void;
|
|
123
|
-
onFiberUnmount(cb: (_fiber: MyReactFiberNode) => void): () => boolean;
|
|
124
|
-
onceFiberUnmount(cb: (_fiber: MyReactFiberNode) => void): void;
|
|
125
|
-
callOnFiberUnmount(_fiber: MyReactFiberNode): void;
|
|
126
|
-
onFiberState(cb: (_fiber: MyReactFiberNode, _updater: import("@my-react/react").UpdateQueue) => void): () => boolean;
|
|
127
|
-
onceFiberState(cb: (_fiber: MyReactFiberNode, _updater: import("@my-react/react").UpdateQueue) => void): void;
|
|
128
|
-
callOnFiberState(_fiber: MyReactFiberNode, _updater: import("@my-react/react").UpdateQueue): void;
|
|
129
|
-
onFiberTrigger(cb: (_fiber: MyReactFiberNode, _state: import("@my-react/react-reconciler").UpdateState) => void): () => boolean;
|
|
130
|
-
onceFiberTrigger(cb: (_fiber: MyReactFiberNode, _state: import("@my-react/react-reconciler").UpdateState) => void): void;
|
|
131
|
-
callOnFiberTrigger(_fiber: MyReactFiberNode, _state: import("@my-react/react-reconciler").UpdateState): void;
|
|
132
|
-
onFiberHMR(cb: (_fiber: MyReactFiberNode, _forceRefresh?: boolean) => void): () => boolean;
|
|
133
|
-
onceFiberHMR(cb: (_fiber: MyReactFiberNode, _forceRefresh?: boolean) => void): void;
|
|
134
|
-
callOnFiberHMR(_fiber: MyReactFiberNode, _forceRefresh?: boolean): void;
|
|
135
|
-
onFiberWarn(cb: (_fiber: MyReactFiberNode, ...args: any) => void): () => boolean;
|
|
136
|
-
onceFiberWarn(cb: (_fiber: MyReactFiberNode, ...args: any) => void): void;
|
|
137
|
-
callOnFiberWarn(_fiber: MyReactFiberNode, ...args: any): void;
|
|
138
|
-
onFiberError(cb: (_fiber: MyReactFiberNode, ...args: any) => void): () => boolean;
|
|
139
|
-
onceFiberError(cb: (_fiber: MyReactFiberNode, ...args: any) => void): void;
|
|
140
|
-
callOnFiberError(_fiber: MyReactFiberNode, ...args: any): void;
|
|
141
|
-
onPerformanceWarn(cb: (_fiber: MyReactFiberNode, _renderTime: number) => void): () => boolean;
|
|
142
|
-
oncePerformanceWarn(cb: (_fiber: MyReactFiberNode, _renderTime: number) => void): void;
|
|
143
|
-
callOnPerformanceWarn(_fiber: MyReactFiberNode, _renderTime: number): void;
|
|
144
|
-
onBeforeFiberRun(cb: (_fiber: MyReactFiberNode) => void): () => boolean;
|
|
145
|
-
onceBeforeFiberRun(cb: (_fiber: MyReactFiberNode) => void): void;
|
|
146
|
-
callOnBeforeFiberRun(_fiber: MyReactFiberNode): void;
|
|
147
|
-
onAfterFiberRun(cb: (_fiber: MyReactFiberNode) => void): () => boolean;
|
|
148
|
-
onceAfterFiberRun(cb: (_fiber: MyReactFiberNode) => void): void;
|
|
149
|
-
callOnAfterFiberRun(_fiber: MyReactFiberNode): void;
|
|
150
|
-
onAfterFiberDone(cb: (_fiber: MyReactFiberNode) => void): () => boolean;
|
|
151
|
-
onceAfterFiberDone(cb: (_fiber: MyReactFiberNode) => void): void;
|
|
152
|
-
callOnAfterFiberDone(_fiber: MyReactFiberNode): void;
|
|
153
|
-
onBeforeDispatchRender(cb: (renderDispatch: CustomRenderDispatch, fiber: MyReactFiberNode) => void): () => boolean;
|
|
154
|
-
onceBeforeDispatchRender(cb: (renderDispatch: CustomRenderDispatch, fiber: MyReactFiberNode) => void): void;
|
|
155
|
-
callOnBeforeDispatchRender(renderDispatch: CustomRenderDispatch, fiber: MyReactFiberNode): void;
|
|
156
|
-
onAfterDispatchRender(cb: (renderDispatch: CustomRenderDispatch) => void): () => boolean;
|
|
157
|
-
onceAfterDispatchRender(cb: (renderDispatch: CustomRenderDispatch) => void): void;
|
|
158
|
-
callOnAfterDispatchRender(renderDispatch: CustomRenderDispatch): void;
|
|
159
|
-
onBeforeDispatchUpdate(cb: (renderDispatch: CustomRenderDispatch, list: Array<MyReactFiberNode>) => void): () => boolean;
|
|
160
|
-
onceBeforeDispatchUpdate(cb: (renderDispatch: CustomRenderDispatch, list: Array<MyReactFiberNode>) => void): void;
|
|
161
|
-
callOnBeforeDispatchUpdate(renderDispatch: CustomRenderDispatch, list: Array<MyReactFiberNode>): void;
|
|
162
|
-
onAfterDispatchUpdate(cb: (renderDispatch: CustomRenderDispatch) => void): () => boolean;
|
|
163
|
-
onceAfterDispatchUpdate(cb: (renderDispatch: CustomRenderDispatch) => void): void;
|
|
164
|
-
callOnAfterDispatchUpdate(renderDispatch: CustomRenderDispatch): void;
|
|
165
|
-
onInstanceInitial(cb: (_instance: import("@my-react/react").MyReactComponent, _fiber: MyReactFiberNode) => void): () => boolean;
|
|
166
|
-
onceInstanceInitial(cb: (_instance: import("@my-react/react").MyReactComponent, _fiber: MyReactFiberNode) => void): void;
|
|
167
|
-
callOnInstanceInitial(_instance: import("@my-react/react").MyReactComponent, _fiber: MyReactFiberNode): void;
|
|
168
|
-
onInstanceUpdate(cb: (_instance: import("@my-react/react").MyReactComponent, _fiber: MyReactFiberNode) => void): () => boolean;
|
|
169
|
-
onceInstanceUpdate(cb: (_instance: import("@my-react/react").MyReactComponent, _fiber: MyReactFiberNode) => void): void;
|
|
170
|
-
callOnInstanceUpdate(_instance: import("@my-react/react").MyReactComponent, _fiber: MyReactFiberNode): void;
|
|
171
|
-
onInstanceState(cb: (_instance: import("@my-react/react").MyReactComponent, _fiber: MyReactFiberNode, _updater: import("@my-react/react").UpdateQueue) => void): () => boolean;
|
|
172
|
-
onceInstanceState(cb: (_instance: import("@my-react/react").MyReactComponent, _fiber: MyReactFiberNode, _updater: import("@my-react/react").UpdateQueue) => void): void;
|
|
173
|
-
callOnInstanceState(_instance: import("@my-react/react").MyReactComponent, _fiber: MyReactFiberNode, _updater: import("@my-react/react").UpdateQueue): void;
|
|
174
|
-
onInstanceUnmount(cb: (_instance: import("@my-react/react").MyReactComponent, _fiber: MyReactFiberNode) => void): () => boolean;
|
|
175
|
-
onceInstanceUnmount(cb: (_instance: import("@my-react/react").MyReactComponent, _fiber: MyReactFiberNode) => void): void;
|
|
176
|
-
callOnInstanceUnmount(_instance: import("@my-react/react").MyReactComponent, _fiber: MyReactFiberNode): void;
|
|
177
|
-
onHookInitial(cb: (_hook: import("@my-react/react-reconciler").MyReactHookNode, _fiber: MyReactFiberNode) => void): () => boolean;
|
|
178
|
-
onceHookInitial(cb: (_hook: import("@my-react/react-reconciler").MyReactHookNode, _fiber: MyReactFiberNode) => void): void;
|
|
179
|
-
callOnHookInitial(_hook: import("@my-react/react-reconciler").MyReactHookNode, _fiber: MyReactFiberNode): void;
|
|
180
|
-
onHookUpdate(cb: (_hook: import("@my-react/react-reconciler").MyReactHookNode, _fiber: MyReactFiberNode) => void): () => boolean;
|
|
181
|
-
onceHookUpdate(cb: (_hook: import("@my-react/react-reconciler").MyReactHookNode, _fiber: MyReactFiberNode) => void): void;
|
|
182
|
-
callOnHookUpdate(_hook: import("@my-react/react-reconciler").MyReactHookNode, _fiber: MyReactFiberNode): void;
|
|
183
|
-
onHookUnmount(cb: (_hook: import("@my-react/react-reconciler").MyReactHookNode, _fiber: MyReactFiberNode) => void): () => boolean;
|
|
184
|
-
onceHookUnmount(cb: (_hook: import("@my-react/react-reconciler").MyReactHookNode, _fiber: MyReactFiberNode) => void): void;
|
|
185
|
-
callOnHookUnmount(_hook: import("@my-react/react-reconciler").MyReactHookNode, _fiber: MyReactFiberNode): void;
|
|
186
|
-
onHookState(cb: (_hook: import("@my-react/react-reconciler").MyReactHookNode, _fiber: MyReactFiberNode, _updater: import("@my-react/react").UpdateQueue) => void): () => boolean;
|
|
187
|
-
onceHookTrigger(cb: (_hook: import("@my-react/react-reconciler").MyReactHookNode, _fiber: MyReactFiberNode, _updater: import("@my-react/react").UpdateQueue) => void): void;
|
|
188
|
-
callOnHookState(_hook: import("@my-react/react-reconciler").MyReactHookNode, _fiber: MyReactFiberNode, _updater: import("@my-react/react").UpdateQueue): void;
|
|
189
|
-
onBeforeCommitMount(cb: (renderDispatch: CustomRenderDispatch) => void): () => boolean;
|
|
190
|
-
onceBeforeCommitMount(cb: (renderDispatch: CustomRenderDispatch) => void): void;
|
|
191
|
-
callOnBeforeCommitMount(renderDispatch: CustomRenderDispatch): void;
|
|
192
|
-
onAfterCommitMount(cb: (renderDispatch: CustomRenderDispatch) => void): () => boolean;
|
|
193
|
-
onceAfterCommitMount(cb: (renderDispatch: CustomRenderDispatch) => void): void;
|
|
194
|
-
callOnAfterCommitMount(renderDispatch: CustomRenderDispatch): void;
|
|
195
|
-
onBeforeCommitUpdate(cb: (renderDispatch: CustomRenderDispatch) => void): () => boolean;
|
|
196
|
-
onceBeforeCommitUpdate(cb: (renderDispatch: CustomRenderDispatch) => void): void;
|
|
197
|
-
callOnBeforeCommitUpdate(renderDispatch: CustomRenderDispatch): void;
|
|
198
|
-
onAfterCommitUpdate(cb: (renderDispatch: CustomRenderDispatch) => void): () => boolean;
|
|
199
|
-
onceAfterCommitUpdate(cb: (renderDispatch: CustomRenderDispatch) => void): void;
|
|
200
|
-
callOnAfterCommitUpdate(renderDispatch: CustomRenderDispatch): void;
|
|
201
|
-
onBeforeCommitUnmount(cb: (renderDispatch: CustomRenderDispatch) => void): () => boolean;
|
|
202
|
-
onceBeforeCommitUnmount(cb: (renderDispatch: CustomRenderDispatch) => void): void;
|
|
203
|
-
callOnBeforeCommitUnmount(renderDispatch: CustomRenderDispatch): void;
|
|
204
|
-
onAfterCommitUnmount(cb: (renderDispatch: CustomRenderDispatch) => void): () => boolean;
|
|
205
|
-
onceAfterCommitUnmount(cb: (renderDispatch: CustomRenderDispatch) => void): void;
|
|
206
|
-
callOnAfterCommitUnmount(renderDispatch: CustomRenderDispatch): void;
|
|
207
|
-
get isMyReactInstance(): boolean;
|
|
208
|
-
_reactInternals?: import("@my-react/react").RenderFiber;
|
|
209
|
-
};
|
|
210
|
-
injectIntoDevToolsWithSocketIO: (url: string, _config: any) => Promise<void>;
|
|
14
|
+
updateContainerSync: (element: MyReactElementNode, container: RenderContainer, ignore: any, callback: () => void) => void;
|
|
15
|
+
injectIntoDevTools: (_config: any) => boolean;
|
|
16
|
+
getPublicRootInstance: (_container: RenderContainer) => Record<string, any>;
|
|
17
|
+
injectIntoDevToolsAuto: (url: string, _config: any) => Promise<void>;
|
|
211
18
|
flushSync: <T extends any[] = any[], K = any>(action: (...args: T) => K, ...args: T) => K;
|
|
212
19
|
flushSyncWork: <T extends any[] = any[], K = any>(action: (...args: T) => K, ...args: T) => K;
|
|
213
20
|
batchedUpdates: <T extends any[] = any[], K = any>(action: (...args: T) => K, ...args: T) => K;
|
|
21
|
+
discreteUpdates: <A, B, C, D, R>(fn: (a: A, b: B, c: C, d: D) => R, a: A, b: B, c: C, d: D) => R;
|
|
22
|
+
deferredUpdates: <A>(fn: () => A) => A;
|
|
23
|
+
flushPassiveEffects: () => boolean;
|
|
24
|
+
isAlreadyRendering: () => boolean;
|
|
25
|
+
findHostInstance: (component: any) => any;
|
|
26
|
+
findHostInstanceWithWarning: (component: any, _methodName: string) => any;
|
|
27
|
+
findHostInstanceWithNoPortals: (fiber: any) => any;
|
|
28
|
+
attemptSynchronousHydration: (_fiber: any) => void;
|
|
29
|
+
attemptDiscreteHydration: (_fiber: any) => void;
|
|
30
|
+
attemptContinuousHydration: (_fiber: any) => void;
|
|
31
|
+
attemptHydrationAtCurrentPriority: (_fiber: any) => void;
|
|
32
|
+
getCurrentUpdatePriority: () => number;
|
|
33
|
+
runWithPriority: <T>(_priority: number, fn: () => T) => T;
|
|
34
|
+
shouldError: (fiber: any) => boolean | undefined;
|
|
35
|
+
shouldSuspend: (fiber: any) => boolean;
|
|
36
|
+
registerMutableSourceForHydration: (_root: any, _mutableSource: any) => void;
|
|
37
|
+
createComponentSelector: (component: any) => {
|
|
38
|
+
$$typeof: symbol;
|
|
39
|
+
value: any;
|
|
40
|
+
};
|
|
41
|
+
createHasPseudoClassSelector: (selectors: any[]) => {
|
|
42
|
+
$$typeof: symbol;
|
|
43
|
+
value: any[];
|
|
44
|
+
};
|
|
45
|
+
createRoleSelector: (role: string) => {
|
|
46
|
+
$$typeof: symbol;
|
|
47
|
+
value: string;
|
|
48
|
+
};
|
|
49
|
+
createTextSelector: (text: string) => {
|
|
50
|
+
$$typeof: symbol;
|
|
51
|
+
value: string;
|
|
52
|
+
};
|
|
53
|
+
createTestNameSelector: (id: string) => {
|
|
54
|
+
$$typeof: symbol;
|
|
55
|
+
value: string;
|
|
56
|
+
};
|
|
57
|
+
getFindAllNodesFailureDescription: (_hostRoot: any, _selectors: any[]) => string | null;
|
|
58
|
+
findAllNodes: (_hostRoot: any, _selectors: any[]) => any[];
|
|
59
|
+
findBoundingRects: (_hostRoot: any, _selectors: any[]) => any[];
|
|
60
|
+
focusWithin: (_hostRoot: any, _selectors: any[]) => boolean;
|
|
61
|
+
observeVisibleRects: (_hostRoot: any, _selectors: any[], _callback: any, _options?: any) => {
|
|
62
|
+
disconnect: () => void;
|
|
63
|
+
};
|
|
214
64
|
};
|
|
215
65
|
//# sourceMappingURL=feature.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"feature.d.ts","sourceRoot":"","sources":["../../src/feature.ts"],"names":[],"mappings":"AAAA,OAAO,EAA8C,KAAK,kBAAkB,EAAE,MAAM,
|
|
1
|
+
{"version":3,"file":"feature.d.ts","sourceRoot":"","sources":["../../src/feature.ts"],"names":[],"mappings":"AAAA,OAAO,EAA8C,KAAK,kBAAkB,EAAE,MAAM,sBAAsB,CAAC;AAC3G,OAAO,EACL,gBAAgB,EAcjB,MAAM,4BAA4B,CAAC;AAUpC,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,YAAY,CAAC;AAOrD,MAAM,MAAM,eAAe,GAAG,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,GAAG;IAClD,QAAQ,EAAE,MAAM,CAAC;IACjB,SAAS,EAAE,gBAAgB,CAAC;IAC5B,aAAa,EAAE,kBAAkB,CAAC;CACnC,CAAC;AAGF,eAAO,MAAM,UAAU,GAAI,SAAS,GAAG;;kCAWA,eAAe,QAAQ,MAAM;iDAqB9C,kBAAkB,aACzB,CAAC,MAAM,IAAI,CAAC,GAAG,IAAI,GAAG,SAAS,cAC9B,eAAe,QACrB,MAAM,uBACS,GAAG,iBACT,OAAO,uCACe,OAAO,GAAG,IAAI,qBAChC,MAAM,uBACJ,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CAIxB,GAAG,cAAc,GAAG,EAAE,aAAa,GAAG,aAAa,GAAG;;;CA2C/F,CAAC"}
|
package/dist/types/index.d.ts
CHANGED
|
@@ -11,5 +11,9 @@ export interface FiberNode<T = Record<string, any>> extends MyReactFiberNode {
|
|
|
11
11
|
alternate?: FiberNode | null;
|
|
12
12
|
}
|
|
13
13
|
export { enableKnownConfigLog } from "./config";
|
|
14
|
+
export declare const defaultOnUncaughtError: (error: Error) => void;
|
|
15
|
+
export declare const defaultOnCaughtError: (error: Error) => void;
|
|
16
|
+
export declare const defaultOnRecoverableError: (error: Error) => void;
|
|
17
|
+
export declare const startHostTransition: () => void;
|
|
14
18
|
export default createReconciler;
|
|
15
19
|
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,4BAA4B,CAAC;AACnE,OAAO,KAAK,oBAAoB,MAAM,kBAAkB,CAAC;AAEzD,cAAc,4BAA4B,CAAC;AAE3C,eAAO,MAAM,OAAO,QAAc,CAAC;AAEnC,eAAO,MAAM,gBAAgB,EAA4B,OAAO,oBAAoB,CAAC;AAErF,MAAM,WAAW,SAAS,CAAC,CAAC,GAAG,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,CAAE,SAAQ,gBAAgB;IAC1E,SAAS,EAAE,CAAC,CAAC;IACb,MAAM,EAAE,SAAS,GAAG,IAAI,CAAC;IACzB,KAAK,EAAE,SAAS,GAAG,IAAI,CAAC;IACxB,OAAO,EAAE,SAAS,GAAG,IAAI,CAAC;IAC1B,SAAS,CAAC,EAAE,SAAS,GAAG,IAAI,CAAC;CAC9B;AAED,OAAO,EAAE,oBAAoB,EAAE,MAAM,UAAU,CAAC;AAEhD,eAAe,gBAAgB,CAAC"}
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/index.ts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,IAAI,CAAC,CA4BxG;
|
|
1
|
+
{"version":3,"file":"polyfill.d.ts","sourceRoot":"","sources":["../../src/polyfill.ts"],"names":[],"mappings":"AAGA,MAAM,WAAW,uBAAuB;IACtC,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,OAAO,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,CAAC;IAC9B,OAAO,CAAC,EAAE,OAAO,CAAC;CACnB;AAED,wBAAsB,gBAAgB,CAAC,GAAG,EAAE,MAAM,EAAE,OAAO,GAAE,uBAA4B,GAAG,OAAO,CAAC,IAAI,CAAC,CA4BxG;AA4VD,wBAAsB,gBAAgB,CAAC,CAAC,GAAG,GAAG,EAAE,GAAG,EAAE,MAAM,EAAE,OAAO,GAAE,uBAA4B,GAAG,OAAO,CAAC,CAAC,CAAC,CAkB9G"}
|
package/dist/types/portal.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { type MyReactElementNode } from "@my-react/react";
|
|
1
|
+
import { type MyReactElementNode } from "@my-react/react/type";
|
|
2
2
|
import type { RenderContainer } from "./feature";
|
|
3
3
|
import type { MyReactFiberNode, CustomRenderDispatch } from "@my-react/react-reconciler";
|
|
4
|
-
export declare const createPortal: (_element: MyReactElementNode, _container: RenderContainer) => import("@my-react/react").MyReactElement;
|
|
4
|
+
export declare const createPortal: (_element: MyReactElementNode, _container: RenderContainer) => import("@my-react/react/type").MyReactElement;
|
|
5
5
|
export declare const nextWorkPortal: (renderDispatch: CustomRenderDispatch, fiber: MyReactFiberNode) => void;
|
|
6
6
|
//# sourceMappingURL=portal.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"portal.d.ts","sourceRoot":"","sources":["../../src/portal.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,kBAAkB,EAAiB,MAAM,
|
|
1
|
+
{"version":3,"file":"portal.d.ts","sourceRoot":"","sources":["../../src/portal.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,kBAAkB,EAAiB,MAAM,sBAAsB,CAAC;AAI9E,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,WAAW,CAAC;AACjD,OAAO,KAAK,EAAE,gBAAgB,EAAyB,oBAAoB,EAAE,MAAM,4BAA4B,CAAC;AAEhH,eAAO,MAAM,YAAY,GAAI,UAAU,kBAAkB,EAAE,YAAY,eAAe,kDAIrF,CAAC;AAEF,eAAO,MAAM,cAAc,GAAI,gBAAgB,oBAAoB,EAAE,OAAO,gBAAgB,SAgB3F,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"preload.d.ts","sourceRoot":"","sources":["../../src/preload.ts"],"names":[],"mappings":"AAEA,eAAO,MAAM,yBAAyB,qBAMrC,CAAC;AAEF,eAAO,MAAM,6BAA6B,qBAMzC,CAAC;AAEF,eAAO,MAAM,8BAA8B,qBAK1C,CAAC"}
|
package/index.d.ts
CHANGED
package/package.json
CHANGED
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
"description": "@my-react/react-reconciler-compact",
|
|
4
4
|
"author": "MrWangJustToDo",
|
|
5
5
|
"license": "MIT",
|
|
6
|
-
"version": "0.0.
|
|
6
|
+
"version": "0.0.16",
|
|
7
7
|
"main": "index.js",
|
|
8
8
|
"types": "index.d.ts",
|
|
9
9
|
"files": [
|
|
@@ -11,6 +11,8 @@
|
|
|
11
11
|
"type.d.ts",
|
|
12
12
|
"index.js",
|
|
13
13
|
"index.d.ts",
|
|
14
|
+
"preload.js",
|
|
15
|
+
"preload.d.ts",
|
|
14
16
|
"constants.js",
|
|
15
17
|
"constants.d.ts"
|
|
16
18
|
],
|
|
@@ -35,6 +37,11 @@
|
|
|
35
37
|
"require": "./type.js",
|
|
36
38
|
"types": "./type.d.ts"
|
|
37
39
|
},
|
|
40
|
+
"./preload": {
|
|
41
|
+
"types": "./preload.d.ts",
|
|
42
|
+
"require": "./preload.js",
|
|
43
|
+
"import": "./dist/esm/preload.mjs"
|
|
44
|
+
},
|
|
38
45
|
"./package.json": "./package.json"
|
|
39
46
|
},
|
|
40
47
|
"buildOptions": [
|
|
@@ -57,6 +64,7 @@
|
|
|
57
64
|
},
|
|
58
65
|
{
|
|
59
66
|
"input": "./src/constants.ts",
|
|
67
|
+
"pkgName": "constants",
|
|
60
68
|
"output": [
|
|
61
69
|
{
|
|
62
70
|
"dir": "./dist",
|
|
@@ -71,14 +79,32 @@
|
|
|
71
79
|
"format": "esm"
|
|
72
80
|
}
|
|
73
81
|
]
|
|
82
|
+
},
|
|
83
|
+
{
|
|
84
|
+
"input": "./src/preload.ts",
|
|
85
|
+
"pkgName": "preload",
|
|
86
|
+
"output": [
|
|
87
|
+
{
|
|
88
|
+
"dir": "./dist",
|
|
89
|
+
"entryFileNames": "cjs/preload.js",
|
|
90
|
+
"format": "cjs",
|
|
91
|
+
"type": true,
|
|
92
|
+
"multiple": true
|
|
93
|
+
},
|
|
94
|
+
{
|
|
95
|
+
"dir": "./dist",
|
|
96
|
+
"entryFileNames": "esm/preload.mjs",
|
|
97
|
+
"format": "esm"
|
|
98
|
+
}
|
|
99
|
+
]
|
|
74
100
|
}
|
|
75
101
|
],
|
|
76
102
|
"devDependencies": {
|
|
77
|
-
"@my-react/react-reconciler": "^0.3.
|
|
78
|
-
"@my-react/react-shared": "^0.3.
|
|
103
|
+
"@my-react/react-reconciler": "^0.3.25",
|
|
104
|
+
"@my-react/react-shared": "^0.3.25",
|
|
79
105
|
"@types/react-reconciler": "^0.32.3"
|
|
80
106
|
},
|
|
81
107
|
"peerDependencies": {
|
|
82
|
-
"@my-react/react": ">=0.3.
|
|
108
|
+
"@my-react/react": ">=0.3.25"
|
|
83
109
|
}
|
|
84
110
|
}
|
package/preload.d.ts
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from "./dist/types/preload";
|