@gengage/assistant-fe 0.6.42 → 0.6.44
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/chat/components/ChatDrawer.d.ts +5 -1
- package/dist/chat/runtime.d.ts +1 -1
- package/dist/chat/types.d.ts +18 -0
- package/dist/chat-runtime.js +1 -1
- package/dist/chat.iife.js +25 -25
- package/dist/chat.js +1 -1
- package/dist/common/overlay.d.ts +1 -0
- package/dist/{common-B9n_o9ki.js → common-B_QhTwRK.js} +2 -2
- package/dist/common.js +7 -7
- package/dist/{connection-warning-ByY3TKaG.js → connection-warning-DjGsAS1h.js} +1 -1
- package/dist/{fastIntent-BaNC2CJz.js → fastIntent-DOgXE46i.js} +1 -1
- package/dist/index.d.ts +1 -1
- package/dist/index.js +12 -12
- package/dist/{native-webview-Ch9lsx7E.js → native-webview-CYX30O3Q.js} +1 -1
- package/dist/native.iife.js +8 -8
- package/dist/native.js +1 -1
- package/dist/{overlay-CPLLn1eK.js → overlay-BPZEIyo_.js} +1 -1
- package/dist/overlay.js +1 -1
- package/dist/qna-runtime.js +1 -1
- package/dist/qna.iife.js +8 -8
- package/dist/qna.js +1 -1
- package/dist/{request-response-cache-DkilqELR.js → request-response-cache-Ddw59jGs.js} +1 -1
- package/dist/{runtime-BkqUiRUi.js → runtime-BJiDilHj.js} +3 -3
- package/dist/{runtime-CmpEARET.js → runtime-Cr3f6wjm.js} +3 -3
- package/dist/{runtime-_ly8XVXC.js → runtime-D39A30T-.js} +1176 -1155
- package/dist/{simbut-CltMk2OF.js → simbut-C-2-g2V1.js} +1 -1
- package/dist/simbut.iife.js +2 -2
- package/dist/simbut.js +1 -1
- package/dist/{simrel-BuCc53Pw.js → simrel-BaahIAgs.js} +1 -1
- package/dist/simrel-runtime.js +1 -1
- package/dist/simrel.iife.js +2 -2
- package/dist/simrel.js +2 -2
- package/dist/{widget-base-vDXD27_n.js → widget-base-DRNUkp-i.js} +4 -1
- package/package.json +1 -1
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type { ChatI18n, ChatMessage } from '../types.js';
|
|
1
|
+
import type { ChatFooterAttribution, ChatI18n, ChatMessage } from '../types.js';
|
|
2
2
|
/** SVG icon map for suggested action chips/pills. Keys match backend icon names. */
|
|
3
3
|
declare const SUGGESTED_ACTION_ICONS: Record<string, string>;
|
|
4
4
|
export { SUGGESTED_ACTION_ICONS };
|
|
@@ -55,6 +55,8 @@ export interface ChatDrawerOptions {
|
|
|
55
55
|
voiceEnabled?: boolean | undefined;
|
|
56
56
|
/** BCP 47 language for speech recognition. Default: 'tr-TR'. */
|
|
57
57
|
voiceLang?: string | undefined;
|
|
58
|
+
/** Optional footer attribution link/text. Falls back to legacy `i18n.poweredBy` when omitted. */
|
|
59
|
+
footerAttribution?: ChatFooterAttribution | undefined;
|
|
58
60
|
/** Callback fired when the "New Chat" button is clicked. */
|
|
59
61
|
onNewChat?: (() => void) | undefined;
|
|
60
62
|
/**
|
|
@@ -147,6 +149,8 @@ export declare class ChatDrawer {
|
|
|
147
149
|
private _cartToastEl;
|
|
148
150
|
private _cartToastTimerId;
|
|
149
151
|
private _renderPhotoAnalysisCard;
|
|
152
|
+
private _createLegacyHeaderPoweredBy;
|
|
153
|
+
private _createFooterAttribution;
|
|
150
154
|
constructor(container: HTMLElement, options: ChatDrawerOptions);
|
|
151
155
|
addMessage(message: ChatMessage): void;
|
|
152
156
|
/** Remove one transcript bubble (e.g. superseded empty assistant placeholder). */
|
package/dist/chat/runtime.d.ts
CHANGED
|
@@ -417,7 +417,7 @@ export declare class GengageChat extends BaseWidget<ChatWidgetConfig> {
|
|
|
417
417
|
private _renderUISpec;
|
|
418
418
|
}
|
|
419
419
|
export declare function createChatWidget(): GengageChat;
|
|
420
|
-
export type { ChatWidgetConfig, ChatMessage, ChatSession, ChatUIComponents, ChatI18n, ChatRendererConfig, ChatUISpecRenderContext, ChatUISpecRegistry, ProductSortState, SerializableChatMessage, } from './types.js';
|
|
420
|
+
export type { ChatFooterAttribution, ChatWidgetConfig, ChatMessage, ChatSession, ChatUIComponents, ChatI18n, ChatRendererConfig, ChatUISpecRenderContext, ChatUISpecRegistry, ProductSortState, SerializableChatMessage, } from './types.js';
|
|
421
421
|
export { renderUISpec, createDefaultChatUISpecRegistry, defaultChatUnknownUISpecRenderer, } from './components/renderUISpec.js';
|
|
422
422
|
export type { UISpecRenderContext } from './components/renderUISpec.js';
|
|
423
423
|
export { getChatScrollElement, invalidateChatScrollCache, CHAT_SCROLL_ELEMENT_ID, } from './utils/get-chat-scroll-element.js';
|
package/dist/chat/types.d.ts
CHANGED
|
@@ -4,6 +4,18 @@ import type { PillLauncherOptions } from '../common/pill-launcher.js';
|
|
|
4
4
|
import type { FloatingLauncherOptions } from './components/FloatingLauncher.js';
|
|
5
5
|
import type { InlineLauncherOptions } from './components/InlineLauncher.js';
|
|
6
6
|
import type { UISpecDomRegistry, UISpecRendererOverrides } from '../common/renderer/index.js';
|
|
7
|
+
export interface ChatFooterAttribution {
|
|
8
|
+
/** Visible footer label. Falls back to legacy `i18n.poweredBy` when omitted. */
|
|
9
|
+
label?: string;
|
|
10
|
+
/** Optional destination for the footer attribution. When omitted, footer stays plain text. */
|
|
11
|
+
href?: string;
|
|
12
|
+
/** Link target for footer attribution links. Defaults to `_blank`. */
|
|
13
|
+
target?: string;
|
|
14
|
+
/** Link rel for footer attribution links. Defaults to `noopener noreferrer`. */
|
|
15
|
+
rel?: string;
|
|
16
|
+
/** Optional accessible label for the footer attribution link. */
|
|
17
|
+
ariaLabel?: string;
|
|
18
|
+
}
|
|
7
19
|
export interface ChatWidgetConfig extends BaseWidgetConfig {
|
|
8
20
|
/**
|
|
9
21
|
* Widget display variant:
|
|
@@ -81,6 +93,11 @@ export interface ChatWidgetConfig extends BaseWidgetConfig {
|
|
|
81
93
|
* open the merchant's favorites page (same pattern as `onCartClick`). The built-in favorites panel is not opened.
|
|
82
94
|
*/
|
|
83
95
|
onFavoritesClick?: () => void;
|
|
96
|
+
/**
|
|
97
|
+
* Optional footer attribution. When omitted, the footer keeps the legacy `i18n.poweredBy` text.
|
|
98
|
+
* Provide `href` to render the footer attribution as a link.
|
|
99
|
+
*/
|
|
100
|
+
footerAttribution?: ChatFooterAttribution;
|
|
84
101
|
/** Callback fired when the cart icon button in the header is clicked (when headerCartUrl is not set). */
|
|
85
102
|
onCartClick?: () => void;
|
|
86
103
|
/** Hide the launcher on mobile viewports. */
|
|
@@ -237,6 +254,7 @@ export interface ChatI18n {
|
|
|
237
254
|
closeButton: string;
|
|
238
255
|
openButton: string;
|
|
239
256
|
newChatButton: string;
|
|
257
|
+
/** Legacy combined branding string used by the header link + footer text when newer branding config is absent. */
|
|
240
258
|
poweredBy: string;
|
|
241
259
|
errorMessage: string;
|
|
242
260
|
retryButton: string;
|
package/dist/chat-runtime.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { c as e, d as t, f as r, i as s, l as n, n as i, r as l, s as C, t as c, u as d } from "./runtime-
|
|
1
|
+
import { c as e, d as t, f as r, i as s, l as n, n as i, r as l, s as C, t as c, u as d } from "./runtime-D39A30T-.js";
|
|
2
2
|
export {
|
|
3
3
|
d as CHAT_SCROLL_ELEMENT_ID,
|
|
4
4
|
s as ChatPresentationState,
|