@deepdesk/deepdesk-sdk 10.12.1-beta.1 → 10.12.1-beta.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/index.cjs.js +7 -7
- package/dist/index.d.mts +103 -84
- package/dist/index.d.ts +103 -84
- package/dist/index.esm.js +7 -7
- package/dist/index.iife.js +14 -14
- package/input.css +1 -1
- package/package.json +1 -1
- package/styles/index.js +1 -1
- package/styles.css +1 -1
- package/widget.css +1 -1
package/dist/index.d.mts
CHANGED
|
@@ -12,6 +12,7 @@ declare const styles$n: {
|
|
|
12
12
|
readonly "title": string;
|
|
13
13
|
readonly "contentIsCropped": string;
|
|
14
14
|
readonly "lineClamp": string;
|
|
15
|
+
readonly "closeIcon": string;
|
|
15
16
|
};
|
|
16
17
|
|
|
17
18
|
type ImageProps = {
|
|
@@ -28,10 +29,14 @@ interface TitleProps extends React.HTMLProps<HTMLHeadingElement> {
|
|
|
28
29
|
className?: string;
|
|
29
30
|
as?: string;
|
|
30
31
|
}
|
|
32
|
+
interface CloseIconProps extends React.HTMLProps<HTMLDivElement> {
|
|
33
|
+
className?: string;
|
|
34
|
+
}
|
|
31
35
|
interface CardComposition {
|
|
32
36
|
Image: FC<ImageProps>;
|
|
33
37
|
Content: FC<ContentProps>;
|
|
34
38
|
Title: FC<TitleProps>;
|
|
39
|
+
CloseIcon: FC<CloseIconProps>;
|
|
35
40
|
}
|
|
36
41
|
type CardStyles = typeof styles$n;
|
|
37
42
|
declare const Card: FC & CardComposition;
|
|
@@ -274,12 +279,12 @@ declare abstract class InputMediator<HTMLElementType extends HTMLElement> {
|
|
|
274
279
|
dispose(): void;
|
|
275
280
|
}
|
|
276
281
|
|
|
277
|
-
type State$
|
|
282
|
+
type State$h = {
|
|
278
283
|
startTime: Date | null;
|
|
279
284
|
stopTime: Date | null;
|
|
280
285
|
};
|
|
281
286
|
|
|
282
|
-
interface State$
|
|
287
|
+
interface State$g {
|
|
283
288
|
contentType: string | null;
|
|
284
289
|
suggestion: TextSuggestion | null;
|
|
285
290
|
}
|
|
@@ -451,25 +456,25 @@ interface StoreConfig {
|
|
|
451
456
|
preloadedState?: any;
|
|
452
457
|
}
|
|
453
458
|
declare const reducers: redux.Reducer<redux.CombinedState<{
|
|
454
|
-
activeSuggestion: State$
|
|
455
|
-
answer: State$
|
|
456
|
-
auth: State$
|
|
457
|
-
autoflows: State$
|
|
458
|
-
conversation: State$
|
|
459
|
-
contentTypes: State$
|
|
460
|
-
customMessages: State$
|
|
461
|
-
passwordlessToken: State$
|
|
462
|
-
entities: State$
|
|
463
|
-
knowledgeAssistant: State$
|
|
464
|
-
handlingTime: State$
|
|
459
|
+
activeSuggestion: State$g;
|
|
460
|
+
answer: State$7;
|
|
461
|
+
auth: State$f;
|
|
462
|
+
autoflows: State$e;
|
|
463
|
+
conversation: State$d;
|
|
464
|
+
contentTypes: State$c;
|
|
465
|
+
customMessages: State$b;
|
|
466
|
+
passwordlessToken: State$a;
|
|
467
|
+
entities: State$9;
|
|
468
|
+
knowledgeAssistant: State$8;
|
|
469
|
+
handlingTime: State$h;
|
|
465
470
|
info: {
|
|
466
471
|
agentInfo?: AgentInfo | undefined;
|
|
467
472
|
agentSettings: unknown;
|
|
468
473
|
visitorInfo?: VisitorInfo | undefined;
|
|
469
474
|
fetchState: FetchState;
|
|
470
475
|
};
|
|
471
|
-
input: State$
|
|
472
|
-
overlayInput: State$
|
|
476
|
+
input: State$6;
|
|
477
|
+
overlayInput: State$6;
|
|
473
478
|
settings: {
|
|
474
479
|
locale: Locale;
|
|
475
480
|
deanonymize: boolean;
|
|
@@ -500,10 +505,10 @@ declare const reducers: redux.Reducer<redux.CombinedState<{
|
|
|
500
505
|
productName: string;
|
|
501
506
|
suggestionFeedbackEmailAddresses?: string[] | undefined;
|
|
502
507
|
};
|
|
503
|
-
profile: State$
|
|
504
|
-
search: State$
|
|
505
|
-
summary: State$
|
|
506
|
-
styleSuggestions: State$
|
|
508
|
+
profile: State$5;
|
|
509
|
+
search: State$4;
|
|
510
|
+
summary: State$3;
|
|
511
|
+
styleSuggestions: State$2;
|
|
507
512
|
ui: {
|
|
508
513
|
showTabHint: boolean;
|
|
509
514
|
inputHasFocus: boolean;
|
|
@@ -511,28 +516,29 @@ declare const reducers: redux.Reducer<redux.CombinedState<{
|
|
|
511
516
|
openOverlayWhenTyping: boolean;
|
|
512
517
|
overlayCollapsedUserOverwrite: boolean;
|
|
513
518
|
};
|
|
519
|
+
rules: State$1;
|
|
514
520
|
textSuggestions: TextSuggestionState;
|
|
515
521
|
}>, redux.AnyAction>;
|
|
516
522
|
declare function createStore(config: StoreConfig): _reduxjs_toolkit_dist_configureStore.ToolkitStore<redux.EmptyObject & {
|
|
517
|
-
activeSuggestion: State$
|
|
518
|
-
answer: State$
|
|
519
|
-
auth: State$
|
|
520
|
-
autoflows: State$
|
|
521
|
-
conversation: State$
|
|
522
|
-
contentTypes: State$
|
|
523
|
-
customMessages: State$
|
|
524
|
-
passwordlessToken: State$
|
|
525
|
-
entities: State$
|
|
526
|
-
knowledgeAssistant: State$
|
|
527
|
-
handlingTime: State$
|
|
523
|
+
activeSuggestion: State$g;
|
|
524
|
+
answer: State$7;
|
|
525
|
+
auth: State$f;
|
|
526
|
+
autoflows: State$e;
|
|
527
|
+
conversation: State$d;
|
|
528
|
+
contentTypes: State$c;
|
|
529
|
+
customMessages: State$b;
|
|
530
|
+
passwordlessToken: State$a;
|
|
531
|
+
entities: State$9;
|
|
532
|
+
knowledgeAssistant: State$8;
|
|
533
|
+
handlingTime: State$h;
|
|
528
534
|
info: {
|
|
529
535
|
agentInfo?: AgentInfo | undefined;
|
|
530
536
|
agentSettings: unknown;
|
|
531
537
|
visitorInfo?: VisitorInfo | undefined;
|
|
532
538
|
fetchState: FetchState;
|
|
533
539
|
};
|
|
534
|
-
input: State$
|
|
535
|
-
overlayInput: State$
|
|
540
|
+
input: State$6;
|
|
541
|
+
overlayInput: State$6;
|
|
536
542
|
settings: {
|
|
537
543
|
locale: Locale;
|
|
538
544
|
deanonymize: boolean;
|
|
@@ -563,10 +569,10 @@ declare function createStore(config: StoreConfig): _reduxjs_toolkit_dist_configu
|
|
|
563
569
|
productName: string;
|
|
564
570
|
suggestionFeedbackEmailAddresses?: string[] | undefined;
|
|
565
571
|
};
|
|
566
|
-
profile: State$
|
|
567
|
-
search: State$
|
|
568
|
-
summary: State$
|
|
569
|
-
styleSuggestions: State$
|
|
572
|
+
profile: State$5;
|
|
573
|
+
search: State$4;
|
|
574
|
+
summary: State$3;
|
|
575
|
+
styleSuggestions: State$2;
|
|
570
576
|
ui: {
|
|
571
577
|
showTabHint: boolean;
|
|
572
578
|
inputHasFocus: boolean;
|
|
@@ -574,27 +580,28 @@ declare function createStore(config: StoreConfig): _reduxjs_toolkit_dist_configu
|
|
|
574
580
|
openOverlayWhenTyping: boolean;
|
|
575
581
|
overlayCollapsedUserOverwrite: boolean;
|
|
576
582
|
};
|
|
583
|
+
rules: State$1;
|
|
577
584
|
textSuggestions: TextSuggestionState;
|
|
578
585
|
}, redux.AnyAction, _reduxjs_toolkit.ThunkMiddleware<redux.CombinedState<{
|
|
579
|
-
activeSuggestion: State$
|
|
580
|
-
answer: State$
|
|
581
|
-
auth: State$
|
|
582
|
-
autoflows: State$
|
|
583
|
-
conversation: State$
|
|
584
|
-
contentTypes: State$
|
|
585
|
-
customMessages: State$
|
|
586
|
-
passwordlessToken: State$
|
|
587
|
-
entities: State$
|
|
588
|
-
knowledgeAssistant: State$
|
|
589
|
-
handlingTime: State$
|
|
586
|
+
activeSuggestion: State$g;
|
|
587
|
+
answer: State$7;
|
|
588
|
+
auth: State$f;
|
|
589
|
+
autoflows: State$e;
|
|
590
|
+
conversation: State$d;
|
|
591
|
+
contentTypes: State$c;
|
|
592
|
+
customMessages: State$b;
|
|
593
|
+
passwordlessToken: State$a;
|
|
594
|
+
entities: State$9;
|
|
595
|
+
knowledgeAssistant: State$8;
|
|
596
|
+
handlingTime: State$h;
|
|
590
597
|
info: {
|
|
591
598
|
agentInfo?: AgentInfo | undefined;
|
|
592
599
|
agentSettings: unknown;
|
|
593
600
|
visitorInfo?: VisitorInfo | undefined;
|
|
594
601
|
fetchState: FetchState;
|
|
595
602
|
};
|
|
596
|
-
input: State$
|
|
597
|
-
overlayInput: State$
|
|
603
|
+
input: State$6;
|
|
604
|
+
overlayInput: State$6;
|
|
598
605
|
settings: {
|
|
599
606
|
locale: Locale;
|
|
600
607
|
deanonymize: boolean;
|
|
@@ -625,10 +632,10 @@ declare function createStore(config: StoreConfig): _reduxjs_toolkit_dist_configu
|
|
|
625
632
|
productName: string;
|
|
626
633
|
suggestionFeedbackEmailAddresses?: string[] | undefined;
|
|
627
634
|
};
|
|
628
|
-
profile: State$
|
|
629
|
-
search: State$
|
|
630
|
-
summary: State$
|
|
631
|
-
styleSuggestions: State$
|
|
635
|
+
profile: State$5;
|
|
636
|
+
search: State$4;
|
|
637
|
+
summary: State$3;
|
|
638
|
+
styleSuggestions: State$2;
|
|
632
639
|
ui: {
|
|
633
640
|
showTabHint: boolean;
|
|
634
641
|
inputHasFocus: boolean;
|
|
@@ -636,6 +643,7 @@ declare function createStore(config: StoreConfig): _reduxjs_toolkit_dist_configu
|
|
|
636
643
|
openOverlayWhenTyping: boolean;
|
|
637
644
|
overlayCollapsedUserOverwrite: boolean;
|
|
638
645
|
};
|
|
646
|
+
rules: State$1;
|
|
639
647
|
textSuggestions: TextSuggestionState;
|
|
640
648
|
}>, redux.AnyAction, {
|
|
641
649
|
dynamicThunkObject: Record<string, unknown> | undefined;
|
|
@@ -645,7 +653,7 @@ declare function createStore(config: StoreConfig): _reduxjs_toolkit_dist_configu
|
|
|
645
653
|
type RootState = ReturnType<typeof reducers>;
|
|
646
654
|
type Store = ReturnType<typeof createStore>;
|
|
647
655
|
|
|
648
|
-
interface State$
|
|
656
|
+
interface State$f {
|
|
649
657
|
isLoggedIn: boolean | null;
|
|
650
658
|
loginFetchState: FetchState;
|
|
651
659
|
verifyFetchState: FetchState;
|
|
@@ -655,25 +663,25 @@ interface State$e {
|
|
|
655
663
|
type Autoflow = CamelCaseKeys<Server$1.Autoflow> & {
|
|
656
664
|
isBusy?: boolean;
|
|
657
665
|
};
|
|
658
|
-
interface State$
|
|
666
|
+
interface State$e {
|
|
659
667
|
list: Autoflow[];
|
|
660
668
|
fetchState: FetchState;
|
|
661
669
|
isInitialRequest: null | boolean;
|
|
662
670
|
}
|
|
663
671
|
|
|
664
|
-
interface State$
|
|
672
|
+
interface State$d {
|
|
665
673
|
current: Conversation | null;
|
|
666
674
|
isSupported: boolean | null;
|
|
667
675
|
}
|
|
668
676
|
|
|
669
677
|
type ContentType = CamelCaseKeys<Server.ContentType>;
|
|
670
|
-
type State$
|
|
678
|
+
type State$c = {
|
|
671
679
|
data: ContentType[] | null;
|
|
672
680
|
fetchState: FetchState;
|
|
673
681
|
};
|
|
674
682
|
|
|
675
683
|
type CustomMessage = CamelCaseKeys<Server$1.CustomMessage>;
|
|
676
|
-
interface State$
|
|
684
|
+
interface State$b {
|
|
677
685
|
list: CustomMessage[];
|
|
678
686
|
fetchState: FetchState;
|
|
679
687
|
isInitialRequest: null | boolean;
|
|
@@ -682,18 +690,18 @@ interface State$a {
|
|
|
682
690
|
answeredSuggestions: string[];
|
|
683
691
|
}
|
|
684
692
|
|
|
685
|
-
type State$
|
|
693
|
+
type State$a = {
|
|
686
694
|
token: string | null;
|
|
687
695
|
accountUrl: string | null;
|
|
688
696
|
interval: NodeJS.Timer | null;
|
|
689
697
|
};
|
|
690
698
|
|
|
691
|
-
type State$
|
|
699
|
+
type State$9 = {
|
|
692
700
|
data: Entity[] | null;
|
|
693
701
|
fetchState: FetchState;
|
|
694
702
|
};
|
|
695
703
|
|
|
696
|
-
type State$
|
|
704
|
+
type State$8 = {
|
|
697
705
|
data: KnowledgeAssistant | null;
|
|
698
706
|
fetchState: FetchState;
|
|
699
707
|
};
|
|
@@ -715,7 +723,7 @@ interface KnowledgeResponse {
|
|
|
715
723
|
question: string;
|
|
716
724
|
answer: KnowledgeAnswer;
|
|
717
725
|
}
|
|
718
|
-
type State$
|
|
726
|
+
type State$7 = {
|
|
719
727
|
data: KnowledgeResponse[];
|
|
720
728
|
fetchState: FetchState;
|
|
721
729
|
};
|
|
@@ -1420,7 +1428,7 @@ type MetricState = {
|
|
|
1420
1428
|
textSuggestions: SuggestionMetrics[];
|
|
1421
1429
|
cuts: any[];
|
|
1422
1430
|
};
|
|
1423
|
-
type State$
|
|
1431
|
+
type State$6 = {
|
|
1424
1432
|
text: string;
|
|
1425
1433
|
html: string | null;
|
|
1426
1434
|
selection: SelectionRange;
|
|
@@ -1436,7 +1444,7 @@ type State$5 = {
|
|
|
1436
1444
|
selectedSuggestionIndex: number;
|
|
1437
1445
|
};
|
|
1438
1446
|
|
|
1439
|
-
type State$
|
|
1447
|
+
type State$5 = {
|
|
1440
1448
|
data: Profile | null;
|
|
1441
1449
|
fetchState: FetchState;
|
|
1442
1450
|
};
|
|
@@ -1450,7 +1458,7 @@ declare enum SearchResultDefaultType {
|
|
|
1450
1458
|
}
|
|
1451
1459
|
type SearchResultType = string | SearchResultDefaultType;
|
|
1452
1460
|
type SearchResult = SearchSuggestion;
|
|
1453
|
-
interface State$
|
|
1461
|
+
interface State$4 {
|
|
1454
1462
|
list: Array<SearchResult>;
|
|
1455
1463
|
page: string;
|
|
1456
1464
|
fetchState: FetchState;
|
|
@@ -1458,18 +1466,26 @@ interface State$3 {
|
|
|
1458
1466
|
aggregates: Record<string, number>;
|
|
1459
1467
|
}
|
|
1460
1468
|
|
|
1461
|
-
type State$
|
|
1469
|
+
type State$3 = {
|
|
1462
1470
|
data: string | null;
|
|
1463
1471
|
fetchState: FetchState;
|
|
1464
1472
|
};
|
|
1465
1473
|
|
|
1466
1474
|
type StyleSuggestion = CamelCaseKeys<Server.StyleSuggestion>;
|
|
1467
|
-
interface State$
|
|
1475
|
+
interface State$2 {
|
|
1468
1476
|
list: StyleSuggestion;
|
|
1469
1477
|
fetchState: FetchState;
|
|
1470
1478
|
isInitialRequest: null | boolean;
|
|
1471
1479
|
}
|
|
1472
1480
|
|
|
1481
|
+
type Cue = CamelCaseKeys<Server.Cue> & {
|
|
1482
|
+
timestamp?: number;
|
|
1483
|
+
};
|
|
1484
|
+
type State$1 = {
|
|
1485
|
+
cues: Cue[];
|
|
1486
|
+
fetchState: FetchState;
|
|
1487
|
+
};
|
|
1488
|
+
|
|
1473
1489
|
type SuggestionState = {
|
|
1474
1490
|
suggestions: TextSuggestion[];
|
|
1475
1491
|
fetchState: FetchState;
|
|
@@ -1806,6 +1822,7 @@ interface SDKEventMap {
|
|
|
1806
1822
|
text: string;
|
|
1807
1823
|
selectionAfter: SelectionRange;
|
|
1808
1824
|
};
|
|
1825
|
+
'cues': Cue[];
|
|
1809
1826
|
'replace': {
|
|
1810
1827
|
text: string;
|
|
1811
1828
|
replace: SelectionRange;
|
|
@@ -1873,25 +1890,25 @@ declare class DeepdeskSDK {
|
|
|
1873
1890
|
store: Store;
|
|
1874
1891
|
constructor({ deepdeskUrl, brokerUrl, version, locale, token, fetch, productName, createCustomChannel, }: SDKOptions);
|
|
1875
1892
|
get state(): redux.EmptyObject & {
|
|
1876
|
-
activeSuggestion: State$
|
|
1877
|
-
answer: State$
|
|
1878
|
-
auth: State$
|
|
1879
|
-
autoflows: State$
|
|
1880
|
-
conversation: State$
|
|
1881
|
-
contentTypes: State$
|
|
1882
|
-
customMessages: State$
|
|
1883
|
-
passwordlessToken: State$
|
|
1884
|
-
entities: State$
|
|
1885
|
-
knowledgeAssistant: State$
|
|
1886
|
-
handlingTime: State$
|
|
1893
|
+
activeSuggestion: State$g;
|
|
1894
|
+
answer: State$7;
|
|
1895
|
+
auth: State$f;
|
|
1896
|
+
autoflows: State$e;
|
|
1897
|
+
conversation: State$d;
|
|
1898
|
+
contentTypes: State$c;
|
|
1899
|
+
customMessages: State$b;
|
|
1900
|
+
passwordlessToken: State$a;
|
|
1901
|
+
entities: State$9;
|
|
1902
|
+
knowledgeAssistant: State$8;
|
|
1903
|
+
handlingTime: State$h;
|
|
1887
1904
|
info: {
|
|
1888
1905
|
agentInfo?: AgentInfo | undefined;
|
|
1889
1906
|
agentSettings: unknown;
|
|
1890
1907
|
visitorInfo?: VisitorInfo | undefined;
|
|
1891
1908
|
fetchState: FetchState;
|
|
1892
1909
|
};
|
|
1893
|
-
input: State$
|
|
1894
|
-
overlayInput: State$
|
|
1910
|
+
input: State$6;
|
|
1911
|
+
overlayInput: State$6;
|
|
1895
1912
|
settings: {
|
|
1896
1913
|
locale: Locale;
|
|
1897
1914
|
deanonymize: boolean;
|
|
@@ -1922,10 +1939,10 @@ declare class DeepdeskSDK {
|
|
|
1922
1939
|
productName: string;
|
|
1923
1940
|
suggestionFeedbackEmailAddresses?: string[] | undefined;
|
|
1924
1941
|
};
|
|
1925
|
-
profile: State$
|
|
1926
|
-
search: State$
|
|
1927
|
-
summary: State$
|
|
1928
|
-
styleSuggestions: State$
|
|
1942
|
+
profile: State$5;
|
|
1943
|
+
search: State$4;
|
|
1944
|
+
summary: State$3;
|
|
1945
|
+
styleSuggestions: State$2;
|
|
1929
1946
|
ui: {
|
|
1930
1947
|
showTabHint: boolean;
|
|
1931
1948
|
inputHasFocus: boolean;
|
|
@@ -1933,6 +1950,7 @@ declare class DeepdeskSDK {
|
|
|
1933
1950
|
openOverlayWhenTyping: boolean;
|
|
1934
1951
|
overlayCollapsedUserOverwrite: boolean;
|
|
1935
1952
|
};
|
|
1953
|
+
rules: State$1;
|
|
1936
1954
|
textSuggestions: TextSuggestionState;
|
|
1937
1955
|
};
|
|
1938
1956
|
get settings(): {
|
|
@@ -2060,6 +2078,7 @@ declare class DeepdeskSDK {
|
|
|
2060
2078
|
suggestions: TextSuggestion[];
|
|
2061
2079
|
index: number | null;
|
|
2062
2080
|
}): void;
|
|
2081
|
+
evaluateRule(label: string, params?: Record<string, any>): Promise<any>;
|
|
2063
2082
|
private handleInputChanged;
|
|
2064
2083
|
private handleKeyDown;
|
|
2065
2084
|
private handleAfterSendMessage;
|