@inploi/plugin-chatbot 14.14.0 → 14.15.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.
- package/README.md +8 -2
- package/cdn/index.js +6 -6
- package/dist/{chatbot-body-ae10ed7d.cjs → chatbot-body-4f5e817b.cjs} +2 -2
- package/dist/{chatbot-body-1dc31e4a.js → chatbot-body-e11d7ba9.js} +361 -348
- package/dist/chatbot.context.test.d.ts +1 -0
- package/dist/chatbot.d.ts +3 -1
- package/dist/chatbot.state.d.ts +4 -2
- package/dist/{index-10c0dfc6.js → index-8afa7a59.js} +735 -729
- package/dist/index-f26ac3c8.cjs +5 -0
- package/dist/plugin-chatbot.cjs +1 -1
- package/dist/plugin-chatbot.js +1 -1
- package/package.json +3 -3
- package/dist/index-1b25fb45.cjs +0 -5
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
package/dist/chatbot.d.ts
CHANGED
|
@@ -45,7 +45,9 @@ export type OpenChatbotParams = {
|
|
|
45
45
|
/** Data to be forwarded to analytics events as custom properties. */
|
|
46
46
|
customProperties?: Record<string, unknown>;
|
|
47
47
|
};
|
|
48
|
-
/**
|
|
48
|
+
/** Job context returned by the API; host context wins at every leaf. */
|
|
49
|
+
jobContext?: Record<string, unknown>;
|
|
50
|
+
/** Host context to be used by nodes internally and to identify saved drafts. */
|
|
49
51
|
context?: Record<string, unknown>;
|
|
50
52
|
/** Title to display in the status bar */
|
|
51
53
|
title: string;
|
package/dist/chatbot.state.d.ts
CHANGED
|
@@ -3,7 +3,7 @@ import { OpenChatbotParams } from '.';
|
|
|
3
3
|
import { Flow } from './chatbot.api';
|
|
4
4
|
import { ChatbotFlowProgress } from './progress';
|
|
5
5
|
|
|
6
|
-
export declare const getCacheKey: (flow: Pick<StartedFlow, "flowKeys" | "id" | "version" | "build" | "context">) => string;
|
|
6
|
+
export declare const getCacheKey: (flow: Pick<StartedFlow, "flowKeys" | "id" | "version" | "build" | "context" | "hostContext">) => string;
|
|
7
7
|
export type StartedFlow = Flow & {
|
|
8
8
|
jobAlerts?: boolean;
|
|
9
9
|
flowKeys: string[];
|
|
@@ -11,6 +11,8 @@ export type StartedFlow = Flow & {
|
|
|
11
11
|
data: FlowStateData;
|
|
12
12
|
startedAt: Date;
|
|
13
13
|
context: Record<string, unknown>;
|
|
14
|
+
/** Original host context for draft keys when interpretation includes served job context. */
|
|
15
|
+
hostContext?: Record<string, unknown>;
|
|
14
16
|
job: OpenChatbotParams['job'];
|
|
15
17
|
locationOrigin: OpenChatbotParams['locationOrigin'];
|
|
16
18
|
nodeIdToProgress: Record<string, ChatbotFlowProgress>;
|
|
@@ -55,7 +57,7 @@ type CurrentFlow = {
|
|
|
55
57
|
export declare const store: {
|
|
56
58
|
current$: import('@preact/signals').Signal<CurrentFlow>;
|
|
57
59
|
viewState$: import('@preact/signals').Signal<"closed" | "maximised" | "minimised">;
|
|
58
|
-
prepareFlow: ({ jobAlerts, flow, context, flowKeys, title, analytics, job, locationOrigin, }: OpenChatbotParams) => Promise<StartedFlow>;
|
|
60
|
+
prepareFlow: ({ jobAlerts, flow, context, jobContext, flowKeys, title, analytics, job, locationOrigin, }: OpenChatbotParams) => Promise<StartedFlow>;
|
|
59
61
|
commitFlow: (flow: StartedFlow) => void;
|
|
60
62
|
/** The candidate chose to continue or start again, so this page does not ask about this application again. */
|
|
61
63
|
settleResume: (flow: StartedFlow) => void;
|