@telia-ace/widget-conversation 1.0.32 → 1.0.33-next.3
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/agent.d.ts +1 -1
- package/dist/components/conversation/conversation.d.ts +1 -1
- package/dist/components/conversation/plugin.d.ts +4 -4
- package/dist/components/conversation/ui/input.d.ts +1 -1
- package/dist/components/conversation/ui/loader.d.ts +1 -1
- package/dist/components/conversation/ui/message-list-items/button-list.d.ts +1 -1
- package/dist/components/conversation/ui/message-list-items/custom.d.ts +1 -1
- package/dist/components/conversation/ui/message-list-items/html.d.ts +1 -1
- package/dist/components/conversation/ui/message-list-items/link-list.d.ts +1 -1
- package/dist/components/conversation/ui/message-list-items/text.d.ts +1 -1
- package/dist/components/conversation/ui/message-list-items/video-request.d.ts +1 -1
- package/dist/components/conversation/ui/message-types/agent.d.ts +1 -1
- package/dist/components/conversation/ui/message-types/message-list.d.ts +1 -1
- package/dist/components/conversation/ui/message-types/system.d.ts +1 -1
- package/dist/components/conversation/ui/message-types/timestamp.d.ts +1 -1
- package/dist/components/conversation/ui/message-types/user.d.ts +1 -1
- package/dist/components/conversation/ui/overlay-outlets.d.ts +2 -2
- package/dist/components/conversation/ui/styles.d.ts +1 -1
- package/dist/components/return-button/plugin.d.ts +1 -1
- package/dist/components/return-button/return-button.d.ts +1 -1
- package/dist/conversation-controller.d.ts +9 -9
- package/dist/conversation-platform.d.ts +4 -4
- package/dist/{conversation.4bd3eedd.js → conversation.bc31361a.js} +330 -305
- package/dist/{conversation.4bd3eedd.js.map → conversation.bc31361a.js.map} +1 -1
- package/dist/index.js +2 -2
- package/dist/resolve-entity-value.d.ts +2 -2
- package/dist/{return-button.9c3eb2ec.js → return-button.fb63a16e.js} +14 -15
- package/dist/{return-button.9c3eb2ec.js.map → return-button.fb63a16e.js.map} +1 -1
- package/dist/store.d.ts +3 -3
- package/dist/types.d.ts +19 -19
- package/package.json +10 -10
package/dist/agent.d.ts
CHANGED
|
@@ -2,7 +2,7 @@ import { Symbol } from '@telia-ace/widget-ui';
|
|
|
2
2
|
import { ConversationEntry } from './conversation-controller';
|
|
3
3
|
import { ConversationProvider } from './conversation-provider';
|
|
4
4
|
import { ConversationMessageSettings, ConverstationMessageItem } from './types';
|
|
5
|
-
export
|
|
5
|
+
export type AgentSettings = {
|
|
6
6
|
id?: string;
|
|
7
7
|
name?: string;
|
|
8
8
|
avatar?: string | Symbol;
|
|
@@ -1,21 +1,21 @@
|
|
|
1
1
|
import { Container } from '@webprovisions/platform';
|
|
2
2
|
import { ConversationMessage, ConversationMessageType } from '../../conversation-controller';
|
|
3
3
|
import { ConversationMessageContent, ConversationMessageSender } from '../../types';
|
|
4
|
-
export
|
|
4
|
+
export type BundledConversationMessage = {
|
|
5
5
|
timestamp: number;
|
|
6
6
|
content: [BundledMessageContent];
|
|
7
7
|
sender: ConversationMessageSender;
|
|
8
8
|
type: ConversationMessageType;
|
|
9
9
|
};
|
|
10
|
-
|
|
10
|
+
type BundledMessageContent = {
|
|
11
11
|
key: string;
|
|
12
12
|
} & ConversationMessageContent;
|
|
13
|
-
export
|
|
13
|
+
export type ConversationContent = {
|
|
14
14
|
loading: boolean;
|
|
15
15
|
typingActors: ConversationMessageSender[];
|
|
16
16
|
messages: ConversationMessage[];
|
|
17
17
|
};
|
|
18
|
-
export
|
|
18
|
+
export type ConversationComponentProperties = {
|
|
19
19
|
providers: string[];
|
|
20
20
|
messages: BundledConversationMessage[];
|
|
21
21
|
overlay?: {
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { DispatchAction } from '@telia-ace/widget-ui';
|
|
2
2
|
import { FC } from 'react';
|
|
3
3
|
import { ButtonListProperties } from '../../../../types';
|
|
4
|
-
|
|
4
|
+
type Props = {
|
|
5
5
|
dispatch: DispatchAction;
|
|
6
6
|
} & ButtonListProperties;
|
|
7
7
|
export declare const ButtonList: FC<Props>;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { DispatchAction } from '@telia-ace/widget-ui';
|
|
2
2
|
import { FC } from 'react';
|
|
3
3
|
import { LinkListProperties } from '../../../../types';
|
|
4
|
-
|
|
4
|
+
type Props = {
|
|
5
5
|
dispatch: DispatchAction;
|
|
6
6
|
} & LinkListProperties;
|
|
7
7
|
export declare const LinkList: FC<Props>;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { DispatchAction } from '@telia-ace/widget-ui';
|
|
2
2
|
import { FC } from 'react';
|
|
3
3
|
import { VideoRequestProperties } from '../../../../types';
|
|
4
|
-
|
|
4
|
+
type Props = {
|
|
5
5
|
dispatch: DispatchAction;
|
|
6
6
|
} & VideoRequestProperties;
|
|
7
7
|
export declare const VideoRequest: FC<Props>;
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import { DispatchAction } from '@telia-ace/widget-ui';
|
|
2
2
|
import { FC } from 'react';
|
|
3
|
-
|
|
3
|
+
type OverlayOutletProps = {
|
|
4
4
|
dispatch: DispatchAction;
|
|
5
5
|
};
|
|
6
6
|
export declare const OverlayOutlet: FC<OverlayOutletProps>;
|
|
7
|
-
|
|
7
|
+
type ConversationOverlayProps = {
|
|
8
8
|
dispatch: DispatchAction;
|
|
9
9
|
header?: string;
|
|
10
10
|
buttonLabel?: string;
|
|
@@ -21,7 +21,7 @@ export declare const MessageContainer: import("@emotion/styled").StyledComponent
|
|
|
21
21
|
center?: boolean | undefined;
|
|
22
22
|
right?: boolean | undefined;
|
|
23
23
|
}, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {}>;
|
|
24
|
-
export
|
|
24
|
+
export type Stacked = 'first' | 'last' | 'middle';
|
|
25
25
|
export declare const MessageContent: import("@emotion/styled").StyledComponent<{
|
|
26
26
|
theme?: Theme | undefined;
|
|
27
27
|
as?: import("react").ElementType<any> | undefined;
|
|
@@ -3,24 +3,24 @@ import { AgentSettings } from './agent';
|
|
|
3
3
|
import { ConversationProvider } from './conversation-provider';
|
|
4
4
|
import { ConversationMessageContent, ConversationMessageSender, ConversationMessageSettings, ConversationMessageUpdateSettings, ConverstationMessageItem, NormalizedMessageSettings } from './types';
|
|
5
5
|
import { User } from './user';
|
|
6
|
-
export
|
|
6
|
+
export type ValidateHandler = (formValues: {
|
|
7
7
|
[key: string]: any;
|
|
8
8
|
}) => Promise<any>;
|
|
9
|
-
export
|
|
9
|
+
export type SubmitHandler = (formValues: {
|
|
10
10
|
[key: string]: any;
|
|
11
11
|
}) => Promise<any>;
|
|
12
|
-
export
|
|
12
|
+
export type ConversationOptions = {
|
|
13
13
|
silent: boolean;
|
|
14
14
|
};
|
|
15
|
-
export
|
|
16
|
-
export
|
|
15
|
+
export type Print = (content: string | ConversationMessageContent) => ConversationEntry;
|
|
16
|
+
export type FormHandlers = {
|
|
17
17
|
[key: string]: FormHandler;
|
|
18
18
|
};
|
|
19
|
-
export
|
|
19
|
+
export type FormHandler = {
|
|
20
20
|
validate?: ValidateHandler;
|
|
21
21
|
submit: SubmitHandler;
|
|
22
22
|
};
|
|
23
|
-
export
|
|
23
|
+
export type CancelLoaderDelegate = () => void;
|
|
24
24
|
export declare class ConversationEntry {
|
|
25
25
|
private writer;
|
|
26
26
|
constructor(writer: EntryWriter);
|
|
@@ -33,14 +33,14 @@ export declare enum ConversationMessageType {
|
|
|
33
33
|
Agent = "agent",
|
|
34
34
|
System = "system"
|
|
35
35
|
}
|
|
36
|
-
export
|
|
36
|
+
export type ConversationMessage = {
|
|
37
37
|
key: string;
|
|
38
38
|
timestamp: number | null;
|
|
39
39
|
content: ConversationMessageContent | null;
|
|
40
40
|
sender: ConversationMessageSender | null;
|
|
41
41
|
type: ConversationMessageType;
|
|
42
42
|
};
|
|
43
|
-
export
|
|
43
|
+
export type EntryWriter = (content: ConversationMessageUpdateSettings | null) => void;
|
|
44
44
|
export declare const getNormalizedMessageSettings: (settings: string | ConversationMessageSettings | ConverstationMessageItem<any> | ConverstationMessageItem<any>[], options?: {
|
|
45
45
|
key?: string | undefined;
|
|
46
46
|
} | undefined) => NormalizedMessageSettings;
|
|
@@ -3,9 +3,9 @@ import { RouteData } from '@telia-ace/widget-routing';
|
|
|
3
3
|
import { Container, EventManager, EventSubscriptionCancellation } from '@webprovisions/platform';
|
|
4
4
|
import { ConversationController } from './conversation-controller';
|
|
5
5
|
import { ConversationProvider } from './conversation-provider';
|
|
6
|
-
export
|
|
7
|
-
export
|
|
8
|
-
export
|
|
6
|
+
export type ConversationHandler = (conversation: ConversationProvider, component: ComponentNodeController) => void | (() => void);
|
|
7
|
+
export type UnregisterControllerDelegate = () => void;
|
|
8
|
+
export type ConversationProviderRegistration = {
|
|
9
9
|
name: string;
|
|
10
10
|
handler: ConversationHandler;
|
|
11
11
|
};
|
|
@@ -14,7 +14,7 @@ export declare enum ConversationEndedBehavior {
|
|
|
14
14
|
Navigate = "navigate",
|
|
15
15
|
None = "none"
|
|
16
16
|
}
|
|
17
|
-
export
|
|
17
|
+
export type SessionInfo = {
|
|
18
18
|
id?: string;
|
|
19
19
|
route?: RouteData;
|
|
20
20
|
conversationEndedBehavior?: ConversationEndedBehavior;
|