@flemo/core 2.3.0 → 2.3.1
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/core/__tests__/adoptEntryIdentity.test.d.ts +1 -0
- package/dist/core/createRouterScope.d.ts +22 -0
- package/dist/index.d.ts +1 -1
- package/dist/index.mjs +1372 -1358
- package/package.json +1 -1
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -31,7 +31,29 @@ export interface CreateRouterScopeInput {
|
|
|
31
31
|
browserDriver: HistoryDriver | null;
|
|
32
32
|
hostedScope: FlemoStores | null;
|
|
33
33
|
persistKey?: string;
|
|
34
|
+
deferEntryAdoption?: boolean;
|
|
34
35
|
routerKey?: string;
|
|
35
36
|
zoneEntryId?: string;
|
|
36
37
|
}
|
|
37
38
|
export default function createRouterScope(input: CreateRouterScopeInput): FlemoStores;
|
|
39
|
+
/**
|
|
40
|
+
* Adopt the identity of the browser entry this scope was seeded on, after the
|
|
41
|
+
* fact — the deferred half of `deferEntryAdoption`.
|
|
42
|
+
*
|
|
43
|
+
* A binding that hydrates calls this once hydration is over, and the store's
|
|
44
|
+
* root frame stops being the generic "root" and becomes the entry it is
|
|
45
|
+
* actually sitting on. That matters for exactly the reason the construction
|
|
46
|
+
* path adopts at all: a traversal back onto this entry has to match it by id
|
|
47
|
+
* rather than collide with every other scope's "root".
|
|
48
|
+
*
|
|
49
|
+
* Every guard below is a refusal to overwrite something real:
|
|
50
|
+
*
|
|
51
|
+
* - a scope that already navigated has a stack this is not the seed of, and
|
|
52
|
+
* rewriting its first frame's id would rename an entry the user has since
|
|
53
|
+
* left,
|
|
54
|
+
* - a seed that is no longer "root" was adopted already (a re-run, a strict
|
|
55
|
+
* mode double effect),
|
|
56
|
+
* - a memory scope has no browser entry to adopt, and
|
|
57
|
+
* - an entry with no frame of its own has no identity to take.
|
|
58
|
+
*/
|
|
59
|
+
export declare function adoptEntryIdentity(scope: FlemoStores): void;
|
package/dist/index.d.ts
CHANGED
|
@@ -10,7 +10,7 @@ export { default as createNavigateStore, type NavigateStatus, type NavigateStore
|
|
|
10
10
|
export { markSelfInducedPop, consumeSelfInducedPop, createSelfPopGuard, type SelfPopGuard } from './navigate/selfPopGuard';
|
|
11
11
|
export { default as createNavigationController, type NavigationControllerDeps, type DistanceOptions, type NavigateOptions, type PopOptions } from './navigate/createNavigationController';
|
|
12
12
|
export { default as createStepController, readStepParams, appendParamsQuery, subscribeStepParamsRestore, type StepControllerDeps } from './navigate/createStepController';
|
|
13
|
-
export { default as createRouterScope, type FlemoStores, type CreateRouterScopeInput } from './core/createRouterScope';
|
|
13
|
+
export { default as createRouterScope, adoptEntryIdentity, type FlemoStores, type CreateRouterScopeInput } from './core/createRouterScope';
|
|
14
14
|
export { default as createScreenStore, type ScreenStore, type ScreenStoreApi, type SharedBarPresence, type SharedBarId, type SharedBarMetadata, type SharedBarsMetadata, type ScreenSurface } from './screen/store';
|
|
15
15
|
export { default as createScreenSelector, type ScreenSelection } from './screen/createScreenSelector';
|
|
16
16
|
export { default as computeScreenFreeze, computeScreenFreezeMode, type ScreenFreezeInput, type ScreenFreezeMode } from './screen/computeScreenFreeze';
|