@granite-js/react-native 0.1.23-next.6 → 0.1.24
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/CHANGELOG.md +19 -65
- package/dist/app/Granite.d.ts +2 -2
- package/dist/async-bridges.js +6 -6
- package/dist/async-bridges.mjs +2 -2
- package/dist/constant-bridges.js +3 -3
- package/dist/constant-bridges.mjs +1 -1
- package/dist/intersection-observer/IOFlatList.d.ts +2 -2
- package/dist/native-event-emitter/nativeEventEmitter.d.ts +1 -5
- package/dist/native-modules/core/GraniteCoreModule.d.ts +1 -1
- package/dist/native-modules/natives/GraniteModule.d.ts +1 -1
- package/dist/router/Router.d.ts +0 -1
- package/dist/router/components/StackNavigator.d.ts +42 -36
- package/dist/router/components/useRouterBackHandler.d.ts +2 -2
- package/dist/video/Video.d.ts +2 -2
- package/dist/video/instance.d.ts +2 -2
- package/package.json +16 -16
- package/src/app/Granite.tsx +2 -2
- package/src/intersection-observer/IOFlatList.ts +2 -2
- package/src/native-event-emitter/nativeEventEmitter.ts +1 -12
- package/src/native-modules/core/GraniteCoreModule.ts +1 -1
- package/src/native-modules/natives/GraniteModule.ts +8 -0
- package/src/native-modules/natives/closeView.ts +2 -2
- package/src/native-modules/natives/getSchemeUri.ts +1 -1
- package/src/router/Router.tsx +5 -5
- package/src/router/components/useRouterBackHandler.tsx +2 -2
- package/src/video/Video.tsx +1 -1
- package/src/video/instance.tsx +2 -2
- package/src/visibility/utils/usePrevious.tsx +1 -1
- package/dist/chunk-2PYPIQMA.mjs +0 -10
- package/dist/chunk-OWDLSIVX.mjs +0 -7
- package/dist/native-modules/natives/GraniteModule.brick.d.ts +0 -10
- package/dist/react/index.d.ts +0 -1
- package/dist/react/useWaitForReturnNavigator.d.ts +0 -39
- package/src/native-modules/natives/GraniteModule.brick.ts +0 -10
package/CHANGELOG.md
CHANGED
|
@@ -1,78 +1,32 @@
|
|
|
1
1
|
# @granite-js/react-native
|
|
2
2
|
|
|
3
|
-
## 0.1.
|
|
3
|
+
## 0.1.24
|
|
4
4
|
|
|
5
5
|
### Patch Changes
|
|
6
6
|
|
|
7
|
-
-
|
|
8
|
-
-
|
|
9
|
-
- @granite-js/
|
|
10
|
-
- @granite-js/
|
|
11
|
-
- @granite-js/
|
|
12
|
-
- @granite-js/
|
|
13
|
-
- @granite-js/
|
|
14
|
-
- @granite-js/
|
|
15
|
-
- @granite-js/
|
|
16
|
-
- @granite-js/cli@0.1.23-next.6
|
|
7
|
+
- Updated dependencies [6e42c3d]
|
|
8
|
+
- @granite-js/plugin-core@0.1.24
|
|
9
|
+
- @granite-js/mpack@0.1.24
|
|
10
|
+
- @granite-js/cli@0.1.24
|
|
11
|
+
- @granite-js/image@0.1.24
|
|
12
|
+
- @granite-js/jest@0.1.24
|
|
13
|
+
- @granite-js/lottie@0.1.24
|
|
14
|
+
- @granite-js/native@0.1.24
|
|
15
|
+
- @granite-js/style-utils@0.1.24
|
|
17
16
|
|
|
18
|
-
## 0.1.23
|
|
19
|
-
|
|
20
|
-
### Patch Changes
|
|
21
|
-
|
|
22
|
-
- temp
|
|
23
|
-
- Updated dependencies
|
|
24
|
-
- @granite-js/plugin-core@0.1.23-next.5
|
|
25
|
-
- @granite-js/style-utils@0.1.23-next.5
|
|
26
|
-
- @granite-js/lottie@0.1.23-next.5
|
|
27
|
-
- @granite-js/native@0.1.23-next.5
|
|
28
|
-
- @granite-js/image@0.1.23-next.5
|
|
29
|
-
- @granite-js/mpack@0.1.23-next.5
|
|
30
|
-
- @granite-js/jest@0.1.23-next.5
|
|
31
|
-
- @granite-js/cli@0.1.23-next.5
|
|
32
|
-
|
|
33
|
-
## 0.1.23-next.4
|
|
34
|
-
|
|
35
|
-
### Patch Changes
|
|
36
|
-
|
|
37
|
-
- test
|
|
38
|
-
- Updated dependencies
|
|
39
|
-
- @granite-js/plugin-core@0.1.23-next.4
|
|
40
|
-
- @granite-js/style-utils@0.1.23-next.4
|
|
41
|
-
- @granite-js/lottie@0.1.23-next.4
|
|
42
|
-
- @granite-js/native@0.1.23-next.4
|
|
43
|
-
- @granite-js/image@0.1.23-next.4
|
|
44
|
-
- @granite-js/mpack@0.1.23-next.4
|
|
45
|
-
- @granite-js/jest@0.1.23-next.4
|
|
46
|
-
- @granite-js/cli@0.1.23-next.4
|
|
47
|
-
|
|
48
|
-
## 0.1.23-next.3
|
|
49
|
-
|
|
50
|
-
### Patch Changes
|
|
51
|
-
|
|
52
|
-
- test
|
|
53
|
-
- Updated dependencies
|
|
54
|
-
- @granite-js/plugin-core@0.1.23-next.3
|
|
55
|
-
- @granite-js/style-utils@0.1.23-next.3
|
|
56
|
-
- @granite-js/lottie@0.1.23-next.3
|
|
57
|
-
- @granite-js/native@0.1.23-next.3
|
|
58
|
-
- @granite-js/image@0.1.23-next.3
|
|
59
|
-
- @granite-js/mpack@0.1.23-next.3
|
|
60
|
-
- @granite-js/jest@0.1.23-next.3
|
|
61
|
-
- @granite-js/cli@0.1.23-next.3
|
|
62
|
-
|
|
63
|
-
## 0.1.23-next.0
|
|
17
|
+
## 0.1.23
|
|
64
18
|
|
|
65
19
|
### Patch Changes
|
|
66
20
|
|
|
67
21
|
- d9b7d7c: avoid multiple app registrations without throwing errors
|
|
68
|
-
- @granite-js/cli@0.1.23
|
|
69
|
-
- @granite-js/image@0.1.23
|
|
70
|
-
- @granite-js/jest@0.1.23
|
|
71
|
-
- @granite-js/lottie@0.1.23
|
|
72
|
-
- @granite-js/mpack@0.1.23
|
|
73
|
-
- @granite-js/native@0.1.23
|
|
74
|
-
- @granite-js/plugin-core@0.1.23
|
|
75
|
-
- @granite-js/style-utils@0.1.23
|
|
22
|
+
- @granite-js/cli@0.1.23
|
|
23
|
+
- @granite-js/image@0.1.23
|
|
24
|
+
- @granite-js/jest@0.1.23
|
|
25
|
+
- @granite-js/lottie@0.1.23
|
|
26
|
+
- @granite-js/mpack@0.1.23
|
|
27
|
+
- @granite-js/native@0.1.23
|
|
28
|
+
- @granite-js/plugin-core@0.1.23
|
|
29
|
+
- @granite-js/style-utils@0.1.23
|
|
76
30
|
|
|
77
31
|
## 0.1.22
|
|
78
32
|
|
package/dist/app/Granite.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { ComponentType,
|
|
1
|
+
import { ComponentType, PropsWithChildren } from 'react';
|
|
2
2
|
import type { InitialProps } from '../initial-props';
|
|
3
3
|
import type { RouterProps, RequireContext } from '../router';
|
|
4
4
|
export interface GraniteProps {
|
|
@@ -68,6 +68,6 @@ export interface GraniteProps {
|
|
|
68
68
|
*/
|
|
69
69
|
export declare const Granite: {
|
|
70
70
|
registerApp(AppContainer: ComponentType<PropsWithChildren<InitialProps>>, { appName, context, router, initialScheme, setIosSwipeGestureEnabled }: GraniteProps): (initialProps: InitialProps) => JSX.Element;
|
|
71
|
-
registerHostApp(AppContainer: ComponentType<PropsWithChildren<InitialProps>>, { appName }: Pick<GraniteProps, "appName">): (initialProps: InitialProps) =>
|
|
71
|
+
registerHostApp(AppContainer: ComponentType<PropsWithChildren<InitialProps>>, { appName }: Pick<GraniteProps, "appName">): (initialProps: InitialProps) => JSX.Element;
|
|
72
72
|
readonly appName: string;
|
|
73
73
|
};
|
package/dist/async-bridges.js
CHANGED
|
@@ -25,19 +25,19 @@ __export(async_bridges_exports, {
|
|
|
25
25
|
});
|
|
26
26
|
module.exports = __toCommonJS(async_bridges_exports);
|
|
27
27
|
|
|
28
|
-
// src/native-modules/natives/GraniteModule.
|
|
29
|
-
var
|
|
30
|
-
var GraniteModule =
|
|
28
|
+
// src/native-modules/natives/GraniteModule.ts
|
|
29
|
+
var import_react_native = require("react-native");
|
|
30
|
+
var GraniteModule = import_react_native.TurboModuleRegistry.getEnforcing("GraniteModule");
|
|
31
31
|
|
|
32
32
|
// src/native-modules/natives/closeView.ts
|
|
33
33
|
async function closeView() {
|
|
34
|
-
return GraniteModule
|
|
34
|
+
return GraniteModule.closeView();
|
|
35
35
|
}
|
|
36
36
|
|
|
37
37
|
// src/native-modules/natives/openURL.ts
|
|
38
|
-
var
|
|
38
|
+
var import_react_native2 = require("react-native");
|
|
39
39
|
function openURL(url) {
|
|
40
|
-
return
|
|
40
|
+
return import_react_native2.Linking.openURL(url);
|
|
41
41
|
}
|
|
42
42
|
// Annotate the CommonJS export names for ESM import in node:
|
|
43
43
|
0 && (module.exports = {
|
package/dist/async-bridges.mjs
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import {
|
|
2
2
|
GraniteModule
|
|
3
|
-
} from "./chunk-
|
|
3
|
+
} from "./chunk-A3JGM5OI.mjs";
|
|
4
4
|
|
|
5
5
|
// src/native-modules/natives/closeView.ts
|
|
6
6
|
async function closeView() {
|
|
7
|
-
return GraniteModule
|
|
7
|
+
return GraniteModule.closeView();
|
|
8
8
|
}
|
|
9
9
|
|
|
10
10
|
// src/native-modules/natives/openURL.ts
|
package/dist/constant-bridges.js
CHANGED
|
@@ -24,9 +24,9 @@ __export(constant_bridges_exports, {
|
|
|
24
24
|
});
|
|
25
25
|
module.exports = __toCommonJS(constant_bridges_exports);
|
|
26
26
|
|
|
27
|
-
// src/native-modules/natives/GraniteModule.
|
|
28
|
-
var
|
|
29
|
-
var GraniteModule =
|
|
27
|
+
// src/native-modules/natives/GraniteModule.ts
|
|
28
|
+
var import_react_native = require("react-native");
|
|
29
|
+
var GraniteModule = import_react_native.TurboModuleRegistry.getEnforcing("GraniteModule");
|
|
30
30
|
|
|
31
31
|
// src/native-modules/natives/getSchemeUri.ts
|
|
32
32
|
function getSchemeUri() {
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import
|
|
1
|
+
import { RefAttributes } from 'react';
|
|
2
2
|
import { FlatList, FlatListProps } from 'react-native';
|
|
3
3
|
import { IOComponentProps } from './withIO';
|
|
4
4
|
export type IOFlatListController = FlatList;
|
|
@@ -51,5 +51,5 @@ export type IOFlatListProps<ItemT = any> = IOComponentProps & FlatListProps<Item
|
|
|
51
51
|
* ```
|
|
52
52
|
*/
|
|
53
53
|
declare const IOFlatList: typeof IOFlatListFunction;
|
|
54
|
-
declare function IOFlatListFunction<ItemT = any>(props: IOFlatListProps<ItemT> & RefAttributes<IOFlatListController>):
|
|
54
|
+
declare function IOFlatListFunction<ItemT = any>(props: IOFlatListProps<ItemT> & RefAttributes<IOFlatListController>): JSX.Element;
|
|
55
55
|
export default IOFlatList;
|
|
@@ -11,9 +11,5 @@ type ParamOf<K extends EventKeys> = EventEmittersMap[K]['params'];
|
|
|
11
11
|
interface EventEmitter {
|
|
12
12
|
addListener<Event extends EventKeys>(event: Event, callback: (...params: ParamOf<Event>) => void): EmitterSubscription;
|
|
13
13
|
}
|
|
14
|
-
export declare const nativeEventEmitter: EventEmitter
|
|
15
|
-
addListener: () => {
|
|
16
|
-
remove: () => void;
|
|
17
|
-
};
|
|
18
|
-
};
|
|
14
|
+
export declare const nativeEventEmitter: EventEmitter;
|
|
19
15
|
export {};
|
|
@@ -4,5 +4,5 @@ interface GraniteCoreModule extends TurboModule {
|
|
|
4
4
|
removeListeners: (count: number) => void;
|
|
5
5
|
importLazy: () => Promise<void>;
|
|
6
6
|
}
|
|
7
|
-
export declare const GraniteCoreModule: GraniteCoreModule
|
|
7
|
+
export declare const GraniteCoreModule: GraniteCoreModule;
|
|
8
8
|
export {};
|
package/dist/router/Router.d.ts
CHANGED
|
@@ -26,7 +26,6 @@ interface StackNavigatorProps {
|
|
|
26
26
|
screenContainer?: ComponentType<PropsWithChildren<any>>;
|
|
27
27
|
}
|
|
28
28
|
type NavigationContainerProps = Pick<ComponentProps<typeof NavigationContainer>, 'ref' | 'documentTitle' | 'fallback' | 'onReady' | 'onUnhandledAction' | 'onStateChange'>;
|
|
29
|
-
export declare const navigationRef: NavigationContainerRefWithCurrent<never>;
|
|
30
29
|
/**
|
|
31
30
|
* @category Components
|
|
32
31
|
* @kind function
|
|
@@ -1,48 +1,54 @@
|
|
|
1
1
|
export declare const StackNavigator: {
|
|
2
|
-
Navigator: import("react").ComponentType<Omit<import("@react-navigation/
|
|
2
|
+
Navigator: import("react").ComponentType<Omit<import("@react-navigation/routers").DefaultRouterOptions<string> & {
|
|
3
|
+
id?: string;
|
|
3
4
|
children: React.ReactNode;
|
|
4
|
-
layout?: ((props: {
|
|
5
|
-
state: import("@react-navigation/routers").StackNavigationState<import("@react-navigation/routers").ParamListBase>;
|
|
6
|
-
navigation: import("@react-navigation/core").NavigationHelpers<import("@react-navigation/routers").ParamListBase, {}>;
|
|
7
|
-
descriptors: Record<string, import("@react-navigation/core").Descriptor<import("@react-navigation/native-stack").NativeStackNavigationOptions, import("@react-navigation/core").NavigationProp<import("@react-navigation/routers").ParamListBase, string, string | undefined, import("@react-navigation/routers").StackNavigationState<import("@react-navigation/routers").ParamListBase>, import("@react-navigation/native-stack").NativeStackNavigationOptions, import("@react-navigation/native-stack").NativeStackNavigationEventMap>, import("@react-navigation/core").RouteProp<import("@react-navigation/routers").ParamListBase, string>>>;
|
|
8
|
-
children: React.ReactNode;
|
|
9
|
-
}) => React.ReactElement) | undefined;
|
|
10
5
|
screenListeners?: Partial<{
|
|
11
|
-
transitionStart: import("@react-navigation/core").EventListenerCallback<import("@react-navigation/native-stack").NativeStackNavigationEventMap & import("@react-navigation/core").EventMapCore<import("@react-navigation/routers").StackNavigationState<import("@react-navigation/routers").ParamListBase>>, "transitionStart"
|
|
12
|
-
transitionEnd: import("@react-navigation/core").EventListenerCallback<import("@react-navigation/native-stack").NativeStackNavigationEventMap & import("@react-navigation/core").EventMapCore<import("@react-navigation/routers").StackNavigationState<import("@react-navigation/routers").ParamListBase>>, "transitionEnd"
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
state: import("@react-navigation/core").EventListenerCallback<import("@react-navigation/native-stack").NativeStackNavigationEventMap & import("@react-navigation/core").EventMapCore<import("@react-navigation/routers").StackNavigationState<import("@react-navigation/routers").ParamListBase>>, "state", unknown>;
|
|
18
|
-
beforeRemove: import("@react-navigation/core").EventListenerCallback<import("@react-navigation/native-stack").NativeStackNavigationEventMap & import("@react-navigation/core").EventMapCore<import("@react-navigation/routers").StackNavigationState<import("@react-navigation/routers").ParamListBase>>, "beforeRemove", true>;
|
|
6
|
+
transitionStart: import("@react-navigation/core").EventListenerCallback<import("@react-navigation/native-stack").NativeStackNavigationEventMap & import("@react-navigation/core").EventMapCore<import("@react-navigation/routers").StackNavigationState<import("@react-navigation/routers").ParamListBase>>, "transitionStart">;
|
|
7
|
+
transitionEnd: import("@react-navigation/core").EventListenerCallback<import("@react-navigation/native-stack").NativeStackNavigationEventMap & import("@react-navigation/core").EventMapCore<import("@react-navigation/routers").StackNavigationState<import("@react-navigation/routers").ParamListBase>>, "transitionEnd">;
|
|
8
|
+
focus: import("@react-navigation/core").EventListenerCallback<import("@react-navigation/native-stack").NativeStackNavigationEventMap & import("@react-navigation/core").EventMapCore<import("@react-navigation/routers").StackNavigationState<import("@react-navigation/routers").ParamListBase>>, "focus">;
|
|
9
|
+
blur: import("@react-navigation/core").EventListenerCallback<import("@react-navigation/native-stack").NativeStackNavigationEventMap & import("@react-navigation/core").EventMapCore<import("@react-navigation/routers").StackNavigationState<import("@react-navigation/routers").ParamListBase>>, "blur">;
|
|
10
|
+
state: import("@react-navigation/core").EventListenerCallback<import("@react-navigation/native-stack").NativeStackNavigationEventMap & import("@react-navigation/core").EventMapCore<import("@react-navigation/routers").StackNavigationState<import("@react-navigation/routers").ParamListBase>>, "state">;
|
|
11
|
+
beforeRemove: import("@react-navigation/core").EventListenerCallback<import("@react-navigation/native-stack").NativeStackNavigationEventMap & import("@react-navigation/core").EventMapCore<import("@react-navigation/routers").StackNavigationState<import("@react-navigation/routers").ParamListBase>>, "beforeRemove">;
|
|
19
12
|
}> | ((props: {
|
|
20
13
|
route: import("@react-navigation/core").RouteProp<import("@react-navigation/routers").ParamListBase, string>;
|
|
21
|
-
navigation:
|
|
14
|
+
navigation: any;
|
|
22
15
|
}) => Partial<{
|
|
23
|
-
transitionStart: import("@react-navigation/core").EventListenerCallback<import("@react-navigation/native-stack").NativeStackNavigationEventMap & import("@react-navigation/core").EventMapCore<import("@react-navigation/routers").StackNavigationState<import("@react-navigation/routers").ParamListBase>>, "transitionStart"
|
|
24
|
-
transitionEnd: import("@react-navigation/core").EventListenerCallback<import("@react-navigation/native-stack").NativeStackNavigationEventMap & import("@react-navigation/core").EventMapCore<import("@react-navigation/routers").StackNavigationState<import("@react-navigation/routers").ParamListBase>>, "transitionEnd"
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
state: import("@react-navigation/core").EventListenerCallback<import("@react-navigation/native-stack").NativeStackNavigationEventMap & import("@react-navigation/core").EventMapCore<import("@react-navigation/routers").StackNavigationState<import("@react-navigation/routers").ParamListBase>>, "state", unknown>;
|
|
30
|
-
beforeRemove: import("@react-navigation/core").EventListenerCallback<import("@react-navigation/native-stack").NativeStackNavigationEventMap & import("@react-navigation/core").EventMapCore<import("@react-navigation/routers").StackNavigationState<import("@react-navigation/routers").ParamListBase>>, "beforeRemove", true>;
|
|
16
|
+
transitionStart: import("@react-navigation/core").EventListenerCallback<import("@react-navigation/native-stack").NativeStackNavigationEventMap & import("@react-navigation/core").EventMapCore<import("@react-navigation/routers").StackNavigationState<import("@react-navigation/routers").ParamListBase>>, "transitionStart">;
|
|
17
|
+
transitionEnd: import("@react-navigation/core").EventListenerCallback<import("@react-navigation/native-stack").NativeStackNavigationEventMap & import("@react-navigation/core").EventMapCore<import("@react-navigation/routers").StackNavigationState<import("@react-navigation/routers").ParamListBase>>, "transitionEnd">;
|
|
18
|
+
focus: import("@react-navigation/core").EventListenerCallback<import("@react-navigation/native-stack").NativeStackNavigationEventMap & import("@react-navigation/core").EventMapCore<import("@react-navigation/routers").StackNavigationState<import("@react-navigation/routers").ParamListBase>>, "focus">;
|
|
19
|
+
blur: import("@react-navigation/core").EventListenerCallback<import("@react-navigation/native-stack").NativeStackNavigationEventMap & import("@react-navigation/core").EventMapCore<import("@react-navigation/routers").StackNavigationState<import("@react-navigation/routers").ParamListBase>>, "blur">;
|
|
20
|
+
state: import("@react-navigation/core").EventListenerCallback<import("@react-navigation/native-stack").NativeStackNavigationEventMap & import("@react-navigation/core").EventMapCore<import("@react-navigation/routers").StackNavigationState<import("@react-navigation/routers").ParamListBase>>, "state">;
|
|
21
|
+
beforeRemove: import("@react-navigation/core").EventListenerCallback<import("@react-navigation/native-stack").NativeStackNavigationEventMap & import("@react-navigation/core").EventMapCore<import("@react-navigation/routers").StackNavigationState<import("@react-navigation/routers").ParamListBase>>, "beforeRemove">;
|
|
31
22
|
}>) | undefined;
|
|
32
23
|
screenOptions?: import("@react-navigation/native-stack").NativeStackNavigationOptions | ((props: {
|
|
33
24
|
route: import("@react-navigation/core").RouteProp<import("@react-navigation/routers").ParamListBase, string>;
|
|
34
|
-
navigation:
|
|
35
|
-
|
|
25
|
+
navigation: any;
|
|
26
|
+
}) => import("@react-navigation/native-stack").NativeStackNavigationOptions) | undefined;
|
|
27
|
+
} & import("@react-navigation/routers").StackRouterOptions, "children" | "id" | "initialRouteName" | "screenListeners" | "screenOptions"> & import("@react-navigation/routers").DefaultRouterOptions<string> & {
|
|
28
|
+
id?: string;
|
|
29
|
+
children: React.ReactNode;
|
|
30
|
+
screenListeners?: Partial<{
|
|
31
|
+
transitionStart: import("@react-navigation/core").EventListenerCallback<import("@react-navigation/native-stack").NativeStackNavigationEventMap & import("@react-navigation/core").EventMapCore<import("@react-navigation/routers").StackNavigationState<import("@react-navigation/routers").ParamListBase>>, "transitionStart">;
|
|
32
|
+
transitionEnd: import("@react-navigation/core").EventListenerCallback<import("@react-navigation/native-stack").NativeStackNavigationEventMap & import("@react-navigation/core").EventMapCore<import("@react-navigation/routers").StackNavigationState<import("@react-navigation/routers").ParamListBase>>, "transitionEnd">;
|
|
33
|
+
focus: import("@react-navigation/core").EventListenerCallback<import("@react-navigation/native-stack").NativeStackNavigationEventMap & import("@react-navigation/core").EventMapCore<import("@react-navigation/routers").StackNavigationState<import("@react-navigation/routers").ParamListBase>>, "focus">;
|
|
34
|
+
blur: import("@react-navigation/core").EventListenerCallback<import("@react-navigation/native-stack").NativeStackNavigationEventMap & import("@react-navigation/core").EventMapCore<import("@react-navigation/routers").StackNavigationState<import("@react-navigation/routers").ParamListBase>>, "blur">;
|
|
35
|
+
state: import("@react-navigation/core").EventListenerCallback<import("@react-navigation/native-stack").NativeStackNavigationEventMap & import("@react-navigation/core").EventMapCore<import("@react-navigation/routers").StackNavigationState<import("@react-navigation/routers").ParamListBase>>, "state">;
|
|
36
|
+
beforeRemove: import("@react-navigation/core").EventListenerCallback<import("@react-navigation/native-stack").NativeStackNavigationEventMap & import("@react-navigation/core").EventMapCore<import("@react-navigation/routers").StackNavigationState<import("@react-navigation/routers").ParamListBase>>, "beforeRemove">;
|
|
37
|
+
}> | ((props: {
|
|
38
|
+
route: import("@react-navigation/core").RouteProp<import("@react-navigation/routers").ParamListBase, string>;
|
|
39
|
+
navigation: any;
|
|
40
|
+
}) => Partial<{
|
|
41
|
+
transitionStart: import("@react-navigation/core").EventListenerCallback<import("@react-navigation/native-stack").NativeStackNavigationEventMap & import("@react-navigation/core").EventMapCore<import("@react-navigation/routers").StackNavigationState<import("@react-navigation/routers").ParamListBase>>, "transitionStart">;
|
|
42
|
+
transitionEnd: import("@react-navigation/core").EventListenerCallback<import("@react-navigation/native-stack").NativeStackNavigationEventMap & import("@react-navigation/core").EventMapCore<import("@react-navigation/routers").StackNavigationState<import("@react-navigation/routers").ParamListBase>>, "transitionEnd">;
|
|
43
|
+
focus: import("@react-navigation/core").EventListenerCallback<import("@react-navigation/native-stack").NativeStackNavigationEventMap & import("@react-navigation/core").EventMapCore<import("@react-navigation/routers").StackNavigationState<import("@react-navigation/routers").ParamListBase>>, "focus">;
|
|
44
|
+
blur: import("@react-navigation/core").EventListenerCallback<import("@react-navigation/native-stack").NativeStackNavigationEventMap & import("@react-navigation/core").EventMapCore<import("@react-navigation/routers").StackNavigationState<import("@react-navigation/routers").ParamListBase>>, "blur">;
|
|
45
|
+
state: import("@react-navigation/core").EventListenerCallback<import("@react-navigation/native-stack").NativeStackNavigationEventMap & import("@react-navigation/core").EventMapCore<import("@react-navigation/routers").StackNavigationState<import("@react-navigation/routers").ParamListBase>>, "state">;
|
|
46
|
+
beforeRemove: import("@react-navigation/core").EventListenerCallback<import("@react-navigation/native-stack").NativeStackNavigationEventMap & import("@react-navigation/core").EventMapCore<import("@react-navigation/routers").StackNavigationState<import("@react-navigation/routers").ParamListBase>>, "beforeRemove">;
|
|
47
|
+
}>) | undefined;
|
|
48
|
+
screenOptions?: import("@react-navigation/native-stack").NativeStackNavigationOptions | ((props: {
|
|
49
|
+
route: import("@react-navigation/core").RouteProp<import("@react-navigation/routers").ParamListBase, string>;
|
|
50
|
+
navigation: any;
|
|
36
51
|
}) => import("@react-navigation/native-stack").NativeStackNavigationOptions) | undefined;
|
|
37
|
-
screenLayout?: ((props: import("@react-navigation/core").ScreenLayoutArgs<import("@react-navigation/routers").ParamListBase, string, import("@react-navigation/native-stack").NativeStackNavigationOptions, import("@react-navigation/native-stack").NativeStackNavigationProp<import("@react-navigation/routers").ParamListBase, string, undefined>>) => React.ReactElement) | undefined;
|
|
38
|
-
UNSTABLE_router?: (<Action extends Readonly<{
|
|
39
|
-
type: string;
|
|
40
|
-
payload?: object;
|
|
41
|
-
source?: string;
|
|
42
|
-
target?: string;
|
|
43
|
-
}>>(original: import("@react-navigation/routers").Router<import("@react-navigation/routers").StackNavigationState<import("@react-navigation/routers").ParamListBase>, Action>) => Partial<import("@react-navigation/routers").Router<import("@react-navigation/routers").StackNavigationState<import("@react-navigation/routers").ParamListBase>, Action>>) | undefined;
|
|
44
|
-
} & {
|
|
45
|
-
id?: undefined;
|
|
46
52
|
}>;
|
|
47
|
-
Screen: <RouteName extends string>(_: import("@react-navigation/core").RouteConfig<import("@react-navigation/routers").ParamListBase, RouteName, import("@react-navigation/routers").StackNavigationState<import("@react-navigation/routers").ParamListBase>, import("@react-navigation/native-stack").NativeStackNavigationOptions, import("@react-navigation/native-stack").NativeStackNavigationEventMap
|
|
53
|
+
Screen: <RouteName extends string>(_: import("@react-navigation/core").RouteConfig<import("@react-navigation/routers").ParamListBase, RouteName, import("@react-navigation/routers").StackNavigationState<import("@react-navigation/routers").ParamListBase>, import("@react-navigation/native-stack").NativeStackNavigationOptions, import("@react-navigation/native-stack").NativeStackNavigationEventMap>) => null;
|
|
48
54
|
};
|
|
@@ -42,13 +42,13 @@ import { NavigationContainerRefWithCurrent } from '@granite-js/native/@react-nav
|
|
|
42
42
|
* }
|
|
43
43
|
*/
|
|
44
44
|
export declare function useRouterBackHandler({ navigationContainerRef, onClose, }: {
|
|
45
|
-
navigationContainerRef: NavigationContainerRefWithCurrent<
|
|
45
|
+
navigationContainerRef: NavigationContainerRefWithCurrent<any>;
|
|
46
46
|
onClose?: () => void;
|
|
47
47
|
}): {
|
|
48
48
|
handler: () => void;
|
|
49
49
|
};
|
|
50
50
|
export declare function useInternalRouterBackHandler({ navigationContainerRef, onClose, }: {
|
|
51
|
-
navigationContainerRef: NavigationContainerRefWithCurrent<
|
|
51
|
+
navigationContainerRef: NavigationContainerRefWithCurrent<any>;
|
|
52
52
|
onClose?: () => void;
|
|
53
53
|
}): {
|
|
54
54
|
handler: () => void;
|
package/dist/video/Video.d.ts
CHANGED
|
@@ -58,11 +58,11 @@ type VideoProps = ComponentProps<typeof AnimatedRNVideo>;
|
|
|
58
58
|
* }
|
|
59
59
|
* ```
|
|
60
60
|
*/
|
|
61
|
-
declare const VideoImpl: import("react").ForwardRefExoticComponent<Omit<import("react-native-video").
|
|
61
|
+
declare const VideoImpl: import("react").ForwardRefExoticComponent<Omit<import("react-native-video").VideoProperties, "onAudioFocusChanged"> & {
|
|
62
62
|
onAudioFocusChanged?: (event: {
|
|
63
63
|
hasAudioFocus: boolean;
|
|
64
64
|
}) => void;
|
|
65
|
-
} & import("react").RefAttributes<
|
|
65
|
+
} & import("react").RefAttributes<VideoRef>>;
|
|
66
66
|
export declare const Video: typeof VideoImpl & {
|
|
67
67
|
isAvailable: boolean;
|
|
68
68
|
};
|
package/dist/video/instance.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import type {
|
|
1
|
+
import type { VideoProperties } from '@granite-js/native/react-native-video';
|
|
2
2
|
import { type ComponentType } from 'react';
|
|
3
|
-
export type VideoNativeProps = Omit<
|
|
3
|
+
export type VideoNativeProps = Omit<VideoProperties, 'onAudioFocusChanged'> & {
|
|
4
4
|
onAudioFocusChanged?: (event: {
|
|
5
5
|
hasAudioFocus: boolean;
|
|
6
6
|
}) => void;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@granite-js/react-native",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.24",
|
|
4
4
|
"description": "The Granite Framework",
|
|
5
5
|
"bin": {
|
|
6
6
|
"granite": "./bin/cli.js"
|
|
@@ -86,39 +86,39 @@
|
|
|
86
86
|
"@babel/core": "^7.24.9",
|
|
87
87
|
"@babel/preset-env": "^7.24.8",
|
|
88
88
|
"@babel/preset-typescript": "^7.24.7",
|
|
89
|
-
"@granite-js/native": "0.1.
|
|
89
|
+
"@granite-js/native": "0.1.24",
|
|
90
90
|
"@testing-library/dom": "^10.4.0",
|
|
91
91
|
"@testing-library/react": "^16.1.0",
|
|
92
92
|
"@types/babel__core": "^7",
|
|
93
93
|
"@types/babel__preset-env": "^7",
|
|
94
94
|
"@types/node": "^22.10.2",
|
|
95
|
-
"@types/react": "
|
|
95
|
+
"@types/react": "18.3.3",
|
|
96
|
+
"@types/react-dom": "^18",
|
|
96
97
|
"@vitest/coverage-v8": "^2.1.8",
|
|
97
|
-
"
|
|
98
|
-
"esbuild": "0.25.9",
|
|
98
|
+
"esbuild": "0.25.8",
|
|
99
99
|
"eslint": "^9.7.0",
|
|
100
100
|
"jsdom": "^25.0.1",
|
|
101
|
-
"react": "
|
|
102
|
-
"react-
|
|
101
|
+
"react": "18.2.0",
|
|
102
|
+
"react-dom": "18.2.0",
|
|
103
|
+
"react-native": "0.72.6",
|
|
103
104
|
"tsup": "^8.5.0",
|
|
104
105
|
"typescript": "5.8.3",
|
|
105
106
|
"vitest": "^2.1.8"
|
|
106
107
|
},
|
|
107
108
|
"peerDependencies": {
|
|
108
|
-
"@granite-js/native": "
|
|
109
|
+
"@granite-js/native": "*",
|
|
109
110
|
"@types/react": "*",
|
|
110
|
-
"brick-module": "*",
|
|
111
111
|
"react": "*",
|
|
112
112
|
"react-native": "*"
|
|
113
113
|
},
|
|
114
114
|
"dependencies": {
|
|
115
|
-
"@granite-js/cli": "0.1.
|
|
116
|
-
"@granite-js/image": "0.1.
|
|
117
|
-
"@granite-js/jest": "0.1.
|
|
118
|
-
"@granite-js/lottie": "0.1.
|
|
119
|
-
"@granite-js/mpack": "0.1.
|
|
120
|
-
"@granite-js/plugin-core": "0.1.
|
|
121
|
-
"@granite-js/style-utils": "0.1.
|
|
115
|
+
"@granite-js/cli": "0.1.24",
|
|
116
|
+
"@granite-js/image": "0.1.24",
|
|
117
|
+
"@granite-js/jest": "0.1.24",
|
|
118
|
+
"@granite-js/lottie": "0.1.24",
|
|
119
|
+
"@granite-js/mpack": "0.1.24",
|
|
120
|
+
"@granite-js/plugin-core": "0.1.24",
|
|
121
|
+
"@granite-js/style-utils": "0.1.24",
|
|
122
122
|
"es-toolkit": "^1.39.8",
|
|
123
123
|
"react-native-url-polyfill": "1.3.0"
|
|
124
124
|
}
|
package/src/app/Granite.tsx
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { ComponentType,
|
|
1
|
+
import { ComponentType, PropsWithChildren } from 'react';
|
|
2
2
|
import { AppRegistry } from 'react-native';
|
|
3
3
|
import { ENTRY_BUNDLE_NAME } from '../constants';
|
|
4
4
|
import type { InitialProps } from '../initial-props';
|
|
@@ -83,7 +83,7 @@ const createApp = () => {
|
|
|
83
83
|
registerHostApp(
|
|
84
84
|
AppContainer: ComponentType<PropsWithChildren<InitialProps>>,
|
|
85
85
|
{ appName }: Pick<GraniteProps, 'appName'>
|
|
86
|
-
): (initialProps: InitialProps) =>
|
|
86
|
+
): (initialProps: InitialProps) => JSX.Element {
|
|
87
87
|
if (appName !== ENTRY_BUNDLE_NAME) {
|
|
88
88
|
throw new Error(`Host appName must be 'shared'`);
|
|
89
89
|
}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import
|
|
1
|
+
import { RefAttributes } from 'react';
|
|
2
2
|
import { FlatList, FlatListProps } from 'react-native';
|
|
3
3
|
import withIO, { IOComponentProps } from './withIO';
|
|
4
4
|
|
|
@@ -67,6 +67,6 @@ const IOFlatList = withIO(FlatList, [
|
|
|
67
67
|
// eslint-disable-next-line @typescript-eslint/no-unused-vars
|
|
68
68
|
declare function IOFlatListFunction<ItemT = any>(
|
|
69
69
|
props: IOFlatListProps<ItemT> & RefAttributes<IOFlatListController>
|
|
70
|
-
):
|
|
70
|
+
): JSX.Element;
|
|
71
71
|
|
|
72
72
|
export default IOFlatList;
|
|
@@ -15,15 +15,4 @@ interface EventEmitter {
|
|
|
15
15
|
): EmitterSubscription;
|
|
16
16
|
}
|
|
17
17
|
|
|
18
|
-
export const nativeEventEmitter = GraniteCoreModule
|
|
19
|
-
? (new NativeEventEmitter(GraniteCoreModule) as unknown as EventEmitter)
|
|
20
|
-
: {
|
|
21
|
-
addListener: () => {
|
|
22
|
-
console.warn('[GraniteCoreModule] is not registered');
|
|
23
|
-
return {
|
|
24
|
-
remove: () => {
|
|
25
|
-
console.warn('[GraniteCoreModule] is not registered');
|
|
26
|
-
},
|
|
27
|
-
};
|
|
28
|
-
},
|
|
29
|
-
};
|
|
18
|
+
export const nativeEventEmitter = new NativeEventEmitter(GraniteCoreModule) as unknown as EventEmitter;
|
|
@@ -6,4 +6,4 @@ interface GraniteCoreModule extends TurboModule {
|
|
|
6
6
|
importLazy: () => Promise<void>;
|
|
7
7
|
}
|
|
8
8
|
|
|
9
|
-
export const GraniteCoreModule = TurboModuleRegistry.
|
|
9
|
+
export const GraniteCoreModule = TurboModuleRegistry.getEnforcing<GraniteCoreModule>('GraniteCoreModule');
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { TurboModule, TurboModuleRegistry } from 'react-native';
|
|
2
|
+
|
|
3
|
+
interface GraniteModuleSpec extends TurboModule {
|
|
4
|
+
closeView: () => void;
|
|
5
|
+
schemeUri: string;
|
|
6
|
+
}
|
|
7
|
+
|
|
8
|
+
export const GraniteModule = TurboModuleRegistry.getEnforcing<GraniteModuleSpec>('GraniteModule');
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { GraniteModule } from './GraniteModule
|
|
1
|
+
import { GraniteModule } from './GraniteModule';
|
|
2
2
|
|
|
3
3
|
/**
|
|
4
4
|
* @public
|
|
@@ -21,5 +21,5 @@ import { GraniteModule } from './GraniteModule.brick';
|
|
|
21
21
|
* ```
|
|
22
22
|
*/
|
|
23
23
|
export async function closeView() {
|
|
24
|
-
return GraniteModule
|
|
24
|
+
return GraniteModule.closeView();
|
|
25
25
|
}
|
package/src/router/Router.tsx
CHANGED
|
@@ -7,7 +7,7 @@ import {
|
|
|
7
7
|
RouteProp,
|
|
8
8
|
} from '@granite-js/native/@react-navigation/native';
|
|
9
9
|
import { NativeStackNavigationOptions } from '@granite-js/native/@react-navigation/native-stack';
|
|
10
|
-
import { ComponentProps, ComponentType, Fragment, PropsWithChildren, ReactElement, useCallback } from 'react';
|
|
10
|
+
import { ComponentProps, ComponentType, Fragment, PropsWithChildren, ReactElement, useCallback, useMemo } from 'react';
|
|
11
11
|
import { InitialProps } from '..';
|
|
12
12
|
import { closeView } from '../native-modules';
|
|
13
13
|
import { BackButton } from './components/BackButton';
|
|
@@ -89,8 +89,6 @@ type NavigationContainerProps = Pick<
|
|
|
89
89
|
'ref' | 'documentTitle' | 'fallback' | 'onReady' | 'onUnhandledAction' | 'onStateChange'
|
|
90
90
|
>;
|
|
91
91
|
|
|
92
|
-
export const navigationRef = createNavigationContainerRef<never>();
|
|
93
|
-
|
|
94
92
|
/**
|
|
95
93
|
* @category Components
|
|
96
94
|
* @kind function
|
|
@@ -143,8 +141,10 @@ export function Router({
|
|
|
143
141
|
initialScheme,
|
|
144
142
|
});
|
|
145
143
|
|
|
144
|
+
const ref = useMemo(() => navigationContainerRef ?? createNavigationContainerRef<any>(), [navigationContainerRef]);
|
|
145
|
+
|
|
146
146
|
const { handler, canGoBack, onBack } = useInternalRouterBackHandler({
|
|
147
|
-
navigationContainerRef:
|
|
147
|
+
navigationContainerRef: ref,
|
|
148
148
|
onClose: closeView,
|
|
149
149
|
});
|
|
150
150
|
|
|
@@ -164,7 +164,7 @@ export function Router({
|
|
|
164
164
|
);
|
|
165
165
|
|
|
166
166
|
return (
|
|
167
|
-
<NavigationContainer ref={
|
|
167
|
+
<NavigationContainer ref={ref} {...navigationContainerProps} linking={linkingOptions}>
|
|
168
168
|
<CanGoBackGuard canGoBack={canGoBack} onBack={onBack} setIosSwipeGestureEnabled={setIosSwipeGestureEnabled}>
|
|
169
169
|
<Container {...initialProps}>
|
|
170
170
|
<StackNavigator.Navigator initialRouteName={initialRouteName} screenOptions={screenOptions}>
|
|
@@ -48,7 +48,7 @@ export function useRouterBackHandler({
|
|
|
48
48
|
navigationContainerRef,
|
|
49
49
|
onClose,
|
|
50
50
|
}: {
|
|
51
|
-
navigationContainerRef: NavigationContainerRefWithCurrent<
|
|
51
|
+
navigationContainerRef: NavigationContainerRefWithCurrent<any>;
|
|
52
52
|
onClose?: () => void;
|
|
53
53
|
}) {
|
|
54
54
|
const { handler } = useInternalRouterBackHandler({ navigationContainerRef, onClose });
|
|
@@ -60,7 +60,7 @@ export function useInternalRouterBackHandler({
|
|
|
60
60
|
navigationContainerRef,
|
|
61
61
|
onClose,
|
|
62
62
|
}: {
|
|
63
|
-
navigationContainerRef: NavigationContainerRefWithCurrent<
|
|
63
|
+
navigationContainerRef: NavigationContainerRefWithCurrent<any>;
|
|
64
64
|
onClose?: () => void;
|
|
65
65
|
}) {
|
|
66
66
|
const { hasBackEvent, onBack } = useBackEventContext();
|
package/src/video/Video.tsx
CHANGED
|
@@ -62,7 +62,7 @@ type VideoProps = ComponentProps<typeof AnimatedRNVideo>;
|
|
|
62
62
|
* }
|
|
63
63
|
* ```
|
|
64
64
|
*/
|
|
65
|
-
const VideoImpl = forwardRef<
|
|
65
|
+
const VideoImpl = forwardRef<VideoRef, instance.VideoNativeProps>((props, ref) => {
|
|
66
66
|
const [isFocused, setIsFocused] = useState(props.muted || props.paused);
|
|
67
67
|
const visible = useVisibility();
|
|
68
68
|
|
package/src/video/instance.tsx
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import type {
|
|
1
|
+
import type { VideoProperties } from '@granite-js/native/react-native-video';
|
|
2
2
|
import { Component as ReactComponent, forwardRef, type ComponentType, type ForwardedRef } from 'react';
|
|
3
3
|
import { View } from 'react-native';
|
|
4
4
|
|
|
5
|
-
export type VideoNativeProps = Omit<
|
|
5
|
+
export type VideoNativeProps = Omit<VideoProperties, 'onAudioFocusChanged'> & {
|
|
6
6
|
onAudioFocusChanged?: (event: { hasAudioFocus: boolean }) => void;
|
|
7
7
|
};
|
|
8
8
|
|
package/dist/chunk-2PYPIQMA.mjs
DELETED
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
// src/native-modules/natives/GraniteModule.ts
|
|
2
|
-
import { TurboModuleRegistry } from "react-native";
|
|
3
|
-
var GraniteModule = TurboModuleRegistry.get("GraniteModule");
|
|
4
|
-
if (!GraniteModule) {
|
|
5
|
-
console.warn("[GraniteModule] is not registered");
|
|
6
|
-
}
|
|
7
|
-
|
|
8
|
-
export {
|
|
9
|
-
GraniteModule
|
|
10
|
-
};
|
package/dist/chunk-OWDLSIVX.mjs
DELETED
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
import { BrickModuleSpec } from 'brick-module';
|
|
2
|
-
interface GraniteModuleSpec extends BrickModuleSpec {
|
|
3
|
-
readonly moduleName: 'GraniteModule';
|
|
4
|
-
closeView(): void;
|
|
5
|
-
schemeUri: string;
|
|
6
|
-
}
|
|
7
|
-
export declare const GraniteModule: GraniteModuleSpec & {
|
|
8
|
-
addEventListener<TEvent = unknown>(eventName: never, listener: (event: TEvent) => void): () => void;
|
|
9
|
-
};
|
|
10
|
-
export {};
|
package/dist/react/index.d.ts
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export { useWaitForReturnNavigator } from './useWaitForReturnNavigator';
|
|
@@ -1,39 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* @public
|
|
3
|
-
* @category Screen Control
|
|
4
|
-
* @name useWaitForReturnNavigator
|
|
5
|
-
* @description
|
|
6
|
-
* A Hook that helps execute the next code synchronously when returning from a screen transition.
|
|
7
|
-
* Screen navigation uses [@react-navigation/native `useNavigation`'s `navigate`](https://reactnavigation.org/docs/6.x/navigation-prop#navigate).
|
|
8
|
-
*
|
|
9
|
-
* For example, it can be used when you want to log that a user has navigated to another screen and returned.
|
|
10
|
-
*
|
|
11
|
-
* @example
|
|
12
|
-
* ### Example of code execution when returning from screen navigation
|
|
13
|
-
*
|
|
14
|
-
* When the **"Navigate"** button is pressed, it navigates to another screen, and logs are created when returning.
|
|
15
|
-
*
|
|
16
|
-
* ```tsx
|
|
17
|
-
* import { Button } from 'react-native';
|
|
18
|
-
* import { useWaitForReturnNavigator } from '@granite-js/react-native';
|
|
19
|
-
*
|
|
20
|
-
* export function UseWaitForReturnNavigator() {
|
|
21
|
-
* const navigate = useWaitForReturnNavigator();
|
|
22
|
-
*
|
|
23
|
-
* return (
|
|
24
|
-
* <>
|
|
25
|
-
* <Button
|
|
26
|
-
* title="Navigate"
|
|
27
|
-
* onPress={async () => {
|
|
28
|
-
* console.log(1);
|
|
29
|
-
* await navigate('/examples/use-visibility');
|
|
30
|
-
* // This code executes when returning to the screen
|
|
31
|
-
* console.log(2);
|
|
32
|
-
* }}
|
|
33
|
-
* />
|
|
34
|
-
* </>
|
|
35
|
-
* );
|
|
36
|
-
* }
|
|
37
|
-
* ```
|
|
38
|
-
*/
|
|
39
|
-
export declare function useWaitForReturnNavigator<T extends Record<string, object | undefined>>(): <RouteName extends keyof T>(route: RouteName, params?: T[RouteName]) => Promise<void>;
|
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
import { BrickModule, BrickModuleSpec } from 'brick-module';
|
|
2
|
-
|
|
3
|
-
interface GraniteModuleSpec extends BrickModuleSpec {
|
|
4
|
-
readonly moduleName: 'GraniteModule';
|
|
5
|
-
|
|
6
|
-
closeView(): void;
|
|
7
|
-
schemeUri: string;
|
|
8
|
-
}
|
|
9
|
-
|
|
10
|
-
export const GraniteModule = BrickModule.get<GraniteModuleSpec>('GraniteModule');
|