@atlaskit/rovo-triggers 9.11.0 → 10.0.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/CHANGELOG.md CHANGED
@@ -1,5 +1,27 @@
1
1
  # @atlaskit/rovo-triggers
2
2
 
3
+ ## 10.0.0
4
+
5
+ ### Major Changes
6
+
7
+ - [`bd3fa2ca8168d`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/bd3fa2ca8168d) -
8
+ Remove the "inline_view" creation context experience and all supporting highlight-actions plumbing
9
+ (the `creationContextParams` flow through the editor-placeholder store, chat input, pubsub
10
+ listener, and chat-new payload).
11
+
12
+ ## 9.11.1
13
+
14
+ ### Patch Changes
15
+
16
+ - [`ade4b041f6ad0`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/ade4b041f6ad0) -
17
+ Behind the `rovo_chat_fix_jira_prompt_dropped_on_reopen` gate, exclude
18
+ `jira-create-context-payload` from the `triggerLatest` replay slot (the same way
19
+ `set-message-context` is handled). This stops the Rovo chat panel, when reopened from a CTA, from
20
+ replaying the continuously-published context payload instead of the action `chat-new` that opened
21
+ the chat — which was dropping the prompt. The only consumer of this event
22
+ (`ChatContextSubscriber`) does not use `triggerLatest`, so live delivery is unaffected. Behaviour
23
+ is unchanged when the gate is off.
24
+
3
25
  ## 9.11.0
4
26
 
5
27
  ### Minor Changes
package/dist/cjs/main.js CHANGED
@@ -24,7 +24,13 @@ var isIgnoredForTriggerLatest = function isIgnoredForTriggerLatest(type) {
24
24
  if (ignoredTriggerLatestEvents.has(type)) {
25
25
  return true;
26
26
  }
27
- return type === 'set-message-context' && (0, _platformFeatureFlags.fg)('rovo_chat_fix_cold_start_prompt_insertion');
27
+ if (type === 'set-message-context') {
28
+ return (0, _platformFeatureFlags.fg)('rovo_chat_fix_cold_start_prompt_insertion');
29
+ }
30
+ if (type === 'jira-create-context-payload') {
31
+ return (0, _platformFeatureFlags.fg)('rovo_chat_fix_jira_prompt_dropped_on_reopen');
32
+ }
33
+ return false;
28
34
  };
29
35
  var createPubSub = function createPubSub() {
30
36
  var subscribedEvents = {};
@@ -11,7 +11,13 @@ const isIgnoredForTriggerLatest = type => {
11
11
  if (ignoredTriggerLatestEvents.has(type)) {
12
12
  return true;
13
13
  }
14
- return type === 'set-message-context' && fg('rovo_chat_fix_cold_start_prompt_insertion');
14
+ if (type === 'set-message-context') {
15
+ return fg('rovo_chat_fix_cold_start_prompt_insertion');
16
+ }
17
+ if (type === 'jira-create-context-payload') {
18
+ return fg('rovo_chat_fix_jira_prompt_dropped_on_reopen');
19
+ }
20
+ return false;
15
21
  };
16
22
  const createPubSub = () => {
17
23
  let subscribedEvents = {};
package/dist/esm/main.js CHANGED
@@ -17,7 +17,13 @@ var isIgnoredForTriggerLatest = function isIgnoredForTriggerLatest(type) {
17
17
  if (ignoredTriggerLatestEvents.has(type)) {
18
18
  return true;
19
19
  }
20
- return type === 'set-message-context' && fg('rovo_chat_fix_cold_start_prompt_insertion');
20
+ if (type === 'set-message-context') {
21
+ return fg('rovo_chat_fix_cold_start_prompt_insertion');
22
+ }
23
+ if (type === 'jira-create-context-payload') {
24
+ return fg('rovo_chat_fix_jira_prompt_dropped_on_reopen');
25
+ }
26
+ return false;
21
27
  };
22
28
  var createPubSub = function createPubSub() {
23
29
  var subscribedEvents = {};
@@ -61,30 +61,6 @@ type ChatModeParam = {
61
61
  useCurrentPageContext?: boolean;
62
62
  appFilters?: unknown[];
63
63
  };
64
- type SerializableCreationContextValue = string | number | boolean | null | undefined | {
65
- [key: string | number]: SerializableCreationContextValue;
66
- } | SerializableCreationContextValue[];
67
- export type CreationContextParams = {
68
- templateInput?: {
69
- templateId: string;
70
- templateType: string;
71
- };
72
- jiraContext?: unknown;
73
- dynamicUiType?: string;
74
- dynamicUiSubtype?: string;
75
- dynamicUiSource?: unknown;
76
- forcedContentType?: string;
77
- contentMauiId?: string;
78
- mediaFileId?: string;
79
- source?: string;
80
- shouldUseExistingContent?: boolean;
81
- isViewMode?: boolean;
82
- experience?: 'cwr' | 'cwr_type' | 'cwr_edit' | 'cwr_existing' | 'inline_edit' | 'inline_view' | 'remix' | 'remix_edit' | 'remix_object' | 'remix_custom' | 'chat_edit' | 'chat_view' | 'keep_existing_page_structure';
83
- contentTypes?: string[];
84
- blocks?: string[];
85
- spaceKey?: string;
86
- additionalContext?: Record<string, SerializableCreationContextValue>;
87
- };
88
64
  export type ResultAttributionContextPayload = {
89
65
  /**
90
66
  * Source surface that launched the agent chat, appended to generated result analytics.
@@ -104,7 +80,6 @@ export type ChatNewPayload = PayloadCore<'chat-new', {
104
80
  };
105
81
  }>;
106
82
  prompt?: string | DocNode;
107
- creationContextParams?: CreationContextParams;
108
83
  /**
109
84
  * Overrides the default auto-send behavior for prompts.
110
85
  * Set this to true to insert prompts not containing backticks into the chat input for dynamic
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@atlaskit/rovo-triggers",
3
- "version": "9.11.0",
3
+ "version": "10.0.0",
4
4
  "description": "Provides various trigger events to drive Rovo Chat functionality, such as a publish-subscribe and URL parameter hooks",
5
5
  "author": "Atlassian Pty Ltd",
6
6
  "publishConfig": {
@@ -41,7 +41,7 @@
41
41
  "@af/integration-testing": "workspace:^",
42
42
  "@af/visual-regression": "workspace:^",
43
43
  "@atlaskit/css": "^1.0.0",
44
- "@atlaskit/primitives": "^21.0.0",
44
+ "@atlaskit/primitives": "^22.0.0",
45
45
  "@atlaskit/ssr": "workspace:^",
46
46
  "@atlassian/a11y-jest-testing": "^0.13.0",
47
47
  "@atlassian/feature-flags-test-utils": "^1.2.0",
@@ -88,6 +88,9 @@
88
88
  "platform-feature-flags": {
89
89
  "rovo_chat_fix_cold_start_prompt_insertion": {
90
90
  "type": "boolean"
91
+ },
92
+ "rovo_chat_fix_jira_prompt_dropped_on_reopen": {
93
+ "type": "boolean"
91
94
  }
92
95
  }
93
96
  }