wovvmap-webview-bridge 1.0.13 → 1.0.15
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/index.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
export { WebViewScreen } from "./webviewBridge/WebViewScreen";
|
|
2
|
-
export { sendStartPointToBridge, sendEndPointToBridge, sendActiveFloorToBridge, sendPathNextBtnClick, sendPathPreBtnClick, sendPathFinishBtnClick, } from "./webviewBridge/BridgeService";
|
|
2
|
+
export { sendStartPointToBridge, sendEndPointToBridge, sendActiveFloorToBridge, sendPathNextBtnClick, sendPathPreBtnClick, sendPathFinishBtnClick, sendGetDirectionToBridge, sendPathFilter } from "./webviewBridge/BridgeService";
|
|
3
3
|
export { BridgeStorage as useBridgeStorage } from "./webviewBridge/BridgeStorage";
|
|
4
4
|
export { registerBridgeHandler } from "./handlers/WebBridgeHandlers";
|
|
5
5
|
export type { IncomingMessage, OutgoingMessage, NodePoint, Category, FloorImage, StepInstruction, NavState, } from "./types/types";
|
package/dist/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,aAAa,EAAE,MAAM,+BAA+B,CAAC;AAG9D,OAAO,EACL,sBAAsB,EACtB,oBAAoB,EACpB,uBAAuB,EACvB,oBAAoB,EACpB,mBAAmB,EACnB,sBAAsB,
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,aAAa,EAAE,MAAM,+BAA+B,CAAC;AAG9D,OAAO,EACL,sBAAsB,EACtB,oBAAoB,EACpB,uBAAuB,EACvB,oBAAoB,EACpB,mBAAmB,EACnB,sBAAsB,EACtB,wBAAwB,EACxB,cAAc,EACf,MAAM,+BAA+B,CAAC;AAGvC,OAAQ,EAAC,aAAa,IAAI,gBAAgB,EAAC,MAAO,+BAA+B,CAAC;AAGlF,OAAO,EAAE,qBAAqB,EAAE,MAAM,8BAA8B,CAAC;AAGrE,YAAY,EACV,eAAe,EACf,eAAe,EACf,SAAS,EACT,QAAQ,EACR,UAAU,EACV,eAAe,EACf,QAAQ,GACT,MAAM,eAAe,CAAC"}
|
package/dist/index.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
// Components
|
|
2
2
|
export { WebViewScreen } from "./webviewBridge/WebViewScreen";
|
|
3
3
|
// Bridge helpers (named exports)
|
|
4
|
-
export { sendStartPointToBridge, sendEndPointToBridge, sendActiveFloorToBridge, sendPathNextBtnClick, sendPathPreBtnClick, sendPathFinishBtnClick, } from "./webviewBridge/BridgeService";
|
|
4
|
+
export { sendStartPointToBridge, sendEndPointToBridge, sendActiveFloorToBridge, sendPathNextBtnClick, sendPathPreBtnClick, sendPathFinishBtnClick, sendGetDirectionToBridge, sendPathFilter } from "./webviewBridge/BridgeService";
|
|
5
5
|
// State/store
|
|
6
6
|
export { BridgeStorage as useBridgeStorage } from "./webviewBridge/BridgeStorage";
|
|
7
7
|
// Handlers
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"WebViewScreen.d.ts","sourceRoot":"","sources":["../../src/webviewBridge/WebViewScreen.tsx"],"names":[],"mappings":"AAMA,KAAK,KAAK,GAAG;IACX,GAAG,EAAE,MAAM,CAAC;IACZ,MAAM,CAAC,EAAE,MAAI,IAAI,CAAA;CAClB,CAAC;AAGF,eAAO,MAAM,aAAa,GAAI,iBAAiB,KAAK,
|
|
1
|
+
{"version":3,"file":"WebViewScreen.d.ts","sourceRoot":"","sources":["../../src/webviewBridge/WebViewScreen.tsx"],"names":[],"mappings":"AAMA,KAAK,KAAK,GAAG;IACX,GAAG,EAAE,MAAM,CAAC;IACZ,MAAM,CAAC,EAAE,MAAI,IAAI,CAAA;CAClB,CAAC;AAGF,eAAO,MAAM,aAAa,GAAI,iBAAiB,KAAK,4CA4BnD,CAAC"}
|
|
@@ -1,12 +1,13 @@
|
|
|
1
1
|
import { jsx as _jsx } from "react/jsx-runtime";
|
|
2
2
|
import { handleBridgeMessage } from "../handlers/WebBridgeHandlers";
|
|
3
|
+
import { webviewRef } from "./WebViewBridgeRef";
|
|
3
4
|
import { WebView } from 'react-native-webview';
|
|
4
5
|
export const WebViewScreen = ({ url, onload }) => {
|
|
5
6
|
const onMessage = (event) => {
|
|
6
7
|
console.log("on message event", event);
|
|
7
8
|
handleBridgeMessage(event);
|
|
8
9
|
};
|
|
9
|
-
return (_jsx(WebView, { source: { uri: url }, onMessage: onMessage, onLoadStart: () => console.log("WebView: load start", url), onLoadEnd: () => {
|
|
10
|
+
return (_jsx(WebView, { ref: webviewRef, source: { uri: url }, onMessage: onMessage, onLoadStart: () => console.log("WebView: load start", url), onLoadEnd: () => {
|
|
10
11
|
if (onload) {
|
|
11
12
|
onload();
|
|
12
13
|
}
|