@botonic/plugin-flow-builder 0.25.0-beta.0 → 0.26.0-alpha.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/lib/cjs/action/index.d.ts +3 -8
- package/lib/cjs/action/index.js +1 -1
- package/lib/cjs/action/index.js.map +1 -1
- package/lib/cjs/action/knowledge-bases.js +2 -1
- package/lib/cjs/action/knowledge-bases.js.map +1 -1
- package/lib/cjs/api.d.ts +4 -1
- package/lib/cjs/api.js +20 -4
- package/lib/cjs/api.js.map +1 -1
- package/lib/cjs/constants.d.ts +1 -0
- package/lib/cjs/constants.js +2 -1
- package/lib/cjs/constants.js.map +1 -1
- package/lib/cjs/content-fields/flow-handoff.js +1 -1
- package/lib/cjs/content-fields/flow-handoff.js.map +1 -1
- package/lib/cjs/content-fields/hubtype-fields/common.d.ts +1 -0
- package/lib/cjs/content-fields/hubtype-fields/index.d.ts +1 -0
- package/lib/cjs/content-fields/hubtype-fields/index.js +1 -0
- package/lib/cjs/content-fields/hubtype-fields/index.js.map +1 -1
- package/lib/cjs/content-fields/hubtype-fields/node-types.d.ts +1 -0
- package/lib/cjs/content-fields/hubtype-fields/node-types.js +1 -0
- package/lib/cjs/content-fields/hubtype-fields/node-types.js.map +1 -1
- package/lib/cjs/content-fields/hubtype-fields/nodes.d.ts +2 -1
- package/lib/cjs/content-fields/hubtype-fields/smart-intent.d.ts +11 -0
- package/lib/cjs/content-fields/hubtype-fields/smart-intent.js +3 -0
- package/lib/cjs/content-fields/hubtype-fields/smart-intent.js.map +1 -0
- package/lib/cjs/index.d.ts +5 -3
- package/lib/cjs/index.js +15 -4
- package/lib/cjs/index.js.map +1 -1
- package/lib/cjs/{action/tracking.js → tracking.js} +1 -1
- package/lib/cjs/tracking.js.map +1 -0
- package/lib/cjs/types.d.ts +7 -2
- package/lib/cjs/types.js +6 -1
- package/lib/cjs/types.js.map +1 -1
- package/lib/cjs/user-input/index.d.ts +4 -0
- package/lib/cjs/{action/user-input.js → user-input/index.js} +8 -4
- package/lib/cjs/user-input/index.js.map +1 -0
- package/lib/cjs/{action → user-input}/intent.js +1 -1
- package/lib/cjs/user-input/intent.js.map +1 -0
- package/lib/cjs/{action → user-input}/keyword.js +1 -1
- package/lib/cjs/user-input/keyword.js.map +1 -0
- package/lib/cjs/user-input/smart-intent.d.ts +4 -0
- package/lib/cjs/user-input/smart-intent.js +40 -0
- package/lib/cjs/user-input/smart-intent.js.map +1 -0
- package/lib/cjs/webview/contents-context.d.ts +3 -0
- package/lib/cjs/webview/contents-context.js +10 -0
- package/lib/cjs/webview/contents-context.js.map +1 -0
- package/lib/cjs/webview/index.d.ts +3 -0
- package/lib/cjs/webview/index.js +10 -0
- package/lib/cjs/webview/index.js.map +1 -0
- package/lib/cjs/webview/types.d.ts +46 -0
- package/lib/cjs/webview/types.js +9 -0
- package/lib/cjs/webview/types.js.map +1 -0
- package/lib/cjs/webview/use-webview-contents.d.ts +2 -0
- package/lib/cjs/webview/use-webview-contents.js +58 -0
- package/lib/cjs/webview/use-webview-contents.js.map +1 -0
- package/lib/esm/action/index.d.ts +3 -8
- package/lib/esm/action/index.js +1 -1
- package/lib/esm/action/index.js.map +1 -1
- package/lib/esm/action/knowledge-bases.js +2 -1
- package/lib/esm/action/knowledge-bases.js.map +1 -1
- package/lib/esm/api.d.ts +4 -1
- package/lib/esm/api.js +20 -4
- package/lib/esm/api.js.map +1 -1
- package/lib/esm/constants.d.ts +1 -0
- package/lib/esm/constants.js +1 -0
- package/lib/esm/constants.js.map +1 -1
- package/lib/esm/content-fields/flow-handoff.js +1 -1
- package/lib/esm/content-fields/flow-handoff.js.map +1 -1
- package/lib/esm/content-fields/hubtype-fields/common.d.ts +1 -0
- package/lib/esm/content-fields/hubtype-fields/index.d.ts +1 -0
- package/lib/esm/content-fields/hubtype-fields/index.js +1 -0
- package/lib/esm/content-fields/hubtype-fields/index.js.map +1 -1
- package/lib/esm/content-fields/hubtype-fields/node-types.d.ts +1 -0
- package/lib/esm/content-fields/hubtype-fields/node-types.js +1 -0
- package/lib/esm/content-fields/hubtype-fields/node-types.js.map +1 -1
- package/lib/esm/content-fields/hubtype-fields/nodes.d.ts +2 -1
- package/lib/esm/content-fields/hubtype-fields/smart-intent.d.ts +11 -0
- package/lib/esm/content-fields/hubtype-fields/smart-intent.js +2 -0
- package/lib/esm/content-fields/hubtype-fields/smart-intent.js.map +1 -0
- package/lib/esm/index.d.ts +5 -3
- package/lib/esm/index.js +14 -5
- package/lib/esm/index.js.map +1 -1
- package/lib/esm/{action/tracking.js → tracking.js} +1 -1
- package/lib/esm/tracking.js.map +1 -0
- package/lib/esm/types.d.ts +7 -2
- package/lib/esm/types.js +5 -0
- package/lib/esm/types.js.map +1 -1
- package/lib/esm/user-input/index.d.ts +4 -0
- package/lib/esm/{action/user-input.js → user-input/index.js} +8 -4
- package/lib/esm/user-input/index.js.map +1 -0
- package/lib/esm/{action → user-input}/intent.js +1 -1
- package/lib/esm/user-input/intent.js.map +1 -0
- package/lib/esm/{action → user-input}/keyword.js +1 -1
- package/lib/esm/user-input/keyword.js.map +1 -0
- package/lib/esm/user-input/smart-intent.d.ts +4 -0
- package/lib/esm/user-input/smart-intent.js +36 -0
- package/lib/esm/user-input/smart-intent.js.map +1 -0
- package/lib/esm/webview/contents-context.d.ts +3 -0
- package/lib/esm/webview/contents-context.js +7 -0
- package/lib/esm/webview/contents-context.js.map +1 -0
- package/lib/esm/webview/index.d.ts +3 -0
- package/lib/esm/webview/index.js +4 -0
- package/lib/esm/webview/index.js.map +1 -0
- package/lib/esm/webview/types.d.ts +46 -0
- package/lib/esm/webview/types.js +6 -0
- package/lib/esm/webview/types.js.map +1 -0
- package/lib/esm/webview/use-webview-contents.d.ts +2 -0
- package/lib/esm/webview/use-webview-contents.js +54 -0
- package/lib/esm/webview/use-webview-contents.js.map +1 -0
- package/package.json +2 -2
- package/src/action/index.tsx +1 -1
- package/src/action/knowledge-bases.ts +2 -1
- package/src/api.ts +30 -4
- package/src/constants.ts +2 -0
- package/src/content-fields/flow-handoff.tsx +1 -1
- package/src/content-fields/hubtype-fields/common.ts +1 -0
- package/src/content-fields/hubtype-fields/index.ts +1 -0
- package/src/content-fields/hubtype-fields/node-types.ts +1 -0
- package/src/content-fields/hubtype-fields/nodes.ts +2 -0
- package/src/content-fields/hubtype-fields/smart-intent.ts +12 -0
- package/src/index.ts +25 -8
- package/src/{action/tracking.ts → tracking.ts} +1 -1
- package/src/types.ts +8 -2
- package/src/{action/user-input.ts → user-input/index.ts} +13 -5
- package/src/{action → user-input}/intent.ts +1 -1
- package/src/{action → user-input}/keyword.ts +1 -1
- package/src/user-input/smart-intent.ts +42 -0
- package/src/webview/contents-context.ts +11 -0
- package/src/webview/index.ts +3 -0
- package/src/webview/types.ts +47 -0
- package/src/webview/use-webview-contents.ts +78 -0
- package/lib/cjs/action/intent.js.map +0 -1
- package/lib/cjs/action/keyword.js.map +0 -1
- package/lib/cjs/action/tracking.js.map +0 -1
- package/lib/cjs/action/user-input.d.ts +0 -4
- package/lib/cjs/action/user-input.js.map +0 -1
- package/lib/esm/action/intent.js.map +0 -1
- package/lib/esm/action/keyword.js.map +0 -1
- package/lib/esm/action/tracking.js.map +0 -1
- package/lib/esm/action/user-input.d.ts +0 -4
- package/lib/esm/action/user-input.js.map +0 -1
- /package/lib/cjs/{action/tracking.d.ts → tracking.d.ts} +0 -0
- /package/lib/cjs/{action → user-input}/intent.d.ts +0 -0
- /package/lib/cjs/{action → user-input}/keyword.d.ts +0 -0
- /package/lib/esm/{action/tracking.d.ts → tracking.d.ts} +0 -0
- /package/lib/esm/{action → user-input}/intent.d.ts +0 -0
- /package/lib/esm/{action → user-input}/keyword.d.ts +0 -0
|
@@ -1,19 +1,21 @@
|
|
|
1
1
|
import { ActionRequest } from '@botonic/react'
|
|
2
2
|
|
|
3
3
|
import { FlowBuilderApi } from '../api'
|
|
4
|
-
import {
|
|
4
|
+
import {
|
|
5
|
+
HtIntentNode,
|
|
6
|
+
HtKeywordNode,
|
|
7
|
+
HtSmartIntentNode,
|
|
8
|
+
} from '../content-fields/hubtype-fields'
|
|
5
9
|
import { getIntentNodeByInput } from './intent'
|
|
6
10
|
import { getKeywordNodeByInput } from './keyword'
|
|
11
|
+
import { getSmartIntentNodeByInput } from './smart-intent'
|
|
7
12
|
|
|
8
13
|
export async function getNodeByUserInput(
|
|
9
14
|
cmsApi: FlowBuilderApi,
|
|
10
15
|
locale: string,
|
|
11
16
|
request: ActionRequest
|
|
12
|
-
): Promise<HtIntentNode | HtKeywordNode | undefined> {
|
|
17
|
+
): Promise<HtSmartIntentNode | HtIntentNode | HtKeywordNode | undefined> {
|
|
13
18
|
if (request.input.data) {
|
|
14
|
-
const intentNode = await getIntentNodeByInput(cmsApi, locale, request)
|
|
15
|
-
if (intentNode) return intentNode
|
|
16
|
-
|
|
17
19
|
const keywordNode = await getKeywordNodeByInput(
|
|
18
20
|
cmsApi,
|
|
19
21
|
locale,
|
|
@@ -21,6 +23,12 @@ export async function getNodeByUserInput(
|
|
|
21
23
|
request.input.data
|
|
22
24
|
)
|
|
23
25
|
if (keywordNode) return keywordNode
|
|
26
|
+
|
|
27
|
+
const smartIntentNode = await getSmartIntentNodeByInput(cmsApi, request)
|
|
28
|
+
if (smartIntentNode) return smartIntentNode
|
|
29
|
+
|
|
30
|
+
const intentNode = await getIntentNodeByInput(cmsApi, locale, request)
|
|
31
|
+
if (intentNode) return intentNode
|
|
24
32
|
}
|
|
25
33
|
return undefined
|
|
26
34
|
}
|
|
@@ -2,7 +2,7 @@ import { ActionRequest } from '@botonic/react'
|
|
|
2
2
|
|
|
3
3
|
import { FlowBuilderApi } from '../api'
|
|
4
4
|
import { HtIntentNode } from '../content-fields/hubtype-fields'
|
|
5
|
-
import { EventName, trackEvent } from '
|
|
5
|
+
import { EventName, trackEvent } from '../tracking'
|
|
6
6
|
|
|
7
7
|
export async function getIntentNodeByInput(
|
|
8
8
|
cmsApi: FlowBuilderApi,
|
|
@@ -2,7 +2,7 @@ import { ActionRequest } from '@botonic/react'
|
|
|
2
2
|
|
|
3
3
|
import { FlowBuilderApi } from '../api'
|
|
4
4
|
import { HtKeywordNode } from '../content-fields/hubtype-fields'
|
|
5
|
-
import { EventName, trackEvent } from '
|
|
5
|
+
import { EventName, trackEvent } from '../tracking'
|
|
6
6
|
|
|
7
7
|
export async function getKeywordNodeByInput(
|
|
8
8
|
cmsApi: FlowBuilderApi,
|
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
import { ActionRequest } from '@botonic/react'
|
|
2
|
+
import axios from 'axios'
|
|
3
|
+
|
|
4
|
+
import { FlowBuilderApi } from '../api'
|
|
5
|
+
import { HtSmartIntentNode } from '../content-fields/hubtype-fields/smart-intent'
|
|
6
|
+
|
|
7
|
+
export async function getSmartIntentNodeByInput(
|
|
8
|
+
cmsApi: FlowBuilderApi,
|
|
9
|
+
request: ActionRequest
|
|
10
|
+
): Promise<HtSmartIntentNode | undefined> {
|
|
11
|
+
const smartIntentNodes = cmsApi.getSmartIntentNodes()
|
|
12
|
+
const intentsInferenceParams = smartIntentNodes.map(smartIntentNode => {
|
|
13
|
+
return {
|
|
14
|
+
name: smartIntentNode.content.title,
|
|
15
|
+
definition: smartIntentNode.content.description,
|
|
16
|
+
}
|
|
17
|
+
})
|
|
18
|
+
intentsInferenceParams.push({
|
|
19
|
+
name: 'Other',
|
|
20
|
+
definition: 'The text does not belong to any other intent.',
|
|
21
|
+
})
|
|
22
|
+
try {
|
|
23
|
+
const response = await axios({
|
|
24
|
+
method: 'POST',
|
|
25
|
+
url: `${process.env.HUBTYPE_API_URL}/external/v1/ai/smart_intents/inference/`,
|
|
26
|
+
headers: {
|
|
27
|
+
Authorization: `Bearer ${request.session._access_token}`,
|
|
28
|
+
'Content-Type': 'application/json',
|
|
29
|
+
},
|
|
30
|
+
data: { text: request.input.data, intents: intentsInferenceParams },
|
|
31
|
+
timeout: 10000,
|
|
32
|
+
})
|
|
33
|
+
console.log({ response })
|
|
34
|
+
return smartIntentNodes.find(
|
|
35
|
+
smartIntentNode =>
|
|
36
|
+
smartIntentNode.content.title === response.data.intent_name
|
|
37
|
+
)
|
|
38
|
+
} catch (e) {
|
|
39
|
+
console.error(e)
|
|
40
|
+
return undefined
|
|
41
|
+
}
|
|
42
|
+
}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { createContext } from 'react'
|
|
2
|
+
|
|
3
|
+
import { WebviewContentsContextType } from './types'
|
|
4
|
+
|
|
5
|
+
export const WebviewContentsContext = createContext<WebviewContentsContextType>(
|
|
6
|
+
{
|
|
7
|
+
getTextContent: () => undefined,
|
|
8
|
+
getImageSrc: () => undefined,
|
|
9
|
+
setCurrentLocale: () => undefined,
|
|
10
|
+
}
|
|
11
|
+
)
|
|
@@ -0,0 +1,47 @@
|
|
|
1
|
+
import { FlowBuilderJSONVersion } from '../types'
|
|
2
|
+
|
|
3
|
+
export enum WebviewContentType {
|
|
4
|
+
TEXT = 'webview-text',
|
|
5
|
+
IMAGE = 'webview-image',
|
|
6
|
+
}
|
|
7
|
+
|
|
8
|
+
export interface WebviewContentsResponse {
|
|
9
|
+
webview_contents: (WebviewTextContent | WebviewImageContent)[]
|
|
10
|
+
}
|
|
11
|
+
|
|
12
|
+
export interface WebviewTextContent {
|
|
13
|
+
code: string
|
|
14
|
+
type: WebviewContentType.TEXT
|
|
15
|
+
content: {
|
|
16
|
+
text: { message: string; locale: string }[]
|
|
17
|
+
}
|
|
18
|
+
}
|
|
19
|
+
|
|
20
|
+
export interface WebviewImageContent {
|
|
21
|
+
code: string
|
|
22
|
+
type: WebviewContentType.IMAGE
|
|
23
|
+
content: {
|
|
24
|
+
image: { file: string; locale: string }[]
|
|
25
|
+
}
|
|
26
|
+
}
|
|
27
|
+
|
|
28
|
+
export interface UseWebviewContentsProps {
|
|
29
|
+
apiUrl?: string
|
|
30
|
+
version?: FlowBuilderJSONVersion
|
|
31
|
+
orgId: string
|
|
32
|
+
botId: string
|
|
33
|
+
webviewId: string
|
|
34
|
+
locale: string
|
|
35
|
+
}
|
|
36
|
+
|
|
37
|
+
export interface UseWebviewContents {
|
|
38
|
+
isLoading: boolean
|
|
39
|
+
error: boolean
|
|
40
|
+
webviewContentsContext: WebviewContentsContextType
|
|
41
|
+
}
|
|
42
|
+
|
|
43
|
+
export interface WebviewContentsContextType {
|
|
44
|
+
getTextContent: (code: string) => string | undefined
|
|
45
|
+
getImageSrc: (code: string) => string | undefined
|
|
46
|
+
setCurrentLocale: (locale: string) => void
|
|
47
|
+
}
|
|
@@ -0,0 +1,78 @@
|
|
|
1
|
+
import axios from 'axios'
|
|
2
|
+
import { useEffect, useState } from 'react'
|
|
3
|
+
|
|
4
|
+
import { FLOW_BUILDER_API_URL_PROD } from '../constants'
|
|
5
|
+
import { FlowBuilderJSONVersion } from '../types'
|
|
6
|
+
import {
|
|
7
|
+
UseWebviewContents,
|
|
8
|
+
UseWebviewContentsProps,
|
|
9
|
+
WebviewContentsResponse,
|
|
10
|
+
WebviewContentType,
|
|
11
|
+
WebviewImageContent,
|
|
12
|
+
WebviewTextContent,
|
|
13
|
+
} from './types'
|
|
14
|
+
|
|
15
|
+
export function useWebviewContents({
|
|
16
|
+
apiUrl = FLOW_BUILDER_API_URL_PROD,
|
|
17
|
+
version = FlowBuilderJSONVersion.LATEST,
|
|
18
|
+
orgId,
|
|
19
|
+
botId,
|
|
20
|
+
webviewId,
|
|
21
|
+
locale,
|
|
22
|
+
}: UseWebviewContentsProps): UseWebviewContents {
|
|
23
|
+
const [textContents, setTextContents] = useState<WebviewTextContent[]>()
|
|
24
|
+
const [imageContents, setImageContents] = useState<WebviewImageContent[]>()
|
|
25
|
+
const [currentLocale, setCurrentLocale] = useState(locale)
|
|
26
|
+
const [isLoading, setLoading] = useState(false)
|
|
27
|
+
const [error, setError] = useState(false)
|
|
28
|
+
|
|
29
|
+
useEffect(() => {
|
|
30
|
+
const getResponseContents = async () => {
|
|
31
|
+
setLoading(true)
|
|
32
|
+
const url = `${apiUrl}/webview/${version}`
|
|
33
|
+
try {
|
|
34
|
+
const response = await axios.get<WebviewContentsResponse>(url, {
|
|
35
|
+
params: { org: orgId, bot: botId, webview: webviewId },
|
|
36
|
+
})
|
|
37
|
+
|
|
38
|
+
const textResponseContents = response.data.webview_contents.filter(
|
|
39
|
+
webviewContent => webviewContent.type === WebviewContentType.TEXT
|
|
40
|
+
) as WebviewTextContent[]
|
|
41
|
+
setTextContents(textResponseContents)
|
|
42
|
+
|
|
43
|
+
const imageResponseContents = response.data.webview_contents.filter(
|
|
44
|
+
webviewContent => webviewContent.type === WebviewContentType.IMAGE
|
|
45
|
+
) as WebviewImageContent[]
|
|
46
|
+
setImageContents(imageResponseContents)
|
|
47
|
+
} catch (error) {
|
|
48
|
+
console.error('Error fetching webview contents:', error)
|
|
49
|
+
setError(true)
|
|
50
|
+
} finally {
|
|
51
|
+
setLoading(false)
|
|
52
|
+
}
|
|
53
|
+
}
|
|
54
|
+
getResponseContents()
|
|
55
|
+
}, [])
|
|
56
|
+
|
|
57
|
+
const getTextContent = (contentID: string): string | undefined => {
|
|
58
|
+
return textContents
|
|
59
|
+
?.find(textContent => textContent.code === contentID)
|
|
60
|
+
?.content.text.find(text => text.locale === currentLocale)?.message
|
|
61
|
+
}
|
|
62
|
+
|
|
63
|
+
const getImageSrc = (contentID: string): string | undefined => {
|
|
64
|
+
return imageContents
|
|
65
|
+
?.find(imageContent => imageContent.code === contentID)
|
|
66
|
+
?.content.image.find(image => image.locale === currentLocale)?.file
|
|
67
|
+
}
|
|
68
|
+
|
|
69
|
+
return {
|
|
70
|
+
isLoading,
|
|
71
|
+
error,
|
|
72
|
+
webviewContentsContext: {
|
|
73
|
+
getTextContent,
|
|
74
|
+
getImageSrc,
|
|
75
|
+
setCurrentLocale,
|
|
76
|
+
},
|
|
77
|
+
}
|
|
78
|
+
}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"intent.js","sourceRoot":"","sources":["../../../src/action/intent.ts"],"names":[],"mappings":";;;;AAIA,yCAA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CAAC,gBAAgB,CAAC,SAAS,EAAE,MAAM,CAAC,CAAA;QAC9D,IAAI,CAAC,WAAW,EAAE;YAChB,OAAO,SAAS,CAAA;SACjB;QACD,MAAM,SAAS,GAAG;YAChB,qBAAqB,EAAE,IAAI;SAC5B,CAAA;QACD,MAAM,IAAA,qBAAU,EAAC,OAAO,EAAE,oBAAS,CAAC,gBAAgB,EAAE,SAAS,CAAC,CAAA;QAChE,OAAO,WAAW,CAAA;IACpB,CAAC;CAAA;AAfD,sDAeC"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"tracking.js","sourceRoot":"","sources":["../../../src/action/tracking.ts"],"names":[],"mappings":";;;;AAEA,wCAAiD;AAEjD,SAAsB,UAAU,CAC9B,OAAsB,EACtB,SAAoB,EACpB,IAA0B;;QAE1B,MAAM,iBAAiB,GAAG,IAAA,8BAAoB,EAAC,OAAO,CAAC,OAAO,CAAC,CAAA;QAC/D,IAAI,iBAAiB,CAAC,UAAU,EAAE;YAChC,MAAM,iBAAiB,CAAC,UAAU,CAAC,OAAO,EAAE,SAAS,EAAE,IAAI,CAAC,CAAA;SAC7D;QACD,OAAM;IACR,CAAC;CAAA;AAVD,gCAUC;AAED,IAAY,SAeX;AAfD,WAAY,SAAS;IACnB,gDAAmC,CAAA;IACnC,oDAAuC,CAAA;IACvC,4CAA+B,CAAA;IAC/B,qCAAwB,CAAA;IACxB,+BAAkB,CAAA;IAClB,mCAAsB,CAAA;IACtB,iCAAoB,CAAA;IACpB,wCAA2B,CAAA;IAC3B,yDAA4C,CAAA;IAC5C,oDAAuC,CAAA;IACvC,kCAAqB,CAAA;IACrB,6CAAgC,CAAA;IAChC,+CAAkC,CAAA;IAClC,yCAA4B,CAAA;AAC9B,CAAC,EAfW,SAAS,GAAT,iBAAS,KAAT,iBAAS,QAepB"}
|
|
@@ -1,4 +0,0 @@
|
|
|
1
|
-
import { ActionRequest } from '@botonic/react';
|
|
2
|
-
import { FlowBuilderApi } from '../api';
|
|
3
|
-
import { HtIntentNode, HtKeywordNode } from '../content-fields/hubtype-fields';
|
|
4
|
-
export declare function getNodeByUserInput(cmsApi: FlowBuilderApi, locale: string, request: ActionRequest): Promise<HtIntentNode | HtKeywordNode | undefined>;
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"user-input.js","sourceRoot":"","sources":["../../../src/action/user-input.ts"],"names":[],"mappings":";;;;AAIA,qCAA+C;AAC/C,uCAAiD;AAEjD,SAAsB,kBAAkB,CACtC,MAAsB,EACtB,MAAc,EACd,OAAsB;;QAEtB,IAAI,OAAO,CAAC,KAAK,CAAC,IAAI,EAAE;YACtB,MAAM,UAAU,GAAG,MAAM,IAAA,6BAAoB,EAAC,MAAM,EAAE,MAAM,EAAE,OAAO,CAAC,CAAA;YACtE,IAAI,UAAU;gBAAE,OAAO,UAAU,CAAA;YAEjC,MAAM,WAAW,GAAG,MAAM,IAAA,+BAAqB,EAC7C,MAAM,EACN,MAAM,EACN,OAAO,EACP,OAAO,CAAC,KAAK,CAAC,IAAI,CACnB,CAAA;YACD,IAAI,WAAW;gBAAE,OAAO,WAAW,CAAA;SACpC;QACD,OAAO,SAAS,CAAA;IAClB,CAAC;CAAA;AAlBD,gDAkBC"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"intent.js","sourceRoot":"","sources":["../../../src/action/intent.ts"],"names":[],"mappings":";AAIA,OAAO,EAAE,SAAS,EAAE,UAAU,EAAE,MAAM,YAAY,CAAA;AAElD,MAAM,UAAgB,oBAAoB,CACxC,MAAsB,EACtB,MAAc,EACd,OAAsB;;QAEtB,MAAM,UAAU,GAAG,MAAM,CAAC,aAAa,CAAC,OAAO,CAAC,KAAK,EAAE,MAAM,CAAC,CAAA;QAC9D,MAAM,SAAS,GAAG;YAChB,MAAM,EAAE,OAAO,CAAC,KAAK,CAAC,MAAgB;YACtC,UAAU,EAAE,OAAO,CAAC,KAAK,CAAC,UAAoB;YAC9C,qBAAqB,EAAE,I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AC;CAAA"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"tracking.js","sourceRoot":"","sources":["../../../src/action/tracking.ts"],"names":[],"mappings":";AAEA,OAAO,EAAE,oBAAoB,EAAE,MAAM,YAAY,CAAA;AAEjD,MAAM,UAAgB,UAAU,CAC9B,OAAsB,EACtB,SAAoB,EACpB,IAA0B;;QAE1B,MAAM,iBAAiB,GAAG,oBAAoB,CAAC,OAAO,CAAC,OAAO,CAAC,CAAA;QAC/D,IAAI,iBAAiB,CAAC,UAAU,EAAE;YAChC,MAAM,iBAAiB,CAAC,UAAU,CAAC,OAAO,EAAE,SAAS,EAAE,IAAI,CAAC,CAAA;SAC7D;QACD,OAAM;IACR,CAAC;CAAA;AAED,MAAM,CAAN,IAAY,SAeX;AAfD,WAAY,SAAS;IACnB,gDAAmC,CAAA;IACnC,oDAAuC,CAAA;IACvC,4CAA+B,CAAA;IAC/B,qCAAwB,CAAA;IACxB,+BAAkB,CAAA;IAClB,mCAAsB,CAAA;IACtB,iCAAoB,CAAA;IACpB,wCAA2B,CAAA;IAC3B,yDAA4C,CAAA;IAC5C,oDAAuC,CAAA;IACvC,kCAAqB,CAAA;IACrB,6CAAgC,CAAA;IAChC,+CAAkC,CAAA;IAClC,yCAA4B,CAAA;AAC9B,CAAC,EAfW,SAAS,KAAT,SAAS,QAepB"}
|
|
@@ -1,4 +0,0 @@
|
|
|
1
|
-
import { ActionRequest } from '@botonic/react';
|
|
2
|
-
import { FlowBuilderApi } from '../api';
|
|
3
|
-
import { HtIntentNode, HtKeywordNode } from '../content-fields/hubtype-fields';
|
|
4
|
-
export declare function getNodeByUserInput(cmsApi: FlowBuilderApi, locale: string, request: ActionRequest): Promise<HtIntentNode | HtKeywordNode | undefined>;
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"user-input.js","sourceRoot":"","sources":["../../../src/action/user-input.ts"],"names":[],"mappings":";AAIA,OAAO,EAAE,oBAAoB,EAAE,MAAM,UAAU,CAAA;AAC/C,OAAO,EAAE,qBAAqB,EAAE,MAAM,WAAW,CAAA;AAEjD,MAAM,UAAgB,kBAAkB,CACtC,MAAsB,EACtB,MAAc,EACd,OAAsB;;QAEtB,IAAI,OAAO,CAAC,KAAK,CAAC,IAAI,EAAE;YACtB,MAAM,UAAU,GAAG,MAAM,oBAAoB,CAAC,MAAM,EAAE,MAAM,EAAE,OAAO,CAAC,CAAA;YACtE,IAAI,UAAU;gBAAE,OAAO,UAAU,CAAA;YAEjC,MAAM,WAAW,GAAG,MAAM,qBAAqB,CAC7C,MAAM,EACN,MAAM,EACN,OAAO,EACP,OAAO,CAAC,KAAK,CAAC,IAAI,CACnB,CAAA;YACD,IAAI,WAAW;gBAAE,OAAO,WAAW,CAAA;SACpC;QACD,OAAO,SAAS,CAAA;IAClB,CAAC;CAAA"}
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|