@deepdesk/deepdesk-sdk 10.1.3 → 10.1.5
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 +5 -5
- package/dist/index.d.mts +21 -3
- package/dist/index.d.ts +21 -3
- package/dist/index.esm.js +5 -5
- package/dist/index.iife.js +11 -11
- package/package.json +1 -1
- package/styles/index.js +1 -1
- package/styles.css +1 -1
package/dist/index.d.mts
CHANGED
|
@@ -176,7 +176,7 @@ declare const ToggleButton: React.FC<Props>;
|
|
|
176
176
|
declare enum Sources {
|
|
177
177
|
SEARCH = "search",
|
|
178
178
|
TEMPLATE = "template",
|
|
179
|
-
ELASTIC_SEARCH = "
|
|
179
|
+
ELASTIC_SEARCH = "search-autocomplete",
|
|
180
180
|
GPT = "gpt",
|
|
181
181
|
TRIE = "trie",
|
|
182
182
|
TRIE_WITH_TYPOS = "trie-with-typos",
|
|
@@ -185,7 +185,10 @@ declare enum Sources {
|
|
|
185
185
|
URL_RECOMMENDATION = "url_recommendation",
|
|
186
186
|
LINK_RECOMMENDATION = "link_recommendation",
|
|
187
187
|
PERSONAL_COLLECTION = "personal-collection",
|
|
188
|
-
PERSONAL_COLLECTION_SEARCH = "personal-collection-search"
|
|
188
|
+
PERSONAL_COLLECTION_SEARCH = "personal-collection-search",
|
|
189
|
+
SEARCH_OVERLAY = "search-overlay",
|
|
190
|
+
SEARCH_PREVIEW = "search-preview",
|
|
191
|
+
SEARCH_URL = "search-url"
|
|
189
192
|
}
|
|
190
193
|
declare enum InputType {
|
|
191
194
|
TAB = "tab",
|
|
@@ -1416,6 +1419,7 @@ interface TextSuggestion extends SuggestionApiMetrics {
|
|
|
1416
1419
|
url?: string;
|
|
1417
1420
|
title?: string;
|
|
1418
1421
|
sourceLabel?: string;
|
|
1422
|
+
searchTerm?: string;
|
|
1419
1423
|
type?: string;
|
|
1420
1424
|
searchKeywords?: string[];
|
|
1421
1425
|
image?: string;
|
|
@@ -1453,6 +1457,7 @@ interface SearchSuggestion extends SuggestionApiMetrics {
|
|
|
1453
1457
|
id?: string;
|
|
1454
1458
|
text: string;
|
|
1455
1459
|
title?: string;
|
|
1460
|
+
source?: string;
|
|
1456
1461
|
context?: string;
|
|
1457
1462
|
image?: string;
|
|
1458
1463
|
type?: SearchResultType;
|
|
@@ -1529,6 +1534,7 @@ type MetricState = {
|
|
|
1529
1534
|
numCharsDeleted: number;
|
|
1530
1535
|
numPaste: number;
|
|
1531
1536
|
agentStartedTypingTimestamp: number | null;
|
|
1537
|
+
externalTimeTotalSeconds: number | null;
|
|
1532
1538
|
pastes: any[];
|
|
1533
1539
|
deletions: any[];
|
|
1534
1540
|
offeredTextSuggestions: TextSuggestion[];
|
|
@@ -1592,6 +1598,17 @@ interface TextSuggestionState {
|
|
|
1592
1598
|
[type: string]: SuggestionState;
|
|
1593
1599
|
}
|
|
1594
1600
|
|
|
1601
|
+
interface MessagePayload {
|
|
1602
|
+
name: string;
|
|
1603
|
+
type: string;
|
|
1604
|
+
payload: unknown;
|
|
1605
|
+
}
|
|
1606
|
+
interface Channel {
|
|
1607
|
+
onMessage(cb: (event: MessageEvent<MessagePayload>) => void): void;
|
|
1608
|
+
postMessage(message: MessagePayload): void;
|
|
1609
|
+
close(): void;
|
|
1610
|
+
}
|
|
1611
|
+
|
|
1595
1612
|
type State = {
|
|
1596
1613
|
locale: Locale;
|
|
1597
1614
|
deanonymize: boolean;
|
|
@@ -1637,6 +1654,7 @@ interface SDKOptions {
|
|
|
1637
1654
|
token?: string;
|
|
1638
1655
|
fetch?: typeof window.fetch;
|
|
1639
1656
|
productName?: string;
|
|
1657
|
+
createCustomChannel?: (name: string) => Channel;
|
|
1640
1658
|
}
|
|
1641
1659
|
interface SDKEventMap {
|
|
1642
1660
|
'select-suggestion': {
|
|
@@ -1710,7 +1728,7 @@ declare class DeepdeskSDK {
|
|
|
1710
1728
|
instanceId: number;
|
|
1711
1729
|
private shouldRender;
|
|
1712
1730
|
store: Store;
|
|
1713
|
-
constructor({ deepdeskUrl, brokerUrl, version, locale, token, fetch, productName, }: SDKOptions);
|
|
1731
|
+
constructor({ deepdeskUrl, brokerUrl, version, locale, token, fetch, productName, createCustomChannel, }: SDKOptions);
|
|
1714
1732
|
get state(): redux.EmptyObject & {
|
|
1715
1733
|
activeSuggestion: State$e;
|
|
1716
1734
|
answer: State$c;
|
package/dist/index.d.ts
CHANGED
|
@@ -176,7 +176,7 @@ declare const ToggleButton: React.FC<Props>;
|
|
|
176
176
|
declare enum Sources {
|
|
177
177
|
SEARCH = "search",
|
|
178
178
|
TEMPLATE = "template",
|
|
179
|
-
ELASTIC_SEARCH = "
|
|
179
|
+
ELASTIC_SEARCH = "search-autocomplete",
|
|
180
180
|
GPT = "gpt",
|
|
181
181
|
TRIE = "trie",
|
|
182
182
|
TRIE_WITH_TYPOS = "trie-with-typos",
|
|
@@ -185,7 +185,10 @@ declare enum Sources {
|
|
|
185
185
|
URL_RECOMMENDATION = "url_recommendation",
|
|
186
186
|
LINK_RECOMMENDATION = "link_recommendation",
|
|
187
187
|
PERSONAL_COLLECTION = "personal-collection",
|
|
188
|
-
PERSONAL_COLLECTION_SEARCH = "personal-collection-search"
|
|
188
|
+
PERSONAL_COLLECTION_SEARCH = "personal-collection-search",
|
|
189
|
+
SEARCH_OVERLAY = "search-overlay",
|
|
190
|
+
SEARCH_PREVIEW = "search-preview",
|
|
191
|
+
SEARCH_URL = "search-url"
|
|
189
192
|
}
|
|
190
193
|
declare enum InputType {
|
|
191
194
|
TAB = "tab",
|
|
@@ -1416,6 +1419,7 @@ interface TextSuggestion extends SuggestionApiMetrics {
|
|
|
1416
1419
|
url?: string;
|
|
1417
1420
|
title?: string;
|
|
1418
1421
|
sourceLabel?: string;
|
|
1422
|
+
searchTerm?: string;
|
|
1419
1423
|
type?: string;
|
|
1420
1424
|
searchKeywords?: string[];
|
|
1421
1425
|
image?: string;
|
|
@@ -1453,6 +1457,7 @@ interface SearchSuggestion extends SuggestionApiMetrics {
|
|
|
1453
1457
|
id?: string;
|
|
1454
1458
|
text: string;
|
|
1455
1459
|
title?: string;
|
|
1460
|
+
source?: string;
|
|
1456
1461
|
context?: string;
|
|
1457
1462
|
image?: string;
|
|
1458
1463
|
type?: SearchResultType;
|
|
@@ -1529,6 +1534,7 @@ type MetricState = {
|
|
|
1529
1534
|
numCharsDeleted: number;
|
|
1530
1535
|
numPaste: number;
|
|
1531
1536
|
agentStartedTypingTimestamp: number | null;
|
|
1537
|
+
externalTimeTotalSeconds: number | null;
|
|
1532
1538
|
pastes: any[];
|
|
1533
1539
|
deletions: any[];
|
|
1534
1540
|
offeredTextSuggestions: TextSuggestion[];
|
|
@@ -1592,6 +1598,17 @@ interface TextSuggestionState {
|
|
|
1592
1598
|
[type: string]: SuggestionState;
|
|
1593
1599
|
}
|
|
1594
1600
|
|
|
1601
|
+
interface MessagePayload {
|
|
1602
|
+
name: string;
|
|
1603
|
+
type: string;
|
|
1604
|
+
payload: unknown;
|
|
1605
|
+
}
|
|
1606
|
+
interface Channel {
|
|
1607
|
+
onMessage(cb: (event: MessageEvent<MessagePayload>) => void): void;
|
|
1608
|
+
postMessage(message: MessagePayload): void;
|
|
1609
|
+
close(): void;
|
|
1610
|
+
}
|
|
1611
|
+
|
|
1595
1612
|
type State = {
|
|
1596
1613
|
locale: Locale;
|
|
1597
1614
|
deanonymize: boolean;
|
|
@@ -1637,6 +1654,7 @@ interface SDKOptions {
|
|
|
1637
1654
|
token?: string;
|
|
1638
1655
|
fetch?: typeof window.fetch;
|
|
1639
1656
|
productName?: string;
|
|
1657
|
+
createCustomChannel?: (name: string) => Channel;
|
|
1640
1658
|
}
|
|
1641
1659
|
interface SDKEventMap {
|
|
1642
1660
|
'select-suggestion': {
|
|
@@ -1710,7 +1728,7 @@ declare class DeepdeskSDK {
|
|
|
1710
1728
|
instanceId: number;
|
|
1711
1729
|
private shouldRender;
|
|
1712
1730
|
store: Store;
|
|
1713
|
-
constructor({ deepdeskUrl, brokerUrl, version, locale, token, fetch, productName, }: SDKOptions);
|
|
1731
|
+
constructor({ deepdeskUrl, brokerUrl, version, locale, token, fetch, productName, createCustomChannel, }: SDKOptions);
|
|
1714
1732
|
get state(): redux.EmptyObject & {
|
|
1715
1733
|
activeSuggestion: State$e;
|
|
1716
1734
|
answer: State$c;
|