@selfhelp/sh2-shp-survey-js-mobile 0.3.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.
@@ -0,0 +1,30 @@
1
+ import { IMobilePluginRegistration } from '@selfhelp/shared/plugin-sdk';
2
+
3
+ /**
4
+ * `@selfhelp/sh2-shp-survey-js-mobile` — mobile entry.
5
+ *
6
+ * Bundled into mobile builds by the host's `plugins:sync` script
7
+ * (per EAS profile). Exports `registerMobile` which returns the
8
+ * plugin's `IMobilePluginRegistration` — the `surveyjs` style.
9
+ *
10
+ * The style (`styles/SurveyJsStyle`) is a thin native shell that hosts the
11
+ * OFFICIAL SurveyJS web runtime (`survey-core` + `survey-react-ui`) inside an
12
+ * isolated, self-contained WebView — `react-native-webview` on native, an
13
+ * `iframe` on the Expo web export — driven by a typed postMessage bridge.
14
+ * This gives mobile full parity with the web frontend (same JSON, question
15
+ * types, validation, conditional logic, completion, redirect). The native
16
+ * host owns ALL authenticated API calls via `@selfhelp/shared`
17
+ * `MobileHostServices`; the WebView never sees the access token.
18
+ */
19
+
20
+ declare const PLUGIN_ID = "sh2-shp-survey-js";
21
+ /**
22
+ * Must match `plugin.json#version` and the mobile `package.json#version`.
23
+ * `PluginRuntime.registerOne()` (web) and the mobile sync script both
24
+ * compare these constants against the manifest version; a mismatch
25
+ * silently breaks the plugin.
26
+ */
27
+ declare const PLUGIN_VERSION = "0.3.0";
28
+ declare const registerMobile: () => IMobilePluginRegistration;
29
+
30
+ export { PLUGIN_ID, PLUGIN_VERSION, registerMobile as default, registerMobile };
@@ -0,0 +1,30 @@
1
+ import { IMobilePluginRegistration } from '@selfhelp/shared/plugin-sdk';
2
+
3
+ /**
4
+ * `@selfhelp/sh2-shp-survey-js-mobile` — mobile entry.
5
+ *
6
+ * Bundled into mobile builds by the host's `plugins:sync` script
7
+ * (per EAS profile). Exports `registerMobile` which returns the
8
+ * plugin's `IMobilePluginRegistration` — the `surveyjs` style.
9
+ *
10
+ * The style (`styles/SurveyJsStyle`) is a thin native shell that hosts the
11
+ * OFFICIAL SurveyJS web runtime (`survey-core` + `survey-react-ui`) inside an
12
+ * isolated, self-contained WebView — `react-native-webview` on native, an
13
+ * `iframe` on the Expo web export — driven by a typed postMessage bridge.
14
+ * This gives mobile full parity with the web frontend (same JSON, question
15
+ * types, validation, conditional logic, completion, redirect). The native
16
+ * host owns ALL authenticated API calls via `@selfhelp/shared`
17
+ * `MobileHostServices`; the WebView never sees the access token.
18
+ */
19
+
20
+ declare const PLUGIN_ID = "sh2-shp-survey-js";
21
+ /**
22
+ * Must match `plugin.json#version` and the mobile `package.json#version`.
23
+ * `PluginRuntime.registerOne()` (web) and the mobile sync script both
24
+ * compare these constants against the manifest version; a mismatch
25
+ * silently breaks the plugin.
26
+ */
27
+ declare const PLUGIN_VERSION = "0.3.0";
28
+ declare const registerMobile: () => IMobilePluginRegistration;
29
+
30
+ export { PLUGIN_ID, PLUGIN_VERSION, registerMobile as default, registerMobile };