@salesforce/ui-bundle-template-feature-react-agentforce-conversation-client 9.12.0 → 9.13.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/README.md CHANGED
@@ -9,7 +9,7 @@ Use this when a user expects to add an employee agent, Agentforce chat, conversa
9
9
  The component embeds the Agentforce chat experience using Lightning Out 2.0. Authentication is resolved automatically:
10
10
 
11
11
  - **Dev (localhost)**: fetches a `frontdoorUrl` from `/__lo/frontdoor`
12
- - **Prod (hosted in org)**: uses `window.location.origin` as `salesforceOrigin`
12
+ - **Prod (hosted in org)**: uses `globalThis.SFDC_ENV?.orgUrl` as `salesforceOrigin` when available
13
13
 
14
14
  ## Step 1: Install
15
15
 
@@ -47,7 +47,7 @@ export default function AppLayout() {
47
47
  | `showHeaderIcon` | `boolean` | No | Show/hide the icon in the header. |
48
48
  | `width` | `number \| string` | No | Inline width (px number or CSS string). |
49
49
  | `height` | `number \| string` | No | Inline height (px number or CSS string). |
50
- | `styleTokens` | `Record<string, string>` | No | Theme tokens for chat UI styling. Merged with package defaults. |
50
+ | `styleTokens` | `Record<string, string>` | No | Theme tokens for chat UI styling. Passed through to the underlying SDK. |
51
51
  | `salesforceOrigin` | `string` | No | Salesforce org origin URL. Resolved automatically if not provided. |
52
52
  | `frontdoorUrl` | `string` | No | Frontdoor URL for authentication. Resolved automatically in dev if not provided. |
53
53
  | `onReady` | `AgentforceReadyHandler` | No | Callback invoked when Lightning Out is ready. Receives the event detail. |
@@ -141,7 +141,7 @@ Both callbacks are optional. When omitted, the SDK still logs errors and readine
141
141
  This React wrapper applies a few defaults around the underlying SDK:
142
142
 
143
143
  - `showAvatar` is set to `false`.
144
- - A default style token set is applied, then your `styleTokens` overrides are merged on top.
144
+ - `channel` is set to `"Vibes"`.
145
145
  - The embed is initialized once per browser window (singleton). If multiple instances mount, only the first successful initialization performs the embed.
146
146
 
147
147
  #### Available Style Tokens
@@ -160,11 +160,24 @@ Style tokens are organized by UI area:
160
160
 
161
161
  ### Prerequisites
162
162
 
163
- - **One of `salesforceOrigin` or `frontdoorUrl` is required** (resolved automatically by the component).
164
- - Use `salesforceOrigin` when your app is hosted inside a Salesforce org and already has an authenticated session.
165
- - Use `frontdoorUrl` when embedding the chat client outside Salesforce (e.g. localhost or an external app).
163
+ - **The SDK requires one of `salesforceOrigin` or `frontdoorUrl`.**
164
+ - The wrapper auto-resolves auth in common cases:
165
+ - **localhost**: fetches `frontdoorUrl` from `/__lo/frontdoor`
166
+ - **org-hosted UI Bundle**: reads `salesforceOrigin` from `globalThis.SFDC_ENV?.orgUrl`
167
+ - If your runtime does not provide either source, pass `salesforceOrigin` or `frontdoorUrl` explicitly.
166
168
  - The org must allow `localhost:<PORT>` in **Trusted Domains for Inline Frames** (session settings) for local development.
167
169
 
170
+ ### If used outside a Salesforce web app (React app)
171
+
172
+ When this package is used in an external React app (not running inside a Salesforce-hosted UI Bundle), you should pass `frontdoorUrl` explicitly so Lightning Out can start with an authenticated Salesforce session.
173
+
174
+ ```tsx
175
+ <AgentforceConversationClient
176
+ agentId="0Xx000000000000AAA"
177
+ frontdoorUrl="https://your-org.my.salesforce.com/secur/frontdoor.jsp?otp=<OTP>"
178
+ />
179
+ ```
180
+
168
181
  ### Underlying SDK
169
182
 
170
183
  This component wraps `@salesforce/agentforce-conversation-client`. For lower-level usage (vanilla JS, non-React frameworks), see the [Agentforce Conversation Client SDK](https://www.npmjs.com/package/@salesforce/agentforce-conversation-client).
package/dist/CHANGELOG.md CHANGED
@@ -3,6 +3,22 @@
3
3
  All notable changes to this project will be documented in this file.
4
4
  See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
5
5
 
6
+ ## [9.13.0](https://github.com/salesforce-experience-platform-emu/webapps/compare/v9.12.1...v9.13.0) (2026-05-28)
7
+
8
+ **Note:** Version bump only for package @salesforce/ui-bundle-template-base-sfdx-project
9
+
10
+
11
+
12
+
13
+
14
+ ## [9.12.1](https://github.com/salesforce-experience-platform-emu/webapps/compare/v9.12.0...v9.12.1) (2026-05-28)
15
+
16
+ **Note:** Version bump only for package @salesforce/ui-bundle-template-base-sfdx-project
17
+
18
+
19
+
20
+
21
+
6
22
  ## [9.12.0](https://github.com/salesforce-experience-platform-emu/webapps/compare/v9.11.0...v9.12.0) (2026-05-27)
7
23
 
8
24
  **Note:** Version bump only for package @salesforce/ui-bundle-template-base-sfdx-project
@@ -1,12 +1,12 @@
1
1
  {
2
2
  "name": "@salesforce/webapp-template-base-sfdx-project-experimental",
3
- "version": "9.12.0",
3
+ "version": "9.13.0",
4
4
  "lockfileVersion": 3,
5
5
  "requires": true,
6
6
  "packages": {
7
7
  "": {
8
8
  "name": "@salesforce/webapp-template-base-sfdx-project-experimental",
9
- "version": "9.12.0",
9
+ "version": "9.13.0",
10
10
  "license": "SEE LICENSE IN LICENSE.txt",
11
11
  "devDependencies": {
12
12
  "@lwc/eslint-plugin-lwc": "^3.3.0",
package/dist/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@salesforce/ui-bundle-template-base-sfdx-project",
3
- "version": "9.12.0",
3
+ "version": "9.13.0",
4
4
  "description": "Base SFDX project template",
5
5
  "license": "SEE LICENSE IN LICENSE.txt",
6
6
  "publishConfig": {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@salesforce/ui-bundle-template-feature-react-agentforce-conversation-client",
3
- "version": "9.12.0",
3
+ "version": "9.13.0",
4
4
  "description": "Embedded Agentforce conversation client feature for UI Bundles",
5
5
  "license": "SEE LICENSE IN LICENSE.txt",
6
6
  "author": "",
@@ -26,7 +26,7 @@
26
26
  "clean": "rm -rf dist"
27
27
  },
28
28
  "dependencies": {
29
- "@salesforce/agentforce-conversation-client": "^9.12.0"
29
+ "@salesforce/agentforce-conversation-client": "^9.13.0"
30
30
  },
31
31
  "devDependencies": {
32
32
  "@types/react": "^19.2.7",