@unisphere/genie-types 1.39.11 → 1.41.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/index.esm.js
CHANGED
|
@@ -1863,6 +1863,10 @@ const floaterVisualSettingsSchema = {
|
|
|
1863
1863
|
mode: modeSchema,
|
|
1864
1864
|
context: chatContextSchema,
|
|
1865
1865
|
customization: chatCustomizationSchema,
|
|
1866
|
+
onThreadIdChanged: {
|
|
1867
|
+
type: 'function',
|
|
1868
|
+
optional: true
|
|
1869
|
+
},
|
|
1866
1870
|
dynamicVariables: dynamicVariablesSchema,
|
|
1867
1871
|
header: headerSchema,
|
|
1868
1872
|
openingPosition: {
|
|
@@ -1887,6 +1891,10 @@ const floaterCTAVisualSettingsSchema = {
|
|
|
1887
1891
|
optional: true
|
|
1888
1892
|
},
|
|
1889
1893
|
mode: modeSchema,
|
|
1894
|
+
onThreadIdChanged: {
|
|
1895
|
+
type: 'function',
|
|
1896
|
+
optional: true
|
|
1897
|
+
},
|
|
1890
1898
|
openByDefault: {
|
|
1891
1899
|
type: 'primitive',
|
|
1892
1900
|
value: 'boolean',
|
|
@@ -1928,6 +1936,10 @@ const containedVisualSettingsSchema = {
|
|
|
1928
1936
|
type: 'function',
|
|
1929
1937
|
optional: true
|
|
1930
1938
|
},
|
|
1939
|
+
onThreadIdChanged: {
|
|
1940
|
+
type: 'function',
|
|
1941
|
+
optional: true
|
|
1942
|
+
},
|
|
1931
1943
|
isExpanded: {
|
|
1932
1944
|
type: 'primitive',
|
|
1933
1945
|
value: 'boolean',
|
|
@@ -1993,6 +2005,10 @@ const pageVisualSettingsSchema = {
|
|
|
1993
2005
|
properties: Object.assign(Object.assign({}, chatCustomizationSchemaProperties), {
|
|
1994
2006
|
schemaVersion: schemaVersionSchema,
|
|
1995
2007
|
scroll: scrollSchema,
|
|
2008
|
+
onThreadIdChanged: {
|
|
2009
|
+
type: 'function',
|
|
2010
|
+
optional: true
|
|
2011
|
+
},
|
|
1996
2012
|
customization: chatCustomizationSchema,
|
|
1997
2013
|
context: pageContextSchema,
|
|
1998
2014
|
initialQuestion: initialQuestionSchema,
|
|
@@ -2054,7 +2070,11 @@ const popupVisualSettingsSchema = {
|
|
|
2054
2070
|
scroll: scrollSchema,
|
|
2055
2071
|
customization: chatCustomizationSchema,
|
|
2056
2072
|
initialQuestion: initialQuestionSchema,
|
|
2057
|
-
dynamicVariables: dynamicVariablesSchema
|
|
2073
|
+
dynamicVariables: dynamicVariablesSchema,
|
|
2074
|
+
onThreadIdChanged: {
|
|
2075
|
+
type: 'function',
|
|
2076
|
+
optional: true
|
|
2077
|
+
}
|
|
2058
2078
|
})
|
|
2059
2079
|
};
|
|
2060
2080
|
|
package/package.json
CHANGED
|
@@ -49,6 +49,7 @@ type InitialQuestion = {
|
|
|
49
49
|
export type PageVisualSettings = ScrollableVisualSettings & ChatCustomization & {
|
|
50
50
|
/** Context for the chat session — host-provided, not user-controllable */
|
|
51
51
|
context?: Pick<ChatContext, 'type' | 'id'>;
|
|
52
|
+
onThreadIdChanged?: (threadId: string) => void;
|
|
52
53
|
};
|
|
53
54
|
/**
|
|
54
55
|
* Visual settings for banner/hero-style chat landing pages.
|
|
@@ -108,6 +109,7 @@ export type BannerVisualSettings = BaseVisualSettings & ChatCustomization & {
|
|
|
108
109
|
export type PopupVisualSettings = ScrollableVisualSettings & ChatCustomization & {
|
|
109
110
|
/** Optional question to ask automatically when popup opens */
|
|
110
111
|
initialQuestion?: InitialQuestion;
|
|
112
|
+
onThreadIdChanged?: (threadId: string) => void;
|
|
111
113
|
};
|
|
112
114
|
export type ChatHeaderSettings = {
|
|
113
115
|
/** Replaces the default header title */
|
|
@@ -125,6 +127,7 @@ export type ContainedVisualSettings = ScrollableVisualSettings & ModeContextVisu
|
|
|
125
127
|
onRequestClose?: () => void;
|
|
126
128
|
/** Callback invoked when the user clicks the expand button */
|
|
127
129
|
onExpand?: () => void;
|
|
130
|
+
onThreadIdChanged?: (threadId: string) => void;
|
|
128
131
|
/** Whether the host has expanded the widget; drives the expand/collapse icon in the header */
|
|
129
132
|
isExpanded?: boolean;
|
|
130
133
|
/** Type of close button to display in the header */
|
|
@@ -138,12 +141,14 @@ export type FloaterCTAVisualSettings = ModeContextVisualSettings & ChatCustomiza
|
|
|
138
141
|
openByDefault?: boolean;
|
|
139
142
|
type?: 'button';
|
|
140
143
|
text?: string;
|
|
144
|
+
onThreadIdChanged?: (threadId: string) => void;
|
|
141
145
|
showIcon?: boolean;
|
|
142
146
|
header?: ChatHeaderSettings;
|
|
143
147
|
};
|
|
144
148
|
export type FloaterVisualSettings = ModeContextVisualSettings & ChatCustomization & {
|
|
145
149
|
openingPosition?: 'left' | 'right';
|
|
146
150
|
header?: ChatHeaderSettings;
|
|
151
|
+
onThreadIdChanged?: (threadId: string) => void;
|
|
147
152
|
};
|
|
148
153
|
export declare const floaterVisualSettingsSchema: ValidatorSchema;
|
|
149
154
|
export declare const floaterCTAVisualSettingsSchema: ValidatorSchema;
|