@qualified-salesforce/web 0.0.1-oidc-bootstrap → 0.1.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.
Files changed (98) hide show
  1. package/CAPABILITY-REFERENCE.md +41 -0
  2. package/CHANGELOG.md +84 -0
  3. package/README.md +65 -0
  4. package/constants.generated.js +30 -2
  5. package/css/widget/multimodal_v2/index.split-css.panda.css +265 -47
  6. package/package.json +18 -4
  7. package/packs/widget/api/docking/viewport_lock.js +93 -2
  8. package/packs/widget/esm/index.d.ts +134 -0
  9. package/packs/widget/esm/index.js +18 -2
  10. package/packs/widget/esm/qualified.css +265 -47
  11. package/src/graphql-types.js +74 -1
  12. package/src/url.js +4 -1
  13. package/vendor/actioncable/connection.js +40 -3
  14. package/vendor/actioncable/connection_monitor.js +8 -0
  15. package/vendor/actioncable/consumer.js +7 -1
  16. package/vendor/actioncable/index.js +5 -2
  17. package/vendor/actioncable/sse_socket.js +262 -0
  18. package/widget/analytics.js +8 -0
  19. package/widget/api_handler/base_api_handler.js +24 -0
  20. package/widget/booker_outcome_tracker.js +58 -20
  21. package/widget/capabilities.js +190 -0
  22. package/widget/channel.js +38 -6
  23. package/widget/constants.generated.js +2 -1
  24. package/widget/multimodal_v2/components/AppLayout.js +1 -1
  25. package/widget/multimodal_v2/components/app/Foreground.js +10 -9
  26. package/widget/multimodal_v2/components/app/Input.js +8 -3
  27. package/widget/multimodal_v2/components/app/LightboxExperience.js +17 -3
  28. package/widget/multimodal_v2/components/app/Main.js +87 -31
  29. package/widget/multimodal_v2/components/app/MessengerButton.js +18 -1
  30. package/widget/multimodal_v2/components/chat/ChatInputForm.js +8 -6
  31. package/widget/multimodal_v2/components/chat/timeline/CalendarEventPickRenderer.js +2 -2
  32. package/widget/multimodal_v2/components/chat/timeline/PresentDeckRenderer.js +346 -170
  33. package/widget/multimodal_v2/components/chat/timeline/SystemRenderer.js +4 -7
  34. package/widget/multimodal_v2/components/decks/index.js +506 -52
  35. package/widget/multimodal_v2/components/helpers/content_click_payloads.js +67 -1
  36. package/widget/multimodal_v2/components/lightbox_gather/index.js +4 -4
  37. package/widget/multimodal_v2/components/meetings/MeetingBookerEntry.js +8 -1
  38. package/widget/multimodal_v2/components/meetings/MeetingOfferEmailStep.js +1 -1
  39. package/widget/multimodal_v2/components/meetings/MeetingSummaryRail.js +1 -1
  40. package/widget/multimodal_v2/components/meetings/MeetingTimeSelector.js +1 -1
  41. package/widget/multimodal_v2/components/multimodal/Controls.js +11 -3
  42. package/widget/multimodal_v2/components/multimodal/useMultimodal.js +19 -7
  43. package/widget/multimodal_v2/components/presentations/index.js +61 -0
  44. package/widget/multimodal_v2/constants.js +1 -1
  45. package/widget/multimodal_v2/images/icons.js +17 -1
  46. package/widget/multimodal_v2/index.panda.js +2 -2
  47. package/widget/multimodal_v2/locales/cs.js +8 -1
  48. package/widget/multimodal_v2/locales/da.js +8 -1
  49. package/widget/multimodal_v2/locales/de.js +8 -1
  50. package/widget/multimodal_v2/locales/en.js +8 -1
  51. package/widget/multimodal_v2/locales/en_AU.js +8 -1
  52. package/widget/multimodal_v2/locales/en_GB.js +8 -1
  53. package/widget/multimodal_v2/locales/es.js +8 -1
  54. package/widget/multimodal_v2/locales/es_LA.js +8 -1
  55. package/widget/multimodal_v2/locales/fi.js +8 -1
  56. package/widget/multimodal_v2/locales/fr.js +8 -1
  57. package/widget/multimodal_v2/locales/fr_CA.js +8 -1
  58. package/widget/multimodal_v2/locales/id.js +8 -1
  59. package/widget/multimodal_v2/locales/it.js +8 -1
  60. package/widget/multimodal_v2/locales/ja.js +8 -1
  61. package/widget/multimodal_v2/locales/ko.js +8 -1
  62. package/widget/multimodal_v2/locales/nb.js +8 -1
  63. package/widget/multimodal_v2/locales/nl.js +8 -1
  64. package/widget/multimodal_v2/locales/pl.js +8 -1
  65. package/widget/multimodal_v2/locales/pt_BR.js +8 -1
  66. package/widget/multimodal_v2/locales/ru.js +8 -1
  67. package/widget/multimodal_v2/locales/sv.js +8 -1
  68. package/widget/multimodal_v2/locales/th.js +8 -1
  69. package/widget/multimodal_v2/locales/tr.js +8 -1
  70. package/widget/multimodal_v2/locales/vi.js +8 -1
  71. package/widget/multimodal_v2/locales/zh_CN.js +8 -1
  72. package/widget/multimodal_v2/locales/zh_TW.js +8 -1
  73. package/widget/multimodal_v2/multimodal.js +5 -1
  74. package/widget/multimodal_v2/multimodal_channel.js +13 -8
  75. package/widget/multimodal_v2/signals/messages_signal.js +4 -0
  76. package/widget/multimodal_v2/stores/ai_conversation_store.js +6 -2
  77. package/widget/multimodal_v2/stores/artifact_store.js +352 -27
  78. package/widget/multimodal_v2/stores/call_store.js +40 -1
  79. package/widget/multimodal_v2/stores/call_ui_adapter.js +1 -1
  80. package/widget/multimodal_v2/stores/decks_store.js +405 -39
  81. package/widget/multimodal_v2/stores/meeting_store.js +15 -10
  82. package/widget/multimodal_v2/stores/presentation_ga_adapter.js +64 -0
  83. package/widget/multimodal_v2/stores/presentation_telemetry_store.js +556 -0
  84. package/widget/multimodal_v2/stores/presentations_store.js +1 -0
  85. package/widget/multimodal_v2/stores/root_store.js +157 -268
  86. package/widget/multimodal_v2/stores/screen_share_store.js +41 -21
  87. package/widget/multimodal_v2/stores/translation_store.js +9 -0
  88. package/widget/multimodal_v2/stores/ui_store.js +7 -7
  89. package/widget/multimodal_v2/stores/website_navigation_store.js +3 -1
  90. package/widget/multimodal_v2/text_turn_response_tracker.js +419 -0
  91. package/widget/multimodal_v2/types.js +21 -1
  92. package/widget/multimodal_v2/utils/locale.js +2 -1
  93. package/widget/multimodal_v2/utils/signals.js +35 -4
  94. package/widget/pardot_visitor.js +7 -1
  95. package/widget/server-logger.js +97 -2
  96. package/widget/tracker.js +69 -21
  97. package/widget/widget/page_mirror_factory.js +9 -1
  98. package/widget/widget/widget.js +29 -4
@@ -110,7 +110,14 @@
110
110
  viewSlide: "ดูสไลด์ {{id}}"
111
111
  },
112
112
  presentation: {
113
- start: "เริ่มการนำเสนอ"
113
+ start: "เริ่มการนำเสนอ",
114
+ continue: "ดูการนำเสนอต่อ",
115
+ slideCount: "{{count}} สไลด์",
116
+ previousSlide: "สไลด์ก่อนหน้า",
117
+ nextSlide: "สไลด์ถัดไป",
118
+ slidePosition: "สไลด์ {{current}} จาก {{total}}",
119
+ switchToVoice: "สลับเป็นโหมดเสียง",
120
+ starting: "กำลังเริ่มการนำเสนอ"
114
121
  },
115
122
  shared: {
116
123
  moreAvatars: "+{{count}} เพิ่มเติม",
@@ -110,7 +110,14 @@
110
110
  viewSlide: "Slayt {{id}}'ı görüntüle"
111
111
  },
112
112
  presentation: {
113
- start: "Sunumu başlat"
113
+ start: "Sunumu başlat",
114
+ continue: "Sunuma devam et",
115
+ slideCount: "{{count}} slayt",
116
+ previousSlide: "Önceki slayt",
117
+ nextSlide: "Sonraki slayt",
118
+ slidePosition: "{{total}} slayttan {{current}}. slayt",
119
+ switchToVoice: "Ses moduna geç",
120
+ starting: "Sunum başlatılıyor"
114
121
  },
115
122
  shared: {
116
123
  moreAvatars: "+{{count}} daha",
@@ -110,7 +110,14 @@
110
110
  viewSlide: "Xem slide {{id}}"
111
111
  },
112
112
  presentation: {
113
- start: "Bắt đầu bài thuyết trình"
113
+ start: "Bắt đầu bài thuyết trình",
114
+ continue: "Tiếp tục bài thuyết trình",
115
+ slideCount: "{{count}} slide",
116
+ previousSlide: "Slide trước",
117
+ nextSlide: "Slide tiếp theo",
118
+ slidePosition: "Slide {{current}} / {{total}}",
119
+ switchToVoice: "Chuyển sang chế độ giọng nói",
120
+ starting: "Đang bắt đầu bài thuyết trình"
114
121
  },
115
122
  shared: {
116
123
  moreAvatars: "+{{count}} nữa",
@@ -110,7 +110,14 @@
110
110
  viewSlide: "查看幻灯片 {{id}}"
111
111
  },
112
112
  presentation: {
113
- start: "开始演示"
113
+ start: "开始演示",
114
+ continue: "继续演示",
115
+ slideCount: "{{count}} 张幻灯片",
116
+ previousSlide: "上一张幻灯片",
117
+ nextSlide: "下一张幻灯片",
118
+ slidePosition: "第 {{current}} 张,共 {{total}} 张",
119
+ switchToVoice: "切换到语音模式",
120
+ starting: "正在开始演示"
114
121
  },
115
122
  shared: {
116
123
  moreAvatars: "+{{count}} 更多",
@@ -110,7 +110,14 @@
110
110
  viewSlide: "查看幻燈片 {{id}}"
111
111
  },
112
112
  presentation: {
113
- start: "開始簡報"
113
+ start: "開始簡報",
114
+ continue: "繼續簡報",
115
+ slideCount: "{{count}} 張幻燈片",
116
+ previousSlide: "上一張幻燈片",
117
+ nextSlide: "下一張幻燈片",
118
+ slidePosition: "第 {{current}} 張,共 {{total}} 張",
119
+ switchToVoice: "切換至語音模式",
120
+ starting: "正在開始簡報"
114
121
  },
115
122
  shared: {
116
123
  moreAvatars: "+{{count}} 更多",
@@ -225,7 +225,7 @@ class Multimodal extends WidgetObject {
225
225
  * later ensureUI() can resolve it again. Full disposal passes false so awaiters
226
226
  * (startCall/startChat) settle instead of hanging on a promise nothing resolves.
227
227
  */ teardownUI(param) {
228
- let { rebuildable = true } = param === void 0 ? {} : param;
228
+ let { rebuildable = true, presentationEndReason } = param === void 0 ? {} : param;
229
229
  var _this_inlineMeetingBooker, _this__rootStore, _this_host;
230
230
  if (!this._rootStore && !this.host) {
231
231
  if (!rebuildable && !this.ready.isSettled) {
@@ -239,6 +239,10 @@ class Multimodal extends WidgetObject {
239
239
  if (rebuildable) {
240
240
  this.ready = createBetterPromise();
241
241
  }
242
+ if (presentationEndReason) {
243
+ var _this__rootStore1;
244
+ (_this__rootStore1 = this._rootStore) == null ? void 0 : _this__rootStore1.presentationTelemetryStore.onExperienceReplaced();
245
+ }
242
246
  this.uiDisposers.forEach((dispose)=>dispose());
243
247
  this.uiDisposers = [];
244
248
  (_this_inlineMeetingBooker = this.inlineMeetingBooker) == null ? void 0 : _this_inlineMeetingBooker.dispose();
@@ -77,7 +77,8 @@ class MultimodalChannel extends Disposable(Object) {
77
77
  off(event, listener) {
78
78
  return this._emitter.off(event, listener);
79
79
  }
80
- perform(action, data) {
80
+ perform(action, data, param) {
81
+ let { reportTimeout = true } = param === void 0 ? {} : param;
81
82
  const id = esm_browser_v4();
82
83
  const event = "" + action + ":response";
83
84
  const promise = createBetterPromise();
@@ -90,13 +91,15 @@ class MultimodalChannel extends Disposable(Object) {
90
91
  settle(result);
91
92
  };
92
93
  const timeoutCallback = ()=>{
93
- var _getSentryClient, _this_widget_config_featureFlags;
94
94
  const error = new Error("Timeout waiting for " + event + " with id " + id);
95
- (_getSentryClient = getSentryClient({
96
- project: "multimodal"
97
- })) == null ? void 0 : _getSentryClient.captureException(error);
98
- if ((_this_widget_config_featureFlags = this.widget.config.featureFlags) == null ? void 0 : _this_widget_config_featureFlags.piperXAgent) {
99
- metrics.emitIncrement("multimodal_client_error");
95
+ if (reportTimeout) {
96
+ var _getSentryClient, _this_widget_config_featureFlags;
97
+ (_getSentryClient = getSentryClient({
98
+ project: "multimodal"
99
+ })) == null ? void 0 : _getSentryClient.captureException(error);
100
+ if ((_this_widget_config_featureFlags = this.widget.config.featureFlags) == null ? void 0 : _this_widget_config_featureFlags.piperXAgent) {
101
+ metrics.emitIncrement("multimodal_client_error");
102
+ }
100
103
  }
101
104
  settle({
102
105
  error: {
@@ -157,7 +160,9 @@ class MultimodalChannel extends Disposable(Object) {
157
160
  // rendering over the legacy messenger. (Initial legacy sessions skip this.)
158
161
  if (prevMode === "new") {
159
162
  var _this_widget_multimodal1;
160
- (_this_widget_multimodal1 = this.widget.multimodal) == null ? void 0 : _this_widget_multimodal1.teardownUI();
163
+ (_this_widget_multimodal1 = this.widget.multimodal) == null ? void 0 : _this_widget_multimodal1.teardownUI({
164
+ presentationEndReason: "replaced"
165
+ });
161
166
  }
162
167
  // Restore the legacy iframe in case an earlier switch had hidden it.
163
168
  this.widget.showLegacyMessenger();
@@ -14,6 +14,9 @@ function createMessagesSignal(initialMessages) {
14
14
  const hasVisitorTextMessage = signals_core_module_w(()=>{
15
15
  return messages.value.some((message)=>message.type === "text" && message.isOwn);
16
16
  });
17
+ const hasVisitorEngaged = signals_core_module_w(()=>{
18
+ return messages.value.some((message)=>isVisitorMessage(message) || isEventMessage(message, "ai_sdr_call_requested"));
19
+ });
17
20
  const pounceMessage = signals_core_module_w(()=>findPounceMessage(messages.value));
18
21
  // A human rep pounce *is* a rep text message (userId + !isAp). We only want to
19
22
  // deactivate when a rep sends a follow-up *after* the pounce. findPounceMessage
@@ -106,6 +109,7 @@ function createMessagesSignal(initialMessages) {
106
109
  hasPounceDismissed,
107
110
  hasAiSdrCallRequested,
108
111
  hasVisitorTextMessage,
112
+ hasVisitorEngaged,
109
113
  hasRepTextMessage,
110
114
  pounceActive,
111
115
  repliedToIds
@@ -1,6 +1,7 @@
1
1
  import { __webpack_require__ } from "../../../js/runtime.js";
2
2
  import { signals_core_module_r, signals_core_module_d } from "../../../js/multimodal_v2.js";
3
3
  import { snakify } from "../../../src/utils.js";
4
+ import { isCapabilityAllowed } from "../../capabilities.js";
4
5
  import "../../telemetry/index.js";
5
6
  import "../../utils/native_globals.js";
6
7
  import { ConversationMode as types_ConversationMode } from "../types.js";
@@ -26,6 +27,7 @@ function _extends() {
26
27
 
27
28
 
28
29
 
30
+
29
31
  class AiConversationStore {
30
32
  emitAvailabilityFailed() {
31
33
  if (this.availabilityTimeoutId === null) return;
@@ -110,8 +112,10 @@ class AiConversationStore {
110
112
  this.handleStartResponse(response.data);
111
113
  }
112
114
  try {
113
- // Initialize navigation interception only when we know the conversation was created successfully
114
- if (this.conversation.value) {
115
+ // Arm navigation interception only on a created conversation, and only when the
116
+ // `agentNavigation` capability is allowed (QAI-5863). Unlike navigate_content/point_cursor,
117
+ // this arms on call start, not off a backend message, so it checks the boundary directly.
118
+ if (isCapabilityAllowed("agentNavigation") && this.conversation.value) {
115
119
  const store = await this.rootStore.websiteNavigationStore.load();
116
120
  // Guard: conversation may have been cleared while we were waiting for the response
117
121
  if (this.conversation.value) {