@encatch/ws-react 0.1.0-beta.18 → 0.1.0-beta.20
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/iframe-messages.d.ts +2 -2
- package/dist/types.d.ts +9 -0
- package/package.json +3 -3
|
@@ -4,9 +4,9 @@
|
|
|
4
4
|
* EncatchPreview (parent) and the iframe form page.
|
|
5
5
|
*/
|
|
6
6
|
/** Message types sent from parent (EncatchPreview) to iframe */
|
|
7
|
-
export type SDKMessageType = "sdk:formConfig" | "sdk:theme" | "sdk:locale" | "sdk:resetData" | "sdk:prefillResponses";
|
|
7
|
+
export type SDKMessageType = "sdk:formConfig" | "sdk:theme" | "sdk:locale" | "sdk:resetData" | "sdk:prefillResponses" | "sdk:refineTextResponse" | "sdk:submitPartialBeforeDismiss";
|
|
8
8
|
/** Message types sent from iframe to parent */
|
|
9
|
-
export type FormMessageType = "form:ready" | "form:submit" | "form:complete" | "form:close" | "form:error" | "form:resize" | "form:themeData";
|
|
9
|
+
export type FormMessageType = "form:ready" | "form:submit" | "form:complete" | "form:close" | "form:error" | "form:resize" | "form:themeData" | "form:refineTextRequest" | "form:readyToDismiss";
|
|
10
10
|
/** Event-publisher messages (prefixed with encatch:) from iframe to parent */
|
|
11
11
|
export type EncatchFormEventType = "encatch:form:show" | "encatch:form:started" | "encatch:form:section:change" | "encatch:form:answered";
|
|
12
12
|
export interface SDKMessage {
|
package/dist/types.d.ts
CHANGED
|
@@ -17,6 +17,15 @@ export interface EncatchFormConfig {
|
|
|
17
17
|
translations?: Record<string, unknown>;
|
|
18
18
|
/** Initial locale for preview (e.g. from admin language selector). If set, iframe applies it on sdk:formConfig. */
|
|
19
19
|
initialLocale?: string;
|
|
20
|
+
/** When true, form navigation follows logicJumpRules instead of linear section order. */
|
|
21
|
+
isLogicJumpsEnabled?: boolean;
|
|
22
|
+
/** Conditional navigation rules keyed by question ID (or '__workflow_start__'). */
|
|
23
|
+
logicJumpRules?: Record<string, Array<{
|
|
24
|
+
jsonLogic: unknown;
|
|
25
|
+
targetQuestionId: string;
|
|
26
|
+
}>>;
|
|
27
|
+
/** Context variable keys expected by the form (informational). */
|
|
28
|
+
contextVariables?: string[];
|
|
20
29
|
};
|
|
21
30
|
appearanceProperties?: {
|
|
22
31
|
themes?: {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@encatch/ws-react",
|
|
3
|
-
"version": "0.1.0-beta.
|
|
3
|
+
"version": "0.1.0-beta.20",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"main": "./dist/index.umd.js",
|
|
6
6
|
"module": "./dist/index.es.js",
|
|
@@ -20,8 +20,8 @@
|
|
|
20
20
|
"react-dom": "^19.1.1"
|
|
21
21
|
},
|
|
22
22
|
"dependencies": {
|
|
23
|
-
"@encatch/schema": "1.1.0-beta.
|
|
24
|
-
"@encatch/event-publisher": "1.0.0-beta.
|
|
23
|
+
"@encatch/schema": "1.1.0-beta.8",
|
|
24
|
+
"@encatch/event-publisher": "1.0.0-beta.4"
|
|
25
25
|
},
|
|
26
26
|
"devDependencies": {
|
|
27
27
|
"@eslint/js": "^9.36.0",
|