@cimulate/copilot-widget 1.47.1 → 1.48.1
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/CHANGELOG.md +8 -0
- package/dist/cimulate-copilot-widget.d.ts +14 -1
- package/dist/cimulate-copilot-widget.es.js +5140 -5101
- package/dist/cimulate-copilot-widget.umd.js +28 -28
- package/dist/copilot.es.js +5129 -5090
- package/dist/copilot.umd.js +29 -29
- package/dist/messaging.css +1 -1
- package/dist/messaging.d.ts +14 -1
- package/dist/messaging.es.js +8556 -8470
- package/dist/messaging.umd.js +36 -36
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -2,6 +2,14 @@
|
|
|
2
2
|
|
|
3
3
|
`@cimulate/copilot-widget` follows [Semantic Versioning](https://semver.org/). Each entry is a released `package.json` version (deployed on merge to `master`), newest first.
|
|
4
4
|
|
|
5
|
+
## 1.48.1 — 2026-10-08
|
|
6
|
+
|
|
7
|
+
- Express payment cancel banner now honors a cartridge-supplied `payload.cancel` string when provided, falling back to the default copy otherwise. The error banner also wraps up to three lines before clipping to accommodate longer provider messages.
|
|
8
|
+
|
|
9
|
+
## 1.48.0 — 2026-10-06
|
|
10
|
+
|
|
11
|
+
- Added `onNavigate` for SPA storefronts. On an unmodified same-tab click of a same-origin product, checkout, or markdown link, the widget calls this handler so the host can route with `history.push` / `router.push` instead of a full page load. Call `event.preventDefault()` inside the handler to skip native navigation. Modifier clicks, `target="_blank"`, and cross-origin URLs are left to the browser. Complements `openLinksInNewTab`.
|
|
12
|
+
|
|
5
13
|
## 1.47.1 — 2026-10-06
|
|
6
14
|
|
|
7
15
|
- Express payment (Apple Pay / Google Pay) now shows a dismissible banner when a payment fails or is canceled, so shoppers see what happened instead of a silent failure. Failure messages take precedence over cancel messages when both fire in sequence.
|
|
@@ -21,6 +21,7 @@ import { FacetedNavigationSuggestion } from '@cimulate/copilot-sdk';
|
|
|
21
21
|
import { FollowUp } from '@cimulate/copilot-sdk';
|
|
22
22
|
import { Inquiry } from '@cimulate/copilot-sdk';
|
|
23
23
|
import { JSX as JSX_2 } from 'react';
|
|
24
|
+
import { MouseEvent as MouseEvent_2 } from 'react';
|
|
24
25
|
import { PartialInquiry } from '@cimulate/copilot-sdk';
|
|
25
26
|
import { ProductView } from '@cimulate/copilot-sdk';
|
|
26
27
|
import { ProductViewAck } from '@cimulate/copilot-sdk';
|
|
@@ -217,6 +218,16 @@ declare interface CopilotWidgetProps extends CimCopilotSdkConfig {
|
|
|
217
218
|
showProductDescription?: boolean;
|
|
218
219
|
theme?: ThemeConfig;
|
|
219
220
|
openLinksInNewTab?: boolean;
|
|
221
|
+
/**
|
|
222
|
+
* Called on an unmodified same-tab click of a same-origin link in the widget
|
|
223
|
+
* (product, checkout, and message links). Use this on SPA storefronts to route
|
|
224
|
+
* with the host router (`history.push`, `router.push`, etc.) instead of a full
|
|
225
|
+
* page load.
|
|
226
|
+
* Call `event.preventDefault()` inside the handler to skip the native
|
|
227
|
+
* navigation. Modifier clicks, `target="_blank"`, and cross-origin URLs
|
|
228
|
+
* are left to the browser.
|
|
229
|
+
*/
|
|
230
|
+
onNavigate?: StorefrontNavigateHandler;
|
|
220
231
|
/**
|
|
221
232
|
* @deprecated This setting has been moved to the initialEntry object. Please use initialEntry.type instead.
|
|
222
233
|
*/
|
|
@@ -302,7 +313,7 @@ declare interface CopilotWidgetProps extends CimCopilotSdkConfig {
|
|
|
302
313
|
* PromptsExtensionContext >
|
|
303
314
|
* CopilotProvider (SocketSdk: copilot-sdk)
|
|
304
315
|
*/
|
|
305
|
-
declare const CopilotWidgetProvider: ({ mode, apiKey, apiToken, baseUrl, customerId, tenantId, logoUrl, headerText, headerConfig, theme, openLinksInNewTab, globalClassName, isDevelopment, componentType, componentConfig, entryType, initialEntry, entryMessage, disclaimerText, disclaimerMarkdown, clientContext, baseCatalogParams, searchPlaceholder, searchButtonLabel, searchConfig, suggestionButtonConfig, messageAlignment, autoScroll, promptsConfig, resetConversationMessage, conversationHistory, onConnect, onCopilotEvent, onRefinedSearch, onRefinedBrowse, __features, children, }: CopilotWidgetProps & {
|
|
316
|
+
declare const CopilotWidgetProvider: ({ mode, apiKey, apiToken, baseUrl, customerId, tenantId, logoUrl, headerText, headerConfig, theme, openLinksInNewTab, onNavigate, globalClassName, isDevelopment, componentType, componentConfig, entryType, initialEntry, entryMessage, disclaimerText, disclaimerMarkdown, clientContext, baseCatalogParams, searchPlaceholder, searchButtonLabel, searchConfig, suggestionButtonConfig, messageAlignment, autoScroll, promptsConfig, resetConversationMessage, conversationHistory, onConnect, onCopilotEvent, onRefinedSearch, onRefinedBrowse, __features, children, }: CopilotWidgetProps & {
|
|
306
317
|
children: ReactNode;
|
|
307
318
|
}) => JSX_2.Element;
|
|
308
319
|
|
|
@@ -636,6 +647,8 @@ declare type StaticQuestionsConfig = {
|
|
|
636
647
|
|
|
637
648
|
declare type StaticQuestionsStrategy = "override" | "append" | "prepend";
|
|
638
649
|
|
|
650
|
+
declare type StorefrontNavigateHandler = (url: string, event: MouseEvent_2<HTMLAnchorElement>) => void;
|
|
651
|
+
|
|
639
652
|
declare type Suggestion = CopilotSearchSuggestion | FacetedNavigationSuggestion | ProductViewSuggestion | CopilotBrowseSuggestion;
|
|
640
653
|
|
|
641
654
|
declare interface SuggestionButtonConfig {
|